Request Defaults

This section describes common rules and parameters used in API requests within the Gaijin Application Platform.


Request Method

By default, all API endpoints use the POST method unless specified otherwise.

In most cases, request parameters are sent in the request body as a JSON object.


Request Parameters

Most requests validate the combination of jwt and factor. If the service cannot use a factor, a signed service_jwt can be provided instead.

Warning

Passing jwt, factor, and service_jwt in the request body is deprecated. Use the corresponding HTTP headers instead.

  • jwt string required

    The JWT token of the user performing the action.

  • factor string conditionally required

    The device factor associated with the user’s JWT (obtained from SSO). Required if service_jwt is not provided.

  • service_jwt string conditionally required

    The static or generated service JWT, used when factor is not provided.

Headers
Authorization: Bearer eyJhbGci...
Factor: ...
Body
{
  "project_id": "...",
  "application_id": 50001,
  "services": [50001, 50002, 50003]
}

Response Parameters

All responses are returned in JSON format.

  • status string required

    Indicates the response status.

    • “OK” — the request was processed successfully.

    • “ERROR” — the request failed.

  • error string optional

    Descriptive error message. Present only when status is "ERROR".

Response example (Success)
{
  "status": "OK"
}
Response example (Error)
{
  "status": "ERROR",
  "error":  "Cannot find project"
}