payloads

package
v0.16.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 6, 2025 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

View Source
const (
	RoleAdmin                      = "admin"
	RoleAdminReadOnly              = "admin_read_only"
	RoleGlobalAuditor              = "global_auditor"
	RoleOrganizationAuditor        = "organization_auditor"
	RoleOrganizationBillingManager = "organization_billing_manager"
	RoleOrganizationManager        = "organization_manager"
	RoleOrganizationUser           = "organization_user"
	RoleSpaceAuditor               = "space_auditor"
	RoleSpaceDeveloper             = "space_developer"
	RoleSpaceManager               = "space_manager"
	RoleSpaceSupporter             = "space_supporter"
)

Variables

View Source
var DefaultLifecycleConfig = config.DefaultLifecycleConfig{
	Type:            "buildpack",
	Stack:           "cflinuxfs3",
	StagingMemoryMB: 1024,
}

DefaultLifecycleConfig is overwritten by main.go

View Source
var DefaultPageSize = 50

DefaultPageSize is overwritten by main.go

Functions

This section is empty.

Types

type AppCreate

type AppCreate struct {
	Name                 string            `json:"name"`
	EnvironmentVariables map[string]string `json:"environment_variables"`
	Relationships        *AppRelationships `json:"relationships"`
	Lifecycle            *Lifecycle        `json:"lifecycle"`
	Metadata             Metadata          `json:"metadata"`
}

func (AppCreate) ToAppCreateMessage

func (p AppCreate) ToAppCreateMessage() repositories.CreateAppMessage

func (AppCreate) Validate added in v0.8.0

func (c AppCreate) Validate() error

type AppDropletsList added in v0.16.0

type AppDropletsList struct {
	GUIDs      string
	OrderBy    string
	Pagination Pagination
}

func (*AppDropletsList) DecodeFromURLValues added in v0.16.0

func (l *AppDropletsList) DecodeFromURLValues(values url.Values) error

func (*AppDropletsList) SupportedKeys added in v0.16.0

func (l *AppDropletsList) SupportedKeys() []string

func (*AppDropletsList) ToMessage added in v0.16.0

func (AppDropletsList) Validate added in v0.16.0

func (l AppDropletsList) Validate() error

type AppList

type AppList struct {
	Names         string
	GUIDs         string
	SpaceGUIDs    string
	OrderBy       string
	LabelSelector string
	Pagination    Pagination
}

func (*AppList) DecodeFromURLValues added in v0.6.0

func (a *AppList) DecodeFromURLValues(values url.Values) error

func (*AppList) SupportedKeys added in v0.2.0

func (a *AppList) SupportedKeys() []string

func (*AppList) ToMessage

func (a *AppList) ToMessage() repositories.ListAppsMessage

func (AppList) Validate added in v0.8.0

func (a AppList) Validate() error

type AppPackagesList added in v0.16.0

type AppPackagesList struct {
	OrderBy    string
	Pagination Pagination
}

func (*AppPackagesList) DecodeFromURLValues added in v0.16.0

func (l *AppPackagesList) DecodeFromURLValues(values url.Values) error

func (*AppPackagesList) SupportedKeys added in v0.16.0

func (l *AppPackagesList) SupportedKeys() []string

func (*AppPackagesList) ToMessage added in v0.16.0

func (AppPackagesList) Validate added in v0.16.0

func (l AppPackagesList) Validate() error

type AppPatch added in v0.3.0

type AppPatch struct {
	Name      string          `json:"name"`
	Metadata  MetadataPatch   `json:"metadata"`
	Lifecycle *LifecyclePatch `json:"lifecycle"`
}

func (*AppPatch) ToMessage added in v0.3.0

func (a *AppPatch) ToMessage(appGUID, spaceGUID string) repositories.PatchAppMessage

func (AppPatch) Validate added in v0.8.0

func (p AppPatch) Validate() error

type AppPatchEnvVars

type AppPatchEnvVars struct {
	Var map[string]interface{} `json:"var"`
}

func (*AppPatchEnvVars) ToMessage

func (a *AppPatchEnvVars) ToMessage(appGUID, spaceGUID string) repositories.PatchAppEnvVarsMessage

func (AppPatchEnvVars) Validate added in v0.8.0

func (p AppPatchEnvVars) Validate() error

type AppProcessList added in v0.16.0

type AppProcessList struct {
	OrderBy    string
	Pagination Pagination
}

func (*AppProcessList) DecodeFromURLValues added in v0.16.0

func (l *AppProcessList) DecodeFromURLValues(values url.Values) error

func (*AppProcessList) SupportedKeys added in v0.16.0

func (l *AppProcessList) SupportedKeys() []string

func (*AppProcessList) ToMessage added in v0.16.0

func (AppProcessList) Validate added in v0.16.0

func (l AppProcessList) Validate() error

type AppRelationships

type AppRelationships struct {
	Space *Relationship `json:"space"`
}

func (AppRelationships) Validate added in v0.8.0

func (r AppRelationships) Validate() error

type AppResource

type AppResource struct {
	GUID    string                 `json:"guid"`
	Process *DestinationAppProcess `json:"process"`
}

func (AppResource) Validate added in v0.8.0

func (a AppResource) Validate() error

type AppRoutesList added in v0.16.0

type AppRoutesList struct {
	Pagination Pagination
	OrderBy    string
}

func (*AppRoutesList) DecodeFromURLValues added in v0.16.0

func (a *AppRoutesList) DecodeFromURLValues(values url.Values) error

func (*AppRoutesList) SupportedKeys added in v0.16.0

func (a *AppRoutesList) SupportedKeys() []string

func (*AppRoutesList) ToMessage added in v0.16.0

func (a *AppRoutesList) ToMessage(appGUID string) repositories.ListRoutesMessage

func (AppRoutesList) Validate added in v0.16.0

func (a AppRoutesList) Validate() error

type AppSetCurrentDroplet

type AppSetCurrentDroplet struct {
	Relationship `json:",inline"`
}

func (AppSetCurrentDroplet) Validate added in v0.8.0

func (d AppSetCurrentDroplet) Validate() error

