• Resolved scottishdev

    (@scottishdev)


    Hello everyone,

    I’m trying to use the JetpackCRM API to search contacts based on their phone number.

    at this point I’m just testing with the program Insomnia.

    So I’ve followed the documentation and have a get url that looks like this:

    https://my-site.co.uk/zbs_api/customer_search?zbs_query=012345123123?api_key={API_KEY}&api_secret={API_SECRET}

    The number after the zbs_query is the customers telephone number and I’m hoping to use it to return the rest of the customers details, address etc.

    I have been able to get successful responses to other queries, but I can’t seem to get the search functionality to work, all I ever get as a response is 403 – Forbidden.

    There’s no examples of how the search query data should be structured to work from so I can only expect I’m formatting it wrong?

    If anyone could shed some light on this, that would be much appreciated.

Viewing 1 replies (of 1 total)
  • Plugin Author bradshawtm

    (@bradshawtm)

    Hello! At a glance it seems like your search is correct; I’ve tested now on my end with the following:

    /zbs_api/customer_search/?api_key={{key_here}}&api_secret={{secret_here}}&zbs_query=555-5555

    Note that when searching for a phone number, we strip out common punctuation and whitespace, so that shouldn’t be an issue either.

    If you use POST instead of GET, you’d receive a 405 Method not allowed error, but as long as the key and secret are correct (and not flipped)` you shouldn’t be getting a 403.

    Can you double-check the above and also try disabling all other plugins to see if there’s a conflict?

Viewing 1 replies (of 1 total)

The topic ‘Search via API’ is closed to new replies.