Create Vendor
POSThttps://secure.fleetio.com/api/v1/vendors
Creates a new Vendor
Request
- application/json
Body
The name of the Vendor. Must be unique.
Possible values: <= 255 characters
The city of the Vendor.
Possible values: <= 255 characters
The email address of the contact person for the Vendor.
Possible values: <= 255 characters
The name of the contact person for the Vendor.
Possible values: <= 255 characters
The phone number of the contact person for the Vendor.
Possible values: <= 255 characters
The country of the Vendor.
Possible values: <= 255 characters
An external ID for the Vendor. Must be unique.
Possible values: <= 255 characters
The phone number of the Vendor.
Possible values: <= 255 characters
The postal code or ZIP code of the Vendor.
Possible values: <= 255 characters
The region, state, province, or territory of the Vendor.
Possible values: <= 255 characters
The street address of the Vendor.
Possible values: <= 255 characters
The second line of the street address of the Vendor.
Possible values: <= 255 characters
The website of the Vendor.
Possible values: <= 255 characters
Indicates whether the Vendor provides fuel.
Will be able to be listed on Fuel Entries
.
Indicates whether the Vendor provides service.
This Vendor will be able to be listed on Service Entries
and Work Orders
.
Indicates whether the Vendor provides parts.
This Vendor will be able to be listed on Parts
and Purchase Orders
.
Indicates whether the Vendor provides vehicles.
This Vendor will be able to be listed on Acquisitions
and Vehicles
.
*Full details on working with Custom Fields here.
Responses
- 200
- 401
- 403
- 422
- 500
OK
Response Headers
- application/json
- Schema
- Example (auto)
Schema
Possible values: >= 1
The date and time at which this record was created.
2023-03-14T13:46:27-06:00
The date and time at which this record was most recently updated.
2023-03-14T13:46:27-06:00
The name of the Vendor.
The phone number of the Vendor.
The street address of the Vendor.
The second line of the street address of the Vendor.
The city of the Vendor.
The region, state, province, or territory of the Vendor.
The postal code or ZIP code of the Vendor.
The country of the Vendor.
The website of the Vendor.
Additional notes about the Vendor.
Indicates whether the Vendor provides fuel.
Indicates whether the Vendor provides service.
Indicates whether the Vendor provides parts.
Indicates whether the Vendor provides vehicles.
The name of the contact person for the Vendor.
The email address of the contact person for the Vendor.
The phone number of the contact person for the Vendor.
The latitude of the Vendor's location.
The longitude of the Vendor's location.
The external identifier of the Vendor.
The date and time when the Vendor was archived, if applicable.
labels object[]required
*Full details on working with Custom Fields here.
{
"id": 0,
"created_at": "2023-03-14T13:46:27-06:00",
"updated_at": "2023-03-14T13:46:27-06:00",
"name": "string",
"phone": "string",
"street_address": "string",
"street_address_line_2": "string",
"city": "string",
"region": "string",
"postal_code": "string",
"country": "string",
"website": "string",
"notes": "string",
"fuel": true,
"service": true,
"parts": true,
"vehicle": true,
"contact_name": "string",
"contact_email": "string",
"contact_phone": "string",
"latitude": 0,
"longitude": 0,
"external_id": "string",
"archived_at": "string",
"labels": [
{
"id": 0,
"name": "string"
}
],
"custom_fields": {}
}
Request could not be authenticated
- application/json
- Schema
- Example (auto)
Schema
Possible values: >= 400
and <= 599
A short, human-readable summary of the problem type. It SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization.
A human-readable explanation specific to this occurrence of the problem.
A URI reference that identifies the specific occurrence of the problem. It may or may not yield further information if dereferenced.
{
"status": 0,
"title": "string",
"detail": "string",
"instance": "string"
}
Insufficient permission to perform this operation
- application/json
- Schema
- Example (auto)
Schema
Possible values: >= 400
and <= 599
A short, human-readable summary of the problem type. It SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization.
A human-readable explanation specific to this occurrence of the problem.
A URI reference that identifies the specific occurrence of the problem. It may or may not yield further information if dereferenced.
{
"status": 0,
"title": "string",
"detail": "string",
"instance": "string"
}
Unprocessable Entity
- application/json
- Schema
- Example (auto)
- Example
Schema
errors object
{
"errors": {}
}
{
"errors": {
"field1": [
"error1",
"error2"
],
"field2": [
"error3"
]
}
}
Something unexpected happened
- application/json
- Schema
- Example (auto)
Schema
Possible values: >= 400
and <= 599
A short, human-readable summary of the problem type. It SHOULD NOT change from occurrence to occurrence of the problem, except for purposes of localization.
A human-readable explanation specific to this occurrence of the problem.
A URI reference that identifies the specific occurrence of the problem. It may or may not yield further information if dereferenced.
{
"status": 0,
"title": "string",
"detail": "string",
"instance": "string"
}
Authorization: Authorization
name: Authorizationtype: apiKeyin: headerdescription: Prefix the value with "Token", for example: "Token 76cbe06c49a64". You can generate a new API key [here](https://secure.fleetio.com/api_keys).
name: Account-Tokentype: apiKeyin: headerdescription: You can find your Account-Token [here](https://secure.fleetio.com/api_keys)
- curl
- ruby
- python
- csharp
- go
- java
- nodejs
- php
- CURL
curl -L 'https://secure.fleetio.com/api/v1/vendors' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: <Authorization>' \
-H 'Account-Token: <Authorization>' \
-d '{
"name": "string",
"city": "string",
"contact_email": "string",
"contact_name": "string",
"contact_phone": "string",
"country": "string",
"external_id": "string",
"phone": "string",
"postal_code": "string",
"region": "string",
"street_address": "string",
"street_address_line_2": "string",
"website": "string",
"fuel": true,
"service": true,
"parts": true,
"vehicle": true,
"custom_fields": {}
}'