Z9.Flex.Community
1.0.1
dotnet add package Z9.Flex.Community --version 1.0.1
NuGet\Install-Package Z9.Flex.Community -Version 1.0.1
<PackageReference Include="Z9.Flex.Community" Version="1.0.1" />
<PackageVersion Include="Z9.Flex.Community" Version="1.0.1" />
<PackageReference Include="Z9.Flex.Community" />
paket add Z9.Flex.Community --version 1.0.1
#r "nuget: Z9.Flex.Community, 1.0.1"
#:package Z9.Flex.Community@1.0.1
#addin nuget:?package=Z9.Flex.Community&version=1.0.1
#tool nuget:?package=Z9.Flex.Community&version=1.0.1
Z9/Flex Community Profile
This repository contains the OpenAPI specification for the Z9/Flex JSON/REST API - Community Profile.
Overview
The Community Profile is a profile of Z9 Security's Z9/Flex API, designed to be the interface and data model for an open, interoperable access control platform.
See Also
- Z9/Open Community Profile - Google Protobuf specification for the Z9/Open binary protocol Community Profile
Z9/Flex and Z9/Open
For more information about the commercial version of Z9/Flex, visit z9flex.com.
For more information about the commercial version of Z9/Open, visit z9open.com.
Z9/FL=X is a registered trademark of Z9 Security. z9/op=n is a registered certification mark of Z9 Security.
License
Apache 2.0 - see LICENSE for details.
Files
z9flex-swagger-community.yaml- OpenAPI 3.0 specificationz9flex-client-csharp/- C#/.NET client library
Usage
The swagger file can be used with OpenAPI tools to generate client libraries in various languages.
C# Client Library
The z9flex-client-csharp/ directory contains a C#/.NET client library (Z9.Flex.Community) for the Z9/Flex Community Profile API. It is built using Microsoft Kiota to auto-generate a strongly-typed REST client from the OpenAPI specification.
The library targets .NET Standard 2.0, making it compatible with .NET Framework 4.7+, .NET Core 2.0+, and .NET 6+.
Getting Started
Create an authentication provider and adapter, then use the client to make API calls:
var handler = new WinHttpHandler
{
ServerCertificateValidationCallback = (message, certificate2, arg3, arg4) => true
};
var authenticationProvider = Z9AuthenticationProvider.CreateInstance(baseUrl,
() => (username: z9Username, password: z9Password), handler);
var adapter = new HttpClientRequestAdapter(authenticationProvider,
httpClient: new Z9HttpClient(handler, authenticationProvider))
{ BaseUrl = baseUrl };
var flexClient = new Z9Flex.Client.FlexClient(adapter);
Then use the client to interact with the API:
var devices = await flexClient.Dev.List.GetAsync();
var schedules = await flexClient.Sched.List.GetAsync();
Regenerating the Client
The auto-generated client code can be regenerated from the swagger using Microsoft Kiota:
dotnet tool install --global Microsoft.OpenApi.Kiota
kiota generate -l CSharp -c FlexClient -n Z9Flex.Client \
-d z9flex-swagger-community.yaml \
-o z9flex-client-csharp/src/Z9Flex/Client
After generation, apply the following post-processing fix to the generated models. Kiota generates unqualified Time? references that conflict with System.Time, so they must be fully qualified:
In z9flex-client-csharp/src/Z9Flex/Client/Models/SchedElement.cs, replace:
public Time? Start { get; set; }
public Time? Stop { get; set; }
with:
public Microsoft.Kiota.Abstractions.Time? Start { get; set; }
public Microsoft.Kiota.Abstractions.Time? Stop { get; set; }
Publishing to NuGet
Pushing a version tag triggers the CI pipeline to build and publish the Z9.Flex.Community package to nuget.org:
Find the latest version and tag the next:
git tag --sort=-v:refname | head -1
git tag v1.0.1
git push origin v1.0.1
Note: This requires a NUGET_API_KEY secret configured in the repository's GitHub Actions settings.
Verify the package is published:
curl -s https://api.nuget.org/v3-flatcontainer/z9.flex.community/index.json
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
| .NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
| .NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
| MonoAndroid | monoandroid was computed. |
| MonoMac | monomac was computed. |
| MonoTouch | monotouch was computed. |
| Tizen | tizen40 was computed. tizen60 was computed. |
| Xamarin.iOS | xamarinios was computed. |
| Xamarin.Mac | xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.0
- Microsoft.Kiota.Abstractions (>= 1.16.3)
- Microsoft.Kiota.Http.HttpClientLibrary (>= 1.16.3)
- Microsoft.Kiota.Serialization.Form (>= 1.16.3)
- Microsoft.Kiota.Serialization.Json (>= 1.16.3)
- Microsoft.Kiota.Serialization.Multipart (>= 1.16.3)
- Microsoft.Kiota.Serialization.Text (>= 1.16.3)
- System.Net.Http.WinHttpHandler (>= 9.0.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.0.1 | 133 | 2/22/2026 |