i have some issues with login using Swiftagram WebView-based Authentication and Basic Authenticator
The first problem with Basic:
after test instagram account username and password are entered i send request.
when i validate profile i get message from switch-case Authenticator.Error.generic(String) - "checkpoint_challenge_required"
what could cause the problem ?
my code:
Authenticator.keychain
.basic(username: loginText! / username /,
password: passwordText! / password /)
.authenticate()
.sink(receiveCompletion: {
switch $0 {
case .failure(let error):
// Deal with two factor authentication.
switch error {
case Authenticator.Error.twoFactorChallenge(let challenge):
print(challenge)
break
case Authenticator.Error.invalidPassword:
print("invalidPassword")
case Authenticator.Error.invalidUsername:
print("invalidUsername")
case Authenticator.Error.invalidURL:
print("invalidURL")
case Authenticator.Error.invalidResponse(let response):
print("invalidURL", response.url as Any)
case Authenticator.Error.generic(let stringErr):
print(stringErr) < - this case
default:
print("default err", error.localizedDescription)
break
}
default:
print("default")
break
}
}, receiveValue: { result in
print("login_result: SUCCESS", result)
})
.store(in: &self.bin)
Second problem with WebView-based:
after test instagram account username and password are entered i send request.
when i validate profile i get error message "There wsa a problem logging you into instagram"
what could cause the problem ?

i have some issues with login using Swiftagram WebView-based Authentication and Basic Authenticator
The first problem with Basic:
after test instagram account username and password are entered i send request.
when i validate profile i get message from switch-case Authenticator.Error.generic(String) - "checkpoint_challenge_required"
what could cause the problem ?
my code:
Authenticator.keychain
.basic(username: loginText! / username /,
password: passwordText! / password /)
.authenticate()
.sink(receiveCompletion: {
switch $0 {
case .failure(let error):
// Deal with two factor authentication.
switch error {
case Authenticator.Error.twoFactorChallenge(let challenge):
print(challenge)
break
case Authenticator.Error.invalidPassword:
print("invalidPassword")
case Authenticator.Error.invalidUsername:
print("invalidUsername")
case Authenticator.Error.invalidURL:
print("invalidURL")
case Authenticator.Error.invalidResponse(let response):
print("invalidURL", response.url as Any)
case Authenticator.Error.generic(let stringErr):
print(stringErr) < - this case
default:
print("default err", error.localizedDescription)
break
}
default:
print("default")
break
}
}, receiveValue: { result in
print("login_result: SUCCESS", result)
})
.store(in: &self.bin)
Second problem with WebView-based:

after test instagram account username and password are entered i send request.
when i validate profile i get error message "There wsa a problem logging you into instagram"
what could cause the problem ?