docs/interfaces/management.ManagementClient.ManagementClientOptionsWithClientSecret.html
Configuration for client credentials authentication using client secret. Use this for server-to-server authentication with a client secret.
const client = new ManagementClient({ domain: 'your-tenant.auth0.com', clientId: 'your-client-id', clientSecret: 'your-client-secret'});Copy
interface ManagementClientOptionsWithClientSecret {
headers?: Record<string, Supplier<string | null | undefined>>;
timeoutInSeconds?: number;
maxRetries?: number;
logging?: LogConfig | Logger;
domain: string;
audience?: string;
telemetry?: boolean;
clientInfo?: { name: string; [key: string]: unknown };
withCustomDomainHeader?: string;
clientId: string;
clientSecret: string;
useMTLS?: boolean;
}
headers?timeoutInSeconds?maxRetries?logging?domainaudience?telemetry?clientInfo?withCustomDomainHeader?clientIdclientSecretuseMTLS?
Optionalheadersheaders?: Record<string, Supplier<string | null | undefined>>
Additional headers to include in requests.
OptionaltimeoutInSecondstimeoutInSeconds?: number
The default maximum time to wait for a response in seconds.
OptionalmaxRetriesmaxRetries?: number
The default number of times to retry the request. Defaults to 2.
OptionalloggingConfigure logging for the client.
domain: string
Auth0 domain (e.g., 'your-tenant.auth0.com')
Optionalaudienceaudience?: string
API audience. Defaults to https://{domain}/api/v2/
https://{domain}/api/v2/
Optionaltelemetrytelemetry?: boolean
Enable/disable telemetry. Defaults to true
trueCopy
OptionalclientInfoclientInfo?: { name: string; [key: string]: unknown }
Custom client information for telemetry
OptionalwithCustomDomainHeaderwithCustomDomainHeader?: string
Custom domain Header to use for whitelisted requests. When provided, the Auth0-Custom-Domain header will be added automatically to supported endpoints. This works seamlessly with custom fetchers - both the custom domain logic and your custom fetcher will be applied.
clientId: string
Auth0 application client ID
clientSecret: string
Auth0 application client secret
OptionaluseMTLSuseMTLS?: boolean
Enable mTLS for token endpoint calls
Member Visibility
ThemeOSLightDark
Properties headerstimeoutInSecondsmaxRetriesloggingdomainaudiencetelemetryclientInfowithCustomDomainHeaderclientIdclientSecretuseMTLS