apps

package
v0.81.0 Latest Latest
Warning

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

Go to latest
Published: Aug 20, 2025 License: Apache-2.0 Imports: 10 Imported by: 9

Documentation

Overview

These APIs allow you to manage Apps, Apps Settings, etc.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App

type App struct {
	// The active deployment of the app. A deployment is considered active when
	// it has been deployed to the app compute.
	ActiveDeployment *AppDeployment `json:"active_deployment,omitempty"`

	AppStatus *ApplicationStatus `json:"app_status,omitempty"`

	BudgetPolicyId string `json:"budget_policy_id,omitempty"`

	ComputeStatus *ComputeStatus `json:"compute_status,omitempty"`
	// The creation time of the app. Formatted timestamp in ISO 6801.
	CreateTime string `json:"create_time,omitempty"`
	// The email of the user that created the app.
	Creator string `json:"creator,omitempty"`
	// The default workspace file system path of the source code from which app
	// deployment are created. This field tracks the workspace source code path
	// of the last active deployment.
	DefaultSourceCodePath string `json:"default_source_code_path,omitempty"`
	// The description of the app.
	Description string `json:"description,omitempty"`

	EffectiveBudgetPolicyId string `json:"effective_budget_policy_id,omitempty"`
	// The effective api scopes granted to the user access token.
	EffectiveUserApiScopes []string `json:"effective_user_api_scopes,omitempty"`
	// The unique identifier of the app.
	Id string `json:"id,omitempty"`
	// The name of the app. The name must contain only lowercase alphanumeric
	// characters and hyphens. It must be unique within the workspace.
	Name string `json:"name"`

	Oauth2AppClientId string `json:"oauth2_app_client_id,omitempty"`

	Oauth2AppIntegrationId string `json:"oauth2_app_integration_id,omitempty"`
	// The pending deployment of the app. A deployment is considered pending
	// when it is being prepared for deployment to the app compute.
	PendingDeployment *AppDeployment `json:"pending_deployment,omitempty"`
	// Resources for the app.
	Resources []AppResource `json:"resources,omitempty"`

	ServicePrincipalClientId string `json:"service_principal_client_id,omitempty"`

	ServicePrincipalId int64 `json:"service_principal_id,omitempty"`

	ServicePrincipalName string `json:"service_principal_name,omitempty"`
	// The update time of the app. Formatted timestamp in ISO 6801.
	UpdateTime string `json:"update_time,omitempty"`
	// The email of the user that last updated the app.
	Updater string `json:"updater,omitempty"`
	// The URL of the app once it is deployed.
	Url string `json:"url,omitempty"`

	UserApiScopes []string `json:"user_api_scopes,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (App) MarshalJSON

func (s App) MarshalJSON() ([]byte, error)

func (*App) UnmarshalJSON

func (s *App) UnmarshalJSON(b []byte) error

type AppAccessControlRequest

type AppAccessControlRequest struct {
	// name of the group
	GroupName string `json:"group_name,omitempty"`

	PermissionLevel AppPermissionLevel `json:"permission_level,omitempty"`
	// application ID of a service principal
	ServicePrincipalName string `json:"service_principal_name,omitempty"`
	// name of the user
	UserName string `json:"user_name,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (AppAccessControlRequest) MarshalJSON

func (s AppAccessControlRequest) MarshalJSON() ([]byte, error)

func (*AppAccessControlRequest) UnmarshalJSON

func (s *AppAccessControlRequest) UnmarshalJSON(b []byte) error

type AppAccessControlResponse

type AppAccessControlResponse struct {
	// All permissions.
	AllPermissions []AppPermission `json:"all_permissions,omitempty"`
	// Display name of the user or service principal.
	DisplayName string `json:"display_name,omitempty"`
	// name of the group
	GroupName string `json:"group_name,omitempty"`
	// Name of the service principal.
	ServicePrincipalName string `json:"service_principal_name,omitempty"`
	// name of the user
	UserName string `json:"user_name,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (AppAccessControlResponse) MarshalJSON

func (s AppAccessControlResponse) MarshalJSON() ([]byte, error)

func (*AppAccessControlResponse) UnmarshalJSON

func (s *AppAccessControlResponse) UnmarshalJSON(b []byte) error

type AppDeployment

type AppDeployment struct {
	// The creation time of the deployment. Formatted timestamp in ISO 6801.
	CreateTime string `json:"create_time,omitempty"`
	// The email of the user creates the deployment.
	Creator string `json:"creator,omitempty"`
	// The deployment artifacts for an app.
	DeploymentArtifacts *AppDeploymentArtifacts `json:"deployment_artifacts,omitempty"`
	// The unique id of the deployment.
	DeploymentId string `json:"deployment_id,omitempty"`
	// The mode of which the deployment will manage the source code.
	Mode AppDeploymentMode `json:"mode,omitempty"`
	// The workspace file system path of the source code used to create the app
	// deployment. This is different from
	// `deployment_artifacts.source_code_path`, which is the path used by the
	// deployed app. The former refers to the original source code location of
	// the app in the workspace during deployment creation, whereas the latter
	// provides a system generated stable snapshotted source code path used by
	// the deployment.
	SourceCodePath string `json:"source_code_path,omitempty"`
	// Status and status message of the deployment
	Status *AppDeploymentStatus `json:"status,omitempty"`
	// The update time of the deployment. Formatted timestamp in ISO 6801.
	UpdateTime string `json:"update_time,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (AppDeployment) MarshalJSON

func (s AppDeployment) MarshalJSON() ([]byte, error)

func (*AppDeployment) UnmarshalJSON

func (s *AppDeployment) UnmarshalJSON(b []byte) error

type AppDeploymentArtifacts

type AppDeploymentArtifacts struct {
	// The snapshotted workspace file system path of the source code loaded by
	// the deployed app.
	SourceCodePath string `json:"source_code_path,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (AppDeploymentArtifacts) MarshalJSON

func (s AppDeploymentArtifacts) MarshalJSON() ([]byte, error)

func (*AppDeploymentArtifacts) UnmarshalJSON

func (s *AppDeploymentArtifacts) UnmarshalJSON(b []byte) error

type AppDeploymentMode

type AppDeploymentMode string
const AppDeploymentModeAutoSync AppDeploymentMode = `AUTO_SYNC`
const AppDeploymentModeSnapshot AppDeploymentMode = `SNAPSHOT`

func (*AppDeploymentMode) Set

func (f *AppDeploymentMode) Set(v string) error

Set raw string value and validate it against allowed values

func (*AppDeploymentMode) String

func (f *AppDeploymentMode) String() string

String representation for fmt.Print

func (*AppDeploymentMode) Type

func (f *AppDeploymentMode) Type() string

Type always returns AppDeploymentMode to satisfy [pflag.Value] interface

func (*AppDeploymentMode) Values added in v0.72.0

func (f *AppDeploymentMode) Values() []AppDeploymentMode

Values returns all possible values for AppDeploymentMode.

There is no guarantee on the order of the values in the slice.

type AppDeploymentState

type AppDeploymentState string
const AppDeploymentStateCancelled AppDeploymentState = `CANCELLED`
const AppDeploymentStateFailed AppDeploymentState = `FAILED`
const AppDeploymentStateInProgress AppDeploymentState = `IN_PROGRESS`
const AppDeploymentStateSucceeded AppDeploymentState = `SUCCEEDED`

func (*AppDeploymentState) Set

func (f *AppDeploymentState) Set(v string) error

Set raw string value and validate it against allowed values

func (*AppDeploymentState) String

func (f *AppDeploymentState) String() string

String representation for fmt.Print

func (*AppDeploymentState) Type

func (f *AppDeploymentState) Type() string

Type always returns AppDeploymentState to satisfy [pflag.Value] interface

func (*AppDeploymentState) Values added in v0.72.0

func (f *AppDeploymentState) Values() []AppDeploymentState

Values returns all possible values for AppDeploymentState.

There is no guarantee on the order of the values in the slice.

type AppDeploymentStatus

type AppDeploymentStatus struct {
	// Message corresponding with the deployment state.
	Message string `json:"message,omitempty"`
	// State of the deployment.
	State AppDeploymentState `json:"state,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (AppDeploymentStatus) MarshalJSON

func (s AppDeploymentStatus) MarshalJSON() ([]byte, error)

func (*AppDeploymentStatus) UnmarshalJSON

func (s *AppDeploymentStatus) UnmarshalJSON(b []byte) error

type AppManifest added in v0.81.0

type AppManifest struct {
	// Description of the app defined by manifest author / publisher
	Description string `json:"description,omitempty"`
	// Name of the app defined by manifest author / publisher
	Name string `json:"name"`

	ResourceSpecs []AppManifestAppResourceSpec `json:"resource_specs,omitempty"`
	// The manifest schema version, for now only 1 is allowed
	Version int `json:"version"`

	ForceSendFields []string `json:"-" url:"-"`
}

App manifest definition

func (AppManifest) MarshalJSON added in v0.81.0

func (s AppManifest) MarshalJSON() ([]byte, error)

func (*AppManifest) UnmarshalJSON added in v0.81.0

func (s *AppManifest) UnmarshalJSON(b []byte) error

type AppManifestAppResourceJobSpec added in v0.81.0

type AppManifestAppResourceJobSpec struct {
	// Permissions to grant on the Job. Supported permissions are: "CAN_MANAGE",
	// "IS_OWNER", "CAN_MANAGE_RUN", "CAN_VIEW".
	Permission AppManifestAppResourceJobSpecJobPermission `json:"permission"`
}

type AppManifestAppResourceJobSpecJobPermission added in v0.81.0

type AppManifestAppResourceJobSpecJobPermission string
const AppManifestAppResourceJobSpecJobPermissionCanManage AppManifestAppResourceJobSpecJobPermission = `CAN_MANAGE`
const AppManifestAppResourceJobSpecJobPermissionCanManageRun AppManifestAppResourceJobSpecJobPermission = `CAN_MANAGE_RUN`
const AppManifestAppResourceJobSpecJobPermissionCanView AppManifestAppResourceJobSpecJobPermission = `CAN_VIEW`
const AppManifestAppResourceJobSpecJobPermissionIsOwner AppManifestAppResourceJobSpecJobPermission = `IS_OWNER`

func (*AppManifestAppResourceJobSpecJobPermission) Set added in v0.81.0

Set raw string value and validate it against allowed values

func (*AppManifestAppResourceJobSpecJobPermission) String added in v0.81.0

String representation for fmt.Print

func (*AppManifestAppResourceJobSpecJobPermission) Type added in v0.81.0

Type always returns AppManifestAppResourceJobSpecJobPermission to satisfy [pflag.Value] interface

func (*AppManifestAppResourceJobSpecJobPermission) Values added in v0.81.0

Values returns all possible values for AppManifestAppResourceJobSpecJobPermission.

There is no guarantee on the order of the values in the slice.

type AppManifestAppResourceSecretSpec added in v0.81.0

type AppManifestAppResourceSecretSpec struct {
	// Permission to grant on the secret scope. For secrets, only one permission
	// is allowed. Permission must be one of: "READ", "WRITE", "MANAGE".
	Permission AppManifestAppResourceSecretSpecSecretPermission `json:"permission"`
}

type AppManifestAppResourceSecretSpecSecretPermission added in v0.81.0

type AppManifestAppResourceSecretSpecSecretPermission string

Permission to grant on the secret scope. Supported permissions are: "READ", "WRITE", "MANAGE".

const AppManifestAppResourceSecretSpecSecretPermissionManage AppManifestAppResourceSecretSpecSecretPermission = `MANAGE`
const AppManifestAppResourceSecretSpecSecretPermissionRead AppManifestAppResourceSecretSpecSecretPermission = `READ`
const AppManifestAppResourceSecretSpecSecretPermissionWrite AppManifestAppResourceSecretSpecSecretPermission = `WRITE`

func (*AppManifestAppResourceSecretSpecSecretPermission) Set added in v0.81.0

Set raw string value and validate it against allowed values

func (*AppManifestAppResourceSecretSpecSecretPermission) String added in v0.81.0

String representation for fmt.Print

func (*AppManifestAppResourceSecretSpecSecretPermission) Type added in v0.81.0

Type always returns AppManifestAppResourceSecretSpecSecretPermission to satisfy [pflag.Value] interface

func (*AppManifestAppResourceSecretSpecSecretPermission) Values added in v0.81.0

Values returns all possible values for AppManifestAppResourceSecretSpecSecretPermission.

There is no guarantee on the order of the values in the slice.

type AppManifestAppResourceServingEndpointSpec added in v0.81.0

type AppManifestAppResourceServingEndpointSpec struct {
	// Permission to grant on the serving endpoint. Supported permissions are:
	// "CAN_MANAGE", "CAN_QUERY", "CAN_VIEW".
	Permission AppManifestAppResourceServingEndpointSpecServingEndpointPermission `json:"permission"`
}

type AppManifestAppResourceServingEndpointSpecServingEndpointPermission added in v0.81.0

type AppManifestAppResourceServingEndpointSpecServingEndpointPermission string
const AppManifestAppResourceServingEndpointSpecServingEndpointPermissionCanManage AppManifestAppResourceServingEndpointSpecServingEndpointPermission = `CAN_MANAGE`
const AppManifestAppResourceServingEndpointSpecServingEndpointPermissionCanQuery AppManifestAppResourceServingEndpointSpecServingEndpointPermission = `CAN_QUERY`
const AppManifestAppResourceServingEndpointSpecServingEndpointPermissionCanView AppManifestAppResourceServingEndpointSpecServingEndpointPermission = `CAN_VIEW`

func (*AppManifestAppResourceServingEndpointSpecServingEndpointPermission) Set added in v0.81.0

Set raw string value and validate it against allowed values

func (*AppManifestAppResourceServingEndpointSpecServingEndpointPermission) String added in v0.81.0

String representation for fmt.Print

func (*AppManifestAppResourceServingEndpointSpecServingEndpointPermission) Type added in v0.81.0

Type always returns AppManifestAppResourceServingEndpointSpecServingEndpointPermission to satisfy [pflag.Value] interface

func (*AppManifestAppResourceServingEndpointSpecServingEndpointPermission) Values added in v0.81.0

Values returns all possible values for AppManifestAppResourceServingEndpointSpecServingEndpointPermission.

There is no guarantee on the order of the values in the slice.

type AppManifestAppResourceSpec added in v0.81.0

type AppManifestAppResourceSpec struct {
	// Description of the App Resource.
	Description string `json:"description,omitempty"`

	JobSpec *AppManifestAppResourceJobSpec `json:"job_spec,omitempty"`
	// Name of the App Resource.
	Name string `json:"name"`

	SecretSpec *AppManifestAppResourceSecretSpec `json:"secret_spec,omitempty"`

	ServingEndpointSpec *AppManifestAppResourceServingEndpointSpec `json:"serving_endpoint_spec,omitempty"`

	SqlWarehouseSpec *AppManifestAppResourceSqlWarehouseSpec `json:"sql_warehouse_spec,omitempty"`

	UcSecurableSpec *AppManifestAppResourceUcSecurableSpec `json:"uc_securable_spec,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

AppResource related fields are copied from app.proto but excludes resource identifiers (e.g. name, id, key, scope, etc.)

func (AppManifestAppResourceSpec) MarshalJSON added in v0.81.0

func (s AppManifestAppResourceSpec) MarshalJSON() ([]byte, error)

func (*AppManifestAppResourceSpec) UnmarshalJSON added in v0.81.0

func (s *AppManifestAppResourceSpec) UnmarshalJSON(b []byte) error

type AppManifestAppResourceSqlWarehouseSpec added in v0.81.0

type AppManifestAppResourceSqlWarehouseSpec struct {
	// Permission to grant on the SQL warehouse. Supported permissions are:
	// "CAN_MANAGE", "CAN_USE", "IS_OWNER".
	Permission AppManifestAppResourceSqlWarehouseSpecSqlWarehousePermission `json:"permission"`
}

type AppManifestAppResourceSqlWarehouseSpecSqlWarehousePermission added in v0.81.0

type AppManifestAppResourceSqlWarehouseSpecSqlWarehousePermission string
const AppManifestAppResourceSqlWarehouseSpecSqlWarehousePermissionCanManage AppManifestAppResourceSqlWarehouseSpecSqlWarehousePermission = `CAN_MANAGE`
const AppManifestAppResourceSqlWarehouseSpecSqlWarehousePermissionCanUse AppManifestAppResourceSqlWarehouseSpecSqlWarehousePermission = `CAN_USE`
const AppManifestAppResourceSqlWarehouseSpecSqlWarehousePermissionIsOwner AppManifestAppResourceSqlWarehouseSpecSqlWarehousePermission = `IS_OWNER`

func (*AppManifestAppResourceSqlWarehouseSpecSqlWarehousePermission) Set added in v0.81.0

Set raw string value and validate it against allowed values

func (*AppManifestAppResourceSqlWarehouseSpecSqlWarehousePermission) String added in v0.81.0

String representation for fmt.Print

func (*AppManifestAppResourceSqlWarehouseSpecSqlWarehousePermission) Type added in v0.81.0

Type always returns AppManifestAppResourceSqlWarehouseSpecSqlWarehousePermission to satisfy [pflag.Value] interface

func (*AppManifestAppResourceSqlWarehouseSpecSqlWarehousePermission) Values added in v0.81.0

Values returns all possible values for AppManifestAppResourceSqlWarehouseSpecSqlWarehousePermission.

There is no guarantee on the order of the values in the slice.

type AppManifestAppResourceUcSecurableSpec added in v0.81.0

type AppManifestAppResourceUcSecurableSpec struct {
	Permission AppManifestAppResourceUcSecurableSpecUcSecurablePermission `json:"permission"`

	SecurableType AppManifestAppResourceUcSecurableSpecUcSecurableType `json:"securable_type"`
}

type AppManifestAppResourceUcSecurableSpecUcSecurablePermission added in v0.81.0

type AppManifestAppResourceUcSecurableSpecUcSecurablePermission string
const AppManifestAppResourceUcSecurableSpecUcSecurablePermissionManage AppManifestAppResourceUcSecurableSpecUcSecurablePermission = `MANAGE`
const AppManifestAppResourceUcSecurableSpecUcSecurablePermissionReadVolume AppManifestAppResourceUcSecurableSpecUcSecurablePermission = `READ_VOLUME`
const AppManifestAppResourceUcSecurableSpecUcSecurablePermissionWriteVolume AppManifestAppResourceUcSecurableSpecUcSecurablePermission = `WRITE_VOLUME`

func (*AppManifestAppResourceUcSecurableSpecUcSecurablePermission) Set added in v0.81.0

Set raw string value and validate it against allowed values

func (*AppManifestAppResourceUcSecurableSpecUcSecurablePermission) String added in v0.81.0

String representation for fmt.Print

func (*AppManifestAppResourceUcSecurableSpecUcSecurablePermission) Type added in v0.81.0

Type always returns AppManifestAppResourceUcSecurableSpecUcSecurablePermission to satisfy [pflag.Value] interface

func (*AppManifestAppResourceUcSecurableSpecUcSecurablePermission) Values added in v0.81.0

Values returns all possible values for AppManifestAppResourceUcSecurableSpecUcSecurablePermission.

There is no guarantee on the order of the values in the slice.

type AppManifestAppResourceUcSecurableSpecUcSecurableType added in v0.81.0

type AppManifestAppResourceUcSecurableSpecUcSecurableType string
const AppManifestAppResourceUcSecurableSpecUcSecurableTypeVolume AppManifestAppResourceUcSecurableSpecUcSecurableType = `VOLUME`

func (*AppManifestAppResourceUcSecurableSpecUcSecurableType) Set added in v0.81.0

Set raw string value and validate it against allowed values

func (*AppManifestAppResourceUcSecurableSpecUcSecurableType) String added in v0.81.0

String representation for fmt.Print

func (*AppManifestAppResourceUcSecurableSpecUcSecurableType) Type added in v0.81.0

Type always returns AppManifestAppResourceUcSecurableSpecUcSecurableType to satisfy [pflag.Value] interface

func (*AppManifestAppResourceUcSecurableSpecUcSecurableType) Values added in v0.81.0

Values returns all possible values for AppManifestAppResourceUcSecurableSpecUcSecurableType.

There is no guarantee on the order of the values in the slice.

type AppPermission

type AppPermission struct {
	Inherited bool `json:"inherited,omitempty"`

	InheritedFromObject []string `json:"inherited_from_object,omitempty"`

	PermissionLevel AppPermissionLevel `json:"permission_level,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (AppPermission) MarshalJSON

func (s AppPermission) MarshalJSON() ([]byte, error)

func (*AppPermission) UnmarshalJSON

func (s *AppPermission) UnmarshalJSON(b []byte) error

type AppPermissionLevel

type AppPermissionLevel string

Permission level

const AppPermissionLevelCanManage AppPermissionLevel = `CAN_MANAGE`
const AppPermissionLevelCanUse AppPermissionLevel = `CAN_USE`

func (*AppPermissionLevel) Set

func (f *AppPermissionLevel) Set(v string) error

Set raw string value and validate it against allowed values

func (*AppPermissionLevel) String

func (f *AppPermissionLevel) String() string

String representation for fmt.Print

func (*AppPermissionLevel) Type

func (f *AppPermissionLevel) Type() string

Type always returns AppPermissionLevel to satisfy [pflag.Value] interface

func (*AppPermissionLevel) Values added in v0.72.0

func (f *AppPermissionLevel) Values() []AppPermissionLevel

Values returns all possible values for AppPermissionLevel.

There is no guarantee on the order of the values in the slice.

type AppPermissions

type AppPermissions struct {
	AccessControlList []AppAccessControlResponse `json:"access_control_list,omitempty"`

	ObjectId string `json:"object_id,omitempty"`

	ObjectType string `json:"object_type,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (AppPermissions) MarshalJSON

func (s AppPermissions) MarshalJSON() ([]byte, error)

func (*AppPermissions) UnmarshalJSON

func (s *AppPermissions) UnmarshalJSON(b []byte) error

type AppPermissionsDescription

type AppPermissionsDescription struct {
	Description string `json:"description,omitempty"`

	PermissionLevel AppPermissionLevel `json:"permission_level,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (AppPermissionsDescription) MarshalJSON

func (s AppPermissionsDescription) MarshalJSON() ([]byte, error)

func (*AppPermissionsDescription) UnmarshalJSON

func (s *AppPermissionsDescription) UnmarshalJSON(b []byte) error

type AppPermissionsRequest

type AppPermissionsRequest struct {
	AccessControlList []AppAccessControlRequest `json:"access_control_list,omitempty"`
	// The app for which to get or manage permissions.
	AppName string `json:"-" url:"-"`
}

type AppResource added in v0.48.0

type AppResource struct {
	Database *AppResourceDatabase `json:"database,omitempty"`
	// Description of the App Resource.
	Description string `json:"description,omitempty"`

	Job *AppResourceJob `json:"job,omitempty"`
	// Name of the App Resource.
	Name string `json:"name"`

	Secret *AppResourceSecret `json:"secret,omitempty"`

	ServingEndpoint *AppResourceServingEndpoint `json:"serving_endpoint,omitempty"`

	SqlWarehouse *AppResourceSqlWarehouse `json:"sql_warehouse,omitempty"`

	UcSecurable *AppResourceUcSecurable `json:"uc_securable,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (AppResource) MarshalJSON added in v0.48.0

func (s AppResource) MarshalJSON() ([]byte, error)

func (*AppResource) UnmarshalJSON added in v0.48.0

func (s *AppResource) UnmarshalJSON(b []byte) error

type AppResourceDatabase added in v0.75.0

type AppResourceDatabase struct {
	DatabaseName string `json:"database_name"`

	InstanceName string `json:"instance_name"`

	Permission AppResourceDatabaseDatabasePermission `json:"permission"`
}

type AppResourceDatabaseDatabasePermission added in v0.75.0

type AppResourceDatabaseDatabasePermission string
const AppResourceDatabaseDatabasePermissionCanConnectAndCreate AppResourceDatabaseDatabasePermission = `CAN_CONNECT_AND_CREATE`

func (*AppResourceDatabaseDatabasePermission) Set added in v0.75.0

Set raw string value and validate it against allowed values

func (*AppResourceDatabaseDatabasePermission) String added in v0.75.0

String representation for fmt.Print

func (*AppResourceDatabaseDatabasePermission) Type added in v0.75.0

Type always returns AppResourceDatabaseDatabasePermission to satisfy [pflag.Value] interface

func (*AppResourceDatabaseDatabasePermission) Values added in v0.75.0

Values returns all possible values for AppResourceDatabaseDatabasePermission.

There is no guarantee on the order of the values in the slice.

type AppResourceJob added in v0.48.0

type AppResourceJob struct {
	// Id of the job to grant permission on.
	Id string `json:"id"`
	// Permissions to grant on the Job. Supported permissions are: "CAN_MANAGE",
	// "IS_OWNER", "CAN_MANAGE_RUN", "CAN_VIEW".
	Permission AppResourceJobJobPermission `json:"permission"`
}

type AppResourceJobJobPermission added in v0.48.0

type AppResourceJobJobPermission string
const AppResourceJobJobPermissionCanManage AppResourceJobJobPermission = `CAN_MANAGE`
const AppResourceJobJobPermissionCanManageRun AppResourceJobJobPermission = `CAN_MANAGE_RUN`
const AppResourceJobJobPermissionCanView AppResourceJobJobPermission = `CAN_VIEW`
const AppResourceJobJobPermissionIsOwner AppResourceJobJobPermission = `IS_OWNER`

func (*AppResourceJobJobPermission) Set added in v0.48.0

Set raw string value and validate it against allowed values

func (*AppResourceJobJobPermission) String added in v0.48.0

func (f *AppResourceJobJobPermission) String() string

String representation for fmt.Print

func (*AppResourceJobJobPermission) Type added in v0.48.0

Type always returns AppResourceJobJobPermission to satisfy [pflag.Value] interface

func (*AppResourceJobJobPermission) Values added in v0.72.0

Values returns all possible values for AppResourceJobJobPermission.

There is no guarantee on the order of the values in the slice.

type AppResourceSecret added in v0.48.0

type AppResourceSecret struct {
	// Key of the secret to grant permission on.
	Key string `json:"key"`
	// Permission to grant on the secret scope. For secrets, only one permission
	// is allowed. Permission must be one of: "READ", "WRITE", "MANAGE".
	Permission AppResourceSecretSecretPermission `json:"permission"`
	// Scope of the secret to grant permission on.
	Scope string `json:"scope"`
}

type AppResourceSecretSecretPermission added in v0.48.0

type AppResourceSecretSecretPermission string

Permission to grant on the secret scope. Supported permissions are: "READ", "WRITE", "MANAGE".

const AppResourceSecretSecretPermissionManage AppResourceSecretSecretPermission = `MANAGE`
const AppResourceSecretSecretPermissionRead AppResourceSecretSecretPermission = `READ`
const AppResourceSecretSecretPermissionWrite AppResourceSecretSecretPermission = `WRITE`

func (*AppResourceSecretSecretPermission) Set added in v0.48.0

Set raw string value and validate it against allowed values

func (*AppResourceSecretSecretPermission) String added in v0.48.0

String representation for fmt.Print

func (*AppResourceSecretSecretPermission) Type added in v0.48.0

Type always returns AppResourceSecretSecretPermission to satisfy [pflag.Value] interface

func (*AppResourceSecretSecretPermission) Values added in v0.72.0

Values returns all possible values for AppResourceSecretSecretPermission.

There is no guarantee on the order of the values in the slice.

type AppResourceServingEndpoint added in v0.48.0

type AppResourceServingEndpoint struct {
	// Name of the serving endpoint to grant permission on.
	Name string `json:"name"`
	// Permission to grant on the serving endpoint. Supported permissions are:
	// "CAN_MANAGE", "CAN_QUERY", "CAN_VIEW".
	Permission AppResourceServingEndpointServingEndpointPermission `json:"permission"`
}

type AppResourceServingEndpointServingEndpointPermission added in v0.48.0

type AppResourceServingEndpointServingEndpointPermission string
const AppResourceServingEndpointServingEndpointPermissionCanManage AppResourceServingEndpointServingEndpointPermission = `CAN_MANAGE`
const AppResourceServingEndpointServingEndpointPermissionCanQuery AppResourceServingEndpointServingEndpointPermission = `CAN_QUERY`
const AppResourceServingEndpointServingEndpointPermissionCanView AppResourceServingEndpointServingEndpointPermission = `CAN_VIEW`

func (*AppResourceServingEndpointServingEndpointPermission) Set added in v0.48.0

Set raw string value and validate it against allowed values

func (*AppResourceServingEndpointServingEndpointPermission) String added in v0.48.0

String representation for fmt.Print

func (*AppResourceServingEndpointServingEndpointPermission) Type added in v0.48.0

Type always returns AppResourceServingEndpointServingEndpointPermission to satisfy [pflag.Value] interface

func (*AppResourceServingEndpointServingEndpointPermission) Values added in v0.72.0

Values returns all possible values for AppResourceServingEndpointServingEndpointPermission.

There is no guarantee on the order of the values in the slice.

type AppResourceSqlWarehouse added in v0.48.0

type AppResourceSqlWarehouse struct {
	// Id of the SQL warehouse to grant permission on.
	Id string `json:"id"`
	// Permission to grant on the SQL warehouse. Supported permissions are:
	// "CAN_MANAGE", "CAN_USE", "IS_OWNER".
	Permission AppResourceSqlWarehouseSqlWarehousePermission `json:"permission"`
}

type AppResourceSqlWarehouseSqlWarehousePermission added in v0.48.0

type AppResourceSqlWarehouseSqlWarehousePermission string
const AppResourceSqlWarehouseSqlWarehousePermissionCanManage AppResourceSqlWarehouseSqlWarehousePermission = `CAN_MANAGE`
const AppResourceSqlWarehouseSqlWarehousePermissionCanUse AppResourceSqlWarehouseSqlWarehousePermission = `CAN_USE`
const AppResourceSqlWarehouseSqlWarehousePermissionIsOwner AppResourceSqlWarehouseSqlWarehousePermission = `IS_OWNER`

func (*AppResourceSqlWarehouseSqlWarehousePermission) Set added in v0.48.0

Set raw string value and validate it against allowed values

func (*AppResourceSqlWarehouseSqlWarehousePermission) String added in v0.48.0

String representation for fmt.Print

func (*AppResourceSqlWarehouseSqlWarehousePermission) Type added in v0.48.0

Type always returns AppResourceSqlWarehouseSqlWarehousePermission to satisfy [pflag.Value] interface

func (*AppResourceSqlWarehouseSqlWarehousePermission) Values added in v0.72.0

Values returns all possible values for AppResourceSqlWarehouseSqlWarehousePermission.

There is no guarantee on the order of the values in the slice.

type AppResourceUcSecurable added in v0.70.0

type AppResourceUcSecurable struct {
	Permission AppResourceUcSecurableUcSecurablePermission `json:"permission"`

	SecurableFullName string `json:"securable_full_name"`

	SecurableType AppResourceUcSecurableUcSecurableType `json:"securable_type"`
}

type AppResourceUcSecurableUcSecurablePermission added in v0.70.0

type AppResourceUcSecurableUcSecurablePermission string
const AppResourceUcSecurableUcSecurablePermissionReadVolume AppResourceUcSecurableUcSecurablePermission = `READ_VOLUME`
const AppResourceUcSecurableUcSecurablePermissionWriteVolume AppResourceUcSecurableUcSecurablePermission = `WRITE_VOLUME`

func (*AppResourceUcSecurableUcSecurablePermission) Set added in v0.70.0

Set raw string value and validate it against allowed values

func (*AppResourceUcSecurableUcSecurablePermission) String added in v0.70.0

String representation for fmt.Print

func (*AppResourceUcSecurableUcSecurablePermission) Type added in v0.70.0

Type always returns AppResourceUcSecurableUcSecurablePermission to satisfy [pflag.Value] interface

func (*AppResourceUcSecurableUcSecurablePermission) Values added in v0.72.0

Values returns all possible values for AppResourceUcSecurableUcSecurablePermission.

There is no guarantee on the order of the values in the slice.

type AppResourceUcSecurableUcSecurableType added in v0.70.0

type AppResourceUcSecurableUcSecurableType string
const AppResourceUcSecurableUcSecurableTypeVolume AppResourceUcSecurableUcSecurableType = `VOLUME`

func (*AppResourceUcSecurableUcSecurableType) Set added in v0.70.0

Set raw string value and validate it against allowed values

func (*AppResourceUcSecurableUcSecurableType) String added in v0.70.0

String representation for fmt.Print

func (*AppResourceUcSecurableUcSecurableType) Type added in v0.70.0

Type always returns AppResourceUcSecurableUcSecurableType to satisfy [pflag.Value] interface

func (*AppResourceUcSecurableUcSecurableType) Values added in v0.72.0

Values returns all possible values for AppResourceUcSecurableUcSecurableType.

There is no guarantee on the order of the values in the slice.

type ApplicationState added in v0.47.0

type ApplicationState string
const ApplicationStateCrashed ApplicationState = `CRASHED`
const ApplicationStateDeploying ApplicationState = `DEPLOYING`
const ApplicationStateRunning ApplicationState = `RUNNING`
const ApplicationStateUnavailable ApplicationState = `UNAVAILABLE`

func (*ApplicationState) Set added in v0.47.0

func (f *ApplicationState) Set(v string) error

Set raw string value and validate it against allowed values

func (*ApplicationState) String added in v0.47.0

func (f *ApplicationState) String() string

String representation for fmt.Print

func (*ApplicationState) Type added in v0.47.0

func (f *ApplicationState) Type() string

Type always returns ApplicationState to satisfy [pflag.Value] interface

func (*ApplicationState) Values added in v0.72.0

func (f *ApplicationState) Values() []ApplicationState

Values returns all possible values for ApplicationState.

There is no guarantee on the order of the values in the slice.

type ApplicationStatus added in v0.47.0

type ApplicationStatus struct {
	// Application status message
	Message string `json:"message,omitempty"`
	// State of the application.
	State ApplicationState `json:"state,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (ApplicationStatus) MarshalJSON added in v0.47.0

func (s ApplicationStatus) MarshalJSON() ([]byte, error)

func (*ApplicationStatus) UnmarshalJSON added in v0.47.0

func (s *ApplicationStatus) UnmarshalJSON(b []byte) error

type AppsAPI

type AppsAPI struct {
	// contains filtered or unexported fields
}

Apps run directly on a customer’s Databricks instance, integrate with their data, use and extend Databricks services, and enable users to interact through single sign-on.

func NewApps

func NewApps(client *client.DatabricksClient) *AppsAPI

func (*AppsAPI) Create

func (a *AppsAPI) Create(ctx context.Context, createAppRequest CreateAppRequest) (*WaitGetAppActive[App], error)

Creates a new app.

func (*AppsAPI) CreateAndWait deprecated

func (a *AppsAPI) CreateAndWait(ctx context.Context, createAppRequest CreateAppRequest, options ...retries.Option[App]) (*App, error)

Calls AppsAPI.Create and waits to reach ACTIVE state

You can override the default timeout of 20 minutes by calling adding retries.Timeout[App](60*time.Minute) functional option.

Deprecated: use AppsAPI.Create.Get() or AppsAPI.WaitGetAppActive

func (*AppsAPI) Delete

func (a *AppsAPI) Delete(ctx context.Context, request DeleteAppRequest) (*App, error)

func (*AppsAPI) DeleteByName

func (a *AppsAPI) DeleteByName(ctx context.Context, name string) (*App, error)

Deletes an app.

func (*AppsAPI) Deploy

func (a *AppsAPI) Deploy(ctx context.Context, createAppDeploymentRequest CreateAppDeploymentRequest) (*WaitGetDeploymentAppSucceeded[AppDeployment], error)

Creates an app deployment for the app with the supplied name.

func (*AppsAPI) DeployAndWait deprecated

func (a *AppsAPI) DeployAndWait(ctx context.Context, createAppDeploymentRequest CreateAppDeploymentRequest, options ...retries.Option[AppDeployment]) (*AppDeployment, error)

Calls AppsAPI.Deploy and waits to reach SUCCEEDED state

You can override the default timeout of 20 minutes by calling adding retries.Timeout[AppDeployment](60*time.Minute) functional option.

Deprecated: use AppsAPI.Deploy.Get() or AppsAPI.WaitGetDeploymentAppSucceeded

func (*AppsAPI) Get

func (a *AppsAPI) Get(ctx context.Context, request GetAppRequest) (*App, error)

func (*AppsAPI) GetByName

func (a *AppsAPI) GetByName(ctx context.Context, name string) (*App, error)

Retrieves information for the app with the supplied name.

func (*AppsAPI) GetDeployment

func (a *AppsAPI) GetDeployment(ctx context.Context, request GetAppDeploymentRequest) (*AppDeployment, error)

func (*AppsAPI) GetDeploymentByAppNameAndDeploymentId

func (a *AppsAPI) GetDeploymentByAppNameAndDeploymentId(ctx context.Context, appName string, deploymentId string) (*AppDeployment, error)

Retrieves information for the app deployment with the supplied name and deployment id.

func (*AppsAPI) GetPermissionLevels

func (a *AppsAPI) GetPermissionLevels(ctx context.Context, request GetAppPermissionLevelsRequest) (*GetAppPermissionLevelsResponse, error)

func (*AppsAPI) GetPermissionLevelsByAppName

func (a *AppsAPI) GetPermissionLevelsByAppName(ctx context.Context, appName string) (*GetAppPermissionLevelsResponse, error)

Gets the permission levels that a user can have on an object.

func (*AppsAPI) GetPermissions

func (a *AppsAPI) GetPermissions(ctx context.Context, request GetAppPermissionsRequest) (*AppPermissions, error)

func (*AppsAPI) GetPermissionsByAppName

func (a *AppsAPI) GetPermissionsByAppName(ctx context.Context, appName string) (*AppPermissions, error)

Gets the permissions of an app. Apps can inherit permissions from their root object.

func (*AppsAPI) List

func (a *AppsAPI) List(ctx context.Context, request ListAppsRequest) listing.Iterator[App]

Lists all apps in the workspace.

func (*AppsAPI) ListAll

func (a *AppsAPI) ListAll(ctx context.Context, request ListAppsRequest) ([]App, error)

Lists all apps in the workspace.

func (*AppsAPI) ListDeployments

func (a *AppsAPI) ListDeployments(ctx context.Context, request ListAppDeploymentsRequest) listing.Iterator[AppDeployment]

Lists all app deployments for the app with the supplied name.

func (*AppsAPI) ListDeploymentsAll

func (a *AppsAPI) ListDeploymentsAll(ctx context.Context, request ListAppDeploymentsRequest) ([]AppDeployment, error)

Lists all app deployments for the app with the supplied name.

func (*AppsAPI) ListDeploymentsByAppName

func (a *AppsAPI) ListDeploymentsByAppName(ctx context.Context, appName string) (*ListAppDeploymentsResponse, error)

Lists all app deployments for the app with the supplied name.

func (*AppsAPI) SetPermissions

func (a *AppsAPI) SetPermissions(ctx context.Context, request AppPermissionsRequest) (*AppPermissions, error)

func (*AppsAPI) Start

func (a *AppsAPI) Start(ctx context.Context, startAppRequest StartAppRequest) (*WaitGetAppActive[App], error)

Start the last active deployment of the app in the workspace.

func (*AppsAPI) StartAndWait deprecated

func (a *AppsAPI) StartAndWait(ctx context.Context, startAppRequest StartAppRequest, options ...retries.Option[App]) (*App, error)

Calls AppsAPI.Start and waits to reach ACTIVE state

You can override the default timeout of 20 minutes by calling adding retries.Timeout[App](60*time.Minute) functional option.

Deprecated: use AppsAPI.Start.Get() or AppsAPI.WaitGetAppActive

func (*AppsAPI) Stop

func (a *AppsAPI) Stop(ctx context.Context, stopAppRequest StopAppRequest) (*WaitGetAppStopped[App], error)

Stops the active deployment of the app in the workspace.

func (*AppsAPI) StopAndWait deprecated added in v0.47.0

func (a *AppsAPI) StopAndWait(ctx context.Context, stopAppRequest StopAppRequest, options ...retries.Option[App]) (*App, error)

Calls AppsAPI.Stop and waits to reach STOPPED state

You can override the default timeout of 20 minutes by calling adding retries.Timeout[App](60*time.Minute) functional option.

Deprecated: use AppsAPI.Stop.Get() or AppsAPI.WaitGetAppStopped

func (*AppsAPI) Update

func (a *AppsAPI) Update(ctx context.Context, request UpdateAppRequest) (*App, error)

func (*AppsAPI) UpdatePermissions

func (a *AppsAPI) UpdatePermissions(ctx context.Context, request AppPermissionsRequest) (*AppPermissions, error)

func (*AppsAPI) WaitGetAppActive added in v0.47.0

func (a *AppsAPI) WaitGetAppActive(ctx context.Context, name string,
	timeout time.Duration, callback func(*App)) (*App, error)

WaitGetAppActive repeatedly calls AppsAPI.Get and waits to reach ACTIVE state

func (*AppsAPI) WaitGetAppStopped added in v0.47.0

func (a *AppsAPI) WaitGetAppStopped(ctx context.Context, name string,
	timeout time.Duration, callback func(*App)) (*App, error)

WaitGetAppStopped repeatedly calls AppsAPI.Get and waits to reach STOPPED state

func (*AppsAPI) WaitGetDeploymentAppSucceeded

func (a *AppsAPI) WaitGetDeploymentAppSucceeded(ctx context.Context, appName string, deploymentId string,
	timeout time.Duration, callback func(*AppDeployment)) (*AppDeployment, error)

WaitGetDeploymentAppSucceeded repeatedly calls AppsAPI.GetDeployment and waits to reach SUCCEEDED state

type AppsInterface

type AppsInterface interface {

	// WaitGetAppActive repeatedly calls [AppsAPI.Get] and waits to reach ACTIVE state
	WaitGetAppActive(ctx context.Context, name string,
		timeout time.Duration, callback func(*App)) (*App, error)

	// WaitGetDeploymentAppSucceeded repeatedly calls [AppsAPI.GetDeployment] and waits to reach SUCCEEDED state
	WaitGetDeploymentAppSucceeded(ctx context.Context, appName string, deploymentId string,
		timeout time.Duration, callback func(*AppDeployment)) (*AppDeployment, error)

	// WaitGetAppStopped repeatedly calls [AppsAPI.Get] and waits to reach STOPPED state
	WaitGetAppStopped(ctx context.Context, name string,
		timeout time.Duration, callback func(*App)) (*App, error)

	// Creates a new app.
	Create(ctx context.Context, createAppRequest CreateAppRequest) (*WaitGetAppActive[App], error)

	// Calls [AppsAPIInterface.Create] and waits to reach ACTIVE state
	//
	// You can override the default timeout of 20 minutes by calling adding
	// retries.Timeout[App](60*time.Minute) functional option.
	//
	// Deprecated: use [AppsAPIInterface.Create].Get() or [AppsAPIInterface.WaitGetAppActive]
	CreateAndWait(ctx context.Context, createAppRequest CreateAppRequest, options ...retries.Option[App]) (*App, error)

	// Deletes an app.
	Delete(ctx context.Context, request DeleteAppRequest) (*App, error)

	// Deletes an app.
	DeleteByName(ctx context.Context, name string) (*App, error)

	// Creates an app deployment for the app with the supplied name.
	Deploy(ctx context.Context, createAppDeploymentRequest CreateAppDeploymentRequest) (*WaitGetDeploymentAppSucceeded[AppDeployment], error)

	// Calls [AppsAPIInterface.Deploy] and waits to reach SUCCEEDED state
	//
	// You can override the default timeout of 20 minutes by calling adding
	// retries.Timeout[AppDeployment](60*time.Minute) functional option.
	//
	// Deprecated: use [AppsAPIInterface.Deploy].Get() or [AppsAPIInterface.WaitGetDeploymentAppSucceeded]
	DeployAndWait(ctx context.Context, createAppDeploymentRequest CreateAppDeploymentRequest, options ...retries.Option[AppDeployment]) (*AppDeployment, error)

	// Retrieves information for the app with the supplied name.
	Get(ctx context.Context, request GetAppRequest) (*App, error)

	// Retrieves information for the app with the supplied name.
	GetByName(ctx context.Context, name string) (*App, error)

	// Retrieves information for the app deployment with the supplied name and
	// deployment id.
	GetDeployment(ctx context.Context, request GetAppDeploymentRequest) (*AppDeployment, error)

	// Retrieves information for the app deployment with the supplied name and
	// deployment id.
	GetDeploymentByAppNameAndDeploymentId(ctx context.Context, appName string, deploymentId string) (*AppDeployment, error)

	// Gets the permission levels that a user can have on an object.
	GetPermissionLevels(ctx context.Context, request GetAppPermissionLevelsRequest) (*GetAppPermissionLevelsResponse, error)

	// Gets the permission levels that a user can have on an object.
	GetPermissionLevelsByAppName(ctx context.Context, appName string) (*GetAppPermissionLevelsResponse, error)

	// Gets the permissions of an app. Apps can inherit permissions from their root
	// object.
	GetPermissions(ctx context.Context, request GetAppPermissionsRequest) (*AppPermissions, error)

	// Gets the permissions of an app. Apps can inherit permissions from their root
	// object.
	GetPermissionsByAppName(ctx context.Context, appName string) (*AppPermissions, error)

	// Lists all apps in the workspace.
	//
	// This method is generated by Databricks SDK Code Generator.
	List(ctx context.Context, request ListAppsRequest) listing.Iterator[App]

	// Lists all apps in the workspace.
	//
	// This method is generated by Databricks SDK Code Generator.
	ListAll(ctx context.Context, request ListAppsRequest) ([]App, error)

	// Lists all app deployments for the app with the supplied name.
	//
	// This method is generated by Databricks SDK Code Generator.
	ListDeployments(ctx context.Context, request ListAppDeploymentsRequest) listing.Iterator[AppDeployment]

	// Lists all app deployments for the app with the supplied name.
	//
	// This method is generated by Databricks SDK Code Generator.
	ListDeploymentsAll(ctx context.Context, request ListAppDeploymentsRequest) ([]AppDeployment, error)

	// Lists all app deployments for the app with the supplied name.
	ListDeploymentsByAppName(ctx context.Context, appName string) (*ListAppDeploymentsResponse, error)

	// Sets permissions on an object, replacing existing permissions if they exist.
	// Deletes all direct permissions if none are specified. Objects can inherit
	// permissions from their root object.
	SetPermissions(ctx context.Context, request AppPermissionsRequest) (*AppPermissions, error)

	// Start the last active deployment of the app in the workspace.
	Start(ctx context.Context, startAppRequest StartAppRequest) (*WaitGetAppActive[App], error)

	// Calls [AppsAPIInterface.Start] and waits to reach ACTIVE state
	//
	// You can override the default timeout of 20 minutes by calling adding
	// retries.Timeout[App](60*time.Minute) functional option.
	//
	// Deprecated: use [AppsAPIInterface.Start].Get() or [AppsAPIInterface.WaitGetAppActive]
	StartAndWait(ctx context.Context, startAppRequest StartAppRequest, options ...retries.Option[App]) (*App, error)

	// Stops the active deployment of the app in the workspace.
	Stop(ctx context.Context, stopAppRequest StopAppRequest) (*WaitGetAppStopped[App], error)

	// Calls [AppsAPIInterface.Stop] and waits to reach STOPPED state
	//
	// You can override the default timeout of 20 minutes by calling adding
	// retries.Timeout[App](60*time.Minute) functional option.
	//
	// Deprecated: use [AppsAPIInterface.Stop].Get() or [AppsAPIInterface.WaitGetAppStopped]
	StopAndWait(ctx context.Context, stopAppRequest StopAppRequest, options ...retries.Option[App]) (*App, error)

	// Updates the app with the supplied name.
	Update(ctx context.Context, request UpdateAppRequest) (*App, error)

	// Updates the permissions on an app. Apps can inherit permissions from their
	// root object.
	UpdatePermissions(ctx context.Context, request AppPermissionsRequest) (*AppPermissions, error)
}

type AppsService deprecated

type AppsService interface {

	// Creates a new app.
	Create(ctx context.Context, request CreateAppRequest) (*App, error)

	// Deletes an app.
	Delete(ctx context.Context, request DeleteAppRequest) (*App, error)

	// Creates an app deployment for the app with the supplied name.
	Deploy(ctx context.Context, request CreateAppDeploymentRequest) (*AppDeployment, error)

	// Retrieves information for the app with the supplied name.
	Get(ctx context.Context, request GetAppRequest) (*App, error)

	// Retrieves information for the app deployment with the supplied name and
	// deployment id.
	GetDeployment(ctx context.Context, request GetAppDeploymentRequest) (*AppDeployment, error)

	// Gets the permission levels that a user can have on an object.
	GetPermissionLevels(ctx context.Context, request GetAppPermissionLevelsRequest) (*GetAppPermissionLevelsResponse, error)

	// Gets the permissions of an app. Apps can inherit permissions from their
	// root object.
	GetPermissions(ctx context.Context, request GetAppPermissionsRequest) (*AppPermissions, error)

	// Lists all apps in the workspace.
	List(ctx context.Context, request ListAppsRequest) (*ListAppsResponse, error)

	// Lists all app deployments for the app with the supplied name.
	ListDeployments(ctx context.Context, request ListAppDeploymentsRequest) (*ListAppDeploymentsResponse, error)

	// Sets permissions on an object, replacing existing permissions if they
	// exist. Deletes all direct permissions if none are specified. Objects can
	// inherit permissions from their root object.
	SetPermissions(ctx context.Context, request AppPermissionsRequest) (*AppPermissions, error)

	// Start the last active deployment of the app in the workspace.
	Start(ctx context.Context, request StartAppRequest) (*App, error)

	// Stops the active deployment of the app in the workspace.
	Stop(ctx context.Context, request StopAppRequest) (*App, error)

	// Updates the app with the supplied name.
	Update(ctx context.Context, request UpdateAppRequest) (*App, error)

	// Updates the permissions on an app. Apps can inherit permissions from
	// their root object.
	UpdatePermissions(ctx context.Context, request AppPermissionsRequest) (*AppPermissions, error)
}

Apps run directly on a customer’s Databricks instance, integrate with their data, use and extend Databricks services, and enable users to interact through single sign-on.

Deprecated: Do not use this interface, it will be removed in a future version of the SDK.

type AppsSettingsAPI added in v0.81.0

type AppsSettingsAPI struct {
	// contains filtered or unexported fields
}

Apps Settings manage the settings for the Apps service on a customer's Databricks instance.

func NewAppsSettings added in v0.81.0

func NewAppsSettings(client *client.DatabricksClient) *AppsSettingsAPI

func (*AppsSettingsAPI) CreateCustomTemplate added in v0.81.0

func (a *AppsSettingsAPI) CreateCustomTemplate(ctx context.Context, request CreateCustomTemplateRequest) (*CustomTemplate, error)

func (*AppsSettingsAPI) DeleteCustomTemplate added in v0.81.0

func (a *AppsSettingsAPI) DeleteCustomTemplate(ctx context.Context, request DeleteCustomTemplateRequest) (*CustomTemplate, error)

func (*AppsSettingsAPI) GetCustomTemplate added in v0.81.0

func (a *AppsSettingsAPI) GetCustomTemplate(ctx context.Context, request GetCustomTemplateRequest) (*CustomTemplate, error)

func (*AppsSettingsAPI) ListCustomTemplates added in v0.81.0

func (a *AppsSettingsAPI) ListCustomTemplates(ctx context.Context, request ListCustomTemplatesRequest) listing.Iterator[CustomTemplate]

Lists all custom templates in the workspace.

func (*AppsSettingsAPI) ListCustomTemplatesAll added in v0.81.0

func (a *AppsSettingsAPI) ListCustomTemplatesAll(ctx context.Context, request ListCustomTemplatesRequest) ([]CustomTemplate, error)

Lists all custom templates in the workspace.

func (*AppsSettingsAPI) UpdateCustomTemplate added in v0.81.0

func (a *AppsSettingsAPI) UpdateCustomTemplate(ctx context.Context, request UpdateCustomTemplateRequest) (*CustomTemplate, error)

type AppsSettingsInterface added in v0.81.0

type AppsSettingsInterface interface {

	// Creates a custom template.
	CreateCustomTemplate(ctx context.Context, request CreateCustomTemplateRequest) (*CustomTemplate, error)

	// Deletes the custom template with the specified name.
	DeleteCustomTemplate(ctx context.Context, request DeleteCustomTemplateRequest) (*CustomTemplate, error)

	// Gets the custom template with the specified name.
	GetCustomTemplate(ctx context.Context, request GetCustomTemplateRequest) (*CustomTemplate, error)

	// Lists all custom templates in the workspace.
	//
	// This method is generated by Databricks SDK Code Generator.
	ListCustomTemplates(ctx context.Context, request ListCustomTemplatesRequest) listing.Iterator[CustomTemplate]

	// Lists all custom templates in the workspace.
	//
	// This method is generated by Databricks SDK Code Generator.
	ListCustomTemplatesAll(ctx context.Context, request ListCustomTemplatesRequest) ([]CustomTemplate, error)

	// Updates the custom template with the specified name. Note that the template
	// name cannot be updated.
	UpdateCustomTemplate(ctx context.Context, request UpdateCustomTemplateRequest) (*CustomTemplate, error)
}

type AppsSettingsService deprecated added in v0.81.0

type AppsSettingsService interface {

	// Creates a custom template.
	CreateCustomTemplate(ctx context.Context, request CreateCustomTemplateRequest) (*CustomTemplate, error)

	// Deletes the custom template with the specified name.
	DeleteCustomTemplate(ctx context.Context, request DeleteCustomTemplateRequest) (*CustomTemplate, error)

	// Gets the custom template with the specified name.
	GetCustomTemplate(ctx context.Context, request GetCustomTemplateRequest) (*CustomTemplate, error)

	// Lists all custom templates in the workspace.
	ListCustomTemplates(ctx context.Context, request ListCustomTemplatesRequest) (*ListCustomTemplatesResponse, error)

	// Updates the custom template with the specified name. Note that the
	// template name cannot be updated.
	UpdateCustomTemplate(ctx context.Context, request UpdateCustomTemplateRequest) (*CustomTemplate, error)
}

Apps Settings manage the settings for the Apps service on a customer's Databricks instance.

Deprecated: Do not use this interface, it will be removed in a future version of the SDK.

type ComputeState added in v0.47.0

type ComputeState string
const ComputeStateActive ComputeState = `ACTIVE`
const ComputeStateDeleting ComputeState = `DELETING`
const ComputeStateError ComputeState = `ERROR`
const ComputeStateStarting ComputeState = `STARTING`
const ComputeStateStopped ComputeState = `STOPPED`
const ComputeStateStopping ComputeState = `STOPPING`
const ComputeStateUpdating ComputeState = `UPDATING`

func (*ComputeState) Set added in v0.47.0

func (f *ComputeState) Set(v string) error

Set raw string value and validate it against allowed values

func (*ComputeState) String added in v0.47.0

func (f *ComputeState) String() string

String representation for fmt.Print

func (*ComputeState) Type added in v0.47.0

func (f *ComputeState) Type() string

Type always returns ComputeState to satisfy [pflag.Value] interface

func (*ComputeState) Values added in v0.72.0

func (f *ComputeState) Values() []ComputeState

Values returns all possible values for ComputeState.

There is no guarantee on the order of the values in the slice.

type ComputeStatus added in v0.47.0

type ComputeStatus struct {
	// Compute status message
	Message string `json:"message,omitempty"`
	// State of the app compute.
	State ComputeState `json:"state,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (ComputeStatus) MarshalJSON added in v0.47.0

func (s ComputeStatus) MarshalJSON() ([]byte, error)

func (*ComputeStatus) UnmarshalJSON added in v0.47.0

func (s *ComputeStatus) UnmarshalJSON(b []byte) error

type CreateAppDeploymentRequest

type CreateAppDeploymentRequest struct {
	// The app deployment configuration.
	AppDeployment AppDeployment `json:"app_deployment"`
	// The name of the app.
	AppName string `json:"-" url:"-"`
}

type CreateAppRequest

type CreateAppRequest struct {
	App App `json:"app"`
	// If true, the app will not be started after creation.
	NoCompute bool `json:"-" url:"no_compute,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (CreateAppRequest) MarshalJSON

func (s CreateAppRequest) MarshalJSON() ([]byte, error)

func (*CreateAppRequest) UnmarshalJSON

func (s *CreateAppRequest) UnmarshalJSON(b []byte) error

type CreateCustomTemplateRequest added in v0.81.0

type CreateCustomTemplateRequest struct {
	Template CustomTemplate `json:"template"`
}

type CustomTemplate added in v0.81.0

type CustomTemplate struct {
	Creator string `json:"creator,omitempty"`
	// The description of the template.
	Description string `json:"description,omitempty"`
	// The Git provider of the template.
	GitProvider string `json:"git_provider"`
	// The Git repository URL that the template resides in.
	GitRepo string `json:"git_repo"`
	// The manifest of the template. It defines fields and default values when
	// installing the template.
	Manifest AppManifest `json:"manifest"`
	// The name of the template. It must contain only alphanumeric characters,
	// hyphens, underscores, and whitespaces. It must be unique within the
	// workspace.
	Name string `json:"name"`
	// The path to the template within the Git repository.
	Path string `json:"path"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (CustomTemplate) MarshalJSON added in v0.81.0

func (s CustomTemplate) MarshalJSON() ([]byte, error)

func (*CustomTemplate) UnmarshalJSON added in v0.81.0

func (s *CustomTemplate) UnmarshalJSON(b []byte) error

type DeleteAppRequest

type DeleteAppRequest struct {
	// The name of the app.
	Name string `json:"-" url:"-"`
}

type DeleteCustomTemplateRequest added in v0.81.0

type DeleteCustomTemplateRequest struct {
	// The name of the custom template.
	Name string `json:"-" url:"-"`
}

type GetAppDeploymentRequest

type GetAppDeploymentRequest struct {
	// The name of the app.
	AppName string `json:"-" url:"-"`
	// The unique id of the deployment.
	DeploymentId string `json:"-" url:"-"`
}

type GetAppPermissionLevelsRequest

type GetAppPermissionLevelsRequest struct {
	// The app for which to get or manage permissions.
	AppName string `json:"-" url:"-"`
}

type GetAppPermissionLevelsResponse

type GetAppPermissionLevelsResponse struct {
	// Specific permission levels
	PermissionLevels []AppPermissionsDescription `json:"permission_levels,omitempty"`
}

type GetAppPermissionsRequest

type GetAppPermissionsRequest struct {
	// The app for which to get or manage permissions.
	AppName string `json:"-" url:"-"`
}

type GetAppRequest

type GetAppRequest struct {
	// The name of the app.
	Name string `json:"-" url:"-"`
}

type GetCustomTemplateRequest added in v0.81.0

type GetCustomTemplateRequest struct {
	// The name of the custom template.
	Name string `json:"-" url:"-"`
}

type ListAppDeploymentsRequest

type ListAppDeploymentsRequest struct {
	// The name of the app.
	AppName string `json:"-" url:"-"`
	// Upper bound for items returned.
	PageSize int `json:"-" url:"page_size,omitempty"`
	// Pagination token to go to the next page of apps. Requests first page if
	// absent.
	PageToken string `json:"-" url:"page_token,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (ListAppDeploymentsRequest) MarshalJSON

func (s ListAppDeploymentsRequest) MarshalJSON() ([]byte, error)

func (*ListAppDeploymentsRequest) UnmarshalJSON

func (s *ListAppDeploymentsRequest) UnmarshalJSON(b []byte) error

type ListAppDeploymentsResponse

type ListAppDeploymentsResponse struct {
	// Deployment history of the app.
	AppDeployments []AppDeployment `json:"app_deployments,omitempty"`
	// Pagination token to request the next page of apps.
	NextPageToken string `json:"next_page_token,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (ListAppDeploymentsResponse) MarshalJSON

func (s ListAppDeploymentsResponse) MarshalJSON() ([]byte, error)

func (*ListAppDeploymentsResponse) UnmarshalJSON

func (s *ListAppDeploymentsResponse) UnmarshalJSON(b []byte) error

type ListAppsRequest

type ListAppsRequest struct {
	// Upper bound for items returned.
	PageSize int `json:"-" url:"page_size,omitempty"`
	// Pagination token to go to the next page of apps. Requests first page if
	// absent.
	PageToken string `json:"-" url:"page_token,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (ListAppsRequest) MarshalJSON

func (s ListAppsRequest) MarshalJSON() ([]byte, error)

func (*ListAppsRequest) UnmarshalJSON

func (s *ListAppsRequest) UnmarshalJSON(b []byte) error

type ListAppsResponse

type ListAppsResponse struct {
	Apps []App `json:"apps,omitempty"`
	// Pagination token to request the next page of apps.
	NextPageToken string `json:"next_page_token,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (ListAppsResponse) MarshalJSON

func (s ListAppsResponse) MarshalJSON() ([]byte, error)

func (*ListAppsResponse) UnmarshalJSON

func (s *ListAppsResponse) UnmarshalJSON(b []byte) error

type ListCustomTemplatesRequest added in v0.81.0

type ListCustomTemplatesRequest struct {
	// Upper bound for items returned.
	PageSize int `json:"-" url:"page_size,omitempty"`
	// Pagination token to go to the next page of custom templates. Requests
	// first page if absent.
	PageToken string `json:"-" url:"page_token,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (ListCustomTemplatesRequest) MarshalJSON added in v0.81.0

func (s ListCustomTemplatesRequest) MarshalJSON() ([]byte, error)

func (*ListCustomTemplatesRequest) UnmarshalJSON added in v0.81.0

func (s *ListCustomTemplatesRequest) UnmarshalJSON(b []byte) error

type ListCustomTemplatesResponse added in v0.81.0

type ListCustomTemplatesResponse struct {
	// Pagination token to request the next page of custom templates.
	NextPageToken string `json:"next_page_token,omitempty"`

	Templates []CustomTemplate `json:"templates,omitempty"`

	ForceSendFields []string `json:"-" url:"-"`
}

func (ListCustomTemplatesResponse) MarshalJSON added in v0.81.0

func (s ListCustomTemplatesResponse) MarshalJSON() ([]byte, error)

func (*ListCustomTemplatesResponse) UnmarshalJSON added in v0.81.0

func (s *ListCustomTemplatesResponse) UnmarshalJSON(b []byte) error

type StartAppRequest

type StartAppRequest struct {
	// The name of the app.
	Name string `json:"-" url:"-"`
}

type StopAppRequest

type StopAppRequest struct {
	// The name of the app.
	Name string `json:"-" url:"-"`
}

type UpdateAppRequest

type UpdateAppRequest struct {
	App App `json:"app"`
	// The name of the app. The name must contain only lowercase alphanumeric
	// characters and hyphens. It must be unique within the workspace.
	Name string `json:"-" url:"-"`
}

type UpdateCustomTemplateRequest added in v0.81.0

type UpdateCustomTemplateRequest struct {
	// The name of the template. It must contain only alphanumeric characters,
	// hyphens, underscores, and whitespaces. It must be unique within the
	// workspace.
	Name string `json:"-" url:"-"`

	Template CustomTemplate `json:"template"`
}

type WaitGetAppActive added in v0.47.0

type WaitGetAppActive[R any] struct {
	Response *R
	Name     string `json:"name"`
	Poll     func(time.Duration, func(*App)) (*App, error)
	// contains filtered or unexported fields
}

WaitGetAppActive is a wrapper that calls AppsAPI.WaitGetAppActive and waits to reach ACTIVE state.

func (*WaitGetAppActive[R]) Get added in v0.47.0

func (w *WaitGetAppActive[R]) Get() (*App, error)

Get the App with the default timeout of 20 minutes.

func (*WaitGetAppActive[R]) GetWithTimeout added in v0.47.0

func (w *WaitGetAppActive[R]) GetWithTimeout(timeout time.Duration) (*App, error)

Get the App with custom timeout.

func (*WaitGetAppActive[R]) OnProgress added in v0.47.0

func (w *WaitGetAppActive[R]) OnProgress(callback func(*App)) *WaitGetAppActive[R]

OnProgress invokes a callback every time it polls for the status update.

type WaitGetAppStopped added in v0.47.0

type WaitGetAppStopped[R any] struct {
	Response *R
	Name     string `json:"name"`
	Poll     func(time.Duration, func(*App)) (*App, error)
	// contains filtered or unexported fields
}

WaitGetAppStopped is a wrapper that calls AppsAPI.WaitGetAppStopped and waits to reach STOPPED state.

func (*WaitGetAppStopped[R]) Get added in v0.47.0

func (w *WaitGetAppStopped[R]) Get() (*App, error)

Get the App with the default timeout of 20 minutes.

func (*WaitGetAppStopped[R]) GetWithTimeout added in v0.47.0

func (w *WaitGetAppStopped[R]) GetWithTimeout(timeout time.Duration) (*App, error)

Get the App with custom timeout.

func (*WaitGetAppStopped[R]) OnProgress added in v0.47.0

func (w *WaitGetAppStopped[R]) OnProgress(callback func(*App)) *WaitGetAppStopped[R]

OnProgress invokes a callback every time it polls for the status update.

type WaitGetDeploymentAppSucceeded

type WaitGetDeploymentAppSucceeded[R any] struct {
	Response     *R
	AppName      string `json:"app_name"`
	DeploymentId string `json:"deployment_id"`
	Poll         func(time.Duration, func(*AppDeployment)) (*AppDeployment, error)
	// contains filtered or unexported fields
}

WaitGetDeploymentAppSucceeded is a wrapper that calls AppsAPI.WaitGetDeploymentAppSucceeded and waits to reach SUCCEEDED state.

func (*WaitGetDeploymentAppSucceeded[R]) Get

Get the AppDeployment with the default timeout of 20 minutes.

func (*WaitGetDeploymentAppSucceeded[R]) GetWithTimeout

func (w *WaitGetDeploymentAppSucceeded[R]) GetWithTimeout(timeout time.Duration) (*AppDeployment, error)

Get the AppDeployment with custom timeout.

func (*WaitGetDeploymentAppSucceeded[R]) OnProgress

func (w *WaitGetDeploymentAppSucceeded[R]) OnProgress(callback func(*AppDeployment)) *WaitGetDeploymentAppSucceeded[R]

OnProgress invokes a callback every time it polls for the status update.

Jump to

Keyboard shortcuts

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