Rename an API token

Needs permission api-token:write.

A JSON Merge Patch: send name, allowedIpRanges, or both; leave one out to keep it. The client id, the secret and the organisations it reaches are untouched. 409 duplicate_token_name when another token in your account already has that name.

allowedIpRanges lists the address ranges the token may be used from: 1 to 20, IPv4 or IPv6, such as 203.0.113.0/24 or 2001:db8::/32, with no spaces or leading zeros. Each is stored as its network address. From anywhere else every API, this one included, answers 403 ip_not_allowed. 400 invalid_ip_range names a range we cannot use. Only a person changes or lifts an existing token's ranges: an API token is refused with 403 insufficient_permissions, missingPermission: api-token:write. An API token restricted to ranges issues or rotates only tokens within them (403 token_ranges_wider_than_yours); one it issues without ranges gets its own. null lets it be used from anywhere again. Changing it needs a person who manages API tokens: a token can never change its own or another token's ranges (403 insufficient_permissions, missingPermission: api-token:write).

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Path Params
string
required
Body Params

Changes a token's name, where it may be used from, or both. Leave a field out to keep it.

string | null

The new display name, unique within your account.

allowedIpRanges
array of strings | null

Address ranges the token may be used from, such as ["203.0.113.0/24", "2001:db8::/32"]: up to 20, IPv4 or
IPv6. The list replaces the old one; null lets it be used from anywhere again.

allowedIpRanges
Headers
string
enum
Defaults to application/merge-patch+json

Generated from available request content types

Allowed:
Responses

Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json