Skip to content

@run402/functions v4.19.0

Choose a tag to compare

@github-actions github-actions released this 03 Nov 14:19
· 105 commits to main since this release

Video preparation for delegated uploads

  • assets.createUpload({ ..., video }) (and uploads.handler's open path) accepts video: { transcript?, language?, maxCostUsdMicros? } for a video/* upload. Once the upload completes, run402 prepares it: a web copy that streams and seeks in every browser (H.264 MP4, at most 1280 px), a poster JPEG, and with transcript: true a timed transcript in the spoken language. language (ISO 639-1) skips detection; maxCostUsdMicros caps the charge, and a longer video fails before any work and costs nothing.
  • uploads.handler({ onVideo, onVideoFailed }) hears the result in a second durable run: onVideo gets the asset with its video outputs, onVideoFailed gets { code, message }.
  • assets.sign / signMany take the video variants video_web, video_poster and video_transcript, and AssetRef.video types the outputs.
  • Billing is per started minute of video, at least five, at the prices published under video in GET /tiers/v1, debited from the organization's allowance once the outputs exist.