This generated sample provides a skeleton to get started with Cloud Endpoints Frameworks for App Engine using a Discovery Document. This sample contains comments of how to use the prior Endpoints Frameworks as well. For clarity, the prior Endpoints Frameworks and the new Endpoints Frameworks are denoted as Endpoints Frameworks v1.0 and Endpoints Frameworks v2.0 respectively.
Google Cloud Endpoints Frameworks v2.0 provides new functionality which may require payment and uses an OpenAPI specification. The OpenAPI development process is explained here and a quickstart is provided here.
-
Add your API method to
src/main/java/com/necoutezpas/YourFirstAPI.java
. -
[Optional]: Use Cloud Endpoints Frameworks v1.0.
-
Uncomment Endpoints Frameworks v1.0 sections and comment Endpoints Frameworks v2.0 sections in the following files.
pom.xml build.gradle src/main/webapp/WEB-INF/web.xml
-
-
Build and Run the application locally at http://localhost:8080 by using:
mvn clean appengine:run
-
Explore local server's API explorer by browsing to:
-
Generate the client library with a readme located at
target/client-libs/helloworld-v1-java.zip
by using:mvn endpoints-framework:clientLibs
-
Build and Deploy your application to Google App Engine by using:
mvn clean appengine:deploy
-
Build and Run the application locally at http://localhost:8080 by using:
gradle clean appengineRun
-
Explore local server's API explorer by browsing to:
-
Generate the client library with a readme located at
build/endpointsClientLibs/helloworld-v1-java.zip
by using:gradle endpointsClientLibs
-
Build and Deploy your application to Google App Engine by using:
gradle clean appengineDeploy