Changes between Version 19 and Version 20 of XMLRPC


Ignore:
Timestamp:
Dec 10, 2008, 9:48:42 AM (16 years ago)
Author:
os
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • XMLRPC

    v19 v20  
    213213'''array !CheckMovieHash( $token, array($moviehash, $moviehash, ...) )'''
    214214
    215 This method returns !MovieImdbID, !MovieName, !MovieYear, if available for each $moviehash.
    216 
    217 Example output:
    218 {{{
     215This method returns best matching !MovieImdbID, !MovieName, !MovieYear, if available for each $moviehash. See also !CheckMovieHash2()
     216
     217Example output:
     218{{{
     219    [status] => 200 OK
    219220    [data] => Array
    220221        (
    221222            [dab462412773581c] => Array
    222223                (
     224                    [MovieHash] => dab462412773581c
    223225                    [MovieImdbID] => 133152
    224226                    [MovieName] => Planet of the Apes
    225227                    [MovieYear] => 2001
    226228                )
     229
    227230            [ae34f157eefc093c] => Array
    228231                (
     232                    [MovieHash] => ae34f157eefc093c
    229233                    [MovieImdbID] => 288477
    230234                    [MovieName] => Ghost Ship
    231235                    [MovieYear] => 2002
    232236                )
     237
    233238            [abcdefg123211222] => Array
    234239                (
    235240                )
     241
    236242        )
    237     [seconds] => 0.046
    238 }}}
    239 
    240 '''Fields explanation:'''
    241 Array in data contains $moviehash => array()
     243
     244    [seconds] => 0.133
     245}}}
     246
     247'''Fields explanation:'''
     248Array in data contains $moviehash => array(), even for unmatched moviehashes.
     249
     250----
     251
     252== !CheckMovieHash2 ==
     253'''array !CheckMovieHash2( $token, array($moviehash, $moviehash, ...) )'''
     254
     255This method returns matching !MovieImdbID, !MovieName, !MovieYear, if available for each $moviehash, always sorted by !SeenCount DESC.
     256
     257Example output:
     258{{{
     259    [status] => 200 OK
     260    [data] => Array
     261        (
     262            [3b2ae156d8c11f7a] => Array
     263                (
     264                    [0] => Array
     265                        (
     266                            [MovieHash] => 3b2ae156d8c11f7a
     267                            [MovieImdbID] => 103644
     268                            [MovieName] => Alien³
     269                            [MovieYear] => 1992
     270                            [SeenCount] => 48
     271                        )
     272
     273                    [1] => Array
     274                        (
     275                            [MovieHash] => 3b2ae156d8c11f7a
     276                            [MovieImdbID] => 133093
     277                            [MovieName] => The Matrix
     278                            [MovieYear] => 1999
     279                            [SeenCount] => 5
     280                        )
     281
     282                )
     283
     284            [53fc6fe84ad5ee31] => Array
     285                (
     286                    [0] => Array
     287                        (
     288                            [MovieHash] => 53fc6fe84ad5ee31
     289                            [MovieImdbID] => 813715
     290                            [MovieName] => "Heroes"
     291                            [MovieYear] => 2006
     292                            [SeenCount] => 427
     293                        )
     294
     295                    [1] => Array
     296                        (
     297                            [MovieHash] => 53fc6fe84ad5ee31
     298                            [MovieImdbID] => 1185913
     299                            [MovieName] => "Heroes" One of Us, One of Them
     300                            [MovieYear] => 2008
     301                            [SeenCount] => 260
     302                        )
     303
     304                )
     305        ...
     306}}}
     307
     308'''Fields explanation:'''
     309Array in data contains $moviehash => array(), '''only''' for matched moviehashes.
     310
     311----
     312
     313== !InsertMovieHash ==
     314'''array !InsertMovieHash( $token, array( array('moviehash' => $moviehash, 'moviebytesize' => $moviebytesize, 'imdbid' => $imdbid, 'movietimems' => $movietimems, 'moviefps' => $moviefps, 'moviefilename' => $moviefilename), array(...) ) )'''
     315
     316Inserts or updates data to tables, which are used for !CheckMovieHash() and !CheckMovieHash2(). Requested parameters are: '''moviehash, moviebytesize, imdbid''', all rest parameters are '''optional''', but preferred to supply them. Before accepting moviehashes, each moviehash is checked against log table if user doesn't already send it.
     317
     318Example output:
     319{{{
     320    [status] => 200 OK
     321    [data] => Array
     322        (
     323            [accepted_moviehashes] => Array
     324                (
     325                    [0] => 53fc6fe84ad5ee31
     326                    [1] => 3b2ae156d8c11f7a
     327                )
     328
     329            [new_imdbs] => Array
     330                (
     331                )
     332
     333        )
     334
     335    [seconds] => 0.014
     336}}}
     337
     338'''Fields explanation:'''
     339accepted_moviehashes - hashes, which was inserted or updated, new_imdbs - imdb ids need to download from imdb.com
    242340
    243341----