google-mirror-api

Using a service account to push cards

独自空忆成欢 提交于 2019-12-13 03:35:33
问题 I'm trying to create a php page which will authenticate using a service account and will create a new timeline card for the application users. (It's working using a client ID for web sites) So I have created a service account, uploaded the key.p12 file to the server and I keep getting this error message: Uncaught exception 'Google_Auth_Exception' with message 'Error refreshing the OAuth2 token, message: '{ "error" : "invalid_grant" }'' As I understood I also need to give access to the service

Mirror API Playground not posting to timeline

强颜欢笑 提交于 2019-12-13 02:49:51
问题 I believe I've gone through all the steps of creating a (web) client-id for authorizing requests from the Mirror API Playground, yet when I hit the Authorize button, and then Insert a card from a template, nothing is sent to glass. I also note that the Timeline tab below is empty. Web I bring up developer tools, I note that the POST to https://www.googleapis.com/rpc is returning results: [ { "error": { "code": 403, "message": "Access Not Configured", "data": [ { "domain": "usageLimits",

Is it possible to override “Roboto” Font by any other webfont?

别等时光非礼了梦想. 提交于 2019-12-12 11:12:19
问题 According to base style https://mirror-api-playground.appspot.com/assets/css/base_style.css the " Roboto " is the default Glass font. Is it possible to use some other webfont (override the Roboto)? I am sure that ingress player would like to change " Roboto " for " coda_regular " 回答1: Importing font is not supported by the Mirror API and the only font available in the client is indeed Roboto. 来源: https://stackoverflow.com/questions/16045900/is-it-possible-to-override-roboto-font-by-any-other

How to insert and retrieve postBody in Mirror API account insert method using PHP

假装没事ソ 提交于 2019-12-12 07:23:51
问题 I need to insert user's email in postBody of mirror API insert method. I am using this code: $authtoken=null; $postBody = new Google_Service_Mirror_Account(); $postBody->setAuthTokens($authtoken); $userdata=array("email"=>$email); $postBody->setUserData($userdata); $account = $service->accounts->insert($userToken, package-name-here, $accountName, $postBody); The above method returns null in response! I am not sure what to add as authtoken. After this, I need to retrieve user's email account

Retrieve the Auth Token in GDK

无人久伴 提交于 2019-12-12 02:49:55
问题 Retrieve the Auth Token in GDK After Inserting the Mirror Account Successfully Now getting the Auth Token in APK side (GDK side). Mainfest.xml <uses-permission android:name="android.permission.GET_ACCOUNTS" /> <uses-permission android:name="android.permission.USE_CREDENTIALS" /> Activity Code : AccountManager accountManager = AccountManager.get(this); // Use your Glassware's account type. Account[] accounts = accountManager.getAccountsByType(ACCOUNT_TYPE);//Same Account_type which was passed

Mirror API custom menu and custom properties

五迷三道 提交于 2019-12-12 01:40:05
问题 In my app I have added custom menu items to user timeline items. I am creating the custom menus in iteration. Is there any way to append the custom properties to the custom menu item? , so that I can know which menu item is clicked. ere is my code for custom menu, // And custom actions List<MenuValue> menuValues = new ArrayList<MenuValue>(); menuValues.add(new MenuValue().setIconUrl(WebUtil.buildUrl(req, "/static/images/drill.png")).setDisplayName("Found")); menuItemList.add(new MenuItem()

How to pull attachments from Google Glass item?

帅比萌擦擦* 提交于 2019-12-11 22:16:48
问题 I created NodeJS server that communicate with Google Glass, I want to know how to pull attachment from item, below you can see the item with attachments: Note: in my project I already have: *Send item item to glass(contact, card, location, etc..) *Subscription to timeline collection *Contact with callback to let Glass user share content - for more info Visit How to add another option to the share functionality of Google Glass? Do I need to use the selfLink to pull the attachment? if yes then

Subscriptions Not Receiving Timeline Notifications

混江龙づ霸主 提交于 2019-12-11 21:59:45
问题 Steps to Reproduce (unexpected behavior in bold ): I successfully create an app contact via the Python Starter App I successfully subscribe to timeline notifications I take a photo with Glass I share that photo with my app contact The photo is duplicated on the timeline The app's callbackUrl is never pinged (yet POSTing manually via curl works fine) Attempting to delete the duplicated photo card makes the Glass OS glitch out until reboot 回答1: Posting some sample code with actual URLs may help

Google Glass - Not receving subscription notifications -

折月煮酒 提交于 2019-12-11 12:49:10
问题 Can someone spot what is wrong? the callback url is a valid ssl url. Also how do we know if google service itself is having issues? I don't yet see posts to my callback url at all on my web server logs.. I don't seem to be getting notifications back. StoredCredentialsDBContext db = new StoredCredentialsDBContext(); TimelineItem item = new TimelineItem() { Creator=new Contact(){DisplayName="DLN Reply Card",Id="TESTREPLYCARD" }, Title = Test Number", Text = "Say Test Number", Notification = new

Can Mirror Api call an external web service?

萝らか妹 提交于 2019-12-11 09:25:01
问题 I want to develop an app with mirror api for the novel google glasses. Is it possible to call an external web service from the glassware? I have to use this web service to obtain the informations to display in the timeline cards. If it is possible, how I can do it? 回答1: You need to provide a web service that interacts with the user's timeline to insert cards, but you can interact with whatever other web services you want from within yours in order to get the data that you push. Something like