Updating Memo/Rich Text Editor Fields with the API
I created a contact custom field with data type "Note" and field type "RichTextEditor" and then ran this API call:

CRM.api3('Contact', 'create', {
  "contact_type": "Individual",
  "id": 180,
  "custom_15": "&lt;p&gt;&lt;strong&gt;foobar&lt;/strong&gt;&lt;/p&gt;"
});


The value was stored as-is, and shows correctly in the UI.

This part of CRM_Utils_API_HTMLInputCoder should ensure that custom fields of type RichTextEditor are excluded.

One scenario in which this might not work: Let's say you have another API wrapper that renames a parameter from, say, food_preference to custom_22. If the renaming API wrapper runs after CRM_Utils_API_HTMLInputCoder (not sure what the order is there, I'd guess core ones run first), food_preference would already be encoded before it gets to your wrapper.