mirror of
https://github.com/gethomepage/homepage.git
synced 2025-12-07 01:26:01 -08:00
Remove inaccurate POST examples from authoring docs
Some checks failed
Docker CI / Linting Checks (push) Has been cancelled
Docs / Linting Checks (push) Has been cancelled
Docker CI / Docker Build & Push (push) Has been cancelled
Docs / Test Build Docs (push) Has been cancelled
Docs / Build & Deploy Docs (push) Has been cancelled
Repository Maintenance / Stale (push) Has been cancelled
Repository Maintenance / Lock Old Threads (push) Has been cancelled
Repository Maintenance / Close Answered Discussions (push) Has been cancelled
Repository Maintenance / Close Outdated Discussions (push) Has been cancelled
Repository Maintenance / Close Unsupported Feature Requests (push) Has been cancelled
Crowdin Action / Crowdin Sync (push) Has been cancelled
Some checks failed
Docker CI / Linting Checks (push) Has been cancelled
Docs / Linting Checks (push) Has been cancelled
Docker CI / Docker Build & Push (push) Has been cancelled
Docs / Test Build Docs (push) Has been cancelled
Docs / Build & Deploy Docs (push) Has been cancelled
Repository Maintenance / Stale (push) Has been cancelled
Repository Maintenance / Lock Old Threads (push) Has been cancelled
Repository Maintenance / Close Answered Discussions (push) Has been cancelled
Repository Maintenance / Close Outdated Discussions (push) Has been cancelled
Repository Maintenance / Close Unsupported Feature Requests (push) Has been cancelled
Crowdin Action / Crowdin Sync (push) Has been cancelled
This commit is contained in:
@@ -225,20 +225,8 @@ const widgetExample = {
|
|||||||
|
|
||||||
#### `method`
|
#### `method`
|
||||||
|
|
||||||
The `method` property is a string that represents the HTTP method that should be used to make the API request. The default value is `GET`.
|
The `method` represents the HTTP method that should be used to make the API request. The default value is `GET`. Note that `POST` requests are not allowed via the
|
||||||
|
widget API and require the use of a custom proxy.
|
||||||
```js
|
|
||||||
const widgetExample = {
|
|
||||||
api: "{url}/api/{endpoint}",
|
|
||||||
mappings: {
|
|
||||||
// `/api/stats`
|
|
||||||
stats: {
|
|
||||||
endpoint: "stats",
|
|
||||||
method: "POST",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
};
|
|
||||||
```
|
|
||||||
|
|
||||||
#### `headers`
|
#### `headers`
|
||||||
|
|
||||||
@@ -251,7 +239,6 @@ const widgetExample = {
|
|||||||
// `/api/stats`
|
// `/api/stats`
|
||||||
stats: {
|
stats: {
|
||||||
endpoint: "stats",
|
endpoint: "stats",
|
||||||
method: "POST",
|
|
||||||
headers: {
|
headers: {
|
||||||
"Content-Type": "application/json",
|
"Content-Type": "application/json",
|
||||||
},
|
},
|
||||||
@@ -271,7 +258,6 @@ const widgetExample = {
|
|||||||
// `/api/graphql`
|
// `/api/graphql`
|
||||||
stats: {
|
stats: {
|
||||||
endpoint: "graphql",
|
endpoint: "graphql",
|
||||||
method: "POST",
|
|
||||||
body: {
|
body: {
|
||||||
query: `
|
query: `
|
||||||
query {
|
query {
|
||||||
|
|||||||
Reference in New Issue
Block a user