I just follow the DRS tutorial and trying below code but not working, Is anything wrong in the below code?
private func launchLogin() {
let manager = AMZNAuthorizationManager.shared()
let request = AMZNAuthorizeRequest()
request.interactiveStrategy = .auto
var scopeObjectArray = [AMZNScope]()
let requestScopes = "dash:replenish";
var options = [String : Any]()
options["serial"] = "123456"
options["device_model"] = "Device_Name_Test"
options["should_include_non_live"] = true
options["is_test_device"] = true
let drsScope = AMZNScopeFactory.scope(withName: requestScopes, data: options)
let profileScope = AMZNProfileScope.profile()
scopeObjectArray.append(drsScope)
scopeObjectArray.append(profileScope)
request.scopes = scopeObjectArray
request.grantType = .code
request.codeChallenge = "U3DddAEJMGgEc-ovgkgp571_atqjX0UjfMXA5QRT-XM"
request.codeChallengeMethod = "S256"
manager.authorize(request, withHandler: requestDRSHandler)
}
Getting below error,
Domain=AMZNLWAErrorDomain Code=6 "(null)" UserInfo={AMZNLWAErrorNonLocalizedDescription=One or more input parameters are wrong.}
Looks like the issue with the backend, can someone help?