$praticien_id])); $client_id = '2936c00e-7452-453a-af62-944cc3ad021e'; $tenant_id = '4b1704a1-7a2a-4618-a6ac-3ffe46e6b3b4'; $redirect_uri = urlencode('https://uslugi.fr/outlook_callback.php'); $resource = urlencode('https://graph.microsoft.com'); $url = "https://login.microsoftonline.com/consumers/oauth2/v2.0/authorize?" . "client_id=$client_id&response_type=code&redirect_uri=$redirect_uri" . "&scope=offline_access%20User.Read%20Calendars.ReadWrite&state=$state&prompt=consent"; header("Location: $url"); exit; ?>