Issues with CyberPanel API Integration Using ChatGPT's HTTP Webhooks Plugin

Ubuntu 18.04

Current Version: 2.3
Build: 4
Current Commit: a47d41a3741c46a4130d81f0db7adf176c198840
Latest Version: 2.3
Latest Build: 4
Latest Commit: f337f895514e0f9eb5240976e09f18cca161cc14

Hello everyone,

I’m trying to integrate the CyberPanel API using ChatGPT’s HTTP Webhooks plugin, a language model developed by OpenAI. My goal is to perform operations on CyberPanel with the help of ChatGPT.

I’ve followed the official CyberPanel API documentation and have been able to successfully make API calls using Postman.

However, when I try to do the same with ChatGPT’s HTTP Webhooks plugin, I don’t get the expected responses.

For example, when I try to list the websites on my CyberPanel server, I get an error message saying “Not Implemented”. Here are the details of the request and response:

image

What confuses me is that I’ve had success using the same plugin with the Cloudflare API. I was able to list all my domains and manipulate records without any issues.

Has anyone had a similar experience or have any idea why this might be happening? Any help would be greatly appreciated.

//===========================//

Steps to reproduce the problem (You need the ChatGPT Plus membership, the GPT4 template and the active HTTP Webhooks plugin):

  1. First, I configured Postman according to the official CyberPanel API documentation and was able to make successful API calls. Here are the details of Postman configuration:
{
    "serverUserName": "admin",
    "controller": "fetchWebsites",
    "websiteName": "cyberpanel.net",
    "page": 1
}
  1. Next, I tried to replicate the same API call using ChatGPT’s HTTP Webhooks plugin. Here are the details of the webhook configuration:
  • Name: CyberPanel_FetchWebsites
  • Script:
{
  "name": "CyberPanel_FetchWebsites",
  "script": "export default { fetch: async (request) => { const url = 'https://you-web-site:8090/cloudAPI/'; const body = JSON.stringify({ serverUserName: 'admin', controller: 'fetchWebsites', websiteName: 'cyberpanel.net', page: 1 }); const options = { method: 'POST', headers: { 'Content-Type': 'text/plain', 'Authorization': 'Basic <YOUR_AUTHORIZATION_TOKEN>' }, body: body }; const response = await fetch(url, options); if (!response.ok) { return new Response(`Error: ${response.status} ${response.statusText}`); } const data = await response.json(); return new Response(JSON.stringify(data)) } };"
}
  1. After configuring the webhook, I tried to run it and got an error message saying “Not Implemented”. Here are the details of the request and the response:
  • Request:
{
    "webhookId": "f49a404f-0dd0-4554-812e-9a4cc807d81d"
}

  • Answer: Not Implemented

I asked CHATGPT to solve your issue but chatgpt says do it yourself as an ai assistant i can’t do all things.