List Variants.

GET /api/teams/{team}/experiments/{experiment}/variants

Path parameters

  • team integer Required

    The ID of the team that the variant belongs to.

  • experiment string Required

    The experiment key that the variants belong to.

Query parameters

  • include string

    Comma-separated list of relationships to include in the response.

  • sort string

    Field to sort by. Defaults to 'id'.

  • page integer

    Page number to return.

  • per_page integer

    Number of items to return in a page. Defaults to 15.

Responses

GET /api/teams/{team}/experiments/{experiment}/variants
curl \
 -X GET https://checkmango.com/api/teams/19/experiments/autem/variants \
 -H "Authorization: Bearer $ACCESS_TOKEN"
Response examples (200)
{
  "data": [
    {
      "id": "NEMO_SIT_MAXIME",
      "type": "variants",
      "attributes": {
        "id": 2,
        "team_id": 22,
        "key": "NEMO_SIT_MAXIME",
        "control": false,
        "description": null,
        "created": {
          "human": "1 second ago",
          "string": "2024-04-08 10:42:02"
        },
        "updated": {
          "human": "1 second ago",
          "string": "2024-04-08 10:42:02"
        }
      },
      "links": {
        "self": {
          "href": "http://checkmango.com/api/teams/22/experiments/SUNT_FUGIT_DOLORIBUS_QUI_EARUM/variants/NEMO_SIT_MAXIME"
        }
      }
    },
    {
      "id": "ERROR_QUIBUSDAM_CUM_IN_INCIDUNT",
      "type": "variants",
      "attributes": {
        "id": 3,
        "team_id": 25,
        "key": "ERROR_QUIBUSDAM_CUM_IN_INCIDUNT",
        "control": false,
        "description": "Sed velit enim quas est soluta. Tempora dolores saepe animi qui corporis. Aut dolor est dignissimos officia magni ut soluta.",
        "created": {
          "human": "1 second ago",
          "string": "2024-04-08 10:42:02"
        },
        "updated": {
          "human": "1 second ago",
          "string": "2024-04-08 10:42:02"
        }
      },
      "links": {
        "self": {
          "href": "http://checkmango.com/api/teams/25/experiments/QUI_ASPERIORES_DOLOREM_MINIMA_DOLOREM/variants/ERROR_QUIBUSDAM_CUM_IN_INCIDUNT"
        }
      }
    }
  ]
}
Response examples (403)
{
  "message": "Unauthenticated."
}
Response examples (404)
{
  "message": "Not Found"
}