Files
portal/openapi
2026-06-25 11:26:20 +02:00
..
2026-06-22 11:38:29 +02:00
2026-06-25 11:26:20 +02:00
2026-06-25 11:26:20 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-25 11:26:20 +02:00
2026-06-25 11:26:20 +02:00
2026-06-25 11:26:20 +02:00
2026-06-25 11:26:20 +02:00
2026-06-25 11:26:20 +02:00
2026-06-25 11:26:20 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00
2026-06-25 11:26:20 +02:00
2026-06-22 11:38:29 +02:00
2026-06-22 11:38:29 +02:00

Go API client for openapi

No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)

Overview

This API client was generated by the OpenAPI Generator project. By using the OpenAPI-spec from a remote server, you can easily generate an API client.

  • API version: 0.1.0
  • Package version: 1.0.0
  • Generator version: 7.24.0-SNAPSHOT
  • Build package: org.openapitools.codegen.languages.GoClientCodegen

Installation

Import the package in a go file in your project and run go mod tidy:

import openapi "github.com/GIT_USER_ID/GIT_REPO_ID"

To use a proxy, set the environment variable HTTP_PROXY:

os.Setenv("HTTP_PROXY", "http://proxy_name:proxy_port")

Configuration of Server URL

Default configuration comes with Servers field that contains server objects as defined in the OpenAPI specification.

Select Server Configuration

For using other server than the one defined on index 0 set context value openapi.ContextServerIndex of type int.

ctx := context.WithValue(context.Background(), openapi.ContextServerIndex, 1)

Templated Server URL

Templated server URL is formatted using default variables from configuration or from context value openapi.ContextServerVariables of type map[string]string.

ctx := context.WithValue(context.Background(), openapi.ContextServerVariables, map[string]string{
	"basePath": "v2",
})

Note, enum values are always validated and all unused variables are silently ignored.

URLs Configuration per Operation

Each operation can use different server URL defined using OperationServers map in the Configuration. An operation is uniquely identified by "{classname}Service.{nickname}" string. Similar rules for overriding default operation server index and variables applies by using openapi.ContextOperationServerIndices and openapi.ContextOperationServerVariables context maps.

ctx := context.WithValue(context.Background(), openapi.ContextOperationServerIndices, map[string]int{
	"{classname}Service.{nickname}": 2,
})
ctx = context.WithValue(context.Background(), openapi.ContextOperationServerVariables, map[string]map[string]string{
	"{classname}Service.{nickname}": {
		"port": "8443",
	},
})

Documentation for API Endpoints

All URIs are relative to http://localhost

Class Method HTTP request Description
AccessAuthAPI AddAccessauthApiV1AaPost Post /api/v1/aa/ Add Accessauth
AccessAuthAPI AssignAccessauthApiV1AaAssignGroupIdAaIdPut Put /api/v1/aa/assign/{group_id}/{aa_id} Assign Accessauth
AccessAuthAPI ChangeAccessauthApiV1AaAaIdPatch Patch /api/v1/aa/{aa_id} Change Accessauth
AccessAuthAPI DeleteAccessauthApiV1AaAaIdDelete Delete /api/v1/aa/{aa_id} Delete Accessauth
AccessAuthAPI GetAllAccessauthsApiV1AaGet Get /api/v1/aa/ Get All Accessauths
AccessAuthAPI GetOneAccessauthApiV1AaAaIdGet Get /api/v1/aa/{aa_id} Get One Accessauth
AccessAuthAPI UnassignAccessauthApiV1AaUnassignGroupIdAaIdPut Put /api/v1/aa/unassign/{group_id}/{aa_id} Unassign Accessauth
CardAPI AddCardApiV1CardsGroupIdPost Post /api/v1/cards/{group_id} Add Card
CardAPI DelCardApiV1CardsDeleteGet Get /api/v1/cards/delete Del Card
CardAPI GetCardsApiV1CardsGroupIdGet Get /api/v1/cards/{group_id} Get Cards
DebugItemsMaybeDontShowThisInUIAPI AddCardManuallyApiV1DebugAddcardGroupidCardKeyGet Get /api/v1/debug/addcard/{groupid}/{card_key} Add Card Manually
DebugItemsMaybeDontShowThisInUIAPI ListAllCardsApiV1DebugGetcardsPut Put /api/v1/debug/getcards List All Cards
DebugItemsMaybeDontShowThisInUIAPI RemoveCardManuallyApiV1DebugRmcardCardKeyGet Get /api/v1/debug/rmcard/{card_key} Remove Card Manually
DoorAPI OpenDoorApiV1DoorClosePut Put /api/v1/door/close Open Door
DoorAPI OpenDoorApiV1DoorOpenPut Put /api/v1/door/open Open Door
DoorAPI TestAccessApiV1DoorTestPost Post /api/v1/door/test Test Access
GroupAPI CreateGroupApiV1GroupsPost Post /api/v1/groups/ Create Group
GroupAPI DeleteGroupApiV1GroupsGroupIdDelete Delete /api/v1/groups/{group_id} Delete Group
GroupAPI GetGroupsApiV1GroupsGet Get /api/v1/groups/ Get Groups
TokenAPI LoginForAccessTokenApiV1TokenPost Post /api/v1/token Login For Access Token
TokenAPI TestLoginApiV1TestLoginGet Get /api/v1/test/login Test Login
UsersAPI CreateUserApiV1UsersPost Post /api/v1/users/ Create User
UsersAPI DeleteUserApiV1UsersUserIdDelete Delete /api/v1/users/{user_id} Delete User
UsersAPI GetCurrentUserApiV1UsersCurrentGet Get /api/v1/users/current Get Current User
UsersAPI ReadUserApiV1UsersUserIdGet Get /api/v1/users/{user_id} Read User
UsersAPI ReadUsersApiV1UsersGet Get /api/v1/users/ Read Users
UsersAPI UpdateUserApiV1UsersUserIdPatch Patch /api/v1/users/{user_id} Update User

Documentation For Models

Documentation For Authorization

Authentication schemes defined for the API:

OAuth2PasswordBearer

  • Type: OAuth
  • Flow: password
  • Authorization URL:
  • Scopes: N/A

Example

auth := context.WithValue(context.Background(), openapi.ContextAccessToken, "ACCESSTOKENSTRING")
r, err := client.Service.Operation(auth, args)

Or via OAuth2 module to automatically refresh tokens and perform user authentication.

import "golang.org/x/oauth2"

/* Perform OAuth2 round trip request and obtain a token */

tokenSource := oauth2cfg.TokenSource(createContext(httpClient), &token)
auth := context.WithValue(oauth2.NoContext, openapi.ContextOAuth2, tokenSource)
r, err := client.Service.Operation(auth, args)

Documentation for Utility Methods

Due to the fact that model structure members are all pointers, this package contains a number of utility functions to easily obtain pointers to values of basic types. Each of these functions takes a value of the given basic type and returns a pointer to it:

  • PtrBool
  • PtrInt
  • PtrInt32
  • PtrInt64
  • PtrFloat
  • PtrFloat32
  • PtrFloat64
  • PtrString
  • PtrTime

Author