I’m trying to call StartStopRecording through the WebAPI using the following url
http://ip:8124/Json/StartStopRecording?sourceId=0&enabled=1&authToken=2 using both
curl and the python
requests library but get a cast exception error returned to me. I’ve verified I can call GetCameras and get a valid response to make sure my authkey wasn’t the problem and I’ve also tried calling StartStopRecording without enabled and/or sourceId and get an
Access Denied message as expected as it’s not a complete path. Here’s the message:
<p>The server encountered an error processing the request. The exception message is 'Specified cast is not valid.'. See server logs for more details. The exception stack trace is: </p> <p> at SyncInvokeStartStopRecording(Object , Object , Object ) at System.ServiceModel.Dispatcher.SyncMethodInvoker.Invoke(Object instance, Object inputs, Object& outputs) at System.ServiceModel.Dispatcher.DispatchOperationRuntime.InvokeBegin(MessageRpc& rpc) at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage5(MessageRpc& rpc) at System.ServiceModel.Dispatcher.MessageRpc.Process(Boolean isOperationContextSet)</p>``` Any ideas would be greatly appreciated as this was working for a few months and has suddenly stopped.