Skip to content
A Java API Client for the HomeSeer JSON API
Java
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src
.gitignore
.travis.yml
LICENSE
README.md
pom.xml

README.md

Travis Codacy Badge

HomeSeer Java Client

A Java client for the HomeSeer JSON API.

The client was built based on this documentation and tested against HS3 Pro (SEL) Edition 3.0.0.548

License

hsclient is distributed under the BSD 3-Clause License.

Maven coordinates

<dependency>
   <groupId>com.khubla.hsclient</groupId>
   <artifactId>hsclient</artifactId>
   <version>1.1.0</version>
</dependency>

Usage

Simply instantiate an HSClient and call the API methods

To get all Devices:

final HSClient hsClient = new HSClientImpl(URL, USERNAME, PASSWORD);
try {
   final Map<Integer, Device> allDevices = hsClient.getDevicesByRef();
} finally {
   hsClient.close();
}

To get all Events:

final HSClient hsClient = new HSClientImpl(URL, USERNAME, PASSWORD);
try {
   final Map<Integer, Event> allEvents = hsClient.getEventsById();
} finally {
   hsClient.close();
}

To get a single Device:

final HSClient hsClient = new HSClientImpl(URL, USERNAME, PASSWORD);
try {
   final Device device = hsClient.getDevice(DEVICEREF);
} finally {
   hsClient.close();
}
You can’t perform that action at this time.