As an example, if I have a Java POJO like this

class Car {
  private String model;
  private String transmissionType;
  private int year;

  ...
  
}

and my endpoint returns Car, then the response would look something like 
this

{
    "model": "Porshe 911",
    "transmissionType": "Petrol",
    "year": 2017
}

What I want to do is, rename the entity such that the response looks like...

{
    "model": "Porshe 911",
    "transmission_type": "Petrol",
    "year": 2017
}

Hope this makes more sense now.

On Tuesday, 4 July 2017 13:34:37 UTC-4, George (Cloud Platform Support) 
wrote:
>
> Hello Raunak, 
>
> How would you describe a use-case typical of your situation? What is here 
> exactly meant by "renaming" an entity? 
>
> A possible solution, based on information at hand, would be based on using 
> Annotation 
> Type ApiTransformer 
> <https://cloud.google.com/endpoints/docs/frameworks/legacy/v1/java/javadoc/com/google/api/server/spi/config/ApiTransformer>.
>  
> More detail in the @ApiTransformer subchapter 
> <https://cloud.google.com/endpoints/docs/frameworks/legacy/v1/java/annotations#apitransformer>
>  
> of the "Endpoint Annotations and Syntax" documentation page. 
>
> All other information you deem relevant can prove quite helpful. 
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/977df85b-2a49-4617-935f-cb0614b0eb1b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to