无法从 START_ARRAY 令牌中反序列化 java.lang.String 的实例:
大家好,我想从 lambda 调用我的 api,但是当我传递请求时,我收到此错误“无法从 START_ARRAY 令牌中反序列化 java.lang.String 的实例” 这是 POJO,但这里只有列表辅助在从 Lambda 传递请求时不会反序列化
@Data
@Builder
@ToString
public class BulkFetchRequest {
@JsonProperty("merchId")
private String merchId;
@JsonProperty("markId")
private String markId;
@JsonProperty("aids")
private List<String> aids;
}
This is my request format:
{
"merchId": "2077759361",
"markId" : "44571",
"aids": ["B096BK8GW", "B09B7S84X", "B07N7QPZD", "B09GG2LPL" , "B09M41GVR"]
}
Hi Everyone i want to call my api from lambda but when i am passing the request i got this error "Cannot deserialize instance of java.lang.String out of START_ARRAY token"
This is the POJO but here only List aids is not deserializing when passing request from Lambda
@Data
@Builder
@ToString
public class BulkFetchRequest {
@JsonProperty("merchId")
private String merchId;
@JsonProperty("markId")
private String markId;
@JsonProperty("aids")
private List<String> aids;
}
This is my request format:
{
"merchId": "2077759361",
"markId" : "44571",
"aids": ["B096BK8GW", "B09B7S84X", "B07N7QPZD", "B09GG2LPL" , "B09M41GVR"]
}
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论