[mythtv] Services API: Does Dvr/AddRecordSchedule work?

John P Poet jppoet at gmail.com
Sat Oct 13 00:49:44 UTC 2018


I see AddRecordSchedule here
https://www.mythtv.org/wiki/API_parameters_29#Dvr_service but when I try to
use it, I am getting a 500 response.  Is this not working, or am I not
calling it correctly?

I am calling it from python:

    endpoint = 'Dvr/AddRecordSchedule'
    post = recrule.asDict()
    opt = {'wrmi':True}

    try:
        resp_dict = backend.send(endpoint=endpoint, postdata=post, opts=opt)
    except RuntimeError as error:
        sys.exit('\nFatal error: "{}"'.format(error))
    except RuntimeWarning as warning:
        print('Warning: {}'.format(warning))

recrule is a classed derived from a named tuple with the various arguments
in it, for example: ChanId, Title, Subtitle, etc.

I admit to not having a lot of python experience, but this seems pretty
straight forward.  I just want to verify that the Dvr/AddRecordSchedule is
supposed to be working, before I waste a lot of time debugging this code.
Various other Services API calls are working perfectly.

Thanks,

John
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mythtv.org/pipermail/mythtv-dev/attachments/20181012/a1888cf2/attachment.html>


More information about the mythtv-dev mailing list