我正在使用MailChimp API v3.0,我需要根据 MailChimp API 文档创建一个新的Segment :http: //developer.mailchimp.com/documentation/mailchimp/reference/lists/segments/
它在我的 C# API Wrapper 中不起作用,我正在使用 CURL(文档中建议)进行测试,特别是用于 Windows 的 CURL:https ://curl.haxx.se/ ...这是我的命令:
curl --request POST --url https://usXX.api.mailchimp.com/3.0/lists/my1i5t1d/segments --header "Authorization: apikey myap1k3y-usXX" --header 'Content-Type: application/json' --data '{"name":"myDynamicSegment"}' --include
响应消息是:
HTTP/1.1 400 Bad Request
Server: nginx
Content-Type: application/problem+json; charset=utf-8
Content-Length: 203
X-Request-Id: 1d001b85-0286-4339-ab37-3cb49c6f28f8
Link: <https://us13.api.mailchimp.com/schema/3.0/ProblemDetailDocument.json>; rel="describedBy"
Date: Thu, 14 Jul 2016 22:06:08 GMT
Connection: close
Set-Cookie: _AVESTA_ENVIRONMENT=prod; path=/
{"type":"http://developer.mailchimp.com/documentation/mailchimp/guides/error-glossary/","title":"JSON Parse Error","status":400,"detail":"We encountered an unspecified JSON parsing error.","instance":""}