Response Codes In Widgets
Response codes are the variables which gets updated after the execution of the widget. Response codes helps in knowing particular status of the field and in troubleshooting if the widget gets failed.
Webhook
Success Response - Below are the variables which will get updated if the execution of the widget was successful and the flow moved to ‘line 0’.
Variable | Description | Value |
$flow.key.response_status | API call Success or Failure status | SUCCESS |
$flow.key.response_status_code | Status Code for response(2XX) | 200 |
$flow.key.response_duration | Duration in seconds for the API to return data | 0.11 |
$flow.key.response_raw | Raw response received from server, null if empty | Â |
$flow.key.response_error | If API resulted in error, Boolean true or false | false |
Error Response - Below are the variables which will get updated if the execution of the widget was Failed and the flow moved to ‘line 1’.
Variable | Description | Value |
$flow.key.response_status | API call Success or Failure status | FAILED |
$flow.key.response_status_code | Status Code for response | 401, 200 |
$flow.key.response_status_type | Type of error, based on status code | Redirection |
$flow.key.response_duration | Duration in seconds for the API to return data | 0.11 |
$flow.key.response_raw | Raw response received from server, null if empty | {...} |
$flow.key.response_error | If API resulted in error, Boolean true or false | true |
$flow.key.error_reason | Reason for failure | SERVER_ERROR |
This document has been developed by Phonon.io for the sole and exclusive use of the customer / prospective customer with whom this document is being shared. Further, this document has been provided by Phonon.io to the recipient in good faith and based on request from the recipient for the same. This document is a confidential document and contains confidential product technology, workflow and commercial details that are for the sole usage of the intended recipients of this document. Recipients are advised not to share this document with any third party that is not the intended recipient of this document and neither to bring this document in full or parts into the public domain. Any unauthorized access may be brought to Phonon.io’s notice immediately. Phonon.io is free to take any legal action it deems necessary against any person or entity that violates this confidentiality agreement. Phonon.io is bound and governed by the rules of the state of Gujarat in India. In case you are not in agreement with the terms set in this clause or are not an intended recipient of this document, please destroy the document and intimate us of the same at info@phonon.io.