https://github.com/bpanel-org/curl
A backend plugin for bPanel that adds a CORS-friendly `curl` API endpoint
https://github.com/bpanel-org/curl
Last synced: 8 months ago
JSON representation
A backend plugin for bPanel that adds a CORS-friendly `curl` API endpoint
- Host: GitHub
- URL: https://github.com/bpanel-org/curl
- Owner: bpanel-org
- Created: 2019-01-03T20:52:44.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-01-04T23:35:43.000Z (over 7 years ago)
- Last Synced: 2025-02-09T11:12:12.691Z (over 1 year ago)
- Language: JavaScript
- Homepage:
- Size: 49.8 KB
- Stars: 0
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# curl
This plugin runs entirely on the server and has no views.
It adds a new API endpoint with the shape...
```
/curl/:host?path=
```
Example usage from the `@Bpanel/price` plugin:
```
http://localhost:5000/curl/cex.io?path=api/ticker/BCH/USD
```
...and fetches JSON API data from the requested URL. This helps bypass CORS
issues for plugins (such as `price` and `price-widget`) that need access
to "arbitrary" servers on the internet.
Currently we require custom branches of `bcurl` and `brq` that allow more
flexibility than usual. If those branches get merged into master we can remove
the custom dependencies:
https://github.com/pinheadmz/bcurl/tree/bpanel-dev
https://github.com/pinheadmz/brq/tree/patch-1