Request Payload
  • 05 Dec 2022
  • Dark
    Light
  • PDF

Request Payload

  • Dark
    Light
  • PDF

Article summary

Payload is simply the body that is sent out on the request to the other system.

  • If the payload is JSON, it will be translated based on the schema for the particular action.
  • The reason it is translated is when IAP refers to a field as X and the other system refers to it as Y, the adapter needs to put the value in X into Y before calling the other system so that the other system will understand the request.
  • The payload can also be plain text or xml in which case nothing will be done with it.
  • Other actions can be done based on the requestDatatype defined in the action.json file. These include encoding, encrypting, URL handling as a form, and translating from JSON to XML.

Example: A request payload

const reqObj = {
  payload: { garbage: 'need since post' },
  uriPathVars: [groupId, deviceId],
  uriQuery: { name: 'anyname' },
  uriOptions: { page: 2 },
  addlHeaders: { audit: 'turnOn' },
  authData: { domain: 'abc' },
  callProperties: {
    stub: true,
    request: {
      attempt_timeout = 60000
    }
  },
  filter: '[*name=doggie]',
  priority: 1,
  event: 'giveMeMyData'
};

Was this article helpful?

What's Next
Changing your password will log you out immediately. Use the new password to log back in.
First name must have atleast 2 characters. Numbers and special characters are not allowed.
Last name must have atleast 1 characters. Numbers and special characters are not allowed.
Enter a valid email
Enter a valid password
Your profile has been successfully updated.