The Movie Database support

Does API V4 has these features: Mark as Favorite / Add to Watchlist? API V4 has new features in Account such as 'Get Movie Recommendations ' base on account info which i can't find in V3 I find it is difficult to use those features together, because i need to finish authentication twice for session_id and access_token

1 svar (på side 1 af 1)

Jump to last post

If you are using Android then you can authenticate with both versions. You can also look up the auth logic (links) from my project Moviebase.

Here an example for the WebView:

 private static final UriMatcher URI_MATCHER = new UriMatcher(UriMatcher.NO_MATCH);
    URI_MATCHER.addURI("moviebase://auth", "v3", 100);
    URI_MATCHER.addURI("moviebase://auth", "v4", 101);

    public void onCreate(@Nullable Bundle savedInstanceState) {

        // initialise webView
        webView.setWebViewClient(new WebViewClient() {
            @Override
            public boolean shouldOverrideUrlLoading(WebView view, WebResourceRequest request) {
                Uri uri = request.getUrl();
                return handleUriLoading(view, uri);
            }
        }

    }

    boolean handleUriLoading(WebView view, Uri uri) {
       switch (URI_MATCHER.match(uri)) {
        case 100: 
            // moviebase://auth/v3?request_token=[xxx]&approved=true
            // check approved parameter
            // handle request token
            // ...
            break;
        case 101:
            // request access token, account details for version 4 etc.
            break;
       }

    }

Kan du ikke finde en film eller TV-serie? Log in og opret den.

Global

s focus the search bar
p open profile menu
esc luk et åbent vindue
? open keyboard shortcut window

På mediesider

b go back (or to parent when applicable)
e go to edit page

On TV season pages

(right arrow) go to next season
(left arrow) go to previous season

On TV episode pages

(right arrow) go to next episode
(left arrow) go to previous episode

På alle billedesider

a open add image window

On all edit pages

t open translation selector
ctrl+ s submit form

På diskussionssider

n opret ny diskussion
w toggle watching status
p toggle public/private
c toggle close/open
a åben aktivitet
r reply to discussion
l go to last reply
ctrl+ enter submit your message
(right arrow) next page
(left arrow) previous page

Indstillinger

Want to rate or add this item to a list?

Log ind