Webhook Connectors support exposing a public API endpoint.
Webhook Connectors enable data to enter the ArcESB flow via HTTP POSTs and PUTs. Each Webhook Connector exposes an endpoint in the application where external clients can send XML and JSON payloads. These payloads are written to an output file and passed along to connected connectors in the flow.
A Sample Request can be specified in the Webhook Connector to simplify the process of transforming data that is POSTed to the endpoint. When an XML sample is specified, and the Webhook Connector is connected to an XML Map Connector in the flow, the XML Map Connector can automatically detect the expected structure of XML files posted to the endpoint. The visual designer of the XML Map Connector can then be used to map this structure into any arbitrary target XML structure.
Settings related to the core operation of the connector.
- Connector Id The static name of the connector. All connector-specific files are held in a folder by the same name within the Data Directory.
- Connector Description An optional field to provide free-form description of the connector and its role in the flow.
- Webhook Endpoint The generated URL (based on connector name) where the endpoint is exposed.
- HTTP Method Whether to allow data to be uploaded via POST calls, PUT calls, or both.
An XML or JSON template representing the expected structure of incoming data. More details can be found in the Sample Requests Section below.
When data is uploaded to the Webhook Endpoint, the body of the web request is written as an output file and passed along to the next connected connector in the flow. This allows for a flexible method of invoking an Arc workflow via an external API call.
Data uploaded to the endpoint is not validated within the Webhook Connector, and should be validated later in the flow if necessary.
The Sample Request field allows for specifying the XML or JSON structure expected for API calls to the webhook endpoint.
The primary benefit of specifying a sample request is when connecting the Webhook Connector to an XML Map Connector in the flow. XML Map Connectors should be used when the API data needs to be converted into some other format, like an EDI document or a database insert.
The XML Map Connector can detect the XML structure of the sample request and use this as the Source File for the XML Map designer. Then, the XML structure representing the target format should be uploaded as the Destination File for the XML Map Connector, at which point the visual designer can be used to convert the source structure into the destination.