fetchRemoteToken static method
Fetches the remote token that allows the user to connect to the bridge remotely.
This is step 2. Step 1 is BridgeDiscoveryService.remoteAuthRequest.
Implementation
static Future<Map<String, dynamic>?> fetchRemoteToken({
required String clientId,
required String clientSecret,
required String pkce,
required String code,
}) async {
final Map<String, String> body = {
"grant_type": "authorization_code",
"code": code,
"code_verifier": pkce,
};
return _fetchRemoteToken(
clientId: clientId,
clientSecret: clientSecret,
body: body,
);
}