External data source
External data source mechanism is used with fields to specify that the value for a field must be fetched from an external source.
Source is described by these properties:
β
β
url
Absolute or relative URL pointing to document containing the data.
method
HTTP method used to request data. Can be βgetβ or βpostβ.
service
Service type, required if relative URL is specified. If set then data is provided by specified service. Service base URL is used to build full URL to data document.
GET
external data via GET
The platform sends GET request to specified URL and expects data as a response.β
POST
external data via POST
The Interaction Cloud sends POST request to specified URL with project, event (if the field attached to event or element) and element (if the field attached to element) custom fields values.β
Request data
If request can not successfully return data it should return non-200 HTTP code and a body like this:β
Error response body
Both missing_fields
and error
are optional.β
POST via Service
Request URL is constructed as <service base url>/prefill.json
.β
The platform passes instance_uuid
and project_uuid
parameters via the query string with an instance id and project id respectively.
Is a service is used as a source, it must be specified as a required service in the app spec.
Was this helpful?