Package: databricks-jobs
databricks-jobsThe Jobs API allows you to create, edit, and delete jobs.
You should never hard code secrets or store them in plain text. Use theSecrets APIto manage secrets in theDatabricks CLI. Use theSecrets utilityto reference secrets in notebooks and jobs.This Python package is automatically generated by theOpenAPI Generatorproject:API version: 2.1Package version: 1.0.0Build package: org.openapitools.codegen.languages.PythonNextgenClientCodegenRequirements.Python 3.7+Installation & Usagepip installIf the python package is hosted on a repository, you can install directly using:pipinstallgit+https://github.com/GIT_USER_ID/GIT_REPO_ID.git(you may need to runpipwith root permission:sudo pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git)Then import the package:importdatabricks_jobsSetuptoolsInstall viaSetuptools.pythonsetup.pyinstall--user(orsudo python setup.py installto install the package for all users)Then import the package:importdatabricks_jobsGetting StartedPlease follow theinstallation procedureand then run the following:from__future__importprint_functionimporttimeimportdatabricks_jobsfromdatabricks_jobs.restimportApiExceptionfrompprintimportpprint# Defining the host is optional and defaults to https://<databricks-instance>/api# See configuration.py for a list of all supported configuration parameters.configuration=databricks_jobs.Configuration(host="https://<databricks-instance>/api")# The client must configure the authentication and authorization parameters# in accordance with the API server security policy.# Examples for each auth method are provided below, use the example that# satisfies your auth use case.# Configure Bearer authorization (api_token): bearerAuthconfiguration=databricks_jobs.Configuration(access_token=os.environ["BEARER_TOKEN"])# Enter a context with an instance of the API clientwithdatabricks_jobs.ApiClient(configuration)asapi_client:# Create an instance of the API classapi_instance=databricks_jobs.DefaultApi(api_client)jobs_create_request=databricks_jobs.JobsCreateRequest()# JobsCreateRequest |try:# Create a new jobapi_response=api_instance.jobs_create(jobs_create_request)print("The response of DefaultApi->jobs_create:\n")pprint(api_response)exceptApiExceptionase:print("Exception when calling DefaultApi->jobs_create:%s\n"%e)Documentation for API EndpointsAll URIs are relative tohttps:///apiClassMethodHTTP requestDescriptionDefaultApijobs_createPOST/2.1/jobs/createCreate a new jobDefaultApijobs_deletePOST/2.1/jobs/deleteDelete a jobDefaultApijobs_getGET/2.1/jobs/getGet a single jobDefaultApijobs_listGET/2.1/jobs/listList all jobsDefaultApijobs_resetPOST/2.1/jobs/resetOverwrites all settings for a jobDefaultApijobs_run_nowPOST/2.1/jobs/run-nowTrigger a new job runDefaultApijobs_runs_cancelPOST/2.1/jobs/runs/cancelCancel a job runDefaultApijobs_runs_cancel_allPOST/2.1/jobs/runs/cancel-allCancel all runs of a jobDefaultApijobs_runs_deletePOST/2.1/jobs/runs/deleteDelete a job runDefaultApijobs_runs_exportGET/2.0/jobs/runs/exportExport and retrieve a job runDefaultApijobs_runs_getGET/2.1/jobs/runs/getGet a single job runDefaultApijobs_runs_get_outputGET/2.1/jobs/runs/get-outputGet the output for a single runDefaultApijobs_runs_listGET/2.1/jobs/runs/listList runs for a jobDefaultApijobs_runs_repairPOST/2.1/jobs/runs/repairRepair a job runDefaultApijobs_runs_submitPOST/2.1/jobs/runs/submitCreate and trigger a one-time runDefaultApijobs_updatePOST/2.1/jobs/updatePartially updates a jobDocumentation For ModelsAccessControlListAccessControlRequestAccessControlRequestForGroupAccessControlRequestForServicePrincipalAccessControlRequestForUserAdlsgen2InfoAutoScaleAwsAttributesAzureAttributesCanManageCanManageRunCanViewClusterAttributesClusterCloudProviderNodeInfoClusterCloudProviderNodeStatusClusterEventClusterEventTypeClusterInfoClusterInstanceClusterLibraryStatusesClusterLogConfClusterSizeClusterSourceClusterSpecClusterStateCronScheduleDbfsStorageInfoDbtOutputDbtTaskDockerBasicAuthDockerImageErrorEventDetailsFileStorageInfoGcpAttributesGitBranchSourceGitCommitSourceGitProviderGitSnapshotGitSourceGitTagSourceInitScriptInfoIsOwnerJobJobClusterJobEmailNotificationsJobSettingsJobTaskJobTaskSettingsJobsCreate200ResponseJobsCreateRequestJobsDeleteRequestJobsGet200ResponseJobsList200ResponseJobsResetRequestJobsRunNow200ResponseJobsRunNowRequestJobsRunsCancelAllRequestJobsRunsCancelRequestJobsRunsDeleteRequestJobsRunsExport200ResponseJobsRunsGet200ResponseJobsRunsGetOutput200ResponseJobsRunsList200ResponseJobsRunsRepair200ResponseJobsRunsRepairRequestJobsRunsSubmit200ResponseJobsRunsSubmitRequestJobsUpdateRequestLibraryLibraryFullStatusLibraryInstallStatusListOrderLogSyncStatusMavenLibraryNewClusterNewTaskClusterNodeTypeNotebookOutputNotebookTaskPermissionLevelPermissionLevelForGroupPipelineTaskPoolClusterTerminationCodePythonPyPiLibraryPythonWheelTaskRCranLibraryRepairHistoryRepairHistoryItemRepairRunInputResizeCauseRunRunLifeCycleStateRunNowInputRunParametersRunParametersPipelineParamsRunResultStateRunStateRunSubmitSettingsRunSubmitTaskSettingsRunTaskRunTypeS3StorageInfoSparkJarTaskSparkNodeSparkNodeAwsAttributesSparkPythonTaskSparkSubmitTaskSparkVersionSqlAlertOutputSqlDashboardOutputSqlDashboardWidgetOutputSqlOutputSqlOutputErrorSqlQueryOutputSqlStatementOutputSqlTaskSqlTaskAlertSqlTaskDashboardSqlTaskQueryTaskDependenciesInnerTaskSparkSubmitTaskTerminationCodeTerminationParameterTerminationReasonTerminationTypeTriggerTypeViewItemViewTypeViewsToExportWebhookNotificationsWebhookNotificationsOnStartInnerDocumentation For AuthorizationbearerAuthType: Bearer authentication (api_token)Author