DSB-PlugIn/AddOn/Calender_Office365_User/auth.php

15 lines
355 B
PHP

<?php
$config = require 'config.php';
$params = [
'client_id' => $config['client_id'],
'response_type' => 'code',
'redirect_uri' => $config['redirect_uri'],
'response_mode' => 'query',
'scope' => $config['scopes'],
];
$authUrl = $config['auth_url'] . '?' . http_build_query($params);
header("Location: $authUrl");
exit;