---
title: "Whether the caller's external AI harness has connected."
method: GET
path: "/api-keys/ai-harness/status"
tags: ["API Keys"]
---

# Whether the caller's external AI harness has connected.

`GET /api-keys/ai-harness/status`

## Request

- Base URL: `/api` (relative, and the document was published on a file host, not at the API’s origin)
- URL: `/api/api-keys/ai-harness/status`
- Auth: HTTP bearer

Backs the console's "Let your AI operate Temps" onboarding and its
app-wide "finish connecting" banner. `connected` when the dedicated
`Temps AI harness` key has authenticated a request, or when a key minted
by a browser-approved `temps login` after it has: the CLI falls back to
that flow when it is not handed a usable key, so the harness works
without ever sending the dedicated key.

## Response `200`

AI harness connection status for the caller

- AiHarnessStatusResponse: `GET /api-keys/ai-harness/status`: the caller's AI harness connection.
  - `connected_via` AiHarnessCredential, nullable: The credential that authenticated the harness. Never carries the secret, only the identifiers the API-key list already shows.
    - `id` integer, required
    - `key_prefix` string, required
    - `kind` 'dedicated_key' | 'cli_login', required: Which credential proved the harness connected.
    - `last_used_at` string, date-time, required
    - `name` string, required
  - `key_created_at` string, date-time, nullable
  - `key_id` integer, nullable: The dedicated harness key, when one exists (active or not).
  - `reason` string, nullable: Why the status is not `connected`, in words the console can show.
  - `setup_path` string, nullable: Console route that resolves `reason`.
  - `status` 'missing' | 'waiting' | 'connected', required: Where the harness onboarding stands for the calling user.

## Other responses

- `401`: Unauthorized
- `403`: Forbidden
- `500`: Internal server error

## Changes

- **2026-11-19** `2d794de171fa`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/gotempsh/apis/temps/changes/api-keys/ai-harness/status/get.md)

---

[API](https://skmtc.dev/gotempsh/apis/temps.md) - [All operations](https://skmtc.dev/gotempsh/apis/temps/llms.txt) - [OpenAPI document](https://skmtc.dev/gotempsh/apis/temps/revisions/3b040526eb43?raw)
