Skip to content

Conversation

@tanya732
Copy link
Contributor

@tanya732 tanya732 commented Nov 5, 2025

Changes

Added below Changes

Below are the changes in following endpoints

Change Type Method Endpoint Method Name
NEW POST /api/v2/connection-profiles create
NEW GET /api/v2/connection-profiles getAll
NEW PATCH /api/v2/connection-profiles/{id} update
NEW GET /api/v2/connection-profiles/{id} get
NEW DELETE /api/v2/connection-profiles/{id} delete
NEW GET /connection-profiles/templates getTemplate
NEW GET /connection-profiles/templates/{id} getAllTemplates
MODIFIED GET /clients/{client_id} get
MODIFIED GET /clients getAll
MODIFIED POST /clients create
MODIFIED UPDATE /clients/{client_id} update
MODIFIED POST //clients/{client_id}/rotate-secret rotateClientSecret

Manual Testing Snippet

  1. Install auth0 npm install auth0
  2. Get Domain, Client Id and Client Secret from Auth0 Dashboard
// Create ManagementClient instance
    const authClient = new ManagementClient({
      domain: "<DOMAIN>",
      clientId: "<CLIENT_ID>",
      clientSecret: "<CLIENT_SECRET>"
    })    

// Create Connection Profile 
    const createPayload: CreateConnectionProfileRequestContent = {
      name: "Another Connection Profile - 6",
    }

  const createConnectionProfiles = await authClient.connectionProfiles.create(createPayload);
  console.log("createConnectionProfiles", createConnectionProfiles);

// Update Connection Profile 
  const updateConnectionProfiles = await authClient.connectionProfiles.update({ id: createConnectionProfiles.data.id! }, {
    organization: {
      show_as_button: "optional",
      assign_membership_on_login: "optional"
    },
    strategy_overrides: {
      pingfederate: {
        enabled_features: ["universal_logout"],
        connection_config: undefined
      }
    }
  });
  console.log("updateConnectionProfiles", updateConnectionProfiles);

// Update Connection Profile by setting fields as null
  const updateConnectionProfilestoSetStrategyOverridesAsNull = await authClient.connectionProfiles.update({ id: createConnectionProfiles.data.id! }, {
    strategy_overrides: null as any
  });
  console.log("updateConnectionProfilestoSetStrategyOverridesAsNull", updateConnectionProfilestoSetStrategyOverridesAsNull);

// Get Connection Profile
  const getConnectionProfiles = await authClient.connectionProfiles.get({ id: createConnectionProfiles.data.id! });
  console.log("getConnectionProfiles", getConnectionProfiles);

// Get All Connection Profiles
  const getAllConnectionProfiles = await authClient.connectionProfiles.getAll();
  console.log("getAllConnectionProfiles", getAllConnectionProfiles);

// Get Connection Profile Template
  const getConnectionProfileTemplate = await authClient.connectionProfiles.getTemplate({id: "auth0-generic"});
  console.log("getConnectionProfileTemplate", getConnectionProfileTemplate);

// Get All Connection Profile Templates
  const getConnectionProfileTemplates = await authClient.connectionProfiles.getAllTemplates();
  console.log("getConnectionProfileTemplates", getConnectionProfileTemplates.data.connection_profile_templates);

// Added express_configuration 
const createClientPayload: ClientCreate = {
    name : "For Connection Profiles",
    express_configuration: {
      initiate_login_uri_template: "https://myapp.com/sso/start?org={organization_name}{organization_id}&conn={connection_name}",
      user_attribute_profile_id: "<ID>",
      connection_profile_id: "<ID>",
      enable_client: true,
      enable_organization: true,
      okta_oin_client_id: "<ID>",
      admin_login_domain: "www.google.com"
    }
  };

    const createClient = await auth0.clients.create(createClientPayload);
    console.log('createClient Response Data:', createClient.data);

    const getClient = await auth0.clients.get({ client_id: createClient.data.id! });
    console.log('getClient Response Data:', getClient.data);

@tanya732 tanya732 marked this pull request as ready for review November 6, 2025 08:14
@tanya732 tanya732 requested a review from a team as a code owner November 6, 2025 08:14
kushalshit27
kushalshit27 previously approved these changes Nov 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants