Module Contents



Execute a Tableau API Resource



class airflow.providers.tableau.operators.tableau.TableauOperator(*, resource: str, method: str, find: str, match_with: str = 'id', site_id: Optional[str] = None, blocking_refresh: bool = True, check_interval: float = 20, tableau_conn_id: str = 'tableau_default', **kwargs)[source]

Bases: airflow.models.BaseOperator

Execute a Tableau API Resource

See also

For more information on how to use this operator, take a look at the guide: TableauOperator

  • resource (str) -- The name of the resource to use.

  • method (str) -- The name of the resource's method to execute.

  • find (str) -- The reference of resource that will receive the action.

  • match_with (Optional[str]) -- The resource field name to be matched with find parameter.

  • site_id (Optional[str]) -- The id of the site where the workbook belongs to.

  • blocking_refresh (bool) -- By default will be blocking means it will wait until it has finished.

  • check_interval (float) -- time in seconds that the job should wait in between each instance state checks until operation is completed

  • tableau_conn_id (str) -- The Tableau Connection id containing the credentials to authenticate to the Tableau Server.

execute(self, context: airflow.utils.context.Context) str[source]

Executes the Tableau API resource and pushes the job id or downloaded file URI to xcom. :param context: The task context during execution. :type context: dict :return: the id of the job that executes the extract refresh or downloaded file URI. :rtype: str

Was this entry helpful?