#Patch method not working
1 messages · Page 1 of 1 (latest)
The CtrlPanel uses a credit-based system.
credits are charged hourly based on the monthly price (price / 30 / 24)
This means that the price of your products won’t be charged right away when the user creates a server, but instead, the credits are reduced hourly—giving the user the option to cancel and create servers freely anytime.
When the user runs out of credits, his server will automatically be suspended.
fetch("https://dash.navocloud.com/api/users/1", {
method: 'PATCH',
headers: {
'Authorization': Bearer apicode :),
'Content-Type': 'application/json'
},
})
Thats what I used to test it
Fetch finished loading: PATCH "https://dash.navocloud.com/api/users/1".
(anonymous) @ VM1561:1
VM1561:1
PATCH https://dash.navocloud.com/admin/api 405 (Method Not Allowed)
(anonymous) @ VM1561:1
VM1561:1 Fetch failed loading: PATCH "https://dash.navocloud.com/admin/api".
Response ^^^
FYI it doesn't update the user even if I specify credits
nvm
Maybe your API key is wrong
I was using the wrong method