convert AuthUtils to a non-static class and instantiate it as an object, support...
[authserver.git] / token.php
... / ...
CommitLineData
1<?php
2/* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this file,
4 * You can obtain one at http://mozilla.org/MPL/2.0/. */
5
6// Simple server based on https://bshaffer.github.io/oauth2-server-php-docs/cookbook
7
8// Include the common auth system files (including the OAuth2 Server object).
9require_once(__DIR__.'/authsystem.inc.php');
10
11// Handle a request for an OAuth2.0 Access Token and send the response to the client
12$server->handleTokenRequest(OAuth2\Request::createFromGlobals())->send();
13
14?>