Match Competitors

Request: GET

Returns a list of competitors for a match.

HTTP Request

GET /v1/{sport}/matches/{matchId}/competitors

Parameters

Parameter Name Value Description
Required Parameters
sport string The sport for which you are making the request
matchId integer The unique identifier for the match
Optional Parameters
useExternalForLeague integer If this value is set to the leagueId for the competitors, then the URL filter parameters matchId will instead refer to the externalId fields of the match in that league.

Request Body

Do not supply a request body with this method.

Response

If successful this method returns a list of Competitor resources.

Request: GET

Get the detail about a specific match competitor

HTTP Request

GET /v1/{sport}/matches/{matchId}/competitors/{competitorId}

Parameters

Parameter Name Value Description
Required Parameters
sport string The sport for which you are making the request
matchId integer The unique identifier for this match
competitorId integer The unique identifier for the competitor in this match. If the competition is team based, then this is the teamId, if person based, then this should be the personId.
Optional Parameters
useExternalForLeague integer If this value is set to the leagueId for the competitor, then the URL filter parameters matchId and competitorId will instead refer to the externalId fields of the respective entities in that league.

Request Body

Do not supply a request body with this method.

Response

If successful this method returns a Competitors resource.

Request: POST

Add a new competitor to a match

HTTP Request

POST /v1/{sport}/matches/{matchId}/competitors

Parameters

Parameter Name Value Description
Required Parameters
sport string The sport for which you are making the request
matchId integer Unique identifier for the match to which you want to add the competitor.
Optional Parameters
useExternalForLeague integer If this value is set to the leagueId for the competitor, then the URL parameter matchId will instead refer to the externalId fields of the match in that league. The content of the request body is also interpreted differently. See the Request Body section for more information.

Request Body

In the request body supply a Competitors resource.

If the useExternalForLeague parameter is specified, then the following fields in the resource will be interpreted as the externalId of the specific entity instead of the unique identifier.

Response

If successful this method returns a Competitors resource.

Request: PUT

Update an existing competitor in a match

HTTP Request

PUT /v1/{sport}/matches/{matchId}/competitors/{competitorId}

Parameters

Parameter Name Value Description
Required Parameters
sport string The sport for which you are making the request
matchId integer The unique identifier for this match
competitorId integer The unique identifier for the competitor in this match. If the competition is team based, then this is the teamId, if person based, then this should be the personId.
Optional Parameters
useExternalForLeague integer If this value is set to the leagueId for the competitor, then the URL parameters matchId and competitorId will instead refer to the externalId fields of the respective entities in that league. The content of the request body is also interpreted differently. See the Request Body section for more information.

Request Body

In the request body supply a Competitors resource.

If the useExternalForLeague parameter is specified, then the following fields in the resource will be interpreted as the externalId of the specific entity instead of the unique identifier.

Response

If successful this method returns a Competitors resource.

Request: DELETE

Delete an existing competitor from a match

HTTP Request

DELETE /v1/{sport}/matches/{matchId}/competitors/{competitorId}

Parameters

Parameter Name Value Description
Required Parameters
sport string The sport for which you are making the request
matchId integer The unique identifier for this match
competitorId integer The unique identifier for the competitor in this match. If the competition is team based, then this is the teamId, if person based, then this should be the personId.
Optional Parameters
confirm integer 0 = Default. FAILURE returned if cascade records found.
1 = override cascades

Affected resources:
useExternalForLeague integer If this value is set to the leagueId for the competitor, then the URL parameters matchId and competitorId will instead refer to the externalId fields of the respective entities in that league.

Request Body

Do not supply a request body with this method.

Response

If no override is flag passed in and the matchId is involved in any of the affected resources then the DELETE will fail (returns FAILURE). Successful this method returns SUCCESS.