LocalHost wamp server specific request to API blocked

Arel64

New member
Joined
May 27, 2020
Messages
3
Hello,
I'm trying to use the DirectAdmin API in a PHP application I'm writing.
Specifically when I try and get the list of ftp accounts (CMD_API_FTP) I get an empty array.
Upon further inspection I found this strange behavior to happen only when I'm working locally from a WAMP server I created on my local machine
When the code is uploaded to the server the command works fine and ftp accounts are listed as expected.
What I've tried:
  • editing hosts file to point to my server
  • Enabling the "Prevent Blacklist Localhost"
This is weird because All of the calls to the API works okay, It is only when I call this specific one on my machine as localhost does this error appear
Thank you for your help!
Edit: Spelling
 
Still not solved, Code is working completely when on server, but when accessing from localhost only null reply.
  • I have tried to install a local ssl certificate and it didn't make a difference
  • It also seems to only occur reseller level commands. Admin commands are executed properly
 
Last edited:
Back
Top