Storages
A storage is a location attached to a converter. The service reads input media files from it. The service writes results to it.
Endpoints
| Method | Path | Description | Scope |
|---|---|---|---|
GET |
/converters/{converter}/storages |
List paginated storages | storages:read |
POST |
/converters/{converter}/storages |
Create a storage | storages:write |
GET |
/storages/{storage} |
Get a storage | storages:read |
PUT/PATCH |
/storages/{storage} |
Update a storage | storages:write |
DELETE |
/storages/{storage} |
Delete a storage | storages:write |
DELETE |
/converters/{converter}/storages |
Delete several storages at once | storages:write |
Storage types
| Type | Settings | Description |
|---|---|---|
s3 |
url, region, access_key, secret_key, bucket (optional) |
S3-compatible: Object Storage |
swift |
auth_url, username, password, tenant (optional), region (optional), domain (optional), auth_version (optional, v2/v3), bucket (optional) |
OpenStack Swift: Object Storage Legacy |
ftp |
host, username, password |
FTP server |
sftp |
host, username, and password or passkey (exclusive) |
SFTP server |
kdrive |
drive_id, token (optional), fullpath (optional), common (optional) |
kDrive |
vod |
vod_id, token (optional) |
Infomaniak VOD |
Secrets (secret_key, password, passkey, token) are stored encrypted.
They are never returned in responses.
Tokens for kDrive and VOD storages
For kdrive and vod storages, the token is optional. When the
conversion task runs, the service derives a short-lived access token from
the OAuth token that launched the workflow. It uses this token to reach the
kDrive or VOD resource.
If no token is attached to the storage, the launch token must have access to the kDrive or VOD. Otherwise the task cannot read from or write to it. A stored token acts as a fallback when the derivation fails.
Example: S3
curl -s -X POST "https://api.infomaniak.com/1/public_clouds/media_conversion/converters/<converter-id>/storages" \
-H "Authorization: Bearer $MC_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "my-bucket",
"type": "s3",
"settings": {
"url": "s3.gva2.infomaniak.cloud",
"region": "<region>",
"access_key": "<your-access-key>",
"secret_key": "<your-secret-key>",
"bucket": "my-bucket"
}
}'
{
"result": "success",
"data": {
"id": "e1f2a3b4-5d6c-7e89-a0b1-2c3d4e5f6a7b",
"type": "s3",
"name": "my-bucket",
"managed": true,
"settings": { ... }
}
}
Testing a storage
A storage can be validated before and after creation:
| Method | Path | Description | Scope |
|---|---|---|---|
POST |
/converters/{converter}/storages/test |
Test settings before creating the storage | storages:write |
POST |
/storages/{storage}/test |
Test an existing storage's connectivity | storages:write |
GET |
/storages/{storage}/browse |
Browse the files available in a storage | storages:read |
curl -s -X POST "https://api.infomaniak.com/1/public_clouds/media_conversion/storages/<storage-id>/test" \
-H "Authorization: Bearer $MC_TOKEN"
{
"result": "success",
"data": true
}
The browse endpoint lists the files of a storage. Pick inputs by path without leaving the API:
curl -s "https://api.infomaniak.com/1/public_clouds/media_conversion/storages/<storage-id>/browse?path=/" \
-H "Authorization: Bearer $MC_TOKEN"
Referencing files
Workflow payloads reference inputs and outputs with URI-style paths. The
service resolves them against the converter's storages. An example is
s3://my-bucket/videos/source.mov for an S3 storage.