Generated iOS Endpoint Discovery File Does Not Work

I hope someone can help me here, maybe give me an idea of โ€‹โ€‹what to look for. When I run the service generator in my discovery file, I get the following output:

Generation Settings:
Output Directory: ~ / Desktop / Endpoints

Discovery RPC URL: https://www.googleapis.com/rpc?prettyPrint=false
Api Log Dir: ~ / Desktop / Endpoints
Flags:

  • Use Service Name Directory: NO
  • Delete unknown files: NO
  • Add "Generated" directory: NO
  • Allow rootURL overrides: YES Loading API files:
  • Extract ~ / Desktop / myendpoint-v1-rest.discovery ERROR: api description is not rpc detection description Generation: Record:
  • No changes from what is already on the disk.

I tried to run it both with the verbose flag, and providing it with a directory for recording logs, and also did not provide me with more information. I created an endpoint using eclipse and the API works in the API.

+4
source share
3 answers

ServiceGenerator needs a discovery file in rpc format instead of resting . You can specify the format with the -f rpc argument

Example:

{your_path_to_appengine_sdk} /endpoints.sh get-discovery-doc -f rpc your.package.yourAPIclass

+6
source

, , rpc. . @PaulR

0

This probably doesn't apply to most people, but if you use Android Studio and use gradle in the backend module, discovery documents can be automatically generated by the installation getClientLibsOnBuild = truein the gradle file:

appengine {
    downloadSdk = true
    appcfg {
        oauth2 = true
    }
    endpoints {
        getClientLibsOnBuild = true
        getDiscoveryDocsOnBuild = true
    }
}

Discovery documents are located at <project>/<module>/build/discovery-docs/. If they are not generated, try deploying to App Engine, which did it for me.

0
source

All Articles