How do we catch exception?
Options
![Joe Thong](https://us.v-cdn.net/6037124/user_avatars/1398509.jpg)
Joe Thong
Member ✭
We are using the Stripe API, when duplicate products are inserted, an exception will be thrown by the Stripe API. We need to catch it and continue the script, instead of breaking it.
On a sidenote, how do we export database or backup?
Thanks
Joe
On a sidenote, how do we export database or backup?
Thanks
Joe
Comments
-
You can add a Precondition(s) in regard to the response from the Stripe API call on whatever is important. This often times can be simply checking the status code:
[Screenshot_2021-08-11_17-53-51.png]
You can use dot notation on the variable to parse to the status or whichever field is important.
The Precondition will be to enforce that something is true. If you don't need to do that but do logic on way or the other depending on what is returned then you can use a Conditional (If...Then...Else) -
oh thanks michael, let me try to use this approach
Categories
- All Categories
- 53 ? Announcements
- 47 ? Releases
- 37 ? Welcome
- 983 ? Help! I'm a Noob
- 125 ? No-Code Front-Ends
- 633 ? Working with APIs
- 439 ? Transforming data
- 126 ? Connect Xano to ...
- 50 ?? Find an Expert
- 348 ❓Other questions
- 35 ? Security
- 22 ✂️ Snippets
- 19 ? Showcase
- 7 ?️ Xano Chatter
- 62 ? Video Tutorials
- 171 ? Request a feature
- 229 ? Report a Bug
- 19 ? Templates & Extensions
- 7 ? Feedback