operations.add_service
POST
/services
const url = 'https://raw.githubusercontent.com/federation/v1/services';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"id":"example","url":"example","version":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://raw.githubusercontent.com/federation/v1/services \ --header 'Content-Type: application/json' \ --data '{ "id": "example", "url": "example", "version": "example" }'Add a service to the federation.
Parameters
Section titled “ Parameters ”Query Parameters
Section titled “Query Parameters ” register
boolean
Re-register all known servers/services
Request Body
Section titled “Request Body ” Media type application/json
A local CanDIG service that can be queried by the federation service
object
id
string
url
Local URL for use by the federation service
string
version
Version of the service
string
Example generated
{ "id": "example", "url": "example", "version": "example"}Responses
Section titled “ Responses ”Service registered successfully
Authorization Error
Internal Error