Skip to content

Your first request

Click Open Workspace on the Welcome screen (or press ⌘⇧O) and pick any folder on your machine — even an empty one.

Right-click in the file tree → New File. Name it requests.http.

### Get a joke
GET https://official-joke-api.appspot.com/random_joke

The ### line is the request name (optional but useful). The next line is the method and URL.

Click the gutter button on the method line, or press ⌘Enter with your cursor anywhere in the request block.

The Results Panel shows:

  • Status code and response time
  • Response headers
  • Response body — JSON is automatically pretty-printed
### Create a post
POST https://jsonplaceholder.typicode.com/posts
Content-Type: application/json
{
"title": "Hello",
"body": "My first post",
"userId": 1
}

Leave one blank line between the last header and the body. That’s the separator.

@baseUrl = https://jsonplaceholder.typicode.com
### List posts
GET {{baseUrl}}/posts
### Get post 1
GET {{baseUrl}}/posts/1
### Create post
POST {{baseUrl}}/posts
Content-Type: application/json
{ "title": "Hello", "userId": 1 }

Define @key = value before the first ###. Reference with {{key}} anywhere in the file.

KeyAction
⌘EnterRun request under cursor
⌘⇧EnterRun all requests in the file
⌘/Toggle line comment
TabAccept autocomplete suggestion