You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
569 B
20 lines
569 B
<?php
|
|
|
|
require __DIR__ . '/../vendor/autoload.php';
|
|
|
|
$proxy1='192.168.128.139:8080';//http://193.49.118.36:8080';
|
|
$proxy2='proxycl.iut.uca.fr ';//http://193.49.118.36:8080';
|
|
|
|
|
|
|
|
|
|
$client = new GuzzleHttp\Client(['base_uri' => '192.168.127.121:8080']);
|
|
try {
|
|
$res = $client->request('POST', '/loan', ['somme' => 1000, 'account_id' => 1, 'approval_id' => 1, 'proxy'=>['http' => $proxy1, 'https'=> $proxy2]]);
|
|
echo $res->getStatusCode();
|
|
echo $res->getHeader('content-type')[0];
|
|
echo $res->getBody();
|
|
} catch (\GuzzleHttp\Exception\GuzzleException $e) {
|
|
|
|
}
|