---
title: "Register a Team website"
method: POST
path: "/oauth-applications"
tags: ["OAuth applications"]
---

# Register a Team website

`POST /oauth-applications`

## Request

- Base URL: `https://api.session.services`
- URL: `https://api.session.services/oauth-applications`
- Auth: API key in header `x-tenant-id`

Registers a website login client for a Team and returns its first credential once.

## Request body

- object: Registration request for a new Team website.
  - `teamId` string, required: Unique team identifier
  - `name` string, required: Operator-facing name for this website.
  - `redirectUris` string[], required: Exact HTTPS callback URLs. HTTP is allowed only for non-production loopback.
  - `requestId` string, uuid, required: Caller-generated idempotency key. Reusing it returns a conflict rather than a second application.

## Response `200`

OK

- object: One-time credential issuance response. Must not be logged or cached.
  - `application` object, required: A Team-owned website login application. Credential secrets are never included.
    - `clientId` string, required: Immutable OAuth client identifier.
    - `teamId` string, required: Unique team identifier
    - `tenantId` string, required: Tenant this application belongs to.
    - `name` string, required: Operator-facing name for this website.
    - `redirectUris` string[], required: Exact HTTPS callback URLs. HTTP is allowed only for non-production loopback.
    - `enabled` boolean, required: Disabled applications stop authenticating immediately.
    - `revision` integer, required: Optimistic concurrency token. Send the value you read.
    - `credentials` object[], required
      - `id` string, required: Opaque credential identifier. It reveals nothing about the secret.
      - `expiresAt` integer: Credential expiry as Unix milliseconds. Omitted for credentials that do not expire.
  - `clientSecret` string, required: New credential. Display once and store only on the website server.

## Other responses

- `400`: 400
- `401`: 401
- `403`: 403
- `404`: 404
- `409`: 409
- `412`: 412
- `422`: 422
- `429`: 429
- `500`: 500
- `501`: 501
- `503`: 503

## Changes

- **2026-11-09** `38649d1c1ac7`: 5 breaking, 2 warning, 1 info
  - the `redirectUris` request property's minItems was increased to `1`
  - the `name` request property's minLength was increased from `0` to `1`
  - added the pattern `^tem_[0-9a-z]{26}$` to the request property `teamId`
  - the `redirectUris/items/` request property format changed from no format to `uri`
  - …4 more
- **2026-11-09** `24b4e38e7054`: 9 breaking, 5 info
  - the `application/name` response property's maxLength was unset from `100` for the response status `200`
  - the `application/redirectUris/items/` response property's maxLength was unset from `2048` for the response status `200`
  - the `application/redirectUris` response property's minItems was decreased from `1` to `0` for the response status `200`
  - the `application/clientId` response property's minLength was decreased from `1` to `0` for the response status `200`
  - …10 more
- **2026-09-21** `2b2f16550f6d`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/session/apis/session-services-api/changes/oauth-applications/post.md)

---

[API](https://skmtc.dev/session/apis/session-services-api.md) - [All operations](https://skmtc.dev/session/apis/session-services-api/llms.txt) - [OpenAPI document](https://skmtc.dev/session/apis/session-services-api/revisions/9346dc3eea56?raw)