type AppTaskList added in v0.16.0

type AppTaskList struct {
	SequenceIDs []int64
	OrderBy     string
	Pagination  Pagination
}

func (*AppTaskList) DecodeFromURLValues added in v0.16.0

func (a *AppTaskList) DecodeFromURLValues(values url.Values) error

func (*AppTaskList) SupportedKeys added in v0.16.0

func (t *AppTaskList) SupportedKeys() []string

func (*AppTaskList) ToMessage added in v0.16.0

func (t *AppTaskList) ToMessage() repositories.ListTasksMessage

func (AppTaskList) Validate added in v0.16.0

func (l AppTaskList) Validate() error

type BrokerAuthentication added in v0.13.0

type BrokerAuthentication struct {
	Type        string            `json:"type"`
	Credentials BrokerCredentials `json:"credentials"`
}

func (BrokerAuthentication) Validate added in v0.13.0

func (a BrokerAuthentication) Validate() error

type BrokerCredentials added in v0.15.0

type BrokerCredentials struct {
	Username string `json:"username"`
	Password string `json:"password"`
}

func (BrokerCredentials) Validate added in v0.15.0

func (c BrokerCredentials) Validate() error

type BuildCreate

type BuildCreate struct {
	Package         *RelationshipData `json:"package"`
	StagingMemoryMB *int              `json:"staging_memory_in_mb"`
	StagingDiskMB   *int              `json:"staging_disk_in_mb"`
	Lifecycle       *Lifecycle        `json:"lifecycle"`
	Metadata        BuildMetadata     `json:"metadata"`
}

func (*BuildCreate) ToMessage

func (BuildCreate) Validate added in v0.8.0

func (b BuildCreate) Validate() error

type BuildList added in v0.16.0

type BuildList struct {
	PackageGUIDs string
	AppGUIDs     string
	States       string
	OrderBy      string
	Pagination   Pagination
}

func (*BuildList) DecodeFromURLValues added in v0.16.0

func (b *BuildList) DecodeFromURLValues(values url.Values) error

func (*BuildList) SupportedKeys added in v0.16.0

func (b *BuildList) SupportedKeys() []string

func (*BuildList) ToMessage added in v0.16.0

func (b *BuildList) ToMessage() repositories.ListBuildsMessage

func (BuildList) Validate added in v0.16.0

func (b BuildList) Validate() error

type BuildMetadata added in v0.7.0

type BuildMetadata struct {
	Annotations map[string]string `json:"annotations"`
	Labels      map[string]string `json:"labels"`
}

func (BuildMetadata) Validate added in v0.8.0

func (m BuildMetadata) Validate() error

type BuildpackList

type BuildpackList struct {
	OrderBy    string
	Pagination Pagination
}

func (*BuildpackList) DecodeFromURLValues added in v0.6.0

func (d *BuildpackList) DecodeFromURLValues(values url.Values) error

func (BuildpackList) SupportedKeys added in v0.2.0

func (d BuildpackList) SupportedKeys() []string

func (BuildpackList) ToMessage added in v0.14.0

func (BuildpackList) Validate added in v0.8.0

func (d BuildpackList) Validate() error

type Data

type Data struct {
	Timeout           *int32  `json:"timeout"`
	Endpoint          *string `json:"endpoint"`
	InvocationTimeout *int32  `json:"invocation_timeout"`
}

type DeploymentCreate added in v0.8.0

type DeploymentCreate struct {
	Droplet       DropletGUID              `json:"droplet"`
	Relationships *DeploymentRelationships `json:"relationships"`
}

func (*DeploymentCreate) ToMessage added in v0.8.0

func (DeploymentCreate) Validate added in v0.8.0

func (c DeploymentCreate) Validate() error

type DeploymentList added in v0.13.0

type DeploymentList struct {
	AppGUIDs     string     `json:"app_guids"`
	OrderBy      string     `json:"order_by"`
	StatusValues string     `json:"status_values"`
	Pagination   Pagination `json:"pagination"`
}

func (*DeploymentList) DecodeFromURLValues added in v0.13.0

func (d *DeploymentList) DecodeFromURLValues(values url.Values) error

func (*DeploymentList) SupportedKeys added in v0.13.0

func (d *DeploymentList) SupportedKeys() []string

func (*DeploymentList) ToMessage added in v0.13.0

func (DeploymentList) Validate added in v0.13.0

func (d DeploymentList) Validate() error

type DeploymentRelationships added in v0.8.0

type DeploymentRelationships struct {
	App *Relationship `json:"app"`
}

func (DeploymentRelationships) Validate added in v0.8.0

func (r DeploymentRelationships) Validate() error

type DestinationAppProcess

type DestinationAppProcess struct {
	Type string `json:"type"`
}

func (DestinationAppProcess) Validate added in v0.8.0

func (p DestinationAppProcess) Validate() error

type DomainCreate added in v0.5.0

type DomainCreate struct {
	Name          string                  `json:"name"`
	Internal      bool                    `json:"internal"`
	Metadata      Metadata                `json:"metadata"`
	Relationships map[string]Relationship `json:"relationships"`
}

func (*DomainCreate) ToMessage added in v0.5.0

func (DomainCreate) Validate added in v0.8.0

func (c DomainCreate) Validate() error

type DomainList

type DomainList struct {
	Names      string
	OrderBy    string
	Pagination Pagination
}

func (*DomainList) DecodeFromURLValues added in v0.6.0

func (d *DomainList) DecodeFromURLValues(values url.Values) error

func (*DomainList) SupportedKeys added in v0.2.0

func (d *DomainList) SupportedKeys() []string

func (*DomainList) ToMessage

func (DomainList) Validate added in v0.16.0

func (a DomainList) Validate() error

type DomainUpdate added in v0.5.0

type DomainUpdate struct {
	Metadata MetadataPatch `json:"metadata"`
}

func (*DomainUpdate) ToMessage added in v0.5.0

func (c *DomainUpdate) ToMessage(domainGUID string) repositories.UpdateDomainMessage

func (DomainUpdate) Validate added in v0.8.0

