Getting Started
The Supermove API is organized around REST. Our API has predictable resource-oriented URLs, accepts JSON-encoded requests and returns JSON-encoded responses.
You can use the Supermove API in test mode which does not affect your live data. The API key you use to authenticate the request determines whether the request is live mode or test mode.
The base url for all requests to the Supermove API is: https://api.supermove.co.
Accessing the API
The Supermove API is currently only available for select partners. If you'd like to get access, please contact us at integrations@supermove.co.
Authentication
The Supermove API uses API keys to authenticate requests. If you are in contact with our team, you should have received an API key via email.
Test mode secret keys have the prefix supermove_test_
and live mode secret keys have the prefix supermove_live_
.
Your API keys carry many privileges, so be sure to keep them secure! Do not share your secret API keys in publicly accessible areas.
Authentication to the API is performed via bearer auth. To use, you must provide the Authorization
header in the form of:
-H "Authorization: Bearer supermove_test_b96d82e35f08c753ae2b1d74291ad19e"
All API requests must be made over HTTPS. Calls made over plain HTTP will fail. API requests without authentication will also fail.
Sending a Lead (via the "Project Sync" endpoint)
This is the main endpoint that syncs a project
with Supermove. A project
consists of many job
objects where each job
represents a single segment of work for a crew.
A project
is uniquely identified by its identifier
. If the system does not find a matching identifier
, it will perform a CREATE action and a new instance will be created. If it does find a matching identifier
, it will perform an UPDATE and update the existing object.
The id
is provided alongside your API key (via email) and indicates the name of your organization on Supermove. This is used to validate your API request.
Resources described below are outlined here.
Request
Method: POST
URL: https://api.supermove.co/v1/projects/sync
An example request for creating a new project on the supermove-demo
account. Feel free to copy this payload and try the request yourself.
{
"id": "supermove-demo",
"project": {
"customer": {
"first_name": "Johnny",
"last_name": "Doe",
"phone_number": "1112223333",
"email": "john.doe@supermove.co"
},
"jobs": [
{
"job_type": {
"identifier": "local-move"
},
"status": "BOOKED",
"move_size": "1 Bedroom",
"date": "2020-01-20",
"start_time_1": "0900",
"additional_notes": "Make sure to take the 10 boxes",
"dispatch_notes": "Notes for the dispatch team",
"office_notes": "Internal notes for the office",
"locations": [
{
"address": "123 Main St.",
"city": "Phoenix",
"zip_code": "12345",
"unit": "101",
"floor_number": 1,
"notes": "Long walk up the stairs"
}
]
}
]
}
}
Response
A successful response from the server will send back the project and its unique identifier.
{
"project": {
"identifier": "1"
}
}
Usage
Here is a curl command that you can use to test out the endpoint.
curl --request POST \\
--url <https://api.supermove.co/v1/projects/sync> \\
--header 'authorization: Bearer supermove_test_b96d82e35f08c753ae2b1d74291ad19e' \\
--header 'content-type: application/json' \\
--data '{
"id": "supermove-demo",
"project": {
"customer": {
"first_name": "Johnny",
"last_name": "Doe",
"phone_number": "1112223333",
"email": "john.doe@supermove.co"
},
"jobs": [
{
"job_type": {
"identifier": "local-move"
},
"status": "BOOKED",
"move_size": "1 Bedroom",
"date": "2020-01-20",
"start_time_1": "0900",
"additional_notes": "Make sure to take the 10 boxes",
"dispatch_notes": "Notes for the dispatch team",
"office_notes": "Internal notes for the office",
"locations": [
{
"address": "123 Main St.",
"city": "Phoenix",
"zip_code": "12345",
"unit": "101",
"floor_number": 1,
"notes": "Long walk up the stairs"
}
]
}
]
}
}'
Callouts
job.kind
has been deprecated in favor ofjob.job_type.identifier
to set the job type.
Comments
0 comments
Please sign in to leave a comment.