---
title: "Create New Authentication Settings"
method: POST
path: "/auth/"
---

# Create New Authentication Settings

`POST /auth/`

## Request

- Base URL: `https://client.apimetrics.io/api/2`
- URL: `https://client.apimetrics.io/api/2/auth/`
- Auth: API key in header `Authorization`
- TypeScript: <https://skmtc.dev/apicontext/apis/api-settings/docs/auth/post.ts> (a function with typed inputs; its response is checked against the schema)

Use this API to create a new Authentication Setting.

## Request body

- object
  - `meta` object
    - `name` string, required: Name for the Authentication Setting
    - `domain` string, required: The domain name for the endpoints expected to use this authentication setting. This is not enforced, it is purely informational.
  - `settings` object
    - `auth_type` string, required: The type of authentication this auth setting uses, for example OAUTH2, MANUAL. See all options available [here](https://docs.apimetrics.io/reference/auth-object#section-settings).
    - `custom_variables` string, json: Object containing runtime variables

## Response `200`

200

- object
  - `keys` object
    - `client_secret` unknown
    - `client_id` unknown
  - `meta` object
    - `domain` string
    - `description` unknown
    - `created` string
    - `documentation` object
      - `keys` unknown
      - `docs` unknown
      - `apps` unknown
      - `provider` unknown
    - `last_update` string
    - `owner` string
    - `tags` unknown[]
      - unknown
    - `name` string
  - `id` string
  - `settings` object
    - `auth_type` string
    - `custom_variables` object

## Other responses

- `400`: 400

---

[API](https://skmtc.dev/apicontext/apis/api-settings.md) - [All operations](https://skmtc.dev/apicontext/apis/api-settings/llms.txt) - [OpenAPI document](https://skmtc.dev/apicontext/apis/api-settings/revisions/2e9a62324e82?raw)
