pydo.nfs.create_action()
Generated on 7 Jul 2026
from pydo version
v0.39.0
Usage
client.nfs.create_action(
nfs_id="0a1b2c3d-4e5f-6a7b-8c9d-0e1f2a3b4c5d",
body={
"type": "resize",
"region": "atl1",
"params": {...},
},
)Description
To execute an action (such as resize) on a specified NFS share,
send a POST request to /v2/nfs/{nfs_id}/actions. In the JSON body
to the request, set the type attribute to on of the supported action types:
| Action | Details |
|---|---|
resize |
Resizes an NFS share. Set the size_gib attribute to a desired value in GiB |
snapshot |
Takes a snapshot of an NFS share |
attach |
Attaches an NFS share to a VPC. Set the vpc_id attribute to the desired VPC ID |
detach |
Detaches an NFS share from a VPC. Set the vpc_id attribute to the desired VPC ID |
reassign |
Reassigns an NFS share from one VPC to another. Set the old_vpc_id and new_vpc_id attributes to the desired VPC IDs |
switch_performance_tier |
Switches the performance tier of an NFS share. Set the performance_tier attribute to the desired tier (e.g., standard, high) |
Parameters
nfs_idstring requiredThe unique ID of the NFS share
typestring requiredThe type of action to initiate for the NFS share (such as resize or snapshot).
regionstring optionalExample:
atl1The DigitalOcean region slug (e.g. atl1, nyc2) where the NFS snapshot resides.
paramsobject optionalShow child properties
performance_tierstring requiredExample:
standardThe performance tier to which the NFS share will be switched (e.g., standard, high).
Request Sample
Response Example
More Information
See /v2/nfs/{nfs_id}/actions in the API reference for additional detail on responses, headers, parameters, and more.