mirror of
https://github.com/LukeHagar/api-specs.git
synced 2025-12-09 20:37:50 +00:00
* added new oauth2 flow and description * renamed authentication to make more sense' by github action: 5967546682
43 lines
1.2 KiB
YAML
43 lines
1.2 KiB
YAML
post:
|
|
operationId: createEntitlement
|
|
tags:
|
|
- Entitlements
|
|
summary: Creates an entitlement
|
|
description: >-
|
|
This internal endpoint creates an entitlement using the given entitlement payload
|
|
security:
|
|
- UserContextAuth: [idn:entitlement:manage]
|
|
requestBody:
|
|
required: true
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: '../schemas/gov-entitlement/EntitlementDTO.yaml'
|
|
responses:
|
|
'201':
|
|
description: Returns the created entitlement DTO object.
|
|
content:
|
|
application/json:
|
|
schema:
|
|
type: array
|
|
items:
|
|
$ref: '../schemas/gov-entitlement/EntitlementDTO.yaml'
|
|
'400':
|
|
description: |
|
|
* Source is missing
|
|
* Source schema is missing
|
|
* Entitlement value is missing and source schema object type is not of the permission type
|
|
* Attribute is missing
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: '../../v3/schemas/ErrorResponseDto.yaml'
|
|
'401':
|
|
$ref: '../../v3/responses/401.yaml'
|
|
'403':
|
|
$ref: '../../v3/responses/403.yaml'
|
|
'429':
|
|
$ref: '../../v3/responses/429.yaml'
|
|
'500':
|
|
$ref: '../../v3/responses/500.yaml'
|