@hostafrica/ha-sdk-typescript 1.0.13 → 1.0.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (121) hide show
  1. package/.github/workflows/codeql.yml +3 -3
  2. package/.github/workflows/release.yml +3 -3
  3. package/.github/workflows/semgrep.yml +1 -1
  4. package/dist/apis/SnapshotsApi.d.ts +63 -3
  5. package/dist/apis/SnapshotsApi.js +190 -2
  6. package/dist/apis/VPSManagementApi.d.ts +2 -2
  7. package/dist/apis/VPSManagementApi.js +2 -2
  8. package/dist/esm/apis/SnapshotsApi.d.ts +63 -3
  9. package/dist/esm/apis/SnapshotsApi.js +191 -3
  10. package/dist/esm/apis/VPSManagementApi.d.ts +2 -2
  11. package/dist/esm/apis/VPSManagementApi.js +2 -2
  12. package/dist/esm/models/CreateSnapshotJobRequestContent.d.ts +76 -0
  13. package/dist/esm/models/CreateSnapshotJobRequestContent.js +63 -0
  14. package/dist/esm/models/CreateSnapshotJobResponseContent.d.ts +40 -0
  15. package/dist/esm/models/CreateSnapshotJobResponseContent.js +49 -0
  16. package/dist/esm/models/CreateSnapshotRequestContent.d.ts +7 -1
  17. package/dist/esm/models/CreateSnapshotRequestContent.js +6 -2
  18. package/dist/esm/models/DeleteSnapshotJobRequestContent.d.ts +38 -0
  19. package/dist/esm/models/DeleteSnapshotJobRequestContent.js +47 -0
  20. package/dist/esm/models/DeleteSnapshotJobResponseContent.d.ts +40 -0
  21. package/dist/esm/models/DeleteSnapshotJobResponseContent.js +49 -0
  22. package/dist/esm/models/ListSnapshotJobsRequestContent.d.ts +32 -0
  23. package/dist/esm/models/ListSnapshotJobsRequestContent.js +43 -0
  24. package/dist/esm/models/ListSnapshotJobsResponseContent.d.ts +40 -0
  25. package/dist/esm/models/ListSnapshotJobsResponseContent.js +49 -0
  26. package/dist/esm/models/SnapshotJob.d.ts +88 -0
  27. package/dist/esm/models/SnapshotJob.js +67 -0
  28. package/dist/esm/models/SnapshotJobDeleteResponseData.d.ts +39 -0
  29. package/dist/esm/models/SnapshotJobDeleteResponseData.js +48 -0
  30. package/dist/esm/models/SnapshotJobLimits.d.ts +44 -0
  31. package/dist/esm/models/SnapshotJobLimits.js +51 -0
  32. package/dist/esm/models/SnapshotJobListResponseData.d.ts +52 -0
  33. package/dist/esm/models/SnapshotJobListResponseData.js +55 -0
  34. package/dist/esm/models/SnapshotJobMutationResponseData.d.ts +46 -0
  35. package/dist/esm/models/SnapshotJobMutationResponseData.js +53 -0
  36. package/dist/esm/models/SnapshotJobPeriod.d.ts +25 -0
  37. package/dist/esm/models/SnapshotJobPeriod.js +43 -0
  38. package/dist/esm/models/SnapshotJobUpdateResponseData.d.ts +39 -0
  39. package/dist/esm/models/SnapshotJobUpdateResponseData.js +48 -0
  40. package/dist/esm/models/UpdateSnapshotJobRequestContent.d.ts +82 -0
  41. package/dist/esm/models/UpdateSnapshotJobRequestContent.js +63 -0
  42. package/dist/esm/models/UpdateSnapshotJobResponseContent.d.ts +40 -0
  43. package/dist/esm/models/UpdateSnapshotJobResponseContent.js +49 -0
  44. package/dist/esm/models/index.d.ts +15 -0
  45. package/dist/esm/models/index.js +15 -0
  46. package/dist/esm/retryablePaths.js +1 -0
  47. package/dist/models/CreateSnapshotJobRequestContent.d.ts +76 -0
  48. package/dist/models/CreateSnapshotJobRequestContent.js +70 -0
  49. package/dist/models/CreateSnapshotJobResponseContent.d.ts +40 -0
  50. package/dist/models/CreateSnapshotJobResponseContent.js +56 -0
  51. package/dist/models/CreateSnapshotRequestContent.d.ts +7 -1
  52. package/dist/models/CreateSnapshotRequestContent.js +6 -2
  53. package/dist/models/DeleteSnapshotJobRequestContent.d.ts +38 -0
  54. package/dist/models/DeleteSnapshotJobRequestContent.js +54 -0
  55. package/dist/models/DeleteSnapshotJobResponseContent.d.ts +40 -0
  56. package/dist/models/DeleteSnapshotJobResponseContent.js +56 -0
  57. package/dist/models/ListSnapshotJobsRequestContent.d.ts +32 -0
  58. package/dist/models/ListSnapshotJobsRequestContent.js +50 -0
  59. package/dist/models/ListSnapshotJobsResponseContent.d.ts +40 -0
  60. package/dist/models/ListSnapshotJobsResponseContent.js +56 -0
  61. package/dist/models/SnapshotJob.d.ts +88 -0
  62. package/dist/models/SnapshotJob.js +74 -0
  63. package/dist/models/SnapshotJobDeleteResponseData.d.ts +39 -0
  64. package/dist/models/SnapshotJobDeleteResponseData.js +55 -0
  65. package/dist/models/SnapshotJobLimits.d.ts +44 -0
  66. package/dist/models/SnapshotJobLimits.js +58 -0
  67. package/dist/models/SnapshotJobListResponseData.d.ts +52 -0
  68. package/dist/models/SnapshotJobListResponseData.js +62 -0
  69. package/dist/models/SnapshotJobMutationResponseData.d.ts +46 -0
  70. package/dist/models/SnapshotJobMutationResponseData.js +60 -0
  71. package/dist/models/SnapshotJobPeriod.d.ts +25 -0
  72. package/dist/models/SnapshotJobPeriod.js +51 -0
  73. package/dist/models/SnapshotJobUpdateResponseData.d.ts +39 -0
  74. package/dist/models/SnapshotJobUpdateResponseData.js +55 -0
  75. package/dist/models/UpdateSnapshotJobRequestContent.d.ts +82 -0
  76. package/dist/models/UpdateSnapshotJobRequestContent.js +70 -0
  77. package/dist/models/UpdateSnapshotJobResponseContent.d.ts +40 -0
  78. package/dist/models/UpdateSnapshotJobResponseContent.js +56 -0
  79. package/dist/models/index.d.ts +15 -0
  80. package/dist/models/index.js +15 -0
  81. package/dist/retryablePaths.js +1 -0
  82. package/dist.zip +0 -0
  83. package/docs/CreateSnapshotJobRequestContent.md +48 -0
  84. package/docs/CreateSnapshotJobResponseContent.md +36 -0
  85. package/docs/CreateSnapshotRequestContent.md +4 -2
  86. package/docs/DeleteSnapshotJobRequestContent.md +36 -0
  87. package/docs/DeleteSnapshotJobResponseContent.md +36 -0
  88. package/docs/ListSnapshotJobsRequestContent.md +34 -0
  89. package/docs/ListSnapshotJobsResponseContent.md +36 -0
  90. package/docs/SnapshotJob.md +53 -0
  91. package/docs/SnapshotJobDeleteResponseData.md +37 -0
  92. package/docs/SnapshotJobLimits.md +39 -0
  93. package/docs/SnapshotJobListResponseData.md +41 -0
  94. package/docs/SnapshotJobMutationResponseData.md +39 -0
  95. package/docs/SnapshotJobPeriod.md +33 -0
  96. package/docs/SnapshotJobUpdateResponseData.md +37 -0
  97. package/docs/SnapshotsApi.md +321 -1
  98. package/docs/UpdateSnapshotJobRequestContent.md +50 -0
  99. package/docs/UpdateSnapshotJobResponseContent.md +36 -0
  100. package/docs/VPSManagementApi.md +1 -1
  101. package/package.json +1 -1
  102. package/src/apis/SnapshotsApi.ts +262 -2
  103. package/src/apis/VPSManagementApi.ts +2 -2
  104. package/src/models/CreateSnapshotJobRequestContent.ts +141 -0
  105. package/src/models/CreateSnapshotJobResponseContent.ts +92 -0
  106. package/src/models/CreateSnapshotRequestContent.ts +12 -3
  107. package/src/models/DeleteSnapshotJobRequestContent.ts +75 -0
  108. package/src/models/DeleteSnapshotJobResponseContent.ts +92 -0
  109. package/src/models/ListSnapshotJobsRequestContent.ts +66 -0
  110. package/src/models/ListSnapshotJobsResponseContent.ts +92 -0
  111. package/src/models/SnapshotJob.ts +157 -0
  112. package/src/models/SnapshotJobDeleteResponseData.ts +83 -0
  113. package/src/models/SnapshotJobLimits.ts +84 -0
  114. package/src/models/SnapshotJobListResponseData.ts +107 -0
  115. package/src/models/SnapshotJobMutationResponseData.ts +99 -0
  116. package/src/models/SnapshotJobPeriod.ts +53 -0
  117. package/src/models/SnapshotJobUpdateResponseData.ts +83 -0
  118. package/src/models/UpdateSnapshotJobRequestContent.ts +148 -0
  119. package/src/models/UpdateSnapshotJobResponseContent.ts +92 -0
  120. package/src/models/index.ts +15 -0
  121. package/src/retryablePaths.ts +1 -0
