Models Hub
User GuideUser Console

Bring Your Own Storage: keep results forever

Configure your own Aliyun OSS or Cloudflare R2 bucket so generated video/image results are transferred automatically and links never expire.

Edit this page

Why bring your own storage

Video and image generation results are stored in the upstream provider's temporary storage by default, with a limited retention period (typically 24–48 hours). After that, the links return errors and the files can no longer be downloaded.

Once you configure your own bucket under Profile → Storage Settings:

  • When a video / image task succeeds, the platform automatically transfers the result file to your own bucket;
  • The task's result_url points directly to your storage and never expires;
  • The data belongs to you — serve it via CDN, back it up, or manage its lifecycle however you like.

The transfer runs entirely on the server side. If a transfer ever fails, the platform default link is used as a fallback, so you never lose access to a result.

Supported providers

ProviderNotes
Aliyun OSSRecommended for users in China; supports transfer-acceleration endpoints
Cloudflare R2S3-compatible, zero egress fees; recommended for international users

Setup: Aliyun OSS

  1. Create a bucket (or reuse an existing one) in the Aliyun OSS console.
  2. We recommend creating a dedicated RAM sub-user in the RAM console, generating an AccessKey for it, and granting it read/write access to this bucket only. Minimal policy example:
{
  "Version": "1",
  "Statement": [
    {
      "Effect": "Allow",
      "Action": ["oss:PutObject", "oss:GetObject"],
      "Resource": ["acs:oss:*:*:your-bucket-name/*"]
    }
  ]
}
  1. Go to Profile → Storage Settings, enable the switch, choose "Aliyun OSS", and fill in:
FieldValue
OSS EndpointThe endpoint of your bucket's region, e.g. https://oss-cn-hangzhou.aliyuncs.com
OSS BucketBucket name
Transfer Acceleration Endpoint (optional)e.g. https://oss-accelerate.aliyuncs.com, faster for cross-border uploads
AccessKey ID / SecretThe sub-user credentials from step 2
Object Prefix (optional)A directory prefix for all stored files, e.g. ai-results
Public Base URL (optional, recommended)The CDN / custom domain bound to the bucket, e.g. https://cdn.example.com
  1. Click Test Upload: the platform writes a test.txt to your bucket and returns its URL. If you can open the link and see the content, the configuration works.
  2. Click Save Settings.

Setup: Cloudflare R2

  1. Create a bucket under R2 in the Cloudflare dashboard.
  2. Create an R2 API token (R2 → Manage R2 API Tokens) with "Object Read & Write" permission, scoped to this bucket. Note the Access Key ID and Secret Access Key.
  3. Go to Profile → Storage Settings, enable the switch, choose "Cloudflare R2", and fill in:
FieldValue
R2 Endpointhttps://<account-id>.r2.cloudflarestorage.com (copy it from the R2 overview page)
R2 BucketBucket name
AccessKey ID / SecretThe API token credentials from step 2
Object Prefix (optional)A directory prefix for all stored files
Public Base URL (strongly recommended)A public custom domain bound to the bucket, e.g. https://media.example.com
  1. Click Test Upload to verify, then Save Settings.

⚠️ R2 note: without a Public Base URL, the platform can only generate signed links valid for at most 7 days (the S3 presign protocol limit). To get permanent links, bind a public custom domain to your R2 bucket. Aliyun OSS has no such limit (without a public domain, signed OSS links default to 10-year validity).

What happens once enabled

  • Video tasks: on success the result is transferred to [prefix/]task-results/<date>/<taskID>.mp4, and the result_url returned by task queries points to your bucket.
  • Image generation: transferred images are stored under [prefix/]relay-temp-images/<date>/.
  • If a transfer fails (e.g. revoked key, non-writable bucket), the platform default link is used automatically and the task result is unaffected. Re-run Test Upload periodically to confirm the configuration still works.

Security

  • Your AccessKey Secret is stored encrypted on the server and is never echoed back by any API; when editing, leaving the field empty keeps the existing secret.
  • All uploads happen server-side — credentials are never sent to the browser or any client.
  • Use least-privilege sub-account credentials (read/write on the target bucket only) and rotate them regularly.

FAQ

Test Upload fails — what should I check? In order: the endpoint region matches the bucket, the bucket name spelling, the AccessKey has write permission (PutObject) on the bucket, and the key hasn't expired or been disabled. The error message includes the storage provider's specific reason.

Why does the returned link contain long signature parameters? Without a Public Base URL, the bucket is treated as private-read and the platform generates signed links. Configure a Public Base URL (public-read bucket or CDN domain) to get clean permanent links.

Will links of historical tasks change after enabling? No. Transfers only apply to tasks completed after enabling; historical tasks keep their original links.

Can I transfer only videos but not images? Not currently — it is a single switch; once enabled, both video and image results are transferred to your bucket.

On this page