func (c DomainUpdate) Validate() error

type DropletGUID added in v0.8.0

type DropletGUID struct {
	Guid string `json:"guid"`
}

type DropletList added in v0.16.0

type DropletList struct {
	GUIDs      string
	AppGUIDs   string
	SpaceGUIDs string
	OrderBy    string
	Pagination Pagination
}

func (*DropletList) DecodeFromURLValues added in v0.16.0

func (l *DropletList) DecodeFromURLValues(values url.Values) error

func (*DropletList) SupportedKeys added in v0.16.0

func (l *DropletList) SupportedKeys() []string

func (*DropletList) ToMessage added in v0.16.0

func (DropletList) Validate added in v0.16.0

func (l DropletList) Validate() error

type DropletUpdate added in v0.7.0

type DropletUpdate struct {
	Metadata MetadataPatch `json:"metadata"`
}

func (*DropletUpdate) ToMessage added in v0.7.0

func (c *DropletUpdate) ToMessage(dropletGUID string) repositories.UpdateDropletMessage

func (DropletUpdate) Validate added in v0.8.0

func (d DropletUpdate) Validate() error

type HealthCheck

type HealthCheck struct {
	Type *string `json:"type"`
	Data *Data   `json:"data"`
}

type Lifecycle

type Lifecycle struct {
	Type string         `json:"type"`
	Data *LifecycleData `json:"data"`
}

func (Lifecycle) Validate added in v0.8.0

func (l Lifecycle) Validate() error

type LifecycleData

type LifecycleData struct {
	Buildpacks []string `json:"buildpacks,omitempty"`
	Stack      string   `json:"stack,omitempty"`
}

func (LifecycleData) ValidateBuildpackLifecycleData added in v0.9.0

func (d LifecycleData) ValidateBuildpackLifecycleData() error

func (LifecycleData) ValidateDockerLifecycleData added in v0.9.0

func (d LifecycleData) ValidateDockerLifecycleData() error

type LifecycleDataPatch added in v0.8.0

type LifecycleDataPatch struct {
	Buildpacks *[]string `json:"buildpacks"`
	Stack      string    `json:"stack"`
}

type LifecyclePatch added in v0.8.0

type LifecyclePatch struct {
	Type string              `json:"type"`
	Data *LifecycleDataPatch `json:"data"`
}

func (LifecyclePatch) Validate added in v0.8.0

func (p LifecyclePatch) Validate() error

type LogCacheRead added in v0.15.0

type LogCacheRead struct {
	StartTime     *int64
	EnvelopeTypes []string
	Limit         *int64
	Descending    bool
}

func (*LogCacheRead) DecodeFromURLValues added in v0.15.0

func (l *LogCacheRead) DecodeFromURLValues(values url.Values) error

func (*LogCacheRead) SupportedKeys added in v0.15.0

func (l *LogCacheRead) SupportedKeys() []string

func (LogCacheRead) Validate added in v0.15.0

func (l LogCacheRead) Validate() error

type Manifest

type Manifest struct {
	Version      int                   `yaml:"version"`
	Applications []ManifestApplication `json:"applications" yaml:"applications"`
}

func (Manifest) Validate added in v0.7.0

func (m Manifest) Validate() error

type ManifestApplication

type ManifestApplication struct {
	Name         string            `json:"name" yaml:"name"`
	Env          map[string]string `yaml:"env"`
	DefaultRoute bool              `json:"default-route" yaml:"default-route"`
	RandomRoute  bool              `yaml:"random-route"`
	NoRoute      bool              `yaml:"no-route"`
	Command      *string           `yaml:"command"`
	Instances    *int32            `json:"instances" yaml:"instances"`
	Memory       *string           `json:"memory" yaml:"memory"`
	DiskQuota    *string           `json:"disk_quota" yaml:"disk_quota"`
	// AltDiskQuota supports `disk-quota` with a hyphen for backwards compatibility.
	// Do not set both DiskQuota and AltDiskQuota.
	//
	// Deprecated: Use DiskQuota instead
	AltDiskQuota                 *string                      `json:"disk-quota" yaml:"disk-quota"`
	HealthCheckHTTPEndpoint      *string                      `yaml:"health-check-http-endpoint"`
	HealthCheckInvocationTimeout *int32                       `json:"health-check-invocation-timeout" yaml:"health-check-invocation-timeout"`
	HealthCheckType              *string                      `json:"health-check-type" yaml:"health-check-type"`
	Timeout                      *int32                       `json:"timeout" yaml:"timeout"`
	Processes                    []ManifestApplicationProcess `json:"processes" yaml:"processes"`
	Routes                       []ManifestRoute              `json:"routes" yaml:"routes"`
	Buildpacks                   []string                     `yaml:"buildpacks"`
	// Deprecated: Use Buildpacks instead
	Buildpack *string                      `json:"buildpack" yaml:"buildpack"`
	Metadata  MetadataPatch                `json:"metadata" yaml:"metadata"`
	Services  []ManifestApplicationService `json:"services" yaml:"services"`
	Docker    any                          `json:"docker,omitempty" yaml:"docker,omitempty"`
}

func (ManifestApplication) ToAppCreateMessage

func (a ManifestApplication) ToAppCreateMessage(spaceGUID string) repositories.CreateAppMessage

func (ManifestApplication) ToAppPatchMessage added in v0.4.0

func (a ManifestApplication) ToAppPatchMessage(appGUID, spaceGUID string) repositories.PatchAppMessage

func (ManifestApplication) Validate added in v0.7.0

func (a ManifestApplication) Validate() error

type ManifestApplicationProcess

