@orangefox-recovery/foxclient 1.0.0

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 (54) hide show
  1. package/.openapi-generator/FILES +34 -0
  2. package/.openapi-generator/VERSION +1 -0
  3. package/.openapi-generator-ignore +23 -0
  4. package/README.md +104 -0
  5. package/api.ts +1904 -0
  6. package/base.ts +86 -0
  7. package/common.ts +150 -0
  8. package/configuration.ts +115 -0
  9. package/dist/api.d.ts +1294 -0
  10. package/dist/api.js +1057 -0
  11. package/dist/base.d.ts +66 -0
  12. package/dist/base.js +65 -0
  13. package/dist/common.d.ts +65 -0
  14. package/dist/common.js +161 -0
  15. package/dist/configuration.d.ts +91 -0
  16. package/dist/configuration.js +44 -0
  17. package/dist/esm/api.d.ts +1294 -0
  18. package/dist/esm/api.js +1042 -0
  19. package/dist/esm/base.d.ts +66 -0
  20. package/dist/esm/base.js +60 -0
  21. package/dist/esm/common.d.ts +65 -0
  22. package/dist/esm/common.js +149 -0
  23. package/dist/esm/configuration.d.ts +91 -0
  24. package/dist/esm/configuration.js +40 -0
  25. package/dist/esm/index.d.ts +13 -0
  26. package/dist/esm/index.js +15 -0
  27. package/dist/index.d.ts +13 -0
  28. package/dist/index.js +31 -0
  29. package/docs/DeviceApi.md +253 -0
  30. package/docs/DeviceResponse.md +44 -0
  31. package/docs/GlobalStatsAggregationModel.md +26 -0
  32. package/docs/HTTPValidationError.md +20 -0
  33. package/docs/ListResponseReleaseResponse.md +22 -0
  34. package/docs/ListResponseShortDeviceResponse.md +22 -0
  35. package/docs/ListResponseShortReleaseResponse.md +22 -0
  36. package/docs/ListResponseStr.md +22 -0
  37. package/docs/MaintainerShortModel.md +26 -0
  38. package/docs/RecoveryImgResponse.md +22 -0
  39. package/docs/ReleaseApi.md +292 -0
  40. package/docs/ReleaseGroupsResponse.md +20 -0
  41. package/docs/ReleaseResponse.md +56 -0
  42. package/docs/ReleaseType.md +12 -0
  43. package/docs/ReleasesSort.md +10 -0
  44. package/docs/ResponseGetReleasesReleasesGet.md +22 -0
  45. package/docs/ShortDeviceResponse.md +38 -0
  46. package/docs/ShortReleaseResponse.md +44 -0
  47. package/docs/StatsApi.md +53 -0
  48. package/docs/ValidationError.md +24 -0
  49. package/docs/ValidationErrorLocInner.md +18 -0
  50. package/git_push.sh +57 -0
  51. package/index.ts +18 -0
  52. package/package.json +41 -0
  53. package/tsconfig.esm.json +7 -0
  54. package/tsconfig.json +18 -0
