> ## Documentation Index
> Fetch the complete documentation index at: https://docs.aiveth.com/llms.txt
> Use this file to discover all available pages before exploring further.

# API introduction

> The public APIs Aiveth offers, their base address and how they are versioned.

Aiveth by Gooclaim has two kinds of public API:

* **Standard protocol endpoints** that your apps call while signing people in: OpenID Connect, OAuth 2.0 and Shared Signals. Any standard library can use them.
* **Server APIs** that your own servers call with an [API key](https://docs.aiveth.com/api-reference/authentication.md): the admin API, the consent API and the events API.

## Base address

All examples use:

```text theme={null}
https://accounts.aiveth.com
```

This address is also the `iss` (issuer) of the tokens Aiveth signs. If your organization uses a [custom domain](https://docs.aiveth.com/brand/custom-domains.md), people who sign in there get tokens with that domain as the issuer, and the discovery document there names its own endpoints.

## Versioning

* **Server APIs** are under `/v1`. A breaking change would come under a new version prefix.
* **Protocol endpoints** follow their specifications and are not versioned: `/oauth/...`, `/.well-known/...` and `/ssf/...`. Read their addresses from the discovery documents instead of hard-coding them.

## OpenID Connect and OAuth 2.0

For signing people in to your apps. No API key; apps authenticate with their client ID and, for server apps, their secret.

| Method | Path | Purpose |
| - | - | - |
| GET | `/.well-known/openid-configuration` | Discovery document |
| GET | `/oauth/authorize` | Start a sign-in |
| POST | `/oauth/token` | Get tokens |
| GET | `/oauth/userinfo` | Who an access token stands for |
| POST | `/oauth/revoke` | End a token |
| GET, POST | `/oauth/logout` | Sign the person out |
| POST | `/oauth/device_authorization` | Start device login |
| POST | `/oauth/introspect` | Check an AI agent token |
| GET | `/v1/auth/.well-known/jwks.json` | Aiveth's public signing keys |

See [OpenID Connect endpoints](https://docs.aiveth.com/api-reference/oidc-endpoints.md) for parameters and answers.

## Admin API

For your server to manage your organization's people. Send an API key with the powers each call needs.

| Method | Path | Power |
| - | - | - |
| GET | `/v1/admin/people` (`?email=` to find one) | `people:read` |
| GET | `/v1/admin/people/{id}` | `people:read` |
| PUT | `/v1/admin/people/{id}/role` | `people:roles` |
| PUT | `/v1/admin/people/{id}/status` | `people:manage` |
| DELETE | `/v1/admin/people/{id}/sessions` | `people:manage` |
| GET, POST | `/v1/admin/invitations` | `people:manage` |
| DELETE | `/v1/admin/invitations/{id}` | `people:manage` |
| GET | `/v1/admin/roles` | `roles:read` |
| GET, PUT | `/v1/admin/people/{id}/fields` | `people:manage` |
| GET, PUT | `/v1/admin/organization/fields` | `organization:fields` |
| POST | `/v1/admin/people/import` | `people:manage` |
| POST | `/v1/admin/people/import/reset-emails` | `people:manage` |
| `/v1/admin/authorization/...` | Fine-grained authorization: check, parts and roles on parts | `authorization:read`, `authorization:write`, `resources:write` |
| GET | `/v1/admin/erasures` | `erasure:write` |
| POST | `/v1/admin/erasures/{id}/done` | `erasure:write` |
| POST | `/v1/admin/agent-actions` | `agents:actions` |

The rules are the console's own. Every change is in the organization's activity log as done by the key, for example `API key "HR sync"`. Lists return everyone at once; there is no paging.

Related guides: [Import users](https://docs.aiveth.com/access/import-users.md), [Custom fields](https://docs.aiveth.com/access/custom-fields.md), [Fine-grained authorization](https://docs.aiveth.com/access/fine-grained-authorization.md), [Erasure](https://docs.aiveth.com/privacy/erasure.md).

## Consent API

For an app that asks for consent on its own screen instead of Aiveth's. Under India's DPDP Act, your server records the answer, checks it before using the data, and withdraws it.

| Method | Path | Power |
| - | - | - |
| POST | `/v1/admin/consents` | `consent:write` |
| POST | `/v1/admin/consents/import` | `consent:write` |
| GET | `/v1/admin/consents/check?person_id=&purpose=` | `consent:read` |
| GET | `/v1/admin/consents/{person_id}` | `consent:read` |
| GET | `/v1/admin/consents/{person_id}/receipt` | `consent:read` |
| DELETE | `/v1/admin/consents/{person_id}/{purpose}` | `consent:write` |

Recording the same answer again changes nothing, so a retry is safe. See [Consent](https://docs.aiveth.com/privacy/consent.md).

## Events API

Read your organization's events back, oldest first.

```bash theme={null}
curl "https://accounts.aiveth.com/v1/events?types=user.created,user.updated&limit=10" \
  -H "Authorization: Bearer aiveth_sk_live_..."
```

| Parameter | Meaning |
| - | - |
| `types` | Comma-separated event types. Leave out for all. |
| `after` | Continue after this event ID. |
| `range_start` | Start at this time (ISO 8601). Can't be used with `after`. |
| `limit` | 1 to 100. Default 10. |

```json theme={null}
{
  "object": "list",
  "data": [
    {
      "object": "event",
      "id": "...",
      "type": "user.created",
      "timestamp": "...",
      "organization_id": "...",
      "data": {}
    }
  ],
  "list_metadata": { "after": "..." }
}
```

Page on by passing `list_metadata.after` as `after`. Events are kept for 30 days. The key needs `events:read`. Each event has the same shape as a [webhook](https://docs.aiveth.com/events/webhooks.md); see [Event types](https://docs.aiveth.com/events/event-types.md).

## Shared Signals

Aiveth is a Shared Signals (OpenID SSF 1.0) transmitter. Your security tools create a stream and receive signed security events.

| Method | Path |
| - | - |
| GET | `/.well-known/ssf-configuration` (public) |
| POST, GET, PATCH, PUT, DELETE | `/ssf/streams` |
| GET, POST | `/ssf/status` |
| POST | `/ssf/verify` |

The stream endpoints need an API key with `signals:manage`. See [Security signals](https://docs.aiveth.com/events/security-signals.md).

## Aiveth's MCP server

Your organization can turn on an MCP server so AI assistants can work in Aiveth for a signed-in admin, with approval for every change. See [MCP server](https://docs.aiveth.com/agents/mcp-server.md).

## SDKs

The [Node](https://docs.aiveth.com/sdks/node.md), [Python](https://docs.aiveth.com/sdks/python.md) and [React](https://docs.aiveth.com/sdks/react.md) SDKs wrap these APIs and verify tokens and webhooks for you.

## Related

* [Authentication](https://docs.aiveth.com/api-reference/authentication.md)
* [Errors and limits](https://docs.aiveth.com/api-reference/errors-and-limits.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.