{list}. Body is always an array: { rules: [ { keyword, match, applies_to }, … ] } (1–1000) — a single keyword is just an array of one. Each applies_to must enable at least one of localpart/domain/email. All-or-nothing: if any item is invalid the whole request is rejected 400 invalid_request and nothing is written. Keywords are stored space-stripped and upserted on keyword (re-adding the same keyword updates the existing rule in place — no duplicate). Returns 200 with { data: [rules] } (each with its stable id, deduped, in first-seen order). Unknown type or list, or an unowned connection, → 404 not_found. Honors Idempotency-Key.curl --location 'https://api.mailfloss.com/v1/integrations//connections//keywords/' \
--header 'Idempotency-Key;' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"rules": [
{
"keyword": "string",
"match": "exact",
"applies_to": {
"localpart": true,
"domain": true,
"email": true
}
}
]
}'{
"data": [
{
"id": "kw_7f8e9d0c1b2a3f4e",
"keyword": "noreply",
"match": "exact",
"applies_to": {
"localpart": true,
"domain": false,
"email": false
}
},
{
"id": "kw_6e7d8c9b0a1f2e3d",
"keyword": "mailinator",
"match": "contains",
"applies_to": {
"localpart": false,
"domain": true,
"email": false
}
}
]
}