You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When request is sent using Accept application/hal+json
firstName is being converted to first_name as expected.
When request is send using Accept application/prs.hal-forms+json
HAL-FORMS _templates section is present, but properties are not converted (ex firstName is displayed). In this case other Jackson annotations are being ignored, @JsonInclude(Include.NON_EMPTY) is one example.
Example class
@Getter
public class User extends RepresentationModel<User> {
@JsonProperty("first_name")
private final String firstName;
@JsonProperty("last_name")
private final String lastName;
@JsonProperty("email")
private final String email;
@JsonProperty("home_phone")
private final String homePhone;
@JsonProperty("cell_phone")
private final String cellPhone;
@JsonCreator
public CreateUser(@JsonProperty("first_name") String firstName,
@JsonProperty("last_name") String lastName,
@JsonProperty("email") String email,
@JsonProperty("home_phone") String homePhone,
@JsonProperty("cell_phone") String cellPhone) {
this.firstName = firstName;
this.lastName = lastName;
this.email = email;
this.homePhone = homePhone;
this.cellPhone = cellPhone;
}
}
The text was updated successfully, but these errors were encountered:
1.0.0.RC2
When configured for HAL or HAL-FORMS
When request is sent using Accept application/hal+json
firstName is being converted to first_name as expected.
When request is send using Accept application/prs.hal-forms+json
HAL-FORMS _templates section is present, but properties are not converted (ex firstName is displayed). In this case other Jackson annotations are being ignored, @JsonInclude(Include.NON_EMPTY) is one example.
Example class
The text was updated successfully, but these errors were encountered: