Trips, stops & legs

Create trips (from a regatta or free-form), manage ordered stops, attach trailers with tow vehicle and driver, change status, and grant trip editors. Legs are derived.

Trips

Method Endpoint Purpose
GET /v1/trip/planner-regattas Regattas the user plans (candidates for bc_regatta_id)
GET /v1/trip/list?whitelabel_id=&status=&include_cancelled=0 Trips of the club
GET /v1/trip/get/{id} Trip with stops, legs, trailers, regatta, permissions
POST /v1/trip/create bc_regatta_id or name; whitelabel_id?, notes, planned_depart_at, planned_return_at
POST /v1/trip/update/{id} Same fields
POST /v1/trip/link-regatta/{id} · unlink-regatta/{id} bc_regatta_id
POST /v1/trip/status/{id} status ∈ draft / planned / departed / completed
POST /v1/trip/cancel/{id} Cancels; every later write answers 409 RP-505
POST /v1/trip/add-trailer/{id} trailer_id, tow_vehicle_id?, driver_name?, driver_phone?
POST /v1/trip/update-trailer/{id} trip_trailer_id + any of the above
POST /v1/trip/remove-trailer/{id} trip_trailer_id (deletes its placements too)
GET /v1/trip/editors/{id} Who may edit: planners, creator, granted users
POST /v1/trip/grant-editor/{id} · revoke-editor/{id} custid — regatta planners only
GET /v1/trip/mine · /v1/trip/drivers/{id} · /v1/trip/members/{id} · /v1/trip/snapshot/{id} Mobile: my trips, trailer drivers, member picker, offline snapshot — see Mobile
POST /v1/trip/add-driver/{id} · remove-driver/{id} trip_trailer_id, custid[, role] — see Mobile

Creating a trip from a regatta copies the regatta's name, dates and venue; the venue becomes the pre-filled regatta stop.

Request

POST /v1/trip/create
Authorization: Bearer rp_live_••••••••
Content-Type: application/json

{
    "bc_regatta_id": 501,
    "notes": "Two trailers, leave Friday noon."
}

Response 201

{
    "success": true,
    "trip": {
        "id": 2,
        "whitelabel_id": 10,
        "name": "Spring Sprints",
        "status": "draft",
        "bc_regatta_id": 501,
        "regatta_name": "Spring Sprints",
        "regatta_venue": null,
        "regatta_venue_id": 71,
        "regatta_start_date": "2027-05-16",
        "regatta_end_date": null,
        "departure_planned_at": null,
        "return_planned_at": null,
        "created_by": 1001,
        "notes": "Two trailers, leave Friday noon.",
        "created_at": "2027-01-15 08:00:00",
        "updated_at": "2027-01-15 08:00:00",
        "club_timezone": "America/New_York",
        "departure_planned_at_local": null,
        "departure_planned_at_display": null,
        "return_planned_at_local": null,
        "return_planned_at_display": null,
        "is_linked": true
    },
    "trailers": [],
    "stops": [
        {
            "stop_id": 6,
            "trip_id": 2,
            "sort_order": 0,
            "type": "regatta",
            "name": "Spring Sprints",
            "address_text": null,
            "lat": null,
            "lng": null,
            "timezone": "America/New_York",
            "planned_arrival_at": null,
            "planned_departure_at": null,
            "actual_arrival_at": null,
            "actual_departure_at": null,
            "stay_minutes": null,
            "show_publicly": true,
            "notes": null,
            "source": "bc_regatta",
            "created_at": "2027-01-15 08:00:00",
            "updated_at": "2027-01-15 08:00:00",
            "is_cargo_stop": true,
            "effective_timezone": "America/New_York",
            "planned_arrival_at_local": null,
            "planned_arrival_at_display": null,
            "planned_departure_at_local": null,
            "planned_departure_at_display": null,
            "actual_arrival_at_local": null,
            "actual_arrival_at_display": null,
            "actual_departure_at_local": null,
            "actual_departure_at_display": null,
            "tz_abbr": "EST"
        }
    ],
    "legs": [],
    "editors": [
        {
            "custid": 1001,
            "name": "Casey Coach",
            "email": "coach@example.com",
            "sources": [
                "creator",
                "planner"
            ],
            "removable": false
        }
    ],
    "warnings": [
        "The first stop should be the origin (where the trailer starts)."
    ],
    "can_edit": true,
    "my_trailer_ids": []
}

