---
title: "Rotate the API key (session-only)"
method: POST
path: "/api/v1/visa/auth/regenerate-key"
tags: ["Account & billing"]
---

# Rotate the API key (session-only)

`POST /api/v1/visa/auth/regenerate-key`

## Request

- Base URL: `https://visa.orizn.app`
- URL: `https://visa.orizn.app/api/v1/visa/auth/regenerate-key`
- Auth: API key in cookie `orizn_token`
- TypeScript: <https://skmtc.dev/orizn/apis/orizn-visa-api/docs/api/v1/visa/auth/regenerate-key/post.ts> (a function with typed inputs; its response is checked against the schema)

## Response `200`

Key rotated.

- object
  - `api_key` string
  - `message` string

## Other responses

- `400`: Missing or malformed parameter.
- `401`: Missing API key, query param or session cookie.
- `404`: No data for the requested resource.

---

[API](https://skmtc.dev/orizn/apis/orizn-visa-api.md) - [All operations](https://skmtc.dev/orizn/apis/orizn-visa-api/llms.txt) - [OpenAPI document](https://skmtc.dev/orizn/apis/orizn-visa-api/revisions/7d2f2bc68d08?raw)
