vendors

Adds a vendor to a company

post/api/v1/vendors

Request

Query parameters

includestring
Example:first_load

Includes child relationships in the response, format is comma separated. Check each model for the list of associated includes

Headers

X-API-TOKENstring required
Example:TOKEN

The API token to be used for authentication

X-Requested-Withstring required
Example:XMLHttpRequest

Used to send the XMLHttpRequest header

Request body

namestring required

Vendor name

address1string

Primary address line

address2string

Secondary address line

citystring

City

statestring

State or province

postal_codestring

Postal code

country_idstring

Country ID

phonestring

Phone number

emailstring email

Email address

websitestring uri

Website URL

custom_value1string

Custom field value 1

custom_value2string

Custom field value 2

custom_value3string

Custom field value 3

custom_value4string

Custom field value 4

is_deletedboolean

Whether the vendor is deleted

archived_atinteger

Timestamp when vendor was archived

Example request

{
  "name": "ABC Supply Company",
  "address1": "123 Main Street",
  "address2": "Suite 100",
  "city": "New York",
  "state": "NY",
  "postal_code": "10001",
  "country_id": "1",
  "phone": "+1-555-123-4567",
  "email": "contact@abcsupply.com",
  "website": "https://www.abcsupply.com",
  "custom_value1": "Custom value 1",
  "custom_value2": "Custom value 2",
  "custom_value3": "Custom value 3",
  "custom_value4": "Custom value 4",
  "archived_at": 1640995200,
  "contacts": [
    {
      "first_name": "John",
      "last_name": "Doe",
      "email": "john.doe@abcsupply.com",
      "phone": "+1-555-123-4567",
      "send_email": true
    }
  ]
}

Response

Returns the saved vendor object

idstring

The hashed id of the vendor. This is a unique identifier for the vendor.

user_idstring

The hashed id of the user who created the vendor. This is a unique identifier for the user.

assigned_user_idstring

The hashed id of the assigned user to this vendor. This is a unique identifier for the user.

namestring

The name of the vendor.

classificationstring

The classification of the vendor.

websitestring

The website of the vendor.

private_notesstring

The private notes of the vendor. These notes are only visible to users with appropriate permissions.

industry_idstring

The industry id of the vendor. This is a unique identifier for the industry.

size_idstring

The size id of the vendor. This is a unique identifier for the size of the vendor.

address1string

The first line of the vendor's address.

address2string

The second line of the vendor's address.

citystring

The city of the vendor's address.

statestring

The state of the vendor's address.

postal_codestring

The postal code of the vendor's address.

phonestring

The phone number of the vendor.

country_idstring

The country id of the vendor. This is a unique identifier for the country.

currency_idstring

The currency id of the vendor. This is a unique identifier for the currency.

custom_value1string

The value of the first custom field for the vendor.

custom_value2string

The value of the second custom field for the vendor.

custom_value3string

The value of the third custom field for the vendor.

custom_value4string

The value of the fourth custom field for the vendor.

vat_numberstring

The VAT number of the vendor.

id_numberstring

The ID number of the vendor.

numberstring

The number of the vendor

is_deletedboolean

Boolean flag determining if the vendor has been deleted

language_idstring

The language id of the vendor. This is a unique identifier for the language.

vendor_hashstring

The vendor hash of the vendor. This is a unique identifier for the vendor.

transaction_namestring

The transaction name of the vendor.

last_loginnumber

Timestamp

created_atnumber

Timestamp

updated_atnumber

Timestamp

display_namestring

The display name of the vendor.

is_tax_exemptboolean

Flag indicating whether the vendor is exempt from taxes

public_notesstring

Notes that are visible to the vendor

routing_idstring

The routing identifier for e-invoicing

Example response

{
  "id": "Opnel5aKBz",
  "user_id": "Opnel5aKBz",
  "assigned_user_id": "Opnel5aKBz",
  "contacts": [
    {
      "id": "Opnel5aKBz",
      "user_id": "Opnel5aKBz",
      "vendor_id": "Opnel5aKBz",
      "first_name": "Harry",
      "last_name": "Windsor",
      "contact_key": "JD0X52bkfZlJRiroCJ0tcSiAjsJTntZ5uqKdiZ0a",
      "confirmation_code": "333-sdjkh34gbasd",
      "phone": "555-123-1234",
      "custom_value1": "2022-10-10",
      "custom_value2": "$1000",
      "email": "harry@windsor.com",
      "email_verified_at": 134341234234,
      "password": "*****",
      "is_primary": true,
      "created_at": 134341234234,
      "updated_at": 134341234234,
      "deleted_at": 134341234234,
      "send_email": true
    }
  ],
  "name": "Harry cafe de wheels",
  "classification": "individual",
  "website": "www.harry.com",
  "private_notes": "Shhh, do not tell the vendor",
  "industry_id": "1",
  "phone": "555-3434-3434",
  "currency_id": "4",
  "number": "11234",
  "is_deleted": true,
  "language_id": "1",
  "vendor_hash": "aaa-sss-www",
  "transaction_name": "aaa-sss-www",
  "last_login": 134341234234,
  "created_at": 134341234234,
  "updated_at": 134341234234,
  "display_name": "Bob the vendor",
  "public_notes": "These are public notes visible to vendors",
  "routing_id": "0088:12345678901"
}

Changes

    • info

      added the optional property // to the response with the status

    • info

      added the optional property // to the response with the status

    • info

      added the optional property // to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status