Request

GET /v1/trip/get/1
Authorization: Bearer rp_live_••••••••

Response 200

{
    "success": true,
    "trip": {
        "id": 1,
        "whitelabel_id": 10,
        "name": "Head of the River",
        "status": "draft",
        "bc_regatta_id": null,
        "regatta_name": null,
        "regatta_venue": null,
        "regatta_venue_id": null,
        "regatta_start_date": null,
        "regatta_end_date": null,
        "departure_planned_at": null,
        "return_planned_at": null,
        "created_by": 1001,
        "notes": null,
        "created_at": "2027-01-15 08:00:00",
        "updated_at": "2027-01-15 08:00:00",
        "club_timezone": "America/New_York",
        "departure_planned_at_local": null,
        "departure_planned_at_display": null,
        "return_planned_at_local": null,
        "return_planned_at_display": null,
        "is_linked": false
    },
    "trailers": [
        {
            "id": 1,
            "trip_id": 1,
            "trailer_id": 1,
            "tow_vehicle_id": 1,
            "driver_name": "Dana",
            "driver_phone": null,
            "sort_order": 0,
            "drivers": [],
            "can_operate": true
        }
    ],
    "stops": [
        {
            "stop_id": 1,
            "trip_id": 1,
            "sort_order": 0,
            "type": "origin",
            "name": "Boathouse",
            "address_text": null,
            "lat": null,
            "lng": null,
            "timezone": null,
            "planned_arrival_at": null,
            "planned_departure_at": null,
            "actual_arrival_at": null,
            "actual_departure_at": null,
            "stay_minutes": null,
            "show_publicly": true,
            "notes": null,
            "source": "manual",
            "created_at": "2027-01-15 08:00:00",
            "updated_at": "2027-01-15 08:00:00",
            "is_cargo_stop": true,
            "effective_timezone": "America/New_York",
            "planned_arrival_at_local": null,
            "planned_arrival_at_display": null,
            "planned_departure_at_local": null,
            "planned_departure_at_display": null,
            "actual_arrival_at_local": null,
            "actual_arrival_at_display": null,
            "actual_departure_at_local": null,
            "actual_departure_at_display": null,
            "tz_abbr": "EST"
        },
        {
            "stop_id": 2,
            "trip_id": 1,
            "sort_order": 1,
            "type": "pickup",
            "name": "Podunk RC",
            "address_text": null,
            "lat": null,
            "lng": null,
            "timezone": null,
            "planned_arrival_at": null,
            "planned_departure_at": null,
            "actual_arrival_at": null,
            "actual_departure_at": null,
            "stay_minutes": null,
            "show_publicly": true,
            "notes": null,
            "source": "manual",
            "created_at": "2027-01-15 08:00:00",
            "updated_at": "2027-01-15 08:00:00",
            "is_cargo_stop": true,
            "effective_timezone": "America/New_York",
            "planned_arrival_at_local": null,
            "planned_arrival_at_display": null,
            "planned_departure_at_local": null,
            "planned_departure_at_display": null,
            "actual_arrival_at_local": null,
            "actual_arrival_at_display": null,
            "actual_departure_at_local": null,
            "actual_departure_at_display": null,
            "tz_abbr": "EST"
        },
        "… 3 more"
    ],
    "legs": [
        {
            "leg_id": 1,
            "trip_id": 1,
            "leg_index": 0,
            "from_stop_id": 1,
            "to_stop_id": 2,
            "from_name": "Boathouse",
            "to_name": "Podunk RC",
            "from_type": "origin",
            "to_type": "pickup",
            "label": "Leg 1: Boathouse → Podunk RC",
            "updated_at": "2027-01-15 08:00:00"
        },
        {
            "leg_id": 2,
            "trip_id": 1,
            "leg_index": 1,
            "from_stop_id": 2,
            "to_stop_id": 4,
            "from_name": "Podunk RC",
            "to_name": "Head of the River",
            "from_type": "pickup",
            "to_type": "regatta",
            "label": "Leg 2: Podunk RC → Head of the River",
            "updated_at": "2027-01-15 08:00:00"
        },
        {
            "leg_id": 3,
            "trip_id": 1,
            "leg_index": 2,
            "from_stop_id": 4,
            "to_stop_id": 5,
            "from_name": "Head of the River",
            "to_name": "Boathouse",
            "from_type": "regatta",
            "to_type": "destination",
            "label": "Leg 3: Head of the River → Boathouse",
            "updated_at": "2027-01-15 08:00:00"
        }
    ],
    "editors": [
        {
            "custid": 1001,
            "name": "Casey Coach",
            "email": "coach@example.com",
            "sources": [
                "creator"
            ],
            "removable": false
        }
    ],
    "warnings": [],
    "can_edit": true,
    "my_trailer_ids": []
}

