Changes between Version 44 and Version 45 of XMLRPC
- Timestamp:
- Jan 24, 2012, 5:39:17 AM (13 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
XMLRPC
v44 v45 86 86 87 87 == !SearchSubtitles == 88 '''array !SearchSubtitles( $token, array(array('sublanguageid' => $sublanguageid, 'moviehash' => $moviehash, 'moviebytesize' => $moviesize, ''imdbid => $imdbid'', ''query'' => 'movie name' ),array(...)))'''89 90 Returns information about found subtitles. It is designed making multiple search at once. When nothing is found, 'data' is empty. If sublanguageid is empty, or have value 'all' - it search in every sublanguage, you can set it to multiple languages (e.g. eng,dut,cze).88 '''array !SearchSubtitles( $token, array(array('sublanguageid' => $sublanguageid, 'moviehash' => $moviehash, 'moviebytesize' => $moviesize, ''imdbid => $imdbid'', ''query'' => 'movie name', "season" => 'season number', "episode" => 'episode number' ),array(...)))''' 89 90 Returns information about found subtitles. It is designed making multiple search at once. When nothing is found, 'data' is empty. If sublanguageid is empty, or have value 'all' - it search in every sublanguage, you can set it to multiple languages (e.g. 'eng,dut,cze'). 91 91 92 92 If you define moviehash and moviebytesize, then imdbid and query in same array are ignored. If you define imdbid, then moviehash, moviebytesize and query is ignored. If you define query, then moviehash, moviebytesize and imdbid is ignored. Pseudocode: … … 104 104 * Some data (IDSubMovieFile, !MovieHash, !MovieByteSize, MovieTimeMS) are set to 0, when searching by imdbid or query 105 105 * Max results is set to 500 found items in total 106 * Season and Episode are not mandatory, when using query/imdb searching 106 107 * For perfect matches use moviehash/moviebytesize searching, for movie matches use imdbid searching, if you can not use any of them, use fulltext search 107 108 * If used this method in movie player and subtitles are found using imdbid or query, should be nice to implement [wiki:DevReadFirst#Yourmovieplayershouldsupportautomaticuploading Automatic Uploading], so we get back movie hash of matching movie 108 109 * !MatchedBy can be: moviehash, imdbid, fulltext (so you know from where results comes from) 109 110 110 Example output: 111 {{{ 112 [data] => Array 111 Tip: you can combine your searches array as you want, so things like 112 {{{ 113 array('query' => 'south park', 'season' => 1, 'episode' => 1,), 114 array('query' => 'beverly hills blondes'), 115 array('query' => 'matrix', 'sublanguageid' => 'cze,slo'), 116 array('moviehash' => '18379ac9af039390', 'moviebytesize' => 366876694) 117 }}} 118 are possible :) 119 120 Example output: 121 {{{ 122 [data] => Array 113 123 ( 114 124 [0] => Array 115 125 ( 116 126 [MatchedBy] => moviehash 117 [IDSubMovieFile] => 8 2181118 [MovieHash] => 09a2c497663259cb119 [MovieByteSize] => 73 3589504120 [MovieTimeMS] => 3165000121 [IDSubtitleFile] => 1 951690121122 [SubFileName] => Night.Watch.2004.CD1.DVDRiP.XViD-FiCO.srt127 [IDSubMovieFile] => 865 128 [MovieHash] => d745cd88e9798509 129 [MovieByteSize] => 734058496 130 [MovieTimeMS] => 0 131 [IDSubtitleFile] => 1118 132 [SubFileName] => Al sur de Granada (SPA).srt 123 133 [SubActualCD] => 1 124 [SubSize] => 27287125 [SubHash] => fe106fe2368799bdc73271bb24ac6df7126 [IDSubtitle] => 3144301127 [UserID] => 367123128 [SubLanguageID] => dut134 [SubSize] => 15019 135 [SubHash] => 0cb51bf4a5266a9aee42a2d8c7ab6793 136 [IDSubtitle] => 905 137 [UserID] => 0 138 [SubLanguageID] => spa 129 139 [SubFormat] => srt 130 140 [SubSumCD] => 1 131 141 [SubAuthorComment] => 132 [SubAddDate] => 2007-08-31 22:18:20 133 [SubBad] => 0 134 [SubRating] => 0.0 135 [SubDownloadsCnt] => 253 136 [MovieReleaseName] => Night Watch 137 [IDMovie] => 516 138 [IDMovieImdb] => 403358 139 [MovieName] => Nochnoy dozor 140 [MovieNameEng] => Night Watch 141 [MovieYear] => 2004 142 [MovieImdbRating] => 0.0 143 [UserNickName] => gyoom 144 [ISO639] => nl 145 [LanguageName] => Dutch 146 [SubComments] => 0 147 [SubDownloadLink] => http://www.opensubtitles.org/en/download/file/1951690121.gz 148 [ZipDownloadLink] => http://www.opensubtitles.org/en/download/sub/3144301 149 [SubtitlesLink] => http://www.opensubtitles.net/en/subtitles/3144301/nochnoy-dozor-nl 142 [SubAddDate] => 2005-06-15 20:05:35 143 [SubBad] => 1 144 [SubRating] => 4.5 145 [SubDownloadsCnt] => 216 146 [MovieReleaseName] => ss 147 [IDMovie] => 11517 148 [IDMovieImdb] => 349076 149 [MovieName] => Al sur de Granada 150 [MovieNameEng] => South from Granada 151 [MovieYear] => 2003 152 [MovieImdbRating] => 6.4 153 [SubFeatured] => 0 154 [UserNickName] => 155 [ISO639] => es 156 [LanguageName] => Spanish 157 [SubComments] => 1 158 [SubHearingImpaired] => 0 159 [UserRank] => 160 [SeriesSeason] => 161 [SeriesEpisode] => 162 [MovieKind] => movie 163 [QueryParameters] => Array 164 ( 165 [sublanguageid] => all 166 [moviehash] => d745cd88e9798509 167 [moviebytesize] => 734058496 168 ) 169 170 [QueryNumber] => 0 171 [SubDownloadLink] => http://dl.opensubtitles.local/en/download/filead/1118.gz 172 [ZipDownloadLink] => http://dl.opensubtitles.local/en/download/subad/905 173 [SubtitlesLink] => http://www.opensubtitles.local/en/subtitles/905/al-sur-de-granada-es 150 174 ) 151 175 152 176 [1] => Array 153 (154 [MatchedBy] => moviehash155 [IDSubMovieFile] => 82182156 [MovieHash] => 09a2c497663259cb157 [MovieByteSize] => 733589504158 [MovieTimeMS] => 3165000159 [IDSubtitleFile] => 1951690122160 [SubFileName] => Night.Watch.2004.CD1.DVDRiP.XViD-FiCO.srt161 [SubActualCD] => 1162 [SubSize] => 27287163 [SubHash] => fe106fe2368799bdc73271bb24ac6df7164 [IDSubtitle] => 3144302165 [UserID] => 367123166 [SubLanguageID] => dut167 [SubFormat] => srt168 [SubSumCD] => 2169 [SubAuthorComment] =>170 [SubAddDate] => 2007-08-31 22:23:39171 [SubBad] => 0172 [SubRating] => 0.0173 [SubDownloadsCnt] => 89174 [MovieReleaseName] => Night Watch175 [IDMovie] => 516176 [IDMovieImdb] => 403358177 [MovieName] => Nochnoy dozor178 [MovieNameEng] => Night Watch179 [MovieYear] => 2004180 [MovieImdbRating] => 0.0181 [UserNickName] => gyoom182 [ISO639] => nl183 [LanguageName] => Dutch184 [SubComments] => 0185 [SubDownloadLink] => http://www.opensubtitles.org/en/download/file/1951690122.gz186 [ZipDownloadLink] => http://www.opensubtitles.org/en/download/sub/3144302187 [SubtitlesLink] => http://www.opensubtitles.net/en/subtitles/3144302/nochnoy-dozor-nl188 )189 177 ... 190 178 }}} 191 179 192 180 '''Fields explanation:''' 193 All field are self-explained. 181 QueryNumber is array number in queries sent, starts from 0. 182 Other: All field are self-explained. 194 183 195 184 ---- … … 249 238 [MovieName] => Planet of the Apes 250 239 [MovieYear] => 2001 251 ) 240 [MovieKind] => movie 241 [SeriesSeason] => 242 [SeriesEpisode] => 243 ) 252 244 253 245 [ae34f157eefc093c] => Array … … 257 249 [MovieName] => Ghost Ship 258 250 [MovieYear] => 2002 251 [MovieKind] => movie 252 [SeriesSeason] => 253 [SeriesEpisode] => 259 254 ) 260 255 … … 280 275 '''array CheckMovieHash2( $token, array($moviehash, $moviehash, ...) )''' 281 276 282 This method returns matching !MovieImdbID, !MovieName, !MovieYear, if available for each $moviehash, always sorted by !SeenCount DESC. Read more about [wiki:MovieIdentification Movie Identification].277 This method returns matching !MovieImdbID, !MovieName, !MovieYear, !SeriesSeason, !SeriesEpisode, !MovieKind if available for each $moviehash, always sorted by !SeenCount DESC. Read more about [wiki:MovieIdentification Movie Identification]. 283 278 284 279 Example output: … … 294 289 [MovieImdbID] => 103644 295 290 [MovieName] => Alien³ 291 [MovieKind] => movie 292 [SeriesSeason] => 293 [SeriesEpisode] => 296 294 [MovieYear] => 1992 297 295 [SeenCount] => 48 … … 303 301 [MovieImdbID] => 133093 304 302 [MovieName] => The Matrix 303 [MovieKind] => movie 304 [SeriesSeason] => 305 [SeriesEpisode] => 305 306 [MovieYear] => 1999 306 307 [SeenCount] => 5 … … 314 315 ( 315 316 [MovieHash] => 53fc6fe84ad5ee31 316 [MovieImdbID] => 813715317 [MovieName] => "Heroes"317 [MovieImdbID] => 0813715 318 [MovieName] => Heroes 318 319 [MovieYear] => 2006 320 [MovieKind] => tv series 321 [SeriesSeason] => 322 [SeriesEpisode] => 319 323 [SeenCount] => 427 320 324 ) … … 324 328 [MovieHash] => 53fc6fe84ad5ee31 325 329 [MovieImdbID] => 1185913 326 [MovieName] => "Heroes" One of Us, One of Them330 [MovieName] => "Heroes" Chapter Three 'One of Us, One of Them' 327 331 [MovieYear] => 2008 332 [MovieKind] => episode 333 [SeriesSeason] => 3 334 [SeriesEpisode] => 3 328 335 [SeenCount] => 260 329 336 ) 330 331 337 ) 332 338 ...