Skip to content

POST Request - JSON Body... #3

Description

@r2d2c3p0

POST URL: http://localhost:8080/users/load
Content-Type: application/json
Body: [{id=1, name=Ajay, teamName=Development, salary=100}]

Response:
{
"timestamp": 1524376855129,
"status": 400,
"error": "Bad Request",
"exception": "org.springframework.http.converter.HttpMessageNotReadableException",
"message": "Could not read document: Can not deserialize instance of com.movingtoweb.model.Users out of START_ARRAY token\n at [Source: java.io.PushbackInputStream@ba08f7b; line: 1, column: 1]; nested exception is com.fasterxml.jackson.databind.JsonMappingException: Can not deserialize instance of com.movingtoweb.model.Users out of START_ARRAY token\n at [Source: java.io.PushbackInputStream@ba08f7b; line: 1, column: 1]",
"path": "/users/load"
}

Can you tell me what am I doing wrong?

Thanks,
r2d2c3p0.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions