All Projects → loozhengyuan → hikvision-sdk

loozhengyuan / hikvision-sdk

Licence: GPL-3.0 license
海康威视 Hikvision SDK for Intelligence Security API (ISAPI).

Programming Languages

go
31211 projects - #10 most used programming language
Makefile
30231 projects
shell
77523 projects

Projects that are alternatives of or similar to hikvision-sdk

hikvision-tftpd
Unbrick a Hikvision device (NVR or camera) via TFTP
Stars: ✭ 82 (+43.86%)
Mutual labels:  hikvision
alarmserver
IP Camera Alarm Server to MQTT
Stars: ✭ 73 (+28.07%)
Mutual labels:  hikvision
hikvision-recover
Command-line tool for generating recovery codes for Hikvision IP Cameras
Stars: ✭ 40 (-29.82%)
Mutual labels:  hikvision
hikvision-client
Client for Hikvision devices
Stars: ✭ 159 (+178.95%)
Mutual labels:  hikvision
pyhikvision
hikvision-sdk for Python3 in action
Stars: ✭ 141 (+147.37%)
Mutual labels:  hikvision
hikstract
Extracts videos recorded by Hikvision IP camera
Stars: ✭ 27 (-52.63%)
Mutual labels:  hikvision

Hikvision ISAPI Go SDK

PkgGoDev Go Report Card ci

Important: This package is still under heavy development, only a partial implementation of the API is available.

Hikvision Go SDK for Intelligence Security API (ISAPI).

This implementation is heavily dependent on the ISAPI Core Protocol. The latest available copy of this specification document was updated on Sep 2019.

Installation

To install the SDK, use go get to fetch the latest version:

go get -u github.com/loozhengyuan/hikvision-sdk/hikvision

Once installed, you may import it directly into your Go application:

import "github.com/loozhengyuan/hikvision-sdk/hikvision"

Usage

package main

import (
	"fmt"

	"github.com/loozhengyuan/hikvision-sdk/hikvision"
)

func main() {
	// Create client object
	c, err := hikvision.NewClient(
		"YOUR_SERVER_HOST",
		"YOUR_SERVER_USERNAME",
		"YOUR_SERVER_PASSWORD",
	)
	if err != nil {
		fmt.Printf("error: %v\n", err)
	}

	// Send request
	d, err := c.GetDeviceInfo()
	if err != nil {
		fmt.Printf("error: %v\n", err)
	}
	fmt.Printf("%+v\n", d)

	// Print device information
	fmt.Printf("Model: %s\n", d.Model)
	fmt.Printf("Serial Number: %s\n", d.SerialNumber)
}

Contributing

There's still lots of work to be done! Only a small subset of the APIs are implemented, so pull requests are welcome.

License

GPL-3.0

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].