Bulk Jobs

Create a bulk YouTube job and obtain a direct R2 upload URL

Creates an awaiting-upload coordinator record. Upload a UTF-8 text file containing one 11-character YouTube video ID per line to upload.href, then call the start operation. The file can be streamed and may contain millions of IDs.

post/bulk-jobs

Request

  • Base URL: https://api.flashdata.dev/v2
  • URL: https://api.flashdata.dev/v2/bulk-jobs
  • Auth: one of:
    • API key in cookie __Host-fd_session and API key in header X-CSRF-Token
    • API key in header X-API-Key

Request body

source'youtube_metadata' | 'youtube_transcript' | 'youtube_captions' | 'youtube_trainability' | 'youtube_download' required
optionsobject

Reused for every ID. Metadata accepts include_formats and include_chapters. Transcript and captions accept language and auto. Trainability accepts no source options. These four data sources optionally accept result_storage. Supported storage_type values are s3, s3_compatible, oss, gcs, azure, cos, bos, and tos. storage_url is the bucket name (Azure container name); object_prefix is optional. S3, S3-compatible, OSS, COS, BOS, and TOS use access_key and secret_key. S3-compatible and OSS also require a public HTTPS endpoint_url. COS, BOS, and TOS require region and use fixed provider endpoints. COS bucket names include the APPID. BOS S3-compatible HTTPS delivery supports bj, su, and hkg. GCS requires service_account with project_id, client_email, and private_key. Azure requires account_name and a container SAS sas_token with write permission. Default object_prefix is YYYYMMDD, frozen to the UTC bulk creation date. Files are written to <prefix>/<source>/<bulkId>/results/part-NNNNNNNN.jsonl.gz; manifest.json in the same bulk directory is written last. Each JSONL row includes its input index and completed, failed, or invalid status. Internal R2 results remain available through the result links for 24 hours. Download accepts the normal YouTube download parameters, requires customer storage, and does not permit browser_delivery. Download storage supports the same eight provider types and credential shapes listed above under the storage field. Download storage may include object_prefix; YYYYMMDD tokens resolve to the UTC upload date, while literal prefixes are unchanged.

callback_urlstring uri

Optional public HTTPS endpoint notified once after manifest publication.

Response

Bulk job created with a 15-minute direct upload URL

Changes

No recorded changes to this operation across all 1 revision of this API.