

While making the signature using SHA1 you use NSString *string_to_sign = [NSString per the documentation. I could've changed it to anything but the thing is I just need to give something new so that a new signature can be generated. So to fix that I just changed the expire time from 1577922200 to 1577933200. However these three parameters are used to authenticate the user so that means the old signature which was generated to deny the permission will deny it again no matter what. This is because the parameters which are apiKey, Signature and Expire time are the same and you only changed the other parameters with your GET request. Then after a little time you realized the error that Opps! The parameters I was passing needed a bracket and you run the code again and you again got 401. Imagine you have created the URL and it didn't work and you got 401.


Based on the solution here I'm posting this answer.
