Skip to content

Set the team player photo

PUT/v1/teams/{teamId}/players/{playerId}/photo

PUT
/v1/teams/{teamId}/players/{playerId}/photo
curl --request PUT \
--url https://api.ligr.live/rest/v1/teams/1/players/1/photo \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "uploadId": 1 }'

Sets the photo of a player on the roster of a team from a completed upload. The API checks the size and SHA-256 of the bytes, the image type, and the 300x300 pixel size. Each upload sets a photo one time. The photo belongs to this team only. Graphics show it as the player photo. The response has the same shape as an item of GET /v1/teams/{teamId}/players.

teamId
required

Entity identifier

integer format: int32
>= 1

The team id

playerId
required

Entity identifier

integer format: int32
>= 1

The player id

Media typeapplication/json

Set the team player photo from a completed upload.

object
uploadId
required

The uploadId from the POST …/uploads route of the same image.

number format: double
Examplegenerated
{
"uploadId": 1
}

Ok

Media typeapplication/json
object
id
required

Entity identifier

integer format: int32
>= 1
firstName
required

Default Player first name

string
>= 1 characters <= 35 characters
gfxFirstName
required

Name predominantly display in graphics

string
nullable >= 1 characters <= 19 characters
gfxLastName
required

Name predominantly display in graphics

string
nullable >= 1 characters <= 19 characters
lastName
required

Default Player first name

string
>= 1 characters <= 35 characters
position
required
string
nullable
positionType
required
string
nullable
number
required
string
0 <= 3 characters
starter
required
boolean
bench
required
boolean
captain
required
boolean
photoUrl
string
nullable /https?:\/\/(www\.)?[-a-zA-Z0-9@:%._\+~#=]{1,256}\.[a-zA-Z0-9()]{1,6}\b([-a-zA-Z0-9()@:%_\+.~#?&//=]*)/
Examplegenerated
{
"id": 1,
"firstName": "example",
"gfxFirstName": "example",
"gfxLastName": "example",
"lastName": "example",
"position": "example",
"positionType": "example",
"number": "example",
"starter": true,
"bench": true,
"captain": true,
"photoUrl": "example"
}