---
title: "Create an API auth session"
method: POST
path: "/v1/api/auth/sessions"
tags: ["auth"]
---

# Create an API auth session

`POST /v1/api/auth/sessions`

Creates a new browser-based auth session for CLI or other API clients. The returned verification URL should be opened in the user's browser to complete authentication.

## Request body

- object
  - `deviceName` string — Name of the device requesting access (e.g. user@MacBook-Pro.local)
  - `callbackUrl` string, uri — HTTPS callback URL to redirect the user to after approving the session

## Response `201`

Session created successfully

- object
  - `sessionId` string, required — Unique session identifier
  - `verificationUrl` string, required — URL to open in the browser to approve the session
  - `expiresAt` string, required — ISO 8601 timestamp when the session expires

## Other responses

- `500` — Internal server error

---

[API](https://skmtc.net/paragraph-xyz/apis/paragraph-api.md) · [All operations](https://skmtc.net/paragraph-xyz/apis/paragraph-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/paragraph-xyz/paragraph-api/versions/7bbf1b62c1a0/schema)
