cURL
curl --request POST \ --url https://cloud.laravel.com/api/buckets/{filesystem}/keys \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data ' { "name": "<string>", "permission": "read_write" } '
{ "data": { "id": "<string>", "type": "filesystemKeys", "attributes": { "name": "<string>", "permission": "read_write", "access_key_id": "<string>", "access_key_secret": "<string>", "created_at": "2023-11-07T05:31:56Z" }, "relationships": { "filesystem": { "data": { "type": "filesystems", "id": "<string>" } } } }, "included": [ { "id": "<string>", "type": "filesystems", "attributes": { "name": "<string>", "type": "cloudflare_r2", "status": "creating", "visibility": "private", "jurisdiction": "default", "endpoint": "<string>", "url": "<string>", "allowed_origins": [ "<unknown>" ], "created_at": "2023-11-07T05:31:56Z" }, "relationships": { "keys": { "data": [ { "type": "filesystemKeys", "id": "<string>" } ] } } } ] }
Create a new key for an object storage bucket.
The Bearer Token generated on the Cloud UI.
The filesystem identifier
3 - 40
read_write
read_only
FilesystemKeyResource
Show child attributes
Was this page helpful?