Volumes /
Attach volume
Attach a volume
Required permission
Project > Volumes > General > Update
Path parameters
projectId
string requiredID of the projectvolumeId
string requiredID of the volume
Request body
- {object}
owningObject
{object}DEPRECATED: The object to attach this volume to.id
string requiredThe id of object to attach this volume to.pattern^[A-Za-z0-9-]+$type
string requiredThe type of the object to attach this volume to.one ofservicenfObject
{object}The object to attach this volume to.id
string requiredThe id of object to attach this volume to.pattern^[A-Za-z0-9-]+$type
string requiredThe type of the object to attach this volume to.one ofservice
Response body
- {object}Response object.
data
{object} requiredResult data.
API
CLI
JS Client
POST /v1/projects/{projectId}/volumes/{volumeId}/attach
Example request
Request body
curl
curl --header "Content-Type: application/json" \
--header "Authorization: Bearer NORTHFLANK_API_TOKEN" \
--request POST \
--data '{"nfObject":{"id":"example-service","type":"service"}}' \
https://api.northflank.com/v1/projects/{projectId}/volumes/{volumeId}/attach
Example response
200 OK
The operation was performed successfully.
JSON
{
"data": {}
}