type ManifestApplicationProcess struct {
	Type      string  `json:"type" yaml:"type"`
	Command   *string `yaml:"command"`
	DiskQuota *string `json:"disk_quota" yaml:"disk_quota"`
	// AltDiskQuota supports `disk-quota` with a hyphen for backwards compatibility.
	// Do not set both DiskQuota and AltDiskQuota.
	//
	// Deprecated: Use DiskQuota instead
	AltDiskQuota                 *string `json:"disk-quota" yaml:"disk-quota"`
	HealthCheckHTTPEndpoint      *string `yaml:"health-check-http-endpoint"`
	HealthCheckInvocationTimeout *int32  `json:"health-check-invocation-timeout" yaml:"health-check-invocation-timeout"`
	HealthCheckType              *string `json:"health-check-type" yaml:"health-check-type"`
	Instances                    *int32  `json:"instances" yaml:"instances"`
	Memory                       *string `json:"memory" yaml:"memory"`
	Timeout                      *int32  `json:"timeout" yaml:"timeout"`
}

TODO: Why is kebab-case used everywhere anyway and we have a deprecated field that claims to use it for backwards compatibility?

func (ManifestApplicationProcess) ToProcessCreateMessage

func (p ManifestApplicationProcess) ToProcessCreateMessage(appGUID, spaceGUID string) repositories.CreateProcessMessage

func (ManifestApplicationProcess) ToProcessPatchMessage

func (p ManifestApplicationProcess) ToProcessPatchMessage(processGUID, spaceGUID string) repositories.PatchProcessMessage

func (ManifestApplicationProcess) Validate added in v0.7.0

func (p ManifestApplicationProcess) Validate() error

type ManifestApplicationService added in v0.9.0

type ManifestApplicationService struct {
	Name        string         `json:"name" yaml:"name"`
	BindingName *string        `json:"binding_name" yaml:"binding_name"`
	Parameters  map[string]any `json:"parameters" yaml:"parameters"`
}

func (*ManifestApplicationService) UnmarshalYAML added in v0.12.0

func (s *ManifestApplicationService) UnmarshalYAML(value *yaml.Node) error

func (ManifestApplicationService) Validate added in v0.9.0

func (s ManifestApplicationService) Validate() error

type ManifestRoute

type ManifestRoute struct {
	Route *string `json:"route" yaml:"route"`
}

func (ManifestRoute) Validate added in v0.7.0

func (m ManifestRoute) Validate() error

type Metadata

type Metadata struct {
	Annotations map[string]string `json:"annotations" yaml:"annotations"`
	Labels      map[string]string `json:"labels"      yaml:"labels"`
}

func (Metadata) Validate added in v0.8.0

func (m Metadata) Validate() error

type MetadataPatch added in v0.3.0

type MetadataPatch struct {
	Annotations map[string]*string `json:"annotations"`
	Labels      map[string]*string `json:"labels"`
}

func (MetadataPatch) Validate added in v0.8.0

func (p MetadataPatch) Validate() error

type OrgCreate

type OrgCreate struct {
	Name      string   `json:"name"`
	Suspended bool     `json:"suspended"`
	Metadata  Metadata `json:"metadata"`
}

func (OrgCreate) ToMessage

func (p OrgCreate) ToMessage() repositories.CreateOrgMessage

func (OrgCreate) Validate added in v0.8.0

func (p OrgCreate) Validate() error

type OrgList added in v0.8.0

type OrgList struct {
	Names      string
	OrderBy    string
	Pagination Pagination
}

func (*OrgList) DecodeFromURLValues added in v0.8.0

func (l *OrgList) DecodeFromURLValues(values url.Values) error

func (*OrgList) SupportedKeys added in v0.8.0

func (l *OrgList) SupportedKeys() []string

func (*OrgList) ToMessage added in v0.8.0

func (l *OrgList) ToMessage() repositories.ListOrgsMessage

func (OrgList) Validate added in v0.16.0

func (l OrgList) Validate() error

type OrgPatch added in v0.3.0

type OrgPatch struct {
	Name     *string       `json:"name"`
	Metadata MetadataPatch `json:"metadata"`
}

func (OrgPatch) ToMessage added in v0.3.0

func (p OrgPatch) ToMessage(orgGUID string) repositories.PatchOrgMessage

func (OrgPatch) Validate added in v0.8.0

func (p OrgPatch) Validate() error

type PackageCreate

type PackageCreate struct {
	Type          string                `json:"type"`
	Relationships *PackageRelationships `json:"relationships"`
	Metadata      Metadata              `json:"metadata"`
	Data          *PackageData          `json:"data"`
}

func (PackageCreate) ToMessage

func (PackageCreate) Validate added in v0.8.0

func (c PackageCreate) Validate() error

type PackageData added in v0.9.0

type PackageData struct {
	Image    string  `json:"image"`
	Username *string `json:"username"`
	Password *string `json:"password"`
}

func (PackageData) Validate added in v0.9.0

func (d PackageData) Validate() error

type PackageDropletList added in v0.16.0

type PackageDropletList struct {
	OrderBy    string
	Pagination Pagination
}

func (*PackageDropletList) DecodeFromURLValues added in v0.16.0

func (p *PackageDropletList) DecodeFromURLValues(values url.Values) error

func (*PackageDropletList) SupportedKeys added in v0.16.0

func (p *PackageDropletList) SupportedKeys() []string

func (*PackageDropletList) ToMessage added in v0.16.0

func (p *PackageDropletList) ToMessage(packageGUID string) repositories.ListDropletsMessage

type PackageList added in v0.8.0

type PackageList struct {
	GUIDs      string
	AppGUIDs   string
	States     string
	OrderBy    string
	Pagination Pagination
}

func (*PackageList) DecodeFromURLValues added in v0.8.0

func (p *PackageList) DecodeFromURLValues(values url.Values) error

func (*PackageList) SupportedKeys added in v0.8.0

func (p *PackageList) SupportedKeys() []string

func (*PackageList) ToMessage added in v0.8.0

func (PackageList) Validate added in v0.8.0

func (p PackageList) Validate() error

type PackageRelationships

type PackageRelationships struct {
	App *Relationship `json:"app"`
}

func (PackageRelationships) Validate added in v0.8.0

func (r PackageRelationships) Validate() error

type PackageUpdate added in v0.5.0

type PackageUpdate struct {
	Metadata MetadataPatch `json:"metadata"`
}

func (*PackageUpdate) ToMessage added in v0.5.0

func (u *PackageUpdate) ToMessage(packageGUID string) repositories.UpdatePackageMessage

