mirror of
https://github.com/morten-olsen/http.md.git
synced 2026-02-08 00:46:28 +01:00
17 lines
367 B
Markdown
17 lines
367 B
Markdown
```http id=createItem json
|
|
POST https://httpbin.org/post
|
|
Content-Type: application/json
|
|
|
|
{"name": "My New Item"}
|
|
```
|
|
|
|
The new item ID is: {{responses.createItem.body.json.name}}
|
|
|
|
Now, let's fetch the item using a (mocked) ID from the response:
|
|
|
|
```http id=fetchItem
|
|
GET https://httpbin.org/anything/{{responses.createItem.body.json.name}}
|
|
```
|
|
|
|
::response{#fetchItem}
|