Xcode 9.2 : API error: Request failed: forbidden (403)

623 Views Asked by At

I’ve a code which is written by third party vendor back in 2014 in Objective-C language. Now, the issue with this is that when I try to login with valid credentials I’m getting below error

API error: Request failed: forbidden (403) in console window.

The strange thing is that if I run the same on postman then it return valid response. The communication with server is done using pod 'AFNetworking', ‘2.4.1’.

Screenshot 1

Is this issue due to older version of AFNetworking being used?

If I update to Pod to latest 3.2.0 version then it fails to build the application with compile time error as ‘Parse Issue’

Screenshot 2

This 'Parse Issue' is resolved by replacing occurrence of AFHTTPRequestOperation with AFHTTPSessionManager. Now the app builds successfully but getting same error for login.

Any fix?

0

There are 0 best solutions below