Using the modules commands
You can use the modules commands to list, enable, disable and delete the modules on your Developer Portal service.
- Log in as Provider org:
apic login --server management_server --realm provider/identity_provider --username provider_username --password provider_passwordYou can determine which identity provider to use in the--realmparameter 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):
For example,apic identity-providers:list --scope provider --server platform_api_endpoint_url --fields title,realm
Theapic identity-providers:list --scope provider --server platform_api_endpoint_url --fields title,realm total_results: 2 results: - title: API Manager User Registry realm: provider/default-idp-2 - title: Corporate LDAP user registry realm: provider/corporate-ldaptitlevalue should enable you to determine which identity provider to use; you can then copy the corresponding--realmparameter directly from the displayedrealmvalue. For any identity providers that your administrator created after API Connect was installed, the names are determined at creation time. The default API Manager Local User Registry for login as a member of a provider organization isdefault-idp-2.For full details of the
apic logincommand, see Logging in to a management server.For a summary of the general-purpose commands and their use, see Developer Portal CLI commands.
- List the modules from a packagename. For example,
apic --mode portaladmin modules:list --org orgid/name --server management_server --catalog name/id --package packagename1,packagename2 - Enable the modulename module. You can upload this module by using the
custom-module:create-import command. For more information, see Using the custom-module commands.For example,
apic --mode portaladmin modules:enable --org orgid/name --server management_server --catalog name/id --modules modulenamemanagement_serveris the endpoint URL of the management server (required).catalogid/nameis the ID or name of the catalog that the site belongs to (required).orgid/nameis the ID or name of the provider organization that the catalog belongs to (required).--packageenables you to filter by project packages. You can use multiple comma separated values.--statusenables you to filter by extension status. Can be_ enabled,disabledand/or'not installed'. You can use multiple comma separated values.--customenables you to filter your results to only the modules that you have installed on your Developer Portal site.
- Disable the modulename module. If you disable a module, you must also disable
all its dependencies. For example,
apic --mode portaladmin modules:disable --org orgid/name --server management_server --catalog name/id --modules modulename,module_lib - Delete the modulename module. The module and all its dependencies must be
disabled before you can delete them.For example,
apic --mode portaladmin modules:delete --org orgid/name --server management_server --catalog name/id --modules modulename
Note that if you want to manage the Forum module, you can use the
forums commands. For more information, see Using the forums commands.