tumblr / tumblr.php

Tumblr API v2 PHP Client
Apache License 2.0
407 stars 115 forks source link

Add authenticating requests with OAuth2 #100

Closed janicejellee closed 2 years ago

janicejellee commented 6 years ago

Authenticating with OAuth2 [work in progress]

This adds support for authenticating any request in the client with OAuth2. It uses the thephpleague/oauth2-client library (although I don't think I used many parts of it...)

I will likely have to make changes, so this is still a work in progress. Let me know if you see any issues, have any code review comments, or think I should organize the files differently, integrate files together, etc. 👀

I have not added documentation yet either.

Testing

I added additional tests for Client2 and RequestHandler2, which are just the existing tests but edited.

You can also test by making calls like this:

    client = new Client2('<access-token>');
    $client->getBlogAvatar('some-blog-name');
    $client->follow('some-blog-name');

@ceyko

ghost commented 4 years ago

you are wasting your time here, tumblr doesnt care about updating there api and there customers