Unknown macro: {next_previous_links}
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Current »

This section explains the following REST operations regarding the associations / association of the resource which have been secured with Basic Auth.

The following terms explain the meaning of the query parameters passed with the following REST URIs.

ParameterExplanation
pathPath of the resource.
typeType of association. By default, Governance Registry has three types of association. These are usedBy, ownedBy, and other.
startStart page number.
sizeNumber of associations to be fetched.
targetTarget resource path

The { start page } and { number of records } parameters can take any value greater than or equal to 0. The { start page } and { number of records } begins with 1. If both of them are 0, then all the associations are retrieved.

Get all the Associations on a Resource

AttributesValues

HTTP Method                

GET
Request URI/associations?path={ resource path }&start={ start page }&size={ number of records }
HTTP Request HeaderAuthorization: Basic { base64encoded(username:password) }
ResponseIt retrieves all the associations posted on the specific resource.
ResponseHTTP 200 OK
Response Typeapplication/json

Get Associations of Specific Type on a Given Resource

AttributesValues

HTTP Method                 

GET
Request URI/associations?path={ resource path }&type={ association type }
HTTP Request HeaderAuthorization: Basic { base64encoded(username:password) }

Description

It retrieves all the associations for the specific type of the given resource
ResponseHTTP 200 OK
Response Typeapplication/json

Add Associations to a Resource

AttributesValues

HTTP Method                 

POST
Request URI/associations?path={resource path}
HTTP Request Header

Authorization: Basic { base64encoded(username:password) }

Content-Type: application/json

Payload[{ "type":"<type of the association>","target":"<valid resource path>"}] 

Description

It adds the array of associations passed as the payload for the source resource
ResponseHTTP 204 No Content.
Response Typeapplication/json

Add Association to a Resource

AttributesValues

HTTP Method                 

POST
Request URI/associations?path={resource path}&targetPath={target resource}&type={assocation type}
HTTP Request Header

Authorization: Basic { base64encoded(username:password) }

Content-Type: application/json

ResponseHTTP 204 No Content.
Response Typeapplication/json

Delete Associations on a Given Resource

AttributesValues

HTTP Method                 

DELETE
Request URI/association?path={resource path}&targetPath={target path}&type={association type}

Description

It deletes the association between the source and target resources for the given association type.
ResponseHTTP 204 No Content.
Response Typeapplication/json

 

 

  • No labels