Publish an API to Developer Portal

About this task

You can expose APIs that you create in webMethods API Gateway to consumers by publishing them to a webMethods Developer Portal. webMethods Developer Portal lists the published APIs and their versions, provides documentation of their functions and allows you to register applications.

The following example describes how to configure a webMethods Developer Portal instance as a destination, publish your Search Cruise REST API to Developer Portal, view the published API from Developer Portal, and try out the API in webMethods Developer Portal.

Before you begin, make sure that the Search Cruise API you want to expose is created.

Procedure

  1. Make sure that you configure webMethods Developer Portal as a destination to publish your API.
    If you have not configured the destination, perform the following steps.
    • Log on to webMethods API Gateway instance.
    • Open the menu options and select Administration.
    • Click Destinations > Developer Portal > Configuration.
    • Provide API key for Portal and Gateway configuration.

    • Click Publish to save the destination details.
  2. Make sure that the API you want to publish is activate.
    This action is necessary so that the consumers can access the gateway localhost and use the API. If the API is not in an active state, perform the following steps.
    1. Open the menu options and select APIs.
    2. Select Search Cruise API from the list of APIs and click Activate to activate the API.
  3. Publish the API to Developer Portal.
    1. Open the menu options and select APIs.
    2. Click the publish icon for the Search Cruise API.
    3. Select Developer Portal and select the communities. The default community is public, and all users have access to this community.
    4. Click Publish. The API is published to Developer Portal. A success message displays when the AI is successfully published to webMethods Developer Portal.
  4. View the Published API in the Developer Portal.
    1. Click the App Switcher icon and select IBM webMethods Developer Portal
    2. Click API gallery in the title navigation bar. You can see the published API.
  5. Try out the API.
    1. In the API gallery page, click View details > Try API for Search Cruise.
    2. Select a stage of the API that you want to test in the Environment field. The applications that are associated with the selected stage appear in the Applications field.
    3. Click the Application to be tested and select a resource from the list that appears.
    4. Select a method and type in a value for the path and query parameters and its corresponding value.
    5. Select Authorization > Authorization type and provide the corresponding API key.
    6. Type in the Header names and corresponding values in the Headers tab.
    7. Click Send. The request and the response of the API appear.