httpin Processor

httpin is a controller processor used to receive inbound http requests (inbound relative to TEDI).

This configuration represents a single HTTP API/interface. You can have more than one HTTP method/verb per URL - TEDI will verify there’s no overlap, it just needs to live in its own config.


Common Settings

SettingDescription
service.type=httpinindicates the type of processor
roleslist of Roles (defined in accounts.properties) that have access to this API
admin.api.auth.schemeadministrative API auth scheme
http.methodhttp verb [post,put,get,delete]
http.url.pathPATH is given to clients calling your API
http.url.patternPATTERN is used internally for routing; it must be a regular expression that uniquely identifies one target endpoint. TEDI will detect overlaps and not allow them
http.suppress.status.codescomma-delimited list of non-2xx response codes that will not cause an alert [-1,400,404,408,503,504]
http.return.responseindicates a body is expected to be returned to the caller
http.return.headerslist of headers from the response to return to the caller - this is to tie into an httpout response if there was one to main continuity

Headers

You can enforce headers on the inbound http requests. The syntax to set a list of headers is as follows: {integer}.{setting}

SettingsDescription
http.header.namethe name of the http header
http.header.defaultthe default value for the header if the caller does not set it
http.header.requiredheader must be present and have a value (if default not provided)

For example, to configure three required headers would look like:

0.http.header.name      = "content-type"
0.http.header.default   = "application/xml"
0.http.header.required  = true

1.http.header.name      = "content-encoding"
1.http.header.default   = "identity"
1.http.header.required  = true

2.http.header.name      = "x-request-id"
2.http.header.default   = ""
2.http.header.required  = true


Path Parameters

To use and configure path parameters, you can set the name, default value, and whether or not its required.

To indicate a segment in the URL is a path parameter use this syntax: {name-of-the-path-parameter}.

SettingsDescription
http.path.param.namethe name of the path parameter
http.path.param.defaultthe default value if not set by the caller
http.path.param.requiredwhether parameter is required

For example, if your URL was /sales/invoice/{id}/{date}, you would configure like so:

0.http.path.param.name    = "id"
0.http.path.param.default   = ""
0.http.path.param.required  = true

0.http.path.param.name    = "date"
0.http.path.param.default   = ""
0.http.path.param.required  = true

Query Parameters

Query parameters can also be configure in a like manner as headers and path parameters.

SettingDescription
http.query.param.namethe name of the query parameter
http.query.param.defaultthe default value for the query parameter if not set by the caller
http.query.param.requiredwhether the query parameter is required and must be set by the caller

For example, if your URL was /sales/invoice/{id}/{date}?{x}, you could configure like so:

0.http.query.param.name      = "x"
0.http.query.param.default   = ""
0.http.query.param.required  = true

Authentication

TEDI supports the following auth schemes for http:

  • none
  • basic auth
  • certificate
  • jws (jwt)
  • http signature

To set the scheme:

SettingsDescription
auth.schemesets the authentication scheme to use for http