downloads->application->name; } function getLatestBuild($projectName, $version){ $buildsStr = file_get_contents('https://papermc.io/api/v2/projects/'.$projectName.'/versions/'.$version); $builds = json_decode($buildsStr); $latestBuild = $builds->builds[count($builds->builds)-1]; return $latestBuild; } function getLatestVersion($projectName){ $versions = file_get_contents('https://papermc.io/api/v2/projects/'.$projectName); $versionJson = json_decode($versions); $numVersions = count($versionJson->versions) - 1; $latestVersion = $versionJson->versions[$numVersions]; return $latestVersion; }