---
title: "Create Customer Token"
method: POST
path: "/api/customer/tokens"
tags: ["Customer"]
---

# Create Customer Token

`POST /api/customer/tokens`

## Request

- Base URL: `https://uptimeify.io`
- URL: `https://uptimeify.io/api/customer/tokens`
- Auth: HTTP bearer

POST /api/customer/tokens

## Request body

- object
  - `name` string, required
  - `expiresInDays` integer: Omit for a token that never expires.
  - `customerId` integer: Required when the login is assigned to more than one customer.

## Response `200`

Successful response

- object
  - `id` integer, required
  - `name` string, required
  - `lastUsedAt` string, date-time, nullable, required
  - `expiresAt` string, date-time, nullable, required
  - `createdAt` string, date-time, required
  - `token` string, required: The token itself. Shown once; store it now.

## Other responses

- `400`: Invalid or missing parameters.
- `401`: Missing, invalid or expired API token.
- `500`: Unexpected server error.

---

[API](https://skmtc.dev/uptimeify/apis/uptimeify-rest-api.md) · [All operations](https://skmtc.dev/uptimeify/apis/uptimeify-rest-api/llms.txt) · [OpenAPI document](https://skmtc.dev/uptimeify/apis/uptimeify-rest-api/revisions/2129a771ee7e?raw)
