Search

getSuppliers

Retrieve suppliers.

Suppliers can be associated with products (see getProducts) and purchase orders / purchase invoices (see getPurchaseDocuments).

Input parameters

Parameter nameDescriptionPossible valueRequired
supplierIDSupplier IDInteger
searchNameSearch from supplier name, e-mail or phone.String
searchPersonFullNameSearch from person full name.String
searchPersonFirstNameSearch from person first name.String
searchPersonLastNameSearch from person last name.String
searchVATNoSearch from supplier VAT noString
searchAttributeNameSearch from attribute name.searchAttributeName and searchAttributeValue have to be specified bothString
searchAttributeValueSearch from attribute valueString
supplierManagerIDSupplier manager. See getEmployees.Integer
groupIDSupplier group ID. See getSupplierGroups.Integer
modeSUPPLIERS, CONTACTS or ALL.
By default ALL.

ERPLY makes a distiction between 1) companies who are suppliers in their own right, and 2) persons who are marked as contact persons of some other supplier. Option "SUPPLIERS" returns only the first ones, "CONTACTS" returns only the second ones and "ALL" returns both.
String
changedSinceRetrieve only items that have been added or modified since the specified timestamp. Use it to keep a local database in sync with ERPLY.Integer (Unix timestamp)
orderBy'name', 'group' or 'lastChanged'. By default 'name'.
orderByDir
recordsOnPageNumber of records API should return. By default 20, at most 100.Integer
pageNoAPI returns at most recordsOnPage items at a time. To retrive the next recordsOnPage items, send a new request with pageNo incremented by one. By default, API returns "page 1".Integer

Response

Field nameTypeDescription
supplierIDIntegerSupplier ID
supplierTypeStringCOMPANY or PERSON.

  • For companies, the following attributes are set: fullName, companyName (both have the same value).
  • For persons, the following attributes are set: fullName, firstName, lastName. fullName is a combination of latter two: "lastName, firstName".

fullName can be used for displaying supplier's name wherever needed.

Guidelines for applications with a supplier edit form:
  • Companies should have one name field and the attribute that is edited should be companyName.
  • Persons should have separate fields for given name and surname (respective attributes: firstName, lastName).

Note: API call saveSupplier also has an input parameter "fullName" (when using that, system tries to interpret and split the name as required), but it should be used only when brokering data from some other system where a better data format is not available.
fullNameStringFull name of the supplier, use for displaying supplier name.
companyNameStringFor companies only.
firstNameString(Given name.) For persons only.
lastNameString(Surname.) For persons only.
groupIDIntegerSupplier group ID
groupNameString
phoneString
mobileString
emailString
faxString
codeStringNational ID number (for persons) / Registry code (for companies).
integrationCodeStringCorresponding supplier identifier in a system integrated with Erply (eg. accounting software)
countryNameStringSupplier country
countryCodeStringSupplier country, as a two-letter country code (ISO 3166-1 alpha-2)
addressStringOne of supplier's addresses. Only for concise displaying of supplier information. To manage addresses, use API calls getAddresses and saveAddress.
GLNString
attributesArrayAdditional attributes. Each item looks like this:

Field nameTypeDescription
attributeNameStringAttribute name
attributeTypeStringAttribute type
attributeValueStringAttribute value
****************To retrieve the following fields, set input parameter responseMode = "detail". These fields are not included in the output by default.
vatNumberStringSupplier VAT number.
skypeString
websiteString
bankNameStringName of supplier's bank.
bankAccountNumberStringNumber of supplier's bank account.
bankIBANStringIBAN number of supplier's bank account.
bankSWIFTStringBIC/SWIFT identifier of supplier's bank account.
birthdayDate (yyyy-mm-dd)Person birthday
companyIDIntegerID of company (if user is a contact person of a particular company)
parentCompanyNameString
supplierManagerIDIntegerSupplier manager ID
supplierManagerNameString
paymentDaysIntegerDefault payment period.
notesString
lastModifiedUnix timestamp
addedUnix timestamp
****************End of extra output fields