Core - Issuing Authorities
The base url for the APIs in this page is at:
/api/admin
A JSON file with OpenAPI data about all core-related admin APIs can be downloaded here
.
Get country codes
Gets a list of country codes available on the database:
Returns a positive Json response with list of the country codes for issuing authorities, in the ISO3661 alpha-3 format:
{
[ "AUT","CHE","FRA","ITA","SVN" ] // String Array
}
Get issuing authorities
Gets the list of issuing authorities available on the database (it’s a Paged List APIs, as explained in the introduction):
Returns the list of the issuing authorities:
[
{
ID: 1234, // Int
Name: "Driver and Vehicle Licensing Agency", // String
CreatedDate: "2001-01-01T01:01:01Z", // DateTime
LastUpdated: "2001-01-01T01:01:01Z", // DateTime
Code: "DVLA", // String
IsToBeVerified: true, // Boolean
CountryCode: "GBR" // String
},
...
]
The CountryCode
property value is a country code in the ISO3661 alpha-3 format.
Add new or edit existing issuing authority
Persists edits about a new or existing issuing authority:
The body of the request is:
{
ID: 123, // Int
Name: "Driver and Vehicle Licensing Agency", // String
CountryCode: "GBR", // String
Code: "DVLA", // String
}
If ID
is not provided or is set to 0, then it will add a new issuing authority record. Otherwise, it will edit the existing record corresponding to the ID
.
The CountryCode
property value is a country code in the ISO3661 alpha-3 format.
If the request is successful it will return a plain Json positive response.
Possible error messages are:
err_InvalidElement
No name, code or countryt code has been provided in the request body, or no authority to edit has been found for the provided
ID
err_DuplicatedElement
The user is trying to add an issuing authority with the same country code and the same code or name
Delete issuing authority
Removes an issuing authority record corresponding to the provided ID from the database:
If successful it returns a plain Json positive answer.
Possible error messages are:
err_ElementDoesNotExist
The ID provided doest not correspond to any existing record
err_ElementAlreadyDeleted
The ID provided corresponds to a record that has already been deleted
err_CannotDeleteExistingDocuments
The issuing authority cannot be deleted because there currently are documents issued by it