OpenAPI-generated Go client for the someones.computer /api surface
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-09-07 08:33:53 +00:00
.github/workflows Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
.openapi-generator Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
api Regenerate from the current someones.computer OpenAPI spec 2026-09-07 10:15:02 +02:00
docs Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
test Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
.gitignore Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
.openapi-generator-ignore Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
api_adoption_approval.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
api_application.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
api_credit_transaction.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
api_deployment.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
api_managed_service.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
api_organization.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
api_service_binding.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
api_swarm.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
client.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
configuration.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
go.mod go mod tidy: restore testify, dropped by the generator's own go.mod template 2026-09-07 01:16:19 +02:00
go.sum go mod tidy: restore testify, dropped by the generator's own go.mod template 2026-09-07 01:16:19 +02:00
LICENSE Initial commit 2026-09-05 18:52:14 +00:00
model_adoption_approval.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_adoption_approval_adoption_approval_input.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_application.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
model_application_json_merge_patch.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
model_bundle_additional_context_input.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
model_bundle_context_input.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
model_bundle_forwarded_image_input.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
model_bundle_upload_target.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
model_constraint_violation.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_constraint_violation_violations_inner.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_credit_transaction.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_credit_transaction_engine_millis.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_credit_transaction_usage_bytes.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_deployment.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_deployment_bundle_upload_confirm_input.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
model_deployment_bundle_upload_confirm_output.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
model_deployment_bundle_upload_declare_input.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
model_deployment_bundle_upload_declare_output.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
model_deployment_deployment_endpoint.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
model_deployment_json_merge_patch.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_deployment_json_merge_patch_build_contexts_value_value.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_deployment_json_merge_patch_canonical_spec_value.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_deployment_variable.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_error.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_failure.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_machine.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_managed_service.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_managed_service_last_load_millis.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_managed_service_managed_service_input.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_managed_service_pending_load_millis.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_managed_service_quota_bytes.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_managed_service_usage_bytes.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_membership.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_o_auth_identity.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_organization.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_organization_json_merge_patch.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_organization_signal.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_port_allocation.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_proxmox_instance.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_recovery_code.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_sealed_secret.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_service.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_service_binding.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_service_binding_service_binding_input.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_service_cpu_limit.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_service_cpu_reservation.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_service_healthcheck_value.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_service_instance.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
model_service_instance_capacity_bytes.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_service_instance_observed_usage_bytes.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_service_mem_limit.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_service_mem_reservation.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_service_ports_inner_value.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_swarm.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_swarm_json_merge_patch.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_swarm_node.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_user.go Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
model_user_avatar_photo.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_variable.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
model_variable_version.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
README.md Regenerate from the current someones.computer OpenAPI spec 2026-09-07 01:12:36 +02:00
response.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00
utils.go Generate Go SDK from the someones.computer OpenAPI spec 2026-09-05 20:16:53 +01:00

Go API client for someonescomputer

JSON-LD resources backing the control panel. Bearer-token reachable since #1418 — see docs/sdk-generation.md.

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: 1.0.0
  • Package version: 1.0.0
  • Generator version: 7.11.0
  • Build package: org.openapitools.codegen.languages.GoClientCodegen

Installation

Install the following dependencies:

go get github.com/stretchr/testify/assert
go get golang.org/x/net/context

Put the package under your project folder and add the following in import:

import someonescomputer "github.com/someones-computer/sdk-go"

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 someonescomputer.ContextServerIndex of type int.

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

Templated Server URL

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

