---
title: "Create a new license for a user"
method: POST
path: "/licenses"
tags: ["License"]
---

# Create a new license for a user

`POST /licenses`

This endpoint is used to create a new license for a user.

If a start date is provided, the license will be activated at the **start** of the specified date in the customer's timezone.
Otherwise, the activation time will default to the **start** of the current day in the customer's timezone.

## Request body

- NewLicense
  - `subscription_id` string, required
  - `license_type_id` string, required
  - `external_license_id` string, required — The external identifier for the license.
  - `start_date` string, date, nullable — The start date of the license. If not provided, defaults to start of day today in the customer's timezone.
  - `end_date` string, date, nullable — The end date of the license. If not provided, the license will remain active until deactivated.

## Response `201`

Created

- LicenseApiResource
  - `id` string, required
  - `subscription_id` string, required
  - `license_type_id` string, required
  - `external_license_id` string, required
  - `status` 'active' | 'inactive', required
  - `start_date` string, date-time, required
  - `end_date` string, date-time, nullable, required

## Other responses

- `400` — Bad Request
- `401` — Unauthorized
- `404` — Not Found
- `409` — Conflict
- `413` — Content Too Large
- `429` — Too Many Requests
- `500` — Internal Server Error

---

[API](https://skmtc.dev/withorb/apis/api-reference.md) · [All operations](https://skmtc.dev/withorb/apis/api-reference/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/withorb/api-reference/revisions/816dfe734e2e/schema)
