From a9c79abea83ca542ac389a2aae7d524c0388f691 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?laussel=20lo=C3=AFc?= Date: Wed, 10 Feb 2021 14:12:09 +0100 Subject: [PATCH] update token endpoint and add new required accept header --- src/Osms.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Osms.php b/src/Osms.php index ed52bf9..7a480c0 100644 --- a/src/Osms.php +++ b/src/Osms.php @@ -69,11 +69,11 @@ public function __construct($config = array()) */ public function getTokenFromConsumerKey() { - $url = self::BASE_URL . '/oauth/v2/token'; + $url = self::BASE_URL . '/oauth/v3/token'; $credentials = $this->getClientId() . ':' . $this->getClientSecret(); - $headers = array('Authorization: Basic ' . base64_encode($credentials)); + $headers = array('Authorization: Basic ' . base64_encode($credentials), 'Accept : application/json'); $args = array('grant_type' => 'client_credentials');