Stream refreshed media for playback and view full
This commit is contained in:
+6
-4
@@ -154,10 +154,12 @@ that deletion is irreversible. The delete button is disabled for a 5 second coun
|
||||
shows the metadata banner below, vertical media shows it to the right, and videos carry a large
|
||||
play icon top-right. The play action embeds a YouTube, Vimeo, Twitch, or Streamable player, or
|
||||
plays a direct mp4/webm/m4v; when neither is possible it opens the external-site warning, since
|
||||
the page is the only way to watch. **View full** opens the embedded media (player, local file,
|
||||
or cached preview) in a new tab; the full link is a separate button that opens the original
|
||||
page with the warning. Length comes from Discord's attachment duration and, for downloads, an
|
||||
ffprobe probe. The status row reads
|
||||
the page is the only way to watch. Playback and **View full** go through
|
||||
`/api/media/<scrape>/<item>/stream`, which serves the local file or re-fetches the source message
|
||||
for a fresh signed URL, so expired CDN links still play. Embed `videoUrl`s (gifv/Tenor mp4s) are
|
||||
stored as `play_url` and used directly. The full link is a separate button that opens the
|
||||
original page with the warning. Length comes from Discord's attachment duration and, for
|
||||
downloads, an ffprobe probe. The status row reads
|
||||
`(Images/Videos) | Downloaded A/B | Cached C/B (excl Downl) | Loaded L/B`, where B is the total
|
||||
for the active filters. A scrape strip shows live progress with Stop.
|
||||
**New scrape…** (rightmost) opens a popup with Server and Group chat trees (servers expand to
|
||||
|
||||
+2
-1
@@ -260,7 +260,8 @@ replaceable.
|
||||
| GET | `/api/transcript` | `limit?`, `sessionId?` | Sessions and captured segments |
|
||||
| GET | `/api/media` | `kind?`, `source?`, `channelId?`, `authorId?`, `aspect?`, `resolution?`, `after?`, `before?`, `limit?`, `offset?` | Media items across every scrape, newest first. `source` is `attachment`, `sticker`, or `embed`; `aspect` and `resolution` are the preset keys; `after`/`before` are ISO times on `posted_at`. Items carry `authorName`, `postedAt`, `width`, `height`, `aspectRatio`, `contentType`, `durationSecs`; `localUrl`/`thumbUrl` when a file or preview exists |
|
||||
| GET | `/api/media/:scrapeId/:itemId/file` | none | The downloaded file, content-typed from its extension |
|
||||
| GET | `/api/media/:scrapeId/:itemId/thumb` | none | The cached WebP preview |
|
||||
| GET | `/api/media/:scrapeId/:itemId/thumb` | none | The cached preview (type from `preview_ext`) |
|
||||
| GET | `/api/media/:scrapeId/:itemId/stream` | none | Playback/full-view source: the local file, or the remote URL refreshed from the source message. Supports `Range` |
|
||||
| GET | `/api/media/scrapes` | none | Every scrape with state and counters |
|
||||
| GET | `/api/media/status` | none | Slopbot connection state and the scrape list |
|
||||
| GET | `/api/media/authors` | none | Distinct posters across every scrape, with counts |
|
||||
|
||||
Reference in New Issue
Block a user