REST Management API
A REST API is available for managing the gateway. You can install this API either from the Policy Manager or automatically on new Gateways using auto-provisioning.
A REST API is available for managing the
CA API Gateway. You can install this API either from the Policy Manager or automatically on new Gateways using auto-provisioning.
When you create a configuration initially, it is best to use the Policy Manager first, then use the REST Management API to manipulate the template. This is easier and less error prone than attempting to create the configuration solely using the REST Management API.
Observe the following when using the REST Management API:
- Do not use encoded XML with the REST Management API, as it is not parsed correctly.
- Do not use "%0A" in URLs. This string is translated into a line feed, which causes issues.
Publish the REST Management Service
You can publish the REST Management Service using
eitherof the following methods:
- Via the the GUI in the Policy Manager
- Auto-provision via the command line (Policy Manager not required)
To publish the REST Management API from the Policy Manager:
- In Policy Manager, select [Tasks] >Services and APIs > Publish Internal Servicefrom the main menu (in the browser client, use the [Manage] menu).
- From list of services, selectGateway REST Management Service.
- Optionally, change theRouting URIif necessary.Note:The routing URI must always end with/*.
- Click [Finish] to publish the service.The Gateway REST Management Service is created and resides in the root folder.
To publish the REST Management API using auto-provisioning:
You can auto-provision only on new or restored Gateways that have no other services installed.
- Log in asssgconfigand open a privileged shell.
- Run the following commands to create an empty file named "restman" in the specified folder:# mkdir -p touch /opt/SecureSpan/Gateway/node/default/etc/bootstrap/services/ # touch /opt/SecureSpan/Gateway/node/default/etc/bootstrap/services/restman
- Exit the privileged shell.The REST Management Service is auto-provisioned the next time the Gateway is restarted.
Access the REST Management API Documentation
Documentation for the REST Management API is available at this location, available after the REST Management API is published:
Log in with your Policy Manager credentials when prompted.
If you enter incorrect credentials, an "Authentication Failed" message is displayed. Trying to access the REST Management API documentation again may simply repeat this error and not prompt for credentials again. If this happens, try these troubleshooting tips:
- Close the browser tab and open a new tab.
- Clear your browser's cache.
- Access the URL in "private browsing" or "incognito" mode in your browser.
The online REST Management API documentation is organized across the following sections:
- Getting Started:Shows how to make a basic REST API call. Provides basic navigation information about the API.
- Authentication:Describes how to authenticate and how users are restricted.
- Resources:Contains a list of all the API resource endpoints. Lists the URLs, parameters, responses, and anything else required to make an API call to the resource.
- Migration:Describes the migration process. Includes information on how to bundle, how to import, and how to resolve mapping issues.
The REST Management API is available online only. There is no offline version.