Skip to main content
The Management API client provides access to Auth0’s Management API endpoints for managing your Auth0 tenant resources programmatically.

Management Client Structure

The Management struct is the main entry point for interacting with Auth0’s Management API. It provides access to all resource managers through dedicated client properties.
type Management struct {
    Actions               *client.Client
    Branding              *brandingclient.Client
    ClientGrants          *clientgrantsclient.Client
    Clients               *clientsclient.Client
    ConnectionProfiles    *connectionprofiles.Client
    Connections           *connectionsclient.Client
    CustomDomains         *customdomains.Client
    DeviceCredentials     *devicecredentials.Client
    EmailTemplates        *emailtemplates.Client
    EventStreams          *eventstreamsclient.Client
    Flows                 *flowsclient.Client
    Forms                 *forms.Client
    UserGrants            *usergrants.Client
    Groups                *groupsclient.Client
    Hooks                 *hooksclient.Client
    Jobs                  *jobsclient.Client
    LogStreams            *logstreams.Client
    Logs                  *logs.Client
    NetworkACLs           *networkacls.Client
    Organizations         *organizationsclient.Client
    Prompts               *promptsclient.Client
    RefreshTokens         *refreshtokens.Client
    ResourceServers       *resourceservers.Client
    Roles                 *rolesclient.Client
    Rules                 *rules.Client
    RulesConfigs          *rulesconfigs.Client
    SelfServiceProfiles   *selfserviceprofilesclient.Client
    Sessions              *sessions.Client
    Stats                 *stats.Client
    SupplementalSignals   *supplementalsignals.Client
    Tickets               *tickets.Client
    TokenExchangeProfiles *tokenexchangeprofiles.Client
    UserAttributeProfiles *userattributeprofiles.Client
    UserBlocks            *userblocks.Client
    Users                 *usersclient.Client
    Anomaly               *anomalyclient.Client
    AttackProtection      *attackprotectionclient.Client
    Emails                *emailsclient.Client
    Guardian              *guardianclient.Client
    Keys                  *keysclient.Client
    RiskAssessments       *riskassessmentsclient.Client
    Tenants               *tenantsclient.Client
    VerifiableCredentials *verifiablecredentialsclient.Client
}

Resource Managers

Each property on the Management struct provides access to specific Auth0 resources:

Core Resources

  • Actions - Manage Auth0 Actions and custom code execution
  • Clients - Manage applications and their configurations
  • Connections - Manage identity providers and databases
  • Users - Manage user accounts and profiles
  • Roles - Manage roles and role-based access control
  • Organizations - Manage organizations (B2B features)

Authentication & Security

  • Guardian - Manage multi-factor authentication settings
  • AttackProtection - Configure attack protection features
  • Anomaly - Access anomaly detection settings
  • RiskAssessments - Manage risk assessment configurations
  • SupplementalSignals - Configure supplemental security signals

Branding & UI

  • Branding - Manage tenant branding and themes
  • Prompts - Customize Universal Login prompts
  • Forms - Manage custom forms
  • EmailTemplates - Customize email templates

Authorization

  • ClientGrants - Manage M2M authorization grants
  • ResourceServers - Manage APIs and their scopes
  • UserGrants - Manage user consent grants
  • Groups - Manage user groups

Advanced Features

  • Flows - Manage Auth0 Flows (Actions successor)
  • Hooks - Manage extensibility hooks
  • Rules - Manage legacy Rules
  • RulesConfigs - Manage Rules configuration

Integrations & Events

  • LogStreams - Configure log streaming to external services
  • EventStreams - Manage event streams for real-time updates
  • Logs - Access tenant logs and events

Tenant Management

  • Tenants - Manage tenant settings
  • Stats - Access tenant statistics
  • CustomDomains - Manage custom domains
  • NetworkACLs - Configure network access controls
  • Emails - Manage email provider settings

User Management

  • UserBlocks - Manage blocked users
  • DeviceCredentials - Manage device credentials
  • RefreshTokens - Manage refresh tokens
  • Sessions - Manage user sessions
  • Tickets - Generate verification and password reset tickets

Identity & Federation

  • ConnectionProfiles - Manage connection profiles
  • TokenExchangeProfiles - Configure token exchange
  • UserAttributeProfiles - Manage user attribute mappings
  • VerifiableCredentials - Manage verifiable credentials
  • SelfServiceProfiles - Configure self-service features

Jobs & Operations

  • Jobs - Manage background jobs (imports, exports)

Example Usage

Once you have initialized a Management client, you can access any resource manager:
import (
    "context"
    "github.com/auth0/go-auth0/v2/management"
    "github.com/auth0/go-auth0/v2/management/client"
    "github.com/auth0/go-auth0/v2/management/option"
)

func main() {
    mgmt, err := client.New(
        "your-tenant.auth0.com",
        option.WithClientCredentials(
            context.Background(),
            "YOUR_CLIENT_ID",
            "YOUR_CLIENT_SECRET",
        ),
    )
    if err != nil {
        // Handle error
    }

    ctx := context.Background()

    // List all clients
    clients, err := mgmt.Clients.List(ctx, &management.ListClientsRequestParameters{})
    
    // Get a user
    user, err := mgmt.Users.Get(ctx, "auth0|123")
    
    // List connections
    connections, err := mgmt.Connections.List(ctx, &management.ListConnectionsRequestParameters{})
    
    // Get tenant settings
    tenant, err := mgmt.Tenants.Get(ctx, &management.GetTenantSettingsRequestParameters{})
}

Next Steps

Build docs developers (and LLMs) love