Skip to content

Language

A language is a normalized identifier used to tag products and tracks. This resource is read-only and has no exposed relationships.


Lists Languages

GET https://domain.com/api/v1/languages

Headers

Name Type Description
Authorization* String Bearer \
Content-Type* String application/vnd.api+json

Response — 200 OK

{
  "data": [
    {
      "type": "languages",
      "id": "3",
      "attributes": {
        "name": "German"
      },
      "links": {
        "self": "https://domain.com/api/v1/languages/3"
      }
    },
    {
      "type": "languages",
      "id": "4",
      "attributes": {
        "name": "English"
      },
      "links": {
        "self": "https://domain.com/api/v1/languages/4"
      }
    },
    {
      "type": "languages",
      "id": "5",
      "attributes": {
        "name": "Spanish"
      },
      "links": {
        "self": "https://domain.com/api/v1/languages/5"
      }
    }
  ],
  "meta": {
    "page": {
      "currentPage": 1,
      "from": 1,
      "lastPage": 8,
      "perPage": 20,
      "to": 20,
      "total": 147
    }
  },
  "jsonapi": {
    "version": "1.0"
  },
  "links": {
    "first": "https://domain.com/api/v1/languages?page[number]=1&page[size]=20",
    "last": "https://domain.com/api/v1/languages?page[number]=8&page[size]=20",
    "next": "https://domain.com/api/v1/languages?page[number]=2&page[size]=20"
  }
}

Filters

Filter Example
Name /languages?filter[name]=Spanish
ID /languages?filter[id]=1,2,3

Get Language

GET https://domain.com/api/v1/languages/:id

Path Parameters

Name Type Description
id* Number Language ID

Headers

Name Type Description
Authorization* String Bearer \
Content-Type* String application/vnd.api+json

Response — 200 OK

{
  "data": {
    "type": "languages",
    "id": "<ID>",
    "attributes": {
      "name": "Spanish"
    },
    "links": {
      "self": "https://domain.com/api/v1/languages/<ID>"
    }
  },
  "jsonapi": {
    "version": "1.0"
  },
  "links": {
    "self": "https://domain.com/api/v1/languages/<ID>"
  }
}

Response — 404 Not Found

{
  "jsonapi": {
    "version": "1.0"
  },
  "errors": [
    {
      "status": "404",
      "title": "Not Found"
    }
  ]
}