APIv3-examples icon indicating copy to clipboard operation
APIv3-examples copied to clipboard

Post requests "gets Required fields were not provided"

Open Taraka16 opened this issue 7 years ago • 3 comments

I'm using postman to send post request to mailchimp. My call look like this:

{
  "operations": [
  {
   "method": "POST",
    "path": "lists/ff80d78e68/members",
    "operation_id": "my-op-id", 
    "params": {}, 
    "body": "{\"email_address\": \"[email protected]\",
    	\"status\": \"subscribed\",
    \"merge_fields\": {
        \"IMIS_ID\": \"12\",
        \"FNAME\": \"test1\",
        \"LNAME\": \"test1last\"
}
    }"
  },
    {
	
    "operation_id": "my-op-id", 
    "method": "POST",
    "path": "lists/ff80d78e68/members",
    "body": "{
    	\"email_address\": \"[email protected]\",
    	\"status\": \"subscribed\",
    \"merge_fields\": {
        \"IMIS_ID\": \"13\",
        \"FNAME\": \"test2\",
        \"LNAME\": \"test2last\"
}
    }"
  }

 ]
}

And that's what I get:

"errors": [
        {
            "field": "",
            "message": "Required fields were not provided: email_address"
        }

Anybody can tell me what I do wrong?

Taraka16 avatar Mar 05 '18 12:03 Taraka16

Did u sovle it? Having same issues now

AllStackDev1 avatar Sep 10 '18 16:09 AllStackDev1

I'm getting the same trying to batch my PUT requests

agordeev avatar Sep 26 '18 04:09 agordeev

check if you are actually passing the required fields.

AllStackDev1 avatar Sep 26 '18 13:09 AllStackDev1