This commit is contained in:
Karel De Smet
2020-12-22 08:02:03 +01:00
5 changed files with 207 additions and 73 deletions

View File

@@ -24,24 +24,6 @@
"code"
]
},
{
"login": "NBTX",
"name": "John Harker",
"avatar_url": "https://avatars3.githubusercontent.com/u/43181178?v=4",
"profile": "https://github.com/NBTX",
"contributions": [
"code"
]
},
{
"login": "jamesgeorge007",
"name": "James George",
"avatar_url": "https://avatars2.githubusercontent.com/u/25279263?v=4",
"profile": "https://ghuser.io/jamesgeorge007",
"contributions": [
"code"
]
}
],
"contributorsPerLine": 7,
"projectName": "hoppscotch",

193
README.md
View File

@@ -10,7 +10,7 @@
</p>
<p>
[![Website](https://img.shields.io/website?url=https%3A%2F%2Fhoppscotch.io&logo=postwoman)](https://hoppscotch.io) [![Travis Build Status](https://img.shields.io/travis/com/hoppscotch/hoppscotch/main?logo=Travis)](https://travis-ci.com/hoppscotch/hoppscotch) [![GitHub release](https://img.shields.io/github/release/hoppscotch/hoppscotch/all?logo=GitHub)](https://github.com/hoppscotch/hoppscotch/releases/latest) [![Tweet](https://img.shields.io/twitter/url?url=https%3A%2F%2Fhoppscotch.io%2F)](https://twitter.com/intent/tweet?url=https%3A%2F%2Fhoppscotch.io&text=%F0%9F%91%BD%20hoppscotch%20%E2%80%A2%20API%20request%20builder%20-%20Helps%20you%20create%20your%20requests%20faster%2C%20saving%20you%20precious%20time%20on%20your%20development&original_referer=https%3A%2F%2Ftwitter.com%2Fshare%3Ftext%3D%25F0%259F%2591%25BD%2520hoppscotch%2520%25E2%2580%25A2%2520API%2520request%2520builder%2520-%2520Helps%2520you%2520create%2520your%2520requests%2520faster%2C%2520saving%2520you%2520precious%2520time%2520on%2520your%2520development%26url%3Dhttps%3A%2F%2Fhoppscotch.io%26hashtags%3Dhoppscotch%26via%3Dliyasthomas&via=liyasthomas&hashtags=hoppscotch)
[![Website](https://img.shields.io/website?url=https%3A%2F%2Fhoppscotch.io&logo=hoppscotch)](https://hoppscotch.io) [![Travis Build Status](https://img.shields.io/travis/com/hoppscotch/hoppscotch/main?logo=Travis)](https://travis-ci.com/hoppscotch/hoppscotch) [![GitHub release](https://img.shields.io/github/release/hoppscotch/hoppscotch/all?logo=GitHub)](https://github.com/hoppscotch/hoppscotch/releases/latest) [![Tweet](https://img.shields.io/twitter/url?url=https%3A%2F%2Fhoppscotch.io%2F)](https://twitter.com/intent/tweet?url=https%3A%2F%2Fhoppscotch.io&text=%F0%9F%91%BD%20hoppscotch%20%E2%80%A2%20API%20request%20builder%20-%20Helps%20you%20create%20your%20requests%20faster%2C%20saving%20you%20precious%20time%20on%20your%20development&original_referer=https%3A%2F%2Ftwitter.com%2Fshare%3Ftext%3D%25F0%259F%2591%25BD%2520hoppscotch%2520%25E2%2580%25A2%2520API%2520request%2520builder%2520-%2520Helps%2520you%2520create%2520your%2520requests%2520faster%2C%2520saving%2520you%2520precious%2520time%2520on%2520your%2520development%26url%3Dhttps%3A%2F%2Fhoppscotch.io%26hashtags%3Dhoppscotch%26via%3Dliyasthomas&via=liyasthomas&hashtags=hoppscotch)
</p>
<p>
@@ -34,7 +34,7 @@
[![Sponsor on GitHub](https://img.shields.io/badge/sponsor-GitHub-181717?logo=github)](https://github.com/sponsors/hoppscotch) [![Contribute on Open Collective](https://img.shields.io/badge/contribute-Open%20Collective-7FADF2?logo=open-collective)](https://opencollective.com/hoppscotch) [![Join on Patreon](https://img.shields.io/badge/join-Patreon-F96854?logo=patreon)](https://www.patreon.com/liyasthomas) [![Donate on PayPal](https://img.shields.io/badge/donate-PayPal-00457C?logo=paypal)](https://www.paypal.me/liyascthomas)
<details>
<summary>Table of contents</summary>
<summary><i><ins>Table of contents</ins></i></summary>
---
@@ -75,7 +75,10 @@
⚡️ **Fast:** Send requests and get/copy responses in real-time.
**Methods**
<details>
<summary><i><ins>HTTP Methods</ins></i></summary>
---
- `GET` - Requests retrieve resource information
- `HEAD` - Retrieve response headers identical to those of a GET request, but without the response body.
@@ -88,20 +91,34 @@
- `PATCH` - Very similar to `PUT` but makes a partial update on a resource
- `<custom>` - Some APIs use custom request methods such as `LIST`. Type in your custom methods.
🌈 **Make it yours:** Customizable combinations for background, foreground and accent colors.
---
**Theming:** [Customize now ✨](https://hoppscotch.io/settings)
</details>
🌈 **Make it yours:** Customizable combinations for background, foreground and accent colors. [Customize now ✨](https://hoppscotch.io/settings)
<details>
<summary><i><ins>Theming</ins></i></summary>
---
- Choose theme: System, Light, Dark (default) and Black
- Choose accent color: Blue, Green (default), Teal, Purple, Orange, Pink, Red, and Yellow
- Toggle multi-colored headings
- Toggle auto-scroll to response
---
</details>
_Customized themes are synced with local session storage_
🔥 **PWA:** Install as a [PWA](https://developers.google.com/web/progressive-web-apps) on your device.
**Features**
<details>
<summary><i><ins>Features</ins></i></summary>
---
- Instant loading with Service Workers
- Offline support
@@ -109,23 +126,31 @@ _Customized themes are synced with local session storage_
- Add to Home Screen
- Desktop PWA
---
</details>
🚀 **Request:** Retrieve response from endpoint instantly.
- Choose `method`
- Enter `URL`
- Send
**Features**
<details>
<summary><i><ins>Features</ins></i></summary>
---
- Copy/share public "Share URL"
- Generate/copy request code snippets for 10+ languages and frameworks
- Import `cURL`
- Label requests
🔌 **WebSocket:** Establish full-duplex communication channels over a single TCP connection.
---
- Send and receive data
- Basic and Bearer Token authentication
</details>
🔌 **WebSocket:** Establish full-duplex communication channels over a single TCP connection.
📡 **Server Sent Events:** Receive a stream of updates from a server over a HTTP connection without resorting to polling.
@@ -135,15 +160,27 @@ _Customized themes are synced with local session storage_
🔮 **GraphQL:** GraphQL is a query language for APIs and a runtime for fulfilling those queries with your existing data.
<details>
<summary><i><ins>Features</ins></i></summary>
---
- Set endpoint and get schemas
- Multi-column docs
- Set custom request headers
- Query schema
- Get query response
---
</details>
🔐 **Authentication:** Allows to identify the end user.
**Types**
<details>
<summary><i><ins>Types</ins></i></summary>
---
- None
- Basic
@@ -151,66 +188,131 @@ _Customized themes are synced with local session storage_
- OAuth 2.0
- OIDC Access Token/PKCE
---
</details>
📢 **Headers:** Describes the format the body of your request is being sent as.
📫 **Parameters:** Use request parameters to set varying parts in simulated requests.
📃 **Request Body:** Used to send and receive data via the REST API.
**Options**
<details>
<summary><i><ins>Options</ins></i></summary>
---
- Set `Content Type`
- Add or remove Parameter list
- Toggle between key-value and RAW input parameter list
👋 **Responses:** Contains the status line, headers and the message/response body.
---
</details>
👋 **Response:** Contains the status line, headers and the message/response body.
<details>
<summary><i><ins>Features</ins></i></summary>
---
- Copy response to clipboard
- Download response as a file
- View preview of HTML responses
- View response headers
- View raw and preview of HTML, image, JSON, XML responses
---
</details>
**History:** Request entries are synced with cloud / local session storage to restore with a single click.
📁 **Collections:** Keep your API requests organized with collections and folders. Reuse them with a single click.
<details>
<summary><i><ins>Features</ins></i></summary>
---
- Unlimited collections, folders and requests
- Nested folders
- Export as / import from GitHub gist
---
</details>
_Collections are synced with cloud / local session storage_
🌐 **Proxy:** Enable Proxy Mode from Settings to access blocked APIs.
**Features**
<details>
<summary><i><ins>Features</ins></i></summary>
---
- Hide your IP address
- Fixes [`CORS`](https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS) (Cross Origin Resource Sharing) issues
- Access APIs served in non-HTTPS (`http://`)
- Use custom Proxy URL
---
</details>
_Official Hoppscotch Proxy is hosted by Apollo Software - **[Privacy Policy](https://apollosoftware.xyz/legal/postwoman)**_
📜 **Pre-Request Scripts β:** Snippets of code associated with a request that are executed before the request is sent.
**Use-cases**
<details>
<summary><i><ins>Use-cases</ins></i></summary>
---
- Initialize environment variables
- Include timestamp in the request headers
- Send a random alphanumeric string in the URL parameters
---
</details>
📄 **API Documentation:** Create and share dynamic API documentation easily, quickly.
**Usage**
<details>
<summary><i><ins>Usage</ins></i></summary>
---
1. Add your requests to Collections and Folders
2. Export Collections and easily share your APIs with the rest of your team
3. Import Collections and Generate Documentation on-the-go
---
</details>
⌨️ **Keyboard Shortcuts:** Optimized for efficiency.
> **[Shortcuts WIki](https://github.com/hoppscotch/hoppscotch/wiki/Shortcuts)**
🌎 **i18n β:** Experience the app in your own language.
<details>
<summary><i><ins>Usage</ins></i></summary>
---
1. Scroll down to the footer
2. Click "Choose Language" icon button
3. Select your language from the menu
---
</details>
_Keep in mind: Translations aren't available for all source and target language combinations_
**To provide a localized experience for users around the world, you can add you own translations.**
@@ -245,24 +347,51 @@ _Add-ons are developed and maintained under **[Official Hoppscotch Organization]
**Post-Request Tests β:** Write tests associated with a request that are executed after the request response.
**Use-cases**
<details>
<summary><i><ins>Use-cases</ins></i></summary>
---
- Check the status code as an integer
- Filter response headers
- Parse the response data
---
</details>
📝 **Notes** : Instantly jot down notes, tasks or whatever you feel like as they come to your mind.
_Notes are only available for signed-in users_
🌱 **Environments** : Environment variables allow you to store and reuse values in your requests and scripts.
**Use-cases**
<details>
<summary><i><ins>Features</ins></i></summary>
---
- Unlimited environments and variables
- Initialize through pre-request script
- Export as / import from GitHub gist
---
</details>
<details>
<summary><i><ins>Use-cases</ins></i></summary>
---
- By storing a value in a variable, you can reference it throughout your request section
- If you need to update the value, you only have to change it in one place
- Using variables increases your ability to work efficiently and minimizes the likelihood of error
---
</details>
**To find out more, please check out [Hoppscotch Wiki](https://github.com/hoppscotch/hoppscotch/wiki).**
## **Demo**
@@ -321,7 +450,7 @@ docker run -p 3000:3000 hoppscotch:latest
```
<details>
<summary>Legacy Container</summary>
<summary><i><ins>Legacy container</ins></i></summary>
---
@@ -370,9 +499,7 @@ See the [`CHANGELOG`](CHANGELOG.md) file for details.
### Lead Developers
- **[Liyas Thomas](https://github.com/liyasthomas)** - _Author_
- **[John Harker](https://github.com/NBTX)** - _Lead developer_
- **[Andrew Bastin](https://github.com/andrewbastin)** - _Lead developer_
- **[James George](https://github.com/jamesgeorge007)** - _Lead maintainer_
- **[Caneco](https://twitter.com/caneco)** - _Logo and banner designer_
### Testing and Debugging
@@ -390,8 +517,6 @@ See the [`CHANGELOG`](CHANGELOG.md) file for details.
<tr>
<td align="center"><a href="https://liyasthomas.web.app"><img src="https://avatars1.githubusercontent.com/u/10395817?v=4" width="100px;" alt=""/><br /><sub><b>Liyas Thomas</b></sub></a><br /><a href="https://github.com/liyasthomas/hoppscotch/commits?author=liyasthomas" title="Code">💻</a> <a href="#design-liyasthomas" title="Design">🎨</a></td>
<td align="center"><a href="https://github.com/AndrewBastin"><img src="https://avatars2.githubusercontent.com/u/9131943?v=4" width="100px;" alt=""/><br /><sub><b>Andrew Bastin</b></sub></a><br /><a href="https://github.com/liyasthomas/hoppscotch/commits?author=AndrewBastin" title="Code">💻</a></td>
<td align="center"><a href="https://github.com/NBTX"><img src="https://avatars3.githubusercontent.com/u/43181178?v=4" width="100px;" alt=""/><br /><sub><b>John Harker</b></sub></a><br /><a href="https://github.com/liyasthomas/hoppscotch/commits?author=NBTX" title="Code">💻</a></td>
<td align="center"><a href="https://ghuser.io/jamesgeorge007"><img src="https://avatars2.githubusercontent.com/u/25279263?v=4" width="100px;" alt=""/><br /><sub><b>James George</b></sub></a><br /><a href="https://github.com/liyasthomas/hoppscotch/commits?author=jamesgeorge007" title="Code">💻</a></td>
</tr>
</table>
@@ -582,7 +707,7 @@ This project is licensed under the [MIT License](https://opensource.org/licenses
<td align="center" width="200px">
<a href="https://hoppscotch.io">
<br/>
<img src="https://img.shields.io/badge/Tested_on-Hoppscotch-202124?logo=postwoman"/>
<img src="https://img.shields.io/badge/Tested_on-Hoppscotch-202124?logo=hoppscotch"/>
</a>
<br/>
<sub>
@@ -590,14 +715,14 @@ This project is licensed under the [MIT License](https://opensource.org/licenses
</sub>
</td>
<td>
<code>[![hoppscotch](https://img.shields.io/badge/Tested_on-Hoppscotch-202124?logo=postwoman)](https://hoppscotch.io)</code>
<code>[![hoppscotch](https://img.shields.io/badge/Tested_on-Hoppscotch-202124?logo=hoppscotch)](https://hoppscotch.io)</code>
</td>
</tr>
<tr>
<td align="center" width="200px">
<a href="https://hoppscotch.io">
<br/>
<img src="https://img.shields.io/badge/Tested_on-Hoppscotch-success?logo=postwoman"/>
<img src="https://img.shields.io/badge/Tested_on-Hoppscotch-success?logo=hoppscotch"/>
</a>
<br/>
<sub>
@@ -605,14 +730,14 @@ This project is licensed under the [MIT License](https://opensource.org/licenses
</sub>
</td>
<td>
<code>[![hoppscotch](https://img.shields.io/badge/Tested_on-Hoppscotch-success?logo=postwoman)](https://hoppscotch.io)</code>
<code>[![hoppscotch](https://img.shields.io/badge/Tested_on-Hoppscotch-success?logo=hoppscotch)](https://hoppscotch.io)</code>
</td>
</tr>
<tr>
<td align="center" width="200px">
<a href="https://hoppscotch.io">
<br/>
<img src="https://img.shields.io/badge/Tested_on-Hoppscotch-critical?logo=postwoman"/>
<img src="https://img.shields.io/badge/Tested_on-Hoppscotch-critical?logo=hoppscotch"/>
</a>
<br/>
<sub>
@@ -620,14 +745,14 @@ This project is licensed under the [MIT License](https://opensource.org/licenses
</sub>
</td>
<td>
<code>[![hoppscotch](https://img.shields.io/badge/Tested_on-Hoppscotch-critical?logo=postwoman)](https://hoppscotch.io)</code>
<code>[![hoppscotch](https://img.shields.io/badge/Tested_on-Hoppscotch-critical?logo=hoppscotch)](https://hoppscotch.io)</code>
</td>
</tr>
<tr>
<td align="center" width="200px">
<a href="https://hoppscotch.io">
<br/>
<img src="https://img.shields.io/badge/Tested_on-Hoppscotch-blueviolet?logo=postwoman"/>
<img src="https://img.shields.io/badge/Tested_on-Hoppscotch-blueviolet?logo=hoppscotch"/>
</a>
<br/>
<sub>
@@ -635,14 +760,14 @@ This project is licensed under the [MIT License](https://opensource.org/licenses
</sub>
</td>
<td>
<code>[![hoppscotch](https://img.shields.io/badge/Tested_on-Hoppscotch-blueviolet?logo=postwoman)](https://hoppscotch.io)</code>
<code>[![hoppscotch](https://img.shields.io/badge/Tested_on-Hoppscotch-blueviolet?logo=hoppscotch)](https://hoppscotch.io)</code>
</td>
</tr>
<tr>
<td align="center" width="200px">
<a href="https://hoppscotch.io">
<br/>
<img src="https://img.shields.io/badge/your_text-Hoppscotch-hex_color_code?logo=postwoman"/>
<img src="https://img.shields.io/badge/your_text-Hoppscotch-hex_color_code?logo=hoppscotch"/>
</a>
<br/>
<sub>
@@ -650,7 +775,7 @@ This project is licensed under the [MIT License](https://opensource.org/licenses
</sub>
</td>
<td>
<code>[![hoppscotch](https://img.shields.io/badge/your_text-Hoppscotch-hex_color_code?logo=postwoman)](https://hoppscotch.io)</code>
<code>[![hoppscotch](https://img.shields.io/badge/your_text-Hoppscotch-hex_color_code?logo=hoppscotch)](https://hoppscotch.io)</code>
</td>
</tr>
</tbody>

65
package-lock.json generated
View File

@@ -2898,13 +2898,14 @@
}
},
"@nuxtjs/pwa": {
"version": "3.3.2",
"resolved": "https://registry.npmjs.org/@nuxtjs/pwa/-/pwa-3.3.2.tgz",
"integrity": "sha512-yVOaU0MKKmsw44Vtl1Rq+kfhXJF46AqXni2YFGpOMvemcaPbkc+PZDyZTf3mDJQkUKgaY1aiiHMisOS/6rvnPg==",
"version": "3.3.3",
"resolved": "https://registry.npmjs.org/@nuxtjs/pwa/-/pwa-3.3.3.tgz",
"integrity": "sha512-SVydLpHWeHFTdBx/UaC8sc39lcDW8IkDUCDSVh8jGz1aPsqZGbATd0MMtGa7uefGInMX+SvN/osmzYjuLlYRpw==",
"dev": true,
"requires": {
"clone-deep": "^4.0.1",
"defu": "^3.2.2",
"execa": "^4.1.0",
"execa": "^5.0.0",
"fs-extra": "^9.0.1",
"hasha": "^5.2.2",
"jimp-compact": "^0.16.1",
@@ -2913,26 +2914,20 @@
"workbox-cdn": "^5.1.4"
},
"dependencies": {
"defu": {
"version": "3.2.2",
"resolved": "https://registry.npmjs.org/defu/-/defu-3.2.2.tgz",
"integrity": "sha512-8UWj5lNv7HD+kB0e9w77Z7TdQlbUYDVWqITLHNqFIn6khrNHv5WQo38Dcm1f6HeNyZf0U7UbPf6WeZDSdCzGDQ==",
"dev": true
},
"execa": {
"version": "4.1.0",
"resolved": "https://registry.npmjs.org/execa/-/execa-4.1.0.tgz",
"integrity": "sha512-j5W0//W7f8UxAn8hXVnwG8tLwdiUy4FJLcSupCg6maBYZDpyBvTApK7KyuI4bKj8KOh1r2YH+6ucuYtJv1bTZA==",
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/execa/-/execa-5.0.0.tgz",
"integrity": "sha512-ov6w/2LCiuyO4RLYGdpFGjkcs0wMTgGE8PrkTHikeUy5iJekXyPIKUjifk5CsE0pt7sMCrMZ3YNqoCj6idQOnQ==",
"dev": true,
"requires": {
"cross-spawn": "^7.0.0",
"get-stream": "^5.0.0",
"human-signals": "^1.1.1",
"cross-spawn": "^7.0.3",
"get-stream": "^6.0.0",
"human-signals": "^2.1.0",
"is-stream": "^2.0.0",
"merge-stream": "^2.0.0",
"npm-run-path": "^4.0.0",
"onetime": "^5.1.0",
"signal-exit": "^3.0.2",
"npm-run-path": "^4.0.1",
"onetime": "^5.1.2",
"signal-exit": "^3.0.3",
"strip-final-newline": "^2.0.0"
}
},
@@ -2948,6 +2943,18 @@
"universalify": "^1.0.0"
}
},
"get-stream": {
"version": "6.0.0",
"resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.0.tgz",
"integrity": "sha512-A1B3Bh1UmL0bidM/YX2NsCOTnGJePL9rO/M+Mw3m9f2gUpfokS0hi5Eah0WSUEWZdZhIZtMjkIYS7mDfOqNHbg==",
"dev": true
},
"human-signals": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz",
"integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==",
"dev": true
},
"jsonfile": {
"version": "6.1.0",
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
@@ -5186,6 +5193,17 @@
"integrity": "sha1-G39Ln1kfHo+DZwQBYANFoCiHQ18=",
"dev": true
},
"clone-deep": {
"version": "4.0.1",
"resolved": "https://registry.npmjs.org/clone-deep/-/clone-deep-4.0.1.tgz",
"integrity": "sha512-neHB9xuzh/wk0dIHweyAXv2aPGZIVk3pLMe+/RNzINf17fe0OG96QroktYAUm7SM1PBnzTabaLboqqxDyMU+SQ==",
"dev": true,
"requires": {
"is-plain-object": "^2.0.4",
"kind-of": "^6.0.2",
"shallow-clone": "^3.0.0"
}
},
"co": {
"version": "4.6.0",
"resolved": "https://registry.npmjs.org/co/-/co-4.6.0.tgz",
@@ -14701,6 +14719,15 @@
"safe-buffer": "^5.0.1"
}
},
"shallow-clone": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/shallow-clone/-/shallow-clone-3.0.1.tgz",
"integrity": "sha512-/6KqX+GVUdqPuPPd2LxDDxzX6CAbjJehAAOKlNpqqUpAqPM6HeL8f+o3a+JsyGjn2lv0WY8UsTgUJjU9Ok55NA==",
"dev": true,
"requires": {
"kind-of": "^6.0.2"
}
},
"shebang-command": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz",

View File

@@ -49,7 +49,7 @@
"@babel/preset-env": "^7.12.11",
"@nuxtjs/color-mode": "^2.0.2",
"@nuxtjs/google-analytics": "^2.4.0",
"@nuxtjs/pwa": "^3.3.2",
"@nuxtjs/pwa": "^3.3.3",
"@nuxtjs/tailwindcss": "^3.4.1",
"@testing-library/jest-dom": "^5.11.6",
"@vue/test-utils": "^1.1.2",

View File

@@ -603,7 +603,7 @@
<label for="generatedCode">{{ $t("javascript_code") }}</label>
<div>
<a
href="https://github.com/hoppscotch/hoppscotch/wiki/Post-Requests-Tests"
href="https://github.com/hoppscotch/hoppscotch/wiki/Post-Request-Tests"
target="_blank"
rel="noopener"
>