# Get a list of available customers Endpoint: GET /customers Version: 1.41 Security: bearerAuth ## Query parameters: - `page` (integer, required) Page of results to show Example: 1 - `pageSize` (integer, required) Results to return per page Example: 100 - `sort` (string) Comma-delimited list of the fields to sort by - defaults to ascending order, suffix :desc to change Example: "id,name | name:desc" - `fields` (string) Comma-delimited list of the field(s) to return if only a subset is required Example: "id,name" - `contractOwnerId` (string) Filter by contract owner Example: "0" - `customerName` (string) Filter by customer name Example: "xyz | in:x,y | like:xyz" - `customerType` (string) Filter by customer type Example: "xyz | in:x,y | like:xyz" - `customerAccountNumber` (string) Filter by customer account number Example: "xyz | in:x,y | like:xyz" - `billingCycleId` (string) Filter by billing cycle Example: "0" - `startDate` (string) Filter by start date Example: "yyyy-MM-dd | lt:yyyy-MM-dd | gt:yyyy-MM-dd | gtn:yyyy-MM-dd" - `endDate` (string) Filter by end date Example: "yyyy-MM-dd | lt:yyyy-MM-dd | gt:yyyy-MM-dd | gtn:yyyy-MM-dd" - `createdDate` (string) Filter by created date/time Example: "yyyy-MM-ddTHH:mm:ssZ | lt:yyyy-MM-ddTHH:mm:ssZ | gt:yyyy-MM-ddTHH:mm:ssZ" - `updatedDate` (string) Filter by updated date/time Example: "yyyy-MM-ddTHH:mm:ssZ | lt:yyyy-MM-ddTHH:mm:ssZ | gt:yyyy-MM-ddTHH:mm:ssZ" ## Response 200 fields (application/json): - `id` (integer) Customer identifier Example: 1 - `contractOwnerId` (integer, required) Contract Owner Identifier - `contractOwnerSubBrandId` (integer) Contract owner sub brand identifier, if not specified then the default will be used - `customerType` (string, required) Customer type Enum: "RESIDENTIAL", "BUSINESS", "RESELLER", "STAFF_MEMBER" - `customerName` (string, required) Customer Name - `customerAccountNumber` (string, required) Customer account number - `startDate` (string, required) Customer start date - `endDate` (string) Customer end date - `createdDate` (string) Customer created date - `updatedDate` (string) Customer updated date - `contractTerm` (integer) Contract term in months if applicable - requires contract term start date - `contractTermStartDate` (string) Start date of contract term if applicable - required with contract term - `customerIsVip` (boolean) Customer is marked as VIP (deprecated - please use customerMarker instead) - `customerMarker` (boolean) Customer is marked, e.g. VIP, Vulnerable, etc - `externalCommissionAgentId` (integer) External commission agent identifier Example: 1 - `onlineBillingRequired` (boolean) Online billing required - `onlineEmailAddress` (string) Email address - `sendWelcomeEmailOn` (string) Send welcome email on this date - `billingCycleId` (integer, required) Billing cycle identifier Example: 1 - `sites` (array, required) - `sites.id` (integer) Site identifier Example: 1 - `sites.customerId` (integer, required) Customer identifier - set to 0 when creating a new customer - `sites.siteName` (string, required) Site name - `sites.siteReference` (string, required) Site reference - `sites.startDate` (string, required) Site start date - `sites.endDate` (string) Site end date - `sites.createdDate` (string) Site created date - `sites.updatedDate` (string) Site updated date - `sites.siteAddress` (object, required) - `sites.siteAddress.id` (integer) Internal identifier for address entry Example: 1 - `sites.siteAddress.businessName` (string) Business name - `sites.siteAddress.address1` (string, required) Address line 1 - `sites.siteAddress.address2` (string) Address line 2 - `sites.siteAddress.address3` (string) Address line 3 - `sites.siteAddress.town` (string, required) Town - `sites.siteAddress.county` (string) County - `sites.siteAddress.postcode` (string, required) Postcode - `sites.siteAddress.country` (string, required) ISO 3166 alpha-2 code representing country Example: "GB" - `sites.siteInvoiceDetails` (object) Invoice details if this site should receive invoices - `sites.siteInvoiceDetails.invoiceSummaryTemplateId` (integer) Invoice summary template identifier - set on creation of site only - `sites.siteInvoiceDetails.invoiceTemplateId` (integer, required) Invoice template identifier - set on creation of site only - `sites.siteInvoiceDetails.electronicSummaryTemplateIds` (array) List of electronic summary template identifiers associated with this site Example: [123] - `sites.siteInvoiceDetails.invoiceSummaryTemplateComponents` (array) List of invoice summary template components associated with this site - `sites.siteInvoiceDetails.invoiceSummaryTemplateComponents.id` (integer, required) Invoice summary component identifier Example: 1 - `sites.siteInvoiceDetails.invoiceSummaryTemplateComponents.positionInTemplate` (integer, required) Position of the component within the invoice summary template Example: 1 - `sites.siteInvoiceDetails.invoiceAddress` (object) - `sites.siteInvoiceDetails.accountPackageReference` (string) Account package reference - `sites.siteInvoiceDetails.paymentTermsInDays` (integer) Payment terms in days, used to derive the invoice due date. Either paymentTermsInDays or preferredPaymentDay are required - `sites.siteInvoiceDetails.preferredPaymentDay` (integer) Preferred payment day of month, used to derive the invoice due date. When automated, it will be used to collect money on that date. Either paymentTermsInDays or preferredPaymentDay are required - `sites.siteInvoiceDetails.paymentMethod` (string, required) Payment method Enum: "CHEQUE", "DIRECT_DEBIT", "CANCELLED_DD", "CANCELLED_CARD", "CREDIT_CARD", "PAYPAL", "BACS", "POST_OFFICE_PAYMENT_CARD", "EZYPAY", "GO_CARDLESS", "GC_INSTANT_BANK_PAYMENTS", "STRIPE", "STRIPE_CARD", "STRIPE_DD", "FINASTRA", "FAST_PAY", "OTHER" - `sites.siteInvoiceDetails.mandateStatus` (string) Mandate status - `sites.siteInvoiceDetails.mandateCreatedDate` (string) Site invoice mandate created date - `sites.siteInvoiceDetails.mandateUpdatedDate` (string) Site invoice mandate updated date - `sites.siteInvoiceDetails.mandateReference` (string) Required when the paymentType is an integrated one, for example GO_CARDLESS, FINASTRA or STRIPE. If GO_CARDLESS, only accepted Created, Pending Submission, Submitted, Active, Reinstated, Customer approval granted and Customer approval skipped - `sites.siteInvoiceDetails.thirdPartyCustomerReference` (string) Reference to a customer in a third party system. For example, Stripe Customer ID (mandatory if a Stripe mandate is provided), or optional references like GO_CARDLESS Customer Reference or FINASTRA Account Number - `sites.siteInvoiceDetails.directDebitReference` (string) Direct debit reference - `sites.siteInvoiceDetails.accountName` (string) Bank account name - `sites.siteInvoiceDetails.accountNumber` (string) Bank account number - `sites.siteInvoiceDetails.sortCode` (string) Sort code - `sites.siteInvoiceDetails.purchaseOrderNumber` (string) Purchase order number - `sites.siteInvoiceDetails.invoiceNotes` (string) Notes to appear on invoices addressed to this site - `sites.siteInvoiceDetails.taxExempt` (boolean) Site is tax exempt - `sites.siteInvoiceDetails.taxRegistrationNumber` (string) Tax registration number - `sites.siteIdReceivingInvoice` (integer) Identifier of another site that receives the invoices if no invoice details provided for this site Example: 1 - `sites.siteContacts` (array, required) - `sites.siteContacts.id` (integer) Contact identifier Example: 1 - `sites.siteContacts.contactName` (string, required) Contact name - `sites.siteContacts.contactTelephoneNumber` (string) Contact telephone number - `sites.siteContacts.contactAlternativeTelephoneNumber` (string) Contact alternative telephone number - `sites.siteContacts.contactEmailAddress` (string) Email address - `sites.siteContacts.contactRole` (string, required) Contact Role Enum: "ACCOUNTS", "TECHNICAL", "SALES", "GENERAL" - `sites.siteContacts.receiveInvoiceBy` (string) Receive invoice by email, post or both? Required when contactNameToAppearOnInvoice is set to true Enum: "EMAIL", "POST", "EMAIL_AND_POST" - `sites.siteContacts.receiveInvoiceSummaryBy` (string) Receive invoice summary by email, post or both? Enum: "EMAIL", "POST", "EMAIL_AND_POST" - `sites.siteContacts.receiveElectronicSummaryReports` (boolean) Will receive electronic summary reports - `sites.siteContacts.emailSuspended` (boolean) Whether the contact is unable to receive emails - `sites.siteContacts.contactNameToAppearOnInvoice` (boolean) Only 1 contact per site can be set to true. If unspecified, this will be defaulted to the 1st contact. If specified for a different contact, it will be set to false for the previous one - `sites.siteContacts.receiveEmailFraudAlert` (boolean) Will receive a fraud alert by email - `sites.siteContacts.receiveSmsFraudAlert` (boolean) Will receive a fraud alert by SMS - `sites.repaymentPlanAmount` (number) Repayment plan period amount in major currency (e.g pounds/dollars/euros) - `sites.repaymentPlanRemainingPeriods` (integer) repayment plan remaining periods (typically in months) - `sites.assignedCustomFields` (array) Example: [{"customFieldDefinitionId":102,"label":"Customer Tier","value":"Gold"}] - `sites.assignedCustomFields.id` (integer) Unique identifier of the assigned custom field Example: 1 - `sites.assignedCustomFields.customFieldDefinitionId` (integer, required) Unique identifier of the custom field definition Example: 1 - `sites.assignedCustomFields.label` (string) Display label of the custom field definition Example: "Additional field definition label" - `sites.assignedCustomFields.value` (string) Value assigned to the assigned custom field (can be null if not set) Example: "Additional field value" - `creditThreshold` (number) Customer credit threshold Example: 100 - `tripwireId` (integer) Tripwire plan identifier - `customerContacts` (array) ## Response 400 fields ## Response 401 fields ## Response 403 fields