-
Notifications
You must be signed in to change notification settings - Fork 184
Open
Description
Expected behavior
App is installed
Actual behavior
Parameter redirect_uri does not match registered URI error thrown, app is not installed.
Steps to reproduce behavior
Using bigcommerce/api version 3.3.1. When using the README.md instructions to get the App's auth token, the "Parameter redirect_uri does not match registered URI" error is always thrown.
I've tried using trailing slashes and not, changing apps, etc. but when I add the Loadcallback URI from the App to the redirect_uri parameter in the code below, sending the request to getAuthToken() always fails.
use Bigcommerce\Api\Client as Bigcommerce;
$object = new \stdClass();
$object->client_id = '[client id from test app]';
$object->client_secret = '[client secret from test app]';
$object->redirect_uri = '[copy pasted from Load Callback URL]';
$object->code = $request->get('code');
$object->context = $request->get('context');
$object->scope = $request->get('scope');
$authTokenResponse = Bigcommerce::getAuthToken($object);
// fails here - getAuthToken returns false
Bigcommerce::configure(array(
'client_id' => 'xxxxxxxx',
'auth_token' => $authTokenResponse->access_token,
'store_hash' => 'xxxxxxx'
));
Metadata
Metadata
Assignees
Labels
No labels