Create http file test interface in pycharm

Create http file test interface in pycharm

insert image description here
Top right
insert image description here
example:

POST http://127.0.0.1:5000/books/
Content-Type: application/json

{
    
    
      "author": "余华1",
      "book_name": "活着1",
      "book_number": "003",
      "book_prize": 39.9,
      "book_publisher": "北京出版社",
      "book_type": "小说"
}

###
GET http://127.0.0.1:5000/books/
Accept: application/json

###

PUT http://127.0.0.1:5000/books/3
Content-Type: application/json

{
    
    
      "author": "余华111111",
      "book_name": "活着1",
      "book_number": "003",
      "book_prize": 39.9,
      "book_publisher": "北京出版社11111",
      "book_type": "小说"
}

###

DELETE http://127.0.0.1:5000/books/3
Accept: application/json

###

Guess you like

Origin blog.csdn.net/weixin_44747173/article/details/125982458
Recommended