Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/ti-infinite/GSMApplication/llms.txt

Use this file to discover all available pages before exploring further.

The getMediaResources endpoint returns a list of multimedia resource configurations grouped by category. Each resource carries an ordering hint and a Config payload that the frontend interprets to render media items such as banners, images, or embedded content. At least one category string must be provided — an empty categories list causes an immediate validation error without hitting the data layer.

Endpoint

GET /api/application/v1/application/getMediaResources

Authentication

All requests to this endpoint require a valid Bearer token. The token can be supplied as an Authorization header or as the gsm_token cookie.
Authorization
string
required
Bearer token obtained during login. Format: Bearer <token>
Note: The API gateway automatically injects the X-Company-Id header from the authenticated session. Clients must never set this header directly.

Query Parameters

categories
string[]
required
One or more category identifiers to filter resources by. Repeat the parameter for multiple values (e.g. ?categories=banners&categories=icons). The request fails with a validation error if this list is empty or omitted.

Response

All responses are wrapped in the standard ApiResponse<T> envelope:
{
  "success": true | false,
  "message": "string",
  "data": [ ... ] | null,
  "errorType": "string" | null,
  "traceId": "string" | null,
  "details": "string" | null
}

Response Fields

success
boolean
required
Indicates whether the request was processed successfully.
message
string
required
Human-readable status message describing the outcome.
data
array
List of multimedia resource objects matching the requested categories. null on failure.
errorType
string | null
Present when success is false. Common values: Validation, NotFound.
traceId
string | null
Optional correlation ID for request tracing across services.
details
string | null
Optional extended error detail message.

HTTP Status Codes

CodeMeaning
200 OKRequest processed. Check success in the body — a validation error (e.g. empty categories) is still returned as HTTP 200 with success: false.
400 Bad RequestReturned when the categories array is null or empty (InvalidCategories validation error).
401 UnauthorizedThe Bearer token is missing, expired, or invalid.
404 Not FoundNo resources were found matching the supplied categories.

Examples

Request — single category

curl --request GET \
  --url 'https://your-gateway.example.com/api/application/v1/application/getMediaResources?categories=banners' \
  --header 'Authorization: Bearer <token>'

Request — multiple categories

curl --request GET \
  --url 'https://your-gateway.example.com/api/application/v1/application/getMediaResources?categories=banners&categories=icons&categories=splash' \
  --header 'Authorization: Bearer <token>'

Successful Response

{
  "success": true,
  "message": "Resources retrieved successfully.",
  "data": [
    {
      "resourceCategory": "banners",
      "resourceOrder": 1,
      "config": "{\"url\":\"https://cdn.example.com/banner1.png\",\"alt\":\"Welcome Banner\"}"
    },
    {
      "resourceCategory": "banners",
      "resourceOrder": 2,
      "config": "{\"url\":\"https://cdn.example.com/banner2.png\",\"alt\":\"Promo Banner\"}"
    },
    {
      "resourceCategory": "icons",
      "resourceOrder": 1,
      "config": "{\"url\":\"https://cdn.example.com/icon-home.svg\",\"size\":24}"
    }
  ],
  "errorType": null,
  "traceId": "00-7c3d1a2b4e9f0c08-01",
  "details": null
}

Validation Error — empty categories

{
  "success": false,
  "message": "At least one category must be provided.",
  "data": null,
  "errorType": "Validation",
  "traceId": "00-7c3d1a2b4e9f0c08-02",
  "details": null
}

Build docs developers (and LLMs) love