MailChimp API 3.0无效的资源错误

And*_*ewb 7 json mailchimp-api-v3.0

我只是想在MailChimp列表中添加一个新成员.但我不断收到以下错误,并不能理解为什么:

type: http://developer.mailchimp.com/documentation/mailchimp/guides/error-glossary/
title: Invalid Resource
status: 400
detail: The resource submitted could not be validated. For field-specific details, see the 'errors' array.
instance:
errors:
0:
field:
message: Schema describes object, NULL found instead
Run Code Online (Sandbox Code Playgroud)

这很奇怪,因为我正在发送正文中的确切对象,详见docs中的exampled:

{"email_address":"urist.mcvankab+3@freddiesjokes.com", "status":"subscribed"}
Run Code Online (Sandbox Code Playgroud)

我在Postman以及MailChimp Playground尝试了这个电话.我在这里省略了JSON中的内容吗?

Yas*_*ynh 8

所以我也陷入困境,事实证明你需要"merge_fields".把它变成一个空物体,

{
    "email_address": "blahblar@blarblah.com",
    "status": "subscribed",
    "merge_fields": {

    }
}
Run Code Online (Sandbox Code Playgroud)

  • @MattCosentino 考虑到我在 4.5 年前“解决”了这个问题,文档还没有更新来解释这个问题,这有点令人遗憾。 (2认同)