---
title: "Approve Agent Authorization"
method: POST
path: "/v1/agent-auth/token/{token}/approve"
tags: ["Agent Auth"]
---

# Approve Agent Authorization

`POST /v1/agent-auth/token/{token}/approve`

Called by the frontend after the user signs in.

Verifies the identity token, creates or looks up the user's API key,
and stores it against the token for the agent to poll via `GET /v1/agent-auth/token/{token}`.

**This endpoint is called by the browser, not by agents directly.**

## Path parameters

- `token` string, required

## Request body

- object
  - `id_token` string, required — Identity token obtained after the user signs in on the approval page
  - `client_name` string — Name of the agent/application (stored in customer metadata for audit)

## Response `200`

Authorization approved. The API key is now available for the agent to poll.

- object
  - `status` string
  - `email` string

## Other responses

- `400` — Invalid token length or invalid request
- `401` — Invalid or expired identity token
- `403` — Unsupported sign-in method
- `409` — Token was already approved (only the first approval is accepted)

---

[API](https://skmtc.net/casparser/apis/cas-parser-track-portfolios-from-cdsl-nsdl-cams-kfintech-2.md) · [All operations](https://skmtc.net/casparser/apis/cas-parser-track-portfolios-from-cdsl-nsdl-cams-kfintech-2/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/casparser/cas-parser-track-portfolios-from-cdsl-nsdl-cams-kfintech-2/revisions/c9918aebb2de/schema)
