Legacy Dev Forum Posts

 View Only

Sign Up

Using Clipboard API inside iframes

  • 1.  Using Clipboard API inside iframes

    Posted 06-05-2025 19:22

    dvoicu | 2021-09-23 14:31:35 UTC | #1

    I added a client application using this link https://help.mypurecloud.com/articles/set-custom-client-application-integration/

    The application is correctly loaded inside an iframe, the only issue is the I cannot use the copy to clipboard functionality from my application because the generated iframe is missing the clipboard-read; clipboard-write permissions. It only has the camera; microphone; geolocation;, not sure how this were added. This is the generated iframe html, I mocked some of the data

    <iframe data-app-id="----" allow="camera; microphone; geolocation;" aria-hidden="false" sandbox="allow-scripts allow-same-origin allow-forms allow-modals allow-popups" src="https://dummy.url" name="app-instance-123" id="123">

    This is the error I'm getting when trying to use the copy to clipboard functionality.

    NotAllowedError: The Clipboard API has been blocked because of a permissions policy applied to the current document. See https://goo.gl/EuHzyv for more details.

    Is there a way to set the required attributes?


    tim.smith | 2021-09-23 17:01:07 UTC | #2

    Client apps do not currently support allowing clipboard operations as the allowed list of iframe options is limited to the ones documented at the link above. You can request new features and share your use case to assist with prioritization at https://genesyscloud.ideas.aha.io/.


    system | 2021-10-24 17:01:31 UTC | #3

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


    This post was migrated from the old Developer Forum.

    ref: 12114