Code: Select all
{
"email_address": "testchimp@gmail.com",
"status": "subscribed",
"merge_fields": {
"FNAME": "testmailchimp",
"LNAME": "testingit",
}
}
Code: Select all
@Override
protected Map getParams(){
Map params = new HashMap();
params.put("email_address","testchimp@gmail.com");
params.put("status","unsubscribed");
//here i want to add the arraylist FNAME and LNAME
return params;
}
Ich habe mein Problem damit gelöst:
Code: Select all
final JSONObject jsonBody = new JSONObject("{\"email_address\":\"mailchimptester@gmail.com\"," +
"\"status\":\"unsubscribed\"," +
"\"merge_fields\":{\"FNAME\":\"test\",\"LNAME\":\"teste\"}}");