Software AG Products 10.7 | Using API Gateway | REST APIs in API Gateway | Service Management
 
Service Management
API Gateway provides the capability to retrieve and manage all APIs in API Gateway and the related information such as applications associated, scopes, versions and so on.
API Gateway provides the following REST API and the resources to manage services:
*GET/rest/apigateway/apis/{apiId}: Retrieves an API based on the apiId specified.
*PUT/rest/apigateway/apis/{apiId}: Updates an API by importing a file, URL or inline based on the apiId specified.
*DELETE/rest/apigateway/apis/{apiId}: Deletes an API based on the apiId specified.
*PUT/rest/apigateway/apis/{apiId}/activate: Activates an API so that the API is exposed to consumers.
*PUT/rest/apigateway/apis/{apiId}/deactivate: Deactivates an API so that the API is not exposed to consumers.
*PUT/rest/apigateway/apis/{apiId}/publish: Publishes API to the registered API Portal.
*PUT/rest/apigateway/apis/{apiId}/unpublish: Unpublishes an API from the registered API Portal.
*PUT/rest/apigateway/apis/{apiId}/mock/enable: Enables you to mock an API by simulating the native service.
*PUT/rest/apigateway/apis/{apiId}/mock/disable: Disables the mocking capability to mock an API.
*GET/rest/apigateway/apis: Retrieves all APIs or subset of APIs based on the apiIds specified.
*POST/rest/apigateway/apis: Creates an API as specified. You can create an API by importing a file, URL, or from scratch.
*DELETE/rest/apigateway/apis: Deletes APIs based on the apiIds specified.
*GET/rest/apigateway/apis/{apiId}/applications: Retrieves the list of registered applications of an API.
*GET/rest/apigateway/apis/{apiId}/source: Retrieves the source file along with the root file name that was used while creating an API.
*GET/rest/apigateway/apis/{apiId}/globalPolicies: Retrieves the list of active global policies applicable for the specified API.
*GET/rest/apigateway/apis/{apiId}/versions: Retrieves all versions of the specified API.
*POST/rest/apigateway/apis/{apiId}/versions: Creates a new version of an API and retains applications if required.
*GET/rest/apigateway/apis/{apiId}/scopes: Retrieves the scopes for the specified API.
*GET/rest/apigateway/apis/{apiId}/scopes/{scopeName}: Retrieves the scopes for the specified API based on the scope name.
*PUT/rest/apis/{apiId}/implementation: Updates the API in API Gateway after its implementation by any API provider tool. This is used by API provider tools to update the API after implementing from their end.
*GET/rest/apis/{apiId}/providerspecification: Downloads the provider specification of REST and SOAP based APIs. Provider specification is nothing but, the specification file (in swagger or wsdl format) with out the concrete API Gateway endpoint and contains all resources, methods, and operations irrespective of whether their exposure to consumer.
*PUT/rest/apigateway/serviceRegistry/unpublish: Unpublishes one or more APIs from one or more service registries.
*GET/rest/apigateway/serviceRegistry/publish: Retrieves the service registry publish information for the API.
*PUT/rest/apigateway/serviceRegistry/publish: Publishes one or more APIs from one or more service registries.
For details about the REST API, see the APIGatewayServiceManagement.json at SAGInstallDir/IntegrationServer/instances/default/packages/WmAPIGateway/resources/apigatewayservices.
For details on sample payloads, import Postman collection from the following link in Postman client: https://github.com/SoftwareAG/webmethods-api-gateway/blob/10.7/apigatewayservices/postmancollections/apis/service-management/ServiceManagement.json.
For sample use cases, see https://github.com/SoftwareAG/webmethods-api-gateway/tree/10.7/apigatewayservices/postmancollections/usecases.