This section provides a reference for APIs that should be implemented by this Building Block.
This section provides a reference for APIs that should be implemented by this Building Block. The APIs defined here establish a blueprint for how the Building Block will interact with other Building Blocks. Additional APIs may be implemented by the Building Block, but the listed APIs define a minimal set of functionality that should be provided by any implementation of this Building Block.
The GovStack non-functional requirements document provides additional information on how 'adaptors' may be used to translate an existing API to the patterns described here. This section also provides guidance on how candidate products are tested and how GovStack validates a product's API against the API specifications defined here.
The tests for the Consent Building Block can be found in this GitHub repository.
The following is an automated rendition of our latest OpenAPI YAML specification.
CREATE - Creates a new Policy object and returns the new object and a PolicyRevision
/config/policy/
An object of type Policy
READ - get a Policy object + latest Revisio
/config/policy/{policyId}//
Unique ID of an object
An object with id revisionId
LIST - returns the current Policy
/config/policy/{policyId}/revisions/
Unique ID of an object
Requested index for start of resources to be provided in response requested by client
Requested number of resources to be provided in response requested by client
LIST - Fetches list of readable Policy objects
/config/policies/
An object with id revisionId
Requested index for start of resources to be provided in response requested by client
Requested number of resources to be provided in response requested by client
CREATE - Creates an Individual in the Consent system
/service/individual/
An object of type Individual
READ - Fetch an Individual in the Consent system
/service/individual/{individualId}//
Unique ID of an object
UPDATE - Updates an Individual in the Consent system
/service/individual/{individualId}//
Unique ID of an object
An object of type Individual
LIST - lists individuals in the system
/service/individuals/
Requested index for start of resources to be provided in response requested by client
Requested number of resources to be provided in response requested by client
READ - fetches the latest version of a Policy and the presented revisionId of an associated Agreement
/service/policy/{policyId}//
Unique ID of an object
An object with id revisionId
DELETE - Cascading delete operation for Right To Be Forgotten, deletes all Consent Records that shall not be retained and have a "forgettable" Agreement. May also delete an unsigned Consent Record, for instance in cases where the user exits the signing process. Individual ID supplied as HTTP header.
/service/individual/record/
No body