Add "display-capture" permissions for Retool and/or custom components

I tried to use getDisplayMedia within a Custom component to do a screencap of the Retool window and I am getting this error:

Error: SecurityError: Failed to execute 'getDisplayMedia' on 'MediaDevices': Access to the feature "display-capture" is disallowed by permission policy.

A little research tells me that this is a feature flag that can be enabled in an iFrame.

I also tried to do it right in a js query and got the same error.

I am developing a bug reporting widget to place onto my apps. I would like to have a screen capture function built in and getDisplayMedia seems like the slickest way to do it.

Another option is to use .downloadPage and then have the user upload the resulting PDF, but it's not as efficient.

2 Likes

Yesss !!

@bradlymathews did you manage to get this working at all? I want this too.

In my case I want to add a component to perform live audio transcription of video calls. The "display" part is technically irrelevant, but the display-capture permission is required for audio and video when you're pulling audio from a video stream.

1 Like

Hey @Dave_Cranwell! Welcome to the community. :slightly_smiling_face:

I don't think the previous generation of custom components were ever updated to allow for display-capture permissions. A lot of those older conversations do talk about punting that particular feature to the new Custom Component Library, but it hasn't yet been implemented.

I'll ask the team about the status of that particular feature and update you here as soon as I have news!

@Darren yes please do, I'd love for this API to be supported. I'm trying the new Custom Component Library for this project but it was a bit of a show-stopper to discover there's no practical way of capturing display media without this. In the meantime I can just launch a window to a personally-hosted app, then have a "copy to retool" button or similar, but being able to transcribe into another retool input field directly would be awesome.

1 Like