Yelp / yelp-android

MIT License
55 stars 36 forks source link

Yelp Fusion Auth with API KEYs #49

Open elope-developers opened 6 years ago

elope-developers commented 6 years ago

"Prior to December 7, 2017 the API used OAuth 2.0 to authenticate requests to the API. In an effort to simplify authentication, starting March 1, 2018 the API will no longer use OAuth 2.0 for requests and will move over to only API Keys. The token endpoint will be deprecated March 1, 2018, at which point you will no longer be able to make requests to it. " -source: Yelp (https://www.yelp.com/developers/documentation/v3/authentication#where-is-my-client-secret-going)

Is there an update to support this in the roadmap? We're closing in on less than a month with no announced update for the yelp-android project.

virgytam commented 6 years ago

Hi Linger-Software, OAuth tokens aren't used in the v2 API (they're only used in the v3 API, aka Fusion), so the current yelp-android clientlib isn't affected.

elope-developers commented 6 years ago

Just to be clear the gradle project lib: 'io.github.ranga543:yelp-fusion-client:0.1.2' is still fine to use, even after the March 1 update?

elope-developers commented 6 years ago

Hello,

Android users are unable to use our client app due to the API not working. We were told that the yelp-android clientlib would not be affected.

virgytam commented 6 years ago

Hi Linger-Software, the clientlib created by ranga543 (https://github.com/ranga543/yelp-fusion-android) is not an official Yelp clientlib, but since it's for Fusion (aka v3), it's possible that the recent change to remove the oauth2/token endpoint is causing it to not work. You'll have to check with the author of that clientlib to confirm.

The only official Yelp Android clientlib is for the v2 API (https://github.com/Yelp/yelp-android), which is the clientlib I thought you were originally referring to. Sorry for the confusion.

elope-developers commented 6 years ago

Ah thank you very much!!! We didn't notice that either!!! I can't believe we weren't using the official on this entire time. Okay. So.

To the new api, it says we're on v3 but per the documentation is says we need:

consumerKey consumerSecret token tokenSecret

YelpAPIFactory apiFactory = new YelpAPIFactory(consumerKey, consumerSecret, token, tokenSecret); YelpAPI yelpAPI = apiFactory.createAPI();

In the yelp manage app page, we do not yet have that available. Is there any solution we can do to get this resolved as quickly as possible on our end?

virgytam commented 6 years ago

The consumerKey, consumerSecret, etc. are all v2 authorization params and we are turning off the v2 API this June 2018. (more info here: https://engineeringblog.yelp.com/2017/06/upcoming-deprecation-of-yelp-api-v2.html) The official yelp-android clientlib is for v2 and unfortunately we do not have an official v3 android clientlib.

Fusion (v3) uses a client_id and a api_key which you can get here: https://www.yelp.com/developers/v3/manage_app

We have some sample code for how to use these values, although we don't have one specifically for Java. https://github.com/Yelp/yelp-fusion#code-samples

elope-developers commented 6 years ago

Thanks for the resources. Since there's no way to sign up for the v2 API anymore (as of April 2017), nor is there any java version of the Fusion API (at the moment), our Android users will be temporarily shut out?

Hopefully, we can get a PHP client set up and running soon with Fusion API working soon, to make HTTP requests from JAVA.

gangadhardhulipala commented 6 years ago

is there any java version of the Fusion API (at the moment) for android users with client ID and API_KEY?

elope-developers commented 6 years ago

Here's the lib we use:

https://github.com/ranga543/yelp-fusion-android

Works great!!!

On Sat, Apr 28, 2018, 04:21 Gangadhar Dhulipala notifications@github.com wrote:

is there any java version of the Fusion API (at the moment) for android users with client ID and API_KEY?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/Yelp/yelp-android/issues/49#issuecomment-385167511, or mute the thread https://github.com/notifications/unsubscribe-auth/AauFVy3RPqqTYcnntVmo7fCvUcmS_kVZks5ttFC_gaJpZM4RqzSQ .