Skip to content
New issue

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

Feature suggestion: reflect request #2

Open
bernd-wechner opened this issue Sep 1, 2021 · 6 comments
Open

Feature suggestion: reflect request #2

bernd-wechner opened this issue Sep 1, 2021 · 6 comments
Assignees
Labels
enhancement New feature or request

Comments

@bernd-wechner
Copy link

bernd-wechner commented Sep 1, 2021

I came across this as a testing tool. It's nice, thanks. Another testing desire I have occasionally is to run an on line webserver temporarily that just responds with a complete and reliable description of the request it received. A request mirror. To test both the construction of and transport of requests I guess. Wonder if this is a nice tool to add that to, or if another exists that I've not found.

@xnbox xnbox added the enhancement New feature or request label Sep 1, 2021
@xnbox
Copy link
Owner

xnbox commented Sep 1, 2021

A server response that completely reflects the request will be rejected by any HTTP client, because the first line of the request and response are different.
For example, the first line of the request is "GET / HTTP/1.1" and the first line of the response is "HTTP/1.1 200 OK".
Maybe add a raw request/response log option?

@bernd-wechner
Copy link
Author

I'd think it good enough to return the request as a well formatted text in a legal response (akin indeed to logging it to a text file and the serving that text file). Just a thought

@xnbox xnbox self-assigned this Sep 1, 2021
@xnbox
Copy link
Owner

xnbox commented Sep 1, 2021

Sounds interesting, I like it!
I put it on my TODO list.
Thank you!

@xnbox
Copy link
Owner

xnbox commented Sep 2, 2021

v1.0.4

  • I have added a printout of live request/response pairs to the console (can be disabled with the --no-log switch)
  • In addition, I added live query/response pairs output to a file (see option --collect)
  • The formatted query output directly in the browser - not yet implemented.

@bernd-wechner
Copy link
Author

My first night making any time for this project in many months. Sorry I haven't been back sooner. But Tonight I gave this a spin, and imagine my surprise to see you're up to v6!

No luck immediately, though. But till report in another issue as I suspect I have a noob problem,

@LeiYangGH
Copy link

isn't httpbin already satisfying these purposes?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants