SmartGare
API referenceEndpoints

Take a bay out of service

Declares a bay unusable for a window because of works, an incident or blocked access. **Required permission:** `traffic.bay-unavailability:write`

POST/traffic/v1/bay-unavailabilities

Declares a bay unusable for a window because of works, an incident or blocked access.

Required permission: traffic.bay-unavailability:write

AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

body*DeclareBayUnavailabilityRequest

Response Body

*/*

*/*

curl -X POST "https://example.com/traffic/v1/bay-unavailabilities" \  -H "Content-Type: application/json" \  -d '{    "bay_id": "string",    "ends_at": "2019-08-24T14:15:22Z",    "reason": "string",    "starts_at": "2019-08-24T14:15:22Z"  }'
{  "bay_id": "string",  "declared_at": "2019-08-24T14:15:22Z",  "declared_by": "string",  "ends_at": "2019-08-24T14:15:22Z",  "id": "string",  "lifted_at": "2019-08-24T14:15:22Z",  "lifted_by": "string",  "lifted_reason": "string",  "reason": "string",  "starts_at": "2019-08-24T14:15:22Z",  "status": "ACTIVE"}