Skip to content

Instantly share code, notes, and snippets.

@alyson-b69
Created September 7, 2020 07:00
Show Gist options
  • Save alyson-b69/bf5c55bee352f4c0bbc4bc43b4a93faf to your computer and use it in GitHub Desktop.
Save alyson-b69/bf5c55bee352f4c0bbc4bc43b4a93faf to your computer and use it in GitHub Desktop.
Requests http AB
### GET wilders with the API
GET https://http-practice.herokuapp.com/wilders
### GET wilders on JavaScript with the API
GET https://http-practice.herokuapp.com/wilders?language=JavaScript
### GET wilders on JavaScript with the API & a big number
GET https://http-practice.herokuapp.com/wilders?language=JavaScript&page=100000
### POST au format URL-encoded
POST https://http-practice.herokuapp.com/wilders
Content-Type: application/x-www-form-urlencoded
name=John%20Doe&language=C%23
### POST au format json
POST https://http-practice.herokuapp.com/wilders
Content-Type: application/json
{
"name" : "Alyson Bernabeu",
"language" : "JavaScript"
}
### GET my wilder to see him
GET https://http-practice.herokuapp.com/wilders/2747
### PUT my wilder to update him
PUT https://http-practice.herokuapp.com/wilders/2747
Content-Type: application/json
{
"name" : "Alyson B",
"language" : "JavaScript"
}
### DELETE my wilder
DELETE https://http-practice.herokuapp.com/wilders/2747
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment