mirror of
https://github.com/pomerium/pomerium.git
synced 2025-04-29 10:26:29 +02:00
* initial core-zero import implementation * Update /config/import openapi description and use PUT instead of POST * update import ui tests * Add 413 as a possible response for /config/import * Options/Settings type conversion tests and related bugfixes * Fixes for proto type conversion and tests * Update core-zero import client * Update core-zero import client * Update import api and environment detection * update go.mod * remove old testdata * Remove usage of deleted setting after merge * remove extra newline from --version output
136 lines
4.3 KiB
Go
136 lines
4.3 KiB
Go
// Package cluster provides primitives to interact with the openapi HTTP API.
|
|
//
|
|
// Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.3.0 DO NOT EDIT.
|
|
package cluster
|
|
|
|
import (
|
|
"time"
|
|
)
|
|
|
|
const (
|
|
BearerAuthScopes = "bearerAuth.Scopes"
|
|
)
|
|
|
|
// Defines values for BundleStatusFailureSource.
|
|
const (
|
|
DatabrokerError BundleStatusFailureSource = "databroker_error"
|
|
DownloadError BundleStatusFailureSource = "download_error"
|
|
InvalidBundle BundleStatusFailureSource = "invalid_bundle"
|
|
IoError BundleStatusFailureSource = "io_error"
|
|
UnknownError BundleStatusFailureSource = "unknown_error"
|
|
)
|
|
|
|
// BootstrapConfig defines model for BootstrapConfig.
|
|
type BootstrapConfig struct {
|
|
ClusterId string `json:"clusterId"`
|
|
|
|
// DatabrokerStorageConnection databroker storage connection string
|
|
DatabrokerStorageConnection *string `json:"databrokerStorageConnection,omitempty"`
|
|
OrganizationId string `json:"organizationId"`
|
|
PseudonymizationKey []byte `json:"pseudonymizationKey"`
|
|
|
|
// SharedSecret shared secret
|
|
SharedSecret []byte `json:"sharedSecret"`
|
|
}
|
|
|
|
// Bundle defines model for Bundle.
|
|
type Bundle struct {
|
|
// Id bundle id
|
|
Id string `json:"id"`
|
|
}
|
|
|
|
// BundleStatus defines model for BundleStatus.
|
|
type BundleStatus struct {
|
|
Failure *BundleStatusFailure `json:"failure,omitempty"`
|
|
Success *BundleStatusSuccess `json:"success,omitempty"`
|
|
}
|
|
|
|
// BundleStatusFailure defines model for BundleStatusFailure.
|
|
type BundleStatusFailure struct {
|
|
Message string `json:"message"`
|
|
|
|
// Source source of the failure
|
|
Source BundleStatusFailureSource `json:"source"`
|
|
}
|
|
|
|
// BundleStatusFailureSource source of the failure
|
|
type BundleStatusFailureSource string
|
|
|
|
// BundleStatusSuccess defines model for BundleStatusSuccess.
|
|
type BundleStatusSuccess struct {
|
|
// Metadata bundle metadata
|
|
Metadata map[string]string `json:"metadata"`
|
|
}
|
|
|
|
// DownloadBundleResponse defines model for DownloadBundleResponse.
|
|
type DownloadBundleResponse struct {
|
|
// CaptureMetadataHeaders bundle metadata that need be picked up by the client from the download URL
|
|
CaptureMetadataHeaders []string `json:"captureMetadataHeaders"`
|
|
ExpiresInSeconds string `json:"expiresInSeconds"`
|
|
|
|
// Url download URL
|
|
Url string `json:"url"`
|
|
}
|
|
|
|
// ErrorResponse defines model for ErrorResponse.
|
|
type ErrorResponse struct {
|
|
// Error Error message
|
|
Error string `json:"error"`
|
|
}
|
|
|
|
// ExchangeTokenRequest defines model for ExchangeTokenRequest.
|
|
type ExchangeTokenRequest struct {
|
|
// RefreshToken cluster identity token
|
|
RefreshToken string `json:"refreshToken"`
|
|
}
|
|
|
|
// ExchangeTokenResponse defines model for ExchangeTokenResponse.
|
|
type ExchangeTokenResponse struct {
|
|
ExpiresInSeconds string `json:"expiresInSeconds"`
|
|
|
|
// IdToken ID token
|
|
IdToken string `json:"idToken"`
|
|
}
|
|
|
|
// GetBootstrapConfigResponse defines model for GetBootstrapConfigResponse.
|
|
type GetBootstrapConfigResponse = BootstrapConfig
|
|
|
|
// GetBundlesResponse defines model for GetBundlesResponse.
|
|
type GetBundlesResponse struct {
|
|
Bundles []Bundle `json:"bundles"`
|
|
}
|
|
|
|
// ImportResponse defines model for ImportResponse.
|
|
type ImportResponse struct {
|
|
Messages *[]string `json:"messages,omitempty"`
|
|
Warnings *[]string `json:"warnings,omitempty"`
|
|
}
|
|
|
|
// ReportUsageRequest defines model for ReportUsageRequest.
|
|
type ReportUsageRequest struct {
|
|
Users []ReportUsageUser `json:"users"`
|
|
}
|
|
|
|
// ReportUsageUser defines model for ReportUsageUser.
|
|
type ReportUsageUser struct {
|
|
LastSignedInAt time.Time `json:"lastSignedInAt"`
|
|
PseudonymousEmail string `json:"pseudonymousEmail"`
|
|
PseudonymousId string `json:"pseudonymousId"`
|
|
}
|
|
|
|
// BundleId defines model for bundleId.
|
|
type BundleId = string
|
|
|
|
// ImportConfigurationParams defines parameters for ImportConfiguration.
|
|
type ImportConfigurationParams struct {
|
|
XImportHints *[]string `json:"X-Import-Hints,omitempty"`
|
|
}
|
|
|
|
// ReportClusterResourceBundleStatusJSONRequestBody defines body for ReportClusterResourceBundleStatus for application/json ContentType.
|
|
type ReportClusterResourceBundleStatusJSONRequestBody = BundleStatus
|
|
|
|
// ExchangeClusterIdentityTokenJSONRequestBody defines body for ExchangeClusterIdentityToken for application/json ContentType.
|
|
type ExchangeClusterIdentityTokenJSONRequestBody = ExchangeTokenRequest
|
|
|
|
// ReportUsageJSONRequestBody defines body for ReportUsage for application/json ContentType.
|
|
type ReportUsageJSONRequestBody = ReportUsageRequest
|