Customers - API Requests

This document provides information about the PurePro public API endpoints associated with customer operations and their objects.
Common operations;
Please select one of the options below: -

Customers

GET

Method:
BaseURL: {{publicApiUrl}}/Customer/{{accountReference}}/{{businessUnitReference}}/Customer_REF
To retrieve details for a specific customer. To retrieve customer details, users would need to pass account and business unit reference to the base URL, along with the customer reference.
Account
  • Cannot be Null
  • Cannot be left blank
Business Unit
  • Cannot be Null
  • Cannot be left blank
Customer
  • Cannot be Null
  • Cannot be left blank

Customer Add

Method:
Base URL: {{publicApiUrl}}/Customer/{{accountReference}}/{{businessUnitReference}}
To add a customer record using the public API you need to pass the account and business unit reference to the base URL with the required objects in the body. Refer to  Appendix I  containing a sample of the request body.
Account
  • Cannot be Null
  • You must select an existing Account to add a worker
Business Unit
  • Cannot be Null
  • You must select an existing Business Unit to add a worker
Customer can be added without contacts, addresses, cost centre or purchase order information
The key dependencies and validations are:
"Reference":"string"
  • Cannot be null
  • Can be blank and the system will automatically generate a reference from the customer
"Name":"string"
  • Cannot be null
  • Cannot be blank
  • You must enter a Customer Name
  • Customer Name must be between 3 and 100 characters
"Email":"string"
  • Cannot be null
  • Cannot be blank
  • You must enter a Customer Email Address
  • You must provide a valid Customer Email Address
"BillingScheme":"string"
  • Can be null
  • Can be blank
"BillingGroup":"string"
  • Can be null
  • Can be blank
"InvoiceDeliveryMethod":"string"
  • Cannot be Null
  • You must provide a Delivery Method.
  • Acceptable values are: - “Email”, “Paper, “Online”
"IndustryClassification":"string"
  • Can be null
  • Can be blank
"VATNumber":"wholenumber"
  • Can be null
  • Can be blank
"VATNumberValid":"boolean"
  • Can be false or true
  • Cannot be null
  • Cannot be blank
"CompaniesHouseNumber":"wholenumber"
  • Can be null
  • Can be blank
"PayMethod":"string"
  • Cannot be null
  • Cannot be blank
  • You must provide a valid Payment method.
  • Acceptable values are: “BACS”, “Cheque”, “Manual”, “Cash”, “Chaps”
"ApprovalFrequency":"wholenumber"
  • Cannot be null
  • Cannot be blank
  • A number must be provided i.e., 60, 120 and that’s in minutes
  • Approval Frequency cannot be negative
"Contact":"string"
  • Can be null
  • If the customer is being added with contact, then the following details needs to be completed
  • You must enter a First Name
  • You must enter a Last Name
  • You must enter an Email Address
  • You must provide a valid Email Address
  • Acceptable values are: “Primary”, “Billing”, “Hiring”, “Other”
"Addresses":"string"
  • Can be null
  • If the address record doesn’t exist in the body, then will return 200 but record will display as failed validation error in the webapp
  • You must enter the Address Line 1
  • Address Line 1 must be between 1 and 35 characters
  • You must enter a postcode
  • Postcode - incorrect format
  • Worker has missing address detail. Please ensure at least 2 lines of the address are populated.
"CostCentre"""string"
  • Can be null
  • If cost centre record exists then reference and description must be supplied
"PurchaseOrder":"string"
Can be null
If the purchase order record exists then can be blank or must be provided
"Currency":"string"
  • Cannot be null
  • Cannot be blank
  • Acceptable values are: "EUR", "GBP", "HUF", "USD"

Customer update

Method:
Base URL: {{publicApiUrl}}/Customer/{{accountReference}}/{{businessUnitReference}}
To update a customer record using the public API you need to pass the account and business unit reference to the base URL with the required objects in the body. Refer to  Appendix J  containing a sample of the request body.
Account
  • Cannot be Null
  • You must select an existing Account to add a worker
Business Unit
  • Cannot be Null
  • You must select an existing Business Unit to add a worker
Note: Customer can be updated without contacts, addresses, cost centre or purchase order information
The key dependencies and validations are:
"Reference":"string"
  • Cannot be null
  • Cannot be blank
  • You must input a customer reference
"BackingData":"string"
Backing data records can only be added via customer update
  • Can be null
  • Or input the following object in the body and update the values with your available dataset
"backingData": {
"consultantReference": "CS1000002",
"costCentre": "1",
"purchaseOrder": "CU10005A",
"industrySector": "IS0000001",
"jobClassification": "JC0000001",
"jobTitle": "JT0000001",
"HiringManagerContact": "3DD",
"WorkLocationAddress": "3DD",
"BillingAddress": "3DD",
"BillingContact": "3DD",
"externalReference": "EXT-1234",
"customBackingData": [
{
"Reference": "test",
"value": "666"
}
],
"hasConsultantSplits": false
}


The contents of this document, along with any associated documents, are the property of PurePro Solutions Ltd. and are shared in strict confidence with the intended recipient. These materials may not be reproduced, shared, or used in any manner without prior written consent from PurePro Solutions Ltd. Unauthorized use or distribution is prohibited.