This is a simple, skeleton application using the Nette, and Microsoft Graph API which is part of Microsoft Graph solution. This is meant to be used as a starting point for your new projects.
The basic Nette skeleton show you how to use Microsft Graph with Nette.
Here are two scenarios:
- Using Microsoft graph as daemon (without user login). See Presenter app/Presenters/GraphPresenter. Detailed Instructions
- Using Microsoft graph for user login (oAuth). See Presenter app/Presenters/Signo365Presenter Instructions
- Web Project for Nette 3.1 requires PHP 7.2
- For Microsoft Graph API you need several libraries, all installed with microsoft/microsoft-graph
The best way to install Web Project is using Composer. If you don't have Composer yet, download it following the instructions. Then use command:
composer create-project nette/web-project path/to/install
cd path/to/install
composer require microsoft/microsoft-graph
composer require league/oauth2-client
Make directories temp/
and log/
writable.
The simplest way to get started is to start the built-in PHP server in the root directory of your project:
php -S localhost:8000 -t www
For Apache or Nginx, setup a virtual host to point to the www/
directory of the project and you
should be ready to go.
It is CRITICAL that whole app/
, config/
, log/
and temp/
directories are not accessible directly
via a web browser. See security warning.