Live-score API's football data supports translations of team names in several different languages. In this page you can read more about this service.
lang
parameter to the URL that you are already using. The language codes that we use in our football data service are specified by ISO standard nomenclature: ISO 639-1. You can read more about this standard here (opens in a new tab). In the table below, we have listed the changes that you should do if you want to receive the names of the football teams in our services in the corresponding language. Examples with each language are shown under the table in the next section.
Language | ISO 639-1 Code | URL Addition |
---|---|---|
English | en | No change, it is our default data language |
Arabic | ar | &lang=ar |
Farsi | fa | &lang=fa |
Russian | ru | &lang=ru |
&lang=ar
in the end of the URL.
Before: http://livescore-api.com/api-client/scores/live.json?key=demo_key&secret=demo_secret
After: http://livescore-api.com/api-client/scores/live.json?key=demo_key&secret=demo_secret&lang=ar
Here is how the output of this this URL might look like. Although, the team names in the json keys home_name
and away_name
appear to be some scrambled letters and numbers, they are in fact valid UTF-8 encoded strings. Once displayed on your website, web app, or mobile app pages and views they will be correct.
{
"success": true,
"data": {
"match": [
{
"id": "119771",
"home_name": "\u0623\u0631\u0643\u0627 \u063a\u062f\u064a\u0646\u064a\u0627",
"away_name": "\u064a\u0627\u063a\u064a\u064a\u0644\u0648\u0646\u064a\u0627 \u0628\u064a\u0627…",
"score": "0 - 2",
"ht_score": "0 - 0",
"ft_score": "0 - 2",
"et_score": "",
"time": "FT",
"league_id": "122",
"status": "FINISHED",
"added": "2018-12-04 19:26:01",
"last_changed": "2018-12-04 21:27:11",
"home_id": "898",
"away_id": "445",
"league_name": "Cup"
}
{
"id": "119768",
"home_name": "\u0631\u0627\u064a\u0648 \u0641\u0627\u064a\u064a\u0643\u0627\u0646\u0648",
"away_name": "\u0644\u064a\u062c\u0627\u0646\u064a\u0633",
"score": "0 - 1",
"ht_score": "0 - 1",
"ft_score": "0 - 1",
"et_score": "",
"time": "FT",
"league_id": "203",
"status": "FINISHED",
"added": "2018-12-04 19:26:01",
"last_changed": "2018-12-04 21:24:02",
"home_id": "792",
"away_id": "25",
"league_name": "Copa del Rey"
}
]
}
}
league
filter so we only get the fixtures for the English Premier League. Once again the only thing that needs to be done is to add the string &lang=fa
in the end of the URL.
Before: http://livescore-api.com/api-client/fixtures/matches.json?key=demo_key&secret=demo_secret&league=25
After: http://livescore-api.com/api-client/fixtures/matches.json?key=demo_key&secret=demo_secret&league=25&lang=fa
league
filter so we only get the fixtures for the English Premier League. Once again the only thing that needs to be done is to add the string &lang=ru
in the end of the URL.
Before: http://livescore-api.com/api-client/scores/history.json?key=demo_key&secret=demo_secret&league=25
After: http://livescore-api.com/api-client/scores/history.json?key=demo_key&secret=demo_secret&league=25&lang=ru