Laminin exposes a RESTful API endpoint that can be used to manipylate the Contacts Module of the Laminin platform by external sources such as a contact form on your company website using HTTP methods. This document lists all integration endpoints for the Contacts Module.
Please note this document uses examples of the non-production environment of Laminin.
Production credentials and endpoints will be supplied upon request.
Authentication Header
The Header must have a key value pair for authentication where the value is the API Key:
- Key: X-Laminin-Client-ID
- Value: {apiKey} to be provided by Laminin
Header Postman Example:
Creating a Contact
Contacts can be created with validation using the POST transaction type on the following endpoint:
https://dev-extapi.lamin.in/api/v1/contacts/
Note that there are two available "Contact Types", each indicated by a numeric integer. When creating a contact for a supplier, please ensure that you set the type to 3.
- Customer / Individuals are indicated by 0
- Company / non-person entities are indicated by 3
JSON Payload Example:
{
"ContactTypeId": 0,
"Title": "Mr",
"FirstName": "Wade",
"LastName": "Wilson",
"UniqueId": "7812110000080",
"PrimaryPhone": "0812345678",
"PrimaryEmail": "wade@dead.pool",
"Supplier": "Company Name"
}
Updating a Contact
Contact details can be updated with validation using the PUT transaction type usng the following endpoint where {id} represents the unique Contact ID as it exists within the Laminin platform:
https://dev-extapi.lamin.in/api/v1/contacts/{id}
JSON Payload Example:
{
"id": 123,
"ContactTypeId": 0,
"Title": "Mr",
"FirstName": "James",
"LastName": "Logan",
"UniqueId": "1902120000080",
"PrimaryPhone": "0112345678",
"PrimaryEmail": "james@logan.com",
"Supplier": "Company Name"
}
Please note that the {id} must be included in both the endpoint url as well as the payload body.
Searching for a Contact
Contacts can be searched with the GET transaction type usng the following endpoint:
https://dev-extapi.lamin.in/api/v1/contacts/search?searchText={searchText}
Any of the following fields with permission-based filtering can be used as the {searchText}
- Name
- Phone Number
- Supplier (Company Name)
Retreiving Contact Details
Contacts details, including associated leads and products, can be retrieved with the GET transaction type usng the following endpoint where {id} represents the unique Contact ID as it exists within the Laminin platform:
https://dev-extapi.lamin.in/api/v1/contacts/{id}
In addition to the primary Contact Module, Laminin also expooses an additional, related module: Contact Products. The following sections will detail the manipulation of these modules via API events.
Creating a Contact Product
Contact Products can be created using the POST transaction type on the following endpoint:
https://dev-extapi.lamin.in/api/v1/contact-products/
There are 3 default fields available on a Contact Product plus an additional 15 "custom fields", 10 string fields and 5 datetime fields. These "custom fields" need to be configured in your environment to be visible to the end user.
JSON Payload Example:
{
"Product": "Premium Black",
"ContractNumber": "LAM00123",
"Premium": 500.00,
"Custom1": "string",
"Custom2": "string",
"Custom3": "string",
"Custom4": "string",
"Custom5": "string",
"Custom6": "string",
"Custom7": "string",
"Custom8": "string",
"Custom9": "string",
"Custom10": "string",
"CustomDate1": "1900-01-01T00:00:00",
"CustomDate2": "1900-01-01T00:00:00",
"CustomDate3": "1900-01-01T00:00:00",
"CustomDate4": "1900-01-01T00:00:00",
"CustomDate5": "1900-01-01T00:00:00"
}
Updating a Contact Product
Contact Product details can be updated with validation using the PUT transaction type usng the following endpoint where {id} represents the unique Product ID as it exists within the Laminin platform:
https://dev-extapi.lamin.in/api/v1/contact-products/{id}
JSON Payload Example:
{
"Id": 1,
"ContactId": 132,
"Product": "Platinum Product",
"ContractNumber": "LAM00456",
"Premium": 5300.00,
"Custom1": "string",
"Custom2": "string",
"Custom3": "string",
"Custom4": "string",
"Custom5": "string",
"Custom6": "string",
"Custom7": "string",
"Custom8": "string",
"Custom9": "string",
"Custom10": "string",
"CustomDate1": "1900-01-01T00:00:00",
"CustomDate2": "1900-01-01T00:00:00",
"CustomDate3": "1900-01-01T00:00:00",
"CustomDate4": "1900-01-01T00:00:00",
"CustomDate5": "1900-01-01T00:00:00"
}
Please note that the {id} must be included in both the endpoint url as well as the payload body.
Deleting a Contact Product
Contact Products can be soft deleted with the DELETE transaction type usng the following endpoint where {id} represents the unique Product ID as it exists within the Laminin platform:
https://dev-extapi.lamin.in/api/v1/contact-products/{id}
No Payload is required in the body.
Searching for a Contact Product
Contact Products can be searched with the GET transaction type usng the following endpoint with allowance for query parameters. This will return a paginated list of products for a specific contact:
Any existing field on a Contact Product can be used as the {searchText}.
Retreiving Contact Product Details
Contact Product details can be retrieved with the GET transaction type usng the following endpoint where {id} represents the unique Product ID as it exists within the Laminin platform:
https://dev-extapi.lamin.in/api/v1/contact-products/{id}
For any questions or additional support, please mail our team at support@lamin.in
Was this article helpful?
That’s Great!
Thank you for your feedback
Sorry! We couldn't be helpful
Thank you for your feedback
Feedback sent
We appreciate your effort and will try to fix the article