We recommend that you use the latest version of this feature, which is renamed to Cloud Endpoints Frameworks for App Engine. This new version supports App Engine standard environment, provides lower latency, and has better integration with App Engine. For more details, see Migrating to 2.0.
A new version of this feature is available, renamed to Cloud Endpoints Frameworks for App Engine. This new version supports the App Engine standard environment, provides lower latency, and better integration with App Engine. For more details, see Migrating to 2.0.
Google Cloud Endpoints Frameworks consist of tools, libraries and capabilities that allow you to generate APIs and client libraries from an App Engine application, referred to as an API backend, to simplify client access to data from other applications. Endpoints Frameworks make it easier to create a web backend on App Engine for web clients and mobile clients such as Android or Apple's iOS.
For mobile developers, Endpoints Frameworks provide a simple way to develop a shared web backend and also provides critical infrastructures, such as OAuth 2.0 authentication, eliminating a great deal of work that would otherwise be needed. Furthermore, because the API backend is an App Engine app, the mobile developer can use all of the services and features available in App Engine, such as Datastore, Google Cloud Storage, Mail, Url Fetch, Task Queues, and so forth. And finally, by using App Engine for the backend, developers are freed from system admin work, load balancing, scaling, and server maintenance.
It is possible to create mobile clients for App Engine backends without Endpoints Frameworks. However, using Endpoints Frameworks makes this process easier because it frees you from having to write wrappers to handle communication with App Engine. The client libraries generated by Endpoints allow you to simply make direct API calls.
Basic Endpoints Frameworks architecture
Here's what using an Endpoints API allows you to do:
Endpoints libraries, tools, and samples
Google Cloud Endpoints Frameworks provide the following libraries and tools:
- The Endpoints package in the SDK:
endpointscfg.pycommand line tool, which generates client libraries for Android devices, and discovery documents for Android and iOS devices, as described in Generating Client Libraries.
Endpoints Frameworks provide the Tic Tac Toe sample that demonstrates a backend API. Companion client samples for that backend are available:
For more samples, refer to the Getting Started tutorials.
Using NDB Datastore with Endpoints Frameworks
The easiest way to use Endpoints Frameworks with NDB Datastore is to use the Endpoints Proto Datastore API library. For complete instructions on using this library, and for code samples, visit the companion website Introduction to the Endpoints Proto Datastore API.
The general workflow for developing an app using Endpoints Frameworks is:
- Write your API backend code first, wrapping the classes and any methods to be exposed, and creating message classes as described in Create an Endpoints API. You'll also need to create an API server, as described in Creating an API server.
- Generate Client Libraries using the
endpointscfg.pyutility directly for Android, and to generate the necessary discovery document for iOS.
- Write your client app, using the custom client libraries when making calls to the API backend.
To get started, follow the tutorial for writing a backend API.