moto
moto copied to clipboard
EventBridge API Destinations
A few weeks ago AWS announced the new API Destinations functionality for EventBridge and I'm eager to try it out and implement it into moto
directly, but I need some guidance on triggering the API endpoint. Should I implement it with the requests
lib and really invoke that API endpoint, so the person who will use it can intercept the call with responses
?
@bblommers do you have any opinion on it? Or is it a stupid idea to even implement it into moto
at all?
Should I implement it with the
requests
lib and really invoke that API endpoint, so the person who will use it can intercept the call withresponses
?
Hey @gruebel, that sounds like a good idea. Probably the only way people can verify the connection details are correct.
For a mocking library, it might not be intuitive that an actual request is made though. Maybe we can lock it behind a setting that defaults to False, and the requests only go through when the developer explicitly turns this feature on.
Yeah, that sounds good. Would it be a separate decorator or change the actual @mock_events
decorator to be able to handle a parameter? Or do you have something completely different in mind?
I was thinking an environment variable (in settings.py) - that's the best way to ensure it also works in server mode.