Passer au contenu principal
POST
/
branding
/
phone
/
providers
TypeScript
import { ManagementClient } from "auth0";

async function main() {
    const client = new ManagementClient({
        token: "<token>",
    });
    await client.branding.phone.providers.create({
        name: "twilio",
        credentials: {
            authToken: "auth_token",
        },
    });
}
main();
{
  "name": "twilio",
  "id": "<string>",
  "tenant": "<string>",
  "channel": "phone",
  "disabled": true,
  "configuration": {
    "sid": "<string>",
    "delivery_methods": [
      "text"
    ],
    "default_from": "<string>",
    "mssid": "<string>"
  },
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z"
}

Autorisations

Authorization
string
header
requis

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Corps

Phone provider configuration schema

name
enum<string>
requis

Name of the phone notification provider

Options disponibles:
twilio,
custom
Required string length: 1 - 100
credentials
object
requis

Provider credentials required to use authenticate to the provider.

disabled
boolean

Whether the provider is enabled (false) or disabled (true).

configuration
object

Réponse

Phone notification provider successfully created.

Phone provider configuration schema

name
enum<string>
requis

Name of the phone notification provider

Options disponibles:
twilio,
custom
Required string length: 1 - 100
id
string
Required string length: 1 - 255
tenant
string

The name of the tenant

Required string length: 1 - 255
channel
enum<string>

This depicts the type of notifications this provider can receive.

Options disponibles:
phone
Maximum string length: 100
disabled
boolean

Whether the provider is enabled (false) or disabled (true).

configuration
object
created_at
string<date-time>

The provider's creation date and time in ISO 8601 format

Maximum string length: 27
updated_at
string<date-time>

The date and time of the last update to the provider in ISO 8601 format

Maximum string length: 27