Last updated 1 day ago
Gets all registry sources
Registry sources
const response = await fetch('./../api/v1//registry-source/', { method: 'GET', headers: { "token": "API-Key <apiKey>" }, }); const data = await response.json();
{ "data": { "sources": [ { "id": "unique-cuid-v2-auto-generated", "type": "WEB3_CARDANO_V1", "identifier": "optional_identifier", "url": "optional_url", "note": "optional_note", "apiKey": "optional_apiKey", "network": "PREPROD", "latestPage": 1, "latestIdentifier": "optional_latestIdentifier" } ] }, "status": "success" }
Creates a new registry source
Registry source
const response = await fetch('./../api/v1//registry-source/', { method: 'POST', headers: { "token": "API-Key <apiKey>", "Content-Type": "application/json" }, body: JSON.stringify({ "type": "WEB3_CARDANO_V1", "identifier": "optional_identifier", "note": "optional_note", "apiKey": "apiKey", "network": "PREPROD" }), }); const data = await response.json();
{ "data": { "id": "unique-cuid-v2-auto-generated" }, "status": "success" }
Updates a registry source
const response = await fetch('./../api/v1//registry-source/', { method: 'PATCH', headers: { "token": "API-Key <apiKey>", "Content-Type": "application/json" }, body: JSON.stringify({ "id": "unique-cuid-v2-auto-generated", "note": "optional_note", "apiKey": "optional_apiKey" }), }); const data = await response.json();
const response = await fetch('./../api/v1//registry-source/', { method: 'DELETE', headers: { "token": "API-Key <apiKey>", "Content-Type": "application/json" }, body: JSON.stringify({ "id": "unique-cuid-v2-auto-generated" }), }); const data = await response.json();