# Offer a document category to an entity type

`POST /lokta-lms/api/v1/documentcategories`

Mandatory fields: entityType, documentCategoryId

Optional fields: documentTagIds, orderPosition, active

documentTagIds may be empty; a category configured before its tags are known is a legitimate state, and
being able to express it is why the mapping is two tables rather than one triple.

One category may be offered to one entity type once; a second attempt is a 403.

## Request body (application/json)
- `documentCategoryId` (integer, required)
- `entityType` (string, required)
- `active` (boolean)
- `documentTagIds` (array)
- `orderPosition` (integer)

## Responses
- `200`: OK

## Response fields
- `resourceId` (integer)

## Example request (cURL)
```bash
curl -X POST \
  'https://default.lokta.tech/lokta-lms/api/v1/documentcategories' \
  -u '{username}:{password}' \
  -H 'Tenant-Identifier: default' \
  -H 'Content-Type: application/json' \
  -d '{
  "documentCategoryId": 1,
  "entityType": "string",
  "active": true,
  "documentTagIds": [
    1
  ],
  "orderPosition": 1
}'
```

## Example response
```json
{
  "resourceId": 1
}
```

Interactive: https://developer.lokta.ai/reference#operation/create
