Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-07-2022 07:21 PM
@Srinivas Gannavaram : Sample python pseudocode for jobs API. Hope this helps you to build your Logic
import requests
import json
databricks_instance ="<databricks-instances>"
url_list = f"{databricks_instance}/api/2.1/jobs/runs/get?run_id=<Your Job RunID>"
headers = {
'Authorization': 'Bearer <databricks-access-token>',
'Content-Type': 'application/json'
}
response = requests.request("GET", url_list, headers=headers).json()
print(response)
print(response['job_id'])
print(response['start_time'])
print(response['end_time'])