# Backup (*backup*) ## Overview ### Available Operations * [create](#create) * [get](#get) * [update](#update) * [remove](#remove) * [manualBackupPostgres](#manualbackuppostgres) * [manualBackupMysql](#manualbackupmysql) * [manualBackupMariadb](#manualbackupmariadb) * [manualBackupMongo](#manualbackupmongo) ## create ### Example Usage ```typescript import { Dokploy } from "dokploy"; const dokploy = new Dokploy({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const result = await dokploy.backup.create({ schedule: "", prefix: "", destinationId: "", database: "", databaseType: "mysql", }); console.log(result); } run(); ``` ### Standalone function The standalone function version of this method: ```typescript import { DokployCore } from "dokploy/core.js"; import { backupCreate } from "dokploy/funcs/backupCreate.js"; // Use `DokployCore` for best tree-shaking performance. // You can create one instance of it to use across an application. const dokploy = new DokployCore({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const res = await backupCreate(dokploy, { schedule: "", prefix: "", destinationId: "", database: "", databaseType: "mysql", }); if (res.ok) { const { value: result } = res; console.log(result); } else { console.log("backupCreate failed:", res.error); } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | | `request` | [operations.BackupCreateRequest](../../models/operations/backupcreaterequest.md) | :heavy_check_mark: | The request object to use for the request. | | `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. | | `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. | | `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. | ### Response **Promise\<[models.ErrorT](../../models/errort.md)\>** ### Errors | Error Type | Status Code | Content Type | | -------------------------- | -------------------------- | -------------------------- | | errors.DokployDefaultError | 4XX, 5XX | \*/\* | ## get ### Example Usage ```typescript import { Dokploy } from "dokploy"; const dokploy = new Dokploy({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const result = await dokploy.backup.get({ backupId: "", }); console.log(result); } run(); ``` ### Standalone function The standalone function version of this method: ```typescript import { DokployCore } from "dokploy/core.js"; import { backupGet } from "dokploy/funcs/backupGet.js"; // Use `DokployCore` for best tree-shaking performance. // You can create one instance of it to use across an application. const dokploy = new DokployCore({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const res = await backupGet(dokploy, { backupId: "", }); if (res.ok) { const { value: result } = res; console.log(result); } else { console.log("backupGet failed:", res.error); } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | | `request` | [operations.BackupOneRequest](../../models/operations/backuponerequest.md) | :heavy_check_mark: | The request object to use for the request. | | `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. | | `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. | | `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. | ### Response **Promise\<[models.ErrorT](../../models/errort.md)\>** ### Errors | Error Type | Status Code | Content Type | | -------------------------- | -------------------------- | -------------------------- | | errors.DokployDefaultError | 4XX, 5XX | \*/\* | ## update ### Example Usage ```typescript import { Dokploy } from "dokploy"; const dokploy = new Dokploy({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const result = await dokploy.backup.update({ schedule: "", prefix: "", backupId: "", destinationId: "", database: "", }); console.log(result); } run(); ``` ### Standalone function The standalone function version of this method: ```typescript import { DokployCore } from "dokploy/core.js"; import { backupUpdate } from "dokploy/funcs/backupUpdate.js"; // Use `DokployCore` for best tree-shaking performance. // You can create one instance of it to use across an application. const dokploy = new DokployCore({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const res = await backupUpdate(dokploy, { schedule: "", prefix: "", backupId: "", destinationId: "", database: "", }); if (res.ok) { const { value: result } = res; console.log(result); } else { console.log("backupUpdate failed:", res.error); } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | | `request` | [operations.BackupUpdateRequest](../../models/operations/backupupdaterequest.md) | :heavy_check_mark: | The request object to use for the request. | | `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. | | `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. | | `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. | ### Response **Promise\<[models.ErrorT](../../models/errort.md)\>** ### Errors | Error Type | Status Code | Content Type | | -------------------------- | -------------------------- | -------------------------- | | errors.DokployDefaultError | 4XX, 5XX | \*/\* | ## remove ### Example Usage ```typescript import { Dokploy } from "dokploy"; const dokploy = new Dokploy({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const result = await dokploy.backup.remove({ backupId: "", }); console.log(result); } run(); ``` ### Standalone function The standalone function version of this method: ```typescript import { DokployCore } from "dokploy/core.js"; import { backupRemove } from "dokploy/funcs/backupRemove.js"; // Use `DokployCore` for best tree-shaking performance. // You can create one instance of it to use across an application. const dokploy = new DokployCore({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const res = await backupRemove(dokploy, { backupId: "", }); if (res.ok) { const { value: result } = res; console.log(result); } else { console.log("backupRemove failed:", res.error); } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | | `request` | [operations.BackupRemoveRequest](../../models/operations/backupremoverequest.md) | :heavy_check_mark: | The request object to use for the request. | | `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. | | `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. | | `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. | ### Response **Promise\<[models.ErrorT](../../models/errort.md)\>** ### Errors | Error Type | Status Code | Content Type | | -------------------------- | -------------------------- | -------------------------- | | errors.DokployDefaultError | 4XX, 5XX | \*/\* | ## manualBackupPostgres ### Example Usage ```typescript import { Dokploy } from "dokploy"; const dokploy = new Dokploy({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const result = await dokploy.backup.manualBackupPostgres({ backupId: "", }); console.log(result); } run(); ``` ### Standalone function The standalone function version of this method: ```typescript import { DokployCore } from "dokploy/core.js"; import { backupManualBackupPostgres } from "dokploy/funcs/backupManualBackupPostgres.js"; // Use `DokployCore` for best tree-shaking performance. // You can create one instance of it to use across an application. const dokploy = new DokployCore({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const res = await backupManualBackupPostgres(dokploy, { backupId: "", }); if (res.ok) { const { value: result } = res; console.log(result); } else { console.log("backupManualBackupPostgres failed:", res.error); } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | | `request` | [operations.BackupManualBackupPostgresRequest](../../models/operations/backupmanualbackuppostgresrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. | | `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. | | `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. | ### Response **Promise\<[models.ErrorT](../../models/errort.md)\>** ### Errors | Error Type | Status Code | Content Type | | -------------------------- | -------------------------- | -------------------------- | | errors.DokployDefaultError | 4XX, 5XX | \*/\* | ## manualBackupMysql ### Example Usage ```typescript import { Dokploy } from "dokploy"; const dokploy = new Dokploy({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const result = await dokploy.backup.manualBackupMysql({ backupId: "", }); console.log(result); } run(); ``` ### Standalone function The standalone function version of this method: ```typescript import { DokployCore } from "dokploy/core.js"; import { backupManualBackupMysql } from "dokploy/funcs/backupManualBackupMysql.js"; // Use `DokployCore` for best tree-shaking performance. // You can create one instance of it to use across an application. const dokploy = new DokployCore({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const res = await backupManualBackupMysql(dokploy, { backupId: "", }); if (res.ok) { const { value: result } = res; console.log(result); } else { console.log("backupManualBackupMysql failed:", res.error); } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | | `request` | [operations.BackupManualBackupMySqlRequest](../../models/operations/backupmanualbackupmysqlrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. | | `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. | | `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. | ### Response **Promise\<[models.ErrorT](../../models/errort.md)\>** ### Errors | Error Type | Status Code | Content Type | | -------------------------- | -------------------------- | -------------------------- | | errors.DokployDefaultError | 4XX, 5XX | \*/\* | ## manualBackupMariadb ### Example Usage ```typescript import { Dokploy } from "dokploy"; const dokploy = new Dokploy({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const result = await dokploy.backup.manualBackupMariadb({ backupId: "", }); console.log(result); } run(); ``` ### Standalone function The standalone function version of this method: ```typescript import { DokployCore } from "dokploy/core.js"; import { backupManualBackupMariadb } from "dokploy/funcs/backupManualBackupMariadb.js"; // Use `DokployCore` for best tree-shaking performance. // You can create one instance of it to use across an application. const dokploy = new DokployCore({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const res = await backupManualBackupMariadb(dokploy, { backupId: "", }); if (res.ok) { const { value: result } = res; console.log(result); } else { console.log("backupManualBackupMariadb failed:", res.error); } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | | `request` | [operations.BackupManualBackupMariadbRequest](../../models/operations/backupmanualbackupmariadbrequest.md) | :heavy_check_mark: | The request object to use for the request. | | `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. | | `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. | | `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. | ### Response **Promise\<[models.ErrorT](../../models/errort.md)\>** ### Errors | Error Type | Status Code | Content Type | | -------------------------- | -------------------------- | -------------------------- | | errors.DokployDefaultError | 4XX, 5XX | \*/\* | ## manualBackupMongo ### Example Usage ```typescript import { Dokploy } from "dokploy"; const dokploy = new Dokploy({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const result = await dokploy.backup.manualBackupMongo({ backupId: "", }); console.log(result); } run(); ``` ### Standalone function The standalone function version of this method: ```typescript import { DokployCore } from "dokploy/core.js"; import { backupManualBackupMongo } from "dokploy/funcs/backupManualBackupMongo.js"; // Use `DokployCore` for best tree-shaking performance. // You can create one instance of it to use across an application. const dokploy = new DokployCore({ authorization: process.env["DOKPLOY_AUTHORIZATION"] ?? "", }); async function run() { const res = await backupManualBackupMongo(dokploy, { backupId: "", }); if (res.ok) { const { value: result } = res; console.log(result); } else { console.log("backupManualBackupMongo failed:", res.error); } } run(); ``` ### Parameters | Parameter | Type | Required | Description | | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | | `request` | [operations.BackupManualBackupMongoRequest](../../models/operations/backupmanualbackupmongorequest.md) | :heavy_check_mark: | The request object to use for the request. | | `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. | | `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. | | `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. | ### Response **Promise\<[models.ErrorT](../../models/errort.md)\>** ### Errors | Error Type | Status Code | Content Type | | -------------------------- | -------------------------- | -------------------------- | | errors.DokployDefaultError | 4XX, 5XX | \*/\* |