-
-
Save beingsane/1a51c05548da97591a20cfbab13765a1 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use GuzzleHttp\Client; | |
class yourController extends Controller { | |
public function saveApiData() | |
{ | |
$client = new Client(); | |
$res = $client->request('POST', 'https://url_to_the_api', [ | |
'form_params' => [ | |
'client_id' => 'test_id', | |
'secret' => 'test_secret', | |
] | |
]); | |
$result= $res->getBody(); | |
dd($result); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment