backupclientv2

package
v0.2.106 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 8, 2025 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	CreateProjectBackupExport(
		ctx context.Context,
		req CreateProjectBackupExportRequest,
		reqEditors ...func(req *http.Request) error,
	) (*http.Response, error)
	DeleteProjectBackupExport(
		ctx context.Context,
		req DeleteProjectBackupExportRequest,
		reqEditors ...func(req *http.Request) error,
	) (*http.Response, error)
	ListProjectBackupSchedules(
		ctx context.Context,
		req ListProjectBackupSchedulesRequest,
		reqEditors ...func(req *http.Request) error,
	) (*[]backupv2.ProjectBackupSchedule, *http.Response, error)
	CreateProjectBackupSchedule(
		ctx context.Context,
		req CreateProjectBackupScheduleRequest,
		reqEditors ...func(req *http.Request) error,
	) (*backupv2.ProjectBackupSchedule, *http.Response, error)
	ListProjectBackups(
		ctx context.Context,
		req ListProjectBackupsRequest,
		reqEditors ...func(req *http.Request) error,
	) (*[]backupv2.ProjectBackup, *http.Response, error)
	CreateProjectBackup(
		ctx context.Context,
		req CreateProjectBackupRequest,
		reqEditors ...func(req *http.Request) error,
	) (*backupv2.ProjectBackup, *http.Response, error)
	GetProjectBackupSchedule(
		ctx context.Context,
		req GetProjectBackupScheduleRequest,
		reqEditors ...func(req *http.Request) error,
	) (*backupv2.ProjectBackupSchedule, *http.Response, error)
	DeleteProjectBackupSchedule(
		ctx context.Context,
		req DeleteProjectBackupScheduleRequest,
		reqEditors ...func(req *http.Request) error,
	) (*http.Response, error)
	UpdateProjectBackupSchedule(
		ctx context.Context,
		req UpdateProjectBackupScheduleRequest,
		reqEditors ...func(req *http.Request) error,
	) (*http.Response, error)
	GetProjectBackup(
		ctx context.Context,
		req GetProjectBackupRequest,
		reqEditors ...func(req *http.Request) error,
	) (*backupv2.ProjectBackup, *http.Response, error)
	DeleteProjectBackup(
		ctx context.Context,
		req DeleteProjectBackupRequest,
		reqEditors ...func(req *http.Request) error,
	) (*http.Response, error)
	UpdateProjectBackupDescription(
		ctx context.Context,
		req UpdateProjectBackupDescriptionRequest,
		reqEditors ...func(req *http.Request) error,
	) (*http.Response, error)
}

func NewClient

func NewClient(client httpclient.RequestRunner) Client

type CreateProjectBackupExportRequest

type CreateProjectBackupExportRequest struct {
	Body            CreateProjectBackupExportRequestBody
	ProjectBackupID string
}

CreateProjectBackupExportRequest models a request for the 'backup-create-project-backup-export' operation. See [1] for more information.

Export a ProjectBackup for download.

[1]: https://developer.mittwald.de/docs/v2/reference/backup/backup-create-project-backup-export

func (*CreateProjectBackupExportRequest) BuildRequest

func (r *CreateProjectBackupExportRequest) BuildRequest(reqEditors ...func(req *http.Request) error) (*http.Request, error)

BuildRequest builds an *http.Request instance from this request that may be used with any regular *http.Client instance.

type CreateProjectBackupExportRequestBody

type CreateProjectBackupExportRequestBody struct {
	Format   CreateProjectBackupExportRequestBodyFormat `json:"format"`
	Password *string                                    `json:"password,omitempty"`
}

CreateProjectBackupExportRequestBody models the JSON body of a 'backup-create-project-backup-export' request

func (*CreateProjectBackupExportRequestBody) Validate

type CreateProjectBackupExportRequestBodyFormat

type CreateProjectBackupExportRequestBodyFormat string

The desired format to export the ProjectBackup in.

const CreateProjectBackupExportRequestBodyFormatTar CreateProjectBackupExportRequestBodyFormat = "tar"
const CreateProjectBackupExportRequestBodyFormatZip CreateProjectBackupExportRequestBodyFormat = "zip"

func (CreateProjectBackupExportRequestBodyFormat) Validate

type CreateProjectBackupRequest

type CreateProjectBackupRequest struct {
	Body      CreateProjectBackupRequestBody
	ProjectID string
}

CreateProjectBackupRequest models a request for the 'backup-create-project-backup' operation. See [1] for more information.

Create a Backup of a Project.

