Using the QueueID via REST API

Follow

This article explains how LeadByte’s REST API uses a QueueID to help you check what happened to a lead after you submit it.This includes information such as: 

- Was it accepted into your campaign?

- Was it sold to a buyer?

- Which buyer was it sold to?

- Which deliveries were triggered and what was their status?


The Basics

When submitting a lead through the REST API, your request is queued.

SO you'll typically get something which looks like the below -

{
    "status": "Success",
    "code": 1,
    "message": "",
    "results": [
        {
            "queueId": "ac1e0206-6d6fd2fa-62ce91e7-ba33-5cc458e6",
            "status": "Queued",
            "code": 1
        }
    ]
}

 

If you want to find out the result of this lead, you'd need to make a 2nd request to LeadByte using the QueueID. (Make sure your REST API key has the "API queue" permission enabled)

The request you'd make -

[GET] https://{account}.leadbyte.com/restapi/v1.3/apiqueue/ac1e0206-6d6fd2fa-62ce91e7-ba33-5cc458e6?key=cb266b24ef4a5b59b722ca5801431120

 

Which would return the following response - 

31960026-98c8-43ca-aab3-b3b4cab7b0e2.png

As you can see, the Lead above is valid, and it was accepted into the campaign on 13th July 2022 at 09:35 UTC.
 


More Options

As it stands, polling the queue ID ONLY returns basic information about the lead.

However, if you head to your REST API key settings and scroll down, you should find a section API Queue

You can include any or all of the below - 

  • Info about the delivery(s) the lead was sent to
  • Info about the campaign the lead entered
  • Info about the supplier who submitted the lead
  • Info about the buyer who bought the lead
  • The lead data itself

As an example, the highlighted section below allows you to append buyer information:  

Edit REST API Key V2 2026-01-06 at 9.45.25 am.jpg

FAQs

Q: Can LeadByte automatically poll the queue and return the lead status to my supplier?

A: Yes! You'd be using our Live Buyer Responses feature, found under your Campaign settings. More on this here

 

As always, if you have any further questions please raise a support ticket.

Was this article helpful?
0 out of 0 found this helpful

Comments