PHP code example of gsmpopovic / medium-api
1. Go to this page and download the library: Download gsmpopovic/medium-api library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
gsmpopovic / medium-api example snippets
// Official Medium API Use cases
_once "../Request.php";
// or, if you're using composer, and have installed this package
ad the .env
if it hasn't already been loaded elsewhere, as in Laravel.
*/
$path = dirname(__DIR__, 1) . DIRECTORY_SEPARATOR . ".env";
$env = new Env($path);
$env->load();
$api = new MediumApi(new Request());
$api->getUser();