Page 1 of 1

Upload parameters (XML-RPC)

Posted: Tue Aug 03, 2021 4:56 pm
by kisjoke91
Hei guys,

I did begin to work on the upload feature of my app, and the rpc api documentation is very clear, however i have a question.
It seems, i need to have a movie file loaded in my software in order to get the movie hash, the file size of the movie and so.
In my understanding without this arguments used in TryUploadSubtitles or UploadSubtitles, i am unable to upload any subtitle file to the sites database. Is it right? Is there any way to upload only the srt file? Because i am sure, there are some peoples, they are just translating a subtitle as it is, without modifying on the timing of the frames, and in this use case there is not necessarily needed a video file.

Re: Upload parameters (XML-RPC)

Posted: Wed Aug 04, 2021 10:28 am
by oss
it is undocumented, but you can try without those parameters aswell

Re: Upload parameters (XML-RPC)

Posted: Wed Aug 04, 2021 2:13 pm
by kisjoke91
Ah cool, I'll try it. Thanks.

Re: Upload parameters (XML-RPC)

Posted: Fri Aug 13, 2021 3:50 pm
by kisjoke91
Hello, i am again.

So the TryUploadSubtitles method works, but if i want to upload the subtitle with the UploadSubtitles method, i get this server response:

Code: Select all

<null> <!-- date: August 13, 2021, 3:25 pm query: SELECT IDSubtitle, SubFileName, MovieID, c.MovieName, MovieReleaseName, SubAdminCheck from subs_subtitle a left join subs_subtitle_file b on a.IDSubtitle = b.SubtitleID left join subs_movie c on a.MovieID = c.IDMovie WHERE 1=1 AND SubEnabled = 1 AND SubActualCD = 1 AND IDSubtitle = ORDER BY IDSubtitle host: api.opensubtitles.org (172.20.100.1) / /xml-rpc error: 1064: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'ORDER BY IDSubtitle' at line 9 --> Requested page is temporarily unavailable, please try again later.
It seems, my query is messing up the SQL query.
What am i doing wrong?

Re: Upload parameters (XML-RPC)

Posted: Fri Aug 13, 2021 6:50 pm
by oss
Hi,

send me the XML REQUEST body (xml), so I can debug better, thanks.

Re: Upload parameters (XML-RPC)

Posted: Sat Aug 14, 2021 2:50 pm
by kisjoke91
Hi,

send me the XML REQUEST body (xml), so I can debug better, thanks.
Here is the assemled XML structure https://pastebin.com/hj8085kg

Edit: I checked the enhanced doc of the RPC method, and the structure of the input example is different, maybe thats all.

Re: Upload parameters (XML-RPC)

Posted: Sat Aug 14, 2021 6:48 pm
by oss
yeah, try to change according enhanced version...try again, should work