API - Call to list the instance's leads searching for a specific field

Introduction

Full endpoint: https://sprinthub-api-master.sprinthub.app/arrow-up-rightleadsadvancedarrow-up-right?i=instanciaarrow-up-right

i = name of your instance

Request type: POST

JSON example

Body

{
    "query": "{leads{id,fullname,email,whatsapp,mobile}}",
    "search": "[email protected]"
}

Request Body

The request body will be JSON and must include two main fields: query and search.

  1. query: This field specifies the information we want to retrieve about the leads. In the example below, we are interested in obtaining the fields id, fullname, email, whatsapp and mobile.

  2. search: This field allows filtering the results based on a search criterion. In the example, we are looking for a lead with the email [email protected].

API call example

Now let's see how to make this API call using Postman:

circle-info

If Search is not specified, the JSON will show all fields from the query for some leads.

Conclusion

In this article, we saw how to make an API call to retrieve leads using SprintHub. We used a specific endpoint and a JSON request body to list leads and fetch specific information. Try different search criteria to meet your specific needs.

Last updated

Was this helpful?