We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When Content-type header is not set, mmock cannot extract keys.
Example log: { "scheme": "http", "host": "1", "port": "80", "method": "POST", "path": "/jsonrpc/v1/payments.create", "queryStringParameters": {}, "fragment": "", "headers": { "Accept-Encoding": [ "gzip" ], "Authorization": [ "Basic cWE6cWE=" ], "Cache-Control": [ "no-cache" ], "Content-Length": [ "33" ], "Cookies": [ "{}" ], "User-Agent": [ "Go-http-client/1.1" ] }, "cookies": {}, "body": "{\"id\":\"e2a69502\",\"jsonrpc\":\"2.0\"}" }
{ "scheme": "http", "host": "1", "port": "80", "method": "POST", "path": "/jsonrpc/v1/payments.create", "queryStringParameters": {}, "fragment": "", "headers": { "Accept-Encoding": [ "gzip" ], "Authorization": [ "Basic cWE6cWE=" ], "Cache-Control": [ "no-cache" ], "Content-Length": [ "33" ], "Cookies": [ "{}" ], "User-Agent": [ "Go-http-client/1.1" ] }, "cookies": {}, "body": "{\"id\":\"e2a69502\",\"jsonrpc\":\"2.0\"}" }
Mapping:
{"id": "{{request.body.id}}", "jsonrpc": "{{request.body.jsonrpc}}"}
What mmock returns: {"id": "{{request.body.id}}", "jsonrpc": "{{request.body.jsonrpc}}"}
P.S. Sorry, i got it wrong for the first time, because of escaped JSON in log
The text was updated successfully, but these errors were encountered:
Maybe create additional parameter to set default content, based on matched mapping?
Sorry, something went wrong.
No branches or pull requests
When Content-type header is not set, mmock cannot extract keys.
Example log:
{ "scheme": "http", "host": "1", "port": "80", "method": "POST", "path": "/jsonrpc/v1/payments.create", "queryStringParameters": {}, "fragment": "", "headers": { "Accept-Encoding": [ "gzip" ], "Authorization": [ "Basic cWE6cWE=" ], "Cache-Control": [ "no-cache" ], "Content-Length": [ "33" ], "Cookies": [ "{}" ], "User-Agent": [ "Go-http-client/1.1" ] }, "cookies": {}, "body": "{\"id\":\"e2a69502\",\"jsonrpc\":\"2.0\"}" }
Mapping:
{"id": "{{request.body.id}}", "jsonrpc": "{{request.body.jsonrpc}}"}
What mmock returns:
{"id": "{{request.body.id}}", "jsonrpc": "{{request.body.jsonrpc}}"}
P.S. Sorry, i got it wrong for the first time, because of escaped JSON in log
The text was updated successfully, but these errors were encountered: