Portier video Hikvision

Non pas testé, j’aimerai bien mais je ne vois pas comment faire !

Cest dans le premier post (mis à jour) de @pergolafabio à cette adresse:

Merci, j’avais vu mais je ne vois pas ou et comment exécuter la commande curl ?

Très intéressant tout ça :slight_smile:. Great Job @pergolafabio :+1:. J’avais pas pensé a analyser la communication hik connect (j’aurais préférer ne pas dépendre du cloud mais bon).

Pour executer curl dans jeedom il faut utiliser le plugin script :

  • pour déclencher l’ouverture de la porte :
    curl -i --digest -u admin:xxx -X PUT -d '<RemoteControlDoor><cmd>open</cmd></RemoteControlDoor>' http://192.168.0.xx/ISAPI/AccessControl/RemoteControl/door/1

  • pour détecter l’appuie sur la sonnette
    Il faudra utiliser un scénario exécuté toutes les X secondes l’un des deux scripts suivant et vérifier le statut de l’appel :

    • méthode locale (non fonctionnel avec le firmware actuel)
      curl -i --digest -u admin:xxx http://192.168.x.x/ISAPI/VideoIntercom/callStatus?format=json

    • méthode hikconnect (nécessite de configurer le hikconnect)
      curl --header "sessionId: SXXX" "https://apiieu.hik-connect.com/v3/devconfig/v1/call/QXXXXXXXX/status"
      avec SXXX un identifiant de session a récupérer régulièrement via une autre commande curl
      et QXXX le numéro de série de l’équipement

Je vais essayer de trouver un peu de temps pour tester tout ça.

2 « J'aime »

no problem
normally an custom firmware for 8003 owners should be released soon, that allows to retrieve the callstatus…

btw, i got an android update on hikconnect, version .15 , now it seems i dont receive push notifications anymore when someone pressed the doorbell ? do you guys notice this too ?

1 « J'aime »

This is not the version V2.2.45 recently posted on the UK portal ?
HIKVISION UK PORTAL (hikvisioneurope.com)

For the android app, I don’t have done the update as I’m not at home.

L’app android m’a également demandé une mise à jour en version .15 ce matin. N’étant pas chez moi en ce moment je vais attendre un peu. Quelqu’un à fait la mise à jour ? Est ce que les notifications fonctionnent toujours lorsque quelqu’un sonne au portier ?

no, that release is not for 8003 systems, its only 8003 thats not fully compliant with ISAPI
some ISAPI command do work, like open door, but callstatus doesnt work ‹ yet ›

will be introduced in newer firmware by end of begin next month

I have updated the thread on Home Assistant forums…i received the 8003 custom firmware, that supports callstatus and also alertstream for url…

Both ISAPI document and firmware is on the other thread

2 « J'aime »

Je vais regarder si je peux intégrer ca dans le plugin Hikvision

5 « J'aime »

@lunarok :pray: :upside_down_face:

1 « J'aime »

@lunarok , i dont use Jeedom, i use Home Assistant
how do you process an JSON , thats actually an infinite stream ? it never ends, its keeps on populating data to an output

Can you show me an example script?

PS: for users
Remember, i have loaded my ds-kd8003 with the custom firmware
callstatus ISAPI was working instantly
alertstream ISAPI was working too, the url … but i saw no events, like door open or illegal badge swiped
contacted hikvision => needed to factory default
afterwards , i finally saw the events, example :

Content-Length: 314

--MIME_boundary
Content-Type: application/json; charset="UTF-8"
Content-Length: 223

{
	"ipAddress":	"192.168.0.70",
	"portNo":	80,
	"protocol":	"HTTP",
	"dateTime":	"Wed, 28 Jul 2021 20:51:56 GMT",
	"activePostCount":	1,
	"eventType":	"heartBeat",
	"eventState":	"active",
	"eventDescription":	"heartBeat"
}
--MIME_boundary
Content-Type: application/json; charset="UTF-8"
Content-Length: 354

{
	"ipAddress":	"192.168.0.70",
	"portNo":	80,
	"protocol":	"HTTP",
	"dateTime":	"Wed, 28 Jul 2021 20:52:05 GMT",
	"activePostCount":	1,
	"eventType":	"AccessControllerEvent",
	"eventState":	"active",
	"eventDescription":	"Access Controller Event",
	"AccessControllerEvent":	{
		"deviceName":	"DS-KD8003",
		"majorEventType":	5,
		"subEventType":	25
	}
}

Hi,

If I remind well, once I get this type of API and in PHP, when you call it, it’s trapping only the first answer so you can parse the message directly. Will check once I can do it.

I see that custom firmware is needed also for opening door for exemple, so really first step.
Will need to be at home to do this first step

ok, thnx in advance

custom firmware is not needed for remote open door, that works already

custom is only needed for callstatus + alertstream

remote open door is not working for my KD8003, the port 80 is not avalaible

it should be

try this command, lots of people are confirming it

curl -i --digest -u admin:xxx -X PUT -d '<RemoteControlDoor><cmd>open</cmd></RemoteControlDoor>' http://192.168.0.70/ISAPI/AccessControl/RemoteControl/door/1

Not working for me, port is closed :

image

what firmware do you have on your DS-KD8003 ? maybe you changed it?

mine is indeed open

image

firmware 2.0.8 build 200701
In network I have 4 submenu, not just 2 Basic and Advanced. But Local Network Conf, Linked Network Conf, FTP Settings, Advance

That’s indeed an older firmware, maybe time to update…
I think it’s still an 1.0 security, upgrade to the custom firmware…
Remember , you need todo a factory reset afterwards… , Also update ivms then, since the config is now webbased… Older ivms don’t support that