func (PackageUpdate) Validate added in v0.8.0

func (p PackageUpdate) Validate() error

type Pagination added in v0.16.0

type Pagination struct {
	PerPage string
	Page    string
}

func (*Pagination) DecodeFromURLValues added in v0.16.0

func (p *Pagination) DecodeFromURLValues(values url.Values) error

func (*Pagination) ToMessage added in v0.16.0

func (p *Pagination) ToMessage(defaultPageSize int) repositories.Pagination

func (Pagination) Validate added in v0.16.0

func (p Pagination) Validate() error

type ProcessList

type ProcessList struct {
	AppGUIDs   string
	OrderBy    string
	Pagination Pagination
}

func (*ProcessList) DecodeFromURLValues added in v0.6.0

func (p *ProcessList) DecodeFromURLValues(values url.Values) error

func (*ProcessList) SupportedKeys added in v0.2.0

func (p *ProcessList) SupportedKeys() []string

func (*ProcessList) ToMessage

func (ProcessList) Validate added in v0.16.0

func (p ProcessList) Validate() error

type ProcessPatch

type ProcessPatch struct {
	Metadata    *MetadataPatch `json:"metadata"`
	Command     *string        `json:"command"`
	HealthCheck *HealthCheck   `json:"health_check"`
}

func (ProcessPatch) ToProcessPatchMessage

func (p ProcessPatch) ToProcessPatchMessage(processGUID, spaceGUID string) repositories.PatchProcessMessage

type ProcessScale

type ProcessScale struct {
	Instances *int32 `json:"instances"`
	MemoryMB  *int64 `json:"memory_in_mb"`
	DiskMB    *int64 `json:"disk_in_mb"`
}

func (ProcessScale) ToRecord

func (ProcessScale) Validate added in v0.8.0

func (p ProcessScale) Validate() error

type Relationship

type Relationship struct {
	Data *RelationshipData `json:"data"`
}

func (Relationship) Validate added in v0.8.0

func (r Relationship) Validate() error

type RelationshipData

type RelationshipData struct {
	GUID string `json:"guid"`
}

func (RelationshipData) Validate added in v0.8.0

func (r RelationshipData) Validate() error

type RoleCreate

type RoleCreate struct {
	Type          string            `json:"type"`
	Relationships RoleRelationships `json:"relationships"`
}

func (RoleCreate) ToMessage

func (RoleCreate) Validate added in v0.8.0

func (p RoleCreate) Validate() error

type RoleList added in v0.8.0

type RoleList struct {
	GUIDs      string
	Types      string
	SpaceGUIDs string
	OrgGUIDs   string
	UserGUIDs  string
	OrderBy    string
	Pagination Pagination
}

func (*RoleList) DecodeFromURLValues added in v0.8.0

func (r *RoleList) DecodeFromURLValues(values url.Values) error

func (RoleList) SupportedKeys added in v0.8.0

func (r RoleList) SupportedKeys() []string

func (RoleList) ToMessage added in v0.14.0

func (r RoleList) ToMessage() repositories.ListRolesMessage

func (RoleList) Validate added in v0.8.0

func (r RoleList) Validate() error

type RoleRelationships

type RoleRelationships struct {
	User         UserRelationship `json:"user"`
	Space        *Relationship    `json:"space"`
	Organization *Relationship    `json:"organization"`
}

func (RoleRelationships) ValidateWithContext added in v0.8.0

func (r RoleRelationships) ValidateWithContext(ctx context.Context) error

type RouteCreate

type RouteCreate struct {
	Host          string              `json:"host"`
	Path          string              `json:"path"`
	Relationships *RouteRelationships `json:"relationships"`
	Metadata      Metadata            `json:"metadata"`
}

func (RouteCreate) ToMessage

func (p RouteCreate) ToMessage(domainNamespace, domainName string) repositories.CreateRouteMessage

func (RouteCreate) Validate added in v0.8.0

func (p RouteCreate) Validate() error

type RouteDestination added in v0.8.0

type RouteDestination struct {
	App      AppResource `json:"app"`
	Port     *int32      `json:"port"`
	Protocol *string     `json:"protocol"`
}

func (RouteDestination) Validate added in v0.8.0

func (r RouteDestination) Validate() error

type RouteDestinationCreate added in v0.8.0

type RouteDestinationCreate struct {
	Destinations []RouteDestination `json:"destinations"`
}

func (RouteDestinationCreate) ToMessage added in v0.8.0

func (RouteDestinationCreate) Validate added in v0.8.0

func (r RouteDestinationCreate) Validate() error

type RouteList

type RouteList struct {
	AppGUIDs    string
	SpaceGUIDs  string
	DomainGUIDs string
	Hosts       string
	Paths       string
	OrderBy     string
	Pagination  Pagination
}

func (*RouteList) DecodeFromURLValues added in v0.6.0

func (p *RouteList) DecodeFromURLValues(values url.Values) error

func (RouteList) SupportedKeys added in v0.2.0

func (p RouteList) SupportedKeys() []string

func (RouteList) ToMessage

func (RouteList) Validate added in v0.16.0

func (p RouteList) Validate() error

type RoutePatch added in v0.5.0

type RoutePatch struct {
	Metadata MetadataPatch `json:"metadata"`
}

func (RoutePatch) ToMessage added in v0.5.0

func (p RoutePatch) ToMessage(routeGUID, spaceGUID string) repositories.PatchRouteMetadataMessage

func (RoutePatch) Validate added in v0.8.0

func (p RoutePatch) Validate() error

type RouteRelationships

type RouteRelationships struct {
	Domain Relationship `json:"domain"`
	Space  Relationship `json:"space"`
}

func (RouteRelationships) Validate added in v0.8.0

func (r RouteRelationships) Validate() error

type SecurityGroupCreate added in v0.16.0

type SecurityGroupCreate struct {
	DisplayName     string                     `json:"name"`
	Rules           []SecurityGroupRule        `json:"rules"`
	GloballyEnabled SecurityGroupWorkloads     `json:"globally_enabled"`
	Relationships   SecurityGroupRelationships `json:"relationships"`
}

