Skip to content

Authority REST API - Association Controller

The association/from/<type>/<code>/to/<totype>/<tocode> URL manipulates individual Associations between two Assets.

HEAD /association/from/<type>/<code>/to/<totype>/<tocode>

Checks if an Association exists between two Assets.

ParameterDescription
typeA single URL-encoded Asset Type code.
codeA single URL-encoded Asset code.
totypeA single URL-encoded Asset Type code.
tocodeA single URL-encoded Asset code.
CodeStatusDescription
204SuccessThe Association exists.
404FailureThe Association does not exist.
422FailureInvalid data was provided.
Content is a JSON array of one or more error codes describing the problem.

GET /association/from/<type>/<code>/to/<totype>/<tocode>

Retreives an Association between two Assets.

ParameterDescription
typeA single URL-encoded Asset Type code.
codeA single URL-encoded Asset code.
totypeA single URL-encoded Asset Type code.
tocodeA single URL-encoded Asset code.
CodeStatusDescription
200SuccessThe Association exists.
Content is a single FullAssociation object.
404FailureThe Association does not exist.
422FailureInvalid data was provided.
Content is a JSON array of one or more error codes describing the problem.

POST /association/from/<type>/<code>/to/<totype>/<tocode>

Adds or updates an Association between two Assets. The Context data will be merged with any existing Association and Assets.

ParameterDescription
typeA single URL-encoded Asset Type code.
codeA single URL-encoded Asset code.
totypeA single URL-encoded Asset Type code.
tocodeA single URL-encoded Asset code.

A single FullAssociation object to add or update. The supplied Asset Types and codes must match that of the URL.

CodeStatusDescription
201SuccessThe Association was registered.
The redirect Location will point to the Association.
422FailureInvalid data was provided.
Content is a JSON array of one or more error codes describing the problem.

DELETE /association/from/<type>/<code>/to/<totype>/<tocode>

Deletes an Association between two Assets.

Alternatively, if one or more app codes are included, removes any matching context data instead. Deletion when there’s no more context data is controlled by deleteOnEmpty.

ParameterDescription
typeA single URL-encoded Asset Type code.
codeA single URL-encoded Asset code.
totypeA single URL-encoded Asset Type code.
tocodeA single URL-encoded Asset code.
ParameterExpectedDescription
appOptionalAn Application identifier. Context data for this Application will be removed from the Association.
Can be specified multiple times to delete additional Applications.
deleteOnEmptyOptionalA boolean true/false. If true, and one or more app values are provided, the Association will be deleted when its context data is empty.
CodeStatusDescription
204SuccessThe Association was deleted.
404FailureThe Association does not exist.
422FailureInvalid data was provided.
Content is a JSON array of one or more error codes describing the problem.