update modules from ms

This commit is contained in:
2024-11-14 01:55:04 +03:00
parent 44c94689c6
commit d2028e926b
6 changed files with 95 additions and 58 deletions

View File

@ -0,0 +1,21 @@
<?php
namespace kernel\helpers;
use http\Client;
class RESTClient
{
public static function request(string $url, string $method = 'GET')
{
$client = new \GuzzleHttp\Client();
return $client->request($method, $url, [
'headers' => [
'Authorization' => 'Bearer ' . $_ENV['MODULE_SHOP_TOKEN']
]
]);
}
}