func (SecurityGroupCreate) ToMessage added in v0.16.0

func (SecurityGroupCreate) Validate added in v0.16.0

func (c SecurityGroupCreate) Validate() error

type SecurityGroupRelationships added in v0.16.0

type SecurityGroupRelationships struct {
	RunningSpaces ToManyRelationship `json:"running_spaces"`
	StagingSpaces ToManyRelationship `json:"staging_spaces"`
}

type SecurityGroupRule added in v0.16.0

type SecurityGroupRule struct {
	Protocol    string `json:"protocol"`
	Destination string `json:"destination"`
	Ports       string `json:"ports,omitempty"`
	Type        int    `json:"type,omitempty"`
	Code        int    `json:"code,omitempty"`
	Description string `json:"description,omitempty"`
	Log         bool   `json:"log,omitempty"`
}

type SecurityGroupWorkloads added in v0.16.0

type SecurityGroupWorkloads struct {
	Running bool `json:"running"`
	Staging bool `json:"staging"`
}

type ServiceBindingCreate

type ServiceBindingCreate struct {
	Relationships *ServiceBindingRelationships `json:"relationships"`
	Type          string                       `json:"type"`
	Parameters    map[string]any               `json:"parameters"`
	Name          *string                      `json:"name"`
}

func (ServiceBindingCreate) ToMessage

func (ServiceBindingCreate) Validate added in v0.8.0

func (p ServiceBindingCreate) Validate() error

type ServiceBindingList

type ServiceBindingList struct {
	Type                 string
	AppGUIDs             string
	ServiceInstanceGUIDs string
	Include              string
	LabelSelector        string
	PlanGUIDs            string
	OrderBy              string
	Pagination           Pagination
}

func (*ServiceBindingList) DecodeFromURLValues added in v0.6.0

func (l *ServiceBindingList) DecodeFromURLValues(values url.Values) error

func (*ServiceBindingList) SupportedKeys added in v0.2.0

func (l *ServiceBindingList) SupportedKeys() []string

func (*ServiceBindingList) ToMessage

func (ServiceBindingList) Validate added in v0.14.0

func (l ServiceBindingList) Validate() error

type ServiceBindingRelationships

type ServiceBindingRelationships struct {
	App             *Relationship `json:"app"`
	ServiceInstance *Relationship `json:"service_instance"`
}

func (ServiceBindingRelationships) Validate added in v0.8.0

func (r ServiceBindingRelationships) Validate() error

type ServiceBindingUpdate added in v0.7.0

type ServiceBindingUpdate struct {
	Metadata MetadataPatch `json:"metadata"`
}

func (*ServiceBindingUpdate) ToMessage added in v0.7.0

func (c *ServiceBindingUpdate) ToMessage(serviceBindingGUID string) repositories.UpdateServiceBindingMessage

func (ServiceBindingUpdate) Validate added in v0.8.0

func (u ServiceBindingUpdate) Validate() error

type ServiceBrokerCreate added in v0.13.0

type ServiceBrokerCreate struct {
	Name           string                `json:"name"`
	URL            string                `json:"url"`
	Labels         map[string]string     `json:"labels,omitempty"`
	Annotations    map[string]string     `json:"annotations,omitempty"`
	Authentication *BrokerAuthentication `json:"authentication"`
}

func (ServiceBrokerCreate) ToMessage added in v0.13.0

func (ServiceBrokerCreate) Validate added in v0.13.0

func (c ServiceBrokerCreate) Validate() error

type ServiceBrokerList added in v0.13.0

type ServiceBrokerList struct {
	Names      string
	OrderBy    string
	Pagination Pagination
}

func (*ServiceBrokerList) DecodeFromURLValues added in v0.13.0

func (b *ServiceBrokerList) DecodeFromURLValues(values url.Values) error

func (*ServiceBrokerList) SupportedKeys added in v0.13.0

func (b *ServiceBrokerList) SupportedKeys() []string

func (*ServiceBrokerList) ToMessage added in v0.13.0

func (ServiceBrokerList) Validate added in v0.16.0

func (l ServiceBrokerList) Validate() error

type ServiceBrokerUpdate added in v0.13.0

type ServiceBrokerUpdate struct {
	Name           *string               `json:"name"`
	URL            *string               `json:"url"`
	Authentication *BrokerAuthentication `json:"authentication"`
	Metadata       MetadataPatch         `json:"metadata"`
}

func (*ServiceBrokerUpdate) IsAsyncRequest added in v0.13.0

func (b *ServiceBrokerUpdate) IsAsyncRequest() bool

func (*ServiceBrokerUpdate) ToMessage added in v0.13.0

func (ServiceBrokerUpdate) Validate added in v0.13.0

func (c ServiceBrokerUpdate) Validate() error

type ServiceInstanceCreate

type ServiceInstanceCreate struct {
	Name          string                        `json:"name"`
	Type          string                        `json:"type"`
	Tags          []string                      `json:"tags"`
	Credentials   map[string]any                `json:"credentials"`
	Parameters    map[string]any                `json:"parameters"`
	Relationships *ServiceInstanceRelationships `json:"relationships"`
	Metadata      Metadata                      `json:"metadata"`
}

func (ServiceInstanceCreate) ToManagedSICreateMessage added in v0.13.0

func (p ServiceInstanceCreate) ToManagedSICreateMessage() repositories.CreateManagedSIMessage

func (ServiceInstanceCreate) ToUPSICreateMessage added in v0.13.0

func (p ServiceInstanceCreate) ToUPSICreateMessage() repositories.CreateUPSIMessage

func (ServiceInstanceCreate) Validate added in v0.8.0

func (c ServiceInstanceCreate) Validate() error

type ServiceInstanceDelete added in v0.14.0

type ServiceInstanceDelete struct {
	Purge bool `json:"purge"`
}

func (*ServiceInstanceDelete) DecodeFromURLValues added in v0.14.0

func (d *ServiceInstanceDelete) DecodeFromURLValues(values url.Values) error

func (*ServiceInstanceDelete) SupportedKeys added in v0.14.0

