Using the factory-reset command

You can use the factory-reset command to perform a factory reset of your Developer Portal, which will delete the portal service and all of its associated Developer Portal sites.

Warning: The factory-reset command is irreversible. You must ensure that you have backups created before running this command.
  1. Log in as Cloud manager:
    apic login --server management_server --realm admin/identity_provider --username admin --password cloud_password
    You can determine which identity provider to use in the --realm parameter by entering the following command to see a list of all available identity providers (you do not need to be logged in to use this command):
    apic identity-providers:list --scope admin --server mgmt_endpoint_url --fields title,realm
    For example:
    apic identity-providers:list --scope admin --server myserver.com --fields title,realm
    total_results: 2
    results:
      - title: Cloud Manager User Registry
        realm: admin/default-idp-1
      - title: Corporate LDAP user registry
        realm: admin/corporate-ldap
    The title value should enable you to determine which identity provider to use; you can then copy the corresponding --realm parameter directly from the displayed realm value. For any identity providers that were created by your administrator after API Connect was installed, the names will have been determined at creation time. The default Cloud Manager Local User Registry for login as a member of the cloud administration organization is default-idp-1.

    For full details of the apic login command, see Logging in to a management server.

  2. Output a dry run status of a Developer Portal factory reset:
    apic --mode portaladmin factory-reset:delete --server management_server --portal_service_endpoint portal_endpoint
    • management_server is the endpoint URL of the management server.
    • portal_endpoint is the URL endpoint of the portal service.
    For example:
    apic --mode portaladmin factory-reset:delete --server api.stagingexample.com --portal_service_endpoint https://api.portal.mystack.com
  3. Perform a factory reset of the Developer Portal, deleting the portal service and all of its associated Developer Portal sites:
    Warning: The factory-reset command is irreversible. You must ensure that you have backups created before running this command.
    apic --mode portaladmin factory-reset:delete --server management_server --portal_service_endpoint portal_endpoint --execute_reset true
    • --execute_reset must be set to true to trigger the Developer Portal reset.
    For example:
    apic --mode portaladmin factory-reset:delete --server api.stagingexample.com --portal_service_endpoint https://api.portal.mystack.com  --execute_reset true