The Certificate upload endpoint is:
The certificate needs to be JSON escaped:
This is a tool you can use for JSON escaping: http://bernhardhaeussner.de/odd/json-escape/
(The tool does not send data back to the hosting server but you can choose your own escaping process as needed).
The resulting upload should look like
“public_certificates”: “JSON escaped certificate”,
“private_key”: “JSON escaped private key”