func (d *ServiceInstanceDelete) SupportedKeys() []string

func (*ServiceInstanceDelete) ToMessage added in v0.14.0

type ServiceInstanceGet added in v0.14.0

type ServiceInstanceGet struct {
	IncludeResourceRules []params.IncludeResourceRule
}

func (*ServiceInstanceGet) DecodeFromURLValues added in v0.14.0

func (g *ServiceInstanceGet) DecodeFromURLValues(values url.Values) error

func (*ServiceInstanceGet) SupportedKeys added in v0.14.0

func (g *ServiceInstanceGet) SupportedKeys() []string

func (ServiceInstanceGet) Validate added in v0.14.0

func (g ServiceInstanceGet) Validate() error

type ServiceInstanceList

type ServiceInstanceList struct {
	Names                string
	GUIDs                string
	Type                 string
	SpaceGUIDs           string
	PlanGUIDs            string
	OrderBy              string
	LabelSelector        string
	IncludeResourceRules []params.IncludeResourceRule
	Pagination           Pagination
}

func (*ServiceInstanceList) DecodeFromURLValues added in v0.6.0

func (l *ServiceInstanceList) DecodeFromURLValues(values url.Values) error

func (*ServiceInstanceList) SupportedKeys added in v0.2.0

func (l *ServiceInstanceList) SupportedKeys() []string

func (*ServiceInstanceList) ToMessage

func (ServiceInstanceList) Validate added in v0.8.0

func (l ServiceInstanceList) Validate() error

type ServiceInstancePatch added in v0.7.0

type ServiceInstancePatch struct {
	Name        *string         `json:"name,omitempty"`
	Tags        *[]string       `json:"tags,omitempty"`
	Credentials *map[string]any `json:"credentials,omitempty"`
	Metadata    MetadataPatch   `json:"metadata"`
}

func (ServiceInstancePatch) ToServiceInstancePatchMessage added in v0.7.0

func (p ServiceInstancePatch) ToServiceInstancePatchMessage(spaceGUID, appGUID string) repositories.PatchServiceInstanceMessage

func (*ServiceInstancePatch) UnmarshalJSON added in v0.7.0

func (p *ServiceInstancePatch) UnmarshalJSON(data []byte) error

func (ServiceInstancePatch) Validate added in v0.8.0

func (p ServiceInstancePatch) Validate() error

type ServiceInstanceRelationships

type ServiceInstanceRelationships struct {
	Space       *Relationship `json:"space"`
	ServicePlan *Relationship `json:"service_plan"`
}

func (ServiceInstanceRelationships) ValidateManagedRelationships added in v0.13.0

func (r ServiceInstanceRelationships) ValidateManagedRelationships() error

func (ServiceInstanceRelationships) ValidateUserProvidedRelationships added in v0.13.0

func (r ServiceInstanceRelationships) ValidateUserProvidedRelationships() error

type ServiceOfferingDelete added in v0.14.0

type ServiceOfferingDelete struct {
	Purge bool
}

func (*ServiceOfferingDelete) DecodeFromURLValues added in v0.14.0

func (d *ServiceOfferingDelete) DecodeFromURLValues(values url.Values) error

func (*ServiceOfferingDelete) SupportedKeys added in v0.14.0

func (d *ServiceOfferingDelete) SupportedKeys() []string

func (*ServiceOfferingDelete) ToMessage added in v0.14.0

type ServiceOfferingGet added in v0.14.0

type ServiceOfferingGet struct {
	IncludeResourceRules []params.IncludeResourceRule
}

func (*ServiceOfferingGet) DecodeFromURLValues added in v0.14.0

func (g *ServiceOfferingGet) DecodeFromURLValues(values url.Values) error

func (ServiceOfferingGet) SupportedKeys added in v0.14.0

func (g ServiceOfferingGet) SupportedKeys() []string

func (ServiceOfferingGet) Validate added in v0.14.0

func (g ServiceOfferingGet) Validate() error

type ServiceOfferingList added in v0.13.0

type ServiceOfferingList struct {
	Names                string
	BrokerNames          string
	IncludeResourceRules []params.IncludeResourceRule
	OrderBy              string
	Pagination           Pagination
}

func (*ServiceOfferingList) DecodeFromURLValues added in v0.13.0

func (l *ServiceOfferingList) DecodeFromURLValues(values url.Values) error

func (*ServiceOfferingList) SupportedKeys added in v0.13.0

func (l *ServiceOfferingList) SupportedKeys() []string

func (*ServiceOfferingList) ToMessage added in v0.13.0

func (ServiceOfferingList) Validate added in v0.13.0

func (l ServiceOfferingList) Validate() error

type ServiceOfferingUpdate added in v0.16.0

type ServiceOfferingUpdate struct {
	Metadata MetadataPatch `json:"metadata"`
}

func (*ServiceOfferingUpdate) ToMessage added in v0.16.0

func (g *ServiceOfferingUpdate) ToMessage(serviceOfferingGUID string) repositories.UpdateServiceOfferingMessage

func (ServiceOfferingUpdate) Validate added in v0.16.0

func (g ServiceOfferingUpdate) Validate() error

type ServicePlanList added in v0.13.0

type ServicePlanList struct {
	ServiceOfferingGUIDs string
	BrokerGUIDs          string
	BrokerNames          string
	Names                string
	ServiceOfferingNames string
	Available            *bool
	IncludeResourceRules []params.IncludeResourceRule
	OrderBy              string
	Pagination           Pagination
}

func (*ServicePlanList) DecodeFromURLValues added in v0.13.0

func (l *ServicePlanList) DecodeFromURLValues(values url.Values) error

func (*ServicePlanList) IgnoredKeys added in v0.13.0

func (l *ServicePlanList) IgnoredKeys() []*regexp.Regexp

func (*ServicePlanList) SupportedKeys added in v0.13.0

func (l *ServicePlanList) SupportedKeys() []string

func (*ServicePlanList) ToMessage added in v0.13.0

func (ServicePlanList) Validate added in v0.13.0

func (l ServicePlanList) Validate() error

type ServicePlanVisibility added in v0.13.0

