Create a new customer and primary site

post/customers
SecuritybearerAuth
Request
Request Body schema: application/json

New customer and default site

contractOwnerId
required
integer <int32>

Contract Owner Identifier

contractOwnerSubBrandId
integer <int32>

Contract owner sub brand identifier, if not specified then the default will be used.

customerType
required
string (CustomerType)

Customer type

Enum: "RESIDENTIAL" "BUSINESS" "RESELLER" "STAFF_MEMBER"
customerName
required
string [ 1 .. 100 ] characters [\w\p{L}\s%£@&#=':;`’,|!_—–\(\)\\/\-\+\.\?\*\...

Customer Name

customerAccountNumber
required
string [ 1 .. 100 ] characters [\w\p{L}\s%£@&#=':;`’,|!_—–\(\)\\/\-\+\.\?\*\...

Customer account number

startDate
required
string <date>

Customer start date

endDate
string <date>

Customer end date

contractTerm
integer <int32>

Contract term in months if applicable - requires contract term start date

contractTermStartDate
string <date>

Start date of contract term if applicable - required with contract term

customerIsVip
boolean
Default: false

Customer is marked as VIP (deprecated - please use customerMarker instead)

customerMarker
boolean
Default: false

Customer is marked, e.g. VIP, Vulnerable, etc

externalCommissionAgentId
integer <int64>

External commission agent identifier

onlineBillingRequired
boolean
Default: false

Online billing required

onlineEmailAddress
string (EmailAddress) <= 255 characters (?:[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-...

Email address

sendWelcomeEmailOn
string <date>

Send welcome email on this date

billingCycleId
required
integer <int64>

Billing cycle identifier

required
Array of objects (Site) [ 1 .. 1000 ] items
creditThreshold
number [ 0 .. 100000000000000000 ]

Customer credit threshold

tripwireId
integer <int64>

Tripwire plan identifier

Array of objects (ContactDetails)
Responses
200

OK

201

Created

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

Request samples
application/json
{
  • "contractOwnerId": 0,
  • "contractOwnerSubBrandId": 0,
  • "customerType": "RESIDENTIAL",
  • "customerName": "string",
  • "customerAccountNumber": "string",
  • "startDate": "2019-08-24",
  • "endDate": "2019-08-24",
  • "contractTerm": 0,
  • "contractTermStartDate": "2019-08-24",
  • "customerIsVip": false,
  • "customerMarker": false,
  • "externalCommissionAgentId": 1,
  • "onlineBillingRequired": false,
  • "onlineEmailAddress": "string",
  • "sendWelcomeEmailOn": "2019-08-24",
  • "billingCycleId": 1,
  • "sites": [
    • {
      • "customerId": 0,
      • "siteName": "string",
      • "siteReference": "string",
      • "startDate": "2019-08-24",
      • "endDate": "2019-08-24",
      • "siteAddress": {
        • "businessName": "string",
        • "address1": "string",
        • "address2": "string",
        • "address3": "string",
        • "town": "string",
        • "county": "string",
        • "postcode": "string",
        • "country": "GB"
        },
      • "siteInvoiceDetails": {
        • "invoiceSummaryTemplateId": 0,
        • "invoiceTemplateId": 0,
        • "invoiceAddress": {
          • "businessName": "string",
          • "address1": "string",
          • "address2": "string",
          • "address3": "string",
          • "town": "string",
          • "county": "string",
          • "postcode": "string",
          • "country": "GB"
          },
        • "accountPackageReference": "string",
        • "paymentTermsInDays": 400,
        • "preferredPaymentDay": 1,
        • "paymentMethod": "CHEQUE",
        • "mandateReference": "string",
        • "directDebitReference": "string",
        • "accountName": "string",
        • "accountNumber": "stringst",
        • "sortCode": "string",
        • "purchaseOrderNumber": "string",
        • "invoiceNotes": "string",
        • "taxExempt": false,
        • "taxRegistrationNumber": "string"
        },
      • "siteIdReceivingInvoice": 1,
      • "siteContacts": [
        • {
          • "contactName": "string",
          • "contactTelephoneNumber": "string",
          • "contactAlternativeTelephoneNumber": "string",
          • "contactEmailAddress": "string",
          • "contactRole": "ACCOUNTS",
          • "receiveInvoiceBy": "EMAIL",
          • "receiveInvoiceSummaryBy": "EMAIL",
          • "receiveElectronicSummaryReports": true,
          • "emailSuspended": false,
          • "contactNameToAppearOnInvoice": false,
          • "receiveEmailFraudAlert": false,
          • "receiveSmsFraudAlert": false
          }
        ],
      • "repaymentPlanAmount": 1,
      • "repaymentPlanRemainingPeriods": 0
      }
    ],
  • "creditThreshold": 100,
  • "tripwireId": 0,
  • "customerContacts": [
    • {
      • "contactName": "string",
      • "contactTelephoneNumber": "string",
      • "contactAlternativeTelephoneNumber": "string",
      • "contactEmailAddress": "string",
      • "contactRole": "ACCOUNTS",
      • "receiveInvoiceBy": "EMAIL",
      • "receiveInvoiceSummaryBy": "EMAIL",
      • "receiveElectronicSummaryReports": true,
      • "emailSuspended": false,
      • "contactNameToAppearOnInvoice": false,
      • "receiveEmailFraudAlert": false,
      • "receiveSmsFraudAlert": false
      }
    ]
}
Response samples
application/json
{
  • "id": 1,
  • "contractOwnerId": 0,
  • "contractOwnerSubBrandId": 0,
  • "customerType": "RESIDENTIAL",
  • "customerName": "string",
  • "customerAccountNumber": "string",
  • "startDate": "2019-08-24",
  • "endDate": "2019-08-24",
  • "createdDate": "2019-08-24T14:15:22Z",
  • "updatedDate": "2019-08-24T14:15:22Z",
  • "contractTerm": 0,
  • "contractTermStartDate": "2019-08-24",
  • "customerIsVip": false,
  • "customerMarker": false,
  • "externalCommissionAgentId": 1,
  • "onlineBillingRequired": false,
  • "onlineEmailAddress": "string",
  • "sendWelcomeEmailOn": "2019-08-24",
  • "billingCycleId": 1,
  • "sites": [
    • {
      • "id": 1,
      • "customerId": 0,
      • "siteName": "string",
      • "siteReference": "string",
      • "startDate": "2019-08-24",
      • "endDate": "2019-08-24",
      • "createdDate": "2019-08-24T14:15:22Z",
      • "updatedDate": "2019-08-24T14:15:22Z",
      • "siteAddress": {
        • "id": 1,
        • "businessName": "string",
        • "address1": "string",
        • "address2": "string",
        • "address3": "string",
        • "town": "string",
        • "county": "string",
        • "postcode": "string",
        • "country": "GB"
        },
      • "siteInvoiceDetails": {
        • "invoiceSummaryTemplateId": 0,
        • "invoiceTemplateId": 0,
        • "invoiceAddress": {
          • "id": 1,
          • "businessName": "string",
          • "address1": "string",
          • "address2": "string",
          • "address3": "string",
          • "town": "string",
          • "county": "string",
          • "postcode": "string",
          • "country": "GB"
          },
        • "accountPackageReference": "string",
        • "paymentTermsInDays": 400,
        • "preferredPaymentDay": 1,
        • "paymentMethod": "CHEQUE",
        • "mandateStatus": "string",
        • "mandateCreatedDate": "2019-08-24T14:15:22Z",
        • "mandateUpdatedDate": "2019-08-24T14:15:22Z",
        • "mandateReference": "string",
        • "directDebitReference": "string",
        • "accountName": "string",
        • "accountNumber": "stringst",
        • "sortCode": "string",
        • "purchaseOrderNumber": "string",
        • "invoiceNotes": "string",
        • "taxExempt": false,
        • "taxRegistrationNumber": "string"
        },
      • "siteIdReceivingInvoice": 1,
      • "siteContacts": [
        • {
          • "id": 1,
          • "contactName": "string",
          • "contactTelephoneNumber": "string",
          • "contactAlternativeTelephoneNumber": "string",
          • "contactEmailAddress": "string",
          • "contactRole": "ACCOUNTS",
          • "receiveInvoiceBy": "EMAIL",
          • "receiveInvoiceSummaryBy": "EMAIL",
          • "receiveElectronicSummaryReports": true,
          • "emailSuspended": false,
          • "contactNameToAppearOnInvoice": false,
          • "receiveEmailFraudAlert": false,
          • "receiveSmsFraudAlert": false
          }
        ],
      • "repaymentPlanAmount": 1,
      • "repaymentPlanRemainingPeriods": 0
      }
    ],
  • "creditThreshold": 100,
  • "tripwireId": 0,
  • "customerContacts": [
    • {
      • "id": 1,
      • "contactName": "string",
      • "contactTelephoneNumber": "string",
      • "contactAlternativeTelephoneNumber": "string",
      • "contactEmailAddress": "string",
      • "contactRole": "ACCOUNTS",
      • "receiveInvoiceBy": "EMAIL",
      • "receiveInvoiceSummaryBy": "EMAIL",
      • "receiveElectronicSummaryReports": true,
      • "emailSuspended": false,
      • "contactNameToAppearOnInvoice": false,
      • "receiveEmailFraudAlert": false,
      • "receiveSmsFraudAlert": false
      }
    ]
}