Unable to search data entires using data from API call

I have an API Call, which I’m using in an API WOrkflow

I believe is working perfectly. When run, I can see the data from the API call, and as part of my workflow actions, include the requested data in an email.

It seems, however, that cannot pass data from the API call to update a data entry OR do a search for a database entry using data from the API call as a constraint.

Has anyone had the same problem?

If you can share your editor, its much easier to look at.

Hi Vincent,

Unfortunately cannot share the editor at this time however I can share screenshots. Better yet, we can do a quick appear.in call whenever its convenient for you.

I’m on WAT (UTC+1)

Here are snapshops of the API workflow:

This is a pic of Step 3 (which doesn’t work)

Same goes for Step 4 and 5
… And this is a pic of Step 6 (an email) which works with all the data included

It looks like the thing you’re modifying in Step 2 is based off the unique id constraint, but you’re saying the unique ID of the Offer should = “tx_ref” from your API call. Is this accurate? Would that tx_ref be saved previously with the Offer unique id?

You should also check on your privacy rules on the Offer type and check your authentication/privacy settings on the API Endpoint (Data > Privacy > Offer). It might be that the endpoint isn’t authorized to search Offers.

Hi Gabby
Thanks for responsing.

The API is for a payment processor (here in Nigeria) and I passed on the unique ID of my ‘Offer’ thing into as the tx_ref field. So yes this is accurate.

Regarding the privacy roles (Data > Privacy > Offer), I don’t have anything defined, meaning it is visible by everyone.

In Settings > API, do I need to select things as to expose their Data API?

Hi Debbie,
Hope you had a good weekend.

I tried what you suggested but made no head way. Like I mentioned in my last post. the tx-ref has been saved with the unique ID of the Offer type. so that part is correct. You can see below a copy of the email that I generate for the API cal which has the info included

image

Regarding the privacy settings, I did try to create settings for that but still it didn’t work. Not sure what else to do at this point. Below are the two ways I tried to define the roles:

  1. limited to current user

  2. no filter

Hello All,

Don’t know if anyone else has any pointers. I’ve tried almost every iteration I can think of to configure the API settings (exposing data types) as well as Data privacy settings in order to modify data types, and still I have no luck.

Can someone explain to me know how the " Use field display instead of ID for key names" checkbox can affect how data is exposed?

Also when is it necessary to set the roles? if the information needed is from data from an API, is that considered to be using a token with administrative access?

#pleaseHelp #deeplyTroubled

Hi @tomi.adegbenro,

To be sure that this is nothing to do with privacy settings, you should tick the ignore privacy settings checkbox on your endpoint.

Also, to be clear, what I think Gaby was asking earlier was whether or not you had previously sent the offer’s unique id to RavePay as the tx_ref. It would be good to see a screenshot of the debugger showing that the tx_ref returned by the API call is indeed the same as the unique id of the offer found by the search.

One other thing to try, when you create the offer, could you set its txRef to its unique id then. Then for your search, instead of testing the returned tx_ref from the API call against the unique_id, you could test it against txRef. This is just in case Bubble is protective of unique_ids in some way.

Finally, even though I don’t think it matters too much, it is a little odd that you’re sorting the Offers search by modified date. There should be only one item with that unique id anyway, so no sort should be required.

Hope you get it sorted.

Hi Louis

Thanks for reaching out! I actually figured it all out and it was in part issues with configuration of my payment process account

I thought I answered the question…and Yes, that what I did. I passed the Offer’s unique ID as my tx_ref and the Job’s unique ID as well.

You are right, I do that as a catch all as part of my debugging process. Force of habit.

How has your experience with Bubble been so far?

Hi @tomi.adegbenro,

Glad you figured it out. Bubble is great! Having tried lots of other no/low-code platforms in the past, I can confidently say Bubble is the most robust. It’s not without its quirks of course but it largely works - for my needs anyway.

All the best with your application.

Louis