Skip to content

DobissSharp is a .NET wrapper for the domotics system Dobiss NXT

License

Notifications You must be signed in to change notification settings

MichelMichels/DobissSharp

Repository files navigation

DobissSharp 📦

DobissSharp is a C# .NET wrapper for the domotics system Dobiss NXT. It contains a REST api wrapper (MichelMichels.DobissSharp.Api) and an opiniated C# library which consumes previous wrapper (MichelMichels.DobissSharp).

Table of Contents

Prerequisites

Installation

Warning

Package MichelMichels.DobissSharp is in development and is subject to breaking changes. Use this at own risk.

Package name Version Description
MichelMichels.DobissSharp.Api NuGet Version Reference implementation of the REST API
MichelMichels.DobissSharp NuGet Version Opiniated C# class library

Get the NuGet packages from nuget.org or search for MichelMichels.DobissSharp in the GUI package manager in Visual Studio.

You can also use the cli of the package manager with following command:

Install-Package MichelMichels.DobissSharp.Api
Install-Package MichelMichels.DobissSharp

Usage

MichelMichels.DobissSharp.Api

Creating the API client:

DobissClientOptions options = new()
{
    BaseUrl = @"http://dobiss.local/",
    SecretKey = "your-secret-api-key",
};
DobissClient apiClient = new(options);

Calls:

// Discover
DiscoverResponse response = await apiClient.Discover();

// Status
StatusResponse response = await apiClient.Status();

// Action
ActionRequest body = new()
{
    AddressId = 0,
    ChannelId = 12,
    ActionId = ActionId.Toggle,
};
ActionResponse response = await apiClient.Action(body);

MichelMichels.DobissSharp

Creating the service:

// See previous code example for creating the API client
DobissService dobiss = new(apiClient);

See the interface IDobissService for more information. This is still in development and subject to breaking changes.

Documentation

Visit the API documentation page of Dobiss NXT for more in-depth information about the API.

Credits

About

DobissSharp is a .NET wrapper for the domotics system Dobiss NXT

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages