POST
/
athletes
/
{athleteId}
Update Athlete in Organization
curl --request POST \
  --url https://api.uplift.ai/v1/athletes/{athleteId} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "first_name": "<string>",
  "last_name": "<string>",
  "date_of_birth": "<string>",
  "email": "<string>",
  "height": 123,
  "weight": 123,
  "custom_attributes": {}
}'
{
  "athlete": {}
}

Attribute Modification

All attributes of the athlete can be updated. The following rules apply:
  • String Attributes:
    • String values can be updated to any non-empty string.
    • String values can also be set to an empty string ("") to clear the attribute.
  • Integer Attributes:
    • Integer values can be updated to any valid integer.
    • Integer values can also be set to 0 to clear the attribute.
  • Special Rules for first_name:
    • The first_name attribute, if included, cannot be empty. It must always contain a non-empty string.
  • Custom Attributes (custom_attributes):
    • Existing custom attributes follow the same update rules as string and integer attributes.
      • If an existing custom attribute is updated with an empty string ("") or 0, the attribute will be deleted from the custom_attributes object.
    • Users can add new custom attributes during the update. New attributes must follow the same rules as described in the createAthlete endpoint.

Example Request

POST /athletes/12345

{
  "last_name": "",
  "email": "john@example.com",
  "weight": 0,
  "custom_attributes": {
    "team": "Team B",
    "position": "pitcher",
    "sport": "MLB"
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

athleteId
string
required

The unique identifier for the athlete record to be retrieved.

Body

application/json

Response

200
application/json

Athlete created successfully.

The response is of type object.