google-cloud-endpoints

Android Studio: IncorrectOperationException when 'Add as Library' is clicked whilst trying to configure Google Apps Endpoints client libraries

百般思念 提交于 2019-12-04 12:51:12
I am trying to generate and use the android client libraries for a Python google app engine project following this guide https://developers.google.com/appengine/docs/python/endpoints/consume_android Everytime I get to this step Select the library you just added, right-click, then select Add As Library to your project. I get the following exception: IncorrectOperationException: Must not change document outside command or undo-transparent action. I'm new to Android Studio but can't seem to find any resources on how to get endpoints client libraries working in Eclipse. Has anyone else experienced

Sending and retreaving data from datastore with mobile backend starter

末鹿安然 提交于 2019-12-04 12:37:30
I'm trying to use Mobile Backend Starter in my Android application. In order to do that I need to store some data in the Datastore. I'm using the provided object CloudEntity but I can only consistently insert and read String . That's the example code I used to send data: CloudEntity entity = new CloudEntity(TEST_KIND_NAME); entity.put(KEY_DATE, new Date(System.currentTimeMillis())); entity.put(KEY_CALENDAR, Calendar.getInstance()); entity.put(KEY_LONG, Long.valueOf(Long.MAX_VALUE)); entity.put(KEY_INTEGER, Integer.valueOf(Integer.MAX_VALUE)); getCloudBackend().insert(entity, simpleHandler);

Google App Engine: Endpoints authentication when custom auth or Open ID is used

…衆ロ難τιáo~ 提交于 2019-12-04 11:42:44
问题 I recently got started with Google App Engine. I intend to use Flask to serve web pages and the Endpoints API, preferably with the Endpoints-Proto-Datastore for everything else. From the beginning, non-Google Authentication mechanisms on GAE seem like they need some work. I'd appreciate any light shed on issues I've found so far: Custom Authentication If you can write an Open ID provider as part of the app, use something like Python-OpenID and also implement a consumer in the same workflow so

How to disable GZipContent in Cloud Endpoints builder in Android

喜欢而已 提交于 2019-12-04 11:41:30
问题 I want to disable GZipContent for a Google Cloud Endpoints class so that a POST can work on the local development server. The latest GPE release generates this endpoint builder: public static final class Builder extends AbstractGoogleJsonClient.Builder { public Builder(HttpTransport transport, JsonFactory jsonFactory, HttpRequestInitializer httpRequestInitializer) { super( transport, jsonFactory, ...); } and Google documentation recommends using it like this: Myendpoint.Builder

Get ImportError: No module named control when following google cloud endpoint tutorial

我怕爱的太早我们不能终老 提交于 2019-12-04 11:35:08
I am following this tutorial on setting up cloud endpoints in python on googles app engine and keep on getting an import error ImportError: No module named control on the Generating the OpenAPI configuration file step when I input python lib/endpoints/endpointscfg.py get_swagger_spec main.EchoApi --hostname echo-api.endpoints.projectid.cloud.goog I followed these steps on a new account and still got this error. No idea what I am doing wrong/steps I am skipping. here is the traceback: Traceback (most recent call last): File "lib/endpoints/endpointscfg.py", line 625, in <module> main(sys.argv)

Can I return a generic in Google Cloud End Point

一笑奈何 提交于 2019-12-04 11:09:25
When I return a generic the end point api file seems to disappear. Sample code is pasted. @ApiMethod public RestResponse<Container> testGeneric() { Container container = new Container(); container.testLong = (long)4345; container.testDate = new Date(); container.testString = "sathya"; container.testDouble = 123.98; container.testInt = 123; RestResponse<Container> response = new RestResponse<Container>(); response.t = container; return response; } Is this a bug in endpoint and is such a thing not allowed at all ? Regards, Sathya I don't think it's a bug, but it's just not supported, in the same

Google Cloud Endpoints without Google Accounts

你。 提交于 2019-12-04 10:26:04
问题 Our web application does not offer Google Accounts authentication. We have implemented our own authentication using WebApp2 Authentication: http://webapp-improved.appspot.com/tutorials/auth.html. We'd like to use Cloud Endpoints as an API for mobile apps/third party developers but we would still like to use oAuth2 for authentication. What are the steps required to implement this? Do we need to setup our own oAuth server on AppEngine and will the Google client libraries be compatible? 回答1: You

Consuming GAE Endpoints with a Python client

牧云@^-^@ 提交于 2019-12-04 09:59:24
问题 I am using Google AppEngine Endpoints to build a web API. I will consume it with a client written in Python. I know that scripts are provided to generate Android and iOS client API, but it doesn't seem that there is anything comparable for Python. It does seem redundant to code everything again. For instance, the messages definition which are basically the same. It there anyway of getting this done more easily? Thanks 回答1: You can use the Google APIs Client Library for Python which is

Google Cloud Endpoints - Making calls with JS client, passing params and JSON body

左心房为你撑大大i 提交于 2019-12-04 08:42:25
问题 I am having some trouble understanding some documentation on this. Located at ... https://developers.google.com/appengine/docs/java/endpoints/consume_js specifically ... // Insert a score gapi.client.tictactoe.scores.insert({'outcome': 'WON'}).execute(function(resp) { console.log(resp); }); // Get the list of previous scores gapi.client.tictactoe.scores.list().execute(function(resp) { console.log(resp); }); Seems like they are passing a score object, as JSON in the request body, to their API

How to use GoogleApiClient to provide credentials for cloud endpoint client

北慕城南 提交于 2019-12-04 07:41:10
Ok, using the GoogleApiClient of Google Play Services I have let the user select an account (if multiple) and confirm oauth permissions for my Android app. I need this for leader boards and a few other things. But I'm also using an AppEngine backend and need to authenticate the user with that. To do so I need to pass in the emailAccount with which to authenticate. Prior to integrating Google Play Services I handled account selection manually, so I always had access to the emailAccount selected by the user. But the GoogleApiClient handles that at arms length. private void signInToGoogleAccount(