Giter Site home page Giter Site logo

postman-demo-server's Introduction

PostmanBin

Demo server for testing / demonstrating Postman. Postman collection with the api endpoints can be downloaded here.

Build Steps

Make sure you have sqlite installed.

$ git clone https://github.com/prakhar1989/Postman-demo-server.git 
$ virtualenv venv 
$ source venv/bin/activate
$ pip install -r requirements.txt
$ python setup.py # sets up the database
$ python app.py 
 * Running on http://127.0.0.1:5000/
 * Restarting with reloader

To deploy a flask app I have a blogpost written here which you can follow.

Endpoints

Method Endpoint Description
1 GET {{url}}/blog/posts Return all blog posts
2 DELETE {{url}}/blog/posts/{{id}} Delete the existing blog post
3 GET {{url}} Returns a JSON with all the available API endpoints.
4 GET {{url}}/blog/users/{{user_id}} Get user details for a user
5 GET {{url}}/blog/posts/{{id}} Return blog post with that ID
6 POST {{url}}/blog/users/ Create a new user with the given username and password.
7 POST {{url}}/blog/posts Create a new blog post
8 GET {{url}}/cookies/delete?name Similar to httpbin.org/cookies. Delete a cookie.
9 GET {{url}}/delay/10 Return response after a few seconds
10 POST {{url}}/post Similar to httpbin.org/post. Return POST data.
11 POST {{url}}/blog/users/tokens/ POST on this endpoint will create a new token provided the username and password is correct. The returned token will be used to make subsequent requests.
12 GET {{url}}/cookies Similar to httpbin.org/cookies. Return cookies set in the domain.
13 DELETE {{url}}/blog/users/tokens/{{token_id}} Delete the token. Effectively signing out the user.
14 GET {{url}}/get Similar to httpbin.org/get. Return GET data.
15 GET {{url}}/headers Similar to httpbin.org/headers. Return all the headers passed to it.
16 GET {{url}}/cookies/set?name=value Similar to httpbin.org/cookies. Set a cookie
17 PUT {{url}}/blog/posts/{{id}} Modify the existing post
18 GET {{url}}/blog/users/ Get all current users of the blog.
19 GET {{url}}/status Return the status of the API with the timestamp.

Thanks

HTTPBIN for inspiration

postman-demo-server's People

Contributors

abhijitkane avatar prakhar1989 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.