Table 18 - Customers
- This article introduces the fields of the customer integration layout. To better understand the concept behind customers, see our article on Customer Concept.
| Order | Field Description | Format and Size | Required | Version | Note |
| 1 | Table Identifier (IDENTIFICADOR) | FIXED=18 (2) | Yes | 1.0 | |
| 2 | Customer Code (codigo) | Integer (10) | Yes | 1.0 | Customers registered by the salesperson take code "0"; the key to updating the code of these customers is the CNPJ/CPF field. |
| 3 | CNPJ/CPF (cpfCNPJ) | Text (18) | No | 1.0 | Send with mask EX: 01.010.101/0001-72; field becomes mandatory when codigo and uniqueID are null, blank, or zero. |
| 4 | Payment Term Code (codCondicaoPagamento) | Text (20) | No | 1.0 | Determines the default payment term for this customer. This is the payment term that will be selected when starting to enter a new order. *When the payment term is locked, it cannot be changed on the order. If bloqueiaCondPagamento = 1, only the defined payment term is shown when creating an Order and cannot be changed. |
| 5 | Payment Method Code (codFormaPagamento) | Text (20) | No | 1.0 | Determines the default payment method for this customer. This is the payment method that will be selected when starting to enter a new order. *When the payment method is locked, it cannot be changed on the order. If bloqueiaFormaPagamento = 1, only the defined payment method is shown when creating an Order and cannot be changed. |
| 6 | Region Code (codRegiao) | Text (30) | No | 5.18 | Region Code |
| 7 | Salesperson Code (codVendedor) | Integer (10) | No | 1.0 | ATTENTION: If the salesperson code is sent, the customer appears only for the specified salesperson; otherwise, the customer appears for all salespersons. |
| 8 | Price List Code (codListaPreco) | Text (20) | No | 1.0 | Determines the default price list for this customer. This is the price list that will be selected when starting to enter a new order. *When the price list is locked, it cannot be changed on the order. If bloqueiaListaPreco = 1, only the defined price list is shown when creating an Order and cannot be changed. |
| 9 | Customer City Code (codCidade) | Integer (10) | Yes | 1.0 | |
| 10 | Branch Code (codFilial) | Text (15) | No | 1.0 | Determines the default branch for this customer. This is the branch that will be selected when starting to enter a new order. *When the branch is locked, it cannot be changed on the order. If bloqueiaFilialUnidade = 1, only the defined branch is shown when creating an Order and cannot be changed. |
| 11 | Corporate Name (nomeRazao) | Text (100) | Yes | 1.0 | |
| 12 | Trade Name (nomeFantasia) | Text (100) | Yes | 1.0 | |
| 13 | Person Type (tipoPessoa) | Text (1) | Yes | 1.0 | F = Individual; J = Legal Entity |
| 14 | Visit Interval (intervaloVisitas) | Integer (10) | No | 1.0 | |
| 15 | ID or State Registration (rgIE) | Text (20) | No | 1.0 | |
| 16 | Primary Phone (telefone1) | Text (255) | No | 1.0 | Send with mask. EX: (51) 3714-7017 |
| 17 | Secondary Phone (telefone2) | Text (255) | No | 1.0 | |
| 18 | Buyer Email Address (emailComprador) | Text (255) | No | 1.0 | |
| 19 | NF-e Email Address (emailNfe) | Text (255) | No | 1.0 | |
| 20 | Financial Email Address (emailFinanceiro) | Text (255) | No | 1.0 | |
| 21 | Contact Person at Customer (contato) | Text (50) | No | 1.0 | |
| 22 | Customer Address (endereco) | Text (100) | No | 1.0 | |
| 23 | Neighborhood (bairro) | Text (50) | No | 1.0 | |
| 24 | ZIP Code (cep) | Text (10) | No | 1.0 | Send with mask EX: 95900-000 |
| 25 | State (uf) | Text (2) | No | 1.0 | |
| 26 | Note (observacao) | Text (2000) | No | 1.0 | |
| 27 | Active (ativo) | Integer (1) | No | 1.0 | 1 = Active or 0 = Inactive |
| 28 | Blocked (bloqueado) | Integer (1) | No | 1.7 | 1 = Does not allow sales to Customer, 0 = Allows sales to Customer |
| 29 | Number (numero) | Integer (10) | No | 1.11 | Address Number |
| 30 | Address Complement (complemento) | Text (200) | No | 1.11 | |
| 31 | Latitude (latitude) | Text (50) | No | 1.12 | |
| 32 | Longitude (longitude) | Text (50) | No | 1.12 | |
| 33 | Lock Branch/Unit editing (bloqueiaFilialUnidade) | Integer (1) | No | 1.15 | Prevents the salesperson from changing the customer default Branch during order entry. |
| 34 | Lock Price List editing (bloqueiaListaPreco) | Integer (1) | No | 1.15 | Prevents the salesperson from changing the customer default Price List during order entry. |
| 35 | Lock Payment Term editing (bloqueiaCondPagamento) | Integer (1) | No | 1.15 | Prevents the salesperson from changing the customer default Payment Term during order entry. |
| 36 | Lock Payment Method editing (bloqueiaFormaPagamento) | Integer (1) | No | 1.15 | Prevents the salesperson from changing the customer default Payment Method during order entry. |
| 37 | Individual State Registration (inscricaoEstadualPessoaFisica) | Text (30) | No | 2.6 | |
| 38 | Demander Customer Unique Identifier (idCliente) | Integer (10) | No | 2.10 | ATTENTION: If the salesperson registered a new customer without entering CPF/CNPJ, the customer assumes code Zero. However, when the ERP returns the customer info it already comes with a code, so this field is used as a key to update the customer since CPF/CNPJ was not filled in. Therefore, your ERP must store this field to return it to Demander; otherwise, customers will duplicate in Demander or salespersons will not be allowed to register customers without entering CPF/CNPJ. |
| 39 | Tax Customer Type (codTipoClienteTributario) | Text (20) | No | 2.13 | This field is used by some companies in IPI and ICMS ST calculations; only be concerned with it if you integrate Tax configuration. |
| 40 | Related Salespersons (vendedoresRelacionados) | Text (500) | No | 2.17 | Send here the codes of the Salespersons who serve the customer separated by commas. This field only needs to be sent from ERP to Demander if more than one salesperson serves (views) the Customer. Example: "24, 75, 145" (If only one salesperson serves the customer, use only the codVendedor field). If a salesperson registers a new customer in Demander, only the codVendedor field is filled; this field starts empty. |
| 41 | Customer in Prospecting (prospecto) | Integer (1) | No | 2.30 | 0 - Not a Prospect, already a Customer. 1 - Is a prospect, not yet a Customer. Demander allows salespersons to register prospects they are currently contacting. Normally these Prospects do not want to provide all registration details; therefore, in the Demander app we have a separate feature for prospect registration, including separate mandatory field settings. Even though they are not customers, Prospects can be exported to the ERP in the customer table layout; if your ERP is not structured to import prospects, configure them not to be exported by accessing "Company Settings", tab "Additional settings" and search for the setting "Export prospects" and set Yes or No. (Currently we do not support importing prospects without code or CNPJ, unless you use the "Demander Unique Identifier" field) |
| 42 | Change Identifier (idAlteracaoERP) | Text (255) | No | 2.31 | Field exclusively for ERP control. Demander only imports and returns it to the ERP. This field can be used for the ERP to implement change conflict control between ERP and salesperson. (Internal note: See task #31145 in Redmine) |
| 43 | Commercial agreement percentage (percAcordoComercial) | Decimal | No | 2.36 | Currently the commercial agreement field is used to decrease or increase the customer maximum discount. EX: If the company has a maximum discount of 25%, but the customer has a commercial agreement of 5%, then for this customer the salesperson can give up to 30% discount. If it is necessary to decrease the customer maximum discount to 20%, -5 can be sent in the commercial agreement field. (Customer Maximum Discount = Company Maximum Discount + Commercial Agreement) |
| 44 | Preferred Carrier Code (codTransportadora) | Text (30) | No | 2.41 | Customer preferred Carrier Code. If this field is filled during order entry, the system will automatically select this carrier, but will still allow changes. |
| 45 | Preferred Redispatch Carrier Code (codRedespacho) | Text (30) | No | 2.41 | Customer preferred Redispatch Carrier Code. If this field is filled during order entry, the system will automatically select this carrier, but will still allow changes. |
| 46 | Date of Birth (dataNascimento) | Date | No | 2.47 | |
| 47 | Related segments (segmentosRelacionados) | Text (500) | No | 2.48 | Field to identify the segments that a given customer uses. Ex: Motorcycle utilities, Bicycle utilities |
| 48 | Regional Council of Dentistry Number (cro) | Text (50) | No | 3.5 | |
| 49 | Customer maximum discount percentage (percentualDescontoMaximo) | Decimal | No | 3.6 | Maximum discount percentage that the customer can receive on an order. When filled, this field overrides any other discount rule. |
| 50 | Freight Rate Table Code (codFaixaFrete) | Text (30) | No | 3.14 | Freight Rate table code used to calculate the suggested freight amount. |
| 51 | Economic group code (codGrupoEconomico) | Text (100) | No | 3.20 | Defines which economic group the customer belongs to. It is necessary to integrate Table 35 - Economic Group. |
| 52 | Additional price lists (listaPrecosAdicionais) | Text (255) | No | 3.20 | Additional price lists that the customer can access. If the customer has a locked list, the additional lists will NOT appear as options to be chosen. |
| 53 | Check-in radius (checkinRaio) | Integer (10) | No | 3.20 | Customer radius in meters, used for the Check-in Module. |
| 54 | Check-in days (checkinDias) | Integer (10) | No | 3.20 | Number of days since last Check-in, used for the Check-in Module. |
| 55 | Additional payment terms (condicoesAdicionais) | Text (255) | No | 3.28 | Additional payment terms that the customer can access. If the customer has a locked payment term, the additional payment terms will NOT appear as options to be chosen. |
| 56 | Integration note (observacaoIntegracao) | Text (2000) | No | 3.34 | When integrated, an eye icon is displayed in the customer record, and this note is shown when clicking it. |
| 57 | Credit limit (limiteCredito) | Decimal | No | 3.37 | Used to block orders for customers that exceed the credit limit. Also used for the Financial Collections Module. |
| 58 | Contribution margin percentage (percMargemContribuicao) | Decimal (8,2) | No | 3.38 | Used for calculation in the Contribution Margin Module. |
| 59 | Appointed Salespersons (VendedoresPrepostos) | Text (500) | No | 3.42 | These are salespersons/representatives managed directly by the salesperson/representative. Example: The representative of ABC Company hires a Salesperson to sell for them; this person will be an Appointed Salesperson under this Representative. |
| 60 | Customer default hierarchy (codHierarquiaLiberacaoPedido) | Text (255) | No | 3.42 | |
| 61 | Customer Type (codTipoCliente) | Text (30) | No | 4.18 | Code from table Customer Type. |
| 62 | Sales Division (codDivisaoVenda) | Text (30) | No | 4.18 | Code from table Sales Division. |
| 63 | Default order type (codTipoPedido) | Integer | No | 4.22 | Defines the default order type for the customer. This order type will be automatically selected when starting a new order. When locked, changing the order type is not permitted, as shown in the examples below. If bloqueiaTipoPedido = 1. |
| 64 | Lock order type editing (bloqueiaTipoPedido) | Boolean | No | 4.22 | This field prevents the salesperson from changing the customer default order type when placing an order. |
| 65 | Additional order types (tipoPedidoAdicionais) | Text (255) | No | 4.22 | Additional order types that the customer can access. If the customer has a locked order type, the additional order types will NOT appear as available options. |
| 66 | Unloading fee (valorDescarga) | Decimal (10,5) | No | 4.47 | Unloading fee per kg of net weight of the Order. Can be used in calculating Ancillary Expenses. |
| 67 | Allows changing Ancillary Expense value (permiteAlterarDespesaAcessoria) | Boolean | No | 4.51 | Determines whether or not the salesperson can change the suggested amount for "Ancillary Expense" in orders for this customer. |
| 68 | Requires purchase order (exigeOrdemDeCompra) | Boolean | No | 4.55 | Determines whether the "purchase order" field is required for this customer. * Only takes effect when the "Order Type" also "requires purchase order"; |
Registration Example:
18|3004007|23.596.536/0001-17||0|0|170895|0|4322509|2|VILMAR MACIEL DE MORAES 78145171091|AUTO DESIGN CENTRO AUTOMOTIVO | 991127156|macieldemorais@bol.com.br|||ALINE|EST DO MARMELEIRO, 35|MAUA|95214410|RS||1|0||||||0|0|||9695140|G||0|2020-08-11 08:19:23|0||||||0||||0|0|||