Search code examples
uber-api

I want to use Get /v1.2/products REST API of Uber in android


I want to use Uber in my app by using its Rest API, and when I hit the same from Postman and i will get the same error every time

{
  "message": "No authentication provided.",
  "code": "unauthorized"
}

after entering the same request as given sample on the Uber Developers Site. you can also check the same here:

this is the link

And I am attaching here the pic of my request.

here is the image


Solution

  • In your Authorization header, replace server_token with Token.

    So your example header has:

    Authorization:server_token SERVER_TOKEN
    

    replace that with:

    Authorization: Token SERVER_TOKEN