Action Error References
Examples of Error Structure
Error Structure Explained
-
error_code
: Is the name of the Error Code. -
message
: Provides a descriptive explanation of the error that occurred. -
data
: Contains any additional information related to the error being returned such as the request method, host and path. -
response
: Contains theHeaders
and thebody
of the request sent.
NOTE
Please be aware that each error is unique. Consequently, some errors may encompass additional data fields, while others might have fewer data fields. This variation depends on the executed action and the specific error encountered. The above Error Structure serves as just one example among several different types of error structures. However, they consistently encompass the essential components of error_code, message, data and body.
Error Types
Error Type | Error Code | Error Message |
---|---|---|
HTTP ERROR | BLINK_HTTP_ERR_INVALID_STATUS_CODE | Blink received an invalid status code after sending an HTTP request to the vendor |
HTTP ERROR | BLINK_HTTP_ERR_PAYLOAD_ERROR | Blink received an error in the response body after sending an HTTP request to the vendor |
HTTP ERROR | BLINK_HTTP_ERR_RATE_LIMIT | Blink encountered a rate-limit after sending an HTTP request to the vendor |
HTTP ERROR | BLINK_HTTP_ERR_RATE_LIMIT_TIMEOUT | The wait duration for API rate limit reset is longer than the request timeout |
REQUEST ERROR | BLINK_HTTP_ERR_MISSING_REQUIRED_PARAM | Missing mandatory parameter %s |
REQUEST ERROR | BLINK_HTTP_ERR_PAYLOAD_LIMIT | Blink failed to parse the base URL (%s) for this action |
REQUEST ERROR | BLINK_HTTP_ERR_BASE_URL | Blink failed to join the base URL with the user’s relative path for this action |
Generic Rate-Limit
Rate limiting controls how often requests can be made to a system or service. It sets a maximum number of requests allowed within a certain period (seconds, minutes, or hours). When this limit is reached, the system may delay or reject further requests until the next time period starts. Blink handles rate limit errors automatically. This is how we do it:
In the Blink Ops Editor, when sending an HTTP request as part of an action, if the Blink’s system receives the response code 429
, it indicates that the generic rate limit has been reached. Additionally, the presence of headers X-RateLimit-Remaining
or X-Rate-Limit-Remaining
with a value of 0
confirms this limit has been reached.
The system will then check for the X-RateLimit-Reset
and X-Rate-Limit-Reset
headers. If these headers are present, they provide an epoch time indicating when you can resume sending requests. The system will automatically retry at that specified time.
Additionally, if the Retry-After
header is found, it indicates the number of seconds to wait before retrying. The system will automatically retry after the specified duration.
In the absence of these headers, the system will employ an exponential backoff strategy, starting with a delay of 100ms
. The retries will continue until the step reaches its configured timeout. If the required wait duration for the API rate limit reset exceeds the step timeout, the following message will be returned: “The wait duration for API rate limit reset is longer than the request timeout”.
In Blink’s HTTP actions, the advanced settings include an option to Retry on Rate Limit. This feature can be enabled by checking the corresponding box. To disable it, simply uncheck the box.
INFO
In all other HTTP-based actions available on the Blink Platform, the Retry on Rate Limit feature is always automatically enabled.
TIP
To prevent these errors, we recommend reducing the number of requests sent through the chosen HTTP action.
Was this page helpful?