Cloud Storage
CloudBase Cloud Storage provides stable, secure, low-cost, and easy-to-use cloud storage services, supporting any quantity and form of unstructured data storage — images, documents, audio, video, files, etc. It is backed by Tencent Cloud COS (Object Storage) and integrates CDN acceleration, Cloud Infinite (CI), content moderation, and more.
Two cloud storage modes
Cloud storage comes in two flavors: classic and PG, determined by your environment type.
| Dimension | Classic cloud storage | PG cloud storage |
|---|---|---|
| Applicable environment | Classic environments (default) | PG environments |
| Bucket concept | Tightly bound to the environment, mainly a path prefix | A row in storage.buckets; per-bucket SQL-level configuration |
| Permission model | Built-in modes (READONLY / PRIVATE, ...) + JSON security rules | PostgreSQL RLS policies (SQL) |
| Upload path | Client SDK gets a signature and uploads directly to COS | Client → Storage API → COS; metadata and object coordinated in one transaction |
| Metadata | Backfilled by the application | Written automatically by Storage API into storage.objects, queryable via SQL |
| How it is selected | Default when creating an environment | Choose PostgreSQL when creating an environment |
- Classic mode: most pages in this section (Console / SDK / Permissions / HTTP API)
- PG mode: PG Cloud Storage + its HTTP API
- CDN / content moderation / image processing / CI: shared by both modes, see the "Advanced" and "Cloud Infinite" groups in this section
The rest of this page focuses on classic mode. If you are using a PG environment, jump directly to PG Cloud Storage.
Management methods
CloudBase cloud storage provides multiple management methods. Pick the one that fits your scenario:
| Method | Features | Use cases | Strengths |
|---|---|---|---|
| Console | Visual UI for permissions and cache settings | Day-to-day management | Easy to pick up, visual |
| SDK | Integrated into applications | App integration | Highly flexible and customizable |
| CLI | Command-line, batch friendly | Automation / batch | Efficient batch ops; good for CI/CD |
| cosBrowser | Visual UI with batch | Frequent file management | Combines visual UX with batch efficiency |
| HTTP API | Standard RESTful API | Server-side / cross-language | Cross-language, callable from any backend |
For example: SDK during development, CLI during Ops, console or cosBrowser for daily admin, HTTP API for cross-language backend integrations.
Main features
CDN acceleration by default
Cloud storage supports CDN acceleration out of the box, with a free CDN domain. CDN delivers content from the node closest to the user, reducing latency.
Authentication integration
CloudBase cloud storage seamlessly integrates with CloudBase auth. You can use user identity together with security rules to control access — e.g. files only readable by signed-in users, or restricted to WeChat-authenticated users.
Under PG mode, authentication and permissions are jointly handled by PostgreSQL's auth schema and RLS policies. See PG Cloud Storage — Permission management.
High extensibility
CloudBase cloud storage works well with other CloudBase services:
- Store a file's fileID in the database
- Combine with CloudBase extensions: image moderation, processing, tagging, blind watermarking, etc.
HTTP API
Cloud storage exposes complete RESTful HTTP APIs, callable from any backend language:
- Classic-mode HTTP API: object upload / download / delete / copy, etc.
- Postgres-Native HTTP API: full bucket / object CRUD, signed URLs, object metadata, multipart upload, gated by RLS.