Body
-
external_id string
Customer's ID generated from a third-party system such as a CRM, POS, or accounting software
-
first_name string Required
-
last_name string Required
-
email string(email) Required
Required if phone is not provided
-
phone string(phone) Required
Phone number in E.164 international format.
Required if email is not provided. -
notes string
-
type number Required
The customer type, 1 for INDIVIDUAL, 2 for BUSINESS
Values are
1
or2
. -
metafields array[object]
POST /customers
curl \
-X POST https://{workspace}.fleetrunnr.com/api/v1/customers \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{"external_id":"ABCD12345","first_name":"John","last_name":"Doe","email":"user2@example.com","phone":"+12163547747","notes":"notes here...","type":1,"metafields":[{"key":"country","value":"France"}]}'
Request example
{
"external_id": "ABCD12345",
"first_name": "John",
"last_name": "Doe",
"email": "user2@example.com",
"phone": "+12163547747",
"notes": "notes here...",
"type": 1,
"metafields": [
{
"key": "country",
"value": "France"
}
]
}
Response examples (200)
{
"message": "success",
"data": {
"customer_uuid": "69ca2683-05d0-4cef-825f-379c0479b22a"
}
}