Constructs a new MdmResource
.
Optionally provide configuration options to this resource class. If not provided, suitable defaults will be used.
Optionally provide a specific IMdmRestHandler. If not provided, the DefaultMdmRestHandler implementation will be used.
Stores the base API endpoint for all REST requests.
Stores the default options to apply to every REST request.
Generate a query string for a URL based on object property values provided.
A query string parameters object to convert to a string.
A URL encoded string containing each parameter and value, or an empty string if no properties were provided.
HTTP GET
- Gets an API property by ID.
The UUID of the property to get.
Optional query string parameters, if required.
Optional REST handler options, if required.
The result of the GET
request.
On success, the response will be a 200 OK
and contain a response body similar to below:
{
id: 'c7de1358-a4ce-4d72-abca-04013f7f4acc',
key: 'test.property',
value: 'test',
category: 'Test',
publiclyVisible: true,
lastUpdatedBy: 'user@test.com',
createdBy: 'admin@test.com',
lastUpdated: '2021-03-10T15:17:05.459Z'
}
Test if a string represents a UUID.
The string to test.
True if value
represents a UUID.
HTTP GET
- Gets a list of all API properties.
Optional query string parameters, if required.
Optional REST handler options, if required.
The result of the GET
request.
On success, the response will be a 200 OK
and contain a response body similar to below:
{
count: 1,
items: [
{
id: 'c7de1358-a4ce-4d72-abca-04013f7f4acc',
key: 'test.property',
value: 'test',
category: 'Test',
publiclyVisible: false,
lastUpdatedBy: 'user@test.com',
createdBy: 'admin@test.com',
lastUpdated: '2021-03-10T15:17:05.459Z'
}
]
}
HTTP GET
- Gets a list of all publicly accessible API properties. Administrator permissions are not required for this API.
Optional query string parameters, if required.
Optional REST handler options, if required.
The result of the GET
request.
On success, the response will be a 200 OK
and contain a response body similar to below:
{
count: 1,
items: [
{
id: 'c7de1358-a4ce-4d72-abca-04013f7f4acc',
key: 'test.property',
value: 'test',
category: 'Test',
publiclyVisible: true,
lastUpdatedBy: 'user@test.com',
createdBy: 'admin@test.com',
lastUpdated: '2021-03-10T15:17:05.459Z'
}
]
}
HTTP DELETE
- Removes an existing API property.
The UUID of the property to remove.
Optional query string parameters, if required.
Optional REST handler options, if required.
The result of the DELETE
request.
On success, the response will be a 204 No Content
and the response body will be empty.
HTTP POST
- Creates a new API property.
The data to use for creation.
Optional REST handler parameters.
The result of the POST
request.
On success, the response will be a 200 OK
and the response body will be the same as that returned
from the get()
function.
Send a HTTP DELETE
request to the given resource.
The full URL to the REST resource.
Optional query string parameters, if required.
Optional REST handler options, if required.
The result of the DELETE
request.
Send a HTTP GET
request to the given resource.
The full URL to the REST resource.
Optional query string parameters, if required.
Optional REST handler options, if required.
The result of the GET
request.
Send a HTTP POST
request to the given resource.
The full URL to the REST resource.
The data to include in the POST
request body.
Optional REST handler options, if required.
The result of the POST
request.
Send a HTTP PUT
request to the given resource.
The full URL to the REST resource.
The data to include in the PUT
request body.
Optional REST handler options, if required.
The result of the PUT
request.
Send a generic HTTP request to the given resource.
The full URL to the REST resource.
Optional query string parameters, if required.
Optional REST handler options, if required.
The result of the request.
All details of HTTP request must be included in the options
parameter, particularly the HTTP method:
simpleRequest('http://localhost/api/test', { }, { method: 'GET' });
HTTP PUT
- Updates an existing API property.
The UUID of the property to update.
The data to use for the update.
Optional REST handler options, if required.
The result of the PUT
request.
On success, the response will be a 200 OK
and the response body will be the same as that returned
from the get()
function.
Generated using TypeDoc
MDM resource for managing system properties in the Mauro instance.