---
title: "Create a new AuthProfile resource"
method: POST
path: "/v1/Webhooks/AuthProfiles"
tags: ["AuthProfiles"]
---

# Create a new AuthProfile resource

`POST /v1/Webhooks/AuthProfiles`

## Request

- Base URL: `https://webhooks.twilio.com`
- URL: `https://webhooks.twilio.com/v1/Webhooks/AuthProfiles`
- Auth: HTTP basic

Creates a new reusable AuthProfile resource for use across multiple Settings.

## Headers

- `Idempotency-Key` string, uuid

## Request body

- union: Request body for creating a new AuthProfile resource
  - PostOAuth2AuthProfile: OAuth2 client credentials authentication
    - `type` 'OAUTH2', required: Authentication type
    - `friendlyName` string, nullable: Human-readable name for identification (optional, defaults to blank)
    - `tokenUrl` string, uri, required: OAuth2 token endpoint URL
    - `clientId` string, required: OAuth2 client identifier
    - `clientSecret` string, required: OAuth2 client secret (never returned, stored securely as secret)
    - `scope` string: OAuth2 scope to request
    - `audience` string: OAuth2 audience parameter
    - `clientCredentialsAuthMethod` 'CLIENT_SECRET_POST' | 'CLIENT_SECRET_BASIC': Client credentials authentication method (defaults to CLIENT_SECRET_POST)
  - PostBasicAuthProfile: HTTP Basic authentication
    - `type` 'BASIC', required: Authentication type
    - `friendlyName` string, nullable: Human-readable name for identification (optional, defaults to blank)
    - `username` string, required: Basic auth username
    - `password` string, required: Basic auth password (never returned, stored securely as secret)
  - PostDigestAuthProfile: HTTP Digest authentication
    - `type` 'DIGEST', required: Authentication type
    - `friendlyName` string, nullable: Human-readable name for identification (optional, defaults to blank)
    - `username` string, required: Digest auth username
    - `password` string, required: Digest auth password (never returned, stored securely as secret)

## Response `201`

AuthProfile created

- union: Authentication resource that can be shared across various settings
  - object: OAuth2 client credentials authentication
    - `id` string, required: Unique AuthProfile identifier (TypeID/TTID format)
    - `type` 'OAUTH2', required: Authentication type
    - `friendlyName` string, required: Human-readable name for identification
    - `createdAt` string, date-time, required
    - `updatedAt` string, date-time, required
    - `tokenUrl` string, uri, required: OAuth2 token endpoint URL
    - `clientId` string, required: OAuth2 client identifier
    - `clientSecret` string: OAuth2 client secret (never returned, stored securely as secret)
    - `scope` string: OAuth2 scope to request
    - `audience` string, nullable: OAuth2 audience parameter
    - `clientCredentialsAuthMethod` 'CLIENT_SECRET_POST' | 'CLIENT_SECRET_BASIC': Client credentials authentication method (defaults to CLIENT_SECRET_POST)
  - object: HTTP Basic authentication
    - `id` string, required: Unique AuthProfile identifier (TypeID/TTID format)
    - `type` 'BASIC', required: Authentication type
    - `friendlyName` string, required: Human-readable name for identification
    - `createdAt` string, date-time, required
    - `updatedAt` string, date-time, required
    - `username` string, required: Basic auth username
    - `password` string: Basic auth password (never returned, stored securely as secret)
  - object: HTTP Digest authentication
    - `id` string, required: Unique AuthProfile identifier (TypeID/TTID format)
    - `type` 'DIGEST', required: Authentication type
    - `friendlyName` string, required: Human-readable name for identification
    - `createdAt` string, date-time, required
    - `updatedAt` string, date-time, required
    - `username` string, required: Digest auth username
    - `password` string: Digest auth password (never returned, stored securely as secret)

## Other responses

- `400`: Validation error
- `401`: Authentication failed
- `403`: Authenticated account does not have permission to perform this operation
- `422`: Account has reached maximum Auth resources limit
- `429`: Rate limit exceeded
- `500`: An unexpected server error occurred

---

[API](https://skmtc.dev/twilio/apis/webhooks-v1.md) - [All operations](https://skmtc.dev/twilio/apis/webhooks-v1/llms.txt) - [OpenAPI document](https://skmtc.dev/twilio/apis/webhooks-v1/revisions/629b4cc3a029?raw)
