Do not display self link in the response of Json API CRNK

196 Views Asked by At

I am using crnk framework. I have an object with some properties. The ID field is annotated with @JsonApiId. In some specific scenario the Id field is null and the self link is generated with null value in place of ID parameter(ex: www.something.com/something/null). How to avoid displaying self link in the response here? I need all other fields to come in the response except self link.

1

There are 1 best solutions below

0
bunny On BEST ANSWER

we can achieve this by using an instance of DefaultSelfLinksInformation with an annotation @JsonApiLinksInformation