Tutorial: Synchronizing application credentials from the Developer Portal with an external server

You can synchronize application credentials from the Developer Portal with an external server.

Before you begin

You must have administrator access to complete this task.

Download the Application credential synchronization folder.

Perform the following steps:

  1. Clone the custom module. Here is an example if you are using Mac and Linux:
    git clone https://github.com/ibm-apiconnect/devportal-addons
  2. Navigate to the appcreds_sync folder:
    cd devportal-addons/apic_v10/modules/appcreds_sync
    

About this task

In this tutorial, you configure a custom module and install it in the Developer Portal to synchronize application credentials between the Developer Portal and an external credentials server.

The appcreds_sync folder that you downloaded is a custom module that contains multiple methods that can be configured with your REST endpoints, and any further specifications that you want to define, to synchronize your Developer Portal application credentials with an external credential server.

For more information, see Custom module development: background and prerequisites.

Procedure

To configure the custom module to synchronize application credentials:

  1. In the appcreds_sync.module file, replace example.com with your REST endpoint for the following method types:
    • http://example.com/app/create
    • http://example.com/app/delete
    • http://example.com/app/creds/create
    • http://example.com/app/creds/update
    • http://example.com/app/creds/delete
    • http://example.com/app/clientid/reset
    • http://example.com/app/clientsecret/reset
  2. Optional: Replace username and password with your username and password in the _appcreds_sync_json_http_request function:
    ('username' . ':' . 'password')
    Note: You can also configure the SSL settings if you need to.
  3. Save the file, and package up the custom module:
    cd..
    tar -czf appcreds_sync.tar.gz appcreds_sync/

To install the configured custom module in the Developer Portal:

  1. Log in to your Developer Portal as an administrator.
  2. If the administrator dashboard does not display, click Manage.
  3. Click Extend > Install new module.
  4. In the Add from a URL field, enter a path to the module . Alternatively, upload the module in the Upload a module or theme archive section.
  5. Click Continue.

To enable the module:

  1. If the administrator dashboard does not display, click Manage.
  2. Click Extend and search for the custom module just installed, for example, Synchronise Application Credentials.
  3. Select the check box and click Enable.

Results

You have configured a custom module that synchronizes application credentials from the Developer Portal, installed that module in the Developer Portal, and enabled it. No further action or configuration is required.