Changes between Version 81 and Version 82 of XMLRPC


Ignore:
Timestamp:
May 11, 2015, 6:37:51 AM (10 years ago)
Author:
os
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • XMLRPC

    v81 v82  
    1010
    1111= Instructions =
    12  * [wiki:DevReadFirst Read this first]
    13  * before using this XML-RPC is vital to have implementation for [wiki:HashSourceCodes OS HASH]
    14  * '''API server domain changed''': XML-RPC requests send to '''http://api.opensubtitles.org/xml-rpc'''
    15  * From 21.4.2015 we support HTTPS for LogIn() if you need it - you can use '''https://api.opensubtitles.org:443/xml-rpc''', for other methods use standard http to save some resources...
    16  * Before developing let us know, we assign useragent to you, empty useragent or unregistered UA will not work.
     12 * [wiki:DevReadFirst Read this first] - Before developing let us know, we assign useragent to you, empty useragent or unregistered UA will not work.
     13 * before using this XML-RPC is required to have implementation for [wiki:HashSourceCodes OS HASH]
     14 * XML-RPC requests send to '''http://api.opensubtitles.org/xml-rpc''',  you may be interested in more verbose version of [wiki:XmlRpcIntro XML-RPC methods with examples]
     15 * we start support HTTPS, if you need it - you can use '''https://api.opensubtitles.org:443/xml-rpc'''
    1716 * For languages codes, check [http://en.wikipedia.org/wiki/List_of_ISO_639-2_codes ISO639], use '''pb/pob''' for Portuguese (Brazil) - [http://www.opensubtitles.org/addons/export_languages.php Download OS languages table dump]
    1817 * IMDB ID is meant to be NUMBER from link of IMDB movie. Example: http://www.imdb.com/title/tt0133093/ - IMDB ID is '0133093' (removing trailing zero is also OK).
     
    2120 * Handle properly HTTP status codes, sometimes you might get 5xx
    2221 * if you get '''407 Download limit reached''', do not use persistent connections (HTTP keep-alive) and don't download more than 200 subtitles per 24 hour per IP/User. If user wants more, he can [http://www.opensubtitles.org/en/support#vip Donate]
    23  * you may be interested in more verbose version of [wiki:XmlRpcIntro XML-RPC methods with examples]
    2422 * if you want search uploads by useragent, use this link: http://www.opensubtitles.org/search/sublanguageid-all/useragent-$UserAgent
    2523 * for testing XML-RPC without programming, follow these [wiki:XML-RPC-debugger instructions]
    2624 * please support '''GZIP compression for XML-RPC''' (in your HTTP request should be Accept-Encoding: gzip), it can save around [http://forum.opensubtitles.org/viewtopic.php?f=8&t=14246&p=27911 97.5% of bandwidth], so it is faster, it is better.
    2725 * for '''XML-RPC and HTTP''' request use registered USERAGENT in HTTP HEADERs, invalid UA could result for blocking users.
     26 * You can specify preferred language for response also by sending HTTP HEADER "Accept-Language"
    2827 * when downloading subtitles using standard HTTP we added HTTP RESPONSE HEADER: Download-Quota: %d, where %d is number how many subtitles can user still download.
    2928 * it is '''REQUIRED''' that your implementation supports '''!LogIn() with user credentials''' (manually input user and password), because there are quite a lot of IPs, which are proxy (some service providers NAT, Singapore, Iran and others), and there is download limit per IP, so those users will hit limit very soon and OS will be not usable for them. Also there is other important reasons why to support this (VIP membership and so on). Also '''NEVER''' put in your application registered username and password, it might be blocked.
    3029
     30
    3131= Common errors =
    3232After reviewing database with movie-hashes, we found developers often make these errors
    33  * moviebytesize set to low integer, so overflow happens. Don't forget files can be more than 8GB big (8.589.934.592 bytes), so make sure you allocate right variable for moviebytesize!
     33 * moviebytesize set to low integer, so overflow happens. Don't forget files can be more than 8GB big (8.589.934.592 bytes), so make sure you allocate right variable for moviebytesize (string is OK)!
    3434 * moviehash in 99,999% can not be '0000000000000000' (we are ignoring them now, but it is error)
    3535 * always pass all Method Parameters as string, because some unwanted conversion can occur. For example moviebytesize pass as string "4249049694" and NOT as int 4249049694.