Stops

Method Endpoint Purpose
POST /v1/stop/add/{trip_id} type, name, address_text, lat, lng, timezone, planned_arrival_at[_local], planned_departure_at[_local], stay_minutes, show_publicly, sort_order
POST /v1/stop/update/{stop_id} Same fields
POST /v1/stop/move/{stop_id} sort_order
POST /v1/stop/remove/{stop_id} Refused while cargo is added/removed there (RP-515)
POST /v1/stop/set-pin/{stop_id} lat, lng[, address_text] — resolves the time zone
POST /v1/stop/set-actual/{stop_id} actual_arrival_at, actual_departure_at (or clear=1)

Stop type ∈ origin | pickup | dropoff | regatta | destination | fuel | rest | overnight | other. Cargo stops (origin, pickup, dropoff, regatta, destination) bound legs and may add/remove boats; the rest are itinerary-only. A trip has exactly one origin (first) and one destination (last) — RP-511, RP-512.

Request

POST /v1/stop/add/1
Authorization: Bearer rp_live_••••••••
Content-Type: application/json

{
    "type": "overnight",
    "name": "Hampton Inn Harrisburg",
    "address_text": "4230 Union Deposit Rd, Harrisburg, PA",
    "lat": 40.2812,
    "lng": -76.8075,
    "stay_minutes": 600,
    "sort_order": 3
}

Response 201

