webMethods Developer Portal REST APIs

You can use the headless architecture feature of webMethods Developer Portal to build an application with the webMethods Developer Portal functions.

You can use the REST APIs that come along with the webMethods Developer Portal installation to perform all functions that you can accomplish through the application's user interface.

Authentication to use webMethods Developer Portal REST APIs

Consumers can provide their webMethods Developer Portal credentials through the HTTP basic authentication method to access the REST APIs.

The users with the API management admin, user and partner roles require an API key and a MCSP token (to be provided as bearer token during invocation) to access the webMethods Developer Portal REST APIs.

Perform the following steps to generate the required inputs.
  • Create API keys from IBM SaaS Console. API keys are mapped with the user roles and thus you should generate an API key for the role by using which you want to invoke APIs.
    • To invoke APIs as an administrator, generate API key for the API management admin, Service admin, or Service owner role.
    • To invoke APIs as a provider, generate API key for the API management user or Service user role.
    • To invoke APIs as a partner, generate API key for the API management partner role.
    For information about creating API keys, see Granting access through service IDs and API keys from the IBM SaaS Console.
  • Using the API key generated from the previous step, make a REST call to the following endpoint with the API key in a request body.
    POST  https://account-iam.platform.saas.ibm.com/api/2.0/services/instanceID/apikeys/token
    {
      "apikey”:”api_key”
    }

    Sample

    POST  https://account-iam.platform.saas.ibm.com/api/2.0/services/20250310=1240-2902-1090-2462ced1b251/apikeys/token
    {
      "apikey": "azI6YTc3NDc3NmEtYTI2YS00YWQzLTg1ODYzOTdiZWZjZmJhOldCVHpQb1JG3BCNHlwcVNEQ3FValhwRlVoMlVrWmhUZ2VLcXNEbW89"
    }
    A token is generated and is valid for two hours.
  • Use the generated token value as the bearer token in the request header during API invocation.

Access privileges-based authorization

The availability of API resources is based on the user privilege. Typically, users who have the API mnagement admin privilege have access to all APIs, whereas the users the other privileges have limited access of API resources.

REST APIs URI format

You can access the webMethods Developer Portal resources by using URI paths. The REST call URI must be specified with corresponding methods in the following format.

http://host:port/portal/rest/v1/resource-name
The URI includes
webMethods Developer Portal URL
For example, http://host:port
Base path
For example, portal/rest
Version
For example, V1
Resource path
For example, apis

Possible response messages

The following table lists the possible response messages and what they indicate.
Response message Description
200 - OK The request is sent and a response is received.
201 - Created The request is fulfilled, resulting in the creation of a new resource.
400 - Bad request A parameter is missing in the request due to which it cannot be processed.
401 - Unauthorized Authorization problem.
403 - Forbidden No permission is available to the requested resource.
404 - Not found The requested resource does not exist.
500 - Internal server error An unexpected condition is encountered and no more specific message is suitable.

List of APIs

The following REST APIs are available in webMethods Developer Portal.