Venues

Request: GET

Returns a list of venues (surfaces) that the user has access to.

HTTP Request

GET /v1/{sport}/venues
GET /v1/{sport}/leagues/{leagueId}/venues

Parameters

Parameter Name Value Description
Required Parameters
sport string The sport for which you are making the request
Optional Parameters
leagueId integer Unique identifier for the league the venue belongs to.
locationId integer Unique identifier for the location

Request Body

Do not supply a request body with this method.

Response

If successful this method returns a list of Venue resources.

Request: GET

Get the detail about a specific venue

HTTP Request

GET /v1/{sport}/venues/{venueId}

Parameters

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

Request Body

Do not supply a request body with this method.

Response

If successful this method returns a Venue resource.

Request: POST

Create a new venue

HTTP Request

POST /v1/{sport}/leagues/{leagueId}/venues

Parameters

Parameter Name Value Description
Required Parameters
sport string The sport for which you are making the request
leagueId integer Unique identifier for the league the venue belongs to.
Optional Parameters
minimumResponse integer If this value is set to 1 then the response resource will only contain venueId and externalId.
bulk integer Create multiple records.
useExternalForLeague integer If this value is set to the leagueId for the venue, then the content of the request body is interpreted differently. See the Request Body section for more information.

Request Body

In the request body supply a Venue resource. If the bulk parameter is specified a list of resources is expected.

Response

If successful this method returns a Venue resource. If the bulk parameter is specified it will return a list of resources. Any errors returned are against the specific 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.

Request: PUT

Update an existing venue

HTTP Request

PUT /v1/{sport}/venues/{venueId}

Parameters

Parameter Name Value Description
Required Parameters
sport string The sport for which you are making the request
venueId integer The unique identifier for this venue
Optional Parameters
useExternalForLeague integer If this value is set to the leagueId for the venue, then the URL parameter venueId will instead refer to the externalId of the venue 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 Venue 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 Venue resource.

Request: DELETE

Delete an existing venue

HTTP Request

DELETE /v1/{sport}/venues/{venueId}

Parameters

Parameter Name Value Description
Required Parameters
sport string The sport for which you are making the request
venueId integer The unique identifier for this venue
Optional Parameters
useExternalForLeague integer If this value is set to the leagueId for the venue, then the URL parameter venueId will instead refer to the externalId of the venue in that league.
confirm integer 0 = Default. FAILURE returned if cascade records found.
1 = override cascades

Affected resources:

Request Body

Do not supply a request body.

Response

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