Add a native endpoint
The OpenAPI Specification explains the structure and purpose of an endpoint specification. If you create a Service from a specification, APIM 3.0 defines the endpoints, paths, HTTP methods, and configures the request and response for you. You simply need to select the appropriate tasks.
In contrast, to add a Triggered Task or Ultra Task endpoint to a Service created from scratch:
Create the endpoint
- With the appropriate version of the Service open, click the Endpoints tab.
- Click Add Triggered Task Endpoint or open the menu and select Add Ultra Task Endpoint.
- Add a name and description.
- Click in the Triggered or Ultra field and select the task to add.
- Click Create. The endpoint opens and a message informs you that there are No paths yet.
Add Paths
For each Path (or route) for this endpoint:
- Click Add.
- For Routing, click either Rules to specify a simple path or an Expression to define a condition for the path. Refer to Endpoint configuration for an example expression.
- Click in the Servers field and select a Snaplex.
- Add a Description to clarify the purpose of this endpoint path.
- Add any required parameters.
- Under Methods, click all appropriate HTTP methods supported by this path.
-
For each method, add:
- A Description.
- Optional Tags.
- Select the Media type for the request body.
This is the required format for the request. For example,
application/json
orapplication/xml
. - Add any required request Parameters. Parameters are typically used to identify a resource while the
request body provides content for that resource. For example, the Pet Store has an endpoint to find a
pet by ID. An
integer
petId
is a required request path parameter. - Add response codes and descriptions. For example, the Pet Store endpoint to get a pet by its ID returns
200
for success,400
for an invalid ID, and404
for a pet not found. - Select a Media type for the response.
- Provide an optional response example.
- Provide the response schema.
- Click Save.
Add the appropriate rules to the Catalog Policy or apply a Policy at the Service or endpoint level, and you are ready to test.