Email attachment upload

Hi!
I'm trying to implement email attachment upload via an app by following instructions from https://developer.mypurecloud.com/forum/t/uploading-attachments-onto-an-email/2953 and https://developer.mypurecloud.com/api/rest/v2/conversations/upload-email-attachments.html.
First of all both places mention different upload addresses: https://api.mypurecloud.com/uploads/postino-attachments and https://apps.mypurecloud.com/uploads/postino-attachments.

If using api address I'm getting in browser log error: Access to XMLHttpRequest at 'https://api.mypurecloud.de/uploads/postino-attachments' from origin 'https://abc.app' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: It does not have HTTP ok status.
In case of apps address error is : Access to XMLHttpRequest at 'https://apps.mypurecloud.de/uploads/postino-attachments' from origin 'https://abc.app' has been blocked by CORS policy: Request header field authtoken is not allowed by Access-Control-Allow-Headers in preflight response.

Which address should we use and how to troubleshoot that error message?

Hi!
Found error in my code, so it is working now.
Anyways, the correct address starts with apps.

1 Like

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.