Source: https://atomicwork-preview.docs-staging.pageloop.ai/api-reference/accessmanagement/postapi-v-1-iga-entitlements

# Create an entitlement

POST `https://{tenant}.atomicwork.com/api/v1/iga/entitlements`

Create a new identity entitlement. Requires app\_id and type.
The entitlement can then be associated with policies and granted to users.

## Authorization

#### X-Api-Key (header, string, required)

## Headers

#### X-Workspace-Id (header, string)

## Body

#### name (body, string, required)

Name of the entitlement

#### description (body, string)

Description of the entitlement

#### app\_id (body, integer, required)

ID of the identity resource app this entitlement belongs to

#### status (body, enum (string))

Status of the entitlement. Defaults to PUBLISHED if not specified.

#### provisioning\_config (body, object)

#### properties

#### provider (enum (string), required)

Provisioning provider

#### type (enum (string), required)

Type of provisioning configuration

#### value (object, required)

#### deprovisioning\_config (body, object)

#### properties

#### provider (enum (string), required)

Deprovisioning provider

#### type (enum (string), required)

Type of deprovisioning configuration

#### value (object, required)

## Response

#### 200

Successful response

#### Request

```bash cURL
curl -X POST 'https://{tenant}.atomicwork.com/api/v1/iga/entitlements' \
  -H 'X-Api-Key: <api-key>' \
  -H 'Content-Type: application/json' \
  -d '{"name": "string", "description": "string", "app_id": 0, "status": "UNPUBLISHED", "provisioning_config": {"provider": "OKTA", "type": "OKTA_GROUP_PROVISIONING", "value": {"label": "string", "icon": {"name": "\u2026", "type": "\u2026", "url": "\u2026"}, "value": "string"}}, "deprovisioning_config": {"provider": "OKTA", "type": "OKTA_GROUP_DEPROVISIONING", "value": {"value": "string", "label": "string", "icon": {"name": "\u2026", "type": "\u2026", "url": "\u2026"}}}}'
```

```javascript JavaScript
const res = await fetch('https://{tenant}.atomicwork.com/api/v1/iga/entitlements', {
  method: 'POST',
  headers: {
    'X-Api-Key': '<api-key>',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({"name": "string", "description": "string", "app_id": 0, "status": "UNPUBLISHED", "provisioning_config": {"provider": "OKTA", "type": "OKTA_GROUP_PROVISIONING", "value": {"label": "string", "icon": {"name": "\u2026", "type": "\u2026", "url": "\u2026"}, "value": "string"}}, "deprovisioning_config": {"provider": "OKTA", "type": "OKTA_GROUP_DEPROVISIONING", "value": {"value": "string", "label": "string", "icon": {"name": "\u2026", "type": "\u2026", "url": "\u2026"}}}}),
});
const data = await res.json();
```

```python Python
import requests

res = requests.post(
    'https://{tenant}.atomicwork.com/api/v1/iga/entitlements',
    headers={'X-Api-Key': '<api-key>'},
    json={"name": "string", "description": "string", "app_id": 0, "status": "UNPUBLISHED", "provisioning_config": {"provider": "OKTA", "type": "OKTA_GROUP_PROVISIONING", "value": {"label": "string", "icon": {"name": "\u2026", "type": "\u2026", "url": "\u2026"}, "value": "string"}}, "deprovisioning_config": {"provider": "OKTA", "type": "OKTA_GROUP_DEPROVISIONING", "value": {"value": "string", "label": "string", "icon": {"name": "\u2026", "type": "\u2026", "url": "\u2026"}}}}
)
data = res.json()
```
