Hi! Could we please enable some services and cookies to improve your experience and our website?

PHPize | SQLize | SQLtest

Online Sandbox for SQL and PHP: Write, Run, Test, and Share SQL Queries and PHP Code

A A A
Login    Share code      Blog   FAQ
Copy Format Clear

Stuck with a problem? Got Error? Ask AI support!

Copy Clear
Copy Format Clear
<?php $login = curl_init(); curl_setopt($login, CURLOPT_URL, "https://a.onenetwork-system.xyz/api/admin/token"); curl_setopt($login, CURLOPT_HTTPHEADER, array( 'Accept: application/json', 'Content-Type: application/x-www-form-urlencoded' )); curl_setopt($login, CURLOPT_RETURNTRANSFER, true); curl_setopt($login, CURLOPT_POSTFIELDS, http_build_query([ 'grant_type' => 'password', 'username' => 'rooter', 'password' => 'retoor0907', 'scope' => '', 'client_id' => 'string', 'client_secret' => 'string' ])); $response = curl_exec($login); curl_close($login); $logdata = json_decode($response, true); echo $logdata["access_token"]; ?>
Copy Clear