# Configure a new API proxy endpoint
Complete the following steps to configure a new API proxy endpoint:
- Prerequisites
- Step 1: Create the endpoint
- Step 2: View the proxy endpoint
- Step 3: Configure the schema
# Prerequisites
Before creating a new API proxy endpoint, ensure that you complete the following prerequisites:
- Create an HTTP connection to enable Workato to forward requests to the external API.
- Create an API proxy collection to organize related endpoints.
- Review the endpoint path guidelines to ensure consistent and valid path configurations.
# Create the endpoint
Complete the following steps to create a proxy endpoint:
Go to Platform > API platform > API collections and select the API proxy collection for which you plan to create the new endpoint.
Select + New endpoint.
Select + New endpoint
Fill in the following fields:
HTTP method
Use the HTTP method drop-down menu to specify the method for the endpoint.
Endpoint name
Enter a descriptive name for the proxy endpoint.
Endpoint path
Define a path to append to both proxy and target base URLs, which can include path parameters. Ensure that the path follows the endpoint path guidelines.
Request timeout
Enter the Request timeout duration to set the time allowed for a request to complete. The value must be between 1 and 30 seconds, with 30 seconds as the maximum and default value.
Select Add endpoint. The new proxy endpoint appears on the API collection page.
Click ••• (ellipsis) next to the endpoint to rename, activate, or delete it.
# View the proxy endpoint
Select an API endpoint in the API collection overview to view its details. You can also download these details in the OpenAPI 2.0 specification from the API collection overview.
A proxy-based endpoint includes the following tabs:
# Configure the schema
IMPORT OPENAPI SPEC FOR AUTOMATIC SETUP
To automatically configure the endpoint schema, select Import OpenAPI specification when creating a new API proxy collection. Workato will populate the schema for each endpoint in the collection.
If you created an endpoint manually or selected Manual configuration when setting up the API proxy collection, configure the schema and headers in the New API proxy request trigger.
Complete the following steps to configure the schema:
Open the New API proxy request trigger from your proxy workflow.
Expand the Request section and configure the following fields:
Request body
Define the schema for the body of incoming requests. This applies to HTTP methods like POST, PUT, or PATCH. You can either paste a sample JSON payload or add fields manually.
Request query parameters
Describe one or more request query parameters.
Request headers
Add any required headers to the request.
Expand the Response schema section and configure the following fields:
Response content type
Required. Specify the format of the response, such as JSON or XML.
Response headers
Specify any headers that you plan to include in the HTTP response.
Responses
Required. Specify at least one HTTP status code, such as
200 - OK
, and describe the expected response body schema. Click Use JSON to paste or upload example JSON output, or manually define fields in the response body.
Click Save to apply your changes.
Your schema configuration is complete. To learn how to test your new proxy endpoint, see Test a proxy endpoint.
Last updated: 12/10/2024, 3:05:53 AM