🚀 You can now run code directly on your disks with serverless execution!
Creates a new disk with the specified configuration. A default disk
token user is automatically generated and returned in the response,
so the disk is immediately mountable. The one-time disk token appears
in authorizedUsers[].token and cannot be retrieved again. (This
disk token is scoped to the new disk and is separate from the API
key you used to make this request.)
To provide your own users instead, pass the deprecated authMethods
field or call AddDiskUser after creation.
curl --request POST \
--url https://control.green.us-east-1.aws.prod.archil.com/api/disks \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "my-data-disk",
"mounts": [
{
"bucketName": "my-bucket",
"accessKeyId": "<string>",
"secretAccessKey": "<string>",
"sessionToken": "<string>",
"bucketPrefix": "data/"
}
],
"authMethods": [
{
"nickname": "<string>",
"principal": "<string>",
"tokenSuffix": "<string>"
}
]
}
'{
"success": true,
"data": {
"diskId": "dsk-0123456789abcdef",
"authorizedUsers": [
{
"principal": "<string>",
"nickname": "<string>",
"tokenSuffix": "<string>",
"token": "<string>",
"identifier": "<string>",
"createdAt": "2023-11-07T05:31:56Z"
}
]
}
}Documentation Index
Fetch the complete documentation index at: https://docs.archil.com/llms.txt
Use this file to discover all available pages before exploring further.
API key (format key-{API_KEY})
Disk name (alphanumeric, dashes, underscores)
1 - 100^[a-zA-Z0-9_-]+$"my-data-disk"
Storage mount to attach. Omit for archil-managed storage.
1Mount configuration for Amazon S3 buckets
Show child attributes
Deprecated. Use AddDiskUser after creation instead. When provided, suppresses the default auto-generated token user.
Show child attributes
Was this page helpful?
curl --request POST \
--url https://control.green.us-east-1.aws.prod.archil.com/api/disks \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "my-data-disk",
"mounts": [
{
"bucketName": "my-bucket",
"accessKeyId": "<string>",
"secretAccessKey": "<string>",
"sessionToken": "<string>",
"bucketPrefix": "data/"
}
],
"authMethods": [
{
"nickname": "<string>",
"principal": "<string>",
"tokenSuffix": "<string>"
}
]
}
'{
"success": true,
"data": {
"diskId": "dsk-0123456789abcdef",
"authorizedUsers": [
{
"principal": "<string>",
"nickname": "<string>",
"tokenSuffix": "<string>",
"token": "<string>",
"identifier": "<string>",
"createdAt": "2023-11-07T05:31:56Z"
}
]
}
}