---
title: "What identity you can hold here, and who you are holding"
method: POST
path: "/agent/identity"
tags: ["Discovery"]
---

# What identity you can hold here, and who you are holding

`POST /agent/identity`

## Request

- Base URL: `https://youspot.com`
- URL: `https://youspot.com/agent/identity`
- Auth: none required

`{"type":"anonymous"}` lists the surfaces that need no credential. `{"type":"service_auth"}` with a bearer names the member whose access it is. Any other type is a 400 naming the two that work.

## Request body

- object
  - `type` 'anonymous' | 'service_auth': Defaults to anonymous.

## Response `200`

The identity, and what it can reach.

- AgentIdentity
  - `identity_type` 'anonymous' | 'service_auth', required
  - `authenticated` boolean, required
  - `endpoints` object, required: What this identity can reach, by name.
  - `skill` string, uri: The walkthrough for getting a credential.
  - `username` string: Present with `service_auth`: whose access the bearer is.

## Other responses

- `400`: The request was refused. `error` is stable; read `error_description` for the reason.
- `401`: The request was refused. `error` is stable; read `error_description` for the reason.

---

[API](https://skmtc.dev/youspot/apis/youspot-http-api.md) · [All operations](https://skmtc.dev/youspot/apis/youspot-http-api/llms.txt) · [OpenAPI document](https://skmtc.dev/youspot/apis/youspot-http-api/revisions/6615ad5d017d?raw)
