---
title: "Start a device-authorization login"
method: POST
path: "/auth/oauth/device/start"
tags: ["auth", "oauth"]
---

# Start a device-authorization login

`POST /auth/oauth/device/start`

## Request

- Base URL: `https://api.namefi.io/v-next`
- URL: `https://api.namefi.io/v-next/auth/oauth/device/start`
- Auth: one of:
  - API key in header `x-api-key`
  - HTTP bearer

Begin a device-authorization login: creates a pending request and returns a browser confirmation URL plus a token to poll for the result.

## Headers

- `x-namefi-eip7702-account` string
- `x-namefi-eip1271-account` string
- `x-namefi-erc1271-account` string

## Request body

- object: Input used to begin a device-authorization login.
  - `client` object: Optional metadata about the client requesting access.
    - `name` string: Human-readable name of the client requesting access.
    - `version` string: Version of the client requesting access.
    - `platform` string: Operating system / platform the client is running on.
  - `clientId` string: Identifier of the requesting client. Known ids render as a verified client on the confirm page; unknown ids are allowed but shown as unverified.
  - `variant` 'headless': Device-authorization variant. Reserved for future flows (e.g. a typed user_code); currently only the headless capability-URL variant is supported.
  - `codeChallenge` string, required: PKCE S256 code challenge: BASE64URL(SHA256(codeVerifier)).
  - `codeChallengeMethod` 'S256', required: PKCE challenge method; only S256 is supported.

## Response `200`

OK

- object: Details required to drive a device-authorization login.
  - `authReqToken` string, uuid, required: Opaque handle for this login request; used to poll status.
  - `confirmUrl` string, uri, required: Browser URL where the user approves or cancels the request.
  - `expiresAt` string, date-time, required: ISO timestamp after which the request can no longer be used.
  - `pollIntervalMs` integer, required: Suggested delay between consecutive status calls.

## Other responses

- `400`: 400
- `401`: 401
- `402`: 402
- `403`: 403
- `404`: 404
- `406`: 406
- `408`: 408
- `409`: 409
- `412`: 412
- `429`: 429
- `500`: 500

---

[API](https://skmtc.dev/namefi/apis/namefi-api.md) · [All operations](https://skmtc.dev/namefi/apis/namefi-api/llms.txt) · [OpenAPI document](https://skmtc.dev/namefi/apis/namefi-api/revisions/3c7c3ade95c9?raw)
