---
title: "Initiate device auth"
method: POST
path: "/api/v1/auth/device/code"
tags: ["Device Authentication"]
---

# Initiate device auth

`POST /api/v1/auth/device/code`

## Request

- Base URL: `http://localhost:8080`
- URL: `http://localhost:8080/api/v1/auth/device/code`
- Auth: HTTP bearer

Generates a device code and user code for CLI login. The user code should be displayed to the user to enter in the browser.

## Response `200`

Device code generated

---

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