[1]: https://developer.mittwald.de/docs/v2/reference/backup/backup-create-project-backup

func (*CreateProjectBackupRequest) BuildRequest

func (r *CreateProjectBackupRequest) BuildRequest(reqEditors ...func(req *http.Request) error) (*http.Request, error)

BuildRequest builds an *http.Request instance from this request that may be used with any regular *http.Client instance.

type CreateProjectBackupRequestBody

type CreateProjectBackupRequestBody struct {
	Description    *string   `json:"description,omitempty"`
	ExpirationTime time.Time `json:"expirationTime"`
}

CreateProjectBackupRequestBody models the JSON body of a 'backup-create-project-backup' request

func (*CreateProjectBackupRequestBody) Validate

func (o *CreateProjectBackupRequestBody) Validate() error

type CreateProjectBackupScheduleRequest

type CreateProjectBackupScheduleRequest struct {
	Body      CreateProjectBackupScheduleRequestBody
	ProjectID string
}

CreateProjectBackupScheduleRequest models a request for the 'backup-create-project-backup-schedule' operation. See [1] for more information.

Create a BackupSchedule for a Project.

[1]: https://developer.mittwald.de/docs/v2/reference/backup/backup-create-project-backup-schedule

func (*CreateProjectBackupScheduleRequest) BuildRequest

func (r *CreateProjectBackupScheduleRequest) BuildRequest(reqEditors ...func(req *http.Request) error) (*http.Request, error)

BuildRequest builds an *http.Request instance from this request that may be used with any regular *http.Client instance.

type CreateProjectBackupScheduleRequestBody

type CreateProjectBackupScheduleRequestBody struct {
	Description *string `json:"description,omitempty"`
	Schedule    string  `json:"schedule"`
	Ttl         string  `json:"ttl"`
}

CreateProjectBackupScheduleRequestBody models the JSON body of a 'backup-create-project-backup-schedule' request

func (*CreateProjectBackupScheduleRequestBody) Validate

type DeleteProjectBackupExportRequest

type DeleteProjectBackupExportRequest struct {
	ProjectBackupID string
}

DeleteProjectBackupExportRequest models a request for the 'backup-delete-project-backup-export' operation. See [1] for more information.

Delete a ProjectBackupExport.

[1]: https://developer.mittwald.de/docs/v2/reference/backup/backup-delete-project-backup-export

func (*DeleteProjectBackupExportRequest) BuildRequest

func (r *DeleteProjectBackupExportRequest) BuildRequest(reqEditors ...func(req *http.Request) error) (*http.Request, error)

BuildRequest builds an *http.Request instance from this request that may be used with any regular *http.Client instance.

type DeleteProjectBackupRequest

type DeleteProjectBackupRequest struct {
	ProjectBackupID string
}

DeleteProjectBackupRequest models a request for the 'backup-delete-project-backup' operation. See [1] for more information.

Delete a ProjectBackup.

[1]: https://developer.mittwald.de/docs/v2/reference/backup/backup-delete-project-backup

func (*DeleteProjectBackupRequest) BuildRequest

func (r *DeleteProjectBackupRequest) BuildRequest(reqEditors ...func(req *http.Request) error) (*http.Request, error)

BuildRequest builds an *http.Request instance from this request that may be used with any regular *http.Client instance.

type DeleteProjectBackupScheduleRequest

type DeleteProjectBackupScheduleRequest struct {
	ProjectBackupScheduleID string
}

DeleteProjectBackupScheduleRequest models a request for the 'backup-delete-project-backup-schedule' operation. See [1] for more information.

Delete a ProjectBackupSchedule.

[1]: https://developer.mittwald.de/docs/v2/reference/backup/backup-delete-project-backup-schedule

func (*DeleteProjectBackupScheduleRequest) BuildRequest

func (r *DeleteProjectBackupScheduleRequest) BuildRequest(reqEditors ...func(req *http.Request) error) (*http.Request, error)

BuildRequest builds an *http.Request instance from this request that may be used with any regular *http.Client instance.

type GetProjectBackupRequest

type GetProjectBackupRequest struct {
	ProjectBackupID string
}

GetProjectBackupRequest models a request for the 'backup-get-project-backup' operation. See [1] for more information.

Get a ProjectBackup.

[1]: https://developer.mittwald.de/docs/v2/reference/backup/backup-get-project-backup

func (*GetProjectBackupRequest) BuildRequest

func (r *GetProjectBackupRequest) BuildRequest(reqEditors ...func(req *http.Request) error) (*http.Request, error)

BuildRequest builds an *http.Request instance from this request that may be used with any regular *http.Client instance.

