官术网_书友最值得收藏!

POST

The POST method is used to create a new resource in a collection or to execute a controller. It is typically a non-idempotent action, in that multiple posts to create an element in a collection that will create multiple elements not updated after the first call.

The POST method is always used when calling controllers as the actions of this is considered non-idempotent.

Request:

POST /v1/cats HTTP/1.1 
Content-Type: application/json
Content-Length: xxxx

{"name": "Felix", "weight": 5}

Response:

HTTP/1.1 201 Created 
Content-Type: application/json
Content-Length: 0
Location: /v1/cats/12343
主站蜘蛛池模板: 聂荣县| 浠水县| 芒康县| 曲松县| 广丰县| 横山县| 习水县| 呼和浩特市| 武城县| 雷波县| 永德县| 龙海市| 广水市| 湖北省| 鄂温| 巴塘县| 新营市| 泰和县| 全州县| 新兴县| 海南省| 三亚市| 永平县| 元阳县| 邻水| 澄迈县| 临颍县| 肃宁县| 洛川县| 蓬安县| 杭锦后旗| 精河县| 河源市| 扎兰屯市| 名山县| 鄂伦春自治旗| 广平县| 哈密市| 阳山县| 缙云县| 临夏县|