Reset default filters for tableau view via rest api - tableau-api

I am using tableau rest api for view data to fetch data for views. There are some default filter values applied to the view filters and I am getting data filtered according to that. I want the complete data. How can I clear the filters via tableau rest api. I cannot use their javascript api.

There is no endpoint in the rest api that enables this functionality out-of-the-box. You may be able to download the workbook and script something that interrogates the raw xml (a twb/twbx file is simply xml) and updates the default filter(s). You can then re-package the workbook and push back to server, then fetch the data.
If you are restricted due to row-level security rules on the data source...the above will not work.

Related

Custom GA data costs = Analytics API column missing?

I am trying to use custom cost data (from PLA, price comparison sites), I already upload data on daily basis, it shows up in GA. However, It does not work as expected on API side - as I need to use this cost data for custom reporting, using ga:adCost return cost data only for Google Ads, nothing else. As I have checked, there is no other cost column in dimensions or metrics....
Concrete:
I import cost data using APIs
Success
However, on the API side, when I want to use that data as a source for data export, the only ,,cost,, related colum is adCost - but only Google Ads costs as a traffic source are returned
https://ga-dev-tools.appspot.com/dimensions-metrics-explorer/
I would expect all traffic sources to have ga:adCost (or ga:cost?) in API as well, however, only Google Ads have that. I suppose that ga:ad* is related to GAds connection data only and custom data imported are to passed to Analytics API and/or there is no metric for that data...
Am i doing wrong API calls to get traffic source / medium & cost data, or custom imported data are not able to get back via API?
Is there a solution? Thanks!

General question about SmartSheet API and creating a user interface

My company keeps individual employee schedules. Each employee manages their own schedule. Admin,supervisors and project manager have to go to each sheet and look for the information.
I need to create a system that allows someone to select a date range and skill set then produce a sheet with the information that matches the criteria. I have installed the Python API and worked through a few tutorials.
Now I need to know how to make command buttons, date pickers . . .
A quick read of my search results indicates that this is not part of the Smartsheet API!
Is there a way to do this through the SmartSheet API? Or how would you approach this?
The Smartsheet API enables you to programmatically access data in Smartsheet (i.e., create, read, update, delete data in Smartsheet). This is true for all APIs -- they simply provide a means for you to programmatically access data. You'll need to build the web app's user interface (UI) yourself by using HTML, CSS, JavaScript, etc.
Alternatively -- instead of building a custom web application like you've described -- I'd suggest that you look into the possibility of creating Smartsheet Reports that can provide the data you've described. You can create Smartsheet Reports via the Smartsheet UI -- so you wouldn't need to do any programming at all.

How to create a dynamic API endpoint connection using HTTP or REST connectors in Azure Data Factory V2

I have an external REST based API that I need to create a connection to in order to retrieve data on a regularly scheduled basis (for BI purposes). This API is fairly robust, and supports around 60 distinct endpoints. Also, this same API is used to access information across multiple client sub-domains (e.g. client1.apisource.com, client2.apisource.com, client3.apisource.com, etc.). In other words, the API endpoints are the same for each client subdomain.
So what I'm trying to figure out is whether it's possible to create a single ADF that contains a complete set of pipeline actions for each endpoint THAT uses a "dynamic" URL based on the client subdomains? In other words...what I'm trying to see if its possible to create a single ADF that can manage a dynamic list of base URLs.
I tried to parameterize the HTTP and REST connections, but this doesn't appear to Is this possible yet. Any thoughts? Thanks!
Here is an example of a Web Activity to call a REST API using parameters and expressions. The URL can be an expression like:
#concat('https://management.azure.com/subscriptions/',pipeline().parameters.SubscriptionID,'/resourceGroups/',pipeline().parameters.ResourceGroup,'/providers/Microsoft.Sql/servers/',pipeline().parameters.Server,'/databases/',pipeline().parameters.DW,'?api-version=2014-04-01')

Record level access control for REST API GET Collection call

So, I am working on the next project that requires more detailed access control functionality (i.e. Sally can only view products in her department).
I get how either a role based access control model or an attribute access control model can 'wrap' an API call to determine if a given user can perform said action on a given object.
Where I keep getting stuck is when you are dealing with a GET call that returns a collection of records. If I ask the API for a page of 20 records from this endpoint, I can't get 20 records, then run a code based authorization check on those records before returning them as I most likely won't be returning 20 records.
It seems like the authorization check either has to be down in the database and/or happen prior to the database query by adding additional filters to the query call (i.e. also filter where product department = clothing).
Anybody have any more concrete implementation examples or ideas how how this could be implemented in a performant manner?
As David mentioned, XACML can be used at the database level for filtering.
Implementing XACML For The Database
The diagram below is for SQL, but can be used as a general example for any database technology.
Let's see how this works:
SQL statement is intercepted.
A query is sent to the external authorization service that implements XACML
The authorization engine (PDP) evaluates the relevant policies, written in XACML or ALFA (an implementation of XACML).
It may query external attribute sources (PIPs) for more info.
The result: SQL statement is dynamically modified to retrieve only authorized data for the user.
How This Would Be Used In An Application
The implementation of XACML you choose to go with would ideally have an SDK in your language of choice or support the XACML REST profile. Either would work for integration into your application.
Given that you are using REST calls, I don't think you would have to add much code to integrate your application with an implementation of XACML.
Implementing XACML for an API Gateway
The principle used in this integration is the ability of an API gateway to make a callout to a third party service.
In this case the third party service is your XACML implementation's Policy Decision Point (PDP). The implementation must support REST/JSON.
The API Gateway is configured to send fine-grained authorization requests to the PDP.
Requests are made using the REST/JSON interface exposed by the PDP. The PDP then returns a response.
The JSON profile of XACML extends the Request/Response schema allowing both the Request and the Response to be encoded in JSON instead of the traditional XML encoding. This makes the Request and the Response much easier to read and also much smaller in size thus transferring less data.
Implementations of XACML
For an entire list of XACML implementations, you can check this list on Wikipedia.
Full disclosure - I work for Axiomatics with David Brossard, who designed the JSON profile for XACML to be used in conjunction with the REST profile.
Axiomatics provides Axiomatics Data Access Filter for relational databases and SmartGuard for HADOOP. Axiomatics Policy Server natively supports both JSON and REST profiles.

Tableau - API Call to Show Everything a User Has Access To

is there an API call, or a link of API calls in which I can show the following structure
Sites User Has Access To
- Projects User Has Access To
-- Workbooks User Has Access to
--- Views User Has Access To (Including Thumbnails)
I'm currently using a mix of the API and directly accessing (not strictly true but that's another story) the PostgreSQL DB. It works and it s pretty neat hack, but I'd rather avoid hacks
I was using 8.3 but now on the latest v9 release
Thanks
I'm using Tableau API to do this, it seems pretty straightforward, but maybe I'm missing something.
Following API reference:
Tableau REST API reference
Sign in and impersonate, use retrieved token in following API calls
Query sites
For each site query workbooks
For each workbook query views
For each view download preview image
Sign out