@@ -0,0 +1,36 @@
1
+
2
+ # ListSnapshotJobsResponseContent
3
+
4
+
5
+ ## Properties
6
+
7
+ Name | Type
8
+ ------------ | -------------
9
+ `status` | [OperationStatus](OperationStatus.md)
10
+ `data` | [SnapshotJobListResponseData](SnapshotJobListResponseData.md)
11
+
12
+ ## Example
13
+
14
+ ```typescript
15
+ import type { ListSnapshotJobsResponseContent } from '@hostafrica/ha-sdk-typescript'
16
+
17
+ // TODO: Update the object below with actual values
18
+ const example = {
19
+ "status": null,
20
+ "data": null,
21
+ } satisfies ListSnapshotJobsResponseContent
22
+
23
+ console.log(example)
24
+
25
+ // Convert the instance to a JSON string
26
+ const exampleJSON: string = JSON.stringify(example)
27
+ console.log(exampleJSON)
28
+
29
+ // Parse the JSON string back to an object
30
+ const exampleParsed = JSON.parse(exampleJSON) as ListSnapshotJobsResponseContent
31
+ console.log(exampleParsed)
32
+ ```
33
+
34
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
35
+
36
+
@@ -0,0 +1,53 @@
1
+
2
+ # SnapshotJob
3
+
4
+ Individual snapshot job item
5
+
6
+ ## Properties
7
+
8
+ Name | Type
9
+ ------------ | -------------
10
+ `id` | number
11
+ `hostingId` | number
12
+ `vmId` | number
13
+ `name` | string
14
+ `description` | string
15
+ `vmstate` | boolean
16
+ `period` | [SnapshotJobPeriod](SnapshotJobPeriod.md)
17
+ `runEvery` | number
18
+ `days` | [Array<DayOfWeek>](DayOfWeek.md)
19
+ `startTime` | string
20
+
21
+ ## Example
22
+
23
+ ```typescript
24
+ import type { SnapshotJob } from '@hostafrica/ha-sdk-typescript'
25
+
26
+ // TODO: Update the object below with actual values
27
+ const example = {
28
+ "id": null,
29
+ "hostingId": null,
30
+ "vmId": null,
31
+ "name": null,
32
+ "description": null,
33
+ "vmstate": null,
34
+ "period": null,
35
+ "runEvery": null,
36
+ "days": null,
37
+ "startTime": null,
38
+ } satisfies SnapshotJob
39
+
40
+ console.log(example)
41
+
42
+ // Convert the instance to a JSON string
43
+ const exampleJSON: string = JSON.stringify(example)
44
+ console.log(exampleJSON)
45
+
46
+ // Parse the JSON string back to an object
47
+ const exampleParsed = JSON.parse(exampleJSON) as SnapshotJob
48
+ console.log(exampleParsed)
49
+ ```
50
+
51
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
52
+
53
+
@@ -0,0 +1,37 @@
1
+
2
+ # SnapshotJobDeleteResponseData
3
+
4
+ Response data for snapshot job delete operation
5
+
6
+ ## Properties
7
+
8
+ Name | Type
9
+ ------------ | -------------
10
+ `message` | string
11
+ `limits` | [SnapshotJobLimits](SnapshotJobLimits.md)
12
+
13
+ ## Example
14
+
15
+ ```typescript
16
+ import type { SnapshotJobDeleteResponseData } from '@hostafrica/ha-sdk-typescript'
17
+
18
+ // TODO: Update the object below with actual values
19
+ const example = {
20
+ "message": null,
21
+ "limits": null,
22
+ } satisfies SnapshotJobDeleteResponseData
23
+
24
+ console.log(example)
25
+
26
+ // Convert the instance to a JSON string
27
+ const exampleJSON: string = JSON.stringify(example)
28
+ console.log(exampleJSON)
29
+
30
+ // Parse the JSON string back to an object
31
+ const exampleParsed = JSON.parse(exampleJSON) as SnapshotJobDeleteResponseData
32
+ console.log(exampleParsed)
33
+ ```
34
+
35
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
36
+
37
+
@@ -0,0 +1,39 @@
1
+
2
+ # SnapshotJobLimits
3
+
4
+ Limits and quota information for snapshot jobs
5
+
6
+ ## Properties
7
+
8
+ Name | Type
9
+ ------------ | -------------
10
+ `maxJobs` | number
11
+ `jobCount` | number
12
+ `canAddMore` | boolean
13
+
14
+ ## Example
15
+
16
+ ```typescript
17
+ import type { SnapshotJobLimits } from '@hostafrica/ha-sdk-typescript'
18
+
19
+ // TODO: Update the object below with actual values
20
+ const example = {
21
+ "maxJobs": null,
22
+ "jobCount": null,
23
+ "canAddMore": null,
24
+ } satisfies SnapshotJobLimits
25
+
26
+ console.log(example)
27
+
28
+ // Convert the instance to a JSON string
29
+ const exampleJSON: string = JSON.stringify(example)
30
+ console.log(exampleJSON)
31
+
32
+ // Parse the JSON string back to an object
33
+ const exampleParsed = JSON.parse(exampleJSON) as SnapshotJobLimits
34
+ console.log(exampleParsed)
35
+ ```
36
+
37
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
38
+
39
+
@@ -0,0 +1,41 @@
1
+
2
+ # SnapshotJobListResponseData
3
+
4
+ Response data for snapshot job list operation
5
+
6
+ ## Properties
7
+
8
+ Name | Type
9
+ ------------ | -------------
10
+ `message` | string
11
+ `jobs` | [Array<SnapshotJob>](SnapshotJob.md)
12
+ `limits` | [SnapshotJobLimits](SnapshotJobLimits.md)
13
+ `allowedPeriods` | Array<string>
14
+
15
+ ## Example
16
+
17
+ ```typescript
18
+ import type { SnapshotJobListResponseData } from '@hostafrica/ha-sdk-typescript'
19
+
20
+ // TODO: Update the object below with actual values
21
+ const example = {
22
+ "message": null,
23
+ "jobs": null,
24
+ "limits": null,
25
+ "allowedPeriods": null,
26
+ } satisfies SnapshotJobListResponseData
27
+
28
+ console.log(example)
29
+
30
+ // Convert the instance to a JSON string
31
+ const exampleJSON: string = JSON.stringify(example)
32
+ console.log(exampleJSON)
33
+
34
+ // Parse the JSON string back to an object
35
+ const exampleParsed = JSON.parse(exampleJSON) as SnapshotJobListResponseData
36
+ console.log(exampleParsed)
37
+ ```
38
+
39
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
40
+
41
+
@@ -0,0 +1,39 @@
1
+
2
+ # SnapshotJobMutationResponseData
3
+
4
+ Response data for snapshot job create operation
5
+
6
+ ## Properties
7
+
8
+ Name | Type
9
+ ------------ | -------------
10
+ `message` | string
11
+ `job` | [SnapshotJob](SnapshotJob.md)
12
+ `limits` | [SnapshotJobLimits](SnapshotJobLimits.md)
13
+
14
+ ## Example
15
+
16
+ ```typescript
17
+ import type { SnapshotJobMutationResponseData } from '@hostafrica/ha-sdk-typescript'
18
+
19
+ // TODO: Update the object below with actual values
20
+ const example = {
21
+ "message": null,
22
+ "job": null,
23
+ "limits": null,
24
+ } satisfies SnapshotJobMutationResponseData
25
+
26
+ console.log(example)
27
+
28
+ // Convert the instance to a JSON string
29
+ const exampleJSON: string = JSON.stringify(example)
30
+ console.log(exampleJSON)
31
+
32
+ // Parse the JSON string back to an object
33
+ const exampleParsed = JSON.parse(exampleJSON) as SnapshotJobMutationResponseData
34
+ console.log(exampleParsed)
35
+ ```
36
+
37
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
38
+
39
+
@@ -0,0 +1,33 @@
1
+
2
+ # SnapshotJobPeriod
3
+
4
+ Schedule period for snapshot jobs
5
+
6
+ ## Properties
7
+
8
+ Name | Type
9
+ ------------ | -------------
10
+
11
+ ## Example
12
+
13
+ ```typescript
14
+ import type { SnapshotJobPeriod } from '@hostafrica/ha-sdk-typescript'
15
+
16
+ // TODO: Update the object below with actual values
17
+ const example = {
18
+ } satisfies SnapshotJobPeriod
19
+
20
+ console.log(example)
21
+
22
+ // Convert the instance to a JSON string
23
+ const exampleJSON: string = JSON.stringify(example)
24
+ console.log(exampleJSON)
25
+
26
+ // Parse the JSON string back to an object
27
+ const exampleParsed = JSON.parse(exampleJSON) as SnapshotJobPeriod
28
+ console.log(exampleParsed)
29
+ ```
30
+
31
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
32
+
33
+
@@ -0,0 +1,37 @@
1
+
2
+ # SnapshotJobUpdateResponseData
3
+
4
+ Response data for snapshot job update operation
5
+
6
+ ## Properties
7
+
8
+ Name | Type
9
+ ------------ | -------------
10
+ `message` | string
11
+ `job` | [SnapshotJob](SnapshotJob.md)
12
+
13
+ ## Example
14
+
15
+ ```typescript
16
+ import type { SnapshotJobUpdateResponseData } from '@hostafrica/ha-sdk-typescript'
17
+
18
+ // TODO: Update the object below with actual values
19
+ const example = {
20
+ "message": null,
21
+ "job": null,
22
+ } satisfies SnapshotJobUpdateResponseData
23
+
24
+ console.log(example)
25
+
26
+ // Convert the instance to a JSON string
27
+ const exampleJSON: string = JSON.stringify(example)
28
+ console.log(exampleJSON)
29
+
30
+ // Parse the JSON string back to an object
31
+ const exampleParsed = JSON.parse(exampleJSON) as SnapshotJobUpdateResponseData
32
+ console.log(exampleParsed)
33
+ ```
34
+
35
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
36
+
37
+
@@ -5,10 +5,14 @@ All URIs are relative to *https://api.hostafrica.com*
5
5
  | Method | HTTP request | Description |
