GET GetChallengeCategories

{baseurl}/api/v1/Integration/GetChallengeCategories

Overview

The GetChallengeCategories retrieves a list of all challenge categories available in the system. The categories are filtered based on the language provided in the request header.


Request

Header Parameters

AttributeTypeOptionsDescription

X-ClientId

string
Required

Provided Client Id.

X-Message

string
Required

Provided encrypted message.

Accept-language

string
Optional

Selected language for response.

X-ClientId and X-Message are only required with V1 API.


Response

The API returns a list of category objects. Each category includes the ID and name of the challenge category.

Response Fields:

  • result(List): A list of categories.

    • Id (integer): The unique identifier of the category.

    • Name (string): The name of the category in the requested language.

Response Parameters

Category: Category information of the challenge.

PropertyTypeDescription

Id

int

Unique identifier of the category.

Name

string

Name of the category.

Response Sample

Success respone
{
    "result": [
        {
            "name": "Food",
            "id": 1
        },
        {
            "name": "Clothes",
            "id": 2
        },
        {
            "name": "Sports",
            "id": 3
        },
        {
            "name": "Electronics",
            "id": 4
        }
    ],
    "message": "Process completed successfully",
    "statusCode": 1,
    "statusName": "Successfully"
}

Notes

  • If no categories match the language criteria, the API returns an empty list, indicating that no categories were found for the requested language.

  • No specific error handling is required, as the method returns a successful response even when no categories are found. The response is consistent in format and includes a meaningful message.

Last updated