Create an API resource
Creates a new API resource that represents a protected backend or service and can be referenced by clients to request access tokens.
API-KeyX-API-KEY<token>MonoCloud APIs require authentication with an API key. Retrieve your key from the Tenant Settings section of the MonoCloud dashboard and include it in the request header as: X-API-Key: <your_api_key>
Request Body
application/json
The request payload used to create an API resource.
TypeScript Definitions
Use the request body type in TypeScript.
Create API Resource Request: Creates a protected backend or service.
Response Headers
201
Returns the location header
uriResponse Body
application/json
The API resource was created successfully
TypeScript Definitions
Use the response body type in TypeScript.
API Resource Response: Represents a protected API resource and its access-token issuance configuration.
Errors
curl -X POST "https://your-domain.us.monocloud.com/api/resources/api_resources" \ -H "X-API-KEY: <token>" \ -H "Content-Type: application/json" \ -d '{ "audience": "http://example.com" }'{ "id": "string", "enabled": true, "display_name": null, "description": null, "creation_time": 0, "last_updated": 0, "audience": "string", "allow_multi_audience": true, "allow_user_info_access": true, "access_token_type": "jwt", "access_token_lifetime": 0, "bind_tokens_to_session": true, "include_jwt_id": true, "user_claims": [ "string" ]}