Partner Leads API
At the time of writing this document there is one public endpoint for submitting leads to TakePayments. The URL of this endpoint is: https://partner.takepayments.com/umbraco/api/PartnerLeadsApi/Insert
Partner Leads API > Insert
Authentication
We will share the API Key for the below requests with you – the one included in these examples is just an example and will not work on live. The API key needs to be included in the body of every request that you send in the ‘ApiKey’ field. Failure to provide a valid API key will result in 401 response.
Specification
Method: POST
Headers: Content-Type=application/json
Request Body
Request Body: The request body needs to be a JSON object, constructed using the following fields (full example of the JSON object)
Request Body Validation
Each field has the following validation associated with it:
FirstName: Required - String - Max Length 200
LastName: Required - String - Max Length 200
Email: Required - String - Max Length 200
ID: Required - String - Max Length 200 - (A unique ID from within your system that you may want to reference later)
ApiKey: Required - String - Max Length 200 - (This will be provided to you before you integrate with the API)
Notes: Not Required - String - Max Length 2000 - (Supporting notes about lead)
Postcode: Not Required - String - Max Length 200
Company: Not Required - String - Max Length 200
Address: Not Required - String - Max Length 2000
Referrer: Not Required - String - Max Length 200 (Name of the person who is referring the lead)
ReferrerEmail: Not Required - String - Max Length 200 (Email address of the person who is referring the lead)
Devices: Not Required - String - Max Length 2000 (Devices associated with this lead. E.g. A920)
Locations: Not Required - String - Max Length 2000 (locations associated with this lead)
Industry: Not Required - String - Max Length 200
CustomerType: Not Required - String - Max Length 200
HotTransfer: Not Required - Boolean (Default is false - used to indicate if this is a hot transfer lead).
ExternalLeadType: Not Required - String - Max Length 200 (A lead type field for you to associate a lead type with it e.g. 'Warm Lead')
ExistigCustomerReferenceNumber: Not Required - String (If a customer already has a reference number with us e.g. TPM1234)
Response Types:
200 OK: The Request was successful and the lead will be processed into our dialler software for a sales person to pick up.
400 Bad Request: The request has something missing from it or doesn't meet the required validation. A note will be included in the JSON response body explaining the issue.
401 Unauthorised: The ApiKey is not included in the request object and/ or doesn't match anything in our system.
Support
If you require additional support on the documentation above please reach out the the developer support inbox at webdevelopers@takepayments.com.