6
6
  |------------- | ------------- | -------------|
7
7
  | [**createSnapshot**](SnapshotsApi.md#createsnapshot) | **POST** /vps/create-snapshot | |
8
+ | [**createSnapshotJob**](SnapshotsApi.md#createsnapshotjob) | **POST** /vps/create-snapshot-job | |
8
9
  | [**deleteSnapshot**](SnapshotsApi.md#deletesnapshot) | **POST** /vps/delete-snapshot | |
10
+ | [**deleteSnapshotJob**](SnapshotsApi.md#deletesnapshotjob) | **POST** /vps/delete-snapshot-job | |
11
+ | [**listSnapshotJobs**](SnapshotsApi.md#listsnapshotjobs) | **POST** /vps/list-snapshot-jobs | |
9
12
  | [**listSnapshots**](SnapshotsApi.md#listsnapshots) | **POST** /vps/list-snapshots | |
10
13
  | [**rollbackSnapshot**](SnapshotsApi.md#rollbacksnapshot) | **POST** /vps/rollback-snapshot | |
11
14
  | [**updateSnapshot**](SnapshotsApi.md#updatesnapshot) | **POST** /vps/update-snapshot | |
15
+ | [**updateSnapshotJob**](SnapshotsApi.md#updatesnapshotjob) | **POST** /vps/update-snapshot-job | |
12
16
 
13
17
 
14
18
 
@@ -91,6 +95,85 @@ example().catch(console.error);
91
95
  [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
92
96
 
93
97
 
98
+ ## createSnapshotJob
99
+
100
+ > CreateSnapshotJobResponseContent createSnapshotJob(createSnapshotJobRequestContent)
101
+
102
+
103
+
104
+ [Under development] Creates a new snapshot job for a VPS service. Use period=\'hourly\' with run_every, or period=\'daily\' with days and start_time.
105
+
106
+ ### Example
107
+
108
+ ```ts
109
+ import {
110
+ Configuration,
111
+ SnapshotsApi,
112
+ } from '@hostafrica/ha-sdk-typescript';
113
+ import type { CreateSnapshotJobRequest } from '@hostafrica/ha-sdk-typescript';
114
+
115
+ async function example() {
116
+ console.log("🚀 Testing @hostafrica/ha-sdk-typescript SDK...");
117
+ const config = new Configuration({
118
+ // Configure HTTP bearer authorization: BearerAuth
119
+ accessToken: "YOUR BEARER TOKEN",
120
+ });
121
+ const api = new SnapshotsApi(config);
122
+
123
+ const body = {
124
+ // CreateSnapshotJobRequestContent
125
+ createSnapshotJobRequestContent: ...,
126
+ } satisfies CreateSnapshotJobRequest;
127
+
128
+ try {
129
+ const data = await api.createSnapshotJob(body);
130
+ console.log(data);
131
+ } catch (error) {
132
+ console.error(error);
133
+ }
134
+ }
135
+
136
+ // Run the test
137
+ example().catch(console.error);
138
+ ```
139
+
140
+ ### Parameters
141
+
142
+
143
+ | Name | Type | Description | Notes |
144
+ |------------- | ------------- | ------------- | -------------|
145
+ | **createSnapshotJobRequestContent** | [CreateSnapshotJobRequestContent](CreateSnapshotJobRequestContent.md) | | |
146
+
147
+ ### Return type
148
+
149
+ [**CreateSnapshotJobResponseContent**](CreateSnapshotJobResponseContent.md)
150
+
151
+ ### Authorization
152
+
153
+ [BearerAuth](../README.md#BearerAuth)
154
+
155
+ ### HTTP request headers
156
+
157
+ - **Content-Type**: `application/json`
158
+ - **Accept**: `application/json`
159
+
160
+
161
+ ### HTTP response details
162
+ | Status code | Description | Response headers |
163
+ |-------------|-------------|------------------|
164
+ | **200** | CreateSnapshotJob 200 response | - |
165
+ | **400** | BadRequestError 400 response | - |
166
+ | **401** | UnauthorizedError 401 response | - |
167
+ | **403** | ForbiddenError 403 response | - |
168
+ | **404** | ResourceNotFoundError 404 response | - |
169
+ | **422** | ValidationError 422 response | - |
170
+ | **429** | TooManyRequestsError 429 response | * Retry-After - Number of seconds to wait before retrying <br> |
171
+ | **500** | InternalServiceError 500 response | - |
172
+ | **503** | ServiceUnavailableError 503 response | * Retry-After - Number of seconds to wait before retrying <br> |
173
+
174
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
175
+
176
+
94
177
  ## deleteSnapshot
95
178
 
96
179
  > DeleteSnapshotResponseContent deleteSnapshot(deleteSnapshotRequestContent)
@@ -170,6 +253,164 @@ example().catch(console.error);
170
253
  [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
171
254
 
172
255
 
256
+ ## deleteSnapshotJob
257
+
258
+ > DeleteSnapshotJobResponseContent deleteSnapshotJob(deleteSnapshotJobRequestContent)
259
+
260
+
261
+
262
+ [Under development]Deletes a snapshot job from a VPS service
263
+
264
+ ### Example
265
+
266
+ ```ts
267
+ import {
268
+ Configuration,
269
+ SnapshotsApi,
270
+ } from '@hostafrica/ha-sdk-typescript';
271
+ import type { DeleteSnapshotJobRequest } from '@hostafrica/ha-sdk-typescript';
272
+
273
+ async function example() {
274
+ console.log("🚀 Testing @hostafrica/ha-sdk-typescript SDK...");
275
+ const config = new Configuration({
276
+ // Configure HTTP bearer authorization: BearerAuth
277
+ accessToken: "YOUR BEARER TOKEN",
278
+ });
279
+ const api = new SnapshotsApi(config);
280
+
281
+ const body = {
282
+ // DeleteSnapshotJobRequestContent
283
+ deleteSnapshotJobRequestContent: ...,
284
+ } satisfies DeleteSnapshotJobRequest;
285
+
286
+ try {
287
+ const data = await api.deleteSnapshotJob(body);
288
+ console.log(data);
289
+ } catch (error) {
290
+ console.error(error);
291
+ }
292
+ }
293
+
294
+ // Run the test
295
+ example().catch(console.error);
296
+ ```
297
+
298
+ ### Parameters
299
+
300
+
301
+ | Name | Type | Description | Notes |
302
+ |------------- | ------------- | ------------- | -------------|
303
+ | **deleteSnapshotJobRequestContent** | [DeleteSnapshotJobRequestContent](DeleteSnapshotJobRequestContent.md) | | |
304
+
305
+ ### Return type
306
+
307
+ [**DeleteSnapshotJobResponseContent**](DeleteSnapshotJobResponseContent.md)
308
+
309
+ ### Authorization
310
+
311
+ [BearerAuth](../README.md#BearerAuth)
312
+
313
+ ### HTTP request headers
314
+
315
+ - **Content-Type**: `application/json`
316
+ - **Accept**: `application/json`
317
+
318
+
319
+ ### HTTP response details
320
+ | Status code | Description | Response headers |
321
+ |-------------|-------------|------------------|
322
+ | **200** | DeleteSnapshotJob 200 response | - |
323
+ | **400** | BadRequestError 400 response | - |
324
+ | **401** | UnauthorizedError 401 response | - |
325
+ | **403** | ForbiddenError 403 response | - |
326
+ | **404** | ResourceNotFoundError 404 response | - |
327
+ | **422** | ValidationError 422 response | - |
328
+ | **429** | TooManyRequestsError 429 response | * Retry-After - Number of seconds to wait before retrying <br> |
329
+ | **500** | InternalServiceError 500 response | - |
330
+ | **503** | ServiceUnavailableError 503 response | * Retry-After - Number of seconds to wait before retrying <br> |
331
+
332
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
333
+
334
+
335
+ ## listSnapshotJobs
336
+
337
+ > ListSnapshotJobsResponseContent listSnapshotJobs(listSnapshotJobsRequestContent)
338
+
339
+
340
+
341
+ [Under development]Retrieves the list of snapshot jobs for a VPS service
342
+
343
+ ### Example
344
+
345
+ ```ts
346
+ import {
347
+ Configuration,
348
+ SnapshotsApi,
349
+ } from '@hostafrica/ha-sdk-typescript';
350
+ import type { ListSnapshotJobsRequest } from '@hostafrica/ha-sdk-typescript';
351
+
352
+ async function example() {
353
+ console.log("🚀 Testing @hostafrica/ha-sdk-typescript SDK...");
354
+ const config = new Configuration({
355
+ // Configure HTTP bearer authorization: BearerAuth
356
+ accessToken: "YOUR BEARER TOKEN",
357
+ });
358
+ const api = new SnapshotsApi(config);
359
+
360
+ const body = {
361
+ // ListSnapshotJobsRequestContent
362
+ listSnapshotJobsRequestContent: ...,
363
+ } satisfies ListSnapshotJobsRequest;
364
+
365
+ try {
366
+ const data = await api.listSnapshotJobs(body);
367
+ console.log(data);
368
+ } catch (error) {
369
+ console.error(error);
370
+ }
371
+ }
372
+
373
+ // Run the test
374
+ example().catch(console.error);
375
+ ```
376
+
377
+ ### Parameters
378
+
379
+
380
+ | Name | Type | Description | Notes |
381
+ |------------- | ------------- | ------------- | -------------|
382
+ | **listSnapshotJobsRequestContent** | [ListSnapshotJobsRequestContent](ListSnapshotJobsRequestContent.md) | | |
383
+
384
+ ### Return type
385
+
386
+ [**ListSnapshotJobsResponseContent**](ListSnapshotJobsResponseContent.md)
387
+
388
+ ### Authorization
389
+
390
+ [BearerAuth](../README.md#BearerAuth)
391
+
392
+ ### HTTP request headers
393
+
394
+ - **Content-Type**: `application/json`
395
+ - **Accept**: `application/json`
396
+
397
+
398
+ ### HTTP response details
399
+ | Status code | Description | Response headers |
400
+ |-------------|-------------|------------------|
401
+ | **200** | ListSnapshotJobs 200 response | - |
402
+ | **400** | BadRequestError 400 response | - |
403
+ | **401** | UnauthorizedError 401 response | - |
404
+ | **403** | ForbiddenError 403 response | - |
405
+ | **404** | ResourceNotFoundError 404 response | - |
406
+ | **422** | ValidationError 422 response | - |
407
+ | **429** | TooManyRequestsError 429 response | * Retry-After - Number of seconds to wait before retrying <br> |
408
+ | **500** | InternalServiceError 500 response | - |
409
+ | **503** | ServiceUnavailableError 503 response | * Retry-After - Number of seconds to wait before retrying <br> |
410
+
411
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
412
+
413
+
173
414
  ## listSnapshots
174
415
 
175
416
  > ListSnapshotsResponseContent listSnapshots(listSnapshotsRequestContent)
@@ -255,7 +496,7 @@ example().catch(console.error);
255
496
 
256
497
 
257
498
 
258
- [Under development] Rolls back a VPS to a previous snapshot state
499
+ Rolls back a VPS to a previous snapshot state
259
500
 
260
501
  ### Example
261
502
 
@@ -406,3 +647,82 @@ example().catch(console.error);
406
647
 
407
648
  [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
408
649
 
650
+
651
+ ## updateSnapshotJob
652
+
653
+ > UpdateSnapshotJobResponseContent updateSnapshotJob(updateSnapshotJobRequestContent)
654
+
655
+
656
+
657
+ [Under development] Updates an existing snapshot job. Only provide fields you want to change.
658
+
659
+ ### Example
660
+
661
+ ```ts
662
+ import {
663
+ Configuration,
664
+ SnapshotsApi,
665
+ } from '@hostafrica/ha-sdk-typescript';
666
+ import type { UpdateSnapshotJobRequest } from '@hostafrica/ha-sdk-typescript';
667
+
668
+ async function example() {
669
+ console.log("🚀 Testing @hostafrica/ha-sdk-typescript SDK...");
670
+ const config = new Configuration({
671
+ // Configure HTTP bearer authorization: BearerAuth
672
+ accessToken: "YOUR BEARER TOKEN",
673
+ });
674
+ const api = new SnapshotsApi(config);
675
+
676
+ const body = {
677
+ // UpdateSnapshotJobRequestContent
678
+ updateSnapshotJobRequestContent: ...,
679
+ } satisfies UpdateSnapshotJobRequest;
680
+
681
+ try {
682
+ const data = await api.updateSnapshotJob(body);
683
+ console.log(data);
684
+ } catch (error) {
685
+ console.error(error);
686
+ }
687
+ }
688
+
689
+ // Run the test
690
+ example().catch(console.error);
691
+ ```
692
+
693
+ ### Parameters
694
+
695
+
696
+ | Name | Type | Description | Notes |
697
+ |------------- | ------------- | ------------- | -------------|
698
+ | **updateSnapshotJobRequestContent** | [UpdateSnapshotJobRequestContent](UpdateSnapshotJobRequestContent.md) | | |
699
+
700
+ ### Return type
701
+
702
+ [**UpdateSnapshotJobResponseContent**](UpdateSnapshotJobResponseContent.md)
703
+
704
+ ### Authorization
705
+
706
+ [BearerAuth](../README.md#BearerAuth)
707
+
708
+ ### HTTP request headers
709
+
710
+ - **Content-Type**: `application/json`
711
+ - **Accept**: `application/json`
712
+
713
+
714
+ ### HTTP response details
715
+ | Status code | Description | Response headers |
716
+ |-------------|-------------|------------------|
717
+ | **200** | UpdateSnapshotJob 200 response | - |
718
+ | **400** | BadRequestError 400 response | - |
719
+ | **401** | UnauthorizedError 401 response | - |
720
+ | **403** | ForbiddenError 403 response | - |
721
+ | **404** | ResourceNotFoundError 404 response | - |
722
+ | **422** | ValidationError 422 response | - |
723
+ | **429** | TooManyRequestsError 429 response | * Retry-After - Number of seconds to wait before retrying <br> |
724
+ | **500** | InternalServiceError 500 response | - |
725
+ | **503** | ServiceUnavailableError 503 response | * Retry-After - Number of seconds to wait before retrying <br> |
726
+
727
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
728
+