Get List
GET/api/surveys
API Endpoint: Retrieve Surveys
Purpose
This endpoint allows users to retrieve a list of surveys available in the application. It is designed to provide users with access to survey data for review or further processing.
Request Format
- Method: GET
- URL:
https://app.udyogx.in/api/surveys
- Request Body: This endpoint does not require a request body.
Response Structure
The response will contain a JSON object with the following structure:
- surveys: An array of survey objects, each containing details about a specific survey.
- Each survey object may include:
id
: Unique identifier for the survey.title
: The title of the survey.description
: A brief description of the survey.created_at
: Timestamp of when the survey was created.updated_at
: Timestamp of the last update to the survey.
- Each survey object may include:
Example Response
{
"surveys": [
{
"id": "1",
"title": "Customer Satisfaction Survey",
"description": "A survey to gauge customer satisfaction levels.",
"created_at": "2023-01-01T00:00:00Z",
"updated_at": "2023-01-02T00:00:00Z"
},
{
"id": "2",
"title": "Product Feedback Survey",
"description": "Feedback survey for our latest product.",
"created_at": "2023-01-03T00:00:00Z",
"updated_at": "2023-01-04T00:00:00Z"
}
]
}
This structure provides a clear understanding of the surveys available and their relevant details.
Responses
- 200