svix.endpoint.get will throw an error when no endpoint is found #2133
Unanswered
jackmu-paragon
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I have a use case where I want to create an endpoint if it doesn't exist
The
svix.endpoint.getwill throw a 404 error, which I understand is part of the underlying API, but it seems weird to wrap it in a try catch. I want to differentiate an "actual error" with a not found response which is an expected behavior.Is try catch the best option, or is there a better way to implement this logic?
Beta Was this translation helpful? Give feedback.
All reactions