Header Values

The most relevant REST request header values for our backend REST APIs are the following:

Field NameDescriptionExample ValuesUsage Comment
AcceptFormat of the function call response that is desired.application/json or application/xmlSetting a value is required.
Content-TypeFormat of the request content.application/json or application/xmlRequired for POST but not for GET.

In the following example, the requested resource is a JSON object:

curl --request POST \
  --url 'https://rest.cleverbridge.com/urlgenerator/generateusersessionurl' \
  --header 'accept: application/json' \
  --header 'content-type: application/json' \
  --header 'authorization: Basic xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' \
  --data '{
    "TargetUrl": "https%3A%2F%2Fwww.cleverbridge.com%2F864%2F%3Fscope%3Dcheckout%26amp%3Bcart%3D97771%26amp%3Blanguage%3Den%26amp%3Bcurrency%3DUSD%26amp%3Bx-source%3Dwebsite-visit-05.2019
  }'