Support for handling all live requests?
I'm using a single yaml file and Stubby to handle all live requests to an api. Is there any support for Stubby to use a single file to dynamically handle all live requests, as such?
- request:
url: ^/.+
method: [GET, POST]
response:
status: 302
headers:
Location: https://liveEndpoint.com<% url[0] %>
As of right now, all requests going through Stubby are GETs despite the client app sending out GETs and POSTs.
You should be able to use a wildcard url; it is just a regex match.
I have no problems with the urls, the regex match just fine. My problem is the request methods don't act dynamically. I list out GET and POST in the method field. My client will send GETs, which Stubby intercepts and acts in an expected manner. The client will subsequently send a POST, only for Stubby to intercept and send a GET.