type GetProjectBackupScheduleRequest

type GetProjectBackupScheduleRequest struct {
	ProjectBackupScheduleID string
}

GetProjectBackupScheduleRequest models a request for the 'backup-get-project-backup-schedule' operation. See [1] for more information.

Get a ProjectBackupSchedule.

[1]: https://developer.mittwald.de/docs/v2/reference/backup/backup-get-project-backup-schedule

func (*GetProjectBackupScheduleRequest) BuildRequest

func (r *GetProjectBackupScheduleRequest) BuildRequest(reqEditors ...func(req *http.Request) error) (*http.Request, error)

BuildRequest builds an *http.Request instance from this request that may be used with any regular *http.Client instance.

type ListProjectBackupSchedulesRequest

type ListProjectBackupSchedulesRequest struct {
	ProjectID string
}

ListProjectBackupSchedulesRequest models a request for the 'backup-list-project-backup-schedules' operation. See [1] for more information.

List BackupSchedules belonging to a Project.

[1]: https://developer.mittwald.de/docs/v2/reference/backup/backup-list-project-backup-schedules

func (*ListProjectBackupSchedulesRequest) BuildRequest

func (r *ListProjectBackupSchedulesRequest) BuildRequest(reqEditors ...func(req *http.Request) error) (*http.Request, error)

BuildRequest builds an *http.Request instance from this request that may be used with any regular *http.Client instance.

type ListProjectBackupsRequest

type ListProjectBackupsRequest struct {
	ProjectID       string
	SearchTerm      *string
	WithExportsOnly *bool
	SortOrder       *backupv2.BackupSortOrder
	Limit           *int64
	Skip            *int64
	Page            *int64
}

ListProjectBackupsRequest models a request for the 'backup-list-project-backups' operation. See [1] for more information.

List Backups belonging to a Project.

[1]: https://developer.mittwald.de/docs/v2/reference/backup/backup-list-project-backups

func (*ListProjectBackupsRequest) BuildRequest

func (r *ListProjectBackupsRequest) BuildRequest(reqEditors ...func(req *http.Request) error) (*http.Request, error)

BuildRequest builds an *http.Request instance from this request that may be used with any regular *http.Client instance.

type UpdateProjectBackupDescriptionRequest

type UpdateProjectBackupDescriptionRequest struct {
	Body            UpdateProjectBackupDescriptionRequestBody
	ProjectBackupID string
}

UpdateProjectBackupDescriptionRequest models a request for the 'backup-update-project-backup-description' operation. See [1] for more information.

Change the description of a ProjectBackup.

[1]: https://developer.mittwald.de/docs/v2/reference/backup/backup-update-project-backup-description

func (*UpdateProjectBackupDescriptionRequest) BuildRequest

func (r *UpdateProjectBackupDescriptionRequest) BuildRequest(reqEditors ...func(req *http.Request) error) (*http.Request, error)

BuildRequest builds an *http.Request instance from this request that may be used with any regular *http.Client instance.

type UpdateProjectBackupDescriptionRequestBody

type UpdateProjectBackupDescriptionRequestBody struct {
	Description *string `json:"description,omitempty"`
}

UpdateProjectBackupDescriptionRequestBody models the JSON body of a 'backup-update-project-backup-description' request

func (*UpdateProjectBackupDescriptionRequestBody) Validate

type UpdateProjectBackupScheduleRequest

type UpdateProjectBackupScheduleRequest struct {
	Body                    UpdateProjectBackupScheduleRequestBody
	ProjectBackupScheduleID string
}

UpdateProjectBackupScheduleRequest models a request for the 'backup-update-project-backup-schedule' operation. See [1] for more information.

Update a ProjectBackupSchedule.

[1]: https://developer.mittwald.de/docs/v2/reference/backup/backup-update-project-backup-schedule

func (*UpdateProjectBackupScheduleRequest) BuildRequest

func (r *UpdateProjectBackupScheduleRequest) BuildRequest(reqEditors ...func(req *http.Request) error) (*http.Request, error)

BuildRequest builds an *http.Request instance from this request that may be used with any regular *http.Client instance.

type UpdateProjectBackupScheduleRequestBody

type UpdateProjectBackupScheduleRequestBody struct {
	Description *string `json:"description,omitempty"`
	Schedule    *string `json:"schedule,omitempty"`
	Ttl         *string `json:"ttl,omitempty"`
}

UpdateProjectBackupScheduleRequestBody models the JSON body of a 'backup-update-project-backup-schedule' request

func (*UpdateProjectBackupScheduleRequestBody) Validate

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL