Author Topic: cURL API testing  (Read 804 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
cURL API testing
« on: July 12, 2019, 04:31:40 AM »
i am wanting to create a script that will change a password for an email account. i am testing by simply trying to list users with cURL using this line
Code: [Select]
curl -d '{"MYKEY":"mYk3yh3r3","action":"list"}' -H "Content-Type: application/json" -X POST https://cwp.mydomain.com:2304/v1/accountdetail  but i get the error

Code: [Select]
{"status":"Error","msj":"error in key","format":"JSON"}
Thanks for your help

Offline
*
Re: cURL API testing
« Reply #1 on: July 12, 2019, 09:19:33 AM »

Offline
*
Re: cURL API testing
« Reply #2 on: July 13, 2019, 03:33:47 AM »
Quote from: josemnunez link=topic=7026.msg24397#msg24397 date=
Visit our documentation

https://docs.control-webpanel.com/docs/developer-tools/api-manager

Thank you now i get
Code: [Select]
{"status":"Error","msj":"Unauthorized action