Open
Description
🐛 Describe the Issue
Just some poor documentation for this.
📍 API Endpoint
https://services.leadconnectorhq.com/contacts/search
💻 Screenshots or Code Samples
The default example given is this:
const url = 'https://services.leadconnectorhq.com/contacts/search';
const options = {
method: 'POST',
headers: {
Authorization: 'Bearer [key]',
Version: '2021-07-28',
'Content-Type': 'application/json',
Accept: 'application/json'
},
body: '{}'
};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
Nowhere does it say body
should look something like this:
{
"pageLimit" : 1,
"locationId" : "yfyIrXrm61r57rx3ex4N",
"query" : "your query here"
}
I had to figure this out on my own. Also, if pageLimit and locationId aren't specified, it'll 422. Nowhere in the documentation is this exemplified or made obvious, even on the linked page here. Please fix your documentation!