docs/media/reference.md
Retrieve all actions.
</dd> </dl> </dd> </dl>const pageableResponse = await client.actions.list({
triggerId: "post-login",
actionName: "actionName",
deployed: true,
page: 1,
per_page: 1,
installed: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.actions.list({
triggerId: "post-login",
actionName: "actionName",
deployed: true,
page: 1,
per_page: 1,
installed: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListActionsRequestParameters
requestOptions: ActionsClient.RequestOptions
Create an action. Once an action is created, it must be deployed, and then bound to a trigger before it will be executed as part of a flow.
</dd> </dl> </dd> </dl>await client.actions.create({
name: "name",
supported_triggers: [
{
id: "post-login",
},
],
});
request: Management.CreateActionRequestContent
requestOptions: ActionsClient.RequestOptions
Retrieve an action by its ID.
</dd> </dl> </dd> </dl>await client.actions.get("id");
id: string — The ID of the action to retrieve.
requestOptions: ActionsClient.RequestOptions
Deletes an action and all of its associated versions. An action must be unbound from all triggers before it can be deleted.
</dd> </dl> </dd> </dl>await client.actions.delete("id", {
force: true,
});
id: string — The ID of the action to delete.
request: Management.DeleteActionRequestParameters
requestOptions: ActionsClient.RequestOptions
Update an existing action. If this action is currently bound to a trigger, updating it will <strong>not</strong> affect any user flows until the action is deployed.
</dd> </dl> </dd> </dl>await client.actions.update("id");
id: string — The id of the action to update.
request: Management.UpdateActionRequestContent
requestOptions: ActionsClient.RequestOptions
Deploy an action. Deploying an action will create a new immutable version of the action. If the action is currently bound to a trigger, then the system will begin executing the newly deployed version of the action immediately. Otherwise, the action will only be executed as a part of a flow once it is bound to that flow.
</dd> </dl> </dd> </dl>await client.actions.deploy("id");
id: string — The ID of an action.
requestOptions: ActionsClient.RequestOptions
Test an action. After updating an action, it can be tested prior to being deployed to ensure it behaves as expected.
</dd> </dl> </dd> </dl>await client.actions.test("id", {
payload: {
key: "value",
},
});
id: string — The id of the action to test.
request: Management.TestActionRequestContent
requestOptions: ActionsClient.RequestOptions
Retrieve branding settings.
</dd> </dl> </dd> </dl>await client.branding.get();
requestOptions: BrandingClient.RequestOptions
Update branding settings.
</dd> </dl> </dd> </dl>await client.branding.update();
request: Management.UpdateBrandingRequestContent
requestOptions: BrandingClient.RequestOptions
Retrieve a list of <a href="https://auth0.com/docs/get-started/applications/application-access-to-apis-client-grants">client grants</a>, including the scopes associated with the application/API pair.
</dd> </dl> </dd> </dl>const pageableResponse = await client.clientGrants.list({
from: "from",
take: 1,
audience: "audience",
client_id: "client_id",
allow_any_organization: true,
subject_type: "client",
default_for: "third_party_clients",
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.clientGrants.list({
from: "from",
take: 1,
audience: "audience",
client_id: "client_id",
allow_any_organization: true,
subject_type: "client",
default_for: "third_party_clients",
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListClientGrantsRequestParameters
requestOptions: ClientGrantsClient.RequestOptions
Create a client grant for a machine-to-machine login flow. To learn more, read <a href="https://www.auth0.com/docs/get-started/authentication-and-authorization-flow/client-credentials-flow">Client Credential Flow</a>.
</dd> </dl> </dd> </dl>await client.clientGrants.create({
audience: "audience",
});
request: Management.CreateClientGrantRequestContent
requestOptions: ClientGrantsClient.RequestOptions
Retrieve a single <a href="https://auth0.com/docs/get-started/applications/application-access-to-apis-client-grants">client grant</a>, including the scopes associated with the application/API pair.
</dd> </dl> </dd> </dl>await client.clientGrants.get("id");
id: string — The ID of the client grant to retrieve.
requestOptions: ClientGrantsClient.RequestOptions
Delete the <a href="https://www.auth0.com/docs/get-started/authentication-and-authorization-flow/client-credentials-flow">Client Credential Flow</a> from your machine-to-machine application.
</dd> </dl> </dd> </dl>await client.clientGrants.delete("id");
id: string — ID of the client grant to delete.
requestOptions: ClientGrantsClient.RequestOptions
Update a client grant.
</dd> </dl> </dd> </dl>await client.clientGrants.update("id");
id: string — ID of the client grant to update.
request: Management.UpdateClientGrantRequestContent
requestOptions: ClientGrantsClient.RequestOptions
Retrieve clients (applications and SSO integrations) matching provided filters. A list of fields to include or exclude may also be specified. For more information, read <a href="https://www.auth0.com/docs/get-started/applications"> Applications in Auth0</a> and <a href="https://www.auth0.com/docs/authenticate/single-sign-on"> Single Sign-On</a>.
<ul> <li> The following can be retrieved with any scope: <code>client_id</code>, <code>app_type</code>, <code>name</code>, and <code>description</code>. </li> <li> The following properties can only be retrieved with the <code>read:clients</code> or <code>read:client_keys</code> scope: <code>callbacks</code>, <code>oidc_logout</code>, <code>allowed_origins</code>, <code>web_origins</code>, <code>tenant</code>, <code>global</code>, <code>config_route</code>, <code>callback_url_template</code>, <code>jwt_configuration</code>, <code>jwt_configuration.lifetime_in_seconds</code>, <code>jwt_configuration.secret_encoded</code>, <code>jwt_configuration.scopes</code>, <code>jwt_configuration.alg</code>, <code>api_type</code>, <code>logo_uri</code>, <code>allowed_clients</code>, <code>owners</code>, <code>custom_login_page</code>, <code>custom_login_page_off</code>, <code>sso</code>, <code>addons</code>, <code>form_template</code>, <code>custom_login_page_codeview</code>, <code>resource_servers</code>, <code>client_metadata</code>, <code>mobile</code>, <code>mobile.android</code>, <code>mobile.ios</code>, <code>allowed_logout_urls</code>, <code>token_endpoint_auth_method</code>, <code>is_first_party</code>, <code>oidc_conformant</code>, <code>is_token_endpoint_ip_header_trusted</code>, <code>initiate_login_uri</code>, <code>grant_types</code>, <code>refresh_token</code>, <code>refresh_token.rotation_type</code>, <code>refresh_token.expiration_type</code>, <code>refresh_token.leeway</code>, <code>refresh_token.token_lifetime</code>, <code>refresh_token.policies</code>, <code>organization_usage</code>, <code>organization_require_behavior</code>. </li> <li> The following properties can only be retrieved with the <code>read:client_keys</code> or <code>read:client_credentials</code> scope: <code>encryption_key</code>, <code>encryption_key.pub</code>, <code>encryption_key.cert</code>, <code>client_secret</code>, <code>client_authentication_methods</code> and <code>signing_key</code>. </li> </ul> </dd> </dl> </dd> </dl>const pageableResponse = await client.clients.list({
fields: "fields",
include_fields: true,
page: 1,
per_page: 1,
include_totals: true,
is_global: true,
is_first_party: true,
app_type: "app_type",
external_client_id: "external_client_id",
q: "q",
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.clients.list({
fields: "fields",
include_fields: true,
page: 1,
per_page: 1,
include_totals: true,
is_global: true,
is_first_party: true,
app_type: "app_type",
external_client_id: "external_client_id",
q: "q",
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListClientsRequestParameters
requestOptions: ClientsClient.RequestOptions
Create a new client (application or SSO integration). For more information, read <a href="https://www.auth0.com/docs/get-started/auth0-overview/create-applications">Create Applications</a> <a href="https://www.auth0.com/docs/authenticate/single-sign-on/api-endpoints-for-single-sign-on>">API Endpoints for Single Sign-On</a>.
Notes:
client_secret parameter unspecified to allow the generation of a safe secret.await client.clients.create({
name: "name",
});
request: Management.CreateClientRequestContent
requestOptions: ClientsClient.RequestOptions
Fetches and validates a Client ID Metadata Document without creating a client.
Returns the raw metadata and how it would be mapped to Auth0 client fields.
This endpoint is useful for testing metadata URIs before creating CIMD clients.
await client.clients.previewCimdMetadata({
external_client_id: "external_client_id",
});
request: Management.PreviewCimdMetadataRequestContent
requestOptions: ClientsClient.RequestOptions
Idempotent registration for Client ID Metadata Document (CIMD) clients.
Uses external_client_id as the unique identifier for upsert operations.
**Create:** Returns 201 when a new client is created (requires \
await client.clients.registerCimdClient({
external_client_id: "external_client_id",
});
request: Management.RegisterCimdClientRequestContent
requestOptions: ClientsClient.RequestOptions
Retrieve client details by ID. Clients are SSO connections or Applications linked with your Auth0 tenant. A list of fields to include or exclude may also be specified. For more information, read <a href="https://www.auth0.com/docs/get-started/applications"> Applications in Auth0</a> and <a href="https://www.auth0.com/docs/authenticate/single-sign-on"> Single Sign-On</a>.
<ul> <li> The following properties can be retrieved with any of the scopes: <code>client_id</code>, <code>app_type</code>, <code>name</code>, and <code>description</code>. </li> <li> The following properties can only be retrieved with the <code>read:clients</code> or <code>read:client_keys</code> scopes: <code>callbacks</code>, <code>oidc_logout</code>, <code>allowed_origins</code>, <code>web_origins</code>, <code>tenant</code>, <code>global</code>, <code>config_route</code>, <code>callback_url_template</code>, <code>jwt_configuration</code>, <code>jwt_configuration.lifetime_in_seconds</code>, <code>jwt_configuration.secret_encoded</code>, <code>jwt_configuration.scopes</code>, <code>jwt_configuration.alg</code>, <code>api_type</code>, <code>logo_uri</code>, <code>allowed_clients</code>, <code>owners</code>, <code>custom_login_page</code>, <code>custom_login_page_off</code>, <code>sso</code>, <code>addons</code>, <code>form_template</code>, <code>custom_login_page_codeview</code>, <code>resource_servers</code>, <code>client_metadata</code>, <code>mobile</code>, <code>mobile.android</code>, <code>mobile.ios</code>, <code>allowed_logout_urls</code>, <code>token_endpoint_auth_method</code>, <code>is_first_party</code>, <code>oidc_conformant</code>, <code>is_token_endpoint_ip_header_trusted</code>, <code>initiate_login_uri</code>, <code>grant_types</code>, <code>refresh_token</code>, <code>refresh_token.rotation_type</code>, <code>refresh_token.expiration_type</code>, <code>refresh_token.leeway</code>, <code>refresh_token.token_lifetime</code>, <code>refresh_token.policies</code>, <code>organization_usage</code>, <code>organization_require_behavior</code>. </li> <li> The following properties can only be retrieved with the <code>read:client_keys</code> or <code>read:client_credentials</code> scopes: <code>encryption_key</code>, <code>encryption_key.pub</code>, <code>encryption_key.cert</code>, <code>client_secret</code>, <code>client_authentication_methods</code> and <code>signing_key</code>. </li> </ul> </dd> </dl> </dd> </dl>await client.clients.get("id", {
fields: "fields",
include_fields: true,
});
id: string — ID of the client to retrieve.
request: Management.GetClientRequestParameters
requestOptions: ClientsClient.RequestOptions
Delete a client and related configuration (rules, connections, etc).
</dd> </dl> </dd> </dl>await client.clients.delete("id");
id: string — ID of the client to delete.
requestOptions: ClientsClient.RequestOptions
Updates a client's settings. For more information, read <a href="https://www.auth0.com/docs/get-started/applications"> Applications in Auth0</a> and <a href="https://www.auth0.com/docs/authenticate/single-sign-on"> Single Sign-On</a>.
Notes:
client_secret and signing_key attributes can only be updated with the update:client_keys scope.await client.clients.update("id");
id: string — ID of the client to update.
request: Management.UpdateClientRequestContent
requestOptions: ClientsClient.RequestOptions
Rotate a client secret.
This endpoint cannot be used with clients configured with Private Key JWT authentication method (client_authentication_methods configured with private_key_jwt). The generated secret is NOT base64 encoded.
For more information, read <a href="https://www.auth0.com/docs/get-started/applications/rotate-client-secret">Rotate Client Secrets</a>.
</dd> </dl> </dd> </dl>await client.clients.rotateSecret("id");
id: string — ID of the client that will rotate secrets.
requestOptions: ClientsClient.RequestOptions
Retrieve a list of Connection Profiles. This endpoint supports Checkpoint pagination.
</dd> </dl> </dd> </dl>const pageableResponse = await client.connectionProfiles.list({
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.connectionProfiles.list({
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListConnectionProfileRequestParameters
requestOptions: ConnectionProfilesClient.RequestOptions
Create a Connection Profile.
</dd> </dl> </dd> </dl>await client.connectionProfiles.create({
name: "name",
});
request: Management.CreateConnectionProfileRequestContent
requestOptions: ConnectionProfilesClient.RequestOptions
Retrieve a list of Connection Profile Templates.
</dd> </dl> </dd> </dl>await client.connectionProfiles.listTemplates();
requestOptions: ConnectionProfilesClient.RequestOptions
Retrieve a Connection Profile Template.
</dd> </dl> </dd> </dl>await client.connectionProfiles.getTemplate("id");
id: string — ID of the connection-profile-template to retrieve.
requestOptions: ConnectionProfilesClient.RequestOptions
Retrieve details about a single Connection Profile specified by ID.
</dd> </dl> </dd> </dl>await client.connectionProfiles.get("id");
id: string — ID of the connection-profile to retrieve.
requestOptions: ConnectionProfilesClient.RequestOptions
Delete a single Connection Profile specified by ID.
</dd> </dl> </dd> </dl>await client.connectionProfiles.delete("id");
id: string — ID of the connection-profile to delete.
requestOptions: ConnectionProfilesClient.RequestOptions
Update the details of a specific Connection Profile.
</dd> </dl> </dd> </dl>await client.connectionProfiles.update("id");
id: string — ID of the connection profile to update.
request: Management.UpdateConnectionProfileRequestContent
requestOptions: ConnectionProfilesClient.RequestOptions
Retrieves detailed list of all <a href="https://auth0.com/docs/authenticate/identity-providers">connections</a> that match the specified strategy. If no strategy is provided, all connections within your tenant are retrieved. This action can accept a list of fields to include or exclude from the resulting list of connections.
This endpoint supports two types of pagination:
<ul> <li>Offset pagination</li> <li>Checkpoint pagination</li> </ul>Checkpoint pagination must be used if you need to retrieve more than 1000 connections.
<h2>Checkpoint Pagination</h2>To search by checkpoint, use the following parameters:
<ul> <li><code>from</code>: Optional id from which to start selection.</li> <li><code>take</code>: The total amount of entries to retrieve when using the from parameter. Defaults to 50.</li> </ul><b>Note</b>: The first time you call this endpoint using checkpoint pagination, omit the <code>from</code> parameter. If there are more results, a <code>next</code> value is included in the response. You can use this for subsequent API calls. When <code>next</code> is no longer included in the response, no pages are remaining.
</dd> </dl> </dd> </dl>const pageableResponse = await client.connections.list({
from: "from",
take: 1,
strategy: ["ad"],
name: "name",
fields: "fields",
include_fields: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.connections.list({
from: "from",
take: 1,
strategy: ["ad"],
name: "name",
fields: "fields",
include_fields: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListConnectionsQueryParameters
requestOptions: ConnectionsClient.RequestOptions
Creates a new connection according to the JSON object received in <code>body</code>.
<b>Note:</b> If a connection with the same name was recently deleted and had a large number of associated users, the deletion may still be processing. Creating a new connection with that name before the deletion completes may fail or produce unexpected results.
</dd> </dl> </dd> </dl>await client.connections.create({
name: "name",
strategy: "ad",
});
request: Management.CreateConnectionRequestContent
requestOptions: ConnectionsClient.RequestOptions
Retrieve details for a specified <a href="https://auth0.com/docs/authenticate/identity-providers">connection</a> along with options that can be used for identity provider configuration.
</dd> </dl> </dd> </dl>await client.connections.get("id", {
fields: "fields",
include_fields: true,
});
id: string — The id of the connection to retrieve
request: Management.GetConnectionRequestParameters
requestOptions: ConnectionsClient.RequestOptions
Removes a specific <a href="https://auth0.com/docs/authenticate/identity-providers">connection</a> from your tenant. This action cannot be undone. Once removed, users can no longer use this connection to authenticate.
<b>Note:</b> If your connection has a large amount of users associated with it, please be aware that this operation can be long running after the response is returned and may impact concurrent <a href="https://auth0.com/docs/api/management/v2/connections/post-connections">create connection</a> requests, if they use an identical connection name.
</dd> </dl> </dd> </dl>await client.connections.delete("id");
id: string — The id of the connection to delete
requestOptions: ConnectionsClient.RequestOptions
Update details for a specific <a href="https://auth0.com/docs/authenticate/identity-providers">connection</a>, including option properties for identity provider configuration.
<b>Note</b>: If you use the <code>options</code> parameter, the entire <code>options</code> object is overriden. To avoid partial data or other issues, ensure all parameters are present when using this option.
</dd> </dl> </dd> </dl>await client.connections.update("id");
id: string — The id of the connection to update
request: Management.UpdateConnectionRequestContent
requestOptions: ConnectionsClient.RequestOptions
Retrieves the status of an ad/ldap connection referenced by its <code>ID</code>. <code>200 OK</code> http status code response is returned when the connection is online, otherwise a <code>404</code> status code is returned along with an error message
</dd> </dl> </dd> </dl>await client.connections.checkStatus("id");
id: string — ID of the connection to check
requestOptions: ConnectionsClient.RequestOptions
Retrieve details on <a href="https://auth0.com/docs/custom-domains">custom domains</a>.
</dd> </dl> </dd> </dl>await client.customDomains.list({
q: "q",
fields: "fields",
include_fields: true,
sort: "sort",
});
request: Management.ListCustomDomainsRequestParameters
requestOptions: CustomDomainsClient.RequestOptions
Create a new custom domain.
Note: The custom domain will need to be verified before it will accept requests.
Optional attributes that can be updated:
TLS Policies:
await client.customDomains.create({
domain: "domain",
type: "auth0_managed_certs",
});
request: Management.CreateCustomDomainRequestContent
requestOptions: CustomDomainsClient.RequestOptions
Retrieve the tenant's default domain.
</dd> </dl> </dd> </dl>await client.customDomains.getDefault();
requestOptions: CustomDomainsClient.RequestOptions
Set the default custom domain for the tenant.
</dd> </dl> </dd> </dl>await client.customDomains.setDefault({
domain: "domain",
});
request: Management.SetDefaultCustomDomainRequestContent
requestOptions: CustomDomainsClient.RequestOptions
Retrieve a custom domain configuration and status.
</dd> </dl> </dd> </dl>await client.customDomains.get("id");
id: string — ID of the custom domain to retrieve.
requestOptions: CustomDomainsClient.RequestOptions
Delete a custom domain and stop serving requests for it.
</dd> </dl> </dd> </dl>await client.customDomains.delete("id");
id: string — ID of the custom domain to delete.
requestOptions: CustomDomainsClient.RequestOptions
Update a custom domain.
These are the attributes that can be updated:
TLS Policies:
Some considerations:
await client.customDomains.update("id");
id: string — The id of the custom domain to update
request: Management.UpdateCustomDomainRequestContent
requestOptions: CustomDomainsClient.RequestOptions
Run the test process on a custom domain.
</dd> </dl> </dd> </dl>await client.customDomains.test("id");
id: string — ID of the custom domain to test.
requestOptions: CustomDomainsClient.RequestOptions
Run the verification process on a custom domain.
Note: Check the <code>status</code> field to see its verification status. Once verification is complete, it may take up to 10 minutes before the custom domain can start accepting requests.
For <code>self_managed_certs</code>, when the custom domain is verified for the first time, the response will also include the <code>cname_api_key</code> which you will need to configure your proxy. This key must be kept secret, and is used to validate the proxy requests.
<a href="https://auth0.com/docs/custom-domains#step-2-verify-ownership">Learn more</a> about verifying custom domains that use Auth0 Managed certificates. <a href="https://auth0.com/docs/custom-domains/self-managed-certificates#step-2-verify-ownership">Learn more</a> about verifying custom domains that use Self Managed certificates.
</dd> </dl> </dd> </dl>await client.customDomains.verify("id");
id: string — ID of the custom domain to verify.
requestOptions: CustomDomainsClient.RequestOptions
Retrieve device credential information (<code>public_key</code>, <code>refresh_token</code>, or <code>rotating_refresh_token</code>) associated with a specific user.
</dd> </dl> </dd> </dl>const pageableResponse = await client.deviceCredentials.list({
page: 1,
per_page: 1,
include_totals: true,
fields: "fields",
include_fields: true,
user_id: "user_id",
client_id: "client_id",
type: "public_key",
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.deviceCredentials.list({
page: 1,
per_page: 1,
include_totals: true,
fields: "fields",
include_fields: true,
user_id: "user_id",
client_id: "client_id",
type: "public_key",
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListDeviceCredentialsRequestParameters
requestOptions: DeviceCredentialsClient.RequestOptions
Create a device credential public key to manage refresh token rotation for a given <code>user_id</code>. Device Credentials APIs are designed for ad-hoc administrative use only and paging is by default enabled for GET requests.
When refresh token rotation is enabled, the endpoint becomes consistent. For more information, read <a href="https://auth0.com/docs/get-started/tenant-settings/signing-keys"> Signing Keys</a>.
</dd> </dl> </dd> </dl>await client.deviceCredentials.createPublicKey({
device_name: "device_name",
type: "public_key",
value: "value",
device_id: "device_id",
});
request: Management.CreatePublicKeyDeviceCredentialRequestContent
requestOptions: DeviceCredentialsClient.RequestOptions
Permanently delete a device credential (such as a refresh token or public key) with the given ID.
</dd> </dl> </dd> </dl>await client.deviceCredentials.delete("id");
id: string — ID of the credential to delete.
requestOptions: DeviceCredentialsClient.RequestOptions
Create an email template.
</dd> </dl> </dd> </dl>await client.emailTemplates.create({
template: "verify_email",
});
request: Management.CreateEmailTemplateRequestContent
requestOptions: EmailTemplatesClient.RequestOptions
Retrieve an email template by pre-defined name. These names are verify_email, verify_email_by_code, reset_email, reset_email_by_code, welcome_email, blocked_account, stolen_credentials, enrollment_email, mfa_oob_code, user_invitation, and async_approval. The names change_password, and password_reset are also supported for legacy scenarios.
await client.emailTemplates.get("verify_email");
templateName: Management.EmailTemplateNameEnum — Template name. Can be verify_email, verify_email_by_code, reset_email, reset_email_by_code, welcome_email, blocked_account, stolen_credentials, enrollment_email, mfa_oob_code, user_invitation, async_approval, change_password (legacy), or password_reset (legacy).
requestOptions: EmailTemplatesClient.RequestOptions
Update an email template.
</dd> </dl> </dd> </dl>await client.emailTemplates.set("verify_email", {
template: "verify_email",
});
templateName: Management.EmailTemplateNameEnum — Template name. Can be verify_email, verify_email_by_code, reset_email, reset_email_by_code, welcome_email, blocked_account, stolen_credentials, enrollment_email, mfa_oob_code, user_invitation, async_approval, change_password (legacy), or password_reset (legacy).
request: Management.SetEmailTemplateRequestContent
requestOptions: EmailTemplatesClient.RequestOptions
Modify an email template.
</dd> </dl> </dd> </dl>await client.emailTemplates.update("verify_email");
templateName: Management.EmailTemplateNameEnum — Template name. Can be verify_email, verify_email_by_code, reset_email, reset_email_by_code, welcome_email, blocked_account, stolen_credentials, enrollment_email, mfa_oob_code, user_invitation, async_approval, change_password (legacy), or password_reset (legacy).
request: Management.UpdateEmailTemplateRequestContent
requestOptions: EmailTemplatesClient.RequestOptions
const pageableResponse = await client.eventStreams.list({
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.eventStreams.list({
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListEventStreamsRequestParameters
requestOptions: EventStreamsClient.RequestOptions
await client.eventStreams.create({
destination: {
type: "webhook",
configuration: {
webhook_endpoint: "webhook_endpoint",
webhook_authorization: {
method: "basic",
username: "username",
},
},
},
});
request: Management.EventStreamsCreateRequest
requestOptions: EventStreamsClient.RequestOptions
await client.eventStreams.get("id");
id: string — Unique identifier for the event stream.
requestOptions: EventStreamsClient.RequestOptions
await client.eventStreams.delete("id");
id: string — Unique identifier for the event stream.
requestOptions: EventStreamsClient.RequestOptions
await client.eventStreams.update("id");
id: string — Unique identifier for the event stream.
request: Management.UpdateEventStreamRequestContent
requestOptions: EventStreamsClient.RequestOptions
await client.eventStreams.test("id", {
event_type: "group.created",
});
id: string — Unique identifier for the event stream.
request: Management.CreateEventStreamTestEventRequestContent
requestOptions: EventStreamsClient.RequestOptions
Subscribe to events via Server-Sent Events (SSE)
</dd> </dl> </dd> </dl>const response = await client.events.subscribe({
from: "from",
from_timestamp: "from_timestamp",
event_type: ["group.created"],
});
for await (const item of response) {
console.log(item);
}
request: Management.SubscribeEventsRequestParameters
requestOptions: EventsClient.RequestOptions
const pageableResponse = await client.flows.list({
page: 1,
per_page: 1,
include_totals: true,
hydrate: ["form_count"],
synchronous: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.flows.list({
page: 1,
per_page: 1,
include_totals: true,
hydrate: ["form_count"],
synchronous: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListFlowsRequestParameters
requestOptions: FlowsClient.RequestOptions
await client.flows.create({
name: "name",
});
request: Management.CreateFlowRequestContent
requestOptions: FlowsClient.RequestOptions
await client.flows.get("id", {
hydrate: ["form_count"],
});
id: string — Flow identifier
request: Management.GetFlowRequestParameters
requestOptions: FlowsClient.RequestOptions
await client.flows.delete("id");
id: string — Flow id
requestOptions: FlowsClient.RequestOptions
await client.flows.update("id");
id: string — Flow identifier
request: Management.UpdateFlowRequestContent
requestOptions: FlowsClient.RequestOptions
const pageableResponse = await client.forms.list({
page: 1,
per_page: 1,
include_totals: true,
hydrate: ["flow_count"],
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.forms.list({
page: 1,
per_page: 1,
include_totals: true,
hydrate: ["flow_count"],
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListFormsRequestParameters
requestOptions: FormsClient.RequestOptions
await client.forms.create({
name: "name",
});
request: Management.CreateFormRequestContent
requestOptions: FormsClient.RequestOptions
await client.forms.get("id", {
hydrate: ["flow_count"],
});
id: string — The ID of the form to retrieve.
request: Management.GetFormRequestParameters
requestOptions: FormsClient.RequestOptions
await client.forms.delete("id");
id: string — The ID of the form to delete.
requestOptions: FormsClient.RequestOptions
await client.forms.update("id");
id: string — The ID of the form to update.
request: Management.UpdateFormRequestContent
requestOptions: FormsClient.RequestOptions
Retrieve the <a href="https://auth0.com/docs/api-auth/which-oauth-flow-to-use">grants</a> associated with your account.
</dd> </dl> </dd> </dl>const pageableResponse = await client.userGrants.list({
per_page: 1,
page: 1,
include_totals: true,
user_id: "user_id",
client_id: "client_id",
audience: "audience",
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.userGrants.list({
per_page: 1,
page: 1,
include_totals: true,
user_id: "user_id",
client_id: "client_id",
audience: "audience",
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListUserGrantsRequestParameters
requestOptions: UserGrantsClient.RequestOptions
Delete a grant associated with your account.
</dd> </dl> </dd> </dl>await client.userGrants.deleteByUserId({
user_id: "user_id",
});
request: Management.DeleteUserGrantByUserIdRequestParameters
requestOptions: UserGrantsClient.RequestOptions
Delete a grant associated with your account.
</dd> </dl> </dd> </dl>await client.userGrants.delete("id");
id: string — ID of the grant to delete.
requestOptions: UserGrantsClient.RequestOptions
List all groups in your tenant.
</dd> </dl> </dd> </dl>const pageableResponse = await client.groups.list({
connection_id: "connection_id",
name: "name",
external_id: "external_id",
search: "search",
fields: "fields",
include_fields: true,
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.groups.list({
connection_id: "connection_id",
name: "name",
external_id: "external_id",
search: "search",
fields: "fields",
include_fields: true,
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListGroupsRequestParameters
requestOptions: GroupsClient.RequestOptions
Retrieve a group by its ID.
</dd> </dl> </dd> </dl>await client.groups.get("id");
id: string — Unique identifier for the group (service-generated).
requestOptions: GroupsClient.RequestOptions
Delete a group by its ID.
</dd> </dl> </dd> </dl>await client.groups.delete("id");
id: string — Unique identifier for the group (service-generated).
requestOptions: GroupsClient.RequestOptions
Retrieve all <a href="https://auth0.com/docs/hooks">hooks</a>. Accepts a list of fields to include or exclude in the result.
</dd> </dl> </dd> </dl>const pageableResponse = await client.hooks.list({
page: 1,
per_page: 1,
include_totals: true,
enabled: true,
fields: "fields",
triggerId: "credentials-exchange",
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.hooks.list({
page: 1,
per_page: 1,
include_totals: true,
enabled: true,
fields: "fields",
triggerId: "credentials-exchange",
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListHooksRequestParameters
requestOptions: HooksClient.RequestOptions
Create a new hook.
</dd> </dl> </dd> </dl>await client.hooks.create({
name: "name",
script: "script",
triggerId: "credentials-exchange",
});
request: Management.CreateHookRequestContent
requestOptions: HooksClient.RequestOptions
Retrieve <a href="https://auth0.com/docs/hooks">a hook</a> by its ID. Accepts a list of fields to include in the result.
</dd> </dl> </dd> </dl>await client.hooks.get("id", {
fields: "fields",
});
id: string — ID of the hook to retrieve.
request: Management.GetHookRequestParameters
requestOptions: HooksClient.RequestOptions
Delete a hook.
</dd> </dl> </dd> </dl>await client.hooks.delete("id");
id: string — ID of the hook to delete.
requestOptions: HooksClient.RequestOptions
Update an existing hook.
</dd> </dl> </dd> </dl>await client.hooks.update("id");
id: string — ID of the hook to update.
request: Management.UpdateHookRequestContent
requestOptions: HooksClient.RequestOptions
Retrieves a job. Useful to check its status.
</dd> </dl> </dd> </dl>await client.jobs.get("id");
id: string — ID of the job.
requestOptions: JobsClient.RequestOptions
Retrieve details on log streams.
Sample Response
[
{
"id": "string",
"name": "string",
"type": "eventbridge",
"status": "active|paused|suspended",
"sink": {
"awsAccountId": "string",
"awsRegion": "string",
"awsPartnerEventSource": "string"
}
},
{
"id": "string",
"name": "string",
"type": "http",
"status": "active|paused|suspended",
"sink": {
"httpContentFormat": "JSONLINES|JSONARRAY",
"httpContentType": "string",
"httpEndpoint": "string",
"httpAuthorization": "string"
}
},
{
"id": "string",
"name": "string",
"type": "eventgrid",
"status": "active|paused|suspended",
"sink": {
"azureSubscriptionId": "string",
"azureResourceGroup": "string",
"azureRegion": "string",
"azurePartnerTopic": "string"
}
},
{
"id": "string",
"name": "string",
"type": "splunk",
"status": "active|paused|suspended",
"sink": {
"splunkDomain": "string",
"splunkToken": "string",
"splunkPort": "string",
"splunkSecure": "boolean"
}
},
{
"id": "string",
"name": "string",
"type": "sumo",
"status": "active|paused|suspended",
"sink": {
"sumoSourceAddress": "string"
}
},
{
"id": "string",
"name": "string",
"type": "datadog",
"status": "active|paused|suspended",
"sink": {
"datadogRegion": "string",
"datadogApiKey": "string"
}
}
]
await client.logStreams.list();
requestOptions: LogStreamsClient.RequestOptions
Create a log stream.
Log Stream Types
The type of log stream being created determines the properties required in the sink payload.
HTTP Stream
For an http Stream, the sink properties are listed in the payload below.
Request:
{
"name": "string",
"type": "http",
"sink": {
"httpEndpoint": "string",
"httpContentType": "string",
"httpContentFormat": "JSONLINES|JSONARRAY",
"httpAuthorization": "string"
}
}
Response:
{
"id": "string",
"name": "string",
"type": "http",
"status": "active",
"sink": {
"httpEndpoint": "string",
"httpContentType": "string",
"httpContentFormat": "JSONLINES|JSONARRAY",
"httpAuthorization": "string"
}
}
Amazon EventBridge Stream
For an eventbridge Stream, the sink properties are listed in the payload below.
Request:
{
"name": "string",
"type": "eventbridge",
"sink": {
"awsRegion": "string",
"awsAccountId": "string"
}
}
The response will include an additional field awsPartnerEventSource in the sink:
Response:
{
"id": "string",
"name": "string",
"type": "eventbridge",
"status": "active",
"sink": {
"awsAccountId": "string",
"awsRegion": "string",
"awsPartnerEventSource": "string"
}
}
Azure Event Grid Stream
For an Azure Event Grid Stream, the sink properties are listed in the payload below.
Request:
{
"name": "string",
"type": "eventgrid",
"sink": {
"azureSubscriptionId": "string",
"azureResourceGroup": "string",
"azureRegion": "string"
}
}
Response:
{
"id": "string",
"name": "string",
"type": "http",
"status": "active",
"sink": {
"azureSubscriptionId": "string",
"azureResourceGroup": "string",
"azureRegion": "string",
"azurePartnerTopic": "string"
}
}
Datadog Stream
For a Datadog Stream, the sink properties are listed in the payload below.
Request:
{
"name": "string",
"type": "datadog",
"sink": {
"datadogRegion": "string",
"datadogApiKey": "string"
}
}
Response:
{
"id": "string",
"name": "string",
"type": "datadog",
"status": "active",
"sink": {
"datadogRegion": "string",
"datadogApiKey": "string"
}
}
Splunk Stream
For a Splunk Stream, the sink properties are listed in the payload below.
Request:
{
"name": "string",
"type": "splunk",
"sink": {
"splunkDomain": "string",
"splunkToken": "string",
"splunkPort": "string",
"splunkSecure": "boolean"
}
}
Response:
{
"id": "string",
"name": "string",
"type": "splunk",
"status": "active",
"sink": {
"splunkDomain": "string",
"splunkToken": "string",
"splunkPort": "string",
"splunkSecure": "boolean"
}
}
Sumo Logic Stream
For a Sumo Logic Stream, the sink properties are listed in the payload below.
Request:
{
"name": "string",
"type": "sumo",
"sink": {
"sumoSourceAddress": "string"
}
}
Response:
{
"id": "string",
"name": "string",
"type": "sumo",
"status": "active",
"sink": {
"sumoSourceAddress": "string"
}
}
await client.logStreams.create({
type: "http",
sink: {
httpEndpoint: "httpEndpoint",
},
});
request: Management.CreateLogStreamRequestContent
requestOptions: LogStreamsClient.RequestOptions
Retrieve a log stream configuration and status.
Sample responses
Amazon EventBridge Log Stream
{
"id": "string",
"name": "string",
"type": "eventbridge",
"status": "active|paused|suspended",
"sink": {
"awsAccountId": "string",
"awsRegion": "string",
"awsPartnerEventSource": "string"
}
}
HTTP Log Stream
{
"id": "string",
"name": "string",
"type": "http",
"status": "active|paused|suspended",
"sink": {
"httpContentFormat": "JSONLINES|JSONARRAY",
"httpContentType": "string",
"httpEndpoint": "string",
"httpAuthorization": "string"
}
}
Datadog Log Stream
{
"id": "string",
"name": "string",
"type": "datadog",
"status": "active|paused|suspended",
"sink": {
"datadogRegion": "string",
"datadogApiKey": "string"
}
}
Mixpanel
Request:
{
"name": "string",
"type": "mixpanel",
"sink": {
"mixpanelRegion": "string",
"mixpanelProjectId": "string",
"mixpanelServiceAccountUsername": "string",
"mixpanelServiceAccountPassword": "string"
}
}
Response:
{
"id": "string",
"name": "string",
"type": "mixpanel",
"status": "active",
"sink": {
"mixpanelRegion": "string",
"mixpanelProjectId": "string",
"mixpanelServiceAccountUsername": "string",
"mixpanelServiceAccountPassword": "string"
}
}
Segment
Request:
{
"name": "string",
"type": "segment",
"sink": {
"segmentWriteKey": "string"
}
}
Response:
{
"id": "string",
"name": "string",
"type": "segment",
"status": "active",
"sink": {
"segmentWriteKey": "string"
}
}
Splunk Log Stream
{
"id": "string",
"name": "string",
"type": "splunk",
"status": "active|paused|suspended",
"sink": {
"splunkDomain": "string",
"splunkToken": "string",
"splunkPort": "string",
"splunkSecure": "boolean"
}
}
Sumo Logic Log Stream
{
"id": "string",
"name": "string",
"type": "sumo",
"status": "active|paused|suspended",
"sink": {
"sumoSourceAddress": "string"
}
}
Status
The status of a log stream maybe any of the following:
active - Stream is currently enabled.paused - Stream is currently user disabled and will not attempt log delivery.suspended - Stream is currently disabled because of errors and will not attempt log delivery.await client.logStreams.get("id");
id: string — The id of the log stream to get
requestOptions: LogStreamsClient.RequestOptions
Delete a log stream.
</dd> </dl> </dd> </dl>await client.logStreams.delete("id");
id: string — The id of the log stream to delete
requestOptions: LogStreamsClient.RequestOptions
Update a log stream.
Examples of how to use the PATCH endpoint.
The following fields may be updated in a PATCH operation:
Note: For log streams of type eventbridge and eventgrid, updating the sink is not permitted.
Update the status of a log stream
{
"status": "active|paused"
}
Update the name of a log stream
{
"name": "string"
}
Update the sink properties of a stream of type http
{
"sink": {
"httpEndpoint": "string",
"httpContentType": "string",
"httpContentFormat": "JSONARRAY|JSONLINES",
"httpAuthorization": "string"
}
}
Update the sink properties of a stream of type datadog
{
"sink": {
"datadogRegion": "string",
"datadogApiKey": "string"
}
}
Update the sink properties of a stream of type splunk
{
"sink": {
"splunkDomain": "string",
"splunkToken": "string",
"splunkPort": "string",
"splunkSecure": "boolean"
}
}
Update the sink properties of a stream of type sumo
{
"sink": {
"sumoSourceAddress": "string"
}
}
await client.logStreams.update("id");
id: string — The id of the log stream to get
request: Management.UpdateLogStreamRequestContent
requestOptions: LogStreamsClient.RequestOptions
Retrieve log entries that match the specified search criteria (or all log entries if no criteria specified).
Set custom search criteria using the <code>q</code> parameter, or search from a specific log ID (<i>"search from checkpoint"</i>).
For more information on all possible event types, their respective acronyms, and descriptions, see <a href="https://auth0.com/docs/logs/log-event-type-codes">Log Event Type Codes</a>.
<h5>To set custom search criteria, use the following parameters:</h5> <ul> <li><b>q:</b> Search Criteria using <a href="https://auth0.com/docs/logs/log-search-query-syntax">Query String Syntax</a></li> <li><b>page:</b> Page index of the results to return. First page is 0.</li> <li><b>per_page:</b> Number of results per page.</li> <li><b>sort:</b> Field to use for sorting appended with `:1` for ascending and `:-1` for descending. e.g. `date:-1`</li> <li><b>fields:</b> Comma-separated list of fields to include or exclude (depending on include_fields) from the result, empty to retrieve all fields.</li> <li><b>include_fields:</b> Whether specified fields are to be included (true) or excluded (false).</li> <li><b>include_totals:</b> Return results inside an object that contains the total result count (true) or as a direct array of results (false, default). <b>Deprecated:</b> this field is deprecated and should be removed from use. See <a href="https://auth0.com/docs/product-lifecycle/deprecations-and-migrations/migrate-to-tenant-log-search-v3#pagination">Search Engine V3 Breaking Changes</a></li> </ul>For more information on the list of fields that can be used in <code>fields</code> and <code>sort</code>, see <a href="https://auth0.com/docs/logs/log-search-query-syntax#searchable-fields">Searchable Fields</a>.
Auth0 <a href="https://auth0.com/docs/logs/retrieve-log-events-using-mgmt-api#limitations">limits the number of logs</a> you can return by search criteria to 100 logs per request. Furthermore, you may paginate only through 1,000 search results. If you exceed this threshold, please redefine your search or use the <a href="https://auth0.com/docs/logs/retrieve-log-events-using-mgmt-api#retrieve-logs-by-checkpoint">get logs by checkpoint method</a>.
<h5>To search from a checkpoint log ID, use the following parameters:</h5> <ul> <li><b>from:</b> Log Event ID from which to start retrieving logs. You can limit the number of logs returned using the <code>take</code> parameter. If you use <code>from</code> at the same time as <code>q</code>, <code>from</code> takes precedence and <code>q</code> is ignored.</li> <li><b>take:</b> Number of entries to retrieve when using the <code>from</code> parameter.</li> </ul><strong>Important:</strong> When fetching logs from a checkpoint log ID, any parameter other than <code>from</code> and <code>take</code> will be ignored, and date ordering is not guaranteed.
</dd> </dl> </dd> </dl>const pageableResponse = await client.logs.list({
page: 1,
per_page: 1,
sort: "sort",
fields: "fields",
include_fields: true,
include_totals: true,
search: "search",
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.logs.list({
page: 1,
per_page: 1,
sort: "sort",
fields: "fields",
include_fields: true,
include_totals: true,
search: "search",
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListLogsRequestParameters
requestOptions: LogsClient.RequestOptions
Retrieve an individual log event.
</dd> </dl> </dd> </dl>await client.logs.get("id");
id: string — log_id of the log to retrieve.
requestOptions: LogsClient.RequestOptions
Get all access control list entries for your client.
</dd> </dl> </dd> </dl>const pageableResponse = await client.networkAcls.list({
page: 1,
per_page: 1,
include_totals: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.networkAcls.list({
page: 1,
per_page: 1,
include_totals: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListNetworkAclsRequestParameters
requestOptions: NetworkAclsClient.RequestOptions
Create a new access control list for your client.
</dd> </dl> </dd> </dl>await client.networkAcls.create({
description: "description",
active: true,
rule: {
action: {},
scope: "management",
},
});
request: Management.CreateNetworkAclRequestContent
requestOptions: NetworkAclsClient.RequestOptions
Get a specific access control list entry for your client.
</dd> </dl> </dd> </dl>await client.networkAcls.get("id");
id: string — The id of the access control list to retrieve.
requestOptions: NetworkAclsClient.RequestOptions
Update existing access control list for your client.
</dd> </dl> </dd> </dl>await client.networkAcls.set("id", {
description: "description",
active: true,
rule: {
action: {},
scope: "management",
},
});
id: string — The id of the ACL to update.
request: Management.SetNetworkAclRequestContent
requestOptions: NetworkAclsClient.RequestOptions
Delete existing access control list for your client.
</dd> </dl> </dd> </dl>await client.networkAcls.delete("id");
id: string — The id of the ACL to delete
requestOptions: NetworkAclsClient.RequestOptions
Update existing access control list for your client.
</dd> </dl> </dd> </dl>await client.networkAcls.update("id");
id: string — The id of the ACL to update.
request: Management.UpdateNetworkAclRequestContent
requestOptions: NetworkAclsClient.RequestOptions
Retrieve detailed list of all Organizations available in your tenant. For more information, see Auth0 Organizations.
This endpoint supports two types of pagination:
<ul> <li>Offset pagination</li> <li>Checkpoint pagination</li> </ul>Checkpoint pagination must be used if you need to retrieve more than 1000 organizations.
<h2>Checkpoint Pagination</h2>To search by checkpoint, use the following parameters:
<ul> <li><code>from</code>: Optional id from which to start selection.</li> <li><code>take</code>: The total number of entries to retrieve when using the <code>from</code> parameter. Defaults to 50.</li> </ul><b>Note</b>: The first time you call this endpoint using checkpoint pagination, omit the <code>from</code> parameter. If there are more results, a <code>next</code> value is included in the response. You can use this for subsequent API calls. When <code>next</code> is no longer included in the response, no pages are remaining.
</dd> </dl> </dd> </dl>const pageableResponse = await client.organizations.list({
from: "from",
take: 1,
sort: "sort",
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.organizations.list({
from: "from",
take: 1,
sort: "sort",
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListOrganizationsRequestParameters
requestOptions: OrganizationsClient.RequestOptions
Create a new Organization within your tenant. To learn more about Organization settings, behavior, and configuration options, review <a href="https://auth0.com/docs/manage-users/organizations/create-first-organization">Create Your First Organization</a>.
</dd> </dl> </dd> </dl>await client.organizations.create({
name: "name",
});
request: Management.CreateOrganizationRequestContent
requestOptions: OrganizationsClient.RequestOptions
Retrieve details about a single Organization specified by name.
</dd> </dl> </dd> </dl>await client.organizations.getByName("name");
name: string — name of the organization to retrieve.
requestOptions: OrganizationsClient.RequestOptions
Retrieve details about a single Organization specified by ID.
</dd> </dl> </dd> </dl>await client.organizations.get("id");
id: string — ID of the organization to retrieve.
requestOptions: OrganizationsClient.RequestOptions
Remove an Organization from your tenant. This action cannot be undone.
<b>Note</b>: Members are automatically disassociated from an Organization when it is deleted. However, this action does <b>not</b> delete these users from your tenant.
</dd> </dl> </dd> </dl>await client.organizations.delete("id");
id: string — Organization identifier.
requestOptions: OrganizationsClient.RequestOptions
Update the details of a specific <a href="https://auth0.com/docs/manage-users/organizations/configure-organizations/create-organizations">Organization</a>, such as name and display name, branding options, and metadata.
</dd> </dl> </dd> </dl>await client.organizations.update("id");
id: string — ID of the organization to update.
request: Management.UpdateOrganizationRequestContent
requestOptions: OrganizationsClient.RequestOptions
Retrieve details of the Universal Login configuration of your tenant. This includes the <a href="https://auth0.com/docs/authenticate/login/auth0-universal-login/identifier-first">Identifier First Authentication</a> and <a href="https://auth0.com/docs/secure/multi-factor-authentication/fido-authentication-with-webauthn/configure-webauthn-device-biometrics-for-mfa">WebAuthn with Device Biometrics for MFA</a> features.
</dd> </dl> </dd> </dl>await client.prompts.getSettings();
requestOptions: PromptsClient.RequestOptions
Update the Universal Login configuration of your tenant. This includes the <a href="https://auth0.com/docs/authenticate/login/auth0-universal-login/identifier-first">Identifier First Authentication</a> and <a href="https://auth0.com/docs/secure/multi-factor-authentication/fido-authentication-with-webauthn/configure-webauthn-device-biometrics-for-mfa">WebAuthn with Device Biometrics for MFA</a> features.
</dd> </dl> </dd> </dl>await client.prompts.updateSettings();
request: Management.UpdateSettingsRequestContent
requestOptions: PromptsClient.RequestOptions
Retrieve a paginated list of refresh tokens for a specific user, with optional filtering by client ID. Results are sorted by credential_id ascending.
</dd> </dl> </dd> </dl>const pageableResponse = await client.refreshTokens.list({
user_id: "user_id",
client_id: "client_id",
from: "from",
take: 1,
fields: "fields",
include_fields: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.refreshTokens.list({
user_id: "user_id",
client_id: "client_id",
from: "from",
take: 1,
fields: "fields",
include_fields: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.GetRefreshTokensRequestParameters
requestOptions: RefreshTokensClient.RequestOptions
Revoke refresh tokens in bulk by ID list, user, user+client, or client.
</dd> </dl> </dd> </dl>await client.refreshTokens.revoke();
request: Management.RevokeRefreshTokensRequestContent
requestOptions: RefreshTokensClient.RequestOptions
Retrieve refresh token information.
</dd> </dl> </dd> </dl>await client.refreshTokens.get("id");
id: string — ID refresh token to retrieve
requestOptions: RefreshTokensClient.RequestOptions
Delete a refresh token by its ID.
</dd> </dl> </dd> </dl>await client.refreshTokens.delete("id");
id: string — ID of the refresh token to delete.
requestOptions: RefreshTokensClient.RequestOptions
Update a refresh token by its ID.
</dd> </dl> </dd> </dl>await client.refreshTokens.update("id");
id: string — ID of the refresh token to update.
request: Management.UpdateRefreshTokenRequestContent
requestOptions: RefreshTokensClient.RequestOptions
Retrieve details of all APIs associated with your tenant.
</dd> </dl> </dd> </dl>const pageableResponse = await client.resourceServers.list({
identifiers: ["identifiers"],
page: 1,
per_page: 1,
include_totals: true,
include_fields: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.resourceServers.list({
identifiers: ["identifiers"],
page: 1,
per_page: 1,
include_totals: true,
include_fields: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListResourceServerRequestParameters
requestOptions: ResourceServersClient.RequestOptions
Create a new API associated with your tenant. Note that all new APIs must be registered with Auth0. For more information, read <a href="https://www.auth0.com/docs/get-started/apis"> APIs</a>.
</dd> </dl> </dd> </dl>await client.resourceServers.create({
identifier: "identifier",
});
request: Management.CreateResourceServerRequestContent
requestOptions: ResourceServersClient.RequestOptions
Retrieve <a href="https://auth0.com/docs/apis">API</a> details with the given ID.
</dd> </dl> </dd> </dl>await client.resourceServers.get("id", {
include_fields: true,
});
id: string — ID or audience of the resource server to retrieve.
request: Management.GetResourceServerRequestParameters
requestOptions: ResourceServersClient.RequestOptions
Delete an existing API by ID. For more information, read <a href="https://www.auth0.com/docs/get-started/apis/api-settings">API Settings</a>.
</dd> </dl> </dd> </dl>await client.resourceServers.delete("id");
id: string — ID or the audience of the resource server to delete.
requestOptions: ResourceServersClient.RequestOptions
Change an existing API setting by resource server ID. For more information, read <a href="https://www.auth0.com/docs/get-started/apis/api-settings">API Settings</a>.
</dd> </dl> </dd> </dl>await client.resourceServers.update("id");
id: string — ID or audience of the resource server to update.
request: Management.UpdateResourceServerRequestContent
requestOptions: ResourceServersClient.RequestOptions
Retrieve detailed list of user roles created in your tenant.
<b>Note</b>: The returned list does not include standard roles available for tenant members, such as Admin or Support Access.
</dd> </dl> </dd> </dl>const pageableResponse = await client.roles.list({
per_page: 1,
page: 1,
include_totals: true,
name_filter: "name_filter",
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.roles.list({
per_page: 1,
page: 1,
include_totals: true,
name_filter: "name_filter",
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListRolesRequestParameters
requestOptions: RolesClient.RequestOptions
Create a user role for <a href="https://auth0.com/docs/manage-users/access-control/rbac">Role-Based Access Control</a>.
<b>Note</b>: New roles are not associated with any permissions by default. To assign existing permissions to your role, review Associate Permissions with a Role. To create new permissions, review Add API Permissions.
</dd> </dl> </dd> </dl>await client.roles.create({
name: "name",
});
request: Management.CreateRoleRequestContent
requestOptions: RolesClient.RequestOptions
Retrieve details about a specific <a href="https://auth0.com/docs/manage-users/access-control/rbac">user role</a> specified by ID.
</dd> </dl> </dd> </dl>await client.roles.get("id");
id: string — ID of the role to retrieve.
requestOptions: RolesClient.RequestOptions
Delete a specific <a href="https://auth0.com/docs/manage-users/access-control/rbac">user role</a> from your tenant. Once deleted, it is removed from any user who was previously assigned that role. This action cannot be undone.
</dd> </dl> </dd> </dl>await client.roles.delete("id");
id: string — ID of the role to delete.
requestOptions: RolesClient.RequestOptions
Modify the details of a specific <a href="https://auth0.com/docs/manage-users/access-control/rbac">user role</a> specified by ID.
</dd> </dl> </dd> </dl>await client.roles.update("id");
id: string — ID of the role to update.
request: Management.UpdateRoleRequestContent
requestOptions: RolesClient.RequestOptions
Retrieve a filtered list of <a href="https://auth0.com/docs/rules">rules</a>. Accepts a list of fields to include or exclude.
</dd> </dl> </dd> </dl>const pageableResponse = await client.rules.list({
page: 1,
per_page: 1,
include_totals: true,
enabled: true,
fields: "fields",
include_fields: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.rules.list({
page: 1,
per_page: 1,
include_totals: true,
enabled: true,
fields: "fields",
include_fields: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListRulesRequestParameters
requestOptions: RulesClient.RequestOptions
Create a <a href="https://auth0.com/docs/rules#create-a-new-rule-using-the-management-api">new rule</a>.
Note: Changing a rule's stage of execution from the default <code>login_success</code> can change the rule's function signature to have user omitted.
</dd> </dl> </dd> </dl>await client.rules.create({
name: "name",
script: "script",
});
request: Management.CreateRuleRequestContent
requestOptions: RulesClient.RequestOptions
Retrieve <a href="https://auth0.com/docs/rules">rule</a> details. Accepts a list of fields to include or exclude in the result.
</dd> </dl> </dd> </dl>await client.rules.get("id", {
fields: "fields",
include_fields: true,
});
id: string — ID of the rule to retrieve.
request: Management.GetRuleRequestParameters
requestOptions: RulesClient.RequestOptions
Delete a rule.
</dd> </dl> </dd> </dl>await client.rules.delete("id");
id: string — ID of the rule to delete.
requestOptions: RulesClient.RequestOptions
Update an existing rule.
</dd> </dl> </dd> </dl>await client.rules.update("id");
id: string — ID of the rule to retrieve.
request: Management.UpdateRuleRequestContent
requestOptions: RulesClient.RequestOptions
Retrieve rules config variable keys.
Note: For security, config variable values cannot be retrieved outside rule execution.
await client.rulesConfigs.list();
requestOptions: RulesConfigsClient.RequestOptions
Sets a rules config variable.
</dd> </dl> </dd> </dl>await client.rulesConfigs.set("key", {
value: "value",
});
key: string — Key of the rules config variable to set (max length: 127 characters).
request: Management.SetRulesConfigRequestContent
requestOptions: RulesConfigsClient.RequestOptions
Delete a rules config variable identified by its key.
</dd> </dl> </dd> </dl>await client.rulesConfigs.delete("key");
key: string — Key of the rules config variable to delete.
requestOptions: RulesConfigsClient.RequestOptions
Retrieves self-service profiles.
</dd> </dl> </dd> </dl>const pageableResponse = await client.selfServiceProfiles.list({
page: 1,
per_page: 1,
include_totals: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.selfServiceProfiles.list({
page: 1,
per_page: 1,
include_totals: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListSelfServiceProfilesRequestParameters
requestOptions: SelfServiceProfilesClient.RequestOptions
Creates a self-service profile.
</dd> </dl> </dd> </dl>await client.selfServiceProfiles.create({
name: "name",
});
request: Management.CreateSelfServiceProfileRequestContent
requestOptions: SelfServiceProfilesClient.RequestOptions
Retrieves a self-service profile by Id.
</dd> </dl> </dd> </dl>await client.selfServiceProfiles.get("id");
id: string — The id of the self-service profile to retrieve
requestOptions: SelfServiceProfilesClient.RequestOptions
Deletes a self-service profile by Id.
</dd> </dl> </dd> </dl>await client.selfServiceProfiles.delete("id");
id: string — The id of the self-service profile to delete
requestOptions: SelfServiceProfilesClient.RequestOptions
Updates a self-service profile.
</dd> </dl> </dd> </dl>await client.selfServiceProfiles.update("id");
id: string — The id of the self-service profile to update
request: Management.UpdateSelfServiceProfileRequestContent
requestOptions: SelfServiceProfilesClient.RequestOptions
Retrieve session information.
</dd> </dl> </dd> </dl>await client.sessions.get("id");
id: string — ID of session to retrieve
requestOptions: SessionsClient.RequestOptions
Delete a session by ID.
</dd> </dl> </dd> </dl>await client.sessions.delete("id");
id: string — ID of the session to delete.
requestOptions: SessionsClient.RequestOptions
Update session information.
</dd> </dl> </dd> </dl>await client.sessions.update("id");
id: string — ID of the session to update.
request: Management.UpdateSessionRequestContent
requestOptions: SessionsClient.RequestOptions
Revokes a session by ID and all associated refresh tokens.
</dd> </dl> </dd> </dl>await client.sessions.revoke("id");
id: string — ID of the session to revoke.
requestOptions: SessionsClient.RequestOptions
Retrieve the number of active users that logged in during the last 30 days.
</dd> </dl> </dd> </dl>await client.stats.getActiveUsersCount();
requestOptions: StatsClient.RequestOptions
Retrieve the number of logins, signups and breached-password detections (subscription required) that occurred each day within a specified date range.
</dd> </dl> </dd> </dl>await client.stats.getDaily({
from: "from",
to: "to",
});
request: Management.GetDailyStatsRequestParameters
requestOptions: StatsClient.RequestOptions
Get the supplemental signals configuration for a tenant.
</dd> </dl> </dd> </dl>await client.supplementalSignals.get();
requestOptions: SupplementalSignalsClient.RequestOptions
Update the supplemental signals configuration for a tenant.
</dd> </dl> </dd> </dl>await client.supplementalSignals.patch({
akamai_enabled: true,
});
request: Management.UpdateSupplementalSignalsRequestContent
requestOptions: SupplementalSignalsClient.RequestOptions
Create an email verification ticket for a given user. An email verification ticket is a generated URL that the user can consume to verify their email address.
</dd> </dl> </dd> </dl>await client.tickets.verifyEmail({
user_id: "user_id",
});
request: Management.VerifyEmailTicketRequestContent
requestOptions: TicketsClient.RequestOptions
Create a password change ticket for a given user. A password change ticket is a generated URL that the user can consume to start a reset password flow.
Note: This endpoint does not verify the given user’s identity. If you call this endpoint within your application, you must design your application to verify the user’s identity.
</dd> </dl> </dd> </dl>await client.tickets.changePassword();
request: Management.ChangePasswordTicketRequestContent
requestOptions: TicketsClient.RequestOptions
Retrieve a list of all Token Exchange Profiles available in your tenant.
By using this feature, you agree to the applicable Free Trial terms in <a href="https://www.okta.com/legal/">Okta’s Master Subscription Agreement</a>. It is your responsibility to securely validate the user’s subject_token. See <a href="https://auth0.com/docs/authenticate/custom-token-exchange">User Guide</a> for more details.
This endpoint supports Checkpoint pagination. To search by checkpoint, use the following parameters:
<ul> <li><code>from</code>: Optional id from which to start selection.</li> <li><code>take</code>: The total amount of entries to retrieve when using the from parameter. Defaults to 50.</li> </ul><b>Note</b>: The first time you call this endpoint using checkpoint pagination, omit the <code>from</code> parameter. If there are more results, a <code>next</code> value is included in the response. You can use this for subsequent API calls. When <code>next</code> is no longer included in the response, no pages are remaining.
</dd> </dl> </dd> </dl>const pageableResponse = await client.tokenExchangeProfiles.list({
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.tokenExchangeProfiles.list({
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.TokenExchangeProfilesListRequest
requestOptions: TokenExchangeProfilesClient.RequestOptions
Create a new Token Exchange Profile within your tenant.
By using this feature, you agree to the applicable Free Trial terms in <a href="https://www.okta.com/legal/">Okta’s Master Subscription Agreement</a>. It is your responsibility to securely validate the user’s subject_token. See <a href="https://auth0.com/docs/authenticate/custom-token-exchange">User Guide</a> for more details.
</dd> </dl> </dd> </dl>await client.tokenExchangeProfiles.create({
name: "name",
subject_token_type: "subject_token_type",
action_id: "action_id",
type: "custom_authentication",
});
request: Management.CreateTokenExchangeProfileRequestContent
requestOptions: TokenExchangeProfilesClient.RequestOptions
Retrieve details about a single Token Exchange Profile specified by ID.
By using this feature, you agree to the applicable Free Trial terms in <a href="https://www.okta.com/legal/">Okta’s Master Subscription Agreement</a>. It is your responsibility to securely validate the user’s subject_token. See <a href="https://auth0.com/docs/authenticate/custom-token-exchange">User Guide</a> for more details.
</dd> </dl> </dd> </dl>await client.tokenExchangeProfiles.get("id");
id: string — ID of the Token Exchange Profile to retrieve.
requestOptions: TokenExchangeProfilesClient.RequestOptions
Delete a Token Exchange Profile within your tenant.
By using this feature, you agree to the applicable Free Trial terms in <a href="https://www.okta.com/legal/">Okta's Master Subscription Agreement</a>. It is your responsibility to securely validate the user's subject_token. See <a href="https://auth0.com/docs/authenticate/custom-token-exchange">User Guide</a> for more details.
</dd> </dl> </dd> </dl>await client.tokenExchangeProfiles.delete("id");
id: string — ID of the Token Exchange Profile to delete.
requestOptions: TokenExchangeProfilesClient.RequestOptions
Update a Token Exchange Profile within your tenant.
By using this feature, you agree to the applicable Free Trial terms in <a href="https://www.okta.com/legal/">Okta's Master Subscription Agreement</a>. It is your responsibility to securely validate the user's subject_token. See <a href="https://auth0.com/docs/authenticate/custom-token-exchange">User Guide</a> for more details.
</dd> </dl> </dd> </dl>await client.tokenExchangeProfiles.update("id");
id: string — ID of the Token Exchange Profile to update.
request: Management.UpdateTokenExchangeProfileRequestContent
requestOptions: TokenExchangeProfilesClient.RequestOptions
Retrieve a list of User Attribute Profiles. This endpoint supports Checkpoint pagination.
</dd> </dl> </dd> </dl>const pageableResponse = await client.userAttributeProfiles.list({
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.userAttributeProfiles.list({
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListUserAttributeProfileRequestParameters
requestOptions: UserAttributeProfilesClient.RequestOptions
Create a User Attribute Profile
</dd> </dl> </dd> </dl>await client.userAttributeProfiles.create({
name: "name",
user_attributes: {
key: {
description: "description",
label: "label",
profile_required: true,
auth0_mapping: "auth0_mapping",
},
},
});
request: Management.CreateUserAttributeProfileRequestContent
requestOptions: UserAttributeProfilesClient.RequestOptions
Retrieve a list of User Attribute Profile Templates.
</dd> </dl> </dd> </dl>await client.userAttributeProfiles.listTemplates();
requestOptions: UserAttributeProfilesClient.RequestOptions
Retrieve a User Attribute Profile Template.
</dd> </dl> </dd> </dl>await client.userAttributeProfiles.getTemplate("id");
id: string — ID of the user-attribute-profile-template to retrieve.
requestOptions: UserAttributeProfilesClient.RequestOptions
Retrieve details about a single User Attribute Profile specified by ID.
</dd> </dl> </dd> </dl>await client.userAttributeProfiles.get("id");
id: string — ID of the user-attribute-profile to retrieve.
requestOptions: UserAttributeProfilesClient.RequestOptions
Delete a single User Attribute Profile specified by ID.
</dd> </dl> </dd> </dl>await client.userAttributeProfiles.delete("id");
id: string — ID of the user-attribute-profile to delete.
requestOptions: UserAttributeProfilesClient.RequestOptions
Update the details of a specific User attribute profile, such as name, user_id and user_attributes.
</dd> </dl> </dd> </dl>await client.userAttributeProfiles.update("id");
id: string — ID of the user attribute profile to update.
request: Management.UpdateUserAttributeProfileRequestContent
requestOptions: UserAttributeProfilesClient.RequestOptions
Retrieve details of all <a href="https://auth0.com/docs/secure/attack-protection/brute-force-protection">Brute-force Protection</a> blocks for a user with the given identifier (username, phone number, or email).
</dd> </dl> </dd> </dl>await client.userBlocks.listByIdentifier({
identifier: "identifier",
consider_brute_force_enablement: true,
});
request: Management.ListUserBlocksByIdentifierRequestParameters
requestOptions: UserBlocksClient.RequestOptions
Remove all <a href="https://auth0.com/docs/secure/attack-protection/brute-force-protection">Brute-force Protection</a> blocks for the user with the given identifier (username, phone number, or email).
Note: This endpoint does not unblock users that were <a href="https://auth0.com/docs/user-profile#block-and-unblock-a-user">blocked by a tenant administrator</a>.
</dd> </dl> </dd> </dl>await client.userBlocks.deleteByIdentifier({
identifier: "identifier",
});
request: Management.DeleteUserBlocksByIdentifierRequestParameters
requestOptions: UserBlocksClient.RequestOptions
Retrieve details of all <a href="https://auth0.com/docs/secure/attack-protection/brute-force-protection">Brute-force Protection</a> blocks for the user with the given ID.
</dd> </dl> </dd> </dl>await client.userBlocks.list("id", {
consider_brute_force_enablement: true,
});
id: string — user_id of the user blocks to retrieve.
request: Management.ListUserBlocksRequestParameters
requestOptions: UserBlocksClient.RequestOptions
Remove all <a href="https://auth0.com/docs/secure/attack-protection/brute-force-protection">Brute-force Protection</a> blocks for the user with the given ID.
Note: This endpoint does not unblock users that were <a href="https://auth0.com/docs/user-profile#block-and-unblock-a-user">blocked by a tenant administrator</a>.
</dd> </dl> </dd> </dl>await client.userBlocks.delete("id");
id: string — The user_id of the user to update.
requestOptions: UserBlocksClient.RequestOptions
Retrieve details of users. It is possible to:
<a href="https://auth0.com/docs/users/search/v3">Learn more about searching for users.</a>
Read about <a href="https://auth0.com/docs/users/search/best-practices">best practices</a> when working with the API endpoints for retrieving users.
Auth0 limits the number of users you can return. If you exceed this threshold, please redefine your search, use the <a href="https://auth0.com/docs/api/management/v2#!/Jobs/post_users_exports">export job</a>, or the <a href="https://auth0.com/docs/extensions/user-import-export">User Import / Export</a> extension.
</dd> </dl> </dd> </dl>const pageableResponse = await client.users.list({
page: 1,
per_page: 1,
include_totals: true,
sort: "sort",
connection: "connection",
fields: "fields",
include_fields: true,
q: "q",
search_engine: "v1",
primary_order: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.users.list({
page: 1,
per_page: 1,
include_totals: true,
sort: "sort",
connection: "connection",
fields: "fields",
include_fields: true,
q: "q",
search_engine: "v1",
primary_order: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListUsersRequestParameters
requestOptions: UsersClient.RequestOptions
Create a new user for a given <a href="https://auth0.com/docs/connections/database">database</a> or <a href="https://auth0.com/docs/connections/passwordless">passwordless</a> connection.
Note: <code>connection</code> is required but other parameters such as <code>email</code> and <code>password</code> are dependent upon the type of connection.
</dd> </dl> </dd> </dl>await client.users.create({
connection: "connection",
});
request: Management.CreateUserRequestContent
requestOptions: UsersClient.RequestOptions
Find users by email. If Auth0 is the identity provider (idP), the email address associated with a user is saved in lower case, regardless of how you initially provided it.
For example, if you register a user as [email protected], Auth0 saves the user's email as [email protected].
Therefore, when using this endpoint, make sure that you are searching for users via email addresses using the correct case.
</dd> </dl> </dd> </dl>await client.users.listUsersByEmail({
fields: "fields",
include_fields: true,
email: "email",
});
request: Management.ListUsersByEmailRequestParameters
requestOptions: UsersClient.RequestOptions
Retrieve user details. A list of fields to include or exclude may also be specified. For more information, see <a href="https://auth0.com/docs/manage-users/user-search/retrieve-users-with-get-users-endpoint">Retrieve Users with the Get Users Endpoint</a>.
</dd> </dl> </dd> </dl>await client.users.get("id", {
fields: "fields",
include_fields: true,
});
id: string — ID of the user to retrieve.
request: Management.GetUserRequestParameters
requestOptions: UsersClient.RequestOptions
Delete a user by user ID. This action cannot be undone. For Auth0 Dashboard instructions, see <a href="https://auth0.com/docs/manage-users/user-accounts/delete-users">Delete Users</a>.
</dd> </dl> </dd> </dl>await client.users.delete("id");
id: string — ID of the user to delete.
requestOptions: UsersClient.RequestOptions
Update a user.
These are the attributes that can be updated at the root level:
<ul> <li>app_metadata</li> <li>blocked</li> <li>email</li> <li>email_verified</li> <li>family_name</li> <li>given_name</li> <li>name</li> <li>nickname</li> <li>password</li> <li>phone_number</li> <li>phone_verified</li> <li>picture</li> <li>username</li> <li>user_metadata</li> <li>verify_email</li> </ul>Some considerations:
<ul> <li>The properties of the new object will replace the old ones.</li> <li>The metadata fields are an exception to this rule (<code>user_metadata</code> and <code>app_metadata</code>). These properties are merged instead of being replaced but be careful, the merge only occurs on the first level.</li> <li>If you are updating <code>email</code>, <code>email_verified</code>, <code>phone_number</code>, <code>phone_verified</code>, <code>username</code> or <code>password</code> of a secondary identity, you need to specify the <code>connection</code> property too.</li> <li>If you are updating <code>email</code> or <code>phone_number</code> you can specify, optionally, the <code>client_id</code> property.</li> <li>Updating <code>email_verified</code> is not supported for enterprise and passwordless sms connections.</li> <li>Updating the <code>blocked</code> to <code>false</code> does not affect the user's blocked state from an excessive amount of incorrectly provided credentials. Use the "Unblock a user" endpoint from the "User Blocks" API to change the user's state.</li> <li>Supported attributes can be unset by supplying <code>null</code> as the value.</li> </ul> <h5>Updating a field (non-metadata property)</h5> To mark the email address of a user as verified, the body to send should be: <pre><code>{ "email_verified": true }</code></pre> <h5>Updating a user metadata root property</h5>Let's assume that our test user has the following <code>user_metadata</code>: <pre><code>{ "user_metadata" : { "profileCode": 1479 } }</code></pre>To add the field <code>addresses</code> the body to send should be:
<pre><code>{ "user_metadata" : { "addresses": {"work_address": "100 Industrial Way"} }}</code></pre>The modified object ends up with the following <code>user_metadata</code> property:<pre><code>{ "user_metadata": { "profileCode": 1479, "addresses": { "work_address": "100 Industrial Way" } } }</code></pre>
<h5>Updating an inner user metadata property</h5>If there's existing user metadata to which we want to add <code>"home_address": "742 Evergreen Terrace"</code> (using the <code>addresses</code> property) we should send the whole <code>addresses</code> object. Since this is a first-level object, the object will be merged in, but its own properties will not be. The body to send should be: <pre><code>{ "user_metadata": { "addresses": { "work_address": "100 Industrial Way", "home_address": "742 Evergreen Terrace" } } }</code></pre>The modified object ends up with the following <code>user_metadata</code> property:
<pre><code>{ "user_metadata": { "profileCode": 1479, "addresses": { "work_address": "100 Industrial Way", "home_address": "742 Evergreen Terrace" } } }</code></pre> </dd> </dl> </dd> </dl>await client.users.update("id");
id: string — ID of the user to update.
request: Management.UpdateUserRequestContent
requestOptions: UsersClient.RequestOptions
Remove an existing multi-factor authentication (MFA) <a href="https://auth0.com/docs/secure/multi-factor-authentication/reset-user-mfa">recovery code</a> and generate a new one. If a user cannot access the original device or account used for MFA enrollment, they can use a recovery code to authenticate.
</dd> </dl> </dd> </dl>await client.users.regenerateRecoveryCode("id");
id: string — ID of the user to regenerate a multi-factor authentication recovery code for.
requestOptions: UsersClient.RequestOptions
Revokes selected resources related to a user (sessions, refresh tokens, ...).
</dd> </dl> </dd> </dl>await client.users.revokeAccess("id");
id: string — ID of the user.
request: Management.RevokeUserAccessRequestContent
requestOptions: UsersClient.RequestOptions
Retrieve all of an action's versions. An action version is created whenever an action is deployed. An action version is immutable, once created.
</dd> </dl> </dd> </dl>const pageableResponse = await client.actions.versions.list("actionId", {
page: 1,
per_page: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.actions.versions.list("actionId", {
page: 1,
per_page: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
actionId: string — The ID of the action.
request: Management.ListActionVersionsRequestParameters
requestOptions: VersionsClient.RequestOptions
Retrieve a specific version of an action. An action version is created whenever an action is deployed. An action version is immutable, once created.
</dd> </dl> </dd> </dl>await client.actions.versions.get("actionId", "id");
actionId: string — The ID of the action.
id: string — The ID of the action version.
requestOptions: VersionsClient.RequestOptions
Performs the equivalent of a roll-back of an action to an earlier, specified version. Creates a new, deployed action version that is identical to the specified version. If this action is currently bound to a trigger, the system will begin executing the newly-created version immediately.
</dd> </dl> </dd> </dl>await client.actions.versions.deploy("actionId", "id");
actionId: string — The ID of an action.
id: string — The ID of an action version.
request: Management.DeployActionVersionRequestContent | null
requestOptions: VersionsClient.RequestOptions
Retrieve information about a specific execution of a trigger. Relevant execution IDs will be included in tenant logs generated as part of that authentication flow. Executions will only be stored for 10 days after their creation.
</dd> </dl> </dd> </dl>await client.actions.executions.get("id");
id: string — The ID of the execution to retrieve.
requestOptions: ExecutionsClient.RequestOptions
Retrieve a paginated list of all Actions Modules with optional filtering and totals.
</dd> </dl> </dd> </dl>const pageableResponse = await client.actions.modules.list({
page: 1,
per_page: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.actions.modules.list({
page: 1,
per_page: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.GetActionModulesRequestParameters
requestOptions: ModulesClient.RequestOptions
Create a new Actions Module for reusable code across actions.
</dd> </dl> </dd> </dl>await client.actions.modules.create({
name: "name",
code: "code",
});
request: Management.CreateActionModuleRequestContent
requestOptions: ModulesClient.RequestOptions
Retrieve details of a specific Actions Module by its unique identifier.
</dd> </dl> </dd> </dl>await client.actions.modules.get("id");
id: string — The ID of the action module to retrieve.
requestOptions: ModulesClient.RequestOptions
Permanently delete an Actions Module. This will fail if the module is still in use by any actions.
</dd> </dl> </dd> </dl>await client.actions.modules.delete("id");
id: string — The ID of the Actions Module to delete.
requestOptions: ModulesClient.RequestOptions
Update properties of an existing Actions Module, such as code, dependencies, or secrets.
</dd> </dl> </dd> </dl>await client.actions.modules.update("id");
id: string — The ID of the action module to update.
request: Management.UpdateActionModuleRequestContent
requestOptions: ModulesClient.RequestOptions
Lists all actions that are using a specific Actions Module, showing which deployed action versions reference this Actions Module.
</dd> </dl> </dd> </dl>const pageableResponse = await client.actions.modules.listActions("id", {
page: 1,
per_page: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.actions.modules.listActions("id", {
page: 1,
per_page: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — The unique ID of the module.
request: Management.GetActionModuleActionsRequestParameters
requestOptions: ModulesClient.RequestOptions
Rolls back an Actions Module's draft to a previously created version. This action copies the code, dependencies, and secrets from the specified version into the current draft.
</dd> </dl> </dd> </dl>await client.actions.modules.rollback("id", {
module_version_id: "module_version_id",
});
id: string — The unique ID of the module to roll back.
request: Management.RollbackActionModuleRequestParameters
requestOptions: ModulesClient.RequestOptions
Retrieve the set of triggers currently available within actions. A trigger is an extensibility point to which actions can be bound.
</dd> </dl> </dd> </dl>await client.actions.triggers.list();
requestOptions: TriggersClient.RequestOptions
List all published versions of a specific Actions Module.
</dd> </dl> </dd> </dl>const pageableResponse = await client.actions.modules.versions.list("id", {
page: 1,
per_page: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.actions.modules.versions.list("id", {
page: 1,
per_page: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — The unique ID of the module.
request: Management.GetActionModuleVersionsRequestParameters
requestOptions: VersionsClient.RequestOptions
Creates a new immutable version of an Actions Module from the current draft version. This publishes the draft as a new version that can be referenced by actions, while maintaining the existing draft for continued development.
</dd> </dl> </dd> </dl>await client.actions.modules.versions.create("id");
id: string — The ID of the action module to create a version for.
requestOptions: VersionsClient.RequestOptions
Retrieve the details of a specific, immutable version of an Actions Module.
</dd> </dl> </dd> </dl>await client.actions.modules.versions.get("id", "versionId");
id: string — The unique ID of the module.
versionId: string — The unique ID of the module version to retrieve.
requestOptions: VersionsClient.RequestOptions
Retrieve the actions that are bound to a trigger. Once an action is created and deployed, it must be attached (i.e. bound) to a trigger so that it will be executed as part of a flow. The list of actions returned reflects the order in which they will be executed during the appropriate flow.
</dd> </dl> </dd> </dl>const pageableResponse = await client.actions.triggers.bindings.list("post-login", {
page: 1,
per_page: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.actions.triggers.bindings.list("post-login", {
page: 1,
per_page: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
triggerId: Management.ActionTriggerTypeEnum — An actions extensibility point.
request: Management.ListActionTriggerBindingsRequestParameters
requestOptions: BindingsClient.RequestOptions
Update the actions that are bound (i.e. attached) to a trigger. Once an action is created and deployed, it must be attached (i.e. bound) to a trigger so that it will be executed as part of a flow. The order in which the actions are provided will determine the order in which they are executed.
</dd> </dl> </dd> </dl>await client.actions.triggers.bindings.updateMany("post-login");
triggerId: Management.ActionTriggerTypeEnum — An actions extensibility point.
request: Management.UpdateActionBindingsRequestContent
requestOptions: BindingsClient.RequestOptions
Check if the given IP address is blocked via the <a href="https://auth0.com/docs/configure/attack-protection/suspicious-ip-throttling">Suspicious IP Throttling</a> due to multiple suspicious attempts.
</dd> </dl> </dd> </dl>await client.anomaly.blocks.checkIp("id");
id: Management.AnomalyIpFormat — IP address to check.
requestOptions: BlocksClient.RequestOptions
Remove a block imposed by <a href="https://auth0.com/docs/configure/attack-protection/suspicious-ip-throttling">Suspicious IP Throttling</a> for the given IP address.
</dd> </dl> </dd> </dl>await client.anomaly.blocks.unblockIp("id");
id: Management.AnomalyIpFormat — IP address to unblock.
requestOptions: BlocksClient.RequestOptions
Get the Bot Detection configuration of your tenant.
</dd> </dl> </dd> </dl>await client.attackProtection.botDetection.get();
requestOptions: BotDetectionClient.RequestOptions
Update the Bot Detection configuration of your tenant.
</dd> </dl> </dd> </dl>await client.attackProtection.botDetection.update();
request: Management.UpdateBotDetectionSettingsRequestContent
requestOptions: BotDetectionClient.RequestOptions
Retrieve details of the Breached Password Detection configuration of your tenant.
</dd> </dl> </dd> </dl>await client.attackProtection.breachedPasswordDetection.get();
requestOptions: BreachedPasswordDetectionClient.RequestOptions
Update details of the Breached Password Detection configuration of your tenant.
</dd> </dl> </dd> </dl>await client.attackProtection.breachedPasswordDetection.update();
request: Management.UpdateBreachedPasswordDetectionSettingsRequestContent
requestOptions: BreachedPasswordDetectionClient.RequestOptions
Retrieve details of the Brute-force Protection configuration of your tenant.
</dd> </dl> </dd> </dl>await client.attackProtection.bruteForceProtection.get();
requestOptions: BruteForceProtectionClient.RequestOptions
Update the Brute-force Protection configuration of your tenant.
</dd> </dl> </dd> </dl>await client.attackProtection.bruteForceProtection.update();
request: Management.UpdateBruteForceSettingsRequestContent
requestOptions: BruteForceProtectionClient.RequestOptions
Get the CAPTCHA configuration for your client.
</dd> </dl> </dd> </dl>await client.attackProtection.captcha.get();
requestOptions: CaptchaClient.RequestOptions
Update existing CAPTCHA configuration for your client.
</dd> </dl> </dd> </dl>await client.attackProtection.captcha.update();
request: Management.UpdateAttackProtectionCaptchaRequestContent
requestOptions: CaptchaClient.RequestOptions
Retrieve details of the Suspicious IP Throttling configuration of your tenant.
</dd> </dl> </dd> </dl>await client.attackProtection.suspiciousIpThrottling.get();
requestOptions: SuspiciousIpThrottlingClient.RequestOptions
Update the details of the Suspicious IP Throttling configuration of your tenant.
</dd> </dl> </dd> </dl>await client.attackProtection.suspiciousIpThrottling.update();
request: Management.UpdateSuspiciousIpThrottlingSettingsRequestContent
requestOptions: SuspiciousIpThrottlingClient.RequestOptions
await client.branding.templates.getUniversalLogin();
requestOptions: TemplatesClient.RequestOptions
Update the Universal Login branding template.
<p>When <code>content-type</code> header is set to <code>application/json</code>:</p> <pre> { "template": "<!DOCTYPE html>{% assign resolved_dir = dir | default: "auto" %}<html lang="{{locale}}" dir="{{resolved_dir}}"><head>{%- auth0:head -%}</head><body class="_widget-auto-layout">{%- auth0:widget -%}</body></html>" } </pre> <p> When <code>content-type</code> header is set to <code>text/html</code>: </p> <pre> <!DOCTYPE html> {% assign resolved_dir = dir | default: "auto" %} <html lang="{{locale}}" dir="{{resolved_dir}}"> <head> {%- auth0:head -%} </head> <body class="_widget-auto-layout"> {%- auth0:widget -%} </body> </html> </pre> </dd> </dl> </dd> </dl>await client.branding.templates.updateUniversalLogin("string");
request: Management.UpdateUniversalLoginTemplateRequestContent
requestOptions: TemplatesClient.RequestOptions
await client.branding.templates.deleteUniversalLogin();
requestOptions: TemplatesClient.RequestOptions
Create branding theme.
</dd> </dl> </dd> </dl>await client.branding.themes.create({
borders: {
button_border_radius: 1.1,
button_border_weight: 1.1,
buttons_style: "pill",
input_border_radius: 1.1,
input_border_weight: 1.1,
inputs_style: "pill",
show_widget_shadow: true,
widget_border_weight: 1.1,
widget_corner_radius: 1.1,
},
colors: {
body_text: "body_text",
error: "error",
header: "header",
icons: "icons",
input_background: "input_background",
input_border: "input_border",
input_filled_text: "input_filled_text",
input_labels_placeholders: "input_labels_placeholders",
links_focused_components: "links_focused_components",
primary_button: "primary_button",
primary_button_label: "primary_button_label",
secondary_button_border: "secondary_button_border",
secondary_button_label: "secondary_button_label",
success: "success",
widget_background: "widget_background",
widget_border: "widget_border",
},
fonts: {
body_text: {
bold: true,
size: 1.1,
},
buttons_text: {
bold: true,
size: 1.1,
},
font_url: "font_url",
input_labels: {
bold: true,
size: 1.1,
},
links: {
bold: true,
size: 1.1,
},
links_style: "normal",
reference_text_size: 1.1,
subtitle: {
bold: true,
size: 1.1,
},
title: {
bold: true,
size: 1.1,
},
},
page_background: {
background_color: "background_color",
background_image_url: "background_image_url",
page_layout: "center",
},
widget: {
header_text_alignment: "center",
logo_height: 1.1,
logo_position: "center",
logo_url: "logo_url",
social_buttons_layout: "bottom",
},
});
request: Management.CreateBrandingThemeRequestContent
requestOptions: ThemesClient.RequestOptions
Retrieve default branding theme.
</dd> </dl> </dd> </dl>await client.branding.themes.getDefault();
requestOptions: ThemesClient.RequestOptions
Retrieve branding theme.
</dd> </dl> </dd> </dl>await client.branding.themes.get("themeId");
themeId: string — The ID of the theme
requestOptions: ThemesClient.RequestOptions
Delete branding theme.
</dd> </dl> </dd> </dl>await client.branding.themes.delete("themeId");
themeId: string — The ID of the theme
requestOptions: ThemesClient.RequestOptions
Update branding theme.
</dd> </dl> </dd> </dl>await client.branding.themes.update("themeId", {
borders: {
button_border_radius: 1.1,
button_border_weight: 1.1,
buttons_style: "pill",
input_border_radius: 1.1,
input_border_weight: 1.1,
inputs_style: "pill",
show_widget_shadow: true,
widget_border_weight: 1.1,
widget_corner_radius: 1.1,
},
colors: {
body_text: "body_text",
error: "error",
header: "header",
icons: "icons",
input_background: "input_background",
input_border: "input_border",
input_filled_text: "input_filled_text",
input_labels_placeholders: "input_labels_placeholders",
links_focused_components: "links_focused_components",
primary_button: "primary_button",
primary_button_label: "primary_button_label",
secondary_button_border: "secondary_button_border",
secondary_button_label: "secondary_button_label",
success: "success",
widget_background: "widget_background",
widget_border: "widget_border",
},
fonts: {
body_text: {
bold: true,
size: 1.1,
},
buttons_text: {
bold: true,
size: 1.1,
},
font_url: "font_url",
input_labels: {
bold: true,
size: 1.1,
},
links: {
bold: true,
size: 1.1,
},
links_style: "normal",
reference_text_size: 1.1,
subtitle: {
bold: true,
size: 1.1,
},
title: {
bold: true,
size: 1.1,
},
},
page_background: {
background_color: "background_color",
background_image_url: "background_image_url",
page_layout: "center",
},
widget: {
header_text_alignment: "center",
logo_height: 1.1,
logo_position: "center",
logo_url: "logo_url",
social_buttons_layout: "bottom",
},
});
themeId: string — The ID of the theme
request: Management.UpdateBrandingThemeRequestContent
requestOptions: ThemesClient.RequestOptions
Retrieve a list of <a href="https://auth0.com/docs/customize/phone-messages/configure-phone-messaging-providers">phone providers</a> details set for a Tenant. A list of fields to include or exclude may also be specified.
</dd> </dl> </dd> </dl>await client.branding.phone.providers.list({
disabled: true,
});
request: Management.ListBrandingPhoneProvidersRequestParameters
requestOptions: ProvidersClient.RequestOptions
Create a <a href="https://auth0.com/docs/customize/phone-messages/configure-phone-messaging-providers">phone provider</a>. The <code>credentials</code> object requires different properties depending on the phone provider (which is specified using the <code>name</code> property).
</dd> </dl> </dd> </dl>await client.branding.phone.providers.create({
name: "twilio",
credentials: {
auth_token: "auth_token",
},
});
request: Management.CreateBrandingPhoneProviderRequestContent
requestOptions: ProvidersClient.RequestOptions
Retrieve <a href="https://auth0.com/docs/customize/phone-messages/configure-phone-messaging-providers">phone provider</a> details. A list of fields to include or exclude may also be specified.
</dd> </dl> </dd> </dl>await client.branding.phone.providers.get("id");
id: string
requestOptions: ProvidersClient.RequestOptions
Delete the configured phone provider.
</dd> </dl> </dd> </dl>await client.branding.phone.providers.delete("id");
id: string
requestOptions: ProvidersClient.RequestOptions
Update a <a href="https://auth0.com/docs/customize/phone-messages/configure-phone-messaging-providers">phone provider</a>. The <code>credentials</code> object requires different properties depending on the phone provider (which is specified using the <code>name</code> property).
</dd> </dl> </dd> </dl>await client.branding.phone.providers.update("id");
id: string
request: Management.UpdateBrandingPhoneProviderRequestContent
requestOptions: ProvidersClient.RequestOptions
await client.branding.phone.providers.test("id", {
to: "to",
});
id: string
request: Management.CreatePhoneProviderSendTestRequestContent
requestOptions: ProvidersClient.RequestOptions
await client.branding.phone.templates.list({
disabled: true,
});
request: Management.ListPhoneTemplatesRequestParameters
requestOptions: TemplatesClient.RequestOptions
await client.branding.phone.templates.create();
request: Management.CreatePhoneTemplateRequestContent
requestOptions: TemplatesClient.RequestOptions
await client.branding.phone.templates.get("id");
id: string
requestOptions: TemplatesClient.RequestOptions
await client.branding.phone.templates.delete("id");
id: string
requestOptions: TemplatesClient.RequestOptions
await client.branding.phone.templates.update("id");
id: string
request: Management.UpdatePhoneTemplateRequestContent
requestOptions: TemplatesClient.RequestOptions
await client.branding.phone.templates.reset("id", {
key: "value",
});
id: string
request: Management.ResetPhoneTemplateRequestContent
requestOptions: TemplatesClient.RequestOptions
await client.branding.phone.templates.test("id", {
to: "to",
});
id: string
request: Management.CreatePhoneTemplateTestNotificationRequestContent
requestOptions: TemplatesClient.RequestOptions
const pageableResponse = await client.clientGrants.organizations.list("id", {
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.clientGrants.organizations.list("id", {
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — ID of the client grant
request: Management.ListClientGrantOrganizationsRequestParameters
requestOptions: OrganizationsClient.RequestOptions
Get the details of a client credential.
<b>Important</b>: To enable credentials to be used for a client authentication method, set the <code>client_authentication_methods</code> property on the client. To enable credentials to be used for JWT-Secured Authorization requests set the <code>signed_request_object</code> property on the client.
</dd> </dl> </dd> </dl>await client.clients.credentials.list("client_id");
client_id: string — ID of the client.
requestOptions: CredentialsClient.RequestOptions
Create a client credential associated to your application. Credentials can be used to configure Private Key JWT and mTLS authentication methods, as well as for JWT-secured Authorization requests.
<h5>Public Key</h5>Public Key credentials can be used to set up Private Key JWT client authentication and JWT-secured Authorization requests.Sample: <pre><code>{ "credential_type": "public_key", "name": "string", "pem": "string", "alg": "RS256", "parse_expiry_from_cert": false, "expires_at": "2022-12-31T23:59:59Z" }</code></pre>
<h5>Certificate (CA-signed & self-signed)</h5>Certificate credentials can be used to set up mTLS client authentication. CA-signed certificates can be configured either with a signed certificate or with just the certificate Subject DN.CA-signed Certificate Sample (pem): <pre><code>{ "credential_type": "x509_cert", "name": "string", "pem": "string" }</code></pre>CA-signed Certificate Sample (subject_dn): <pre><code>{ "credential_type": "cert_subject_dn", "name": "string", "subject_dn": "string" }</code></pre>Self-signed Certificate Sample: <pre><code>{ "credential_type": "cert_subject_dn", "name": "string", "pem": "string" }</code></pre>
The credential will be created but not yet enabled for use until you set the corresponding properties in the client:
<ul> <li>To enable the credential for Private Key JWT or mTLS authentication methods, set the <code>client_authentication_methods</code> property on the client. For more information, read <a href="https://auth0.com/docs/get-started/applications/configure-private-key-jwt">Configure Private Key JWT Authentication</a> and <a href="https://auth0.com/docs/get-started/applications/configure-mtls">Configure mTLS Authentication</a></li> <li>To enable the credential for JWT-secured Authorization requests, set the <code>signed_request_object</code>property on the client. For more information, read <a href="https://auth0.com/docs/get-started/applications/configure-jar">Configure JWT-secured Authorization Requests (JAR)</a></li> </ul> </dd> </dl> </dd> </dl>await client.clients.credentials.create("client_id", {
credential_type: "public_key",
});
client_id: string — ID of the client.
request: Management.PostClientCredentialRequestContent
requestOptions: CredentialsClient.RequestOptions
Get the details of a client credential.
<b>Important</b>: To enable credentials to be used for a client authentication method, set the <code>client_authentication_methods</code> property on the client. To enable credentials to be used for JWT-Secured Authorization requests set the <code>signed_request_object</code> property on the client.
</dd> </dl> </dd> </dl>await client.clients.credentials.get("client_id", "credential_id");
client_id: string — ID of the client.
credential_id: string — ID of the credential.
requestOptions: CredentialsClient.RequestOptions
Delete a client credential you previously created. May be enabled or disabled. For more information, read <a href="https://www.auth0.com/docs/get-started/authentication-and-authorization-flow/client-credentials-flow">Client Credential Flow</a>.
</dd> </dl> </dd> </dl>await client.clients.credentials.delete("client_id", "credential_id");
client_id: string — ID of the client.
credential_id: string — ID of the credential to delete.
requestOptions: CredentialsClient.RequestOptions
Change a client credential you previously created. May be enabled or disabled. For more information, read <a href="https://www.auth0.com/docs/get-started/authentication-and-authorization-flow/client-credentials-flow">Client Credential Flow</a>.
</dd> </dl> </dd> </dl>await client.clients.credentials.update("client_id", "credential_id");
client_id: string — ID of the client.
credential_id: string — ID of the credential.
request: Management.PatchClientCredentialRequestContent
requestOptions: CredentialsClient.RequestOptions
Retrieve all connections that are enabled for the specified <a href="https://www.auth0.com/docs/get-started/applications"> Application</a>, using checkpoint pagination. A list of fields to include or exclude for each connection may also be specified.
<ul> <li> This endpoint requires the <code>read:connections</code> scope and any one of <code>read:clients</code> or <code>read:client_summary</code>. </li> <li> <b>Note</b>: The first time you call this endpoint, omit the <code>from</code> parameter. If there are more results, a <code>next</code> value is included in the response. You can use this for subsequent API calls. When <code>next</code> is no longer included in the response, no further results are remaining. </li> </ul> </dd> </dl> </dd> </dl>const pageableResponse = await client.clients.connections.get("id", {
strategy: ["ad"],
from: "from",
take: 1,
fields: "fields",
include_fields: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.clients.connections.get("id", {
strategy: ["ad"],
from: "from",
take: 1,
fields: "fields",
include_fields: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — ID of the client for which to retrieve enabled connections.
request: Management.ConnectionsGetRequest
requestOptions: ConnectionsClient.RequestOptions
Retrieve a list of directory provisioning configurations of a tenant.
</dd> </dl> </dd> </dl>const pageableResponse = await client.connections.directoryProvisioning.list({
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.connections.directoryProvisioning.list({
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListDirectoryProvisioningsRequestParameters
requestOptions: DirectoryProvisioningClient.RequestOptions
Retrieve the directory provisioning configuration of a connection.
</dd> </dl> </dd> </dl>await client.connections.directoryProvisioning.get("id");
id: string — The id of the connection to retrieve its directory provisioning configuration
requestOptions: DirectoryProvisioningClient.RequestOptions
Create a directory provisioning configuration for a connection.
</dd> </dl> </dd> </dl>await client.connections.directoryProvisioning.create("id");
id: string — The id of the connection to create its directory provisioning configuration
request: Management.CreateDirectoryProvisioningRequestContent | null
requestOptions: DirectoryProvisioningClient.RequestOptions
Delete the directory provisioning configuration of a connection.
</dd> </dl> </dd> </dl>await client.connections.directoryProvisioning.delete("id");
id: string — The id of the connection to delete its directory provisioning configuration
requestOptions: DirectoryProvisioningClient.RequestOptions
Update the directory provisioning configuration of a connection.
</dd> </dl> </dd> </dl>await client.connections.directoryProvisioning.update("id");
id: string — The id of the connection to create its directory provisioning configuration
request: Management.UpdateDirectoryProvisioningRequestContent | null
requestOptions: DirectoryProvisioningClient.RequestOptions
Retrieve the directory provisioning default attribute mapping of a connection.
</dd> </dl> </dd> </dl>await client.connections.directoryProvisioning.getDefaultMapping("id");
id: string — The id of the connection to retrieve its directory provisioning configuration
requestOptions: DirectoryProvisioningClient.RequestOptions
Retrieve the configured synchronized groups for a connection directory provisioning configuration.
</dd> </dl> </dd> </dl>const pageableResponse = await client.connections.directoryProvisioning.listSynchronizedGroups("id", {
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.connections.directoryProvisioning.listSynchronizedGroups("id", {
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — The id of the connection to list synchronized groups for.
request: Management.ListSynchronizedGroupsRequestParameters
requestOptions: DirectoryProvisioningClient.RequestOptions
Create or replace the selected groups for a connection directory provisioning configuration.
</dd> </dl> </dd> </dl>await client.connections.directoryProvisioning.set("id", {
groups: [
{
id: "id",
},
],
});
id: string — The id of the connection to create or replace synchronized groups for
request: Management.ReplaceSynchronizedGroupsRequestContent
requestOptions: DirectoryProvisioningClient.RequestOptions
Retrieve a list of SCIM configurations of a tenant.
</dd> </dl> </dd> </dl>const pageableResponse = await client.connections.scimConfiguration.list({
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.connections.scimConfiguration.list({
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListScimConfigurationsRequestParameters
requestOptions: ScimConfigurationClient.RequestOptions
Retrieves a scim configuration by its <code>connectionId</code>.
</dd> </dl> </dd> </dl>await client.connections.scimConfiguration.get("id");
id: string — The id of the connection to retrieve its SCIM configuration
requestOptions: ScimConfigurationClient.RequestOptions
Create a scim configuration for a connection.
</dd> </dl> </dd> </dl>await client.connections.scimConfiguration.create("id");
id: string — The id of the connection to create its SCIM configuration
request: Management.CreateScimConfigurationRequestContent | null
requestOptions: ScimConfigurationClient.RequestOptions
Deletes a scim configuration by its <code>connectionId</code>.
</dd> </dl> </dd> </dl>await client.connections.scimConfiguration.delete("id");
id: string — The id of the connection to delete its SCIM configuration
requestOptions: ScimConfigurationClient.RequestOptions
Update a scim configuration by its <code>connectionId</code>.
</dd> </dl> </dd> </dl>await client.connections.scimConfiguration.update("id", {
user_id_attribute: "user_id_attribute",
mapping: [{}],
});
id: string — The id of the connection to update its SCIM configuration
request: Management.UpdateScimConfigurationRequestContent
requestOptions: ScimConfigurationClient.RequestOptions
Retrieves a scim configuration's default mapping by its <code>connectionId</code>.
</dd> </dl> </dd> </dl>await client.connections.scimConfiguration.getDefaultMapping("id");
id: string — The id of the connection to retrieve its default SCIM mapping
requestOptions: ScimConfigurationClient.RequestOptions
Retrieve all clients that have the specified <a href="https://auth0.com/docs/authenticate/identity-providers">connection</a> enabled.
<b>Note</b>: The first time you call this endpoint, omit the <code>from</code> parameter. If there are more results, a <code>next</code> value is included in the response. You can use this for subsequent API calls. When <code>next</code> is no longer included in the response, no further results are remaining.
</dd> </dl> </dd> </dl>const pageableResponse = await client.connections.clients.get("id", {
take: 1,
from: "from",
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.connections.clients.get("id", {
take: 1,
from: "from",
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — The id of the connection for which enabled clients are to be retrieved
request: Management.GetConnectionEnabledClientsRequestParameters
requestOptions: ClientsClient.RequestOptions
await client.connections.clients.update("id", [
{
client_id: "client_id",
status: true,
},
]);
id: string — The id of the connection to modify
request: Management.UpdateEnabledClientConnectionsRequestContent
requestOptions: ClientsClient.RequestOptions
Gets the connection keys for the Okta or OIDC connection strategy.
</dd> </dl> </dd> </dl>await client.connections.keys.get("id");
id: string — ID of the connection
requestOptions: KeysClient.RequestOptions
Provision initial connection keys for Okta or OIDC connection strategies. This endpoint allows you to create keys before configuring the connection to use Private Key JWT authentication, enabling zero-downtime transitions.
</dd> </dl> </dd> </dl>await client.connections.keys.create("id");
id: string — ID of the connection
request: Management.PostConnectionKeysRequestContent | null
requestOptions: KeysClient.RequestOptions
Rotates the connection keys for the Okta or OIDC connection strategies.
</dd> </dl> </dd> </dl>await client.connections.keys.rotate("id");
id: string — ID of the connection
request: Management.RotateConnectionKeysRequestContent | null
requestOptions: KeysClient.RequestOptions
Deletes a specified connection user by its email (you cannot delete all users from specific connection). Currently, only Database Connections are supported.
</dd> </dl> </dd> </dl>await client.connections.users.deleteByEmail("id", {
email: "email",
});
id: string — The id of the connection (currently only database connections are supported)
request: Management.DeleteConnectionUsersByEmailQueryParameters
requestOptions: UsersClient.RequestOptions
Request an on-demand synchronization of the directory.
</dd> </dl> </dd> </dl>await client.connections.directoryProvisioning.synchronizations.create("id");
id: string — The id of the connection to trigger synchronization for
requestOptions: SynchronizationsClient.RequestOptions
Retrieves all scim tokens by its connection <code>id</code>.
</dd> </dl> </dd> </dl>await client.connections.scimConfiguration.tokens.get("id");
id: string — The id of the connection to retrieve its SCIM configuration
requestOptions: TokensClient.RequestOptions
Create a scim token for a scim client.
</dd> </dl> </dd> </dl>await client.connections.scimConfiguration.tokens.create("id");
id: string — The id of the connection to create its SCIM token
request: Management.CreateScimTokenRequestContent
requestOptions: TokensClient.RequestOptions
Deletes a scim token by its connection <code>id</code> and <code>tokenId</code>.
</dd> </dl> </dd> </dl>await client.connections.scimConfiguration.tokens.delete("id", "tokenId");
id: string — The connection id that owns the SCIM token to delete
tokenId: string — The id of the scim token to delete
requestOptions: TokensClient.RequestOptions
Retrieve details of the <a href="https://auth0.com/docs/customize/email/smtp-email-providers">email provider configuration</a> in your tenant. A list of fields to include or exclude may also be specified.
</dd> </dl> </dd> </dl>await client.emails.provider.get({
fields: "fields",
include_fields: true,
});
request: Management.GetEmailProviderRequestParameters
requestOptions: ProviderClient.RequestOptions
Create an <a href="https://auth0.com/docs/email/providers">email provider</a>. The <code>credentials</code> object requires different properties depending on the email provider (which is specified using the <code>name</code> property):
<ul> <li><code>mandrill</code> requires <code>api_key</code></li> <li><code>sendgrid</code> requires <code>api_key</code></li> <li> <code>sparkpost</code> requires <code>api_key</code>. Optionally, set <code>region</code> to <code>eu</code> to use the SparkPost service hosted in Western Europe; set to <code>null</code> to use the SparkPost service hosted in North America. <code>eu</code> or <code>null</code> are the only valid values for <code>region</code>. </li> <li> <code>mailgun</code> requires <code>api_key</code> and <code>domain</code>. Optionally, set <code>region</code> to <code>eu</code> to use the Mailgun service hosted in Europe; set to <code>null</code> otherwise. <code>eu</code> or <code>null</code> are the only valid values for <code>region</code>. </li> <li><code>ses</code> requires <code>accessKeyId</code>, <code>secretAccessKey</code>, and <code>region</code></li> <li> <code>smtp</code> requires <code>smtp_host</code>, <code>smtp_port</code>, <code>smtp_user</code>, and <code>smtp_pass</code> </li> </ul> Depending on the type of provider it is possible to specify <code>settings</code> object with different configuration options, which will be used when sending an email: <ul> <li> <code>smtp</code> provider, <code>settings</code> may contain <code>headers</code> object. <ul> <li> When using AWS SES SMTP host, you may provide a name of configuration set in <code>X-SES-Configuration-Set</code> header. Value must be a string. </li> <li> When using Sparkpost host, you may provide value for <code>X-MSYS_API</code> header. Value must be an object. </li> </ul> </li> <li> for <code>ses</code> provider, <code>settings</code> may contain <code>message</code> object, where you can provide a name of configuration set in <code>configuration_set_name</code> property. Value must be a string. </li> </ul> </dd> </dl> </dd> </dl>await client.emails.provider.create({
name: "mailgun",
credentials: {
api_key: "api_key",
},
});
request: Management.CreateEmailProviderRequestContent
requestOptions: ProviderClient.RequestOptions
Delete the email provider.
</dd> </dl> </dd> </dl>await client.emails.provider.delete();
requestOptions: ProviderClient.RequestOptions
Update an <a href="https://auth0.com/docs/email/providers">email provider</a>. The <code>credentials</code> object requires different properties depending on the email provider (which is specified using the <code>name</code> property):
<ul> <li><code>mandrill</code> requires <code>api_key</code></li> <li><code>sendgrid</code> requires <code>api_key</code></li> <li> <code>sparkpost</code> requires <code>api_key</code>. Optionally, set <code>region</code> to <code>eu</code> to use the SparkPost service hosted in Western Europe; set to <code>null</code> to use the SparkPost service hosted in North America. <code>eu</code> or <code>null</code> are the only valid values for <code>region</code>. </li> <li> <code>mailgun</code> requires <code>api_key</code> and <code>domain</code>. Optionally, set <code>region</code> to <code>eu</code> to use the Mailgun service hosted in Europe; set to <code>null</code> otherwise. <code>eu</code> or <code>null</code> are the only valid values for <code>region</code>. </li> <li><code>ses</code> requires <code>accessKeyId</code>, <code>secretAccessKey</code>, and <code>region</code></li> <li> <code>smtp</code> requires <code>smtp_host</code>, <code>smtp_port</code>, <code>smtp_user</code>, and <code>smtp_pass</code> </li> </ul> Depending on the type of provider it is possible to specify <code>settings</code> object with different configuration options, which will be used when sending an email: <ul> <li> <code>smtp</code> provider, <code>settings</code> may contain <code>headers</code> object. <ul> <li> When using AWS SES SMTP host, you may provide a name of configuration set in <code>X-SES-Configuration-Set</code> header. Value must be a string. </li> <li> When using Sparkpost host, you may provide value for <code>X-MSYS_API</code> header. Value must be an object. </li> </ul> for <code>ses</code> provider, <code>settings</code> may contain <code>message</code> object, where you can provide a name of configuration set in <code>configuration_set_name</code> property. Value must be a string. </li> </ul> </dd> </dl> </dd> </dl>await client.emails.provider.update();
request: Management.UpdateEmailProviderRequestContent
requestOptions: ProviderClient.RequestOptions
await client.eventStreams.deliveries.list("id", {
statuses: "statuses",
event_types: "event_types",
date_from: "date_from",
date_to: "date_to",
from: "from",
take: 1,
});
id: string — Unique identifier for the event stream.
request: Management.ListEventStreamDeliveriesRequestParameters
requestOptions: DeliveriesClient.RequestOptions
await client.eventStreams.deliveries.getHistory("id", "event_id");
id: string — Unique identifier for the event stream.
event_id: string — Unique identifier for the event
requestOptions: DeliveriesClient.RequestOptions
await client.eventStreams.redeliveries.create("id");
id: string — Unique identifier for the event stream.
request: Management.CreateEventStreamRedeliveryRequestContent
requestOptions: RedeliveriesClient.RequestOptions
await client.eventStreams.redeliveries.createById("id", "event_id");
id: string — Unique identifier for the event stream.
event_id: string — Unique identifier for the event
requestOptions: RedeliveriesClient.RequestOptions
const pageableResponse = await client.flows.executions.list("flow_id", {
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.flows.executions.list("flow_id", {
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
flow_id: string — Flow id
request: Management.ListFlowExecutionsRequestParameters
requestOptions: ExecutionsClient.RequestOptions
await client.flows.executions.get("flow_id", "execution_id", {
hydrate: ["debug"],
});
flow_id: string — Flow id
execution_id: string — Flow execution id
request: Management.GetFlowExecutionRequestParameters
requestOptions: ExecutionsClient.RequestOptions
await client.flows.executions.delete("flow_id", "execution_id");
flow_id: string — Flows id
execution_id: string — Flow execution identifier
requestOptions: ExecutionsClient.RequestOptions
const pageableResponse = await client.flows.vault.connections.list({
page: 1,
per_page: 1,
include_totals: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.flows.vault.connections.list({
page: 1,
per_page: 1,
include_totals: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListFlowsVaultConnectionsRequestParameters
requestOptions: ConnectionsClient.RequestOptions
await client.flows.vault.connections.create({
name: "name",
app_id: "ACTIVECAMPAIGN",
setup: {
type: "API_KEY",
api_key: "api_key",
base_url: "base_url",
},
});
request: Management.CreateFlowsVaultConnectionRequestContent
requestOptions: ConnectionsClient.RequestOptions
await client.flows.vault.connections.get("id");
id: string — Flows Vault connection ID
requestOptions: ConnectionsClient.RequestOptions
await client.flows.vault.connections.delete("id");
id: string — Vault connection id
requestOptions: ConnectionsClient.RequestOptions
await client.flows.vault.connections.update("id");
id: string — Flows Vault connection ID
request: Management.UpdateFlowsVaultConnectionRequestContent
requestOptions: ConnectionsClient.RequestOptions
List all users that are a member of this group.
</dd> </dl> </dd> </dl>const pageableResponse = await client.groups.members.get("id", {
fields: "fields",
include_fields: true,
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.groups.members.get("id", {
fields: "fields",
include_fields: true,
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — Unique identifier for the group (service-generated).
request: Management.GetGroupMembersRequestParameters
requestOptions: MembersClient.RequestOptions
Create a <a href="https://auth0.com/docs/secure/multi-factor-authentication/auth0-guardian/create-custom-enrollment-tickets">multi-factor authentication (MFA) enrollment ticket</a>, and optionally send an email with the created ticket, to a given user. Create a <a href="https://auth0.com/docs/secure/multi-factor-authentication/auth0-guardian/create-custom-enrollment-tickets">multi-factor authentication (MFA) enrollment ticket</a>, and optionally send an email with the created ticket to a given user. Enrollment tickets can specify which factor users must enroll with or allow existing MFA users to enroll in additional factors.
Note: Users cannot enroll in Email as a factor through custom enrollment tickets.
</dd> </dl> </dd> </dl>await client.guardian.enrollments.createTicket({
user_id: "user_id",
});
request: Management.CreateGuardianEnrollmentTicketRequestContent
requestOptions: EnrollmentsClient.RequestOptions
Retrieve details, such as status and type, for a specific multi-factor authentication enrollment registered to a user account.
</dd> </dl> </dd> </dl>await client.guardian.enrollments.get("id");
id: string — ID of the enrollment to be retrieve.
requestOptions: EnrollmentsClient.RequestOptions
Remove a specific multi-factor authentication (MFA) enrollment from a user's account. This allows the user to re-enroll with MFA. For more information, review <a href="https://auth0.com/docs/secure/multi-factor-authentication/reset-user-mfa">Reset User Multi-Factor Authentication and Recovery Codes</a>.
</dd> </dl> </dd> </dl>await client.guardian.enrollments.delete("id");
id: string — ID of the enrollment to be deleted.
requestOptions: EnrollmentsClient.RequestOptions
Retrieve details of all <a href="https://auth0.com/docs/secure/multi-factor-authentication/multi-factor-authentication-factors">multi-factor authentication factors</a> associated with your tenant.
</dd> </dl> </dd> </dl>await client.guardian.factors.list();
requestOptions: FactorsClient.RequestOptions
Update the status (i.e., enabled or disabled) of a specific multi-factor authentication factor.
</dd> </dl> </dd> </dl>await client.guardian.factors.set("push-notification", {
enabled: true,
});
name: Management.GuardianFactorNameEnum — Factor name. Can be sms, push-notification, email, duo otp webauthn-roaming, webauthn-platform, or recovery-code.
request: Management.SetGuardianFactorRequestContent
requestOptions: FactorsClient.RequestOptions
Retrieve the <a href="https://auth0.com/docs/secure/multi-factor-authentication/enable-mfa">multi-factor authentication (MFA) policies</a> configured for your tenant.
The following policies are supported:
<ul> <li><code>all-applications</code> policy prompts with MFA for all logins.</li> <li><code>confidence-score</code> policy prompts with MFA only for low confidence logins.</li> </ul><b>Note</b>: The <code>confidence-score</code> policy is part of the <a href="https://auth0.com/docs/secure/multi-factor-authentication/adaptive-mfa">Adaptive MFA feature</a>. Adaptive MFA requires an add-on for the Enterprise plan; review <a href="https://auth0.com/pricing">Auth0 Pricing</a> for more details.
</dd> </dl> </dd> </dl>await client.guardian.policies.list();
requestOptions: PoliciesClient.RequestOptions
Set <a href="https://auth0.com/docs/secure/multi-factor-authentication/enable-mfa">multi-factor authentication (MFA) policies</a> for your tenant.
The following policies are supported:
<ul> <li><code>all-applications</code> policy prompts with MFA for all logins.</li> <li><code>confidence-score</code> policy prompts with MFA only for low confidence logins.</li> </ul><b>Note</b>: The <code>confidence-score</code> policy is part of the <a href="https://auth0.com/docs/secure/multi-factor-authentication/adaptive-mfa">Adaptive MFA feature</a>. Adaptive MFA requires an add-on for the Enterprise plan; review <a href="https://auth0.com/pricing">Auth0 Pricing</a> for more details.
</dd> </dl> </dd> </dl>await client.guardian.policies.set(["all-applications"]);
request: Management.SetGuardianPoliciesRequestContent
requestOptions: PoliciesClient.RequestOptions
Retrieve list of <a href="https://auth0.com/docs/secure/multi-factor-authentication/multi-factor-authentication-factors/configure-sms-voice-notifications-mfa">phone-type MFA factors</a> (i.e., sms and voice) that are enabled for your tenant.
</dd> </dl> </dd> </dl>await client.guardian.factors.phone.getMessageTypes();
requestOptions: PhoneClient.RequestOptions
Replace the list of <a href="https://auth0.com/docs/secure/multi-factor-authentication/multi-factor-authentication-factors/configure-sms-voice-notifications-mfa">phone-type MFA factors</a> (i.e., sms and voice) that are enabled for your tenant.
</dd> </dl> </dd> </dl>await client.guardian.factors.phone.setMessageTypes({
message_types: ["sms"],
});
request: Management.SetGuardianFactorPhoneMessageTypesRequestContent
requestOptions: PhoneClient.RequestOptions
Retrieve configuration details for a Twilio phone provider that has been set up in your tenant. To learn more, review <a href="https://auth0.com/docs/secure/multi-factor-authentication/multi-factor-authentication-factors/configure-sms-voice-notifications-mfa">Configure SMS and Voice Notifications for MFA</a>.
</dd> </dl> </dd> </dl>await client.guardian.factors.phone.getTwilioProvider();
requestOptions: PhoneClient.RequestOptions
Update the configuration of a Twilio phone provider that has been set up in your tenant. To learn more, review <a href="https://auth0.com/docs/secure/multi-factor-authentication/multi-factor-authentication-factors/configure-sms-voice-notifications-mfa">Configure SMS and Voice Notifications for MFA</a>.
</dd> </dl> </dd> </dl>await client.guardian.factors.phone.setTwilioProvider();
request: Management.SetGuardianFactorsProviderPhoneTwilioRequestContent
requestOptions: PhoneClient.RequestOptions
Retrieve details of the multi-factor authentication phone provider configured for your tenant.
</dd> </dl> </dd> </dl>await client.guardian.factors.phone.getSelectedProvider();
requestOptions: PhoneClient.RequestOptions
await client.guardian.factors.phone.setProvider({
provider: "auth0",
});
request: Management.SetGuardianFactorsProviderPhoneRequestContent
requestOptions: PhoneClient.RequestOptions
Retrieve details of the multi-factor authentication enrollment and verification templates for phone-type factors available in your tenant.
</dd> </dl> </dd> </dl>await client.guardian.factors.phone.getTemplates();
requestOptions: PhoneClient.RequestOptions
Customize the messages sent to complete phone enrollment and verification (subscription required).
</dd> </dl> </dd> </dl>await client.guardian.factors.phone.setTemplates({
enrollment_message: "enrollment_message",
verification_message: "verification_message",
});
request: Management.SetGuardianFactorPhoneTemplatesRequestContent
requestOptions: PhoneClient.RequestOptions
Retrieve configuration details for the multi-factor authentication APNS provider associated with your tenant.
</dd> </dl> </dd> </dl>await client.guardian.factors.pushNotification.getApnsProvider();
requestOptions: PushNotificationClient.RequestOptions
Overwrite all configuration details of the multi-factor authentication APNS provider associated with your tenant.
</dd> </dl> </dd> </dl>await client.guardian.factors.pushNotification.setApnsProvider();
request: Management.SetGuardianFactorsProviderPushNotificationApnsRequestContent
requestOptions: PushNotificationClient.RequestOptions
Modify configuration details of the multi-factor authentication APNS provider associated with your tenant.
</dd> </dl> </dd> </dl>await client.guardian.factors.pushNotification.updateApnsProvider();
request: Management.UpdateGuardianFactorsProviderPushNotificationApnsRequestContent
requestOptions: PushNotificationClient.RequestOptions
Overwrite all configuration details of the multi-factor authentication FCM provider associated with your tenant.
</dd> </dl> </dd> </dl>await client.guardian.factors.pushNotification.setFcmProvider();
request: Management.SetGuardianFactorsProviderPushNotificationFcmRequestContent
requestOptions: PushNotificationClient.RequestOptions
Modify configuration details of the multi-factor authentication FCM provider associated with your tenant.
</dd> </dl> </dd> </dl>await client.guardian.factors.pushNotification.updateFcmProvider();
request: Management.UpdateGuardianFactorsProviderPushNotificationFcmRequestContent
requestOptions: PushNotificationClient.RequestOptions
Overwrite all configuration details of the multi-factor authentication FCMV1 provider associated with your tenant.
</dd> </dl> </dd> </dl>await client.guardian.factors.pushNotification.setFcmv1Provider();
request: Management.SetGuardianFactorsProviderPushNotificationFcmv1RequestContent
requestOptions: PushNotificationClient.RequestOptions
Modify configuration details of the multi-factor authentication FCMV1 provider associated with your tenant.
</dd> </dl> </dd> </dl>await client.guardian.factors.pushNotification.updateFcmv1Provider();
request: Management.UpdateGuardianFactorsProviderPushNotificationFcmv1RequestContent
requestOptions: PushNotificationClient.RequestOptions
Retrieve configuration details for an AWS SNS push notification provider that has been enabled for MFA. To learn more, review <a href="https://auth0.com/docs/secure/multi-factor-authentication/multi-factor-authentication-factors/configure-push-notifications-for-mfa">Configure Push Notifications for MFA</a>.
</dd> </dl> </dd> </dl>await client.guardian.factors.pushNotification.getSnsProvider();
requestOptions: PushNotificationClient.RequestOptions
Configure the <a href="https://auth0.com/docs/multifactor-authentication/developer/sns-configuration">AWS SNS push notification provider configuration</a> (subscription required).
</dd> </dl> </dd> </dl>await client.guardian.factors.pushNotification.setSnsProvider();
request: Management.SetGuardianFactorsProviderPushNotificationSnsRequestContent
requestOptions: PushNotificationClient.RequestOptions
Configure the <a href="https://auth0.com/docs/multifactor-authentication/developer/sns-configuration">AWS SNS push notification provider configuration</a> (subscription required).
</dd> </dl> </dd> </dl>await client.guardian.factors.pushNotification.updateSnsProvider();
request: Management.UpdateGuardianFactorsProviderPushNotificationSnsRequestContent
requestOptions: PushNotificationClient.RequestOptions
Modify the push notification provider configured for your tenant. For more information, review <a href="https://auth0.com/docs/secure/multi-factor-authentication/multi-factor-authentication-factors/configure-push-notifications-for-mfa">Configure Push Notifications for MFA</a>.
</dd> </dl> </dd> </dl>await client.guardian.factors.pushNotification.getSelectedProvider();
requestOptions: PushNotificationClient.RequestOptions
Modify the push notification provider configured for your tenant. For more information, review <a href="https://auth0.com/docs/secure/multi-factor-authentication/multi-factor-authentication-factors/configure-push-notifications-for-mfa">Configure Push Notifications for MFA</a>.
</dd> </dl> </dd> </dl>await client.guardian.factors.pushNotification.setProvider({
provider: "guardian",
});
request: Management.SetGuardianFactorsProviderPushNotificationRequestContent
requestOptions: PushNotificationClient.RequestOptions
Retrieve the <a href="https://auth0.com/docs/multifactor-authentication/twilio-configuration">Twilio SMS provider configuration</a> (subscription required).
A new endpoint is available to retrieve the Twilio configuration related to phone factors (<a href='https://auth0.com/docs/api/management/v2/#!/Guardian/get_twilio'>phone Twilio configuration</a>). It has the same payload as this one. Please use it instead.
await client.guardian.factors.sms.getTwilioProvider();
requestOptions: SmsClient.RequestOptions
This endpoint has been deprecated. To complete this action, use the <a href="https://auth0.com/docs/api/management/v2/guardian/put-twilio">Update Twilio phone configuration</a> endpoint.
<b>Previous functionality</b>: Update the Twilio SMS provider configuration.
await client.guardian.factors.sms.setTwilioProvider();
request: Management.SetGuardianFactorsProviderSmsTwilioRequestContent
requestOptions: SmsClient.RequestOptions
This endpoint has been deprecated. To complete this action, use the <a href="https://auth0.com/docs/api/management/v2/guardian/get-phone-providers">Retrieve phone configuration</a> endpoint instead.
<b>Previous functionality</b>: Retrieve details for the multi-factor authentication SMS provider configured for your tenant.
await client.guardian.factors.sms.getSelectedProvider();
requestOptions: SmsClient.RequestOptions
This endpoint has been deprecated. To complete this action, use the <a href="https://auth0.com/docs/api/management/v2/guardian/put-phone-providers">Update phone configuration</a> endpoint instead.
<b>Previous functionality</b>: Update the multi-factor authentication SMS provider configuration in your tenant.
await client.guardian.factors.sms.setProvider({
provider: "auth0",
});
request: Management.SetGuardianFactorsProviderSmsRequestContent
requestOptions: SmsClient.RequestOptions
This endpoint has been deprecated. To complete this action, use the <a href="https://auth0.com/docs/api/management/v2/guardian/get-factor-phone-templates">Retrieve enrollment and verification phone templates</a> endpoint instead.
<b>Previous function</b>: Retrieve details of SMS enrollment and verification templates configured for your tenant.
await client.guardian.factors.sms.getTemplates();
requestOptions: SmsClient.RequestOptions
This endpoint has been deprecated. To complete this action, use the <a href="https://auth0.com/docs/api/management/v2/guardian/put-factor-phone-templates">Update enrollment and verification phone templates</a> endpoint instead.
<b>Previous functionality</b>: Customize the messages sent to complete SMS enrollment and verification.
await client.guardian.factors.sms.setTemplates({
enrollment_message: "enrollment_message",
verification_message: "verification_message",
});
request: Management.SetGuardianFactorSmsTemplatesRequestContent
requestOptions: SmsClient.RequestOptions
Retrieves the DUO account and factor configuration.
</dd> </dl> </dd> </dl>await client.guardian.factors.duo.settings.get();
requestOptions: SettingsClient.RequestOptions
Set the DUO account configuration and other properties specific to this factor.
</dd> </dl> </dd> </dl>await client.guardian.factors.duo.settings.set();
request: Management.SetGuardianFactorDuoSettingsRequestContent
requestOptions: SettingsClient.RequestOptions
await client.guardian.factors.duo.settings.update();
request: Management.UpdateGuardianFactorDuoSettingsRequestContent
requestOptions: SettingsClient.RequestOptions
Retrieve a hook's secrets by the ID of the hook.
</dd> </dl> </dd> </dl>await client.hooks.secrets.get("id");
id: string — ID of the hook to retrieve secrets from.
requestOptions: SecretsClient.RequestOptions
Add one or more secrets to an existing hook. Accepts an object of key-value pairs, where the key is the name of the secret. A hook can have a maximum of 20 secrets.
</dd> </dl> </dd> </dl>await client.hooks.secrets.create("id", {
key: "value",
});
id: string — The id of the hook to retrieve
request: Management.CreateHookSecretRequestContent
requestOptions: SecretsClient.RequestOptions
Delete one or more existing secrets for a given hook. Accepts an array of secret names to delete.
</dd> </dl> </dd> </dl>await client.hooks.secrets.delete("id", ["string"]);
id: string — ID of the hook whose secrets to delete.
request: Management.DeleteHookSecretRequestContent
requestOptions: SecretsClient.RequestOptions
Update one or more existing secrets for an existing hook. Accepts an object of key-value pairs, where the key is the name of the existing secret.
</dd> </dl> </dd> </dl>await client.hooks.secrets.update("id", {
key: "value",
});
id: string — ID of the hook whose secrets to update.
request: Management.UpdateHookSecretRequestContent
requestOptions: SecretsClient.RequestOptions
Export all users to a file via a long-running job.
</dd> </dl> </dd> </dl>await client.jobs.usersExports.create();
request: Management.CreateExportUsersRequestContent
requestOptions: UsersExportsClient.RequestOptions
Import users from a <a href="https://auth0.com/docs/users/references/bulk-import-database-schema-examples">formatted file</a> into a connection via a long-running job. When importing users, with or without upsert, the email_verified is set to false when the email address is added or updated. Users must verify their email address. To avoid this behavior, set email_verified to true in the imported data.
await client.jobs.usersImports.create({
users: fs.createReadStream("/path/to/your/file"),
connection_id: "connection_id",
});
request: Management.CreateImportUsersRequestContent
requestOptions: UsersImportsClient.RequestOptions
Send an email to the specified user that asks them to click a link to <a href="https://auth0.com/docs/email/custom#verification-email">verify their email address</a>.
Note: You must have the Status toggle enabled for the verification email template for the email to be sent.
await client.jobs.verificationEmail.create({
user_id: "user_id",
});
request: Management.CreateVerificationEmailRequestContent
requestOptions: VerificationEmailClient.RequestOptions
Retrieve error details of a failed job.
</dd> </dl> </dd> </dl>await client.jobs.errors.get("id");
id: string — ID of the job.
requestOptions: ErrorsClient.RequestOptions
Get entire jwks representation of custom signing keys.
</dd> </dl> </dd> </dl>await client.keys.customSigning.get();
requestOptions: CustomSigningClient.RequestOptions
Create or replace entire jwks representation of custom signing keys.
</dd> </dl> </dd> </dl>await client.keys.customSigning.set({
keys: [
{
kty: "EC",
},
],
});
request: Management.SetCustomSigningKeysRequestContent
requestOptions: CustomSigningClient.RequestOptions
Delete entire jwks representation of custom signing keys.
</dd> </dl> </dd> </dl>await client.keys.customSigning.delete();
requestOptions: CustomSigningClient.RequestOptions
Retrieve details of all the encryption keys associated with your tenant.
</dd> </dl> </dd> </dl>const pageableResponse = await client.keys.encryption.list({
page: 1,
per_page: 1,
include_totals: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.keys.encryption.list({
page: 1,
per_page: 1,
include_totals: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListEncryptionKeysRequestParameters
requestOptions: EncryptionClient.RequestOptions
Create the new, pre-activated encryption key, without the key material.
</dd> </dl> </dd> </dl>await client.keys.encryption.create({
type: "customer-provided-root-key",
});
request: Management.CreateEncryptionKeyRequestContent
requestOptions: EncryptionClient.RequestOptions
Perform rekeying operation on the key hierarchy.
</dd> </dl> </dd> </dl>await client.keys.encryption.rekey();
requestOptions: EncryptionClient.RequestOptions
Retrieve details of the encryption key with the given ID.
</dd> </dl> </dd> </dl>await client.keys.encryption.get("kid");
kid: string — Encryption key ID
requestOptions: EncryptionClient.RequestOptions
Import wrapped key material and activate encryption key.
</dd> </dl> </dd> </dl>await client.keys.encryption.import("kid", {
wrapped_key: "wrapped_key",
});
kid: string — Encryption key ID
request: Management.ImportEncryptionKeyRequestContent
requestOptions: EncryptionClient.RequestOptions
Delete the custom provided encryption key with the given ID and move back to using native encryption key.
</dd> </dl> </dd> </dl>await client.keys.encryption.delete("kid");
kid: string — Encryption key ID
requestOptions: EncryptionClient.RequestOptions
Create the public wrapping key to wrap your own encryption key material.
</dd> </dl> </dd> </dl>await client.keys.encryption.createPublicWrappingKey("kid");
kid: string — Encryption key ID
requestOptions: EncryptionClient.RequestOptions
Retrieve details of all the application signing keys associated with your tenant.
</dd> </dl> </dd> </dl>await client.keys.signing.list();
requestOptions: SigningClient.RequestOptions
Rotate the application signing key of your tenant.
</dd> </dl> </dd> </dl>await client.keys.signing.rotate();
requestOptions: SigningClient.RequestOptions
Retrieve details of the application signing key with the given ID.
</dd> </dl> </dd> </dl>await client.keys.signing.get("kid");
kid: string — Key id of the key to retrieve
requestOptions: SigningClient.RequestOptions
Revoke the application signing key with the given ID.
</dd> </dl> </dd> </dl>await client.keys.signing.revoke("kid");
kid: string — Key id of the key to revoke
requestOptions: SigningClient.RequestOptions
const pageableResponse = await client.organizations.clientGrants.list("id", {
audience: "audience",
client_id: "client_id",
grant_ids: ["grant_ids"],
page: 1,
per_page: 1,
include_totals: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.organizations.clientGrants.list("id", {
audience: "audience",
client_id: "client_id",
grant_ids: ["grant_ids"],
page: 1,
per_page: 1,
include_totals: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — Organization identifier.
request: Management.ListOrganizationClientGrantsRequestParameters
requestOptions: ClientGrantsClient.RequestOptions
await client.organizations.clientGrants.create("id", {
grant_id: "grant_id",
});
id: string — Organization identifier.
request: Management.AssociateOrganizationClientGrantRequestContent
requestOptions: ClientGrantsClient.RequestOptions
await client.organizations.clientGrants.delete("id", "grant_id");
id: string — Organization identifier.
grant_id: string — The Client Grant ID to remove from the organization
requestOptions: ClientGrantsClient.RequestOptions
const pageableResponse = await client.organizations.connections.list("id", {
page: 1,
per_page: 1,
include_totals: true,
is_enabled: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.organizations.connections.list("id", {
page: 1,
per_page: 1,
include_totals: true,
is_enabled: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — Organization identifier.
request: Management.ListOrganizationAllConnectionsRequestParameters
requestOptions: ConnectionsClient.RequestOptions
await client.organizations.connections.create("id", {
connection_id: "connection_id",
});
id: string — Organization identifier.
request: Management.CreateOrganizationAllConnectionRequestParameters
requestOptions: ConnectionsClient.RequestOptions
await client.organizations.connections.get("id", "connection_id");
id: string — Organization identifier.
connection_id: string — Connection identifier.
requestOptions: ConnectionsClient.RequestOptions
await client.organizations.connections.delete("id", "connection_id");
id: string — Organization identifier.
connection_id: string — Connection identifier.
requestOptions: ConnectionsClient.RequestOptions
await client.organizations.connections.update("id", "connection_id");
id: string — Organization identifier.
connection_id: string — Connection identifier.
request: Management.UpdateOrganizationConnectionRequestParameters
requestOptions: ConnectionsClient.RequestOptions
Retrieve list of all organization discovery domains associated with the specified organization. This endpoint is subject to eventual consistency; newly created, updated, or deleted discovery domains may not immediately appear in the response.
</dd> </dl> </dd> </dl>const pageableResponse = await client.organizations.discoveryDomains.list("id", {
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.organizations.discoveryDomains.list("id", {
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — ID of the organization.
request: Management.ListOrganizationDiscoveryDomainsRequestParameters
requestOptions: DiscoveryDomainsClient.RequestOptions
Create a new discovery domain for an organization.
</dd> </dl> </dd> </dl>await client.organizations.discoveryDomains.create("id", {
domain: "domain",
});
id: string — ID of the organization.
request: Management.CreateOrganizationDiscoveryDomainRequestContent
requestOptions: DiscoveryDomainsClient.RequestOptions
Retrieve details about a single organization discovery domain specified by domain name. This endpoint is subject to eventual consistency; newly created, updated, or deleted discovery domains may not immediately appear in the response.
</dd> </dl> </dd> </dl>await client.organizations.discoveryDomains.getByName("id", "discovery_domain");
id: string — ID of the organization.
discovery_domain: string — Domain name of the discovery domain.
requestOptions: DiscoveryDomainsClient.RequestOptions
Retrieve details about a single organization discovery domain specified by ID. This endpoint is subject to eventual consistency; newly created, updated, or deleted discovery domains may not immediately appear in the response.
</dd> </dl> </dd> </dl>await client.organizations.discoveryDomains.get("id", "discovery_domain_id");
id: string — ID of the organization.
discovery_domain_id: string — ID of the discovery domain.
requestOptions: DiscoveryDomainsClient.RequestOptions
Remove a discovery domain from an organization. This action cannot be undone.
</dd> </dl> </dd> </dl>await client.organizations.discoveryDomains.delete("id", "discovery_domain_id");
id: string — ID of the organization.
discovery_domain_id: string — ID of the discovery domain.
requestOptions: DiscoveryDomainsClient.RequestOptions
Update the verification status and/or use_for_organization_discovery for an organization discovery domain. The <code>status</code> field must be either <code>pending</code> or <code>verified</code>. The <code>use_for_organization_discovery</code> field can be <code>true</code> or <code>false</code> (default: <code>true</code>).
</dd> </dl> </dd> </dl>await client.organizations.discoveryDomains.update("id", "discovery_domain_id");
id: string — ID of the organization.
discovery_domain_id: string — ID of the discovery domain to update.
request: Management.UpdateOrganizationDiscoveryDomainRequestContent
requestOptions: DiscoveryDomainsClient.RequestOptions
Retrieve details about a specific connection currently enabled for an Organization. Information returned includes details such as connection ID, name, strategy, and whether the connection automatically grants membership upon login.
</dd> </dl> </dd> </dl>const pageableResponse = await client.organizations.enabledConnections.list("id", {
page: 1,
per_page: 1,
include_totals: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.organizations.enabledConnections.list("id", {
page: 1,
per_page: 1,
include_totals: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — Organization identifier.
request: Management.ListOrganizationConnectionsRequestParameters
requestOptions: EnabledConnectionsClient.RequestOptions
Enable a specific connection for a given Organization. To enable a connection, it must already exist within your tenant; connections cannot be created through this action.
<a href="https://auth0.com/docs/authenticate/identity-providers">Connections</a> represent the relationship between Auth0 and a source of users. Available types of connections include database, enterprise, and social.
</dd> </dl> </dd> </dl>await client.organizations.enabledConnections.add("id", {
connection_id: "connection_id",
});
id: string — Organization identifier.
request: Management.AddOrganizationConnectionRequestContent
requestOptions: EnabledConnectionsClient.RequestOptions
Retrieve details about a specific connection currently enabled for an Organization. Information returned includes details such as connection ID, name, strategy, and whether the connection automatically grants membership upon login.
</dd> </dl> </dd> </dl>await client.organizations.enabledConnections.get("id", "connectionId");
id: string — Organization identifier.
connectionId: string — Connection identifier.
requestOptions: EnabledConnectionsClient.RequestOptions
Disable a specific connection for an Organization. Once disabled, Organization members can no longer use that connection to authenticate.
<b>Note</b>: This action does not remove the connection from your tenant.
</dd> </dl> </dd> </dl>await client.organizations.enabledConnections.delete("id", "connectionId");
id: string — Organization identifier.
connectionId: string — Connection identifier.
requestOptions: EnabledConnectionsClient.RequestOptions
Modify the details of a specific connection currently enabled for an Organization.
</dd> </dl> </dd> </dl>await client.organizations.enabledConnections.update("id", "connectionId");
id: string — Organization identifier.
connectionId: string — Connection identifier.
request: Management.UpdateOrganizationConnectionRequestContent
requestOptions: EnabledConnectionsClient.RequestOptions
Retrieve a detailed list of invitations sent to users for a specific Organization. The list includes details such as inviter and invitee information, invitation URLs, and dates of creation and expiration. To learn more about Organization invitations, review <a href="https://auth0.com/docs/manage-users/organizations/configure-organizations/invite-members">Invite Organization Members</a>.
</dd> </dl> </dd> </dl>const pageableResponse = await client.organizations.invitations.list("id", {
page: 1,
per_page: 1,
include_totals: true,
fields: "fields",
include_fields: true,
sort: "sort",
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.organizations.invitations.list("id", {
page: 1,
per_page: 1,
include_totals: true,
fields: "fields",
include_fields: true,
sort: "sort",
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — Organization identifier.
request: Management.ListOrganizationInvitationsRequestParameters
requestOptions: InvitationsClient.RequestOptions
Create a user invitation for a specific Organization. Upon creation, the listed user receives an email inviting them to join the Organization. To learn more about Organization invitations, review <a href="https://auth0.com/docs/manage-users/organizations/configure-organizations/invite-members">Invite Organization Members</a>.
</dd> </dl> </dd> </dl>await client.organizations.invitations.create("id", {
inviter: {
name: "name",
},
invitee: {
email: "email",
},
client_id: "client_id",
});
id: string — Organization identifier.
request: Management.CreateOrganizationInvitationRequestContent
requestOptions: InvitationsClient.RequestOptions
await client.organizations.invitations.get("id", "invitation_id", {
fields: "fields",
include_fields: true,
});
id: string — Organization identifier.
invitation_id: string — The id of the user invitation.
request: Management.GetOrganizationInvitationRequestParameters
requestOptions: InvitationsClient.RequestOptions
await client.organizations.invitations.delete("id", "invitation_id");
id: string — Organization identifier.
invitation_id: string — The id of the user invitation.
requestOptions: InvitationsClient.RequestOptions
List organization members. This endpoint is subject to eventual consistency. New users may not be immediately included in the response and deleted users may not be immediately removed from it.
<ul> <li> Use the <code>fields</code> parameter to optionally define the specific member details retrieved. If <code>fields</code> is left blank, all fields (except roles) are returned. </li> <li> Member roles are not sent by default. Use <code>fields=roles</code> to retrieve the roles assigned to each listed member. To use this parameter, you must include the <code>read:organization_member_roles</code> scope in the token. </li> </ul>This endpoint supports two types of pagination:
Checkpoint pagination must be used if you need to retrieve more than 1000 organization members.
<h2>Checkpoint Pagination</h2>To search by checkpoint, use the following parameters: - from: Optional id from which to start selection. - take: The total amount of entries to retrieve when using the from parameter. Defaults to 50. Note: The first time you call this endpoint using Checkpoint Pagination, you should omit the <code>from</code> parameter. If there are more results, a <code>next</code> value will be included in the response. You can use this for subsequent API calls. When <code>next</code> is no longer included in the response, this indicates there are no more pages remaining.
</dd> </dl> </dd> </dl>const pageableResponse = await client.organizations.members.list("id", {
from: "from",
take: 1,
fields: "fields",
include_fields: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.organizations.members.list("id", {
from: "from",
take: 1,
fields: "fields",
include_fields: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — Organization identifier.
request: Management.ListOrganizationMembersRequestParameters
requestOptions: MembersClient.RequestOptions
Set one or more existing users as members of a specific <a href="https://auth0.com/docs/manage-users/organizations">Organization</a>.
To add a user to an Organization through this action, the user must already exist in your tenant. If a user does not yet exist, you can <a href="https://auth0.com/docs/manage-users/organizations/configure-organizations/invite-members">invite them to create an account</a>, manually create them through the Auth0 Dashboard, or use the Management API.
</dd> </dl> </dd> </dl>await client.organizations.members.create("id", {
members: ["members"],
});
id: string — Organization identifier.
request: Management.CreateOrganizationMemberRequestContent
requestOptions: MembersClient.RequestOptions
await client.organizations.members.delete("id", {
members: ["members"],
});
id: string — Organization identifier.
request: Management.DeleteOrganizationMembersRequestContent
requestOptions: MembersClient.RequestOptions
Retrieve detailed list of roles assigned to a given user within the context of a specific Organization.
Users can be members of multiple Organizations with unique roles assigned for each membership. This action only returns the roles associated with the specified Organization; any roles assigned to the user within other Organizations are not included.
</dd> </dl> </dd> </dl>const pageableResponse = await client.organizations.members.roles.list("id", "user_id", {
page: 1,
per_page: 1,
include_totals: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.organizations.members.roles.list("id", "user_id", {
page: 1,
per_page: 1,
include_totals: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — Organization identifier.
user_id: string — ID of the user to associate roles with.
request: Management.ListOrganizationMemberRolesRequestParameters
requestOptions: RolesClient.RequestOptions
Assign one or more <a href="https://auth0.com/docs/manage-users/access-control/rbac">roles</a> to a user to determine their access for a specific Organization.
Users can be members of multiple Organizations with unique roles assigned for each membership. This action assigns roles to a user only for the specified Organization. Roles cannot be assigned to a user across multiple Organizations in the same call.
</dd> </dl> </dd> </dl>await client.organizations.members.roles.assign("id", "user_id", {
roles: ["roles"],
});
id: string — Organization identifier.
user_id: string — ID of the user to associate roles with.
request: Management.AssignOrganizationMemberRolesRequestContent
requestOptions: RolesClient.RequestOptions
Remove one or more Organization-specific <a href="https://auth0.com/docs/manage-users/access-control/rbac">roles</a> from a given user.
Users can be members of multiple Organizations with unique roles assigned for each membership. This action removes roles from a user in relation to the specified Organization. Roles assigned to the user within a different Organization cannot be managed in the same call.
</dd> </dl> </dd> </dl>await client.organizations.members.roles.delete("id", "user_id", {
roles: ["roles"],
});
id: string — Organization identifier.
user_id: string — User ID of the organization member to remove roles from.
request: Management.DeleteOrganizationMemberRolesRequestContent
requestOptions: RolesClient.RequestOptions
Get render setting configurations for all screens.
</dd> </dl> </dd> </dl>const pageableResponse = await client.prompts.rendering.list({
fields: "fields",
include_fields: true,
page: 1,
per_page: 1,
include_totals: true,
prompt: "prompt",
screen: "screen",
rendering_mode: "advanced",
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.prompts.rendering.list({
fields: "fields",
include_fields: true,
page: 1,
per_page: 1,
include_totals: true,
prompt: "prompt",
screen: "screen",
rendering_mode: "advanced",
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListAculsRequestParameters
requestOptions: RenderingClient.RequestOptions
Learn more about <a href='https://auth0.com/docs/customize/login-pages/advanced-customizations/getting-started/configure-acul-screens'>configuring render settings</a> for advanced customization.
</dd> </dl> </dd> </dl>await client.prompts.rendering.bulkUpdate({
configs: [
{
prompt: "login",
screen: "login",
},
],
});
request: Management.BulkUpdateAculRequestContent
requestOptions: RenderingClient.RequestOptions
Get render settings for a screen.
</dd> </dl> </dd> </dl>await client.prompts.rendering.get("login", "login");
prompt: Management.PromptGroupNameEnum — Name of the prompt
screen: Management.ScreenGroupNameEnum — Name of the screen
requestOptions: RenderingClient.RequestOptions
Learn more about <a href='https://auth0.com/docs/customize/login-pages/advanced-customizations/getting-started/configure-acul-screens'>configuring render settings</a> for advanced customization.
</dd> </dl> </dd> </dl>await client.prompts.rendering.update("login", "login");
prompt: Management.PromptGroupNameEnum — Name of the prompt
screen: Management.ScreenGroupNameEnum — Name of the screen
request: Management.UpdateAculRequestContent
requestOptions: RenderingClient.RequestOptions
Retrieve custom text for a specific prompt and language.
</dd> </dl> </dd> </dl>await client.prompts.customText.get("login", "am");
prompt: Management.PromptGroupNameEnum — Name of the prompt.
language: Management.PromptLanguageEnum — Language to update.
requestOptions: CustomTextClient.RequestOptions
Set custom text for a specific prompt. Existing texts will be overwritten.
</dd> </dl> </dd> </dl>await client.prompts.customText.set("login", "am", {
key: "value",
});
prompt: Management.PromptGroupNameEnum — Name of the prompt.
language: Management.PromptLanguageEnum — Language to update.
request: Management.SetsCustomTextsByLanguageRequestContent
requestOptions: CustomTextClient.RequestOptions
Get template partials for a prompt
</dd> </dl> </dd> </dl>await client.prompts.partials.get("login");
prompt: Management.PartialGroupsEnum — Name of the prompt.
requestOptions: PartialsClient.RequestOptions
Set template partials for a prompt
</dd> </dl> </dd> </dl>await client.prompts.partials.set("login", {
key: "value",
});
prompt: Management.PartialGroupsEnum — Name of the prompt.
request: Management.SetPartialsRequestContent
requestOptions: PartialsClient.RequestOptions
Gets the tenant settings for risk assessments
</dd> </dl> </dd> </dl>await client.riskAssessments.settings.get();
requestOptions: SettingsClient.RequestOptions
Updates the tenant settings for risk assessments
</dd> </dl> </dd> </dl>await client.riskAssessments.settings.update({
enabled: true,
});
request: Management.UpdateRiskAssessmentsSettingsRequestContent
requestOptions: SettingsClient.RequestOptions
Gets the risk assessment settings for the new device assessor
</dd> </dl> </dd> </dl>await client.riskAssessments.settings.newDevice.get();
requestOptions: NewDeviceClient.RequestOptions
Updates the risk assessment settings for the new device assessor
</dd> </dl> </dd> </dl>await client.riskAssessments.settings.newDevice.update({
remember_for: 1,
});
request: Management.UpdateRiskAssessmentsSettingsNewDeviceRequestContent
requestOptions: NewDeviceClient.RequestOptions
Retrieve detailed list (name, description, resource server) of permissions granted by a specified user role.
</dd> </dl> </dd> </dl>const pageableResponse = await client.roles.permissions.list("id", {
per_page: 1,
page: 1,
include_totals: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.roles.permissions.list("id", {
per_page: 1,
page: 1,
include_totals: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — ID of the role to list granted permissions.
request: Management.ListRolePermissionsRequestParameters
requestOptions: PermissionsClient.RequestOptions
Add one or more <a href="https://auth0.com/docs/manage-users/access-control/configure-core-rbac/manage-permissions">permissions</a> to a specified user role.
</dd> </dl> </dd> </dl>await client.roles.permissions.add("id", {
permissions: [
{
resource_server_identifier: "resource_server_identifier",
permission_name: "permission_name",
},
],
});
id: string — ID of the role to add permissions to.
request: Management.AddRolePermissionsRequestContent
requestOptions: PermissionsClient.RequestOptions
Remove one or more <a href="https://auth0.com/docs/manage-users/access-control/configure-core-rbac/manage-permissions">permissions</a> from a specified user role.
</dd> </dl> </dd> </dl>await client.roles.permissions.delete("id", {
permissions: [
{
resource_server_identifier: "resource_server_identifier",
permission_name: "permission_name",
},
],
});
id: string — ID of the role to remove permissions from.
request: Management.DeleteRolePermissionsRequestContent
requestOptions: PermissionsClient.RequestOptions
Retrieve list of users associated with a specific role. For Dashboard instructions, review <a href="https://auth0.com/docs/manage-users/access-control/configure-core-rbac/roles/view-users-assigned-to-roles">View Users Assigned to Roles</a>.
This endpoint supports two types of pagination:
<ul> <li>Offset pagination</li> <li>Checkpoint pagination</li> </ul>Checkpoint pagination must be used if you need to retrieve more than 1000 organization members.
<h2>Checkpoint Pagination</h2>To search by checkpoint, use the following parameters:
<ul> <li><code>from</code>: Optional id from which to start selection.</li> <li><code>take</code>: The total amount of entries to retrieve when using the from parameter. Defaults to 50.</li> </ul><b>Note</b>: The first time you call this endpoint using checkpoint pagination, omit the <code>from</code> parameter. If there are more results, a <code>next</code> value is included in the response. You can use this for subsequent API calls. When <code>next</code> is no longer included in the response, no pages are remaining.
</dd> </dl> </dd> </dl>const pageableResponse = await client.roles.users.list("id", {
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.roles.users.list("id", {
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — ID of the role to retrieve a list of users associated with.
request: Management.ListRoleUsersRequestParameters
requestOptions: UsersClient.RequestOptions
Assign one or more users to an existing user role. To learn more, review <a href="https://auth0.com/docs/manage-users/access-control/rbac">Role-Based Access Control</a>.
<b>Note</b>: New roles cannot be created through this action.
</dd> </dl> </dd> </dl>await client.roles.users.assign("id", {
users: ["users"],
});
id: string — ID of the role to assign users to.
request: Management.AssignRoleUsersRequestContent
requestOptions: UsersClient.RequestOptions
Retrieves text customizations for a given self-service profile, language and Self-Service Enterprise Configuration flow page.
</dd> </dl> </dd> </dl>await client.selfServiceProfiles.customText.list("id", "en", "get-started");
id: string — The id of the self-service profile.
language: Management.SelfServiceProfileCustomTextLanguageEnum — The language of the custom text.
page: Management.SelfServiceProfileCustomTextPageEnum — The page where the custom text is shown.
requestOptions: CustomTextClient.RequestOptions
Updates text customizations for a given self-service profile, language and Self-Service Enterprise Configuration flow page.
</dd> </dl> </dd> </dl>await client.selfServiceProfiles.customText.set("id", "en", "get-started", {
key: "value",
});
id: string — The id of the self-service profile.
language: Management.SelfServiceProfileCustomTextLanguageEnum — The language of the custom text.
page: Management.SelfServiceProfileCustomTextPageEnum — The page where the custom text is shown.
request: Management.SetSelfServiceProfileCustomTextRequestContent
requestOptions: CustomTextClient.RequestOptions
Creates an access ticket to initiate the Self-Service Enterprise Configuration flow using a self-service profile.
</dd> </dl> </dd> </dl>await client.selfServiceProfiles.ssoTicket.create("id");
id: string — The id of the self-service profile to retrieve
request: Management.CreateSelfServiceProfileSsoTicketRequestContent
requestOptions: SsoTicketClient.RequestOptions
Revokes a Self-Service Enterprise Configuration access ticket and invalidates associated sessions. The ticket will no longer be accepted to initiate a Self-Service Enterprise Configuration session. If any users have already started a session through this ticket, their session will be terminated. Clients should expect a 202 Accepted response upon successful processing, indicating that the request has been acknowledged and that the revocation is underway but may not be fully completed at the time of response. If the specified ticket does not exist, a 202 Accepted response is also returned, signaling that no further action is required.
Clients should treat these 202 responses as an acknowledgment that the request has been accepted and is in progress, even if the ticket was not found.
await client.selfServiceProfiles.ssoTicket.revoke("profileId", "id");
profileId: string — The id of the self-service profile
id: string — The id of the ticket to revoke
requestOptions: SsoTicketClient.RequestOptions
Retrieve tenant settings. A list of fields to include or exclude may also be specified.
</dd> </dl> </dd> </dl>await client.tenants.settings.get({
fields: "fields",
include_fields: true,
});
request: Management.GetTenantSettingsRequestParameters
requestOptions: SettingsClient.RequestOptions
Update settings for a tenant.
</dd> </dl> </dd> </dl>await client.tenants.settings.update();
request: Management.UpdateTenantSettingsRequestContent
requestOptions: SettingsClient.RequestOptions
Retrieve detailed list of authentication methods associated with a specified user.
</dd> </dl> </dd> </dl>const pageableResponse = await client.users.authenticationMethods.list("id", {
page: 1,
per_page: 1,
include_totals: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.users.authenticationMethods.list("id", {
page: 1,
per_page: 1,
include_totals: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — The ID of the user in question.
request: Management.ListUserAuthenticationMethodsRequestParameters
requestOptions: AuthenticationMethodsClient.RequestOptions
Create an authentication method. Authentication methods created via this endpoint will be auto confirmed and should already have verification completed.
</dd> </dl> </dd> </dl>await client.users.authenticationMethods.create("id", {
type: "phone",
});
id: string — The ID of the user to whom the new authentication method will be assigned.
request: Management.CreateUserAuthenticationMethodRequestContent
requestOptions: AuthenticationMethodsClient.RequestOptions
Replace the specified user <a href="https://auth0.com/docs/secure/multi-factor-authentication/multi-factor-authentication-factors"> authentication methods</a> with supplied values.
<b>Note</b>: Authentication methods supplied through this action do not iterate on existing methods. Instead, any methods passed will overwrite the user’s existing settings.
await client.users.authenticationMethods.set("id", [
{
type: "phone",
},
]);
id: string — The ID of the user in question.
request: Management.SetUserAuthenticationMethodsRequestContent
requestOptions: AuthenticationMethodsClient.RequestOptions
Remove all authentication methods (i.e., enrolled MFA factors) from the specified user account. This action cannot be undone.
</dd> </dl> </dd> </dl>await client.users.authenticationMethods.deleteAll("id");
id: string — The ID of the user in question.
requestOptions: AuthenticationMethodsClient.RequestOptions
await client.users.authenticationMethods.get("id", "authentication_method_id");
id: string — The ID of the user in question.
authentication_method_id: string — The ID of the authentication methods in question.
requestOptions: AuthenticationMethodsClient.RequestOptions
Remove the authentication method with the given ID from the specified user. For more information, review <a href="https://auth0.com/docs/secure/multi-factor-authentication/manage-mfa-auth0-apis/manage-authentication-methods-with-management-api">Manage Authentication Methods with Management API</a>.
</dd> </dl> </dd> </dl>await client.users.authenticationMethods.delete("id", "authentication_method_id");
id: string — The ID of the user in question.
authentication_method_id: string — The ID of the authentication method to delete.
requestOptions: AuthenticationMethodsClient.RequestOptions
Modify the authentication method with the given ID from the specified user. For more information, review <a href="https://auth0.com/docs/secure/multi-factor-authentication/manage-mfa-auth0-apis/manage-authentication-methods-with-management-api">Manage Authentication Methods with Management API</a>.
</dd> </dl> </dd> </dl>await client.users.authenticationMethods.update("id", "authentication_method_id");
id: string — The ID of the user in question.
authentication_method_id: string — The ID of the authentication method to update.
request: Management.UpdateUserAuthenticationMethodRequestContent
requestOptions: AuthenticationMethodsClient.RequestOptions
Remove all authenticators registered to a given user ID, such as OTP, email, phone, and push-notification. This action cannot be undone. For more information, review <a href="https://auth0.com/docs/secure/multi-factor-authentication/manage-mfa-auth0-apis/manage-authentication-methods-with-management-api">Manage Authentication Methods with Management API</a>.
</dd> </dl> </dd> </dl>await client.users.authenticators.deleteAll("id");
id: string — ID of the user to delete.
requestOptions: AuthenticatorsClient.RequestOptions
Retrieve all connected accounts associated with the user.
</dd> </dl> </dd> </dl>const pageableResponse = await client.users.connectedAccounts.list("id", {
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.users.connectedAccounts.list("id", {
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — ID of the user to list connected accounts for.
request: Management.GetUserConnectedAccountsRequestParameters
requestOptions: ConnectedAccountsClient.RequestOptions
Retrieve the first <a href="https://auth0.com/docs/secure/multi-factor-authentication/multi-factor-authentication-factors">multi-factor authentication</a> enrollment that a specific user has confirmed.
</dd> </dl> </dd> </dl>await client.users.enrollments.get("id");
id: string — ID of the user to list enrollments for.
requestOptions: EnrollmentsClient.RequestOptions
List active federated connections tokensets for a provided user
</dd> </dl> </dd> </dl>await client.users.federatedConnectionsTokensets.list("id");
id: string — User identifier
requestOptions: FederatedConnectionsTokensetsClient.RequestOptions
await client.users.federatedConnectionsTokensets.delete("id", "tokenset_id");
id: string — Id of the user that owns the tokenset
tokenset_id: string — The tokenset id
requestOptions: FederatedConnectionsTokensetsClient.RequestOptions
List all groups to which this user belongs.
</dd> </dl> </dd> </dl>const pageableResponse = await client.users.groups.get("id", {
fields: "fields",
include_fields: true,
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.users.groups.get("id", {
fields: "fields",
include_fields: true,
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — ID of the user to list groups for.
request: Management.GetUserGroupsRequestParameters
requestOptions: GroupsClient.RequestOptions
Link two user accounts together forming a primary and secondary relationship. On successful linking, the endpoint returns the new array of the primary account identities.
Note: There are two ways of invoking the endpoint:
<ul> <li>With the authenticated primary account's JWT in the Authorization header, which has the <code>update:current_user_identities</code> scope: <pre> POST /api/v2/users/PRIMARY_ACCOUNT_USER_ID/identities Authorization: "Bearer PRIMARY_ACCOUNT_JWT" { "link_with": "SECONDARY_ACCOUNT_JWT" } </pre> In this case, only the <code>link_with</code> param is required in the body, which also contains the JWT obtained upon the secondary account's authentication. </li> <li>With a token generated by the API V2 containing the <code>update:users</code> scope: <pre> POST /api/v2/users/PRIMARY_ACCOUNT_USER_ID/identities Authorization: "Bearer YOUR_API_V2_TOKEN" { "provider": "SECONDARY_ACCOUNT_PROVIDER", "connection_id": "SECONDARY_ACCOUNT_CONNECTION_ID(OPTIONAL)", "user_id": "SECONDARY_ACCOUNT_USER_ID" } </pre> In this case you need to send <code>provider</code> and <code>user_id</code> in the body. Optionally you can also send the <code>connection_id</code> param which is suitable for identifying a particular database connection for the 'auth0' provider. </li> </ul> </dd> </dl> </dd> </dl>await client.users.identities.link("id");
id: string — ID of the primary user account to link a second user account to.
request: Management.LinkUserIdentityRequestContent
requestOptions: IdentitiesClient.RequestOptions
Unlink a specific secondary account from a target user. This action requires the ID of both the target user and the secondary account.
Unlinking the secondary account removes it from the identities array of the target user and creates a new standalone profile for the secondary account. To learn more, review <a href="https://auth0.com/docs/manage-users/user-accounts/user-account-linking/unlink-user-accounts">Unlink User Accounts</a>.
</dd> </dl> </dd> </dl>await client.users.identities.delete("id", "ad", "user_id");
id: string — ID of the primary user account.
provider: Management.UserIdentityProviderEnum — Identity provider name of the secondary linked account (e.g. google-oauth2).
user_id: string — ID of the secondary linked account (e.g. 123456789081523216417 part after the | in google-oauth2|123456789081523216417).
requestOptions: IdentitiesClient.RequestOptions
Retrieve log events for a specific user.
Note: For more information on all possible event types, their respective acronyms and descriptions, see <a href="https://auth0.com/docs/logs/log-event-type-codes">Log Event Type Codes</a>.
For more information on the list of fields that can be used in sort, see <a href="https://auth0.com/docs/logs/log-search-query-syntax#searchable-fields">Searchable Fields</a>.
Auth0 <a href="https://auth0.com/docs/logs/retrieve-log-events-using-mgmt-api#limitations">limits the number of logs</a> you can return by search criteria to 100 logs per request. Furthermore, you may only paginate through up to 1,000 search results. If you exceed this threshold, please redefine your search.
</dd> </dl> </dd> </dl>const pageableResponse = await client.users.logs.list("id", {
page: 1,
per_page: 1,
sort: "sort",
include_totals: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.users.logs.list("id", {
page: 1,
per_page: 1,
sort: "sort",
include_totals: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — ID of the user of the logs to retrieve
request: Management.ListUserLogsRequestParameters
requestOptions: LogsClient.RequestOptions
Invalidate all remembered browsers across all <a href="https://auth0.com/docs/multifactor-authentication">authentication factors</a> for a user.
</dd> </dl> </dd> </dl>await client.users.multifactor.invalidateRememberBrowser("id");
id: string — ID of the user to invalidate all remembered browsers and authentication factors for.
requestOptions: MultifactorClient.RequestOptions
Remove a <a href="https://auth0.com/docs/multifactor-authentication">multifactor</a> authentication configuration from a user's account. This forces the user to manually reconfigure the multi-factor provider.
</dd> </dl> </dd> </dl>await client.users.multifactor.deleteProvider("id", "duo");
id: string — ID of the user to remove a multifactor configuration from.
provider: Management.UserMultifactorProviderEnum — The multi-factor provider. Supported values 'duo' or 'google-authenticator'
requestOptions: MultifactorClient.RequestOptions
Retrieve list of the specified user's current Organization memberships. User must be specified by user ID. For more information, review <a href="https://auth0.com/docs/manage-users/organizations">Auth0 Organizations</a>.
</dd> </dl> </dd> </dl>const pageableResponse = await client.users.organizations.list("id", {
page: 1,
per_page: 1,
include_totals: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.users.organizations.list("id", {
page: 1,
per_page: 1,
include_totals: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — ID of the user to retrieve the organizations for.
request: Management.ListUserOrganizationsRequestParameters
requestOptions: OrganizationsClient.RequestOptions
Retrieve all permissions associated with the user.
</dd> </dl> </dd> </dl>const pageableResponse = await client.users.permissions.list("id", {
per_page: 1,
page: 1,
include_totals: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.users.permissions.list("id", {
per_page: 1,
page: 1,
include_totals: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — ID of the user to retrieve the permissions for.
request: Management.ListUserPermissionsRequestParameters
requestOptions: PermissionsClient.RequestOptions
Assign permissions to a user.
</dd> </dl> </dd> </dl>await client.users.permissions.create("id", {
permissions: [
{
resource_server_identifier: "resource_server_identifier",
permission_name: "permission_name",
},
],
});
id: string — ID of the user to assign permissions to.
request: Management.CreateUserPermissionsRequestContent
requestOptions: PermissionsClient.RequestOptions
Remove permissions from a user.
</dd> </dl> </dd> </dl>await client.users.permissions.delete("id", {
permissions: [
{
resource_server_identifier: "resource_server_identifier",
permission_name: "permission_name",
},
],
});
id: string — ID of the user to remove permissions from.
request: Management.DeleteUserPermissionsRequestContent
requestOptions: PermissionsClient.RequestOptions
Clear risk assessment assessors for a specific user
</dd> </dl> </dd> </dl>await client.users.riskAssessments.clear("id", {
connection: "connection",
assessors: ["new-device"],
});
id: string — ID of the user to clear assessors for.
request: Management.ClearAssessorsRequestContent
requestOptions: RiskAssessmentsClient.RequestOptions
Retrieve detailed list of all user roles currently assigned to a user.
<b>Note</b>: This action retrieves all roles assigned to a user in the context of your whole tenant. To retrieve Organization-specific roles, use the following endpoint: <a href="https://auth0.com/docs/api/management/v2/organizations/get-organization-member-roles">Get user roles assigned to an Organization member</a>.
</dd> </dl> </dd> </dl>const pageableResponse = await client.users.roles.list("id", {
per_page: 1,
page: 1,
include_totals: true,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.users.roles.list("id", {
per_page: 1,
page: 1,
include_totals: true,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
id: string — ID of the user to list roles for.
request: Management.ListUserRolesRequestParameters
requestOptions: RolesClient.RequestOptions
Assign one or more existing user roles to a user. For more information, review <a href="https://auth0.com/docs/manage-users/access-control/rbac">Role-Based Access Control</a>.
<b>Note</b>: New roles cannot be created through this action. Additionally, this action is used to assign roles to a user in the context of your whole tenant. To assign roles in the context of a specific Organization, use the following endpoint: <a href="https://auth0.com/docs/api/management/v2/organizations/post-organization-member-roles">Assign user roles to an Organization member</a>.
</dd> </dl> </dd> </dl>await client.users.roles.assign("id", {
roles: ["roles"],
});
id: string — ID of the user to associate roles with.
request: Management.AssignUserRolesRequestContent
requestOptions: RolesClient.RequestOptions
Remove one or more specified user roles assigned to a user.
<b>Note</b>: This action removes a role from a user in the context of your whole tenant. If you want to unassign a role from a user in the context of a specific Organization, use the following endpoint: <a href="https://auth0.com/docs/api/management/v2/organizations/delete-organization-member-roles">Delete user roles from an Organization member</a>.
</dd> </dl> </dd> </dl>await client.users.roles.delete("id", {
roles: ["roles"],
});
id: string — ID of the user to remove roles from.
request: Management.DeleteUserRolesRequestContent
requestOptions: RolesClient.RequestOptions
Retrieve details for a user's refresh tokens.
</dd> </dl> </dd> </dl>const pageableResponse = await client.users.refreshToken.list("user_id", {
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.users.refreshToken.list("user_id", {
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
user_id: string — ID of the user to get refresh tokens for
request: Management.ListRefreshTokensRequestParameters
requestOptions: RefreshTokenClient.RequestOptions
Delete all refresh tokens for a user.
</dd> </dl> </dd> </dl>await client.users.refreshToken.delete("user_id");
user_id: string — ID of the user to get remove refresh tokens for
requestOptions: RefreshTokenClient.RequestOptions
Retrieve details for a user's sessions.
</dd> </dl> </dd> </dl>const pageableResponse = await client.users.sessions.list("user_id", {
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.users.sessions.list("user_id", {
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
user_id: string — ID of the user to get sessions for
request: Management.ListUserSessionsRequestParameters
requestOptions: SessionsClient.RequestOptions
Delete all sessions for a user.
</dd> </dl> </dd> </dl>await client.users.sessions.delete("user_id");
user_id: string — ID of the user to get sessions for
requestOptions: SessionsClient.RequestOptions
List verifiable credential templates.
</dd> </dl> </dd> </dl>const pageableResponse = await client.verifiableCredentials.verification.templates.list({
from: "from",
take: 1,
});
for await (const item of pageableResponse) {
console.log(item);
}
// Or you can manually iterate page-by-page
let page = await client.verifiableCredentials.verification.templates.list({
from: "from",
take: 1,
});
while (page.hasNextPage()) {
page = page.getNextPage();
}
// You can also access the underlying response
const response = page.response;
request: Management.ListVerifiableCredentialTemplatesRequestParameters
requestOptions: TemplatesClient.RequestOptions
Create a verifiable credential template.
</dd> </dl> </dd> </dl>await client.verifiableCredentials.verification.templates.create({
name: "name",
type: "type",
dialect: "dialect",
presentation: {
"org.iso.18013.5.1.mDL": {
"org.iso.18013.5.1": {},
},
},
well_known_trusted_issuers: "well_known_trusted_issuers",
});
request: Management.CreateVerifiableCredentialTemplateRequestContent
requestOptions: TemplatesClient.RequestOptions
Get a verifiable credential template.
</dd> </dl> </dd> </dl>await client.verifiableCredentials.verification.templates.get("id");
id: string — ID of the template to retrieve.
requestOptions: TemplatesClient.RequestOptions
Delete a verifiable credential template.
</dd> </dl> </dd> </dl>await client.verifiableCredentials.verification.templates.delete("id");
id: string — ID of the template to retrieve.
requestOptions: TemplatesClient.RequestOptions
Update a verifiable credential template.
</dd> </dl> </dd> </dl>await client.verifiableCredentials.verification.templates.update("id");
id: string — ID of the template to retrieve.
request: Management.UpdateVerifiableCredentialTemplateRequestContent
requestOptions: TemplatesClient.RequestOptions