---
title: "Update client credentials token"
method: PATCH
path: "/resources/tenants/api-tokens/v1/{id}"
tags: ["API (tenant) tokens"]
---

# Update client credentials token

`PATCH /resources/tenants/api-tokens/v1/{id}`

## Request

- Base URL: `http://localhost:8181`
- URL: `http://localhost:8181/resources/tenants/api-tokens/v1/{id}`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/frontegg/apis/entitlements-agent-pdp/docs/resources/tenants/api-tokens/v1/:id/patch.ts> (a function with typed inputs; its response is checked against the schema)

This route updates a tenant API token. Send the tenant’s ID in the **`frontegg-tenant-id`** header. Optionally, send as POST body params values for description, roles, and permissions for the token.

## Path parameters

- `id` string, required

## Headers

- `frontegg-tenant-id` string, required

## Request body

- UpdateApiTokenDto
  - `description` string
  - `roleIds` string[]: Array of role ids
  - `permissionIds` string[]: Array of permission ids

## Response `200`

- UpdateTenantApiTokenResponseDto
  - `clientId` string, required
  - `description` string, nullable, required
  - `tenantId` string, required
  - `createdByUserId` string, nullable, required
  - `metadata` object, required: Extra data that will be encoded as part of the JWT
  - `createdAt` string, date-time, required
  - `permissionIds` string[]: Array of permission ids
  - `roleIds` string[]: Array of role ids
  - `expires` string, date-time

---

[API](https://skmtc.dev/frontegg/apis/entitlements-agent-pdp.md) - [All operations](https://skmtc.dev/frontegg/apis/entitlements-agent-pdp/llms.txt) - [OpenAPI document](https://skmtc.dev/frontegg/apis/entitlements-agent-pdp/revisions/c496ae9e1c3e?raw)
