All URIs are relative to https://api.machines.dev/v1
Method | HTTP request | Description |
---|---|---|
CreateVolumeSnapshot | Post /apps/{app_name}/volumes/{volume_id}/snapshots | Create Snapshot |
VolumeDelete | Delete /apps/{app_name}/volumes/{volume_id} | Destroy Volume |
VolumesCreate | Post /apps/{app_name}/volumes | Create Volume |
VolumesExtend | Put /apps/{app_name}/volumes/{volume_id}/extend | Extend Volume |
VolumesGetById | Get /apps/{app_name}/volumes/{volume_id} | Get Volume |
VolumesList | Get /apps/{app_name}/volumes | List Volumes |
VolumesListSnapshots | Get /apps/{app_name}/volumes/{volume_id}/snapshots | List Snapshots |
VolumesUpdate | Put /apps/{app_name}/volumes/{volume_id} | Update Volume |
CreateVolumeSnapshot(ctx, appName, volumeId).Execute()
Create Snapshot
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/OutboundSpade/FlyMachines"
)
func main() {
appName := "appName_example" // string | Fly App Name
volumeId := "volumeId_example" // string | Volume ID
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.VolumesAPI.CreateVolumeSnapshot(context.Background(), appName, volumeId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `VolumesAPI.CreateVolumeSnapshot``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
appName | string | Fly App Name | |
volumeId | string | Volume ID |
Other parameters are passed through a pointer to a apiCreateVolumeSnapshotRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
(empty response body)
No authorization required
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Volume VolumeDelete(ctx, appName, volumeId).Execute()
Destroy Volume
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/OutboundSpade/FlyMachines"
)
func main() {
appName := "appName_example" // string | Fly App Name
volumeId := "volumeId_example" // string | Volume ID
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.VolumesAPI.VolumeDelete(context.Background(), appName, volumeId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `VolumesAPI.VolumeDelete``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `VolumeDelete`: Volume
fmt.Fprintf(os.Stdout, "Response from `VolumesAPI.VolumeDelete`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
appName | string | Fly App Name | |
volumeId | string | Volume ID |
Other parameters are passed through a pointer to a apiVolumeDeleteRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
No authorization required
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Volume VolumesCreate(ctx, appName).Request(request).Execute()
Create Volume
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/OutboundSpade/FlyMachines"
)
func main() {
appName := "appName_example" // string | Fly App Name
request := *openapiclient.NewCreateVolumeRequest() // CreateVolumeRequest | Request body
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.VolumesAPI.VolumesCreate(context.Background(), appName).Request(request).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `VolumesAPI.VolumesCreate``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `VolumesCreate`: Volume
fmt.Fprintf(os.Stdout, "Response from `VolumesAPI.VolumesCreate`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
appName | string | Fly App Name |
Other parameters are passed through a pointer to a apiVolumesCreateRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
request | CreateVolumeRequest | Request body |
No authorization required
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ExtendVolumeResponse VolumesExtend(ctx, appName, volumeId).Request(request).Execute()
Extend Volume
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/OutboundSpade/FlyMachines"
)
func main() {
appName := "appName_example" // string | Fly App Name
volumeId := "volumeId_example" // string | Volume ID
request := *openapiclient.NewExtendVolumeRequest() // ExtendVolumeRequest | Request body
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.VolumesAPI.VolumesExtend(context.Background(), appName, volumeId).Request(request).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `VolumesAPI.VolumesExtend``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `VolumesExtend`: ExtendVolumeResponse
fmt.Fprintf(os.Stdout, "Response from `VolumesAPI.VolumesExtend`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
appName | string | Fly App Name | |
volumeId | string | Volume ID |
Other parameters are passed through a pointer to a apiVolumesExtendRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
request | ExtendVolumeRequest | Request body |
No authorization required
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Volume VolumesGetById(ctx, appName, volumeId).Execute()
Get Volume
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/OutboundSpade/FlyMachines"
)
func main() {
appName := "appName_example" // string | Fly App Name
volumeId := "volumeId_example" // string | Volume ID
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.VolumesAPI.VolumesGetById(context.Background(), appName, volumeId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `VolumesAPI.VolumesGetById``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `VolumesGetById`: Volume
fmt.Fprintf(os.Stdout, "Response from `VolumesAPI.VolumesGetById`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
appName | string | Fly App Name | |
volumeId | string | Volume ID |
Other parameters are passed through a pointer to a apiVolumesGetByIdRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
No authorization required
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
[]Volume VolumesList(ctx, appName).Summary(summary).Execute()
List Volumes
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/OutboundSpade/FlyMachines"
)
func main() {
appName := "appName_example" // string | Fly App Name
summary := true // bool | Only return summary info about volumes (omit blocks, block size, etc) (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.VolumesAPI.VolumesList(context.Background(), appName).Summary(summary).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `VolumesAPI.VolumesList``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `VolumesList`: []Volume
fmt.Fprintf(os.Stdout, "Response from `VolumesAPI.VolumesList`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
appName | string | Fly App Name |
Other parameters are passed through a pointer to a apiVolumesListRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
summary | bool | Only return summary info about volumes (omit blocks, block size, etc) |
No authorization required
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
[]VolumeSnapshot VolumesListSnapshots(ctx, appName, volumeId).Execute()
List Snapshots
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/OutboundSpade/FlyMachines"
)
func main() {
appName := "appName_example" // string | Fly App Name
volumeId := "volumeId_example" // string | Volume ID
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.VolumesAPI.VolumesListSnapshots(context.Background(), appName, volumeId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `VolumesAPI.VolumesListSnapshots``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `VolumesListSnapshots`: []VolumeSnapshot
fmt.Fprintf(os.Stdout, "Response from `VolumesAPI.VolumesListSnapshots`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
appName | string | Fly App Name | |
volumeId | string | Volume ID |
Other parameters are passed through a pointer to a apiVolumesListSnapshotsRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
No authorization required
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Volume VolumesUpdate(ctx, appName, volumeId).Request(request).Execute()
Update Volume
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/OutboundSpade/FlyMachines"
)
func main() {
appName := "appName_example" // string | Fly App Name
volumeId := "volumeId_example" // string | Volume ID
request := *openapiclient.NewUpdateVolumeRequest() // UpdateVolumeRequest | Request body
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.VolumesAPI.VolumesUpdate(context.Background(), appName, volumeId).Request(request).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `VolumesAPI.VolumesUpdate``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `VolumesUpdate`: Volume
fmt.Fprintf(os.Stdout, "Response from `VolumesAPI.VolumesUpdate`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
appName | string | Fly App Name | |
volumeId | string | Volume ID |
Other parameters are passed through a pointer to a apiVolumesUpdateRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
request | UpdateVolumeRequest | Request body |
No authorization required
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]