Introduction to Refonte.AI API
Data Engine Core Resources
Data Engine Tasks Types
Error Code | Meaning |
---|---|
200 | OK -- Everything worked as expected. |
400 | Bad Request -- The request was unacceptable, often due to missing a required parameter. |
401 | Unauthorized -- No valid API key provided. |
402 | Not enabled -- Please contact sales@refonteapi.com before creating this type of task. |
404 | Not Found -- The requested resource doesn't exist. |
409 | Conflict -- The provided idempotency key or `unique_id` is already in use for a different request. |
429 | Too Many Requests -- Too many requests hit the API too quickly. |
500 | Internal Server Error -- We had a problem with our server. Try again later. |
The task callback will be triggered with an error response outlining the issues and the task's `status` will be changed to `error` if one or more task attachments contain invalid data. Further information regarding the issue and unsuccessful attachments will be kept in the task answer.
These illustrations aid in your comprehension of the format and contents of error messages that the API returns under various circumstances.
When you submit a request to the API without providing an attachment or the attachments option, you get this error. It indicates that in order for your API request to be handled correctly, you must include either a single attachment or an array of attachments.
The reason for this error message is because there was a problem downloading one or more of the attachments that were included in your API request. It implies that there might be issues with the given attachment URLs or connectivity. For the Refonte.AI API to download and process the attachments, you might need to make sure that they are available and legitimate.
Though it gives more detailed information about the attachments that could not be downloaded, this error is similar to the previous one. It may also contain further information, including the URLs or identifiers of the problematic attachments. You can use this information to pinpoint the exact attachments that didn't download and solve the issue.
400 Bad Request
{
"status_code": 400,
"error": "Please include an attachment or attachments parameter."
}
Attachment 403
// example task.response with failed attachment due to access issues
{
"error": "One or more attachments could not be downloaded.",
"attachments": [
{
"statusCode": 403, // HTTP code received when fetching attachment
"url": "http://example.com/kitten.png", // attachment URL
}
]
}
Attachment 403
// example task.response
// with failed attachment processing
{
"error": "One or more attachments could not be downloaded.",
"frames": [ // frames which failed processing
{
"frame": 10, // frame #
"message": "Invalid JSON Format: Unexpected end of JSON input",
"attachment": {
"statusCode": 200, // HTTP code received when fetching attachment
"url": "http://example.com/lidar/frame10.json", // attachment URL
}
}
]
}
Updated about 2 months ago