@@ -0,0 +1,292 @@
1
+ # ReleaseApi
2
+
3
+ All URIs are relative to *http://localhost*
4
+
5
+ |Method | HTTP request | Description|
6
+ |------------- | ------------- | -------------|
7
+ |[**getReleaseExtendedReleasesGetGet**](#getreleaseextendedreleasesgetget) | **GET** /releases/get | Get Release Extended|
8
+ |[**getReleaseReleasesReleaseIdGet**](#getreleasereleasesreleaseidget) | **GET** /releases/{release_id} | Get Release|
9
+ |[**getReleasesReleasesGet**](#getreleasesreleasesget) | **GET** /releases/ | Get Releases|
10
+ |[**getUpdatesUpdatesLastKnownIdGet**](#getupdatesupdateslastknownidget) | **GET** /updates/{last_known_id} | Get Updates|
11
+
12
+ # **getReleaseExtendedReleasesGetGet**
13
+ > ReleaseResponse getReleaseExtendedReleasesGetGet()
14
+
15
+ Extended get device method, including the ability to get a device using device codename instead of the ID and Build ID. Example: /device/get?codename=lavender Calling this method without parameters will return the latest available release in the database Warning: the filename identification is deprecated! Use /release/<release_id> instead!
16
+
17
+ ### Example
18
+
19
+ ```typescript
20
+ import {
21
+ ReleaseApi,
22
+ Configuration,
23
+ ,
24
+
25
+ } from '@orangefox-recovery/foxclient';
26
+
27
+ const configuration = new Configuration();
28
+ const apiInstance = new ReleaseApi(configuration);
29
+
30
+ let releaseId: ; //Release ID (optional) (default to undefined)
31
+ let id: ; //Release ID (deprecated) (optional) (default to undefined)
32
+ let buildId: string; //Build ID, `ro.build.fox_id` prop (optional) (default to undefined)
33
+ let filename: string; // (optional) (default to undefined)
34
+
35
+ const { status, data } = await apiInstance.getReleaseExtendedReleasesGetGet(
36
+ releaseId,
37
+ id,
38
+ buildId,
39
+ filename
40
+ );
41
+ ```
42
+
43
+ ### Parameters
44
+
45
+ |Name | Type | Description | Notes|
46
+ |------------- | ------------- | ------------- | -------------|
47
+ | **releaseId** | **** | Release ID | (optional) defaults to undefined|
48
+ | **id** | **** | Release ID (deprecated) | (optional) defaults to undefined|
49
+ | **buildId** | [**string**] | Build ID, &#x60;ro.build.fox_id&#x60; prop | (optional) defaults to undefined|
50
+ | **filename** | [**string**] | | (optional) defaults to undefined|
51
+
52
+
53
+ ### Return type
54
+
55
+ **ReleaseResponse**
56
+
57
+ ### Authorization
58
+
59
+ [oauth2_password](../README.md#oauth2_password), [bearer_auth](../README.md#bearer_auth)
60
+
61
+ ### HTTP request headers
62
+
63
+ - **Content-Type**: Not defined
64
+ - **Accept**: application/json
65
+
66
+
67
+ ### HTTP response details
68
+ | Status code | Description | Response headers |
69
+ |-------------|-------------|------------------|
70
+ |**200** | Successful Response | - |
71
+ |**422** | Validation Error | - |
72
+
73
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
74
+
75
+ # **getReleaseReleasesReleaseIdGet**
76
+ > ReleaseResponse getReleaseReleasesReleaseIdGet()
77
+
78
+ Gets release information using the release ID, nothing to discuss really.
79
+
80
+ ### Example
81
+
82
+ ```typescript
83
+ import {
84
+ ReleaseApi,
85
+ Configuration
86
+ } from '@orangefox-recovery/foxclient';
87
+
88
+ const configuration = new Configuration();
89
+ const apiInstance = new ReleaseApi(configuration);
90
+
91
+ let releaseId: any; // (default to undefined)
92
+
93
+ const { status, data } = await apiInstance.getReleaseReleasesReleaseIdGet(
94
+ releaseId
95
+ );
96
+ ```
97
+
98
+ ### Parameters
99
+
100
+ |Name | Type | Description | Notes|
101
+ |------------- | ------------- | ------------- | -------------|
102
+ | **releaseId** | **any** | | defaults to undefined|
103
+
104
+
105
+ ### Return type
106
+
107
+ **ReleaseResponse**
108
+
109
+ ### Authorization
110
+
111
+ [oauth2_password](../README.md#oauth2_password), [bearer_auth](../README.md#bearer_auth)
112
+
113
+ ### HTTP request headers
114
+
115
+ - **Content-Type**: Not defined
116
+ - **Accept**: application/json
117
+
118
+
119
+ ### HTTP response details
120
+ | Status code | Description | Response headers |
121
+ |-------------|-------------|------------------|
122
+ |**200** | Successful Response | - |
123
+ |**422** | Validation Error | - |
124
+
125
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
126
+
127
+ # **getReleasesReleasesGet**
128
+ > ResponseGetReleasesReleasesGet getReleasesReleasesGet()
129
+
130
+ Lists releases. This method contains a bunch of different parameters to filter releases for different cases. For example, you may use ?after_release_id param to get only releases that came after the last known one (aka get updates). You can filter releases by maintainer_id to get releases from a specific maintainer. This is the maintainer who released the build, not the current maintainer of the device. Getting releases by device codename is obsolete thought. The reason for this is that devices could change codenames eventually. Unfortunately, some OEMs and community make a total mess of them. Please use /device methods to determine the right device (preferably with the user decision), save the device ID somewhere and use it afterward. Version tag is deprecated for the same reason, it\'s not really consistent, as it might contain patch and mod versions and very different by each maintainer.
131
+
132
+ ### Example
133
+
134
+ ```typescript
135
+ import {
136
+ ReleaseApi,
137
+ Configuration,
138
+
139
+ } from '@orangefox-recovery/foxclient';
140
+
141
+ const configuration = new Configuration();
142
+ const apiInstance = new ReleaseApi(configuration);
143
+
144
+ let id: Array<any>; //Filter by Release IDs (optional) (default to undefined)
145
+ let id2: Array<any>; //Filter by Release IDs (deprecated) (optional) (default to undefined)
146
+ let buildId: Array<string>; //Filter by Build IDs (optional) (default to undefined)
147
+ let deviceId: Array<any>; //Filter by Device IDs (optional) (default to undefined)
148
+ let maintainerId: Array<any>; //Filter by Maintainer IDs (optional) (default to undefined)
149
+ let codename: Array<string>; //Filter by device codenames (optional) (default to undefined)
150
+ let version: Array<string>; //Filter by release version (optional) (default to undefined)
151
+ let type: Array<ReleaseType>; //Filter by release type (optional) (default to undefined)
152
+ let archived: boolean; //Filter by the archived status (optional) (default to undefined)
153
+ let freezed: boolean; //Filter by the freezed status (optional) (default to undefined)
154
+ let afterReleaseId: ; //Show releases after the provided one (optional) (default to undefined)
155
+ let afterDate: number; //Show releases after the provided timestamp (optional) (default to undefined)
156
+ let sort: ReleasesSort; //Sort mode (optional) (default to undefined)
157
+ let group: boolean; //Group releases by version + variant. This will change the response! (optional) (default to undefined)
158
+ let skip: number; //Skip query results (optional) (default to undefined)
159
+ let limit: number; //Limit query results (0 means unlimited) (optional) (default to undefined)
160
+
161
+ const { status, data } = await apiInstance.getReleasesReleasesGet(
162
+ id,
163
+ id2,
164
+ buildId,
165
+ deviceId,
166
+ maintainerId,
167
+ codename,
168
+ version,
169
+ type,
170
+ archived,
171
+ freezed,
172
+ afterReleaseId,
173
+ afterDate,
174
+ sort,
175
+ group,
176
+ skip,
177
+ limit
178
+ );
179
+ ```
180
+
181
+ ### Parameters
182
+
183
+ |Name | Type | Description | Notes|
184
+ |------------- | ------------- | ------------- | -------------|
185
+ | **id** | **Array&lt;any&gt;** | Filter by Release IDs | (optional) defaults to undefined|
186
+ | **id2** | **Array&lt;any&gt;** | Filter by Release IDs (deprecated) | (optional) defaults to undefined|
187
+ | **buildId** | **Array&lt;string&gt;** | Filter by Build IDs | (optional) defaults to undefined|
188
+ | **deviceId** | **Array&lt;any&gt;** | Filter by Device IDs | (optional) defaults to undefined|
189
+ | **maintainerId** | **Array&lt;any&gt;** | Filter by Maintainer IDs | (optional) defaults to undefined|
190
+ | **codename** | **Array&lt;string&gt;** | Filter by device codenames | (optional) defaults to undefined|
191
+ | **version** | **Array&lt;string&gt;** | Filter by release version | (optional) defaults to undefined|
192
+ | **type** | **Array&lt;ReleaseType&gt;** | Filter by release type | (optional) defaults to undefined|
193
+ | **archived** | [**boolean**] | Filter by the archived status | (optional) defaults to undefined|
194
+ | **freezed** | [**boolean**] | Filter by the freezed status | (optional) defaults to undefined|
195
+ | **afterReleaseId** | **** | Show releases after the provided one | (optional) defaults to undefined|
196
+ | **afterDate** | [**number**] | Show releases after the provided timestamp | (optional) defaults to undefined|
197
+ | **sort** | **ReleasesSort** | Sort mode | (optional) defaults to undefined|
198
+ | **group** | [**boolean**] | Group releases by version + variant. This will change the response! | (optional) defaults to undefined|
199
+ | **skip** | [**number**] | Skip query results | (optional) defaults to undefined|
200
+ | **limit** | [**number**] | Limit query results (0 means unlimited) | (optional) defaults to undefined|
201
+
202
+
203
+ ### Return type
204
+
205
+ **ResponseGetReleasesReleasesGet**
206
+
207
+ ### Authorization
208
+
209
+ [oauth2_password](../README.md#oauth2_password), [bearer_auth](../README.md#bearer_auth)
210
+
211
+ ### HTTP request headers
212
+
213
+ - **Content-Type**: Not defined
214
+ - **Accept**: application/json
215
+
216
+
217
+ ### HTTP response details
218
+ | Status code | Description | Response headers |
219
+ |-------------|-------------|------------------|
220
+ |**200** | Successful Response | - |
221
+ |**404** | Item not found | - |
222
+ |**422** | Validation Error | - |
223
+
224
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
225
+
226
+ # **getUpdatesUpdatesLastKnownIdGet**
227
+ > ListResponseShortReleaseResponse getUpdatesUpdatesLastKnownIdGet()
228
+
229
+ Get updates method. Returns all new releases with release IDs. For example, \"/updates/<id>\" will return a list of all releases that were created after. You can also use \"device_id\" or / and \"release_type\" params. The first one will filter releases by specific devices, the second one will filter by release type. This can be useful, for example, if you want to notify users only with stable releases for this specific device. Warning: This method is obsolete! Please use /release/?after_release_id= instead!
230
+
231
+ ### Example
232
+
233
+ ```typescript
234
+ import {
235
+ ReleaseApi,
236
+ Configuration
237
+ } from '@orangefox-recovery/foxclient';
238
+
239
+ const configuration = new Configuration();
240
+ const apiInstance = new ReleaseApi(configuration);
241
+
242
+ let lastKnownId: any; // (default to undefined)
243
+ let deviceId: Array<any>; //Filter by device ID (optional) (default to undefined)
244
+ let type: Array<ReleaseType>; //Filter by release type (optional) (default to undefined)
245
+ let releaseType: Array<ReleaseType>; //Filter by release type (legacy) (optional) (default to undefined)
246
+ let skip: number; //Skip query results (optional) (default to undefined)
247
+ let limit: number; //Limit query results (0 means unlimited) (optional) (default to undefined)
248
+
249
+ const { status, data } = await apiInstance.getUpdatesUpdatesLastKnownIdGet(
250
+ lastKnownId,
251
+ deviceId,
252
+ type,
253
+ releaseType,
254
+ skip,
255
+ limit
256
+ );
257
+ ```
258
+
259
+ ### Parameters
260
+
261
+ |Name | Type | Description | Notes|
262
+ |------------- | ------------- | ------------- | -------------|
263
+ | **lastKnownId** | **any** | | defaults to undefined|
264
+ | **deviceId** | **Array&lt;any&gt;** | Filter by device ID | (optional) defaults to undefined|
265
+ | **type** | **Array&lt;ReleaseType&gt;** | Filter by release type | (optional) defaults to undefined|
266
+ | **releaseType** | **Array&lt;ReleaseType&gt;** | Filter by release type (legacy) | (optional) defaults to undefined|
267
+ | **skip** | [**number**] | Skip query results | (optional) defaults to undefined|
268
+ | **limit** | [**number**] | Limit query results (0 means unlimited) | (optional) defaults to undefined|
269
+
270
+
271
+ ### Return type
272
+
273
+ **ListResponseShortReleaseResponse**
274
+
275
+ ### Authorization
276
+
277
+ [oauth2_password](../README.md#oauth2_password), [bearer_auth](../README.md#bearer_auth)
278
+
279
+ ### HTTP request headers
280
+
281
+ - **Content-Type**: Not defined
282
+ - **Accept**: application/json
283
+
284
+
285
+ ### HTTP response details
286
+ | Status code | Description | Response headers |
287
+ |-------------|-------------|------------------|
288
+ |**200** | Successful Response | - |
289
+ |**422** | Validation Error | - |
290
+
291
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
292
+
@@ -0,0 +1,20 @@
1
+ # ReleaseGroupsResponse
2
+
3
+
4
+ ## Properties
5
+
6
+ Name | Type | Description | Notes
7
+ ------------ | ------------- | ------------- | -------------
8
+ **data** | **{ [key: string]: Array&lt;ReleaseResponse&gt;; }** | | [default to undefined]
9
+
10
+ ## Example
11
+
12
+ ```typescript
13
+ import { ReleaseGroupsResponse } from '@orangefox-recovery/foxclient';
14
+
15
+ const instance: ReleaseGroupsResponse = {
16
+ data,
17
+ };
18
+ ```
19
+
20
+ [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
@@ -0,0 +1,56 @@
1
+ # ReleaseResponse
2
+
3
+
4
+ ## Properties
5
+
6
+ Name | Type | Description | Notes
7
+ ------------ | ------------- | ------------- | -------------
8
+ **_id** | **string** | | [default to undefined]
9
+ **size** | **number** | | [default to undefined]
10
+ **id** | **string** | Release ID, that\&#39;s how we indentify the release in the infrastructure | [default to undefined]
11
+ **build_id** | **string** | | [optional] [default to undefined]
12
+ **filename** | **string** | | [default to undefined]
13
+ **variant** | **string** | | [default to undefined]
14
+ **device_id** | **string** | | [default to undefined]
15
+ **date** | **string** | | [default to undefined]
16
+ **md5** | **string** | | [default to undefined]
17
+ **version** | **string** | | [default to undefined]
18
+ **type** | [**ReleaseType**](ReleaseType.md) | | [default to undefined]
19
+ **maintainer_id** | **string** | | [optional] [default to undefined]
20
+ **archived** | **boolean** | | [default to undefined]
21
+ **recovery_img** | [**RecoveryImgResponse**](RecoveryImgResponse.md) | | [default to undefined]
22
+ **changelog** | **Array&lt;string&gt;** | | [default to undefined]
23
+ **bugs** | **Array&lt;string&gt;** | | [default to undefined]
24
+ **notes** | **string** | | [default to undefined]
25
+ **url** | **string** | URL of the release on the official website | [readonly] [default to undefined]
26
+ **mirrors** | **{ [key: string]: string; }** | Mirrors list (deprecated) | [readonly] [default to undefined]
27
+
28
+ ## Example
29
+
30
+ ```typescript
31
+ import { ReleaseResponse } from '@orangefox-recovery/foxclient';
32
+
33
+ const instance: ReleaseResponse = {
34
+ _id,
35
+ size,
36
+ id,
37
+ build_id,
38
+ filename,
39
+ variant,
40
+ device_id,
41
+ date,
42
+ md5,
43
+ version,
44
+ type,
45
+ maintainer_id,
46
+ archived,
47
+ recovery_img,
48
+ changelog,
49
+ bugs,
50
+ notes,
51
+ url,
52
+ mirrors,
53
+ };
54
+ ```
55
+
56
+ [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
@@ -0,0 +1,12 @@
1
+ # ReleaseType
2
+
3
+
4
+ ## Enum
5
+
6
+ * `Stable` (value: `'stable'`)
7
+
8
+ * `Beta` (value: `'beta'`)
9
+
10
+ * `Alpha` (value: `'alpha'`)
11
+
12
+ [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
@@ -0,0 +1,10 @@
1
+ # ReleasesSort
2
+
3
+
4
+ ## Enum
5
+
6
+ * `DateAsc` (value: `'date_asc'`)
7
+
8
+ * `DateDesc` (value: `'date_desc'`)
9
+
10
+ [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
@@ -0,0 +1,22 @@
1
+ # ResponseGetReleasesReleasesGet
2
+
3
+
4
+ ## Properties
5
+
6
+ Name | Type | Description | Notes
7
+ ------------ | ------------- | ------------- | -------------
8
+ **data** | **{ [key: string]: Array&lt;ReleaseResponse&gt;; }** | | [default to undefined]
9
+ **count** | **number** | | [readonly] [default to undefined]
10
+
11
+ ## Example
12
+
13
+ ```typescript
14
+ import { ResponseGetReleasesReleasesGet } from '@orangefox-recovery/foxclient';
15
+
16
+ const instance: ResponseGetReleasesReleasesGet = {
17
+ data,
18
+ count,
19
+ };
20
+ ```
21
+
22
+ [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
@@ -0,0 +1,38 @@
1
+ # ShortDeviceResponse
2
+
3
+
4
+ ## Properties
5
+
6
+ Name | Type | Description | Notes
7
+ ------------ | ------------- | ------------- | -------------
8
+ **_id** | **string** | | [default to undefined]
9
+ **codename** | **string** | Device codename, legacy | [default to undefined]
10
+ **model_name** | **string** | Model name of device, does not include the OEM part, legacy | [default to undefined]
11
+ **oem_name** | **string** | | [default to undefined]
12
+ **id** | **string** | | [default to undefined]
13
+ **codenames** | **Array&lt;string&gt;** | | [default to undefined]
14
+ **model_names** | **Array&lt;string&gt;** | | [default to undefined]
15
+ **supported** | **boolean** | | [default to undefined]
16
+ **full_name** | **string** | Full name of device / devices, legacy | [readonly] [default to undefined]
17
+ **url** | **string** | URL of the device on the official website | [readonly] [default to undefined]
18
+
19
+ ## Example
20
+
21
+ ```typescript
22
+ import { ShortDeviceResponse } from '@orangefox-recovery/foxclient';
23
+
24
+ const instance: ShortDeviceResponse = {
25
+ _id,
26
+ codename,
27
+ model_name,
28
+ oem_name,
29
+ id,
30
+ codenames,
31
+ model_names,
32
+ supported,
33
+ full_name,
34
+ url,
35
+ };
36
+ ```
37
+
38
+ [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
@@ -0,0 +1,44 @@
1
+ # ShortReleaseResponse
2
+
3
+
4
+ ## Properties
5
+
6
+ Name | Type | Description | Notes
7
+ ------------ | ------------- | ------------- | -------------
8
+ **_id** | **string** | | [default to undefined]
9
+ **size** | **number** | | [default to undefined]
10
+ **id** | **string** | Release ID, that\&#39;s how we indentify the release in the infrastructure | [default to undefined]
11
+ **build_id** | **string** | | [optional] [default to undefined]
12
+ **filename** | **string** | | [default to undefined]
13
+ **variant** | **string** | | [default to undefined]
14
+ **device_id** | **string** | | [default to undefined]
15
+ **date** | **string** | | [default to undefined]
16
+ **md5** | **string** | | [default to undefined]
17
+ **version** | **string** | | [default to undefined]
18
+ **type** | [**ReleaseType**](ReleaseType.md) | | [default to undefined]
19
+ **maintainer_id** | **string** | | [optional] [default to undefined]
20
+ **archived** | **boolean** | | [default to undefined]
21
+
22
+ ## Example
23
+
24
+ ```typescript
25
+ import { ShortReleaseResponse } from '@orangefox-recovery/foxclient';
26
+
27
+ const instance: ShortReleaseResponse = {
28
+ _id,
29
+ size,
30
+ id,
31
+ build_id,
32
+ filename,
33
+ variant,
34
+ device_id,
35
+ date,
36
+ md5,
37
+ version,
38
+ type,
39
+ maintainer_id,
40
+ archived,
41
+ };
42
+ ```
43
+
44
+ [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
@@ -0,0 +1,53 @@
1
+ # StatsApi
2
+
3
+ All URIs are relative to *http://localhost*
4
+
5
+ |Method | HTTP request | Description|
6
+ |------------- | ------------- | -------------|
7
+ |[**publicStatsStatsGet**](#publicstatsstatsget) | **GET** /stats/ | Public Stats|
8
+
9
+ # **publicStatsStatsGet**
10
+ > GlobalStatsAggregationModel publicStatsStatsGet()
11
+
12
+ Returns the global OrangeFox downloads statistics. This request causes an increased load to the database, as it needs to aggregate all the release stats data, therefore, it is limited to a small number of requests per minute for public usage.
13
+
14
+ ### Example
15
+
16
+ ```typescript
17
+ import {
18
+ StatsApi,
19
+ Configuration
20
+ } from '@orangefox-recovery/foxclient';
21
+
22
+ const configuration = new Configuration();
23
+ const apiInstance = new StatsApi(configuration);
24
+
25
+ const { status, data } = await apiInstance.publicStatsStatsGet();
26
+ ```
27
+
28
+ ### Parameters
29
+ This endpoint does not have any parameters.
30
+
31
+
32
+ ### Return type
33
+
34
+ **GlobalStatsAggregationModel**
35
+
36
+ ### Authorization
37
+
38
+ [oauth2_password](../README.md#oauth2_password), [bearer_auth](../README.md#bearer_auth)
39
+
40
+ ### HTTP request headers
41
+
42
+ - **Content-Type**: Not defined
43
+ - **Accept**: application/json
44
+
45
+
46
+ ### HTTP response details
47
+ | Status code | Description | Response headers |
48
+ |-------------|-------------|------------------|
49
+ |**200** | Successful Response | - |
50
+ |**429** | Too many requests | - |
51
+
52
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
53
+
@@ -0,0 +1,24 @@
1
+ # ValidationError
2
+
3
+
4
+ ## Properties
5
+
6
+ Name | Type | Description | Notes
7
+ ------------ | ------------- | ------------- | -------------
8
+ **loc** | [**Array&lt;ValidationErrorLocInner&gt;**](ValidationErrorLocInner.md) | | [default to undefined]
9
+ **msg** | **string** | | [default to undefined]
10
+ **type** | **string** | | [default to undefined]
11
+
12
+ ## Example
13
+
14
+ ```typescript
15
+ import { ValidationError } from '@orangefox-recovery/foxclient';
16
+
17
+ const instance: ValidationError = {
18
+ loc,
19
+ msg,
20
+ type,
21
+ };
22
+ ```
23
+
24
+ [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
@@ -0,0 +1,18 @@
1
+ # ValidationErrorLocInner
2
+
3
+
4
+ ## Properties
5
+
6
+ Name | Type | Description | Notes
7
+ ------------ | ------------- | ------------- | -------------
8
+
9
+ ## Example
10
+
11
+ ```typescript
12
+ import { ValidationErrorLocInner } from '@orangefox-recovery/foxclient';
13
+
14
+ const instance: ValidationErrorLocInner = {
15
+ };
16
+ ```
17
+
18
+ [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
package/git_push.sh ADDED
@@ -0,0 +1,57 @@
1
+ #!/bin/sh
2
+ # ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/
3
+ #
4
+ # Usage example: /bin/sh ./git_push.sh wing328 openapi-petstore-perl "minor update" "gitlab.com"
5
+
6
+ git_user_id=$1
7
+ git_repo_id=$2
8
+ release_note=$3
9
+ git_host=$4
10
+
11
+ if [ "$git_host" = "" ]; then
12
+ git_host="github.com"
13
+ echo "[INFO] No command line input provided. Set \$git_host to $git_host"
14
+ fi
15
+
16
+ if [ "$git_user_id" = "" ]; then
17
+ git_user_id="GIT_USER_ID"
18
+ echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id"
19
+ fi
20
+
21
+ if [ "$git_repo_id" = "" ]; then
22
+ git_repo_id="GIT_REPO_ID"
23
+ echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id"
24
+ fi
25
+
26
+ if [ "$release_note" = "" ]; then
27
+ release_note="Minor update"
28
+ echo "[INFO] No command line input provided. Set \$release_note to $release_note"
29
+ fi
30
+
31
+ # Initialize the local directory as a Git repository
32
+ git init
33
+
34
+ # Adds the files in the local repository and stages them for commit.
35
+ git add .
36
+
37
+ # Commits the tracked changes and prepares them to be pushed to a remote repository.
38
+ git commit -m "$release_note"
39
+
40
+ # Sets the new remote
41
+ git_remote=$(git remote)
42
+ if [ "$git_remote" = "" ]; then # git remote not defined
43
+
44
+ if [ "$GIT_TOKEN" = "" ]; then
45
+ echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment."
46
+ git remote add origin https://${git_host}/${git_user_id}/${git_repo_id}.git
47
+ else
48
+ git remote add origin https://${git_user_id}:"${GIT_TOKEN}"@${git_host}/${git_user_id}/${git_repo_id}.git
49
+ fi
50
+
51
+ fi
52
+
53
+ git pull origin master
54
+
55
+ # Pushes (Forces) the changes in the local repository up to the remote repository
56
+ echo "Git pushing to https://${git_host}/${git_user_id}/${git_repo_id}.git"
57
+ git push origin master 2>&1 | grep -v 'To https'
package/index.ts ADDED
@@ -0,0 +1,18 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Fox API
5
+ * Warning: Please add a custom \'X-FoxAPI-App=MyAppName\' header to your requests. This would help us fighting against DDoS attacks in future, while keeping your application\'s access to the API. In future, this may be a mandatory requirement. To reduce the system load, the API endpoints are rate limited. The default limit is 20 requests per minute. Contact admin@orangefox.tech if you need a higher limit. The requests may be logged for analytics and development purposes.
6
+ *
7
+ * The version of the OpenAPI document: 5.1.1
8
+ * Contact: admin@orangefox.tech
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+
16
+ export * from "./api";
17
+ export * from "./configuration";
18
+