You are on page 1of 6

2018. 10. 4. httpbin.

org

httpbin.org
0.9.2

[ Base URL: httpbin.org/ ]

A simple HTTP Request & Response Service.

Run locally: $ docker run -p 80:80 kennethreitz/httpbin

the developer - Website


Send email to the developer

Schemes

HTTPS

HTTP Methods Testing di erent HTTP verbs

DELETE /delete "The request's DELETE parameters.

GET /get The request's query parameters.

PATCH /patch The request's PATCH parameters.

POST /post The request's POST parameters.

PUT /put The request's PUT parameters.

Auth Auth methods

GET /basic-auth/{user}/{passwd} Prompts the user for authorization using HTTP Basic Auth.

GET /bearer "Prompts the user for authorization using bearer authentication..

"Prompts the user for authorization using Digest


GET /digest-auth/{qop}/{user}/{passwd}
Auth.

"Prompts the user for authorization


/di
https://httpbin.org/#/Anything
h/{ }/{ }/{ d}/{ l i h } 1/6
2018. 10. 4. httpbin.org
GET /digest-auth/{qop}/{user}/{passwd}/{algorithm}
using Digest Auth + Algorithm.

"Prompts the user for


authorization using
GET /digest-auth/{qop}/{user}/{passwd}/{algorithm}/{stale_after}
Digest Auth +
Algorithm.

"Prompts the user for authorization using HTTP Basic


GET /hidden-basic-auth/{user}/{passwd}
Auth.

Status codes Generates responses with given status code

DELETE /status/{codes} Return status code or random status code if more than one are given

GET /status/{codes} Return status code or random status code if more than one are given

PATCH /status/{codes} Return status code or random status code if more than one are given

POST /status/{codes} Return status code or random status code if more than one are given

PUT /status/{codes} Return status code or random status code if more than one are given

Request inspection Inspect the request data

GET /headers Return the incoming request's HTTP headers.

GET /ip Returns the requester's IP Address.

GET /user-agent Return the incoming requests's User-Agent header.

Response inspection Inspect the response data like caching and headers

Returns a 304 if an If-Modi ed-Since header or If-None-Match is present. Returns the


GET /cache
same as a GET otherwise.

GET /cache/{value} Sets a Cache-Control header for n seconds.

Assumes the resource has the given etag and responds to If-None-Match and
GET /etag/{etag}
If-Match headers appropriately.

https://httpbin.org/#/Anything 2/6
2018. 10. 4. httpbin.org

GET /response-headers Returns a set of response headers from the query string.

POST /response-headers Returns a set of response headers from the query string.

Response formats Returns responses in di erent data formats

GET /brotli "Returns Brotli-encoded data.

GET /deflate "Returns De ate-encoded data.

GET /deny Returns page denied by robots.txt rules.

GET /encoding/utf8 Returns a UTF-8 encoded body.

GET /gzip Returns GZip-encoded data.

GET /html Returns a simple HTML document.

GET /json Returns a simple JSON document.

GET /robots.txt Returns some robots.txt rules.

GET /xml Returns a simple XML document.

Dynamic data Generates random and dynamic data

GET /base64/{value} "Decodes base64url-encoded string.

GET /bytes/{n} Returns n random bytes generated with given seed

DELETE /delay/{delay} "Returns a delayed response (max of 10 seconds).

GET /delay/{delay} "Returns a delayed response (max of 10 seconds).

https://httpbin.org/#/Anything 3/6
2018. 10. 4. httpbin.org

PATCH /delay/{delay} "Returns a delayed response (max of 10 seconds).

POST /delay/{delay} "Returns a delayed response (max of 10 seconds).

PUT /delay/{delay} "Returns a delayed response (max of 10 seconds).

GET /drip Drips data over a duration after an optional initial delay.

GET /links/{n}/{offset} Generate a page containing n links to other pages which do the same.

Streams n random bytes generated with given seed, at given chunk size
GET /range/{numbytes}
per packet.

Streams n random bytes generated with given seed, at given chunk size
GET /stream-bytes/{n}
per packet.

GET /stream/{n} Stream n JSON responses

GET /uuid Return a UUID4.

Cookies Creates, reads and deletes Cookies

GET /cookies Returns cookie data.

GET /cookies/delete Deletes cookie(s) as provided by the query string and redirects to cookie list.

GET /cookies/set Sets cookie(s) as provided by the query string and redirects to cookie list.

GET /cookies/set/{name}/{value} Sets a cookie and redirects to cookie list.

Images Returns di erent image formats

GET /image Returns a simple image of the type suggest by the Accept header.

GET /image/jpeg Returns a simple JPEG image.

https://httpbin.org/#/Anything 4/6
2018. 10. 4. httpbin.org

GET /image/png Returns a simple PNG image.

GET /image/svg Returns a simple SVG image.

GET /image/webp Returns a simple WEBP image.

Redirects Returns di erent redirect responses

GET /absolute-redirect/{n} Absolutely 302 Redirects n times.

DELETE /redirect-to 302/3XX Redirects to the given URL.

GET /redirect-to 302/3XX Redirects to the given URL.

PATCH /redirect-to 302/3XX Redirects to the given URL.

POST /redirect-to 302/3XX Redirects to the given URL.

PUT /redirect-to 302/3XX Redirects to the given URL.

GET /redirect/{n} 302 Redirects n times.

GET /relative-redirect/{n} Relatively 302 Redirects n times.

Anything Returns anything that is passed to request

DELETE /anything Returns anything passed in request data.

GET /anything Returns anything passed in request data.

PATCH /anything Returns anything passed in request data.

POST /anything Returns anything passed in request data.

PUT /anything Returns anything passed in request data.


https://httpbin.org/#/Anything 5/6
2018. 10. 4. httpbin.org

DELETE /anything/{anything} Returns anything passed in request data.

GET /anything/{anything} Returns anything passed in request data.

PATCH /anything/{anything} Returns anything passed in request data.

POST /anything/{anything} Returns anything passed in request data.

PUT /anything/{anything} Returns anything passed in request data.

[Powered by Flasgger]
Other Utilities
HTML form that posts to /post /forms/post

https://httpbin.org/#/Anything 6/6

You might also like