The ReDem API delivers clear, consistent, and well-structured responses to ensure seamless integration and efficient processing. Each response follows a standardized format aligned with RESTful principles and OpenAPI standards.

This structure enhances transparency, simplifies parsing and error handling, and supports fast debugging—ensuring reliability and predictability in every interaction.

✅ Success Response

The success response of the ReDem API indicates that the request has been processed successfully. This response is well-structured and provides crucial information about the request’s status.

The success response follows a standardized format to ensure consistency, predictability, and ease of use for developers.

Success responses are structured as follows:

  • success: A variable indicating whether the operation was successful.
  • message: A variable that human-readable message providing additional context or confirmation of the requested action.
  • results: This object serves as a container to hold the results for the requested data, encapsulating all relevant information and outputs in a structured format.
Sample success response for "Add Respondent"
{
    "success": true,
    "message": "Respondent Evaluated successfully",
    "results": {
        "status": "JOB_COMPLETED",
        "respondentQuality": {
            "isExcluded": true,
            "reasonsForExclusion": [
                "Open Ended Score Threshold",
                "Coherence Score Threshold"
            ],
            "redemScore": 85,
           // ... rest of the response object ...
        }
    }
}

⚠️ Error Response

The error response of the ReDem API is returned when a request fails due to various reasons. This response provides clear, actionable information to help developers identify and resolve the cause of the error. The response format is consistent, ensuring easy parsing and fast debugging.

Error responses are structured as follows:

  • success: A variable indicating whether the operation was successful.
  • message: A variable that human-readable message providing additional context or confirmation of the requested action.
  • errors: This object serves as a container to hold the errors for the requested data.
Sample error response for "Add Respondent"
{
    "success": false,
    "message": "Validation Error",
    "errors": {
        "0": "\"surveyName\" is required",
        "1": "\"dataPoints[0].dataPointId\" is required"
    }
}