jobs_list: List all jobs in a Databricks workspace.

View source: R/jobs_list.R

jobs_listR Documentation

List all jobs in a Databricks workspace.

Description

Fetches all of the details for jobs in the authenticated workspace. See also runs_list to learn more about a particular job run.

Usage

jobs_list(workspace, token = NULL, verbose = T)

Arguments

workspace

A string representing the web workspace of your Databricks instance. E.g., "https://eastus2.azuredatabricks.net" or "https://demo.cloud.databricks.com".

token

A valid authentication token generated via User Settings in Databricks or via the Databricks REST API 2.0. If none is provided, netrc will be used.

verbose

If true, will pretty print the success or failure of the request. Defaults to TRUE.

Details

The API endpoint for running a job is '2.0/jobs/list'. For all details on API calls please see the official documentation at https://docs.databricks.com/dev-tools/api/latest/.

Value

A list with four elements:

  • response - The full API response, including status code.

  • response_list - The JSON result transformed into a list.

  • response_df - The JSON result transformed into a dataframe.

  • response_tidy - A simple dataframe with the job ID, name, time of creation, and who created it.

If the details of jobs are not needed, use the response_tidy dataframe.

Examples

jobs <- jobs_list(workspace = "https://eastus2.azuredatabricks.net",
                  token = "dapiafoi32984320890d9asaf1")

## Get data in different formats
jobs_json <- jobs$response_json
jobs_list <- jobs$response_list
jobs_df <- jobs$response_df


RafiKurlansik/bricksteR documentation built on Oct. 13, 2022, 6:58 a.m.