godo.Snapshots.Get()
Generated on 5 Nov 2026
from godo version
v1.236.0
Usage
client.Snapshots.Get(ctx context.Context, snapshotID string) (*godo.Snapshot, *godo.Response, error)Description
Get retrieves a snapshot by id.
This method sends a GET request to /v2/snapshots/{}.
Parameters
snapshotIDstring required
Returns
- *godo.Snapshot
- *godo.Response
The HTTP response, with pagination
Links,Meta, andRatelimit information.- error
Non-nil when the request fails. API errors are returned as
*godo.ErrorResponse.
Fields of godo.Snapshot
Snapshot represents a DigitalOcean Snapshot
IDstringNamestringResourceIDstringResourceTypestringRegions[]stringMinDiskSizeintSizeGigaBytesfloat64CreatedstringTags[]string
Request Sample
More Information
See GET /v2/snapshots/{} in the API reference for additional detail on responses, headers, parameters, and more.
See the Go package documentation for the source of this method.