Use the GET
method on the /api-definitions/{id}
endpoint to export an API definition
from Talend Cloud API Designer.
For use cases using this request, see Talend Cloud API Designer Examples.
Before you begin
- You have an API in Talend Cloud API Designer.
- You have generated a Personal Access Token. For further information, see Generating a Personal Access Token.
Procedure
- Open Talend Cloud API Tester and create a new request.
-
Keep the default
GET
method and enter the following URI with the correct parameters:https://apid.{region}.cloud.talend.com/api/v1/api-definitions/{api-id}
Parameter Description {region}
Region for your Talend Cloud account. The value can be: -
us-west
-
us
-
eu
-
ap
-
au
For more information, see Talend Cloud regions and URLs.
{api-id}
ID of the API version to fetch. To get it, open your API in Talend Cloud API Designer and go to Settings > MANAGEMENT API or use the GET
method on the/api-definitions
endpoint to get a list of API definitions with their IDs. -
- Optional:
Expand QUERY PARAMETERS
and click Add query parameters.
The following parameters are available:
Parameter Description format Format in which you want to export your definition. The value can be: - OpenApi3 (default value)
- Swagger20
- Swagger12
- Raml10
- Raml08
- OpenApi3Aws (format compatible with AWS API Gateway)
- Swagger20Azure (format compatible with Azure API Management)
talendExtensions Specify if you want your exported definition to contain Talend extensions or annotations. The value can be true or false. The default value is false. Note: Talend extensions are not compatible with AWS API Gateway and Azure API Management. If you have entered OpenApi3AWS or Swagger20Azure in the format parameter, this parameter is ignored. -
Click the Add header
button and enter Authorization in the
name field and Bearer followed by a space and your token in the
value field.
Tip: In Talend Cloud API Tester, you can add your token as a private environment variable and reference it in your requests using the expression builder. For more information, see Using environments.
-
Once your request is configured, click Send.
Example