{
    "success": true,
    "stop": {
        "stop_id": 7,
        "trip_id": 1,
        "sort_order": 3,
        "type": "overnight",
        "name": "Hampton Inn Harrisburg",
        "address_text": "4230 Union Deposit Rd, Harrisburg, PA",
        "lat": 40.2812,
        "lng": -76.8075,
        "timezone": "America/New_York",
        "planned_arrival_at": null,
        "planned_departure_at": null,
        "actual_arrival_at": null,
        "actual_departure_at": null,
        "stay_minutes": 600,
        "show_publicly": false,
        "notes": null,
        "source": "manual",
        "created_at": "2027-01-15 08:00:00",
        "updated_at": "2027-01-15 08:00:00",
        "is_cargo_stop": false,
        "effective_timezone": "America/New_York",
        "planned_arrival_at_local": null,
        "planned_arrival_at_display": null,
        "planned_departure_at_local": null,
        "planned_departure_at_display": null,
        "actual_arrival_at_local": null,
        "actual_arrival_at_display": null,
        "actual_departure_at_local": null,
        "actual_departure_at_display": null,
        "tz_abbr": "EST"
    },
    "trip": {
        "id": 1,
        "whitelabel_id": 10,
        "name": "Head of the River",
        "status": "draft",
        "bc_regatta_id": null,
        "regatta_name": null,
        "regatta_venue": null,
        "regatta_venue_id": null,
        "regatta_start_date": null,
        "regatta_end_date": null,
        "departure_planned_at": null,
        "return_planned_at": null,
        "created_by": 1001,
        "notes": null,
        "created_at": "2027-01-15 08:00:00",
        "updated_at": "2027-01-15 08:00:00",
        "club_timezone": "America/New_York",
        "departure_planned_at_local": null,
        "departure_planned_at_display": null,
        "return_planned_at_local": null,
        "return_planned_at_display": null,
        "is_linked": false
    },
    "trailers": [
        {
            "id": 1,
            "trip_id": 1,
            "trailer_id": 1,
            "tow_vehicle_id": 1,
            "driver_name": "Dana",
            "driver_phone": null,
            "sort_order": 0,
            "drivers": [],
            "can_operate": true
        }
    ],
    "stops": [
        {
            "stop_id": 1,
            "trip_id": 1,
            "sort_order": 0,
            "type": "origin",
            "name": "Boathouse",
            "address_text": null,
            "lat": null,
            "lng": null,
            "timezone": null,
            "planned_arrival_at": null,
            "planned_departure_at": null,
            "actual_arrival_at": null,
            "actual_departure_at": null,
            "stay_minutes": null,
            "show_publicly": true,
            "notes": null,
            "source": "manual",
            "created_at": "2027-01-15 08:00:00",
            "updated_at": "2027-01-15 08:00:00",
            "is_cargo_stop": true,
            "effective_timezone": "America/New_York",
            "planned_arrival_at_local": null,
            "planned_arrival_at_display": null,
            "planned_departure_at_local": null,
            "planned_departure_at_display": null,
            "actual_arrival_at_local": null,
            "actual_arrival_at_display": null,
            "actual_departure_at_local": null,
            "actual_departure_at_display": null,
            "tz_abbr": "EST"
        },
        {
            "stop_id": 2,
            "trip_id": 1,
            "sort_order": 1,
            "type": "pickup",
            "name": "Podunk RC",
            "address_text": null,
            "lat": null,
            "lng": null,
            "timezone": null,
            "planned_arrival_at": null,
            "planned_departure_at": null,
            "actual_arrival_at": null,
            "actual_departure_at": null,
            "stay_minutes": null,
            "show_publicly": true,
            "notes": null,
            "source": "manual",
            "created_at": "2027-01-15 08:00:00",
            "updated_at": "2027-01-15 08:00:00",
            "is_cargo_stop": true,
            "effective_timezone": "America/New_York",
            "planned_arrival_at_local": null,
            "planned_arrival_at_display": null,
            "planned_departure_at_local": null,
            "planned_departure_at_display": null,
            "actual_arrival_at_local": null,
            "actual_arrival_at_display": null,
            "actual_departure_at_local": null,
            "actual_departure_at_display": null,
            "tz_abbr": "EST"
        },
        "… 4 more"
    ],
    "legs": [
        {
            "leg_id": 1,
            "trip_id": 1,
            "leg_index": 0,
            "from_stop_id": 1,
            "to_stop_id": 2,
            "from_name": "Boathouse",
            "to_name": "Podunk RC",
            "from_type": "origin",
            "to_type": "pickup",
            "label": "Leg 1: Boathouse → Podunk RC",
            "updated_at": "2027-01-15 08:00:00"
        },
        {
            "leg_id": 2,
            "trip_id": 1,
            "leg_index": 1,
            "from_stop_id": 2,
            "to_stop_id": 4,
            "from_name": "Podunk RC",
            "to_name": "Head of the River",
            "from_type": "pickup",
            "to_type": "regatta",
            "label": "Leg 2: Podunk RC → Head of the River",
            "updated_at": "2027-01-15 08:00:00"
        },
        {
            "leg_id": 3,
            "trip_id": 1,
            "leg_index": 2,
            "from_stop_id": 4,
            "to_stop_id": 5,
            "from_name": "Head of the River",
            "to_name": "Boathouse",
            "from_type": "regatta",
            "to_type": "destination",
            "label": "Leg 3: Head of the River → Boathouse",
            "updated_at": "2027-01-15 08:00:00"
        }
    ],
    "editors": [
        {
            "custid": 1001,
            "name": "Casey Coach",
            "email": "coach@example.com",
            "sources": [
                "creator"
            ],
            "removable": false
        }
    ],
    "warnings": [],
    "can_edit": true,
    "my_trailer_ids": []
}

