Skip to main content

post-all-copy

Follows: AuthenticationCachingPollingList Response Format

Creates a new vendor.

Parameters


firstNamestring
First name of the vendor contact. Required (with lastName) unless companyName is provided.

lastNamestring
Last name of the vendor contact. Required (with firstName) unless companyName is provided.

companyNamestring
Company name of the vendor. Required unless firstName and lastName are provided.

useCompanyNameAsDisplayNameboolean
Display the company name rather than the personal name. Defaults to true when only a company name is given, false otherwise. Requires companyName when set to true.

vendorTypeselect
Vendor type: general, utility, external_management_company or in-house_maintenance. Defaults to general.
Possible Values:  
general
utility
external_management_company
in-house_maintenance

addressStreetstring
Line one of the vendor's street address.

addressStreet2string
Line two of the vendor's street address.

addressCitystring
City of the vendor's address.

addressStatestring
State or region code of the vendor's address, e.g. CA.

addressZipstring
Postal code of the vendor's address.

addressCountrystring
ISO-2 country code of the vendor's address. Defaults to US when any other address field is given.

phoneNumberstring
Phone number for the vendor.

phoneLabelselect
Label for the phone number. Defaults to Office when a phoneNumber is given.
Possible Values:  
Office
Mobile
Home
Fax

emailstring
Email address for the vendor.

glAccountIdselect
AppFolio ID of the default GL account for the vendor's bills.

tradeIdsmulti
AppFolio IDs of the work order categories (trades) the vendor covers.

taxIdstring
Taxpayer ID (SSN or EIN) for 1099 reporting. Accepted on create but never included in a response.

taxpayerNamestring
Name used for 1099 tax reporting. Defaults to the company name when useCompanyNameAsDisplayName is set, otherwise to "firstName lastName".

send1099boolean
Whether the vendor receives a 1099. Defaults to true.

 

Returns


The standard List Response Format with a data property containing an array with one Created Vendor object.

The response reflects the vendor as stored in AppFolio, not the request as submitted. The address, phone number and email are returned as address, phoneNumbers and email, the same way the Vendor list row returns them; glAccountId is returned as the account's displayed defaultGLAccount, and tradeIds as the displayed vendorTrades string.