Changes between Version 1 and Version 2 of XMLRPC
- Timestamp:
- Jul 17, 2008, 10:10:45 AM (16 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
XMLRPC
v1 v2 11 11 = Instructions = 12 12 13 * All developing tests do on: http://dev.opensubtitles.org/xml-rpc 13 * All developing tests do on: http://dev.opensubtitles.org/xml-rpc (currently offline, so do it on main server:) 14 14 * Main server is: http://www.opensubtitles.org/xml-rpc 15 15 * Before developing and if you use this API let us know, we assign useragent to you, empty useragent will not work 16 16 * If you use language, 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] 17 * for gzip compression use function/method which adds no header to output, for php it is: [http://www.php.net/manual/en/function.gzcompress.php gzcompress] 17 18 18 19 = XMLRPC methods = … … 328 329 '''Fields explanation:''' 329 330 data is absolute link to subtitles. 331 ---- 332 333 == !DetectLanguage == 334 335 '''array !DetectLanguage( $token, array($text, $text, ...) )''' 336 337 Returns array of MD5 => ISO639-2 language codes, trying to detect language for given $text. Note: $text MUST be base64 encoded and should be gzipped (without header), for save some bandwidth and for better speed. MD5 is md5() of unpacked text, input text should be up to 4096 bytes long for good results - but you can send all contents of subtitles. [http://www.boxoffice.ch/pseudo/ PHP textcat] 338 339 Example output: 340 {{{ 341 [status] => 200 OK 342 [data] => Array 343 ( 344 [9e107d9d372bb6826bd81d3542a419d6] => eng 345 [ffd93f16876049265fbaef4da268dd0e] => cze 346 ... 347 ) 348 [seconds] => 0.625 349 }}} 350 351 Fields explanation: All fields are self-explained. Note: if you get instead of 3 characters language some other languagename - please contact us with input/output text (for example scots) 330 352 331 353 ----