Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Preview API: expose supported file/MIME types via Capabilities endpoint #31267

Open
felix-schwarz opened this issue Apr 25, 2018 · 7 comments
Open

Comments

@felix-schwarz
Copy link

Clients targeting the Preview API at remote.php/dav/files/[user]/[file]?x=[width]&y=[height]&c=[eTag]&preview=1 have no way of telling in advance for which file types a preview can likely be expected to be available.

Ideally, a list of MIME types, for which the Preview API is likely capable of providing a preview, would be available as part of the capabilities endpoint.

Using that list, clients could then see if the MIME type of an item is in that list and only request thumbnails for those items for which this is the case.

@felix-schwarz felix-schwarz changed the title Expose supported Preview API MIME Types Expose file/MIME types supported by Preview API via Capabilities endpoint Apr 25, 2018
@felix-schwarz felix-schwarz changed the title Expose file/MIME types supported by Preview API via Capabilities endpoint Preview API: expose supported file/MIME types via Capabilities endpoint Apr 25, 2018
@ownclouders
Copy link
Contributor

GitMate.io thinks the contributor most likely able to help you is @PVince81.

Possibly related issues are #14106 (previews broken for non-supported file types), #7574 (Add to mime type list), #15124 (MPO support), #29076 (Add eml to list of known mime types), and #29158 (Dear Support, ).

@michaelstingl
Copy link

michaelstingl commented Apr 30, 2018

Related docs:
https://doc.owncloud.org/server/latest/admin_manual/configuration/server/config_sample_php_parameters.html#previews

'enabledPreviewProviders' => array(
        'OC\Preview\PNG',
        'OC\Preview\JPEG',
        'OC\Preview\GIF',
        'OC\Preview\BMP',
        'OC\Preview\XBitmap',
        'OC\Preview\MP3',
        'OC\Preview\TXT',
        'OC\Preview\MarkDown'
),

@michaelstingl
Copy link

Could the capability also include available formats of the preview itself?

Example 1

Source:

  • *.docx

Available previews:

  • *.pdf
  • *.png

Example 2

Source:

  • *.r3d (Redcode RAW, from RED Digital Cinema Camera)

Available previews:

  • *.png (static previews)
  • *.mp4 (video previews, could be played in browser or iOS app)

Related:

@felix-schwarz
Copy link
Author

Yes, this would be awesome. That way, clients could - in addition to knowing which files to request previews for - also pick the preview format they can process best.

@ownclouders
Copy link
Contributor

Hey, this issue has been closed because the label status/STALE is set and there were no updates for 7 days. Feel free to reopen this issue if you deem it appropriate.

(This is an automated comment from GitMate.io.)

@ownclouders
Copy link
Contributor

Hey, this issue has been closed because the label status/STALE is set and there were no updates for 7 days. Feel free to reopen this issue if you deem it appropriate.

(This is an automated comment from GitMate.io.)

@stale
Copy link

stale bot commented Sep 20, 2021

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 10 days if no further activity occurs. Thank you for your contributions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Development

No branches or pull requests

5 participants