type ServicePlanVisibility struct {
	Type          string                   `json:"type"`
	Organizations []VisibilityOrganization `json:"organizations,omitempty"`
}

func (*ServicePlanVisibility) ToApplyMessage added in v0.13.0

func (*ServicePlanVisibility) ToUpdateMessage added in v0.13.0

func (ServicePlanVisibility) Validate added in v0.13.0

func (p ServicePlanVisibility) Validate() error

type SpaceCreate

type SpaceCreate struct {
	Name          string              `json:"name"`
	Relationships *SpaceRelationships `json:"relationships"`
	Metadata      Metadata            `json:"metadata"`
}

func (SpaceCreate) ToMessage

func (SpaceCreate) Validate added in v0.8.0

func (c SpaceCreate) Validate() error

type SpaceDeleteRoutes added in v0.16.0

type SpaceDeleteRoutes struct {
	Unmapped string `json:"unmapped"`
}

func (*SpaceDeleteRoutes) DecodeFromURLValues added in v0.16.0

func (d *SpaceDeleteRoutes) DecodeFromURLValues(values url.Values) error

func (*SpaceDeleteRoutes) SupportedKeys added in v0.16.0

func (d *SpaceDeleteRoutes) SupportedKeys() []string

func (SpaceDeleteRoutes) Validate added in v0.16.0

func (d SpaceDeleteRoutes) Validate() error

type SpaceGet added in v0.16.0

type SpaceGet struct {
	IncludeResourceRules []params.IncludeResourceRule
}

func (*SpaceGet) DecodeFromURLValues added in v0.16.0

func (s *SpaceGet) DecodeFromURLValues(values url.Values) error

func (*SpaceGet) SupportedKeys added in v0.16.0

func (s *SpaceGet) SupportedKeys() []string

func (SpaceGet) Validate added in v0.16.0

func (g SpaceGet) Validate() error

type SpaceList added in v0.8.0

type SpaceList struct {
	Names                string
	GUIDs                string
	OrganizationGUIDs    string
	IncludeResourceRules []params.IncludeResourceRule
	Pagination           Pagination
}

func (*SpaceList) DecodeFromURLValues added in v0.8.0

func (l *SpaceList) DecodeFromURLValues(values url.Values) error

func (*SpaceList) SupportedKeys added in v0.8.0

func (l *SpaceList) SupportedKeys() []string

func (*SpaceList) ToMessage added in v0.8.0

func (l *SpaceList) ToMessage() repositories.ListSpacesMessage

func (SpaceList) Validate added in v0.16.0

func (s SpaceList) Validate() error

type SpacePatch added in v0.3.0

type SpacePatch struct {
	Metadata MetadataPatch `json:"metadata"`
}

func (SpacePatch) ToMessage added in v0.3.0

func (p SpacePatch) ToMessage(spaceGUID, orgGUID string) repositories.PatchSpaceMetadataMessage

func (SpacePatch) Validate added in v0.8.0

func (p SpacePatch) Validate() error

type SpaceRelationships

type SpaceRelationships struct {
	Org *Relationship `json:"organization"`
}

func (SpaceRelationships) Validate added in v0.8.0

func (r SpaceRelationships) Validate() error

type StackList added in v0.16.0

type StackList struct {
	Pagination Pagination
}

func (*StackList) DecodeFromURLValues added in v0.16.0

func (l *StackList) DecodeFromURLValues(values url.Values) error

func (*StackList) SupportedKeys added in v0.16.0

func (l *StackList) SupportedKeys() []string

func (*StackList) ToMessage added in v0.16.0

func (s *StackList) ToMessage() (message repositories.ListStacksMessage)

func (StackList) Validate added in v0.16.0

func (s StackList) Validate() error

type TaskCreate added in v0.2.0

type TaskCreate struct {
	Command  string   `json:"command"`
	Metadata Metadata `json:"metadata"`
}

func (TaskCreate) ToMessage added in v0.2.0

func (TaskCreate) Validate added in v0.8.0

func (c TaskCreate) Validate() error

type TaskList added in v0.2.0

type TaskList struct {
	OrderBy    string
	Pagination Pagination
}

func (*TaskList) DecodeFromURLValues added in v0.6.0

func (l *TaskList) DecodeFromURLValues(values url.Values) error

func (*TaskList) SupportedKeys added in v0.2.0

func (l *TaskList) SupportedKeys() []string

func (*TaskList) ToMessage added in v0.2.0

func (l *TaskList) ToMessage() repositories.ListTasksMessage

func (TaskList) Validate added in v0.16.0

func (l TaskList) Validate() error

type TaskUpdate added in v0.7.0

type TaskUpdate struct {
	Metadata MetadataPatch `json:"metadata"`
}

func (*TaskUpdate) ToMessage added in v0.7.0

func (u *TaskUpdate) ToMessage(taskGUID, spaceGUID string) repositories.PatchTaskMetadataMessage

func (TaskUpdate) Validate added in v0.8.0

func (u TaskUpdate) Validate() error

type ToManyRelationship added in v0.16.0

type ToManyRelationship struct {
	Data []RelationshipData `json:"data"`
}

type UserList added in v0.16.0

type UserList struct {
	Names      string
	Pagination Pagination
}

func (*UserList) DecodeFromURLValues added in v0.16.0

func (l *UserList) DecodeFromURLValues(values url.Values) error

func (*UserList) SupportedKeys added in v0.16.0

func (l *UserList) SupportedKeys() []string

func (*UserList) ToMessage added in v0.16.0

func (l *UserList) ToMessage() (message repositories.ListUsersMessage)

func (UserList) Validate added in v0.16.0

func (l UserList) Validate() error

type UserRelationship

type UserRelationship struct {
	Data UserRelationshipData `json:"data"`
}

type UserRelationshipData

type UserRelationshipData struct {
	Username string `json:"username"`
	GUID     string `json:"guid"`
	Origin   string `json:"origin"`
}

type VisibilityOrganization added in v0.15.0

type VisibilityOrganization struct {
	GUID string `json:"guid"`
	Name string `json:"name"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL