GetSequences command documentation - Input Parameters

Hi, I am trying to get the sequences from a specific camera.

I have looked at the documentation regarding the required input parameters for the “GetSequences” command.

https://doc.developer.milestonesys.com/mipsdkmobile/reference/protocols/mobile_command.html

This is the request:

<?xml version="1.0" encoding="utf-8"?>

<Communication xmlns:xsi=“http://www.w3.org/2001/XMLSchema-instance

xmlns:xsd="[http://www.w3.org/2001/XMLSchema](http://www.w3.org/2001/XMLSchema)">

<ConnectionId>79299342-cd44-4cae-a4c9-e1593645c4a6</ConnectionId >

<Command SequenceId="5">

    <Type>Request</Type>

    <Name>GetSequences</Name>

    <InputParams>

        <Param Name="ItemKind" Value="Camera" />

        <Param Name="ItemId" Value="11c683f9-ae6c-400f-a4b5-c9385f91c59e" />

        <Param Name="SeqType" Value="Recording" />

        <Param Name="Time" Value="1656472219357" />

        <Param Name="AfterTime" Value="1656478219357" />

        <Param Name="AfterCount" Value="1" />

    </InputParams>

</Command>

I received a response with Error code: 13, with error string: “Missing mandatory input parameter: : CameraId”

CameraId was not in the list of parameters in the documentation. I suppose this is going to be the same value in “ItemId”?

I sent the same request. adding the “CameraId” parameter with the same value as the “ItemId” parameter which is the cameraId value. But this time i received this response:

<?xml version="1.0" encoding="utf-8"?>

<Communication xmlns:xsd=“http://www.w3.org/2001/XMLSchema

xmlns:xsi="[http://www.w3.org/2001/XMLSchema-instance](http://www.w3.org/2001/XMLSchema-instance)">

<ConnectionId>692ea8b9-6c11-40c1-804b-be6c970ebc8f</ConnectionId>

<Command SequenceId="5">

    <Type>Response</Type>

    <Name>GetSequences</Name>

    <InputParams />

    <OutputParams />

    <Items />

    <Result>Error</Result>

    <ErrorCode>13</ErrorCode>

</Command>

No error string was given and it was giving the “Missing input parameter” error code. Did I miss something?

Hi Timothy,

ItemId and CameraId are (or should be) interchangeable for the “GetSequences” command.

Is it possible that in your second attempt (after providing both parameters) you forgot to provide AfterTime and AfterCount?

Can you please provide a WireShark capture so that we can investigate what’s going on?

Regards,

Nikolay

Hi Nikolay,

Thanks for the response.

Our Milestone Mobile Server is now encrypted(HTTPS) due to our integrating platform being implemented with HTTPS as well.

Due to some restrictions, I can’t change that setting. Thus, the Wireshark trace are encrypted and I’m not sure how useful it would be.

Could you provide a working sample or a sample xmlHttpRequest without using the libraries?

I understand that there are libraries provided so that I can just perform the requests through the wrappers. But due to some restrictions, it’s a little difficult to import all of the libraries directly. Thus I am performing the xmlHttpRequests manually and not through the provided libraries.

Any advice would be appreciated.

Regards,

Timothy

Hi Timothy,

Unfortunately we could not provide such a sample.

The closest thing is Wireshark trace from a test application (attached).

I’ve checked the code - you are right.

Due to a bug, CameraId is considered as a mandatory parameter.

So you have to provide it for sure.

As for others - those should be enough.

You could try to add “MinTimeBetweenSequences” with value of 0. It is not a required one in the last version, but I cannot guarantee what is the status in the version your are using.

posted a file.

posted a file.

Hi Nikolay,

Sorry for the late reply. but thank you for the responses!

The wireshark traces were useful. It helped clarify what the input parameters needed.

I think for my case, the issue were the dates(Before/After, Time/Count) and the “Time” parameters. I might’ve been putting incorrect values.

Thanks!