Endpoints Frameworks verarbeitet ebenso wie andere Web-Frameworks die Low-Level-Kommunikationsdetails von HTTP-Anfragen und -Antworten für Ihre Anwendung. Wenn ein Client eine Anfrage an Ihre API sendet, leitet Endpoints Frameworks die URL der Anfrage an die Funktion oder Methode in Ihrem Code weiter, von der die Anfrage verarbeitet wird.
Endpoints Frameworks konvertiert den Rückgabewert in das JSON-Format und sendet die Antwort. Metadaten fügen Sie Ihrem Quellcode in Java mit Anmerkungen und in Python mit Decorators hinzu. Die Metadaten definieren die Oberfläche der REST APIs für Ihre Anwendung.
@endpoints.method(# This method takes a ResourceContainer defined above.ECHO_RESOURCE,# This method returns an Echo message.EchoResponse,path="echo",http_method="POST",name="echo",)defecho(self,request):output_message=" ".join([request.message]*request.n)returnEchoResponse(message=output_message)
Wenn Sie Endpoints Frameworks verwenden, brauchen Sie für Ihre Anwendung keinen Webserver eines Drittanbieters wie Apache Tomcat oder Gunicorn bereitzustellen. Sie annotieren oder dekorieren den Code und stellen die Anwendung so bereit, wie sie es auch in der App Engine-Standardumgebung tun würden.
API-Verwaltung
Der Extensible Service Proxy (ESP) bietet API-Verwaltungsfeatures für Endpoints für OpenAPI und Endpoints für gRPC. Er wird zusammen mit den Instanzen Ihres Back-Ends in einem Container ausgeführt.
Da die App Engine-Standardumgebung in der Entwicklungsphase von Endpoints Frameworks keine Bereitstellungen für mehrere Container unterstützt hat, wird der ESP von Endpoints Frameworks nicht verwendet. Endpoints Frameworks enthält stattdessen ein integriertes API-Gateway mit API-Verwaltungsfeatures, die mit den Features vergleichbar sind, die der ESP für Endpoints für OpenAPI und Endpoints für gRPC bereitstellt.
Endpoints Frameworks fängt alle Anforderungen ab und führt alle erforderlichen Prüfungen durch, z. B. eine Authentifizierung, bevor die Anfrage an die Back-End API weitergeleitet wird. Wenn das Back-End antwortet, erfasst und meldet Endpoints Frameworks telemetrische Messwerte. Messwerte für Ihre API können Sie in der Google Cloud Console auf der Seite Endpoints > Dienste einsehen.
Sie können Endpoints Frameworks mit oder ohne API-Verwaltungsfunktionen verwenden. Die Verwendung von Endpoints Frameworks ohne API-Verwaltungsfunktionen ist kostenlos. Die Gebühren für API-Verwaltungsfunktionen finden Sie auf der Seite mit den Cloud Endpoints-Preisen.
Beschränkungen
Endpoints Frameworks wird nur in den Python 2.7- und Java 8-Laufzeiten der App Engine-Standardumgebung unterstützt.
Endpoints Frameworks bietet keine Unterstützung für die Node.js-, PHP- und Go-Laufzeiten in der App Engine-Standardumgebung.
Endpoints Frameworks bietet keine Unterstützung für die flexible Umgebung von App Engine.
Endpoints Frameworks bietet keine Unterstützung für Cloud Run-Funktionen, Compute Engine und Google Kubernetes Engine.
[[["Leicht verständlich","easyToUnderstand","thumb-up"],["Mein Problem wurde gelöst","solvedMyProblem","thumb-up"],["Sonstiges","otherUp","thumb-up"]],[["Schwer verständlich","hardToUnderstand","thumb-down"],["Informationen oder Beispielcode falsch","incorrectInformationOrSampleCode","thumb-down"],["Benötigte Informationen/Beispiele nicht gefunden","missingTheInformationSamplesINeed","thumb-down"],["Problem mit der Übersetzung","translationIssue","thumb-down"],["Sonstiges","otherDown","thumb-down"]],["Zuletzt aktualisiert: 2025-08-18 (UTC)."],[[["\u003cp\u003eCloud Endpoints Frameworks is a web framework designed for the App Engine standard Python 2.7 and Java 8 runtime environments, allowing you to generate REST APIs and client libraries.\u003c/p\u003e\n"],["\u003cp\u003eEndpoints Frameworks handles HTTP requests and responses, routing URLs to the appropriate code functions and converting return values to JSON, simplifying API development.\u003c/p\u003e\n"],["\u003cp\u003eUsing annotations in Java and decorators in Python, Endpoints Frameworks lets you define the surface of REST APIs directly within your code without the need for a third-party web server.\u003c/p\u003e\n"],["\u003cp\u003eWhile not using the Extensible Service Proxy (ESP), Endpoints Frameworks provides built-in API management comparable to ESP, including request interception, authentication, and telemetry reporting.\u003c/p\u003e\n"],["\u003cp\u003eEndpoints Frameworks is limited to the App Engine standard Python 2.7 and Java 8 environments and does not support Node.js, PHP, Go, the App Engine flexible environment, Cloud Run, Compute Engine, or Google Kubernetes Engine.\u003c/p\u003e\n"]]],[],null,["# Cloud Endpoints Frameworks is a [web\nframework](https://wikipedia.org/wiki/Web_framework) for the App Engine\nstandard [Python 2.7 and Java 8 runtime\nenvironments](/appengine/docs/standard/runtimes).\nCloud Endpoints Frameworks provides the tools and libraries that allow you to\ngenerate REST APIs and client libraries for your application.\n| **Note:** Endpoints Frameworks doesn't support the PHP, Go, or Node.js runtimes.\n\nLike other web frameworks, Endpoints Frameworks handles the low-level\ncommunication details of HTTP requests and responses for your application. When\na client sends a request to your API, Endpoints Frameworks routes the\nrequest's URL to the function or method in your code that processes the request.\nEndpoints Frameworks converts the return value to JSON and sends the\nresponse. You add metadata (by using annotations in Java and decorators in\nPython) to your source code. The metadata defines the\n[surface](/endpoints/docs/frameworks/glossary#surface) of the REST APIs for your\napplication. \n\n### Java\n\n @ApiMethod(name = \"echo\")\n public Message echo(Message message, @Named(\"n\") @Nullable Integer n) {\n return doEcho(message, n);\n }\n\nIn the example code, the\n[annotations](/endpoints/docs/frameworks/java/annotate-code) begin with\nthe `@` character.\n\n### Python\n\n @endpoints.method(\n # This method takes a ResourceContainer defined above.\n ECHO_RESOURCE,\n # This method returns an Echo message.\n EchoResponse,\n path=\"echo\",\n http_method=\"POST\",\n name=\"echo\",\n )\n def echo(self, request):\n output_message = \" \".join([request.message] * request.n)\n return EchoResponse(message=output_message)\n\nIn the example code, the\n[decorators](/endpoints/docs/frameworks/python/create_api) begin with\nthe `@` character.\n\nWith Endpoints Frameworks, you don't have to deploy a third-party web\nserver (such as Apache Tomcat or Gunicorn) with your application. You annotate\nor decorate the code and deploy your application as you normally would to the\n[App Engine standard environment](/appengine/docs/standard).\n\nAPI management\n--------------\n\nThe [Extensible Service Proxy\n(ESP)](/endpoints/docs/frameworks/glossary#extensible_service_proxy)\nprovides API management features for Endpoints for OpenAPI and\nEndpoints for gRPC. ESP runs in a container\nalongside each instance of your backend.\n\n\nBecause the App Engine standard environment didn't support\nmulti-container deployments when Endpoints Frameworks was\nunder development, Endpoints Frameworks doesn't use\nESP. Instead, Endpoints Frameworks includes a built-in\n[API gateway](https://wikipedia.org/wiki/API_management)\nthat provides API management features that are comparable to the\nfeatures that ESP provides for Endpoints for OpenAPI and\nEndpoints for gRPC.\n\n\u003cbr /\u003e\n\nEndpoints Frameworks intercepts all requests and performs any\nnecessary checks (such as authentication) before forwarding the request to the\nAPI backend. When the backend responds, Endpoints Frameworks gathers\nand reports telemetry. You can view metrics for your API on the **Endpoints\nServices** page in the Google Cloud console.\n\nYou can use Endpoints Frameworks with or without API management\nfunctionality. Use of Endpoints Frameworks without API management\nfunctionality is offered at no charge. API management functionality is charged\naccording to the [Endpoints pricing\npage](/endpoints/pricing).\n\nLimitations\n-----------\n\n- Endpoints Frameworks is supported only on the App Engine standard Python 2.7 and Java 8 runtime environments.\n- Endpoints Frameworks doesn't support the Node.js, PHP, and Go runtime environments on the App Engine standard environment.\n- Endpoints Frameworks doesn't support the App Engine flexible environment.\n- Endpoints Frameworks doesn't support Cloud Run functions, Compute Engine, and Google Kubernetes Engine.\n\nWhat's next\n-----------\n\n- To learn more about the differences between ESP and\n Endpoints Frameworks, see [Comparing Extensible Service Proxy and\n Endpoints Frameworks](/endpoints/docs/frameworks/frameworks-extensible-service-proxy#endpoints_frameworks).\n\n- For information on the language-specific libraries and tools, see the following:\n\n - [About Endpoints Frameworks for\n Java](/endpoints/docs/frameworks/java/about-cloud-endpoints-frameworks)\n - [About Endpoints Frameworks for\n Python](/endpoints/docs/frameworks/python/about-cloud-endpoints-frameworks)\n- To learn how to configure, deploy, and send requests to a sample API, see the\n following:\n\n - [Getting started with Endpoints Frameworks for Java](/endpoints/docs/frameworks/java/get-started-frameworks-java)\n - [Getting started with Endpoints Frameworks for Python](/endpoints/docs/frameworks/python/get-started-frameworks-python)"]]