browser_fetch
Make an HTTPS request from the extension background. It is not subject to the page's CORS or CSP, so it works for API calls (Google, Stripe, Slack) where a fetch from the page would be blocked.
Instructions
Make an HTTPS request from the extension background. It is not subject to the page's CORS or CSP, so it works for API calls (Google, Stripe, Slack) where a fetch from the page would be blocked. Your browser cookies are not sent and the answer's cookies are not stored: pass a token in headers. Plain http works only to 127.0.0.1.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | URL to fetch | |
| body | No | Request body (for POST/PUT) | |
| method | No | HTTP method (default: GET) | |
| headers | No | Request headers as key-value pairs |