A later planned departure on the regatta stop is what makes the route planner put the leg home on the right day:

Request

POST /v1/stop/update/4
Authorization: Bearer rp_live_••••••••
Content-Type: application/json

{
    "planned_departure_at_local": "2027-05-16 13:00",
    "timezone": "America/New_York"
}

Response 200

{
    "success": true,
    "stop": {
        "stop_id": 4,
        "trip_id": 1,
        "sort_order": 4,
        "type": "regatta",
        "name": "Head of the River",
        "address_text": null,
        "lat": null,
        "lng": null,
        "timezone": "America/New_York",
        "planned_arrival_at": null,
        "planned_departure_at": 1810486800,
        "actual_arrival_at": null,
        "actual_departure_at": null,
        "stay_minutes": null,
        "show_publicly": true,
        "notes": null,
        "source": "manual",
        "created_at": "2027-01-15 08:00:00",
        "updated_at": "2027-01-15 08:00:00",
        "is_cargo_stop": true,
        "effective_timezone": "America/New_York",
        "planned_arrival_at_local": null,
        "planned_arrival_at_display": null,
        "planned_departure_at_local": "2027-05-16T13:00:00-04:00",
        "planned_departure_at_display": "Sun, May 16, 2027 1:00 PM EDT",
        "actual_arrival_at_local": null,
        "actual_arrival_at_display": null,
        "actual_departure_at_local": null,
        "actual_departure_at_display": null,
        "tz_abbr": "EDT"
    },
    "trip": {
        "id": 1,
        "whitelabel_id": 10,
        "name": "Head of the River",
        "status": "draft",
        "bc_regatta_id": null,
        "regatta_name": null,
        "regatta_venue": null,
        "regatta_venue_id": null,
        "regatta_start_date": null,
        "regatta_end_date": null,
        "departure_planned_at": null,
        "return_planned_at": null,
        "created_by": 1001,
        "notes": null,
        "created_at": "2027-01-15 08:00:00",
        "updated_at": "2027-01-15 08:00:00",
        "club_timezone": "America/New_York",
        "departure_planned_at_local": null,
        "departure_planned_at_display": null,
        "return_planned_at_local": null,
        "return_planned_at_display": null,
        "is_linked": false
    },
    "trailers": [
        {
            "id": 1,
            "trip_id": 1,
            "trailer_id": 1,
            "tow_vehicle_id": 1,
            "driver_name": "Dana",
            "driver_phone": null,
            "sort_order": 0,
            "drivers": [],
            "can_operate": true
        }
    ],
    "stops": [
        {
            "stop_id": 1,
            "trip_id": 1,
            "sort_order": 0,
            "type": "origin",
            "name": "Boathouse",
            "address_text": null,
            "lat": null,
            "lng": null,
            "timezone": null,
            "planned_arrival_at": null,
            "planned_departure_at": null,
            "actual_arrival_at": null,
            "actual_departure_at": null,
            "stay_minutes": null,
            "show_publicly": true,
            "notes": null,
            "source": "manual",
            "created_at": "2027-01-15 08:00:00",
            "updated_at": "2027-01-15 08:00:00",
            "is_cargo_stop": true,
            "effective_timezone": "America/New_York",
            "planned_arrival_at_local": null,
            "planned_arrival_at_display": null,
            "planned_departure_at_local": null,
            "planned_departure_at_display": null,
            "actual_arrival_at_local": null,
            "actual_arrival_at_display": null,
            "actual_departure_at_local": null,
            "actual_departure_at_display": null,
            "tz_abbr": "EST"
        },
        {
            "stop_id": 2,
            "trip_id": 1,
            "sort_order": 1,
            "type": "pickup",
            "name": "Podunk RC",
            "address_text": null,
            "lat": null,
            "lng": null,
            "timezone": null,
            "planned_arrival_at": null,
            "planned_departure_at": null,
            "actual_arrival_at": null,
            "actual_departure_at": null,
            "stay_minutes": null,
            "show_publicly": true,
            "notes": null,
            "source": "manual",
            "created_at": "2027-01-15 08:00:00",
            "updated_at": "2027-01-15 08:00:00",
            "is_cargo_stop": true,
            "effective_timezone": "America/New_York",
            "planned_arrival_at_local": null,
            "planned_arrival_at_display": null,
            "planned_departure_at_local": null,
            "planned_departure_at_display": null,
            "actual_arrival_at_local": null,
            "actual_arrival_at_display": null,
            "actual_departure_at_local": null,
            "actual_departure_at_display": null,
            "tz_abbr": "EST"
        },
        "… 4 more"
    ],
    "legs": [
        {
            "leg_id": 1,
            "trip_id": 1,
            "leg_index": 0,
            "from_stop_id": 1,
            "to_stop_id": 2,
            "from_name": "Boathouse",
            "to_name": "Podunk RC",
            "from_type": "origin",
            "to_type": "pickup",
            "label": "Leg 1: Boathouse → Podunk RC",
            "updated_at": "2027-01-15 08:00:00"
        },
        {
            "leg_id": 2,
            "trip_id": 1,
            "leg_index": 1,
            "from_stop_id": 2,
            "to_stop_id": 4,
            "from_name": "Podunk RC",
            "to_name": "Head of the River",
            "from_type": "pickup",
            "to_type": "regatta",
            "label": "Leg 2: Podunk RC → Head of the River",
            "updated_at": "2027-01-15 08:00:00"
        },
        {
            "leg_id": 3,
            "trip_id": 1,
            "leg_index": 2,
            "from_stop_id": 4,
            "to_stop_id": 5,
            "from_name": "Head of the River",
            "to_name": "Boathouse",
            "from_type": "regatta",
            "to_type": "destination",
            "label": "Leg 3: Head of the River → Boathouse",
            "updated_at": "2027-01-15 08:00:00"
        }
    ],
    "editors": [
        {
            "custid": 1001,
            "name": "Casey Coach",
            "email": "coach@example.com",
            "sources": [
                "creator"
            ],
            "removable": false
        }
    ],
    "warnings": [],
    "can_edit": true,
    "my_trailer_ids": []
}

