Creates an instance of the ResourcesApi.
The configuration object for the Permit SDK.
The logger instance for logging.
Creates a new resource.
The data for the new resource.
A promise that resolves to the created resource.
PermitApiError If the API returns an error HTTP status code.
PermitContextError If the configured ApiContext does not match the required endpoint context.
Deletes a resource.
The key of the resource to delete.
A promise that resolves when the resource is deleted.
PermitApiError If the API returns an error HTTP status code.
PermitContextError If the configured ApiContext does not match the required endpoint context.
Ensure that the API Key has the necessary permissions to successfully call the API endpoint. Note that this check is not foolproof, and the API may still throw 401.
The required API Key Access level for the endpoint.
PermitContextError If the currently set API key access level does not match the required access level.
Ensure that the API context matches the required endpoint context.
The required API context level for the endpoint.
PermitContextError If the currently set API context level does not match the required context level.
Retrieves a resource by its key.
The key of the resource.
A promise that resolves to the resource.
PermitApiError If the API returns an error HTTP status code.
PermitContextError If the configured ApiContext does not match the required endpoint context.
Retrieves a resource by its ID. Alias for the get method.
The ID of the resource.
A promise that resolves to the resource.
PermitApiError If the API returns an error HTTP status code.
PermitContextError If the configured ApiContext does not match the required endpoint context.
Retrieves a resource by its key. Alias for the get method.
The key of the resource.
A promise that resolves to the resource.
PermitApiError If the API returns an error HTTP status code.
PermitContextError If the configured ApiContext does not match the required endpoint context.
Retrieves a list of resources.
Optional
pagination: IPaginationThe pagination options,
A promise that resolves to an array of resources.
PermitApiError If the API returns an error HTTP status code.
PermitContextError If the configured ApiContext does not match the required endpoint context.
Creates a resource if such a resource does not exists, otherwise completely replaces the resource configuration.
The key of the resource.
The updated data for the resource.
A promise that resolves to the updated resource.
PermitApiError If the API returns an error HTTP status code.
PermitContextError If the configured ApiContext does not match the required endpoint context.
Updates a resource.
The key of the resource.
The updated data for the resource.
A promise that resolves to the updated resource.
PermitApiError If the API returns an error HTTP status code.
PermitContextError If the configured ApiContext does not match the required endpoint context.
Generated using TypeDoc
The ResourcesApi class provides methods for interacting with Permit Resources.