Bookmarks integration via HTTP request
AnsweredHow should I configure my HTTP request so that Wave associates the values we send as Tags?
This is an example of the HTTP we send ...
-
Hello Raúl,
could you please give more details on your case? Do you use generic events to trigger any action in addition to create a bookmark?
At the moment it isn’t possible to pass the value for tags for bookmark by triggering generic events. In general, you can use /ec2/bookmarks/add API call to create a bookmark without triggering generic event. Check my example below:
http://192.168.0.8:7001/ec2/bookmarks/add?guid=18c44b39-6e56-450d-81b1-4706fa058531&startTimeMs=1603977190000&durationMs=20000&name=milesight&cameraId=1612b3499-71be-4044-256f-a0be1171bdb1&tag=matricula:1112BHT,marca:Fiat,modelo:Rumbo,color:Blanco,tipo:Furgoneta
Please pay attention to guid parameter. It should be unique for each bookmark and you'll have to generate it in your code.
0 -
No, I only create generic events to create a marker every time I detect the registration of a vehicle.
I have tried the url that you have given me but it returns the following error: {"error":"1","errorString":"Missing parameter(s) or invalid parameter values"}
Could you check the url you have given me?
Thank you
0 -
Try this one :
http://192.168.0.8:7001/ec2/bookmarks/add?guid=18c44b39-6e56-450d-81b1-4706fa058533&startTimeMs=1603977190000&durationMs=20000&name=milesight&cameraId=1612b3499-71be-4044-256f-a0be1171bdb1&tag=matricula:1112BHT,marca:Fiat,modelo:Rumbo,color:Blanco,tipo:Furgoneta
It seems previous link had wrong cameraID. If you'll receive error bellow:
{"error":"3","errorString":"Can't add bookmark"}
It would mean that bookmark with provided guid already exists, so you'll have to change guid parameter in your request.
0 -
How I have to get the guid for the request?
0 -
You can use third-party modules/packages for this. For example, if you're using NodeJs, you can use UUID package - https://www.npmjs.com/package/uuid
If you need few UUIDs for manual testing, you can use an online generator tool like this - https://www.guidgenerator.com0 -
I'm trying this request: http://192.168.0.8:7001/ec2/bookmarks/add?guid=c2eadfa5-6480-418c-b86b-49998b39cbcd&startTimeMs=1603977190000&durationMs=20000&name=milesight&cameraId=612b3499-71be-4044-256f-a0be1171bdb1&marca:Fiat,modelo:Rumbo,color:Blanco,tipo:Furgoneta but it returns next error:
{"error":"1","errorString":"Missing parameter(s) or invalid parameter values"}
What parameter am I missing?
0 -
I see 'tag=' sub-string is missing at the end of the request, but it shouldn't be an issue. I've copy-pasted your example, replaced server IP and cameraId values with mine and it worked at my end. Could you please verify cameraId value at your end?
Try executing request http://192.168.0.8:7001/ec2/getCamerasEx?id=612b3499-71be-4044-256f-a0be1171bdb1 . Would it return camera's parameters?
0 -
Hello Anton,
I execute your request and in the bottom image you can see her result
0 -
Hi Raúl, would it be possible to provide me with remote access to your system via TeamViewer? I don't see what's wrong with your request as it works on my test system, so having remote access will help us to move forward. I suggest we switch to support ticket so that you'll be able to send me remote access details securely. Would it be okay for you?
0 -
Could it be that it doesn't work because I'm using Wave instead of Nx?
0 -
If you're using Wave 4.1 release or 4.1 patch it shouldn't be an issue. Which build number are you using?
0 -
I'm using Wave 4.1
0 -
That shouldn't be an issue. Would it be possible to provide me with remote access to your system via TeamViewer?
0 -
How can I send you my teamviewer or anydesk credentials?
0 -
I've opened support ticket for you, please reply with teamviewer credentials.
0 -
Did you ever get this to work I seem to have the same issue cannot make bookmark
0 -
Unfortunately, I haven't heard back from Raúl so I'm not sure if he managed to resolve the issue.
How do you create bookmark? Do you use
/ec2/bookmarks/add API call? Do you receive the error from the server or server respond with status code 200?
0 -
Hi Anton,
Sorry for not reply but I have been very busy during last month. I would like open again the support ticket because I haven't resolved the issue.
The next week I will have time for resolve the problem with you, could you tell me what day can you? And tell me, how I can send you my teamviewer credentials.0 -
Hi Raúl Colomer,
Anton is enjoying his holiday this week, but next week he should be back. I'll reopen the ticket (#24424) for you, and you can continue the conversation there with Anton Babinov.
0 -
The problem was solved. It was caused by older Wave build. At some point, duration option was renamed to durationMs and startTime to startTimeMs.
To avoid such issues, it is best to check with server's API reference at http://<server ip>:7001/static/api.xml
0
Please sign in to leave a comment.
Comments
20 comments