Resource information
URL | https://api.statscore.com/v2/translations/events |
---|---|
Method | PUT |
Description | Add/update event participants name translation by provider ID. |
Authorization required | Yes |
Parameters
Name | Data type | Description |
---|---|---|
token | xsd:string | REQUIRED. More information concerning authorization in API introduction section |
POST parameters
Name | Data type | Description |
---|---|---|
lang_code | xsd:string | REQUIRED. Language code, e.g "zh-CN" - case sensitive |
provider_id | xsd:int | REQUIRED. The identifier of provider for given identifiers (event_id, participant.id) At this moment only: |
event_id | xsd:int | REQUIRED. The identifier for event |
.participants | ||
id | xsd:int | REQUIRED. The identifier of participant |
name | xsd:string | REQUIRED. The value of translated name (short_name) |
position | xsd:int | REQUIRED. The value of position, e.g 1 (for home participant), 2 ... |
Output elements
If fail:
.data | |
---|---|
message | Response info message. |
status | Response code. |
If success:
.data | |
---|---|
message | Successfully translated participant(s) |
not_translated | List of participants that was not found |
Sample curl call
Request | Parameters |
---|---|
curl --location --request PUT 'https://api.statscore.com/v2/translations/events?token={token}' \ --header 'Content-Type: application/json' \ --data '{ "lang_code": "zh-CN", "provider_id": 74, "event_id": 55555, "participants":[ { "id": 11111, "name": "Part 1 translate", "position": 1 }, { "id": 22222, "name": "Part 2 translate", "position": 2 } ] }' | token |