Using API

After successfully deploying Cloudera Workflow Orchestrator, access it through API.

  1. Obtain your access token by performing steps 1 through 3 in the Creating tokens for using the API section.
  2. Obtain the Cloudera Workflow Orchestrator URL (CWO_URL).
    1. Access Anywhere Cloud Console.
    2. Sign in using your enterprise identity provider.
    3. Click Apps in the left navigation pane on the Anywhere Cloud Console. The list of deployed engines and the associated blueprints is displayed.
    4. In the Deployed Engines tab, search for the required Cloudera Workflow Orchestrator instance.
    5. Click on that instance. A details pane is displayed.
    6. Copy the URL available in the URL column.
  3. Set the ACCESS_TOKEN and CWO_URL to run the Airflow API requests.

    Example

    curl -H "Authorization: Bearer ${ACCESS_TOKEN}" ${CWO_URL}api/v2/dags/example_bash_operator
    
    {"dag_id":"example_bash_operator","dag_display_name":"example_bash_operator","is_paused":false,"is_stale":false....}

    For more information about using Airflow API, see Airflow API.