Omada API with PHP (Login fail)

This thread has been locked for further replies. You can start a new thread to share your ideas or ask questions.

Omada API with PHP (Login fail)

This thread has been locked for further replies. You can start a new thread to share your ideas or ask questions.
Omada API with PHP (Login fail)
Omada API with PHP (Login fail)
2022-04-14 14:02:56
Model: Adapter  
Hardware Version: V1
Firmware Version: 5.0.30
Hello, I get the error when trying to connect: {"errorCode":-30109,"msg":"Invaild username or password."}
What am I doing wrong?

 

 

$headers = array(
            "Content-Type: application/json",
            "Accept: application/json",
        );

$loginInfo = array(
            "name" => user,
            "password" => pass
        );
 
$chLogin = curl_init();
curl_setopt($chLogin, CURLOPT_POST, TRUE);
curl_setopt($chLogin, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($chLogin, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($chLogin, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($chLogin, CURLOPT_URL, 'https://ip:port/omadacId/api/v2/login');
curl_setopt($chLogin, CURLOPT_HTTPHEADER, $headers);
curl_setopt($chLogin, CURLOPT_POSTFIELDS, json_encode($loginInfo));

$OutputLogin = curl_exec($chLogin);
curl_close($chLogin);

echo $OutputLogin;

 

OutputLogin: {"errorCode":-30109,"msg":"Invaild username or password."}

  0      
  0      
#1
Options
1 Reply
Re:Omada API with PHP (Login fail)
2022-04-19 09:58:39

It seems like username/password incrrect.

 

Controller password must be more than 8 letters/characters

 

  0  
  0  
#2
Options

Information

Helpful: 0

Views: 776

Replies: 1

Related Articles