Updates an existing voyage event.
| Code | Description |
|---|---|
| 404 | Not found. |
| 422 | Unprocessable Entity. |
| 500 | Internal Server Error. |
curl 'https://app.octopi.co/api/v1/voyages/V001/voyage_events/1' \
-X 'PATCH' \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
-H 'Authorization: Token token=YOURTOKEN' \
-d '{
"voyage_event": {
"started_at": "2024-01-15T10:35:00Z",
"completed_at": "2024-01-15T11:05:00Z",
"notes": "Updated pilot boarding information"
}
}'
{
"voyage_event": {
"id": 1,
"event_name": "Pilot Boarded",
"event_type_id": 5,
"created_at": "2024-01-15T10:30:00Z",
"updated_at": "2024-01-15T10:36:00Z",
"started_at": "2024-01-15T10:35:00Z",
"completed_at": "2024-01-15T11:05:00Z",
"custom_value": null,
"service_boat": {
"id": 2,
"name": "Pilot Boat Alpha"
},
"pilot": {
"id": 3,
"name": "John Smith"
},
"user": {
"id": 4,
"name": "Jane Doe"
},
"notes": "Updated pilot boarding information"
}
}
| Param name | Description |
|---|---|
|
voyage_number required |
The voyage number that owns this event Validations:
|
|
id required |
The voyage event ID Validations:
|
|
voyage_event required |
Validations:
|
|
voyage_event[started_at] optional |
Start time in ISO 8601 format Validations:
|
|
voyage_event[completed_at] optional |
Completion time in ISO 8601 format Validations:
|
|
voyage_event[service_boat_id] optional |
Service boat ID Validations:
|
|
voyage_event[pilot_id] optional |
Pilot ID Validations:
|
|
voyage_event[from_berth_id] optional |
From berth area ID Validations:
|
|
voyage_event[to_berth_id] optional |
To berth area ID Validations:
|
|
voyage_event[custom_value] optional |
Custom value for the event Validations:
|
|
voyage_event[notes] optional |
Additional notes Validations:
|