A month ago there was another interface to the google API where we could 'build' the fields parameter from a very handy popup. Where can we find it now?
Related
dear all I am trying to develop a Telerik report and its data source is web service data source.
I complete all process according to Telerik reporting instruction and it can access my service initially. and pass parameter value as well as but when I click finish but to complete adding by data model it again hit my backend and pass parameters name not value.
please help me out from this trouble. it already kill my day.
for more reference please see the attached image.
Initiation step 1:
parameter assign:
Backend receive parameter when i press download button correctly.
according to parameter retrieve data:
But finally when click finish button it hit again in backend and backend receive the parameter value like this. and this is the main problem.
I hope I can explain. please help me from this trouble.
I am following the Row level filtering with Embedded dashboards tutorial to build a secure, multi-tenant dashboard using Data Studio as the reporting UI/backend (and Anvil as the front-end in Python), with the aim of filtering data from a BigQuery table based on specific user permisisons.
I have completed the initial connector tutorial successfully as recommended. So far I have also completed the following steps (1-4) successfully :
Build user authentication in Anvil and set permissions in user table (JSON containing specific field values each user is permitted to view)
Build mechanism to create access_token in Anvil, based on hex md5 hash of a combination of user and unix timestamp, with one hour expiry
Set and store app_secret securely in Anvil to authenticate inbound requests
Create API endpoint in Anvil which validates the app_secret and validates access_token and returns JSON containing user_email and permitted_accounts
Now I've got to the point of building the custom connector, with the aim of building the next part of the flow:
Pass access_token to Data Studio by encoding and including it in the embed URL (the report will be embedded via an iFrame) as per this section
Extract access_token from embed URL in App Script as per the statement "This will be used to capture a token from embed URL's parameters." from this section
Hit the API endpoint with the app_secret and access_token from App Script to validate and receive the user permissions associated with the access_token IF validation checks pass in Anvil, otherwise return appropriate error message
Construct query based on user permissions and get data from BigQuery using this approach
... then set schema etc...
However, upon reaching step 6 in this flow where I need to parse the access_token from the URL, the code included in the Write the Connector Code section takes the token as a user-inputted text field and does not take it from the embed URL's parameters (which to me makes no sense as making a user continually manually transpose a short-lived token seems to negate the point of this exercise).
I am also unable to find documentation in the API reference on how to achieve this.
PLEASE, does anybody know how to capture parameters from Report Embed URLs in an App Script Community Connector? I assumed it was possible from the documentation:
getConfig() should return at least one config item. This will be used to capture a token from embed URL's parameters.
Thank you for taking the time!
a. I'm assuming access_token is an overridable config parameter in your getConfig.
b. When you create the initial report, during the data source creation, you can put in any value in access_token config field. However, check the box to 'Allow "access_token" to be modified in reports'. That means, report viewers will be able to override this value even though they do not have edit access to the report or the data source.
c. Confirm that your setp #5 is following the instructions here to pass the override value for access_token.
d. That's it. Now it is irrelevant what value you put in for access_token during initial report creation. For user X, your portal was pass the value hash(user, timestamp) as the value for access_token. In your connector's getData function, request.configParams.access_token will return that specific value. You can then call your endpoint with that value to get back the user identity.
I have the Google Picker API implemented in an application, with the Google Drive view included. Currently, entering a search query in the search bar of the Google Drive view starts showing a drop-down with some file results included, like this:
search bar drop down
However, clicking the "magnifying glass" search button, or pressing enter, or clicking "search for all items containing...", all results in an empty picker, like this:
empty picker with no search results
I believe this is occurring because a call to https://docs.google.com/picker/pvr is returning this error as a response every time: &&&START&&&{"error":true,"errorMessage":"Internal error"}.
The parameters being sent to that /pvr endpoint are here:
start: 0
numResults: 50
sort: 3
desc: true
q: testing
cursor:
mine: 2
service: docs
type: NOT_COLLECTION
options: {"ff":true,"filterTeamDriveResults":true}
token: J********
version: 4
app: 2
clientUser: 1************
developerKey: A*************
subapp: 5
What I found is that manually removing the "filterTeamDriveResults":true key from the "options" hash and doing an ajax post directly resulted in a successful request, but for whatever reason that option is included with every request from the picker, and any time a request is made with that option included, it seems to fail with the same "Internal error" response. I'm wondering what the source of that option is, and if there's any way to remove it from our picker. As far as I can tell it doesn't seem to be controlled by any of the options in the JavaScript API that we're loading from https://apis.google.com/js/api.js?onload=onApiLoad.
This started happening to us last week as well after having been using the Google Picker API for years without any issues. Your clue about the filterTeamDriveResults key reminded me of something I had just read, about upcoming changes to the Google Drive API and Google Picker API:
Next, we’re introducing a new Drive API resource collection, called “Drives,” to replace the “Team Drives” resource collection. This new resource collection can help you create, delete, get, list and update your shared drives, and features all the same fields, resources and available methods as the “Team Drives” resource collection. If you have been using the “Team Drives” resource collection in your applications, consider migrating as soon as possible as all related fields for Drive API , Drive Activity API and Google Picker API, will no longer be supported starting June 1, 2020.
It doesn't seem related, at least not directly, but made me think that perhaps, the SUPPORT_DRIVES feature that I had seen here in the docs, could "disable" that other teamDrive feature (even though it's not really that, but still...). And indeed, that fixed it. Basically just:
new google.picker.PickerBuilder().
setAppId(appId).
addView(new google.picker.DocsView().setIncludeFolders(true)).
enableFeature(google.picker.Feature.SUPPORT_DRIVES)
...
One thing to notice is this warning when enabling this feature:
Before enabling this make sure to refer to Google Drive API documentation for enabling shared drives and make any necessary Drive Rest API changes.
Might be relevant in your case.
On a user's page on the G Suite admin console, an admin can see the last login of a user. For example, one user I can see has a "last login" date of two years ago.
I'm trying to pull this date programatically. However, the Reports API that provides information on login events only goes back 180 days. How is Google getting this login date, and can it be fetched via API?
Google has this information because they are logging the event when it happens and storing that to present in the admin console. If you start to build an application now and start storing those events as time passes you too will have a date that goes back years. G Suite Enterprise customers can seamlessly do this if they Set up BigQuery logs in the Admin console.
You should be able to get this information now though. Look at the following APIs used in GAMADV-XTD you can get this info with this command for example.
gam report users parameters accounts:last_login_time filters "accounts:last_login_time<#filtertime#" filtertime -5y
https://developers.google.com/admin-sdk/reports/v1/reference/activities
https://developers.google.com/admin-sdk/reports/v1/reference/customerUsageReports
https://developers.google.com/admin-sdk/reports/v1/reference/userUsageReport
I somehow missed this before, but you can get the last login date/time with the User Usage Report (rather than the Login Activity report).
API docs are here and the App Script example I'm using is here. I realized that if GAM was pulling the information there had to be an API for it.
I'm running a Wordpress site with Event Calendar plugin by Modern Tribe.
I wonder how I can have a feed or json of all my events to be processed by another application (i.e. a mobile app). In the docs, I found out I can add /feed at my calendar's url to get the feed xml, but it's not retrieving important information such as palce and time of the event.
Has anyone any suggestion? My second choice is to build an extra php file for processing raw queries in the db.
Thanks