Help with VMS 6.1 REST Analytics Integration: Service Requirements and Deletion Issues

New

Comments

4 comments

  • Avatar
    Jose M Martinez
    0
    Comment actions Permalink
  • Avatar
    Nikita

    Hello!

    First of all, thank you for trying out our beta functionality and sharing your feedback!

    To address your questions:

    1. Deleting an Integration Request
      The "Delete Integration Request" option is for scenarios where you don’t want to approve an integration and would like to remove the request from the Integrations window. Once an integration is approved, there is no longer a request to delete.
      If your intention is to remove an already approved integration, you can do so by using the following endpoint:
      DELETE /rest/v4/analytics/integrations/{id}

    2. Services error
      I see that you’ve provided the engine manifest and device agent manifest. However, could you, please, show the integration manifest? We recently introduced support for integrations that rely on SaaS services, and this error appears when an integration requests a service it needs to operate.

    Let me know if this helps or if you need further clarification!

    0
    Comment actions Permalink
  • Avatar
    Jose M Martinez

    Thank you for the clarification about integration deletion.

    I want to better explain our goal: We are trying to implement something similar to the api/createEvent endpoint but with additional visualization capabilities. Specifically:

    1. We want to send events that include bounding boxes to visualize them over the video
    2. For this, we are trying to use the endpoint /rest/v4/analytics/engines/{id}/deviceAgents/{deviceId}/metadata/object

    Our main question is about the correct sequence of steps to achieve this. What would be the complete flow from integration creation to being able to send events with bounding boxes that are visualized over a specific device?

    Currently, we have:

    1. Created the integration (REST-only)
    2. Approved the integration
    3. Tried to activate it on a device

    But we encounter the integration service error. Could you provide us with the correct sequence of steps and endpoints needed to achieve this goal?

    Thank you in advance.

    0
    Comment actions Permalink
  • Avatar
    Nikita

    The correct way to create a REST-only integration is:

    1. Send a request for approval, providing an Integration and an Engine manifests. If the Integration is planned to be REST-only, the Integration manifest must have isRestOnly flag set to true, also, Device Agent manifest must be provided along with two others.
    2. Approve the Integration. In general scenario, the administrator of the system will need to approve it in the UI with pin-code, provided by Integration.
    3. Integration must understand that it was approved before operating. For REST-only Integration this might be done by polling GET ​/rest​/v4​/users​/{username}, for the Integration's user. There's a parameters section, if approved, this section will contain "isApproved" flag equal to true, also, integration ID can be found there for convenience.
    4. After that, Integration can authorize with this user, get engine id at GET /rest/v4/analytics/engines?integrationId=<your_integration_id> and poll for device agents at GET /rest/v4/analytics/engines/{engine_id}/deviceAgents
    5. When user activate integration in the device settings, there would be deviceAgents in the response from #4
    6. After that you can get stream for the device, analyze it and send metadata for this device.

    The error about services you get may occur if you included "isLicenseRequired" in the Integration manifest, telling the server that it must obtain service license from the Cloud.

    Hope that helps!

     

    0
    Comment actions Permalink

Please sign in to leave a comment.