The Maintenance Visit object
Attributes
Unique identifier for the object.
ISO 8601 timestamp of when the object was created.
ISO 8601 timestamp of when the object was last updated.
Default: draft
Default: Unscheduled
{
"id": "maintenance-visit_abc123",
"created_at": "2024-01-15T09: 30: 00Z",
"updated_at": "2024-01-15T09: 30: 00Z",
"status": "draft",
"customer": "customer_example",
"customer_name": "customer_name_example",
"address_display": "address_display_example",
"contact_display": "contact_display_example",
"contact_mobile": "contact_mobile_example",
"contact_email": "[email protected]",
"mntc_date": "2024-01-15",
"mntc_time": "mntc_time_example",
"completion_status": "completion_status_example",
"maintenance_type": "Unscheduled",
"customer_feedback": "customer_feedback_example",
"company": "Example Corp",
"customer_address": "customer_address_example",
"contact_person": "contact_person_example",
"territory": "territory_example",
"customer_group": "customer_group_example",
"maintenance_schedule": "maintenance_schedule_example",
"maintenance_schedule_detail": "maintenance_schedule_detail_example"
} /api/maintenance/maintenance-visit/{id} Retrieve a maintenance visit
Retrieves the details of an existing maintenance visit. Supply the unique maintenance visit ID that was returned from a previous request.
Path parameters
The identifier of the maintenance visit to retrieve.
Returns
Returns the maintenance visit object if a valid identifier was provided.
curl https://api.overplane.dev/api/maintenance/maintenance-visit/maintenance-visit_abc123 \
-H "Authorization: Bearer sk_test_..." {
"id": "maintenance-visit_abc123",
"created_at": "2024-01-15T09: 30: 00Z",
"updated_at": "2024-01-15T09: 30: 00Z",
"status": "draft",
"customer": "customer_example",
"customer_name": "customer_name_example",
"address_display": "address_display_example",
"contact_display": "contact_display_example",
"contact_mobile": "contact_mobile_example",
"contact_email": "[email protected]",
"mntc_date": "2024-01-15",
"mntc_time": "mntc_time_example",
"completion_status": "completion_status_example",
"maintenance_type": "Unscheduled",
"customer_feedback": "customer_feedback_example",
"company": "Example Corp",
"customer_address": "customer_address_example",
"contact_person": "contact_person_example",
"territory": "territory_example",
"customer_group": "customer_group_example",
"maintenance_schedule": "maintenance_schedule_example",
"maintenance_schedule_detail": "maintenance_schedule_detail_example"
} /api/maintenance/maintenance-visit List all maintenance visits
Returns a list of maintenance visits. The results are sorted by creation date, with the most recently created appearing first.
Query parameters
Maximum number of objects to return. Default: 20.
Number of objects to skip for pagination. Default: 0.
Returns
A paginated list of maintenance visit objects.
curl https://api.overplane.dev/api/maintenance/maintenance-visit \
-H "Authorization: Bearer sk_test_..." {
"data": [
{
"id": "maintenance-visit_abc123",
"created_at": "2024-01-15T09: 30: 00Z",
"updated_at": "2024-01-15T09: 30: 00Z",
"status": "draft",
"customer": "customer_example",
"customer_name": "customer_name_example",
"address_display": "address_display_example",
"contact_display": "contact_display_example",
"contact_mobile": "contact_mobile_example",
"contact_email": "[email protected]",
"mntc_date": "2024-01-15",
"mntc_time": "mntc_time_example",
"completion_status": "completion_status_example",
"maintenance_type": "Unscheduled",
"customer_feedback": "customer_feedback_example",
"company": "Example Corp",
"customer_address": "customer_address_example",
"contact_person": "contact_person_example",
"territory": "territory_example",
"customer_group": "customer_group_example",
"maintenance_schedule": "maintenance_schedule_example",
"maintenance_schedule_detail": "maintenance_schedule_detail_example"
}
],
"has_more": false,
"total": 1
} /api/maintenance/maintenance-visit Create a maintenance visit
Creates a new maintenance visit object.
Body parameters
Default: draft
Default: Unscheduled
Returns
Returns the newly created maintenance visit object if the call succeeded.
curl https://api.overplane.dev/api/maintenance/maintenance-visit \
-H "Authorization: Bearer sk_test_..." \
-X POST \
-H "Content-Type: application/json" \
-d '{"customer":"customer_example","mntc_date":"2024-01-15","completion_status":"completion_status_example","company":"Example Corp"}' {
"id": "maintenance-visit_abc123",
"created_at": "2024-01-15T09: 30: 00Z",
"updated_at": "2024-01-15T09: 30: 00Z",
"status": "draft",
"customer": "customer_example",
"customer_name": "customer_name_example",
"address_display": "address_display_example",
"contact_display": "contact_display_example",
"contact_mobile": "contact_mobile_example",
"contact_email": "[email protected]",
"mntc_date": "2024-01-15",
"mntc_time": "mntc_time_example",
"completion_status": "completion_status_example",
"maintenance_type": "Unscheduled",
"customer_feedback": "customer_feedback_example",
"company": "Example Corp",
"customer_address": "customer_address_example",
"contact_person": "contact_person_example",
"territory": "territory_example",
"customer_group": "customer_group_example",
"maintenance_schedule": "maintenance_schedule_example",
"maintenance_schedule_detail": "maintenance_schedule_detail_example"
} /api/maintenance/maintenance-visit/{id} Update a maintenance visit
Updates the specified maintenance visit by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
Path parameters
The identifier of the maintenance visit to update.
Body parameters
Default: draft
Default: Unscheduled
Returns
Returns the updated maintenance visit object.
curl https://api.overplane.dev/api/maintenance/maintenance-visit/maintenance-visit_abc123 \
-H "Authorization: Bearer sk_test_..." \
-X PATCH \
-H "Content-Type: application/json" \
-d '{"status":"draft","customer":"customer_example"}' {
"id": "maintenance-visit_abc123",
"created_at": "2024-01-15T09: 30: 00Z",
"updated_at": "2024-01-15T09: 30: 00Z",
"status": "draft",
"customer": "customer_example",
"customer_name": "customer_name_example",
"address_display": "address_display_example",
"contact_display": "contact_display_example",
"contact_mobile": "contact_mobile_example",
"contact_email": "[email protected]",
"mntc_date": "2024-01-15",
"mntc_time": "mntc_time_example",
"completion_status": "completion_status_example",
"maintenance_type": "Unscheduled",
"customer_feedback": "customer_feedback_example",
"company": "Example Corp",
"customer_address": "customer_address_example",
"contact_person": "contact_person_example",
"territory": "territory_example",
"customer_group": "customer_group_example",
"maintenance_schedule": "maintenance_schedule_example",
"maintenance_schedule_detail": "maintenance_schedule_detail_example"
} /api/maintenance/maintenance-visit/{id} Delete a maintenance visit
Permanently deletes a maintenance visit. This cannot be undone.
Path parameters
The identifier of the maintenance visit to delete.
Returns
Returns a confirmation that the maintenance visit has been deleted.
curl https://api.overplane.dev/api/maintenance/maintenance-visit/maintenance-visit_abc123 \
-H "Authorization: Bearer sk_test_..." \
-X DELETE {
"id": "maintenance-visit_abc123",
"deleted": true
} /api/maintenance/maintenance-visit/{id}/submit Submit a maintenance visit
Submits a draft maintenance visit, transitioning its status from draft to submitted.
Path parameters
The identifier of the maintenance visit to act on.
Returns
Returns the maintenance visit object with updated status.
curl https://api.overplane.dev/api/maintenance/maintenance-visit/maintenance-visit_abc123/submit \
-H "Authorization: Bearer sk_test_..." \
-X POST {
"id": "maintenance-visit_abc123",
"created_at": "2024-01-15T09: 30: 00Z",
"updated_at": "2024-01-15T09: 30: 00Z",
"status": "draft",
"customer": "customer_example",
"customer_name": "customer_name_example",
"address_display": "address_display_example",
"contact_display": "contact_display_example",
"contact_mobile": "contact_mobile_example",
"contact_email": "[email protected]",
"mntc_date": "2024-01-15",
"mntc_time": "mntc_time_example",
"completion_status": "completion_status_example",
"maintenance_type": "Unscheduled",
"customer_feedback": "customer_feedback_example",
"company": "Example Corp",
"customer_address": "customer_address_example",
"contact_person": "contact_person_example",
"territory": "territory_example",
"customer_group": "customer_group_example",
"maintenance_schedule": "maintenance_schedule_example",
"maintenance_schedule_detail": "maintenance_schedule_detail_example"
} /api/maintenance/maintenance-visit/{id}/cancel Cancel a maintenance visit
Cancels a submitted maintenance visit, transitioning its status to cancelled.
Path parameters
The identifier of the maintenance visit to act on.
Returns
Returns the maintenance visit object with updated status.
curl https://api.overplane.dev/api/maintenance/maintenance-visit/maintenance-visit_abc123/cancel \
-H "Authorization: Bearer sk_test_..." \
-X POST {
"id": "maintenance-visit_abc123",
"created_at": "2024-01-15T09: 30: 00Z",
"updated_at": "2024-01-15T09: 30: 00Z",
"status": "draft",
"customer": "customer_example",
"customer_name": "customer_name_example",
"address_display": "address_display_example",
"contact_display": "contact_display_example",
"contact_mobile": "contact_mobile_example",
"contact_email": "[email protected]",
"mntc_date": "2024-01-15",
"mntc_time": "mntc_time_example",
"completion_status": "completion_status_example",
"maintenance_type": "Unscheduled",
"customer_feedback": "customer_feedback_example",
"company": "Example Corp",
"customer_address": "customer_address_example",
"contact_person": "contact_person_example",
"territory": "territory_example",
"customer_group": "customer_group_example",
"maintenance_schedule": "maintenance_schedule_example",
"maintenance_schedule_detail": "maintenance_schedule_detail_example"
} Line items
Child objects that belong to this maintenance visit. These are accessed via the parent's ID.
Maintenance Visit Purpose
Attributes
Endpoints
/api/maintenance/maintenance-visit-purpose?parent_id={id} /api/maintenance/maintenance-visit-purpose /api/maintenance/maintenance-visit-purpose/{id} /api/maintenance/maintenance-visit-purpose/{id} /api/maintenance/maintenance-visit-purpose/reorder {
"id": "maintenance-visit-purpose_abc123",
"idx": 1,
"maintenance_visit_id": "maintenance_visit_id_example",
"item_code": "item_code_example",
"item_name": "item_name_example",
"serial_no": "serial_no_example",
"description": "description_example",
"service_person": "service_person_example",
"work_done": "work_done_example",
"prevdoc_doctype": "prevdoc_doctype_example",
"prevdoc_docname": "prevdoc_docname_example",
"maintenance_schedule_detail": "maintenance_schedule_detail_example"
}