đ 2 min read
To query a data source with VizQL Data Service (VDS), you must first assign the API Access capability in the Permission dialog. For information about setting up this data source capability in the Tableau user interface, see the Permission Capabilities and Templates topic in either Tableau Cloud Help or Tableau Server Help.
For information about setting up this data source capability using the REST API, see Permissions.
VDS requires that you send an authentication token with each request. The token lets Tableau Cloud or Tableau Server verify your identity and makes sure that youâre signed in. To get a token, you can call the Tableau REST API Sign In method, in one of three ways.
To sign in using a PAT, see Make a Sign In Request with a Personal Access Token in the Tableau REST API Help for more information.
If you use a JWT, set the scope (scp) in the JWT to tableau:viz_data_service:read
. The permissions of the user in the JWT determine query results.
See Make a Sign In Request with a JWT in the Tableau REST API Help for more information on using a JWT to create a credentials token that you can use with VDS.
See Make a Sign In Request with Username and Password in the Tableau REST API Help for more information.
For information about token expiration, changing the token timeout value, and more, see Using the Authentication Token In Subsequent Calls in the Tableau REST API Help.