Legs

Legs are returned on GET /v1/trip/get/{id} as legs[] = {leg_id, index, from_stop_id, to_stop_id} — one per pair of consecutive cargo stops, rebuilt whenever stops change. Leg ids are stable while the two bounding stops stay adjacent; after inserting a cargo stop between them, the old leg is replaced by two new ones and placements re-attach by stop.

Trailers on a trip

Request

POST /v1/trip/update-trailer/1
Authorization: Bearer rp_live_••••••••
Content-Type: application/json

{
    "trip_trailer_id": 1,
    "driver_name": "Dana Rivers",
    "driver_phone": "+1 555 0100"
}

Response 200

{
    "success": true,
    "trailer": {
        "id": 1,
        "trip_id": 1,
        "trailer_id": 1,
        "tow_vehicle_id": 1,
        "driver_name": "Dana Rivers",
        "driver_phone": "+1 555 0100",
        "sort_order": 0
    },
    "trailers": [
        {
            "id": 1,
            "trip_id": 1,
            "trailer_id": 1,
            "tow_vehicle_id": 1,
            "driver_name": "Dana Rivers",
            "driver_phone": "+1 555 0100",
            "sort_order": 0,
            "drivers": [],
            "can_operate": false
        }
    ]
}

Editors

Request

GET /v1/trip/editors/1
Authorization: Bearer rp_live_••••••••

Response 200

{
    "success": true,
    "editors": [
        {
            "custid": 1001,
            "name": "Casey Coach",
            "email": "coach@example.com",
            "sources": [
                "creator"
            ],
            "removable": false
        }
    ]
}