w.apps: Apps¶
- class databricks.sdk.service.serving.AppsAPI¶
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.
- create(name: str [, description: Optional[str]]) Wait[App]¶
Create an app.
Creates a new app.
- Parameters:
name – str The name of the app. The name must contain only lowercase alphanumeric characters and hyphens. It must be unique within the workspace.
description – str (optional) The description of the app.
- Returns:
Long-running operation waiter for
App. See :method:wait_get_app_idle for more details.
- create_and_wait(name: str [, description: Optional[str], timeout: datetime.timedelta = 0:20:00]) App¶
- delete(name: str)¶
Delete an app.
Deletes an app.
- Parameters:
name – str The name of the app.
- deploy(app_name: str, source_code_path: str, mode: AppDeploymentMode) Wait[AppDeployment]¶
Create an app deployment.
Creates an app deployment for the app with the supplied name.
- Parameters:
app_name – str The name of the app.
source_code_path – str 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.
mode –
AppDeploymentModeThe mode of which the deployment will manage the source code.
- Returns:
Long-running operation waiter for
AppDeployment. See :method:wait_get_deployment_app_succeeded for more details.
- deploy_and_wait(app_name: str, source_code_path: str, mode: AppDeploymentMode, timeout: datetime.timedelta = 0:20:00) AppDeployment¶
- get(name: str) App¶
Get an app.
Retrieves information for the app with the supplied name.
- Parameters:
name – str The name of the app.
- Returns:
App
- get_deployment(app_name: str, deployment_id: str) AppDeployment¶
Get an app deployment.
Retrieves information for the app deployment with the supplied name and deployment id.
- Parameters:
app_name – str The name of the app.
deployment_id – str The unique id of the deployment.
- Returns:
AppDeployment
- get_environment(name: str) AppEnvironment¶
Get app environment.
Retrieves app environment.
- Parameters:
name – str The name of the app.
- Returns:
AppEnvironment
- list([, page_size: Optional[int], page_token: Optional[str]]) Iterator[App]¶
List apps.
Lists all apps in the workspace.
- Parameters:
page_size – int (optional) Upper bound for items returned.
page_token – str (optional) Pagination token to go to the next page of apps. Requests first page if absent.
- Returns:
Iterator over
App
- list_deployments(app_name: str [, page_size: Optional[int], page_token: Optional[str]]) Iterator[AppDeployment]¶
List app deployments.
Lists all app deployments for the app with the supplied name.
- Parameters:
app_name – str The name of the app.
page_size – int (optional) Upper bound for items returned.
page_token – str (optional) Pagination token to go to the next page of apps. Requests first page if absent.
- Returns:
Iterator over
AppDeployment
- start(name: str) AppDeployment¶
Start an app.
Start the last active deployment of the app in the workspace.
- Parameters:
name – str The name of the app.
- Returns:
AppDeployment
- stop(name: str)¶
Stop an app.
Stops the active deployment of the app in the workspace.
- Parameters:
name – str The name of the app.
- update(name: str [, description: Optional[str]]) App¶
Update an app.
Updates the app with the supplied name.
- Parameters:
name – str The name of the app. The name must contain only lowercase alphanumeric characters and hyphens. It must be unique within the workspace.
description – str (optional) The description of the app.
- Returns:
App
- wait_get_app_idle(name: str, timeout: datetime.timedelta = 0:20:00, callback: Optional[Callable[[App], None]]) App¶
- wait_get_deployment_app_succeeded(app_name: str, deployment_id: str, timeout: datetime.timedelta = 0:20:00, callback: Optional[Callable[[AppDeployment], None]]) AppDeployment¶