ctx := context.WithValue(context.Background(), someonescomputer.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 someonescomputer.ContextOperationServerIndices and someonescomputer.ContextOperationServerVariables context maps.

ctx := context.WithValue(context.Background(), someonescomputer.ContextOperationServerIndices, map[string]int{
	"{classname}Service.{nickname}": 2,
})
ctx = context.WithValue(context.Background(), someonescomputer.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
AdoptionApprovalAPI ApiAdoptionApprovalsGetCollection Get /api/adoption_approvals Retrieves the collection of AdoptionApproval resources.
AdoptionApprovalAPI ApiAdoptionApprovalsIdDelete Delete /api/adoption_approvals/{id} Removes the AdoptionApproval resource.
AdoptionApprovalAPI ApiAdoptionApprovalsIdGet Get /api/adoption_approvals/{id} Retrieves a AdoptionApproval resource.
AdoptionApprovalAPI ApiAdoptionApprovalsPost Post /api/adoption_approvals Creates a AdoptionApproval resource.
ApplicationAPI ApiApplicationsGetCollection Get /api/applications Retrieves the collection of Application resources.
ApplicationAPI ApiApplicationsIdDelete Delete /api/applications/{id} Removes the Application resource.
ApplicationAPI ApiApplicationsIdGet Get /api/applications/{id} Retrieves a Application resource.
ApplicationAPI ApiApplicationsIdPatch Patch /api/applications/{id} Updates the Application resource.
ApplicationAPI ApiApplicationsPost Post /api/applications Creates a Application resource.
CreditTransactionAPI ApiCreditTransactionsGetCollection Get /api/credit_transactions Retrieves the collection of CreditTransaction resources.
CreditTransactionAPI ApiCreditTransactionsIdGet Get /api/credit_transactions/{id} Retrieves a CreditTransaction resource.
DeploymentAPI ApiDeploymentsGetCollection Get /api/deployments Retrieves the collection of Deployment resources.
DeploymentAPI ApiDeploymentsIdDelete Delete /api/deployments/{id} Removes the Deployment resource.
DeploymentAPI ApiDeploymentsIdGet Get /api/deployments/{id} Retrieves a Deployment resource.
DeploymentAPI ApiDeploymentsIdPatch Patch /api/deployments/{id} Updates the Deployment resource.
DeploymentAPI ApiDeploymentsIdendpointsGetCollection Get /api/deployments/{id}/endpoints Retrieves the collection of Deployment resources.
DeploymentAPI ApiDeploymentsPost Post /api/deployments Creates a Deployment resource.
DeploymentAPI BundleUploadConfirm Post /api/deployments/bundle_uploads/confirm Creates a Deployment resource.
DeploymentAPI BundleUploadDeclare Post /api/deployments/bundle_uploads Creates a Deployment resource.
ManagedServiceAPI ApiManagedServicesGetCollection Get /api/managed_services Retrieves the collection of ManagedService resources.
ManagedServiceAPI ApiManagedServicesIdDelete Delete /api/managed_services/{id} Removes the ManagedService resource.
ManagedServiceAPI ApiManagedServicesIdGet Get /api/managed_services/{id} Retrieves a ManagedService resource.
ManagedServiceAPI ApiManagedServicesPost Post /api/managed_services Creates a ManagedService resource.
ManagedServiceAPI Resume Post /api/managed_services/{id}/resume Creates a ManagedService resource.
ManagedServiceAPI Suspend Post /api/managed_services/{id}/suspend Creates a ManagedService resource.
OrganizationAPI ApiOrganizationsGetCollection Get /api/organizations Retrieves the collection of Organization resources.
OrganizationAPI ApiOrganizationsIdDelete Delete /api/organizations/{id} Removes the Organization resource.
OrganizationAPI ApiOrganizationsIdGet Get /api/organizations/{id} Retrieves a Organization resource.
OrganizationAPI ApiOrganizationsIdPatch Patch /api/organizations/{id} Updates the Organization resource.
OrganizationAPI ApiOrganizationsPost Post /api/organizations Creates a Organization resource.
ServiceBindingAPI ApiServiceBindingsGetCollection Get /api/service_bindings Retrieves the collection of ServiceBinding resources.
ServiceBindingAPI ApiServiceBindingsIdDelete Delete /api/service_bindings/{id} Removes the ServiceBinding resource.
ServiceBindingAPI ApiServiceBindingsIdGet Get /api/service_bindings/{id} Retrieves a ServiceBinding resource.
ServiceBindingAPI ApiServiceBindingsPost Post /api/service_bindings Creates a ServiceBinding resource.
SwarmAPI ApiSwarmsGetCollection Get /api/swarms Retrieves the collection of Swarm resources.
SwarmAPI ApiSwarmsIdDelete Delete /api/swarms/{id} Removes the Swarm resource.
SwarmAPI ApiSwarmsIdGet Get /api/swarms/{id} Retrieves a Swarm resource.
SwarmAPI ApiSwarmsIdPatch Patch /api/swarms/{id} Updates the Swarm resource.
SwarmAPI ApiSwarmsPost Post /api/swarms Creates a Swarm resource.

Documentation For Models

Documentation For Authorization

Authentication schemes defined for the API:

bearerAuth

  • Type: HTTP Bearer token authentication

Example

auth := context.WithValue(context.Background(), someonescomputer.ContextAccessToken, "BEARER_TOKEN_STRING")
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