@putdotio/sdk 13.3.1 → 14.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.
- package/README.md +11 -147
- package/dist/{forms-DnapntwW.js → forms-B9-NYUR5.js} +103 -89
- package/dist/forms-B9-NYUR5.js.map +1 -0
- package/dist/{index-WM491qVG.d.ts → index-DHmXAQNF.d.ts} +253 -417
- package/dist/index.d.ts +2 -2
- package/dist/index.js +497 -682
- package/dist/index.js.map +1 -1
- package/dist/utilities.d.ts +17 -29
- package/dist/utilities.js +48 -66
- package/dist/utilities.js.map +1 -1
- package/package.json +8 -6
- package/dist/forms-DnapntwW.js.map +0 -1
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { A as PutioOperationError, B as isPutioOperationError, C as
|
|
2
|
-
import {
|
|
3
|
-
|
|
1
|
+
import { A as PutioOperationError, B as isPutioOperationError, C as PositiveIntegerSchema, D as PutioAuthError, E as PutioApiError, F as definePutioOperationErrorSpec, G as parseErrorBody, H as mapConfigurationError, I as fallbackPutioErrorEnvelope, J as withOperationErrors, K as responseRateLimitHeaders, L as isPutioApiError, M as PutioTransportError, N as PutioValidationError, O as PutioConfigurationError, P as decodePutioErrorEnvelope, R as isPutioAuthError, S as NonEmptyStringSchema, T as decodeAndRun, U as mapDecodeErrorToValidationError, V as isPutioRateLimitError, W as mapTransportError, _ as selectJsonField, a as PutioSdkConfig, b as DEFAULT_PUTIO_UPLOAD_BASE_URL, c as makePutioFetchClient, d as putioSdkLayer, f as putioSdkLiveLayer, g as requestVoid, h as requestText, i as PutioHttpClient, j as PutioRateLimitError, k as PutioErrorEnvelopeSchema, l as makePutioFetchLayer, m as requestJson, n as toCursorSelectionForm, o as buildPutioUrl, p as requestArrayBuffer, q as toPutioResponseError, r as OkResponseSchema, s as encodePathSegment, t as joinCsv, u as normalizePutioSdkOptions, v as selectJsonFields, w as cursorSelectionSchema, x as DEFAULT_PUTIO_WEB_APP_URL, y as DEFAULT_PUTIO_API_BASE_URL, z as isPutioErrorEnvelope } from "./forms-B9-NYUR5.js";
|
|
2
|
+
import { Context, Effect, Layer, ManagedRuntime, Predicate, Schema, SchemaIssue, SchemaParser, Struct } from "effect";
|
|
3
|
+
// src/domains/account.ts
|
|
4
4
|
const RequestedFlag$1 = Schema.Literal(1);
|
|
5
5
|
const AccountDiskSchema = Schema.Struct({
|
|
6
6
|
avail: Schema.Number.check(Schema.isGreaterThanOrEqualTo(0)),
|
|
@@ -180,26 +180,19 @@ const AccountConfirmationsEnvelopeSchema = Schema.Struct({
|
|
|
180
180
|
confirmations: Schema.Array(AccountConfirmationSchema),
|
|
181
181
|
status: Schema.Literal("OK")
|
|
182
182
|
});
|
|
183
|
-
const
|
|
184
|
-
const failMissingField$1 = (field) => Effect.fail(missingFieldError$1(field));
|
|
185
|
-
const widenValidationError$1 = (effect) => effect;
|
|
183
|
+
const failMissingField$1 = (field) => Effect.fail(new PutioValidationError({ cause: `Expected put.io to include "${field}" because it was requested` }));
|
|
186
184
|
const mapSensitiveAccountDecodeError = (operation) => () => new PutioValidationError({ cause: {
|
|
187
185
|
domain: "account",
|
|
188
186
|
operation,
|
|
189
187
|
reason: "Invalid request input"
|
|
190
188
|
} });
|
|
191
|
-
const hasDownloadToken = (value) => typeof value.download_token === "string";
|
|
192
|
-
const hasFeatures = (value) => typeof value.features === "object" && value.features !== null;
|
|
193
|
-
const hasPas = (value) => typeof value.pas === "object" && value.pas !== null && typeof value.pas.user_hash === "string";
|
|
194
|
-
const hasPaddleUserId = (value) => "paddle_user_id" in value;
|
|
195
|
-
const hasPushToken = (value) => typeof value.push_token === "string";
|
|
196
189
|
const ensureAccountInfoFields = (effect, query) => Effect.gen(function* () {
|
|
197
|
-
const info = yield*
|
|
198
|
-
if (query.download_token === 1 &&
|
|
199
|
-
if (query.features === 1 &&
|
|
200
|
-
if (query.pas === 1 &&
|
|
201
|
-
if (query.profitwell === 1 && !
|
|
202
|
-
if (query.push_token === 1 &&
|
|
190
|
+
const info = yield* effect;
|
|
191
|
+
if (query.download_token === 1 && info.download_token === void 0) return yield* failMissingField$1("download_token");
|
|
192
|
+
if (query.features === 1 && info.features === void 0) return yield* failMissingField$1("features");
|
|
193
|
+
if (query.pas === 1 && info.pas === void 0) return yield* failMissingField$1("pas");
|
|
194
|
+
if (query.profitwell === 1 && !("paddle_user_id" in info)) return yield* failMissingField$1("paddle_user_id");
|
|
195
|
+
if (query.push_token === 1 && info.push_token === void 0) return yield* failMissingField$1("push_token");
|
|
203
196
|
return info;
|
|
204
197
|
});
|
|
205
198
|
const SaveAccountSettingsErrorSpec = definePutioOperationErrorSpec({
|
|
@@ -289,14 +282,14 @@ const AccountConfirmationsErrorSpec = definePutioOperationErrorSpec({
|
|
|
289
282
|
}]
|
|
290
283
|
});
|
|
291
284
|
function getAccountInfo(query = {}) {
|
|
292
|
-
return
|
|
285
|
+
return decodeAndRun(AccountInfoQuerySchema, query, (decodedQuery) => {
|
|
293
286
|
const effect = requestJson(AccountInfoEnvelopeSchema, {
|
|
294
287
|
method: "GET",
|
|
295
288
|
path: "/v2/account/info",
|
|
296
289
|
query: decodedQuery
|
|
297
290
|
}).pipe(selectJsonField("info"));
|
|
298
291
|
return ensureAccountInfoFields(effect, decodedQuery);
|
|
299
|
-
})
|
|
292
|
+
});
|
|
300
293
|
}
|
|
301
294
|
const getAccountSettings = () => requestJson(AccountSettingsEnvelopeSchema, {
|
|
302
295
|
method: "GET",
|
|
@@ -314,14 +307,14 @@ const saveAccountSettings = (payload) => Schema.decodeUnknownEffect(SaveAccountS
|
|
|
314
307
|
method: "POST",
|
|
315
308
|
path: "/v2/account/settings"
|
|
316
309
|
})), withOperationErrors(SaveAccountSettingsErrorSpec));
|
|
317
|
-
const clearAccount = (options) =>
|
|
310
|
+
const clearAccount = (options) => decodeAndRun(AccountClearOptionsSchema, options, (decodedOptions) => requestJson(OkResponseSchema, {
|
|
318
311
|
body: {
|
|
319
312
|
type: "form",
|
|
320
313
|
value: decodedOptions
|
|
321
314
|
},
|
|
322
315
|
method: "POST",
|
|
323
316
|
path: "/v2/account/clear"
|
|
324
|
-
}))
|
|
317
|
+
}));
|
|
325
318
|
const destroyAccount = (currentPassword) => Schema.decodeUnknownEffect(Schema.String.check(Schema.isMinLength(1)))(currentPassword).pipe(Effect.mapError(mapSensitiveAccountDecodeError("destroy")), Effect.flatMap((decodedPassword) => requestJson(OkResponseSchema, {
|
|
326
319
|
body: {
|
|
327
320
|
type: "form",
|
|
@@ -330,13 +323,12 @@ const destroyAccount = (currentPassword) => Schema.decodeUnknownEffect(Schema.St
|
|
|
330
323
|
method: "POST",
|
|
331
324
|
path: "/v2/account/destroy"
|
|
332
325
|
})));
|
|
333
|
-
const listAccountConfirmations = (subject) =>
|
|
326
|
+
const listAccountConfirmations = (subject) => decodeAndRun(Schema.UndefinedOr(AccountConfirmationSubjectSchema), subject, (decodedSubject) => requestJson(AccountConfirmationsEnvelopeSchema, {
|
|
334
327
|
method: "GET",
|
|
335
328
|
path: "/v2/account/confirmation/list",
|
|
336
329
|
query: decodedSubject ? { type: decodedSubject } : void 0
|
|
337
|
-
}))
|
|
338
|
-
|
|
339
|
-
//#region src/domains/app-specific-passwords.ts
|
|
330
|
+
})).pipe(selectJsonField("confirmations"), withOperationErrors(AccountConfirmationsErrorSpec));
|
|
331
|
+
// src/domains/app-specific-passwords.ts
|
|
340
332
|
const AppSpecificPasswordIdSchema = Schema.Int.check(Schema.isGreaterThan(0));
|
|
341
333
|
const AppSpecificPasswordNoteSchema = Schema.Trim.check(Schema.isMinLength(1), Schema.isMaxLength(255));
|
|
342
334
|
const MaskedIpv4AddressPattern = /^(?:(?:25[0-5]|2[0-4]\d|1?\d?\d)\.){3}XXX$/;
|
|
@@ -405,43 +397,41 @@ const DeleteAllAppSpecificPasswordsErrorSpec = definePutioOperationErrorSpec({
|
|
|
405
397
|
operation: "appSpecificPasswords.deleteAll",
|
|
406
398
|
knownErrors: [RestrictedAppSpecificPasswordError]
|
|
407
399
|
});
|
|
408
|
-
const createAppSpecificPassword = (input) =>
|
|
400
|
+
const createAppSpecificPassword = (input) => decodeAndRun(CreateAppSpecificPasswordInputSchema, input, (decodedInput) => requestJson(CreateAppSpecificPasswordEnvelopeSchema, {
|
|
409
401
|
body: {
|
|
410
402
|
type: "form",
|
|
411
403
|
value: decodedInput
|
|
412
404
|
},
|
|
413
405
|
method: "POST",
|
|
414
406
|
path: "/v2/app_specific_password/create"
|
|
415
|
-
}))
|
|
407
|
+
})).pipe(selectJsonFields("created_at", "id", "ip_address", "last_used_at", "note", "password"), withOperationErrors(CreateAppSpecificPasswordErrorSpec));
|
|
416
408
|
const listAppSpecificPasswords = () => requestJson(ListAppSpecificPasswordsEnvelopeSchema, {
|
|
417
409
|
method: "GET",
|
|
418
410
|
path: "/v2/app_specific_password/list"
|
|
419
411
|
}).pipe(selectJsonField("passwords"), withOperationErrors(ListAppSpecificPasswordsErrorSpec));
|
|
420
|
-
const deleteAppSpecificPassword = (id) =>
|
|
412
|
+
const deleteAppSpecificPassword = (id) => decodeAndRun(AppSpecificPasswordIdSchema, id, (decodedId) => requestJson(OkResponseSchema, {
|
|
421
413
|
method: "POST",
|
|
422
414
|
path: `/v2/app_specific_password/${encodePathSegment(decodedId)}/delete`
|
|
423
|
-
}))
|
|
415
|
+
})).pipe(Effect.asVoid, withOperationErrors(DeleteAppSpecificPasswordErrorSpec));
|
|
424
416
|
const deleteAllAppSpecificPasswords = () => requestJson(OkResponseSchema, {
|
|
425
417
|
method: "POST",
|
|
426
418
|
path: "/v2/app_specific_password/delete_all"
|
|
427
419
|
}).pipe(Effect.asVoid, withOperationErrors(DeleteAllAppSpecificPasswordsErrorSpec));
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
const OAuthAppBaseSchema = Schema.Struct({
|
|
420
|
+
// src/domains/oauth.ts
|
|
421
|
+
const OAuthAppSchema = Schema.Struct({
|
|
431
422
|
description: Schema.String,
|
|
432
423
|
has_icon: Schema.NullOr(Schema.Boolean),
|
|
433
424
|
id: Schema.Int,
|
|
434
425
|
name: Schema.String,
|
|
435
426
|
website: Schema.String
|
|
436
427
|
});
|
|
437
|
-
const
|
|
438
|
-
const OwnedOAuthAppSchema = OAuthAppBaseSchema.pipe(Schema.fieldsAssign({
|
|
428
|
+
const OwnedOAuthAppSchema = OAuthAppSchema.pipe(Schema.fieldsAssign({
|
|
439
429
|
callback: Schema.String,
|
|
440
430
|
hidden: Schema.Boolean,
|
|
441
431
|
secret: Schema.String
|
|
442
432
|
}));
|
|
443
433
|
const MyOAuthAppSchema = OwnedOAuthAppSchema.pipe(Schema.fieldsAssign({ users: Schema.Int.check(Schema.isGreaterThanOrEqualTo(0)) }));
|
|
444
|
-
const PopularOAuthAppSchema =
|
|
434
|
+
const PopularOAuthAppSchema = OAuthAppSchema.pipe(Schema.fieldsAssign({
|
|
445
435
|
hidden: Schema.optional(Schema.Boolean),
|
|
446
436
|
maker: Schema.String,
|
|
447
437
|
users: Schema.optional(Schema.Int.check(Schema.isGreaterThanOrEqualTo(0)))
|
|
@@ -581,66 +571,63 @@ const queryOAuthApps = () => requestJson(OAuthAppsEnvelopeSchema, {
|
|
|
581
571
|
method: "GET",
|
|
582
572
|
path: "/v2/oauth/apps"
|
|
583
573
|
}).pipe(selectJsonField("apps"), withOperationErrors(QueryOAuthAppsErrorSpec));
|
|
584
|
-
const getOAuthApp = (id, options) =>
|
|
574
|
+
const getOAuthApp = (id, options) => decodeAndRun(Schema.Struct({
|
|
585
575
|
id: OAuthAppIdSchema,
|
|
586
576
|
options: Schema.optional(Schema.Struct({ edit: Schema.optional(Schema.Boolean) }))
|
|
587
|
-
}), {
|
|
577
|
+
}), {
|
|
588
578
|
id,
|
|
589
579
|
options
|
|
590
|
-
}
|
|
580
|
+
}, (decodedInput) => requestJson(OAuthAppWithTokenSchema, {
|
|
591
581
|
method: "GET",
|
|
592
582
|
path: decodedInput.options?.edit ? `/v2/oauth/apps/${encodePathSegment(decodedInput.id)}/edit` : `/v2/oauth/apps/${encodePathSegment(decodedInput.id)}`
|
|
593
|
-
}))
|
|
594
|
-
const setOAuthAppIcon = (id, input) => {
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
};
|
|
614
|
-
const createOAuthApp = (input) => Schema.decodeUnknownEffect(OAuthAppCreateInputSchema, { onExcessProperty: "error" })(input).pipe(Effect.mapError(mapDecodeErrorToValidationError), Effect.flatMap((decodedInput) => requestJson(OAuthAppEnvelopeSchema, {
|
|
583
|
+
})).pipe(withOperationErrors(GetOAuthAppErrorSpec));
|
|
584
|
+
const setOAuthAppIcon = (id, input) => decodeAndRun(Schema.Struct({
|
|
585
|
+
id: OAuthAppIdSchema,
|
|
586
|
+
input: OAuthSetIconInputSchema
|
|
587
|
+
}), {
|
|
588
|
+
id,
|
|
589
|
+
input
|
|
590
|
+
}, (decodedInput) => {
|
|
591
|
+
const formData = new FormData();
|
|
592
|
+
formData.append("icon", decodedInput.input.icon);
|
|
593
|
+
return requestJson(OkResponseSchema, {
|
|
594
|
+
body: {
|
|
595
|
+
type: "form-data",
|
|
596
|
+
value: formData
|
|
597
|
+
},
|
|
598
|
+
method: "POST",
|
|
599
|
+
path: `/v2/oauth/apps/${encodePathSegment(decodedInput.id)}/icon`
|
|
600
|
+
});
|
|
601
|
+
});
|
|
602
|
+
const createOAuthApp = (input) => decodeAndRun(OAuthAppCreateInputSchema, input, (decodedInput) => requestJson(OAuthAppEnvelopeSchema, {
|
|
615
603
|
body: {
|
|
616
604
|
type: "form-data",
|
|
617
605
|
value: makeCreateOAuthAppFormData(decodedInput)
|
|
618
606
|
},
|
|
619
607
|
method: "POST",
|
|
620
608
|
path: "/v2/oauth/apps/register"
|
|
621
|
-
}))
|
|
622
|
-
const updateOAuthApp = (input) =>
|
|
609
|
+
})).pipe(withOperationErrors(CreateOAuthAppErrorSpec));
|
|
610
|
+
const updateOAuthApp = (input) => decodeAndRun(OAuthAppUpdateInputSchema, input, (decodedInput) => requestJson(OAuthAppWithTokenSchema, {
|
|
623
611
|
body: {
|
|
624
612
|
type: "form-data",
|
|
625
613
|
value: makeUpdateOAuthAppFormData(decodedInput)
|
|
626
614
|
},
|
|
627
615
|
method: "POST",
|
|
628
616
|
path: `/v2/oauth/apps/${encodePathSegment(decodedInput.id)}`
|
|
629
|
-
}))
|
|
630
|
-
const deleteOAuthApp = (id) =>
|
|
617
|
+
})).pipe(withOperationErrors(UpdateOAuthAppErrorSpec));
|
|
618
|
+
const deleteOAuthApp = (id) => decodeAndRun(OAuthAppIdSchema, id, (decodedId) => requestJson(OkResponseSchema, {
|
|
631
619
|
method: "POST",
|
|
632
620
|
path: `/v2/oauth/apps/${encodePathSegment(decodedId)}/delete`
|
|
633
|
-
}))
|
|
634
|
-
const regenerateOAuthAppToken = (id) =>
|
|
621
|
+
})).pipe(withOperationErrors(DeleteOAuthAppErrorSpec));
|
|
622
|
+
const regenerateOAuthAppToken = (id) => decodeAndRun(OAuthAppIdSchema, id, (decodedId) => requestJson(OAuthRegeneratedTokenEnvelopeSchema, {
|
|
635
623
|
method: "POST",
|
|
636
624
|
path: `/v2/oauth/apps/${encodePathSegment(decodedId)}/regenerate_token`
|
|
637
|
-
}))
|
|
625
|
+
})).pipe(selectJsonField("access_token"), withOperationErrors(RegenerateOAuthAppTokenErrorSpec));
|
|
638
626
|
const getPopularOAuthApps = () => requestJson(PopularOAuthAppsEnvelopeSchema, {
|
|
639
627
|
method: "GET",
|
|
640
628
|
path: "/v2/oauth/apps/popular"
|
|
641
629
|
}).pipe(selectJsonField("apps"));
|
|
642
|
-
|
|
643
|
-
//#region src/domains/auth.ts
|
|
630
|
+
// src/domains/auth.ts
|
|
644
631
|
const LoginResponseSchema = Schema.Struct({
|
|
645
632
|
access_token: Schema.String,
|
|
646
633
|
user_id: Schema.Int
|
|
@@ -689,11 +676,7 @@ const AuthorizationCodeSchema = Schema.Struct({
|
|
|
689
676
|
code: Schema.String,
|
|
690
677
|
qr_code_url: Schema.String
|
|
691
678
|
});
|
|
692
|
-
const AuthorizationCodeEnvelopeSchema = Schema.
|
|
693
|
-
code: Schema.String,
|
|
694
|
-
qr_code_url: Schema.String,
|
|
695
|
-
status: Schema.Literal("OK")
|
|
696
|
-
});
|
|
679
|
+
const AuthorizationCodeEnvelopeSchema = AuthorizationCodeSchema.pipe(Schema.fieldsAssign({ status: Schema.Literal("OK") }));
|
|
697
680
|
const CodeMatchEnvelopeSchema = Schema.Struct({
|
|
698
681
|
oauth_token: Schema.NullOr(Schema.String),
|
|
699
682
|
status: Schema.Literal("OK")
|
|
@@ -746,21 +729,12 @@ const ExistsEnvelopeSchema = Schema.Struct({
|
|
|
746
729
|
exists: Schema.Boolean,
|
|
747
730
|
status: Schema.Literal("OK")
|
|
748
731
|
});
|
|
749
|
-
const
|
|
732
|
+
const AccessTokenEnvelopeSchema = Schema.Struct({
|
|
750
733
|
access_token: Schema.String,
|
|
751
734
|
status: Schema.Literal("OK")
|
|
752
735
|
});
|
|
753
|
-
const GenerateTOTPEnvelopeSchema = Schema.
|
|
754
|
-
|
|
755
|
-
secret: Schema.String,
|
|
756
|
-
status: Schema.Literal("OK"),
|
|
757
|
-
uri: Schema.String
|
|
758
|
-
});
|
|
759
|
-
const VerifyTOTPEnvelopeSchema = Schema.Struct({
|
|
760
|
-
status: Schema.Literal("OK"),
|
|
761
|
-
token: Schema.String,
|
|
762
|
-
user_id: Schema.Int
|
|
763
|
-
});
|
|
736
|
+
const GenerateTOTPEnvelopeSchema = GenerateTOTPResponseSchema.pipe(Schema.fieldsAssign({ status: Schema.Literal("OK") }));
|
|
737
|
+
const VerifyTOTPEnvelopeSchema = VerifyTOTPResponseSchema.pipe(Schema.fieldsAssign({ status: Schema.Literal("OK") }));
|
|
764
738
|
const RecoveryCodesEnvelopeSchema = Schema.Struct({
|
|
765
739
|
recovery_codes: TwoFactorRecoveryCodesSchema,
|
|
766
740
|
status: Schema.Literal("OK")
|
|
@@ -1097,7 +1071,7 @@ const logout = () => requestJson(OkResponseSchema, {
|
|
|
1097
1071
|
method: "POST",
|
|
1098
1072
|
path: "/v2/oauth/grants/logout"
|
|
1099
1073
|
});
|
|
1100
|
-
const register = (input) => decodeAuthInput("register", RegisterInputSchema, input, (decodedInput) => requestJson(
|
|
1074
|
+
const register = (input) => decodeAuthInput("register", RegisterInputSchema, input, (decodedInput) => requestJson(AccessTokenEnvelopeSchema, {
|
|
1101
1075
|
auth: { type: "none" },
|
|
1102
1076
|
body: {
|
|
1103
1077
|
type: "form",
|
|
@@ -1147,7 +1121,7 @@ const forgotPassword = (mail) => decodeAuthInput("forgotPassword", NonEmptyStrin
|
|
|
1147
1121
|
const resetPassword = (key, password) => decodeAuthInput("resetPassword", AuthResetPasswordInputSchema, {
|
|
1148
1122
|
key,
|
|
1149
1123
|
password
|
|
1150
|
-
}, (decodedInput) => requestJson(
|
|
1124
|
+
}, (decodedInput) => requestJson(AccessTokenEnvelopeSchema, {
|
|
1151
1125
|
auth: { type: "none" },
|
|
1152
1126
|
body: {
|
|
1153
1127
|
type: "form",
|
|
@@ -1207,11 +1181,7 @@ const validateToken = (token) => decodeAuthInput("validateToken", NonEmptyString
|
|
|
1207
1181
|
const generateTOTP = () => requestJson(GenerateTOTPEnvelopeSchema, {
|
|
1208
1182
|
method: "POST",
|
|
1209
1183
|
path: "/v2/two_factor/generate/totp"
|
|
1210
|
-
}).pipe(
|
|
1211
|
-
recovery_codes,
|
|
1212
|
-
secret,
|
|
1213
|
-
uri
|
|
1214
|
-
})), withOperationErrors(GenerateTOTPErrorSpec));
|
|
1184
|
+
}).pipe(selectJsonFields("recovery_codes", "secret", "uri"), withOperationErrors(GenerateTOTPErrorSpec));
|
|
1215
1185
|
const verifyTOTP = (twoFactorScopedToken, code) => decodeAuthInput("verifyTOTP", AuthVerifyTotpInputSchema, {
|
|
1216
1186
|
code,
|
|
1217
1187
|
twoFactorScopedToken
|
|
@@ -1224,10 +1194,7 @@ const verifyTOTP = (twoFactorScopedToken, code) => decodeAuthInput("verifyTOTP",
|
|
|
1224
1194
|
method: "POST",
|
|
1225
1195
|
path: "/v2/two_factor/verify/totp",
|
|
1226
1196
|
query: { oauth_token: decodedInput.twoFactorScopedToken }
|
|
1227
|
-
}).pipe(
|
|
1228
|
-
token,
|
|
1229
|
-
user_id
|
|
1230
|
-
})))).pipe(withOperationErrors(VerifyTOTPErrorSpec));
|
|
1197
|
+
}).pipe(selectJsonFields("token", "user_id"))).pipe(withOperationErrors(VerifyTOTPErrorSpec));
|
|
1231
1198
|
const getRecoveryCodes = () => requestJson(RecoveryCodesEnvelopeSchema, {
|
|
1232
1199
|
method: "GET",
|
|
1233
1200
|
path: "/v2/two_factor/recovery_codes"
|
|
@@ -1236,154 +1203,109 @@ const regenerateRecoveryCodes = () => requestJson(RecoveryCodesEnvelopeSchema, {
|
|
|
1236
1203
|
method: "POST",
|
|
1237
1204
|
path: "/v2/two_factor/recovery_codes/refresh"
|
|
1238
1205
|
}).pipe(selectJsonField("recovery_codes"), withOperationErrors(RegenerateRecoveryCodesErrorSpec));
|
|
1239
|
-
|
|
1240
|
-
//#region src/domains/config.ts
|
|
1206
|
+
// src/domains/config.ts
|
|
1241
1207
|
const nativeObjectConstructorSource = Function.prototype.toString.call(Object);
|
|
1242
1208
|
const nativeArrayConstructorSource = Function.prototype.toString.call(Array);
|
|
1243
|
-
const
|
|
1209
|
+
const isNativePrototype = (prototype, constructorSource) => {
|
|
1244
1210
|
const constructor = Object.getOwnPropertyDescriptor(prototype, "constructor")?.value;
|
|
1245
|
-
|
|
1246
|
-
return typeof constructor === "function" && constructorPrototype === prototype && Function.prototype.toString.call(constructor) === constructorSource;
|
|
1211
|
+
return Predicate.isFunction(constructor) && Object.getOwnPropertyDescriptor(constructor, "prototype")?.value === prototype && Function.prototype.toString.call(constructor) === constructorSource;
|
|
1247
1212
|
};
|
|
1248
1213
|
const isPlainRecord = (value) => {
|
|
1249
1214
|
try {
|
|
1215
|
+
if (Array.isArray(value)) return false;
|
|
1250
1216
|
const prototype = Object.getPrototypeOf(value);
|
|
1251
1217
|
if (prototype === null) return true;
|
|
1252
1218
|
if (Object.getPrototypeOf(prototype) !== null) return false;
|
|
1253
|
-
return
|
|
1219
|
+
return isNativePrototype(prototype, nativeObjectConstructorSource);
|
|
1254
1220
|
} catch {
|
|
1255
1221
|
return false;
|
|
1256
1222
|
}
|
|
1257
1223
|
};
|
|
1258
1224
|
const isPlainArray = (value) => {
|
|
1259
1225
|
try {
|
|
1226
|
+
if (!Array.isArray(value)) return false;
|
|
1260
1227
|
const prototype = Object.getPrototypeOf(value);
|
|
1261
|
-
return prototype !== null && Object.getPrototypeOf(prototype) !== null &&
|
|
1228
|
+
return prototype !== null && Object.getPrototypeOf(prototype) !== null && isNativePrototype(prototype, nativeArrayConstructorSource);
|
|
1262
1229
|
} catch {
|
|
1263
1230
|
return false;
|
|
1264
1231
|
}
|
|
1265
1232
|
};
|
|
1266
|
-
const
|
|
1267
|
-
const
|
|
1268
|
-
|
|
1269
|
-
if (value
|
|
1270
|
-
|
|
1271
|
-
value
|
|
1272
|
-
} : validatedJsonWalk;
|
|
1273
|
-
if (typeof value === "number") return Number.isFinite(value) ? mode === "snapshot" ? {
|
|
1274
|
-
_tag: "Snapshot",
|
|
1275
|
-
value
|
|
1276
|
-
} : validatedJsonWalk : invalidJsonWalk;
|
|
1277
|
-
if (typeof value !== "object" || ancestors.has(value)) return invalidJsonWalk;
|
|
1233
|
+
const copyOfJsonValue = (value, copies) => (Predicate.isObjectKeyword(value) ? copies.get(value) : void 0) ?? value;
|
|
1234
|
+
const isJsonValueWithin = (value, ancestors, copies) => {
|
|
1235
|
+
if (Predicate.isNull(value) || Predicate.isString(value) || Predicate.isBoolean(value)) return true;
|
|
1236
|
+
if (Predicate.isNumber(value)) return Number.isFinite(value);
|
|
1237
|
+
if (!Predicate.isObjectKeyword(value) || ancestors.has(value)) return false;
|
|
1278
1238
|
ancestors.add(value);
|
|
1279
1239
|
try {
|
|
1280
1240
|
if (Array.isArray(value)) {
|
|
1281
|
-
if (!isPlainArray(value)) return
|
|
1241
|
+
if (!isPlainArray(value)) return false;
|
|
1282
1242
|
const descriptors = Object.getOwnPropertyDescriptors(value);
|
|
1283
|
-
const
|
|
1284
|
-
if (
|
|
1285
|
-
const output =
|
|
1286
|
-
for (let index = 0; index <
|
|
1243
|
+
const length = descriptors["length"]?.value;
|
|
1244
|
+
if (!Number.isSafeInteger(length) || length < 0) return false;
|
|
1245
|
+
const output = [];
|
|
1246
|
+
for (let index = 0; index < length; index += 1) {
|
|
1287
1247
|
const descriptor = descriptors[String(index)];
|
|
1288
|
-
if (descriptor === void 0 || !("value" in descriptor)) return
|
|
1289
|
-
|
|
1290
|
-
if (item._tag === "Invalid") return item;
|
|
1291
|
-
if (output === void 0) {
|
|
1292
|
-
if (item._tag !== "Validated") return invalidJsonWalk;
|
|
1293
|
-
} else {
|
|
1294
|
-
if (item._tag !== "Snapshot") return invalidJsonWalk;
|
|
1295
|
-
output.push(item.value);
|
|
1296
|
-
}
|
|
1248
|
+
if (descriptor === void 0 || !("value" in descriptor) || !isJsonValueWithin(descriptor.value, ancestors, copies)) return false;
|
|
1249
|
+
if (copies !== void 0) output.push(copyOfJsonValue(descriptor.value, copies));
|
|
1297
1250
|
}
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
value: output
|
|
1301
|
-
};
|
|
1251
|
+
copies?.set(value, output);
|
|
1252
|
+
return true;
|
|
1302
1253
|
}
|
|
1303
|
-
if (!isPlainRecord(value)) return
|
|
1304
|
-
const output =
|
|
1254
|
+
if (!isPlainRecord(value)) return false;
|
|
1255
|
+
const output = {};
|
|
1305
1256
|
for (const [key, descriptor] of Object.entries(Object.getOwnPropertyDescriptors(value))) {
|
|
1306
1257
|
if (!descriptor.enumerable) continue;
|
|
1307
|
-
if (!("value" in descriptor)) return
|
|
1308
|
-
|
|
1309
|
-
if (item._tag === "Invalid") return item;
|
|
1310
|
-
if (output === void 0) {
|
|
1311
|
-
if (item._tag !== "Validated") return invalidJsonWalk;
|
|
1312
|
-
continue;
|
|
1313
|
-
}
|
|
1314
|
-
if (item._tag !== "Snapshot") return invalidJsonWalk;
|
|
1315
|
-
Object.defineProperty(output, key, {
|
|
1258
|
+
if (!("value" in descriptor) || !isJsonValueWithin(descriptor.value, ancestors, copies)) return false;
|
|
1259
|
+
if (copies !== void 0) Object.defineProperty(output, key, {
|
|
1316
1260
|
configurable: true,
|
|
1317
1261
|
enumerable: true,
|
|
1318
|
-
value:
|
|
1262
|
+
value: copyOfJsonValue(descriptor.value, copies),
|
|
1319
1263
|
writable: true
|
|
1320
1264
|
});
|
|
1321
1265
|
}
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
value: output
|
|
1325
|
-
};
|
|
1266
|
+
copies?.set(value, output);
|
|
1267
|
+
return true;
|
|
1326
1268
|
} catch {
|
|
1327
|
-
return
|
|
1269
|
+
return false;
|
|
1328
1270
|
} finally {
|
|
1329
1271
|
ancestors.delete(value);
|
|
1330
1272
|
}
|
|
1331
1273
|
};
|
|
1332
|
-
const
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
};
|
|
1336
|
-
const snapshotJsonObject = (value) => {
|
|
1337
|
-
const snapshot = snapshotJsonValue(value);
|
|
1338
|
-
return typeof snapshot === "object" && snapshot !== null && !Array.isArray(snapshot) ? snapshot : void 0;
|
|
1339
|
-
};
|
|
1340
|
-
const isJsonValue = (value) => walkJsonValue(value, "validate")._tag === "Validated";
|
|
1341
|
-
const isJsonObject = (value) => typeof value === "object" && value !== null && isJsonValue(value) && !Array.isArray(value);
|
|
1274
|
+
const isJsonValue = (value) => isJsonValueWithin(value, /* @__PURE__ */ new Set(), void 0);
|
|
1275
|
+
const isJsonObjectValue = (value) => Predicate.isObjectKeyword(value) && !Array.isArray(value);
|
|
1276
|
+
const isJsonObject = (value) => isJsonValue(value) && isJsonObjectValue(value);
|
|
1342
1277
|
const JsonValueSchema = Schema.declareConstructor()([], () => (input, ast, options) => {
|
|
1343
|
-
const
|
|
1344
|
-
return
|
|
1278
|
+
const copies = /* @__PURE__ */ new Map();
|
|
1279
|
+
return isJsonValueWithin(input, /* @__PURE__ */ new Set(), copies) ? Effect.succeed(copyOfJsonValue(input, copies)) : Effect.fail(new SchemaIssue.InvalidType(ast, input, options));
|
|
1345
1280
|
}, { expected: "a JSON-compatible value" });
|
|
1346
1281
|
const JsonValueResponseSchema = Schema.declareConstructor()([], () => (input, ast, options) => isJsonValue(input) ? Effect.succeed(input) : Effect.fail(new SchemaIssue.InvalidType(ast, input, options)), { expected: "a JSON-compatible value" });
|
|
1347
1282
|
const JsonObjectResponseSchema = Schema.declareConstructor()([], () => (input, ast, options) => isJsonObject(input) ? Effect.succeed(input) : Effect.fail(new SchemaIssue.InvalidType(ast, input, options)), { expected: "a JSON object" });
|
|
1348
1283
|
const JsonObjectSchema = Schema.declareConstructor()([], () => (input, ast, options) => {
|
|
1349
|
-
const
|
|
1350
|
-
|
|
1284
|
+
const copies = /* @__PURE__ */ new Map();
|
|
1285
|
+
if (!isJsonValueWithin(input, /* @__PURE__ */ new Set(), copies)) return Effect.fail(new SchemaIssue.InvalidType(ast, input, options));
|
|
1286
|
+
const copy = copyOfJsonValue(input, copies);
|
|
1287
|
+
return isJsonObjectValue(copy) ? Effect.succeed(copy) : Effect.fail(new SchemaIssue.InvalidType(ast, input, options));
|
|
1351
1288
|
}, { expected: "a JSON object" });
|
|
1352
1289
|
const ConfigKeySchema = Schema.String.check(Schema.isMinLength(1), Schema.isPattern(/^(?!\.{1,2}$)/), Schema.makeFilter((key) => key.isWellFormed(), { expected: "a well-formed Unicode config key" }));
|
|
1353
1290
|
const ConfigSetKeyInputSchema = Schema.Struct({
|
|
1354
1291
|
key: ConfigKeySchema,
|
|
1355
1292
|
value: JsonValueSchema
|
|
1356
1293
|
});
|
|
1357
|
-
const
|
|
1358
|
-
|
|
1359
|
-
try
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
|
|
1363
|
-
|
|
1364
|
-
|
|
1365
|
-
|
|
1366
|
-
|
|
1367
|
-
|
|
1368
|
-
|
|
1369
|
-
|
|
1370
|
-
|
|
1371
|
-
|
|
1372
|
-
const fields = getResponseEnvelopeFields(input, "config");
|
|
1373
|
-
if (fields === void 0 || fields.status !== "OK") return Effect.fail(new SchemaIssue.InvalidType(ast, input, options));
|
|
1374
|
-
return SchemaParser.decodeUnknownEffect(configSchema)(fields.value, options).pipe(Effect.map((config) => ({
|
|
1375
|
-
config,
|
|
1376
|
-
status: "OK"
|
|
1377
|
-
})));
|
|
1378
|
-
});
|
|
1379
|
-
const makeConfigValueEnvelopeSchema = (schema) => Schema.declareConstructor()([schema], ([valueSchema]) => (input, ast, options) => {
|
|
1380
|
-
const fields = getResponseEnvelopeFields(input, "value");
|
|
1381
|
-
if (fields === void 0 || fields.status !== "OK") return Effect.fail(new SchemaIssue.InvalidType(ast, input, options));
|
|
1382
|
-
return SchemaParser.decodeUnknownEffect(valueSchema)(fields.value, options).pipe(Effect.map((value) => ({
|
|
1383
|
-
status: "OK",
|
|
1384
|
-
value
|
|
1385
|
-
})));
|
|
1386
|
-
});
|
|
1294
|
+
const okEnvelopeField = (status, field) => status !== void 0 && "value" in status && status.value === "OK" && field !== void 0 && "value" in field ? field : void 0;
|
|
1295
|
+
const makeConfigEnvelopeSchema = (schema) => Schema.declareConstructor()([schema], ([configSchema]) => (input, ast, options) => Effect.try({
|
|
1296
|
+
try: () => isPlainRecord(input) ? okEnvelopeField(Object.getOwnPropertyDescriptor(input, "status"), Object.getOwnPropertyDescriptor(input, "config")) : void 0,
|
|
1297
|
+
catch: () => new SchemaIssue.InvalidType(ast, input, options)
|
|
1298
|
+
}).pipe(Effect.flatMap((field) => field === void 0 ? Effect.fail(new SchemaIssue.InvalidType(ast, input, options)) : SchemaParser.decodeUnknownEffect(configSchema)(field.value, options)), Effect.map((config) => ({
|
|
1299
|
+
config,
|
|
1300
|
+
status: "OK"
|
|
1301
|
+
}))));
|
|
1302
|
+
const makeConfigValueEnvelopeSchema = (schema) => Schema.declareConstructor()([schema], ([valueSchema]) => (input, ast, options) => Effect.try({
|
|
1303
|
+
try: () => isPlainRecord(input) ? okEnvelopeField(Object.getOwnPropertyDescriptor(input, "status"), Object.getOwnPropertyDescriptor(input, "value")) : void 0,
|
|
1304
|
+
catch: () => new SchemaIssue.InvalidType(ast, input, options)
|
|
1305
|
+
}).pipe(Effect.flatMap((field) => field === void 0 ? Effect.fail(new SchemaIssue.InvalidType(ast, input, options)) : SchemaParser.decodeUnknownEffect(valueSchema)(field.value, options)), Effect.map((value) => ({
|
|
1306
|
+
status: "OK",
|
|
1307
|
+
value
|
|
1308
|
+
}))));
|
|
1387
1309
|
const ConfigEnvelopeSchema = makeConfigEnvelopeSchema(JsonObjectResponseSchema);
|
|
1388
1310
|
const ConfigValueEnvelopeSchema = makeConfigValueEnvelopeSchema(JsonValueResponseSchema);
|
|
1389
1311
|
const readConfig = () => requestJson(ConfigEnvelopeSchema, {
|
|
@@ -1394,46 +1316,45 @@ const readConfigWith = (schema) => requestJson(makeConfigEnvelopeSchema(JsonObje
|
|
|
1394
1316
|
method: "GET",
|
|
1395
1317
|
path: "/v2/config"
|
|
1396
1318
|
}).pipe(Effect.map((envelope) => envelope["config"]));
|
|
1397
|
-
const writeConfig = (config) =>
|
|
1319
|
+
const writeConfig = (config) => decodeAndRun(JsonObjectSchema, config, (decodedConfig) => requestJson(OkResponseSchema, {
|
|
1398
1320
|
body: {
|
|
1399
1321
|
type: "json",
|
|
1400
1322
|
value: { config: decodedConfig }
|
|
1401
1323
|
},
|
|
1402
1324
|
method: "PUT",
|
|
1403
1325
|
path: "/v2/config"
|
|
1404
|
-
}))
|
|
1405
|
-
const getConfigKey = (key) =>
|
|
1326
|
+
}));
|
|
1327
|
+
const getConfigKey = (key) => decodeAndRun(ConfigKeySchema, key, (decodedKey) => requestJson(ConfigValueEnvelopeSchema, {
|
|
1406
1328
|
method: "GET",
|
|
1407
1329
|
path: `/v2/config/${encodePathSegment(decodedKey)}`
|
|
1408
|
-
}))
|
|
1409
|
-
const getConfigKeyWith = (key, schema) =>
|
|
1330
|
+
})).pipe(selectJsonField("value"));
|
|
1331
|
+
const getConfigKeyWith = (key, schema) => decodeAndRun(ConfigKeySchema, key, (decodedKey) => requestJson(makeConfigValueEnvelopeSchema(JsonValueResponseSchema.pipe(Schema.decodeTo(schema))), {
|
|
1410
1332
|
method: "GET",
|
|
1411
1333
|
path: `/v2/config/${encodePathSegment(decodedKey)}`
|
|
1412
|
-
}))
|
|
1413
|
-
const setConfigKey = (key, value) =>
|
|
1334
|
+
})).pipe(Effect.map((envelope) => envelope["value"]));
|
|
1335
|
+
const setConfigKey = (key, value) => decodeAndRun(ConfigSetKeyInputSchema, {
|
|
1414
1336
|
key,
|
|
1415
1337
|
value
|
|
1416
|
-
}
|
|
1338
|
+
}, (decodedInput) => requestJson(OkResponseSchema, {
|
|
1417
1339
|
body: {
|
|
1418
1340
|
type: "json",
|
|
1419
1341
|
value: { value: decodedInput.value }
|
|
1420
1342
|
},
|
|
1421
1343
|
method: "PUT",
|
|
1422
1344
|
path: `/v2/config/${encodePathSegment(decodedInput.key)}`
|
|
1423
|
-
}))
|
|
1424
|
-
const deleteConfigKey = (key) =>
|
|
1345
|
+
}));
|
|
1346
|
+
const deleteConfigKey = (key) => decodeAndRun(ConfigKeySchema, key, (decodedKey) => requestJson(OkResponseSchema, {
|
|
1425
1347
|
method: "DELETE",
|
|
1426
1348
|
path: `/v2/config/${encodePathSegment(decodedKey)}`
|
|
1427
|
-
}))
|
|
1428
|
-
|
|
1429
|
-
//#region src/domains/download-links.ts
|
|
1349
|
+
}));
|
|
1350
|
+
// src/domains/download-links.ts
|
|
1430
1351
|
const DownloadLinksStatusSchema = Schema.Literals([
|
|
1431
1352
|
"NEW",
|
|
1432
1353
|
"PROCESSING",
|
|
1433
1354
|
"DONE",
|
|
1434
1355
|
"ERROR"
|
|
1435
1356
|
]);
|
|
1436
|
-
const DownloadLinksCreateInputSchema =
|
|
1357
|
+
const DownloadLinksCreateInputSchema = cursorSelectionSchema("ids", "excludeIds", {});
|
|
1437
1358
|
const DownloadLinksPayloadSchema = Schema.Struct({
|
|
1438
1359
|
download_links: Schema.Array(Schema.String),
|
|
1439
1360
|
media_links: Schema.Array(Schema.String),
|
|
@@ -1508,20 +1429,19 @@ const GetDownloadLinksErrorSpec = definePutioOperationErrorSpec({
|
|
|
1508
1429
|
{ statusCode: 404 }
|
|
1509
1430
|
]
|
|
1510
1431
|
});
|
|
1511
|
-
const createDownloadLinks = (input = {}) =>
|
|
1432
|
+
const createDownloadLinks = (input = {}) => decodeAndRun(DownloadLinksCreateInputSchema, input, (decodedInput) => requestJson(DownloadLinksCreateEnvelopeSchema, {
|
|
1512
1433
|
body: {
|
|
1513
1434
|
type: "form",
|
|
1514
1435
|
value: toCursorSelectionForm(decodedInput)
|
|
1515
1436
|
},
|
|
1516
1437
|
method: "POST",
|
|
1517
1438
|
path: "/v2/download_links/create"
|
|
1518
|
-
}))
|
|
1519
|
-
const getDownloadLinks = (id) =>
|
|
1439
|
+
})).pipe(selectJsonFields("id"), withOperationErrors(CreateDownloadLinksErrorSpec));
|
|
1440
|
+
const getDownloadLinks = (id) => decodeAndRun(PositiveIntegerSchema, id, (decodedId) => requestJson(DownloadLinksInfoSchema, {
|
|
1520
1441
|
method: "GET",
|
|
1521
1442
|
path: `/v2/download_links/${encodePathSegment(decodedId)}`
|
|
1522
|
-
}))
|
|
1523
|
-
|
|
1524
|
-
//#region src/domains/events.ts
|
|
1443
|
+
})).pipe(withOperationErrors(GetDownloadLinksErrorSpec));
|
|
1444
|
+
// src/domains/events.ts
|
|
1525
1445
|
const HistoryEventBaseSchema = Schema.Struct({
|
|
1526
1446
|
created_at: Schema.String,
|
|
1527
1447
|
id: Schema.Int,
|
|
@@ -1668,25 +1588,24 @@ const GetEventTorrentErrorSpec = definePutioOperationErrorSpec({
|
|
|
1668
1588
|
{ statusCode: 500 }
|
|
1669
1589
|
]
|
|
1670
1590
|
});
|
|
1671
|
-
const listEvents = (query = {}) =>
|
|
1591
|
+
const listEvents = (query = {}) => decodeAndRun(EventsListQuerySchema, query, (decodedQuery) => requestJson(EventsListEnvelopeSchema, {
|
|
1672
1592
|
method: "GET",
|
|
1673
1593
|
path: "/v2/events/list",
|
|
1674
1594
|
query: decodedQuery
|
|
1675
|
-
}))
|
|
1676
|
-
const deleteEvent = (id) =>
|
|
1595
|
+
})).pipe(withOperationErrors(ListEventsErrorSpec));
|
|
1596
|
+
const deleteEvent = (id) => decodeAndRun(PositiveIntegerSchema, id, (decodedId) => requestJson(OkResponseSchema, {
|
|
1677
1597
|
method: "POST",
|
|
1678
1598
|
path: `/v2/events/delete/${encodePathSegment(decodedId)}`
|
|
1679
|
-
}))
|
|
1599
|
+
})).pipe(withOperationErrors(DeleteEventErrorSpec));
|
|
1680
1600
|
const clearEvents = () => requestJson(OkResponseSchema, {
|
|
1681
1601
|
method: "POST",
|
|
1682
1602
|
path: "/v2/events/delete"
|
|
1683
1603
|
}).pipe(withOperationErrors(ClearEventsErrorSpec));
|
|
1684
|
-
const getEventTorrent = (id) =>
|
|
1604
|
+
const getEventTorrent = (id) => decodeAndRun(PositiveIntegerSchema, id, (decodedId) => requestArrayBuffer({
|
|
1685
1605
|
method: "GET",
|
|
1686
1606
|
path: `/v2/events/${encodePathSegment(decodedId)}/torrent`
|
|
1687
|
-
}))
|
|
1688
|
-
|
|
1689
|
-
//#region src/domains/family.ts
|
|
1607
|
+
})).pipe(withOperationErrors(GetEventTorrentErrorSpec));
|
|
1608
|
+
// src/domains/family.ts
|
|
1690
1609
|
const NonNegativeIntegerSchema = Schema.Int.check(Schema.isGreaterThanOrEqualTo(0));
|
|
1691
1610
|
const NonNegativeIntegerFromStringSchema = Schema.NumberFromString.check(Schema.isInt(), Schema.isGreaterThanOrEqualTo(0));
|
|
1692
1611
|
const FamilyInviteSchema = Schema.Struct({
|
|
@@ -1803,16 +1722,15 @@ const createFamilyInvite = () => requestJson(FamilyCreateInviteEnvelopeSchema, {
|
|
|
1803
1722
|
method: "POST",
|
|
1804
1723
|
path: "/v2/family/sub_account"
|
|
1805
1724
|
}).pipe(selectJsonFields("code"), withOperationErrors(CreateFamilyInviteErrorSpec));
|
|
1806
|
-
const removeFamilyMember = (username) =>
|
|
1725
|
+
const removeFamilyMember = (username) => decodeAndRun(NonEmptyStringSchema, username, (decodedUsername) => requestJson(OkResponseSchema, {
|
|
1807
1726
|
method: "DELETE",
|
|
1808
1727
|
path: `/v2/family/sub_account/${encodePathSegment(decodedUsername)}`
|
|
1809
|
-
}))
|
|
1810
|
-
const joinFamily = (inviteCode) =>
|
|
1728
|
+
})).pipe(Effect.asVoid, withOperationErrors(RemoveFamilyMemberErrorSpec));
|
|
1729
|
+
const joinFamily = (inviteCode) => decodeAndRun(NonEmptyStringSchema, inviteCode, (decodedInviteCode) => requestJson(OkResponseSchema, {
|
|
1811
1730
|
method: "POST",
|
|
1812
1731
|
path: `/v2/family/join/${encodePathSegment(decodedInviteCode)}`
|
|
1813
|
-
}))
|
|
1814
|
-
|
|
1815
|
-
//#region src/domains/ifttt.ts
|
|
1732
|
+
})).pipe(Effect.asVoid, withOperationErrors(JoinFamilyErrorSpec));
|
|
1733
|
+
// src/domains/ifttt.ts
|
|
1816
1734
|
const IFTTTStatusEnvelopeSchema = Schema.Struct({
|
|
1817
1735
|
enabled: Schema.Boolean,
|
|
1818
1736
|
status: Schema.Literal("OK")
|
|
@@ -1869,8 +1787,7 @@ const sendIftttEvent = (input) => decodeAndRun(IftttEventInputSchema, input, (de
|
|
|
1869
1787
|
method: "POST",
|
|
1870
1788
|
path: "/v2/ifttt-client/event"
|
|
1871
1789
|
})).pipe(Effect.asVoid, withOperationErrors(SendIftttEventErrorSpec));
|
|
1872
|
-
|
|
1873
|
-
//#region src/domains/files.ts
|
|
1790
|
+
// src/domains/files.ts
|
|
1874
1791
|
const RequestedFlag = Schema.Literal(1);
|
|
1875
1792
|
const NonNegativeFileIdSchema = Schema.Int.check(Schema.isGreaterThanOrEqualTo(0));
|
|
1876
1793
|
const SHARED_WITH_YOU_ROOT_ID = -2;
|
|
@@ -2030,14 +1947,7 @@ const FilesListEnvelopeSchema = Schema.Struct({
|
|
|
2030
1947
|
status: Schema.Literal("OK"),
|
|
2031
1948
|
total: Schema.optional(Schema.Int.check(Schema.isGreaterThanOrEqualTo(0)))
|
|
2032
1949
|
});
|
|
2033
|
-
const FilesListContinueEnvelopeSchema = Schema.
|
|
2034
|
-
breadcrumbs: Schema.optional(Schema.Array(FileBreadcrumbSchema)),
|
|
2035
|
-
cursor: Schema.NullOr(Schema.String),
|
|
2036
|
-
files: Schema.Array(FileBroadSchema),
|
|
2037
|
-
parent: Schema.optional(Schema.NullOr(FileBroadSchema)),
|
|
2038
|
-
status: Schema.Literal("OK"),
|
|
2039
|
-
total: Schema.optional(Schema.Int.check(Schema.isGreaterThanOrEqualTo(0)))
|
|
2040
|
-
});
|
|
1950
|
+
const FilesListContinueEnvelopeSchema = FilesListEnvelopeSchema.pipe(Schema.fieldsAssign({ parent: Schema.optional(Schema.NullOr(FileBroadSchema)) }));
|
|
2041
1951
|
const FilesSearchEnvelopeSchema = Schema.Struct({
|
|
2042
1952
|
cursor: Schema.NullOr(Schema.String),
|
|
2043
1953
|
files: Schema.Array(FileBroadSchema),
|
|
@@ -2056,10 +1966,6 @@ const FileGetInputSchema = Schema.Struct({
|
|
|
2056
1966
|
id: ReadableFileIdSchema,
|
|
2057
1967
|
query: Schema.optional(FileQuerySchema)
|
|
2058
1968
|
});
|
|
2059
|
-
const FilesSearchContinueInputSchema = Schema.Struct({
|
|
2060
|
-
cursor: NonEmptyStringSchema,
|
|
2061
|
-
query: Schema.Struct({ per_page: Schema.optional(PositiveIntegerSchema) })
|
|
2062
|
-
});
|
|
2063
1969
|
const FileSubtitlesInputSchema = Schema.Struct({
|
|
2064
1970
|
fileId: PositiveFileIdSchema,
|
|
2065
1971
|
options: Schema.Struct({ languages: Schema.optional(Schema.Array(NonEmptyStringSchema).check(Schema.isMinLength(1))) })
|
|
@@ -2222,8 +2128,8 @@ const FilesMoveSelectionInputSchema = Schema.Struct({
|
|
|
2222
2128
|
parentId: NonNegativeFileIdSchema,
|
|
2223
2129
|
selection: FilesBulkSelectionSchema
|
|
2224
2130
|
});
|
|
2225
|
-
const FilesWatchStatusInputSchema =
|
|
2226
|
-
const FilesExtractInputSchema =
|
|
2131
|
+
const FilesWatchStatusInputSchema = cursorSelectionSchema("ids", "excludeIds", { watched: Schema.Boolean });
|
|
2132
|
+
const FilesExtractInputSchema = cursorSelectionSchema("ids", "excludeIds", { password: Schema.optional(NonEmptyStringSchema) });
|
|
2227
2133
|
const FileUploadInputSchema = Schema.Struct({
|
|
2228
2134
|
file: Schema.instanceOf(Blob),
|
|
2229
2135
|
fileName: Schema.optional(NonEmptyStringSchema),
|
|
@@ -2561,13 +2467,11 @@ const FileUploadErrorSpec = definePutioOperationErrorSpec({
|
|
|
2561
2467
|
{ statusCode: 429 }
|
|
2562
2468
|
]
|
|
2563
2469
|
});
|
|
2564
|
-
const
|
|
2565
|
-
const failMissingField = (field) => Effect.fail(missingFieldError(field));
|
|
2566
|
-
const widenValidationError = (effect) => effect;
|
|
2470
|
+
const failMissingField = (field) => Effect.fail(new PutioValidationError({ cause: `Expected put.io to include "${field}" because it was requested` }));
|
|
2567
2471
|
const hasStreamUrl = (value) => "stream_url" in value;
|
|
2568
2472
|
const hasMp4StreamUrl = (value) => "mp4_stream_url" in value;
|
|
2569
2473
|
const hasMp4StreamUrlWhenAvailable = (value) => !value.is_mp4_available || hasMp4StreamUrl(value);
|
|
2570
|
-
const hasMp4StatusFields = (value) => "mp4_size" in value &&
|
|
2474
|
+
const hasMp4StatusFields = (value) => "mp4_size" in value && value.need_convert !== void 0;
|
|
2571
2475
|
const hasVideoMetadata = (value) => "video_metadata" in value;
|
|
2572
2476
|
const hasMediaMetadata = (value) => "media_metadata" in value;
|
|
2573
2477
|
const hasCodecs = (value) => "content_type_and_codecs" in value;
|
|
@@ -2585,19 +2489,19 @@ const resolveRouteContext = (token) => Effect.gen(function* () {
|
|
|
2585
2489
|
const resolveApiBaseUrl = Effect.gen(function* () {
|
|
2586
2490
|
return (yield* PutioSdkConfig).baseUrl ?? "https://api.put.io";
|
|
2587
2491
|
});
|
|
2588
|
-
const
|
|
2492
|
+
const toOriginalFlag = (playOriginal) => playOriginal === void 0 ? void 0 : playOriginal ? 1 : 0;
|
|
2589
2493
|
const toUploadResult = (value) => {
|
|
2590
|
-
if (value.file) return {
|
|
2494
|
+
if (value.file) return Effect.succeed({
|
|
2591
2495
|
file: value.file,
|
|
2592
2496
|
type: "file"
|
|
2593
|
-
};
|
|
2594
|
-
if (value.transfer) return {
|
|
2497
|
+
});
|
|
2498
|
+
if (value.transfer) return Effect.succeed({
|
|
2595
2499
|
transfer: value.transfer,
|
|
2596
2500
|
type: "transfer"
|
|
2597
|
-
};
|
|
2598
|
-
|
|
2501
|
+
});
|
|
2502
|
+
return Effect.fail(new PutioValidationError({ cause: "Expected put.io upload response to contain either \"file\" or \"transfer\"" }));
|
|
2599
2503
|
};
|
|
2600
|
-
const buildFileApiDownloadUrl = (baseUrl, fileId, options) => buildPutioUrl(baseUrl, options.name ? `/v2/files/${encodePathSegment(fileId)}/download/${
|
|
2504
|
+
const buildFileApiDownloadUrl = (baseUrl, fileId, options) => buildPutioUrl(baseUrl, options.name ? `/v2/files/${encodePathSegment(fileId)}/download/${encodePathSegment(options.name)}` : `/v2/files/${encodePathSegment(fileId)}/download`, {
|
|
2601
2505
|
...useTunnelToQuery(options.useTunnel),
|
|
2602
2506
|
oauth_token: options.downloadToken
|
|
2603
2507
|
});
|
|
@@ -2605,7 +2509,7 @@ const buildFileApiContentUrl = (baseUrl, fileId, options) => buildPutioUrl(baseU
|
|
|
2605
2509
|
...useTunnelToQuery(options.useTunnel),
|
|
2606
2510
|
oauth_token: options.downloadToken
|
|
2607
2511
|
});
|
|
2608
|
-
const buildFileApiMp4DownloadUrl = (baseUrl, fileId, options) => buildPutioUrl(baseUrl, options.name ? `/v2/files/${encodePathSegment(fileId)}/mp4/download/${
|
|
2512
|
+
const buildFileApiMp4DownloadUrl = (baseUrl, fileId, options) => buildPutioUrl(baseUrl, options.name ? `/v2/files/${encodePathSegment(fileId)}/mp4/download/${encodePathSegment(options.name)}` : `/v2/files/${encodePathSegment(fileId)}/mp4/download`, {
|
|
2609
2513
|
...useTunnelToQuery(options.useTunnel),
|
|
2610
2514
|
convert: options.convert ? 1 : void 0,
|
|
2611
2515
|
oauth_token: options.downloadToken
|
|
@@ -2613,7 +2517,7 @@ const buildFileApiMp4DownloadUrl = (baseUrl, fileId, options) => buildPutioUrl(b
|
|
|
2613
2517
|
const buildFileHlsStreamUrl = (baseUrl, fileId, options) => buildPutioUrl(baseUrl, `/v2/files/${encodePathSegment(fileId)}/hls/media.m3u8`, {
|
|
2614
2518
|
max_subtitle_count: options.maxSubtitleCount,
|
|
2615
2519
|
oauth_token: options.downloadToken,
|
|
2616
|
-
original:
|
|
2520
|
+
original: toOriginalFlag(options.playOriginal),
|
|
2617
2521
|
subtitle_languages: joinCsv(options.subtitleLanguages)
|
|
2618
2522
|
});
|
|
2619
2523
|
const buildFileXspfPlaylistUrl = (baseUrl, fileId, options) => buildPutioUrl(baseUrl, `/v2/files/${encodePathSegment(fileId)}/xspf`, { oauth_token: options.downloadToken });
|
|
@@ -2625,7 +2529,7 @@ const createFileUploadFormData = (input) => {
|
|
|
2625
2529
|
return formData;
|
|
2626
2530
|
};
|
|
2627
2531
|
const ensureFileQueryFields = (effect, query) => Effect.gen(function* () {
|
|
2628
|
-
const file = yield*
|
|
2532
|
+
const file = yield* effect;
|
|
2629
2533
|
if (query.stream_url === 1 && !hasStreamUrl(file)) return yield* failMissingField("stream_url");
|
|
2630
2534
|
if ((query.mp4_status === 1 || query.mp4_stream_url === 1) && !hasMp4StatusFields(file)) return yield* failMissingField(query.mp4_stream_url === 1 ? "mp4_size/need_convert" : "mp4_size");
|
|
2631
2535
|
if (query.mp4_stream_url === 1 && !hasMp4StreamUrlWhenAvailable(file)) return yield* failMissingField("mp4_stream_url");
|
|
@@ -2669,7 +2573,7 @@ function getFile(input) {
|
|
|
2669
2573
|
});
|
|
2670
2574
|
}
|
|
2671
2575
|
function getFileChild(input) {
|
|
2672
|
-
return
|
|
2576
|
+
return decodeAndRun(FileGetChildInputSchema, input, (decodedInput) => {
|
|
2673
2577
|
const effect = requestJson(FileEnvelopeSchema, {
|
|
2674
2578
|
method: "GET",
|
|
2675
2579
|
path: `/v2/files/${encodePathSegment(decodedInput.parentId)}/child`,
|
|
@@ -2679,9 +2583,9 @@ function getFileChild(input) {
|
|
|
2679
2583
|
}
|
|
2680
2584
|
}).pipe(selectJsonField("file"), withOperationErrors(GetFileChildErrorSpec));
|
|
2681
2585
|
return decodedInput.query === void 0 ? effect : ensureFileQueryFields(effect, decodedInput.query);
|
|
2682
|
-
})
|
|
2586
|
+
});
|
|
2683
2587
|
}
|
|
2684
|
-
const copyFile = (input) =>
|
|
2588
|
+
const copyFile = (input) => decodeAndRun(FileCopyInputSchema, input, (decodedInput) => requestJson(FileEnvelopeSchema, {
|
|
2685
2589
|
body: {
|
|
2686
2590
|
type: "form",
|
|
2687
2591
|
value: {
|
|
@@ -2692,8 +2596,8 @@ const copyFile = (input) => Schema.decodeUnknownEffect(FileCopyInputSchema, { on
|
|
|
2692
2596
|
},
|
|
2693
2597
|
method: "POST",
|
|
2694
2598
|
path: "/v2/files/copy"
|
|
2695
|
-
}))
|
|
2696
|
-
const touchFiles = (input) =>
|
|
2599
|
+
})).pipe(selectJsonField("file"), withOperationErrors(CopyFileErrorSpec));
|
|
2600
|
+
const touchFiles = (input) => decodeAndRun(FileTouchInputSchema, input, (decodedInput) => requestJson(OkResponseSchema, {
|
|
2697
2601
|
body: {
|
|
2698
2602
|
type: "form",
|
|
2699
2603
|
value: {
|
|
@@ -2703,17 +2607,17 @@ const touchFiles = (input) => Schema.decodeUnknownEffect(FileTouchInputSchema, {
|
|
|
2703
2607
|
},
|
|
2704
2608
|
method: "POST",
|
|
2705
2609
|
path: "/v2/files/touch"
|
|
2706
|
-
}))
|
|
2707
|
-
const canWriteFile = (fileId) =>
|
|
2610
|
+
})).pipe(Effect.asVoid, withOperationErrors(TouchFilesErrorSpec));
|
|
2611
|
+
const canWriteFile = (fileId) => decodeAndRun(PositiveFileIdSchema, fileId, (decodedFileId) => requestJson(FileCanWriteEnvelopeSchema, {
|
|
2708
2612
|
method: "GET",
|
|
2709
2613
|
path: `/v2/files/${encodePathSegment(decodedFileId)}/can-write`
|
|
2710
|
-
}))
|
|
2711
|
-
const searchFiles = (query) =>
|
|
2614
|
+
})).pipe(selectJsonField("user_id"), withOperationErrors(CanWriteFileErrorSpec));
|
|
2615
|
+
const searchFiles = (query) => decodeAndRun(FilesSearchQuerySchema, query, (decodedQuery) => requestJson(FilesSearchEnvelopeSchema, {
|
|
2712
2616
|
method: "GET",
|
|
2713
2617
|
path: "/v2/files/search",
|
|
2714
2618
|
query: decodedQuery
|
|
2715
|
-
}))
|
|
2716
|
-
const continueSearch = (cursor, query = {}) => decodeAndRun(
|
|
2619
|
+
})).pipe(withOperationErrors(SearchFilesErrorSpec));
|
|
2620
|
+
const continueSearch = (cursor, query = {}) => decodeAndRun(FilesContinueInputSchema, {
|
|
2717
2621
|
cursor,
|
|
2718
2622
|
query
|
|
2719
2623
|
}, (decodedInput) => requestJson(FilesSearchEnvelopeSchema, {
|
|
@@ -2725,7 +2629,7 @@ const continueSearch = (cursor, query = {}) => decodeAndRun(FilesSearchContinueI
|
|
|
2725
2629
|
path: "/v2/files/search/continue",
|
|
2726
2630
|
query: decodedInput.query
|
|
2727
2631
|
})).pipe(withOperationErrors(SearchFilesErrorSpec));
|
|
2728
|
-
const setFileSort = (input) =>
|
|
2632
|
+
const setFileSort = (input) => decodeAndRun(FileSetSortInputSchema, input, (decodedInput) => requestJson(OkResponseSchema, {
|
|
2729
2633
|
body: {
|
|
2730
2634
|
type: "form",
|
|
2731
2635
|
value: {
|
|
@@ -2735,7 +2639,7 @@ const setFileSort = (input) => Schema.decodeUnknownEffect(FileSetSortInputSchema
|
|
|
2735
2639
|
},
|
|
2736
2640
|
method: "POST",
|
|
2737
2641
|
path: "/v2/files/set-sort-by"
|
|
2738
|
-
}))
|
|
2642
|
+
})).pipe(Effect.asVoid);
|
|
2739
2643
|
const resetFileSortSettings = () => requestJson(OkResponseSchema, {
|
|
2740
2644
|
method: "POST",
|
|
2741
2645
|
path: "/v2/files/remove-sort-by-settings"
|
|
@@ -2877,7 +2781,7 @@ const getHlsMasterPlaylist = (fileId, options = {}) => decodeAndRun(Schema.Struc
|
|
|
2877
2781
|
path: `/v2/files/${encodePathSegment(decoded.fileId)}/hls/media.m3u8`,
|
|
2878
2782
|
query: {
|
|
2879
2783
|
max_subtitle_count: decoded.options.maxSubtitleCount,
|
|
2880
|
-
original:
|
|
2784
|
+
original: toOriginalFlag(decoded.options.playOriginal),
|
|
2881
2785
|
subtitle_languages: joinCsv(decoded.options.subtitleLanguages)
|
|
2882
2786
|
}
|
|
2883
2787
|
})).pipe(withOperationErrors(GetHlsMasterPlaylistErrorSpec));
|
|
@@ -3013,9 +2917,8 @@ const uploadFile = (input, options = {}) => decodeAndRun(Schema.Struct({
|
|
|
3013
2917
|
method: "POST",
|
|
3014
2918
|
path: "/v2/files/upload",
|
|
3015
2919
|
query: { oauth_token: token }
|
|
3016
|
-
})))).pipe(Effect.
|
|
3017
|
-
|
|
3018
|
-
//#region src/domains/friend-invites.ts
|
|
2920
|
+
})))).pipe(Effect.flatMap(toUploadResult), withOperationErrors(FileUploadErrorSpec));
|
|
2921
|
+
// src/domains/friend-invites.ts
|
|
3019
2922
|
const FriendInviteJoinedUserStatusSchema = Schema.Literals([
|
|
3020
2923
|
"CONVERTED",
|
|
3021
2924
|
"IN_TRIAL",
|
|
@@ -3079,8 +2982,7 @@ const createFriendInvite = () => requestJson(FriendInviteCreateEnvelopeSchema, {
|
|
|
3079
2982
|
method: "POST",
|
|
3080
2983
|
path: "/v2/account/create_friend_invitation"
|
|
3081
2984
|
}).pipe(selectJsonFields("code"), withOperationErrors(CreateFriendInviteErrorSpec));
|
|
3082
|
-
|
|
3083
|
-
//#region src/domains/friends.ts
|
|
2985
|
+
// src/domains/friends.ts
|
|
3084
2986
|
const FriendBaseSchema = Schema.Struct({
|
|
3085
2987
|
avatar_url: Schema.String,
|
|
3086
2988
|
id: Schema.Int.check(Schema.isGreaterThanOrEqualTo(0)),
|
|
@@ -3227,15 +3129,14 @@ const FriendSharedFolderErrorSpec = definePutioOperationErrorSpec({
|
|
|
3227
3129
|
{ statusCode: 404 }
|
|
3228
3130
|
]
|
|
3229
3131
|
});
|
|
3230
|
-
const decodeUsername = (username) => Schema.decodeUnknownEffect(NonEmptyStringSchema)(username).pipe(Effect.mapError(mapDecodeErrorToValidationError));
|
|
3231
3132
|
const listFriends = () => requestJson(FriendsListEnvelopeSchema, {
|
|
3232
3133
|
method: "GET",
|
|
3233
3134
|
path: "/v2/friends/list"
|
|
3234
3135
|
}).pipe(selectJsonFields("friends", "total"), withOperationErrors(ListFriendsErrorSpec));
|
|
3235
|
-
const searchFriends = (username) =>
|
|
3136
|
+
const searchFriends = (username) => decodeAndRun(NonEmptyStringSchema, username, (decodedUsername) => requestJson(FriendSearchEnvelopeSchema, {
|
|
3236
3137
|
method: "GET",
|
|
3237
3138
|
path: `/v2/friends/user-search/${encodePathSegment(decodedUsername)}`
|
|
3238
|
-
}))
|
|
3139
|
+
})).pipe(selectJsonField("users"), withOperationErrors(SearchFriendsErrorSpec));
|
|
3239
3140
|
const listWaitingRequests = () => requestJson(FriendRequestsEnvelopeSchema, {
|
|
3240
3141
|
method: "GET",
|
|
3241
3142
|
path: "/v2/friends/waiting-requests"
|
|
@@ -3248,28 +3149,27 @@ const listSentRequests = () => requestJson(FriendRequestsEnvelopeSchema, {
|
|
|
3248
3149
|
method: "GET",
|
|
3249
3150
|
path: "/v2/friends/sent-requests"
|
|
3250
3151
|
}).pipe(selectJsonField("friends"), withOperationErrors(ListSentRequestsErrorSpec));
|
|
3251
|
-
const sendFriendRequest = (username) =>
|
|
3152
|
+
const sendFriendRequest = (username) => decodeAndRun(NonEmptyStringSchema, username, (decodedUsername) => requestJson(OkResponseSchema, {
|
|
3252
3153
|
method: "POST",
|
|
3253
3154
|
path: `/v2/friends/${encodePathSegment(decodedUsername)}/request`
|
|
3254
|
-
}))
|
|
3255
|
-
const removeFriend = (username) =>
|
|
3155
|
+
})).pipe(withOperationErrors(SendFriendRequestErrorSpec));
|
|
3156
|
+
const removeFriend = (username) => decodeAndRun(NonEmptyStringSchema, username, (decodedUsername) => requestJson(OkResponseSchema, {
|
|
3256
3157
|
method: "POST",
|
|
3257
3158
|
path: `/v2/friends/${encodePathSegment(decodedUsername)}/unfriend`
|
|
3258
|
-
}))
|
|
3259
|
-
const approveFriendRequest = (username) =>
|
|
3159
|
+
})).pipe(withOperationErrors(RemoveFriendErrorSpec));
|
|
3160
|
+
const approveFriendRequest = (username) => decodeAndRun(NonEmptyStringSchema, username, (decodedUsername) => requestJson(OkResponseSchema, {
|
|
3260
3161
|
method: "POST",
|
|
3261
3162
|
path: `/v2/friends/${encodePathSegment(decodedUsername)}/approve`
|
|
3262
|
-
}))
|
|
3263
|
-
const denyFriendRequest = (username) =>
|
|
3163
|
+
})).pipe(withOperationErrors(ApproveFriendRequestErrorSpec));
|
|
3164
|
+
const denyFriendRequest = (username) => decodeAndRun(NonEmptyStringSchema, username, (decodedUsername) => requestJson(OkResponseSchema, {
|
|
3264
3165
|
method: "POST",
|
|
3265
3166
|
path: `/v2/friends/${encodePathSegment(decodedUsername)}/deny`
|
|
3266
|
-
}))
|
|
3267
|
-
const getFriendSharedFolder = (username) =>
|
|
3167
|
+
})).pipe(withOperationErrors(DenyFriendRequestErrorSpec));
|
|
3168
|
+
const getFriendSharedFolder = (username) => decodeAndRun(NonEmptyStringSchema, username, (decodedUsername) => requestJson(FriendSharedFolderEnvelopeSchema, {
|
|
3268
3169
|
method: "GET",
|
|
3269
3170
|
path: `/v2/friends/${encodePathSegment(decodedUsername)}/files`
|
|
3270
|
-
}))
|
|
3271
|
-
|
|
3272
|
-
//#region src/domains/payment.ts
|
|
3171
|
+
})).pipe(selectJsonField("file"), withOperationErrors(FriendSharedFolderErrorSpec));
|
|
3172
|
+
// src/domains/payment.ts
|
|
3273
3173
|
const PaymentPlanTypeSchema = Schema.Literals(["onetime", "subscription"]);
|
|
3274
3174
|
const PaymentOptionPlanTypeSchema = Schema.Literals([
|
|
3275
3175
|
"onetime",
|
|
@@ -3864,7 +3764,7 @@ const listPaymentInvites = () => requestJson(PaymentInvitesEnvelopeSchema, {
|
|
|
3864
3764
|
}).pipe(selectJsonField("vouchers"), withOperationErrors(ListPaymentInvitesErrorSpec));
|
|
3865
3765
|
const previewPaymentChangePlan = (input) => decodeAndRun(PaymentChangePlanPreviewInputSchema, input, (decodedInput) => requestJson(PaymentChangePlanPreviewSchema, {
|
|
3866
3766
|
method: "GET",
|
|
3867
|
-
path: `/v2/payment/change_plan/${
|
|
3767
|
+
path: `/v2/payment/change_plan/${encodePathSegment(decodedInput.plan_path)}`,
|
|
3868
3768
|
query: {
|
|
3869
3769
|
coupon_code: decodedInput.coupon_code,
|
|
3870
3770
|
payment_type: decodedInput.payment_type
|
|
@@ -3879,12 +3779,12 @@ const submitPaymentChangePlan = (input) => decodeAndRun(PaymentChangePlanSubmitI
|
|
|
3879
3779
|
}
|
|
3880
3780
|
},
|
|
3881
3781
|
method: "POST",
|
|
3882
|
-
path: `/v2/payment/change_plan/${
|
|
3782
|
+
path: `/v2/payment/change_plan/${encodePathSegment(decodedInput.plan_path)}`,
|
|
3883
3783
|
query: { coupon_code: decodedInput.coupon_code }
|
|
3884
3784
|
})).pipe(withOperationErrors(SubmitPaymentChangePlanErrorSpec));
|
|
3885
3785
|
const confirmFastspringOrder = (reference) => decodeAndRun(NonEmptyStringSchema, reference, (decodedReference) => requestJson(PaymentFastspringConfirmEnvelopeSchema, {
|
|
3886
3786
|
method: "GET",
|
|
3887
|
-
path: `/v2/payment/fs-confirm/${
|
|
3787
|
+
path: `/v2/payment/fs-confirm/${encodePathSegment(decodedReference)}`
|
|
3888
3788
|
}).pipe(selectJsonField("confirmed"))).pipe(withOperationErrors(ConfirmFastspringOrderErrorSpec));
|
|
3889
3789
|
const stopPaymentSubscription = () => requestJson(OkResponseSchema, {
|
|
3890
3790
|
method: "POST",
|
|
@@ -3892,11 +3792,11 @@ const stopPaymentSubscription = () => requestJson(OkResponseSchema, {
|
|
|
3892
3792
|
}).pipe(Effect.asVoid, withOperationErrors(StopSubscriptionErrorSpec));
|
|
3893
3793
|
const getPaymentVoucherInfo = (code) => decodeAndRun(NonEmptyStringSchema, code, (decodedCode) => requestJson(PaymentVoucherInfoSchema, {
|
|
3894
3794
|
method: "GET",
|
|
3895
|
-
path: `/v2/payment/redeem_voucher/${
|
|
3795
|
+
path: `/v2/payment/redeem_voucher/${encodePathSegment(decodedCode)}`
|
|
3896
3796
|
})).pipe(withOperationErrors(GetPaymentVoucherInfoErrorSpec));
|
|
3897
3797
|
const redeemPaymentVoucher = (code) => decodeAndRun(NonEmptyStringSchema, code, (decodedCode) => requestJson(OkResponseSchema, {
|
|
3898
3798
|
method: "POST",
|
|
3899
|
-
path: `/v2/payment/redeem_voucher/${
|
|
3799
|
+
path: `/v2/payment/redeem_voucher/${encodePathSegment(decodedCode)}`
|
|
3900
3800
|
})).pipe(Effect.asVoid, withOperationErrors(RedeemPaymentVoucherErrorSpec));
|
|
3901
3801
|
const reportPayments = (paymentIds) => decodeAndRun(PaymentIdsSchema, paymentIds, (decodedPaymentIds) => requestJson(OkResponseSchema, {
|
|
3902
3802
|
body: {
|
|
@@ -3916,11 +3816,11 @@ const createPaddleWaitingPayment = (input) => decodeAndRun(PaymentPaddleWaitingP
|
|
|
3916
3816
|
})).pipe(Effect.asVoid, withOperationErrors(CreatePaddleWaitingPaymentErrorSpec));
|
|
3917
3817
|
const getPaddleBillingInvoiceUrl = (paymentId) => decodeAndRun(PositiveIntegerSchema, paymentId, (decodedPaymentId) => requestJson(PaymentPaddleBillingInvoiceEnvelopeSchema, {
|
|
3918
3818
|
method: "GET",
|
|
3919
|
-
path: `/v2/payment/methods/paddle_billing/invoice/${
|
|
3819
|
+
path: `/v2/payment/methods/paddle_billing/invoice/${encodePathSegment(decodedPaymentId)}`
|
|
3920
3820
|
}).pipe(selectJsonField("url"))).pipe(withOperationErrors(GetPaddleBillingInvoiceUrlErrorSpec));
|
|
3921
3821
|
const createPaddleBillingUpdatePaymentMethodTransaction = (userSubscriptionId) => decodeAndRun(PositiveIntegerSchema, userSubscriptionId, (decodedUserSubscriptionId) => requestJson(PaymentPaddleBillingUpdatePaymentMethodEnvelopeSchema, {
|
|
3922
3822
|
method: "GET",
|
|
3923
|
-
path: `/v2/payment/methods/paddle_billing/update_payment_method/${
|
|
3823
|
+
path: `/v2/payment/methods/paddle_billing/update_payment_method/${encodePathSegment(decodedUserSubscriptionId)}`
|
|
3924
3824
|
}).pipe(selectJsonField("transaction_id"))).pipe(withOperationErrors(CreatePaddleBillingUpdatePaymentMethodTransactionErrorSpec));
|
|
3925
3825
|
const createOpenNodeCharge = (planPath) => decodeAndRun(NonEmptyStringSchema, planPath, (decodedPlanPath) => requestJson(PaymentOpenNodeChargeEnvelopeSchema, {
|
|
3926
3826
|
body: {
|
|
@@ -3929,9 +3829,8 @@ const createOpenNodeCharge = (planPath) => decodeAndRun(NonEmptyStringSchema, pl
|
|
|
3929
3829
|
},
|
|
3930
3830
|
method: "POST",
|
|
3931
3831
|
path: "/v2/payment/methods/opennode/charge"
|
|
3932
|
-
}).pipe(selectJsonField("opennode"),
|
|
3933
|
-
|
|
3934
|
-
//#region src/domains/podcast.ts
|
|
3832
|
+
}).pipe(selectJsonField("opennode"), selectJsonField("checkout_url"))).pipe(withOperationErrors(CreateOpenNodeChargeErrorSpec));
|
|
3833
|
+
// src/domains/podcast.ts
|
|
3935
3834
|
const PodcastLinkTypeSchema = Schema.Literals([
|
|
3936
3835
|
"all",
|
|
3937
3836
|
"audio",
|
|
@@ -3953,16 +3852,15 @@ const PodcastLinksEnvelopeSchema = Schema.Struct({
|
|
|
3953
3852
|
status: Schema.Literal("OK"),
|
|
3954
3853
|
token: Schema.String
|
|
3955
3854
|
});
|
|
3956
|
-
const getPodcastLinks = (input) =>
|
|
3855
|
+
const getPodcastLinks = (input) => decodeAndRun(PodcastGetLinksInputSchema, input, (decodedInput) => requestJson(PodcastLinksEnvelopeSchema, {
|
|
3957
3856
|
method: "GET",
|
|
3958
3857
|
path: "/v2/podcast/links",
|
|
3959
3858
|
query: {
|
|
3960
3859
|
parent_id: decodedInput.parentId,
|
|
3961
3860
|
type: decodedInput.types ? joinCsv(decodedInput.types) : void 0
|
|
3962
3861
|
}
|
|
3963
|
-
}))
|
|
3964
|
-
|
|
3965
|
-
//#region src/domains/rss.ts
|
|
3862
|
+
})).pipe(selectJsonFields("links", "token"));
|
|
3863
|
+
// src/domains/rss.ts
|
|
3966
3864
|
const RssFeedSchema = Schema.Struct({
|
|
3967
3865
|
created_at: Schema.String,
|
|
3968
3866
|
delete_old_files: Schema.Boolean,
|
|
@@ -4236,74 +4134,68 @@ const toCreateBody = (params) => ({
|
|
|
4236
4134
|
unwanted_keywords: params.unwanted_keywords ?? ""
|
|
4237
4135
|
});
|
|
4238
4136
|
const toUpdateBody = (params) => ({
|
|
4239
|
-
|
|
4240
|
-
|
|
4241
|
-
keyword: params.keyword ?? void 0,
|
|
4242
|
-
parent_dir_id: params.parent_dir_id,
|
|
4243
|
-
rss_source_url: params.rss_source_url,
|
|
4244
|
-
title: params.title,
|
|
4245
|
-
unwanted_keywords: params.unwanted_keywords ?? ""
|
|
4137
|
+
...toCreateBody(params),
|
|
4138
|
+
delete_old_files: params.delete_old_files
|
|
4246
4139
|
});
|
|
4247
4140
|
const listRssFeeds = () => requestJson(RssFeedsEnvelopeSchema, {
|
|
4248
4141
|
method: "GET",
|
|
4249
4142
|
path: "/v2/rss/list"
|
|
4250
4143
|
}).pipe(selectJsonField("feeds"), withOperationErrors(ListRssFeedsErrorSpec));
|
|
4251
|
-
const getRssFeed = (id) =>
|
|
4144
|
+
const getRssFeed = (id) => decodeAndRun(PositiveIntegerSchema, id, (decodedId) => requestJson(RssFeedEnvelopeSchema, {
|
|
4252
4145
|
method: "GET",
|
|
4253
4146
|
path: `/v2/rss/${encodePathSegment(decodedId)}`
|
|
4254
|
-
}))
|
|
4255
|
-
const createRssFeed = (params) =>
|
|
4147
|
+
})).pipe(selectJsonField("feed"), withOperationErrors(GetRssFeedErrorSpec));
|
|
4148
|
+
const createRssFeed = (params) => decodeAndRun(RssFeedParamsSchema, params, (decodedParams) => requestJson(RssFeedEnvelopeSchema, {
|
|
4256
4149
|
body: {
|
|
4257
4150
|
type: "form",
|
|
4258
4151
|
value: toCreateBody(decodedParams)
|
|
4259
4152
|
},
|
|
4260
4153
|
method: "POST",
|
|
4261
4154
|
path: "/v2/rss/create"
|
|
4262
|
-
}))
|
|
4263
|
-
const updateRssFeed = (id, params) =>
|
|
4155
|
+
})).pipe(selectJsonField("feed"), withOperationErrors(CreateRssFeedErrorSpec));
|
|
4156
|
+
const updateRssFeed = (id, params) => decodeAndRun(RssFeedUpdateInputSchema, {
|
|
4264
4157
|
id,
|
|
4265
4158
|
params
|
|
4266
|
-
}
|
|
4159
|
+
}, (decodedInput) => requestJson(OkResponseSchema, {
|
|
4267
4160
|
body: {
|
|
4268
4161
|
type: "form",
|
|
4269
4162
|
value: toUpdateBody(decodedInput.params)
|
|
4270
4163
|
},
|
|
4271
4164
|
method: "POST",
|
|
4272
4165
|
path: `/v2/rss/${encodePathSegment(decodedInput.id)}`
|
|
4273
|
-
}))
|
|
4274
|
-
const pauseRssFeed = (id) =>
|
|
4166
|
+
})).pipe(withOperationErrors(UpdateRssFeedErrorSpec));
|
|
4167
|
+
const pauseRssFeed = (id) => decodeAndRun(PositiveIntegerSchema, id, (decodedId) => requestJson(OkResponseSchema, {
|
|
4275
4168
|
method: "POST",
|
|
4276
4169
|
path: `/v2/rss/${encodePathSegment(decodedId)}/pause`
|
|
4277
|
-
}))
|
|
4278
|
-
const resumeRssFeed = (id) =>
|
|
4170
|
+
})).pipe(withOperationErrors(PauseRssFeedErrorSpec));
|
|
4171
|
+
const resumeRssFeed = (id) => decodeAndRun(PositiveIntegerSchema, id, (decodedId) => requestJson(OkResponseSchema, {
|
|
4279
4172
|
method: "POST",
|
|
4280
4173
|
path: `/v2/rss/${encodePathSegment(decodedId)}/resume`
|
|
4281
|
-
}))
|
|
4282
|
-
const deleteRssFeed = (id) =>
|
|
4174
|
+
})).pipe(withOperationErrors(ResumeRssFeedErrorSpec));
|
|
4175
|
+
const deleteRssFeed = (id) => decodeAndRun(PositiveIntegerSchema, id, (decodedId) => requestJson(OkResponseSchema, {
|
|
4283
4176
|
method: "POST",
|
|
4284
4177
|
path: `/v2/rss/${encodePathSegment(decodedId)}/delete`
|
|
4285
|
-
}))
|
|
4286
|
-
const listRssFeedItems = (id) =>
|
|
4178
|
+
})).pipe(withOperationErrors(DeleteRssFeedErrorSpec));
|
|
4179
|
+
const listRssFeedItems = (id) => decodeAndRun(PositiveIntegerSchema, id, (decodedId) => requestJson(RssFeedItemsEnvelopeSchema, {
|
|
4287
4180
|
method: "GET",
|
|
4288
4181
|
path: `/v2/rss/${encodePathSegment(decodedId)}/items`
|
|
4289
|
-
}))
|
|
4290
|
-
const clearRssFeedLogs = (id) =>
|
|
4182
|
+
})).pipe(selectJsonFields("feed", "items"), withOperationErrors(ListRssFeedItemsErrorSpec));
|
|
4183
|
+
const clearRssFeedLogs = (id) => decodeAndRun(PositiveIntegerSchema, id, (decodedId) => requestJson(OkResponseSchema, {
|
|
4291
4184
|
method: "POST",
|
|
4292
4185
|
path: `/v2/rss/${encodePathSegment(decodedId)}/clear-log`
|
|
4293
|
-
}))
|
|
4294
|
-
const retryRssFeedItem = (feedId, itemId) =>
|
|
4186
|
+
})).pipe(withOperationErrors(ClearRssFeedLogsErrorSpec));
|
|
4187
|
+
const retryRssFeedItem = (feedId, itemId) => decodeAndRun(RssFeedItemRetryInputSchema, {
|
|
4295
4188
|
feedId,
|
|
4296
4189
|
itemId
|
|
4297
|
-
}
|
|
4190
|
+
}, (decodedInput) => requestJson(OkResponseSchema, {
|
|
4298
4191
|
method: "POST",
|
|
4299
4192
|
path: `/v2/rss/${encodePathSegment(decodedInput.feedId)}/items/${encodePathSegment(decodedInput.itemId)}/retry`
|
|
4300
|
-
}))
|
|
4301
|
-
const retryAllRssFeedItems = (feedId) =>
|
|
4193
|
+
})).pipe(withOperationErrors(RetryRssFeedItemErrorSpec));
|
|
4194
|
+
const retryAllRssFeedItems = (feedId) => decodeAndRun(PositiveIntegerSchema, feedId, (decodedFeedId) => requestJson(OkResponseSchema, {
|
|
4302
4195
|
method: "POST",
|
|
4303
4196
|
path: `/v2/rss/${encodePathSegment(decodedFeedId)}/retry-all`
|
|
4304
|
-
}))
|
|
4305
|
-
|
|
4306
|
-
//#region src/domains/sharing.ts
|
|
4197
|
+
})).pipe(withOperationErrors(RetryAllRssFeedItemsErrorSpec));
|
|
4198
|
+
// src/domains/sharing.ts
|
|
4307
4199
|
const SharingCloneStatusSchema = Schema.Literals([
|
|
4308
4200
|
"NEW",
|
|
4309
4201
|
"PROCESSING",
|
|
@@ -4384,22 +4276,7 @@ const PublicSharesEnvelopeSchema = Schema.Struct({
|
|
|
4384
4276
|
public_shares: Schema.Array(PublicShareSchema),
|
|
4385
4277
|
status: Schema.optional(Schema.Literal("OK"))
|
|
4386
4278
|
});
|
|
4387
|
-
const
|
|
4388
|
-
breadcrumbs: Schema.optional(Schema.Array(Schema.Tuple([Schema.Int, Schema.String]))),
|
|
4389
|
-
cursor: Schema.NullOr(Schema.String),
|
|
4390
|
-
files: Schema.Array(FileBroadSchema),
|
|
4391
|
-
parent: Schema.NullOr(FileBroadSchema),
|
|
4392
|
-
status: Schema.Literal("OK"),
|
|
4393
|
-
total: Schema.optional(Schema.Int.check(Schema.isGreaterThanOrEqualTo(0)))
|
|
4394
|
-
});
|
|
4395
|
-
const PublicShareFileListContinueEnvelopeSchema = Schema.Struct({
|
|
4396
|
-
breadcrumbs: Schema.optional(Schema.Array(Schema.Tuple([Schema.Int, Schema.String]))),
|
|
4397
|
-
cursor: Schema.NullOr(Schema.String),
|
|
4398
|
-
files: Schema.Array(FileBroadSchema),
|
|
4399
|
-
parent: Schema.optional(Schema.NullOr(FileBroadSchema)),
|
|
4400
|
-
status: Schema.Literal("OK"),
|
|
4401
|
-
total: Schema.optional(Schema.Int.check(Schema.isGreaterThanOrEqualTo(0)))
|
|
4402
|
-
});
|
|
4279
|
+
const PublicShareFileListContinueEnvelopeSchema = FilesListEnvelopeSchema.pipe(Schema.fieldsAssign({ parent: Schema.optional(Schema.NullOr(FileBroadSchema)) }));
|
|
4403
4280
|
const PublicShareFileUrlEnvelopeSchema = Schema.Struct({
|
|
4404
4281
|
status: Schema.optional(Schema.Literal("OK")),
|
|
4405
4282
|
url: Schema.String
|
|
@@ -4617,7 +4494,7 @@ const GetPublicShareFileUrlErrorSpec = definePutioOperationErrorSpec({
|
|
|
4617
4494
|
]
|
|
4618
4495
|
});
|
|
4619
4496
|
const toShareTarget = (target) => target.type === "everyone" ? "everyone" : target.friendNames.join(",");
|
|
4620
|
-
const cloneSharedFiles = (input = {}) =>
|
|
4497
|
+
const cloneSharedFiles = (input = {}) => decodeAndRun(SharingCloneInputSchema, input, (decodedInput) => requestJson(SharingCloneEnvelopeSchema, {
|
|
4621
4498
|
body: {
|
|
4622
4499
|
type: "form",
|
|
4623
4500
|
value: {
|
|
@@ -4627,12 +4504,12 @@ const cloneSharedFiles = (input = {}) => Schema.decodeUnknownEffect(SharingClone
|
|
|
4627
4504
|
},
|
|
4628
4505
|
method: "POST",
|
|
4629
4506
|
path: "/v2/sharing/clone"
|
|
4630
|
-
}))
|
|
4631
|
-
const getSharingCloneInfo = (id) =>
|
|
4507
|
+
})).pipe(selectJsonFields("id"), withOperationErrors(CreateSharingCloneErrorSpec));
|
|
4508
|
+
const getSharingCloneInfo = (id) => decodeAndRun(PositiveIntegerSchema, id, (decodedId) => requestJson(SharingCloneInfoSchema, {
|
|
4632
4509
|
method: "GET",
|
|
4633
4510
|
path: `/v2/sharing/clone/${encodePathSegment(decodedId)}`
|
|
4634
|
-
}))
|
|
4635
|
-
const shareFiles = (input) =>
|
|
4511
|
+
})).pipe(withOperationErrors(GetSharingCloneInfoErrorSpec));
|
|
4512
|
+
const shareFiles = (input) => decodeAndRun(SharingShareInputSchema, input, (decodedInput) => requestJson(OkResponseSchema, {
|
|
4636
4513
|
body: {
|
|
4637
4514
|
type: "form",
|
|
4638
4515
|
value: {
|
|
@@ -4642,48 +4519,48 @@ const shareFiles = (input) => Schema.decodeUnknownEffect(SharingShareInputSchema
|
|
|
4642
4519
|
},
|
|
4643
4520
|
method: "POST",
|
|
4644
4521
|
path: "/v2/files/share"
|
|
4645
|
-
}))
|
|
4522
|
+
})).pipe(withOperationErrors(ShareFilesErrorSpec));
|
|
4646
4523
|
const listSharedFiles = () => requestJson(SharedFilesEnvelopeSchema, {
|
|
4647
4524
|
method: "GET",
|
|
4648
4525
|
path: "/v2/files/shared"
|
|
4649
4526
|
}).pipe(selectJsonField("shared"), withOperationErrors(ListSharedFilesErrorSpec));
|
|
4650
|
-
const getSharedWith = (fileId) =>
|
|
4527
|
+
const getSharedWith = (fileId) => decodeAndRun(PositiveIntegerSchema, fileId, (decodedFileId) => requestJson(SharedFileSharedWithSchema, {
|
|
4651
4528
|
method: "GET",
|
|
4652
4529
|
path: `/v2/files/${encodePathSegment(decodedFileId)}/shared-with-v2`
|
|
4653
|
-
}))
|
|
4654
|
-
const unshareFile = (input) =>
|
|
4530
|
+
})).pipe(withOperationErrors(GetSharedWithErrorSpec));
|
|
4531
|
+
const unshareFile = (input) => decodeAndRun(SharingUnshareInputSchema, input, (decodedInput) => requestJson(OkResponseSchema, {
|
|
4655
4532
|
body: {
|
|
4656
4533
|
type: "form",
|
|
4657
4534
|
value: { shares: joinCsv(decodedInput.shares) ?? "everyone" }
|
|
4658
4535
|
},
|
|
4659
4536
|
method: "POST",
|
|
4660
4537
|
path: `/v2/files/${encodePathSegment(decodedInput.fileId)}/unshare`
|
|
4661
|
-
}))
|
|
4662
|
-
const createPublicShare = (fileId) =>
|
|
4538
|
+
})).pipe(withOperationErrors(UnshareFileErrorSpec));
|
|
4539
|
+
const createPublicShare = (fileId) => decodeAndRun(PositiveIntegerSchema, fileId, (decodedFileId) => requestJson(PublicShareEnvelopeSchema, {
|
|
4663
4540
|
method: "POST",
|
|
4664
4541
|
path: `/v2/public_share/${encodePathSegment(decodedFileId)}`
|
|
4665
|
-
}))
|
|
4542
|
+
})).pipe(selectJsonField("public_share"), withOperationErrors(CreatePublicShareErrorSpec));
|
|
4666
4543
|
const listPublicShares = () => requestJson(PublicSharesEnvelopeSchema, {
|
|
4667
4544
|
method: "GET",
|
|
4668
4545
|
path: "/v2/public_share/list"
|
|
4669
4546
|
}).pipe(selectJsonField("public_shares"), withOperationErrors(ListPublicSharesErrorSpec));
|
|
4670
|
-
const deletePublicShare = (id) =>
|
|
4547
|
+
const deletePublicShare = (id) => decodeAndRun(PositiveIntegerSchema, id, (decodedId) => requestJson(OkResponseSchema, {
|
|
4671
4548
|
method: "DELETE",
|
|
4672
4549
|
path: `/v2/public_share/${encodePathSegment(decodedId)}`
|
|
4673
|
-
}))
|
|
4550
|
+
})).pipe(withOperationErrors(DeletePublicShareErrorSpec));
|
|
4674
4551
|
const getPublicShare = () => requestJson(PublicShareEnvelopeSchema, {
|
|
4675
4552
|
method: "GET",
|
|
4676
4553
|
path: "/v2/public_share"
|
|
4677
4554
|
}).pipe(selectJsonField("public_share"), withOperationErrors(GetPublicShareErrorSpec));
|
|
4678
|
-
const listPublicShareFiles = (query = {}) =>
|
|
4555
|
+
const listPublicShareFiles = (query = {}) => decodeAndRun(PublicShareListQuerySchema, query, (decodedQuery) => requestJson(FilesListEnvelopeSchema, {
|
|
4679
4556
|
method: "GET",
|
|
4680
4557
|
path: "/v2/public_share/files/list",
|
|
4681
4558
|
query: decodedQuery
|
|
4682
|
-
}))
|
|
4683
|
-
const continuePublicShareFiles = (cursor, query = {}) =>
|
|
4559
|
+
})).pipe(withOperationErrors(ListPublicShareFilesErrorSpec));
|
|
4560
|
+
const continuePublicShareFiles = (cursor, query = {}) => decodeAndRun(PublicShareContinueInputSchema, {
|
|
4684
4561
|
cursor,
|
|
4685
4562
|
query
|
|
4686
|
-
}
|
|
4563
|
+
}, (decodedInput) => requestJson(PublicShareFileListContinueEnvelopeSchema, {
|
|
4687
4564
|
body: {
|
|
4688
4565
|
type: "form",
|
|
4689
4566
|
value: { cursor: decodedInput.cursor }
|
|
@@ -4691,13 +4568,12 @@ const continuePublicShareFiles = (cursor, query = {}) => Schema.decodeUnknownEff
|
|
|
4691
4568
|
method: "POST",
|
|
4692
4569
|
path: "/v2/public_share/files/list/continue",
|
|
4693
4570
|
query: decodedInput.query
|
|
4694
|
-
}))
|
|
4695
|
-
const getPublicShareFileUrl = (fileId) =>
|
|
4571
|
+
})).pipe(withOperationErrors(ContinuePublicShareFilesErrorSpec));
|
|
4572
|
+
const getPublicShareFileUrl = (fileId) => decodeAndRun(PositiveIntegerSchema, fileId, (decodedFileId) => requestJson(PublicShareFileUrlEnvelopeSchema, {
|
|
4696
4573
|
method: "GET",
|
|
4697
4574
|
path: `/v2/public_share/files/${encodePathSegment(decodedFileId)}/url`
|
|
4698
|
-
}))
|
|
4699
|
-
|
|
4700
|
-
//#region src/domains/trash.ts
|
|
4575
|
+
})).pipe(selectJsonField("url"), withOperationErrors(GetPublicShareFileUrlErrorSpec));
|
|
4576
|
+
// src/domains/trash.ts
|
|
4701
4577
|
const TrashFileSchema = Schema.Struct({
|
|
4702
4578
|
content_type: Schema.NullOr(Schema.String),
|
|
4703
4579
|
created_at: Schema.String,
|
|
@@ -4742,23 +4618,19 @@ const TrashContinueInputSchema = Schema.Struct({
|
|
|
4742
4618
|
cursor: NonEmptyStringSchema,
|
|
4743
4619
|
query: TrashListQuerySchema
|
|
4744
4620
|
});
|
|
4745
|
-
const
|
|
4746
|
-
errorType: "invalid_scope",
|
|
4747
|
-
statusCode: 401
|
|
4748
|
-
};
|
|
4749
|
-
const RestrictedWriteError = {
|
|
4621
|
+
const RestrictedScopeError$1 = {
|
|
4750
4622
|
errorType: "invalid_scope",
|
|
4751
4623
|
statusCode: 401
|
|
4752
4624
|
};
|
|
4753
4625
|
const ListTrashErrorSpec = definePutioOperationErrorSpec({
|
|
4754
4626
|
domain: "trash",
|
|
4755
4627
|
operation: "list",
|
|
4756
|
-
knownErrors: [
|
|
4628
|
+
knownErrors: [RestrictedScopeError$1]
|
|
4757
4629
|
});
|
|
4758
4630
|
const ContinueTrashErrorSpec = definePutioOperationErrorSpec({
|
|
4759
4631
|
domain: "trash",
|
|
4760
4632
|
operation: "continue",
|
|
4761
|
-
knownErrors: [
|
|
4633
|
+
knownErrors: [RestrictedScopeError$1, { statusCode: 400 }]
|
|
4762
4634
|
});
|
|
4763
4635
|
const RestoreTrashErrorSpec = definePutioOperationErrorSpec({
|
|
4764
4636
|
domain: "trash",
|
|
@@ -4780,7 +4652,7 @@ const RestoreTrashErrorSpec = definePutioOperationErrorSpec({
|
|
|
4780
4652
|
errorType: "TRASH_RESTORE_TOO_MANY_FILES",
|
|
4781
4653
|
statusCode: 400
|
|
4782
4654
|
},
|
|
4783
|
-
|
|
4655
|
+
RestrictedScopeError$1,
|
|
4784
4656
|
{ statusCode: 400 },
|
|
4785
4657
|
{ statusCode: 404 }
|
|
4786
4658
|
]
|
|
@@ -4797,7 +4669,7 @@ const DeleteTrashErrorSpec = definePutioOperationErrorSpec({
|
|
|
4797
4669
|
errorType: "TRASH_LOCK_TIMEOUT",
|
|
4798
4670
|
statusCode: 400
|
|
4799
4671
|
},
|
|
4800
|
-
|
|
4672
|
+
RestrictedScopeError$1,
|
|
4801
4673
|
{ statusCode: 400 },
|
|
4802
4674
|
{ statusCode: 404 }
|
|
4803
4675
|
]
|
|
@@ -4808,7 +4680,7 @@ const EmptyTrashErrorSpec = definePutioOperationErrorSpec({
|
|
|
4808
4680
|
knownErrors: [{
|
|
4809
4681
|
errorType: "TRASH_LOCK_TIMEOUT",
|
|
4810
4682
|
statusCode: 400
|
|
4811
|
-
},
|
|
4683
|
+
}, RestrictedScopeError$1]
|
|
4812
4684
|
});
|
|
4813
4685
|
const toBulkTrashBody = (input) => {
|
|
4814
4686
|
if (input.useCursor === true) return {
|
|
@@ -4857,8 +4729,7 @@ const emptyTrash = () => requestJson(OkResponseSchema, {
|
|
|
4857
4729
|
method: "POST",
|
|
4858
4730
|
path: "/v2/trash/empty"
|
|
4859
4731
|
}).pipe(Effect.asVoid, withOperationErrors(EmptyTrashErrorSpec));
|
|
4860
|
-
|
|
4861
|
-
//#region src/domains/transfers.ts
|
|
4732
|
+
// src/domains/transfers.ts
|
|
4862
4733
|
const TransferIdSchema = PositiveIntegerSchema;
|
|
4863
4734
|
const TransferIdsSchema = Schema.Array(TransferIdSchema).check(Schema.isMinLength(1));
|
|
4864
4735
|
const TransferTypeSchema = Schema.Literals([
|
|
@@ -5298,8 +5169,7 @@ const stopTransferRecording = (id) => decodeAndRun(TransferIdSchema, id, (decode
|
|
|
5298
5169
|
method: "POST",
|
|
5299
5170
|
path: "/v2/transfers/stop-recording"
|
|
5300
5171
|
})).pipe(withOperationErrors(StopRecordingTransferErrorSpec));
|
|
5301
|
-
|
|
5302
|
-
//#region src/domains/rate-limits.ts
|
|
5172
|
+
// src/domains/rate-limits.ts
|
|
5303
5173
|
const RemoveRateLimitBanInputSchema = Schema.Struct({
|
|
5304
5174
|
captchaToken: NonEmptyStringSchema,
|
|
5305
5175
|
id: NonEmptyStringSchema
|
|
@@ -5338,8 +5208,7 @@ const removeRateLimitBan = (input) => Schema.decodeUnknownEffect(RemoveRateLimit
|
|
|
5338
5208
|
method: "DELETE",
|
|
5339
5209
|
path: `/v2/ban/${encodePathSegment(id)}`
|
|
5340
5210
|
})), withOperationErrors(RemoveRateLimitBanErrorSpec));
|
|
5341
|
-
|
|
5342
|
-
//#region src/domains/tunnel.ts
|
|
5211
|
+
// src/domains/tunnel.ts
|
|
5343
5212
|
const TunnelRouteSchema = Schema.Struct({
|
|
5344
5213
|
description: Schema.String,
|
|
5345
5214
|
hosts: Schema.Array(Schema.String),
|
|
@@ -5361,8 +5230,7 @@ const listTunnelRoutes = () => requestJson(TunnelRoutesEnvelopeSchema, {
|
|
|
5361
5230
|
method: "GET",
|
|
5362
5231
|
path: "/v2/tunnel/routes"
|
|
5363
5232
|
}).pipe(selectJsonField("routes"), withOperationErrors(ListTunnelRoutesErrorSpec));
|
|
5364
|
-
|
|
5365
|
-
//#region src/domains/zips.ts
|
|
5233
|
+
// src/domains/zips.ts
|
|
5366
5234
|
const ZipStatusSchema = Schema.Literals([
|
|
5367
5235
|
"NEW",
|
|
5368
5236
|
"PROCESSING",
|
|
@@ -5410,19 +5278,19 @@ const ZipInfoSchema = Schema.Union([
|
|
|
5410
5278
|
ZipInfoErrorSchema,
|
|
5411
5279
|
ZipInfoDoneSchema
|
|
5412
5280
|
]);
|
|
5413
|
-
const CreateZipInputSchema =
|
|
5414
|
-
|
|
5415
|
-
|
|
5416
|
-
|
|
5417
|
-
};
|
|
5418
|
-
const
|
|
5281
|
+
const CreateZipInputSchema = Schema.Struct({
|
|
5282
|
+
cursor: Schema.optional(NonEmptyStringSchema),
|
|
5283
|
+
exclude_ids: Schema.optional(Schema.Array(PositiveIntegerSchema)),
|
|
5284
|
+
file_ids: Schema.optional(Schema.Array(PositiveIntegerSchema).check(Schema.isMinLength(1)))
|
|
5285
|
+
}).check(Schema.makeFilter((input) => input.cursor !== void 0 || input.file_ids !== void 0, { expected: "a non-empty cursor or file ID selection" }));
|
|
5286
|
+
const RestrictedScopeError = {
|
|
5419
5287
|
errorType: "invalid_scope",
|
|
5420
5288
|
statusCode: 401
|
|
5421
5289
|
};
|
|
5422
5290
|
const ListZipsErrorSpec = definePutioOperationErrorSpec({
|
|
5423
5291
|
domain: "zips",
|
|
5424
5292
|
operation: "list",
|
|
5425
|
-
knownErrors: [
|
|
5293
|
+
knownErrors: [RestrictedScopeError]
|
|
5426
5294
|
});
|
|
5427
5295
|
const CreateZipErrorSpec = definePutioOperationErrorSpec({
|
|
5428
5296
|
domain: "zips",
|
|
@@ -5432,7 +5300,7 @@ const CreateZipErrorSpec = definePutioOperationErrorSpec({
|
|
|
5432
5300
|
errorType: "ZIP_TOTAL_SIZE_EXCEEDED",
|
|
5433
5301
|
statusCode: 403
|
|
5434
5302
|
},
|
|
5435
|
-
|
|
5303
|
+
RestrictedScopeError,
|
|
5436
5304
|
{ statusCode: 400 },
|
|
5437
5305
|
{ statusCode: 403 }
|
|
5438
5306
|
]
|
|
@@ -5449,7 +5317,7 @@ const GetZipErrorSpec = definePutioOperationErrorSpec({
|
|
|
5449
5317
|
errorType: "ERROR_IN_ZIP",
|
|
5450
5318
|
statusCode: 500
|
|
5451
5319
|
},
|
|
5452
|
-
|
|
5320
|
+
RestrictedScopeError,
|
|
5453
5321
|
{ statusCode: 403 },
|
|
5454
5322
|
{ statusCode: 410 },
|
|
5455
5323
|
{ statusCode: 500 }
|
|
@@ -5463,7 +5331,7 @@ const CancelZipErrorSpec = definePutioOperationErrorSpec({
|
|
|
5463
5331
|
errorType: "LINK_EXPIRED",
|
|
5464
5332
|
statusCode: 410
|
|
5465
5333
|
},
|
|
5466
|
-
|
|
5334
|
+
RestrictedScopeError,
|
|
5467
5335
|
{ statusCode: 403 },
|
|
5468
5336
|
{ statusCode: 410 }
|
|
5469
5337
|
]
|
|
@@ -5475,11 +5343,11 @@ const listZips = () => requestJson(ZipsListEnvelopeSchema, {
|
|
|
5475
5343
|
const createZip = (input) => decodeAndRun(CreateZipInputSchema, input, (decodedInput) => requestJson(ZipCreateEnvelopeSchema, {
|
|
5476
5344
|
body: {
|
|
5477
5345
|
type: "form",
|
|
5478
|
-
value:
|
|
5346
|
+
value: toCursorSelectionForm({
|
|
5479
5347
|
cursor: decodedInput.cursor,
|
|
5480
5348
|
excludeIds: decodedInput.exclude_ids,
|
|
5481
5349
|
ids: decodedInput.file_ids
|
|
5482
|
-
})
|
|
5350
|
+
})
|
|
5483
5351
|
},
|
|
5484
5352
|
method: "POST",
|
|
5485
5353
|
path: "/v2/zips/create"
|
|
@@ -5492,342 +5360,290 @@ const cancelZip = (id) => decodeAndRun(PositiveIntegerSchema, id, (decodedId) =>
|
|
|
5492
5360
|
method: "GET",
|
|
5493
5361
|
path: `/v2/zips/${encodePathSegment(decodedId)}/cancel`
|
|
5494
5362
|
})).pipe(Effect.asVoid, withOperationErrors(CancelZipErrorSpec));
|
|
5495
|
-
|
|
5496
|
-
//#region src/core/client.ts
|
|
5497
|
-
const promiseClientRuntimeCache = /* @__PURE__ */ new WeakMap();
|
|
5498
|
-
const disposedPromiseClientStates = /* @__PURE__ */ new WeakSet();
|
|
5363
|
+
// src/core/client.ts
|
|
5499
5364
|
const getPromiseClientRuntime = (state) => {
|
|
5500
|
-
if (
|
|
5501
|
-
|
|
5502
|
-
|
|
5503
|
-
const runtime = ManagedRuntime.make(makePutioSdkLiveLayer(state.runtimeConfig));
|
|
5504
|
-
promiseClientRuntimeCache.set(state, runtime);
|
|
5505
|
-
return runtime;
|
|
5365
|
+
if (state.disposed) throw mapConfigurationError("This Promise client has been disposed and can no longer execute SDK effects");
|
|
5366
|
+
state.runtime ??= ManagedRuntime.make(putioSdkLiveLayer(state.runtimeConfig));
|
|
5367
|
+
return state.runtime;
|
|
5506
5368
|
};
|
|
5507
5369
|
const disposePromiseClientRuntime = async (state) => {
|
|
5508
|
-
|
|
5509
|
-
|
|
5510
|
-
|
|
5511
|
-
|
|
5512
|
-
await runtime.dispose();
|
|
5370
|
+
const { runtime } = state;
|
|
5371
|
+
state.disposed = true;
|
|
5372
|
+
state.runtime = void 0;
|
|
5373
|
+
await runtime?.dispose();
|
|
5513
5374
|
};
|
|
5514
|
-
const
|
|
5515
|
-
|
|
5516
|
-
|
|
5517
|
-
|
|
5518
|
-
|
|
5519
|
-
return Promise.reject(Cause.squash(cause));
|
|
5520
|
-
}
|
|
5521
|
-
});
|
|
5522
|
-
const provideSdk = async (state, effect) => {
|
|
5523
|
-
const operationConfig = {
|
|
5524
|
-
...state.runtimeConfig,
|
|
5525
|
-
accessToken: state.accessToken
|
|
5526
|
-
};
|
|
5527
|
-
const operation = Effect.provideService(effect, PutioSdkConfig, operationConfig);
|
|
5528
|
-
return rejectWithSdkFailure(await getPromiseClientRuntime(state).runPromiseExit(operation));
|
|
5529
|
-
};
|
|
5530
|
-
const snapshotUrl = (value) => typeof value === "string" || value === void 0 ? value : new URL(value.href);
|
|
5375
|
+
const provideSdk = async (state, effect) => getPromiseClientRuntime(state).runPromise(Effect.provideService(effect, PutioSdkConfig, {
|
|
5376
|
+
...state.runtimeConfig,
|
|
5377
|
+
accessToken: state.accessToken
|
|
5378
|
+
}));
|
|
5379
|
+
const snapshotUrl = (value) => Predicate.isString(value) || value === void 0 ? value : new URL(value.href);
|
|
5531
5380
|
const snapshotHeaders = (value) => value === void 0 ? void 0 : [...new Headers(value)];
|
|
5532
|
-
|
|
5533
|
-
|
|
5534
|
-
|
|
5535
|
-
|
|
5536
|
-
run
|
|
5537
|
-
|
|
5538
|
-
Object.defineProperty(entry, operationEntryMarker, { value: true });
|
|
5539
|
-
return Object.freeze(entry);
|
|
5540
|
-
};
|
|
5541
|
-
const inputFree = (operation) => operationAtBoundary(operation, "input-free");
|
|
5542
|
-
const pure = (operation) => operationAtBoundary(operation, "pure");
|
|
5543
|
-
const validated = (operation) => operationAtBoundary(operation, "validated");
|
|
5544
|
-
const isOperationEntry = (value) => typeof value === "object" && value !== null && Object.getPrototypeOf(value) === Object.prototype && Object.isFrozen(value) && Object.hasOwn(value, operationEntryMarker) && value[operationEntryMarker] === true && Object.hasOwn(value, "boundary") && Object.hasOwn(value, "run") && Reflect.ownKeys(value).length === 3 && (value.boundary === "input-free" || value.boundary === "pure" || value.boundary === "validated") && typeof value.run === "function";
|
|
5545
|
-
const runClassifiedOperation = (entry, args) => {
|
|
5546
|
-
const result = Reflect.apply(entry.run, void 0, args);
|
|
5547
|
-
if (entry.boundary === "pure") {
|
|
5548
|
-
if (Effect.isEffect(result)) throw new TypeError("Pure SDK operation returned an Effect");
|
|
5549
|
-
return result;
|
|
5550
|
-
}
|
|
5551
|
-
if (!Effect.isEffect(result)) throw new TypeError(`${entry.boundary} SDK operation did not return an Effect`);
|
|
5552
|
-
return result;
|
|
5553
|
-
};
|
|
5554
|
-
const cloneOperationTree = (tree) => Object.fromEntries(Object.entries(tree).map(([key, value]) => [key, isOperationEntry(value) ? value.run : cloneOperationTree(value)]));
|
|
5555
|
-
const runPromiseOperation = (entry, state, args) => {
|
|
5556
|
-
const result = runClassifiedOperation(entry, args);
|
|
5557
|
-
return entry.boundary === "pure" ? result : provideSdk(state, result);
|
|
5558
|
-
};
|
|
5559
|
-
const makePromiseOperationTree = (tree, state) => Object.fromEntries(Object.entries(tree).map(([key, value]) => [key, isOperationEntry(value) ? (...args) => runPromiseOperation(value, state, args) : makePromiseOperationTree(value, state)]));
|
|
5560
|
-
const assertClassifiedOperationTree = (tree, parentPath = "") => {
|
|
5561
|
-
const entries = Object.entries(tree);
|
|
5562
|
-
if (Object.getPrototypeOf(tree) !== Object.prototype || entries.length === 0) throw new TypeError(`SDK operation namespace ${parentPath || "<root>"} is not a non-empty plain object`);
|
|
5563
|
-
for (const [key, value] of entries) {
|
|
5564
|
-
const path = parentPath ? `${parentPath}.${key}` : key;
|
|
5565
|
-
if (isOperationEntry(value)) continue;
|
|
5566
|
-
if (typeof value === "object" && value !== null) assertClassifiedOperationTree(value, path);
|
|
5567
|
-
else throw new TypeError(`SDK operation ${path} has no request-boundary classification`);
|
|
5381
|
+
var OperationEntry = class {
|
|
5382
|
+
run;
|
|
5383
|
+
toPromise;
|
|
5384
|
+
constructor(run, toPromise) {
|
|
5385
|
+
this.run = run;
|
|
5386
|
+
this.toPromise = toPromise;
|
|
5568
5387
|
}
|
|
5569
5388
|
};
|
|
5389
|
+
const effect = (operation) => new OperationEntry(operation, (state) => (...args) => provideSdk(state, operation(...args)));
|
|
5390
|
+
const pure = (operation) => new OperationEntry(operation, () => operation);
|
|
5391
|
+
const mapOperationTree = (tree, toOperation) => Object.fromEntries(Object.entries(tree).map(([key, value]) => [key, value instanceof OperationEntry ? toOperation(value) : mapOperationTree(value, toOperation)]));
|
|
5570
5392
|
const sharedOperationTree = {
|
|
5571
5393
|
account: {
|
|
5572
5394
|
appSpecificPasswords: {
|
|
5573
|
-
create:
|
|
5574
|
-
delete:
|
|
5575
|
-
deleteAll:
|
|
5576
|
-
list:
|
|
5577
|
-
},
|
|
5578
|
-
clear:
|
|
5579
|
-
destroy:
|
|
5580
|
-
getInfo:
|
|
5581
|
-
getSettings:
|
|
5582
|
-
listSubtitleLanguages:
|
|
5583
|
-
listConfirmations:
|
|
5584
|
-
saveSettings:
|
|
5395
|
+
create: effect(createAppSpecificPassword),
|
|
5396
|
+
delete: effect(deleteAppSpecificPassword),
|
|
5397
|
+
deleteAll: effect(deleteAllAppSpecificPasswords),
|
|
5398
|
+
list: effect(listAppSpecificPasswords)
|
|
5399
|
+
},
|
|
5400
|
+
clear: effect(clearAccount),
|
|
5401
|
+
destroy: effect(destroyAccount),
|
|
5402
|
+
getInfo: effect(getAccountInfo),
|
|
5403
|
+
getSettings: effect(getAccountSettings),
|
|
5404
|
+
listSubtitleLanguages: effect(listAccountSubtitleLanguages),
|
|
5405
|
+
listConfirmations: effect(listAccountConfirmations),
|
|
5406
|
+
saveSettings: effect(saveAccountSettings)
|
|
5585
5407
|
},
|
|
5586
5408
|
auth: {
|
|
5587
5409
|
buildLoginUrl: pure(buildAuthLoginUrl),
|
|
5588
|
-
checkCodeMatch:
|
|
5589
|
-
clients:
|
|
5590
|
-
exchangeAuthorizationCode:
|
|
5591
|
-
exists:
|
|
5592
|
-
forgotPassword:
|
|
5593
|
-
getCode:
|
|
5594
|
-
getFamilyInvite:
|
|
5595
|
-
getFriendInvite:
|
|
5596
|
-
getGiftCard:
|
|
5597
|
-
getVoucher:
|
|
5598
|
-
grants:
|
|
5599
|
-
linkDevice:
|
|
5600
|
-
login:
|
|
5601
|
-
logout:
|
|
5602
|
-
register:
|
|
5603
|
-
resetPassword:
|
|
5604
|
-
revokeAllClients:
|
|
5605
|
-
revokeApp:
|
|
5606
|
-
revokeClient:
|
|
5410
|
+
checkCodeMatch: effect(checkCodeMatch),
|
|
5411
|
+
clients: effect(clients),
|
|
5412
|
+
exchangeAuthorizationCode: effect(exchangeOAuthAuthorizationCode),
|
|
5413
|
+
exists: effect(exists),
|
|
5414
|
+
forgotPassword: effect(forgotPassword),
|
|
5415
|
+
getCode: effect(getCode),
|
|
5416
|
+
getFamilyInvite: effect(getFamilyInvite),
|
|
5417
|
+
getFriendInvite: effect(getFriendInvite),
|
|
5418
|
+
getGiftCard: effect(getGiftCard),
|
|
5419
|
+
getVoucher: effect(getVoucher),
|
|
5420
|
+
grants: effect(grants),
|
|
5421
|
+
linkDevice: effect(linkDevice),
|
|
5422
|
+
login: effect(login),
|
|
5423
|
+
logout: effect(logout),
|
|
5424
|
+
register: effect(register),
|
|
5425
|
+
resetPassword: effect(resetPassword),
|
|
5426
|
+
revokeAllClients: effect(revokeAllClients),
|
|
5427
|
+
revokeApp: effect(revokeApp),
|
|
5428
|
+
revokeClient: effect(revokeClient),
|
|
5607
5429
|
twoFactor: {
|
|
5608
|
-
generateTOTP:
|
|
5609
|
-
getRecoveryCodes:
|
|
5610
|
-
regenerateRecoveryCodes:
|
|
5611
|
-
verifyTOTP:
|
|
5430
|
+
generateTOTP: effect(generateTOTP),
|
|
5431
|
+
getRecoveryCodes: effect(getRecoveryCodes),
|
|
5432
|
+
regenerateRecoveryCodes: effect(regenerateRecoveryCodes),
|
|
5433
|
+
verifyTOTP: effect(verifyTOTP)
|
|
5612
5434
|
},
|
|
5613
|
-
validateToken:
|
|
5435
|
+
validateToken: effect(validateToken)
|
|
5614
5436
|
},
|
|
5615
5437
|
config: {
|
|
5616
|
-
deleteKey:
|
|
5617
|
-
getKey:
|
|
5618
|
-
getKeyWith:
|
|
5619
|
-
read:
|
|
5620
|
-
readWith:
|
|
5621
|
-
setKey:
|
|
5622
|
-
write:
|
|
5438
|
+
deleteKey: effect(deleteConfigKey),
|
|
5439
|
+
getKey: effect(getConfigKey),
|
|
5440
|
+
getKeyWith: effect(getConfigKeyWith),
|
|
5441
|
+
read: effect(readConfig),
|
|
5442
|
+
readWith: effect(readConfigWith),
|
|
5443
|
+
setKey: effect(setConfigKey),
|
|
5444
|
+
write: effect(writeConfig)
|
|
5623
5445
|
},
|
|
5624
5446
|
downloadLinks: {
|
|
5625
|
-
create:
|
|
5626
|
-
get:
|
|
5447
|
+
create: effect(createDownloadLinks),
|
|
5448
|
+
get: effect(getDownloadLinks)
|
|
5627
5449
|
},
|
|
5628
5450
|
events: {
|
|
5629
|
-
clear:
|
|
5630
|
-
delete:
|
|
5631
|
-
getTorrent:
|
|
5632
|
-
list:
|
|
5451
|
+
clear: effect(clearEvents),
|
|
5452
|
+
delete: effect(deleteEvent),
|
|
5453
|
+
getTorrent: effect(getEventTorrent),
|
|
5454
|
+
list: effect(listEvents)
|
|
5633
5455
|
},
|
|
5634
5456
|
family: {
|
|
5635
|
-
createInvite:
|
|
5636
|
-
join:
|
|
5637
|
-
listInvites:
|
|
5638
|
-
listMembers:
|
|
5639
|
-
removeMember:
|
|
5457
|
+
createInvite: effect(createFamilyInvite),
|
|
5458
|
+
join: effect(joinFamily),
|
|
5459
|
+
listInvites: effect(listFamilyInvites),
|
|
5460
|
+
listMembers: effect(listFamilyMembers),
|
|
5461
|
+
removeMember: effect(removeFamilyMember)
|
|
5640
5462
|
},
|
|
5641
5463
|
ifttt: {
|
|
5642
|
-
getStatus:
|
|
5643
|
-
sendEvent:
|
|
5464
|
+
getStatus: effect(getIftttStatus),
|
|
5465
|
+
sendEvent: effect(sendIftttEvent)
|
|
5644
5466
|
},
|
|
5645
|
-
podcast: { getLinks:
|
|
5467
|
+
podcast: { getLinks: effect(getPodcastLinks) },
|
|
5646
5468
|
files: {
|
|
5647
|
-
canWrite:
|
|
5648
|
-
continue:
|
|
5649
|
-
continueSearch:
|
|
5650
|
-
copy:
|
|
5651
|
-
convertToMp4:
|
|
5652
|
-
convertManyToMp4:
|
|
5653
|
-
convertSelectionToMp4:
|
|
5654
|
-
createUploadRequest:
|
|
5655
|
-
createFolder:
|
|
5656
|
-
deleteExtraction:
|
|
5657
|
-
deleteMp4:
|
|
5658
|
-
deleteSelection:
|
|
5659
|
-
delete:
|
|
5660
|
-
extract:
|
|
5661
|
-
findNext:
|
|
5662
|
-
findNextVideo:
|
|
5663
|
-
getApiContentUrl:
|
|
5664
|
-
getApiDownloadUrl:
|
|
5665
|
-
getApiMp4DownloadUrl:
|
|
5666
|
-
get:
|
|
5667
|
-
getChild:
|
|
5668
|
-
getDownloadUrl:
|
|
5669
|
-
getHlsMasterPlaylist:
|
|
5670
|
-
getHlsStreamUrl:
|
|
5671
|
-
getXspfPlaylistUrl:
|
|
5672
|
-
getMp4Status:
|
|
5673
|
-
getStartFrom:
|
|
5674
|
-
list:
|
|
5675
|
-
listActiveConversions:
|
|
5676
|
-
listExtractions:
|
|
5677
|
-
listSubtitles:
|
|
5678
|
-
move:
|
|
5679
|
-
moveSelection:
|
|
5680
|
-
putMp4ToMyFiles:
|
|
5681
|
-
rename:
|
|
5682
|
-
resetSortSettings:
|
|
5683
|
-
resetStartFrom:
|
|
5684
|
-
search:
|
|
5685
|
-
setSort:
|
|
5686
|
-
setWatchStatus:
|
|
5687
|
-
setStartFrom:
|
|
5688
|
-
touch:
|
|
5689
|
-
upload:
|
|
5469
|
+
canWrite: effect(canWriteFile),
|
|
5470
|
+
continue: effect(continueFiles),
|
|
5471
|
+
continueSearch: effect(continueSearch),
|
|
5472
|
+
copy: effect(copyFile),
|
|
5473
|
+
convertToMp4: effect(convertFileToMp4),
|
|
5474
|
+
convertManyToMp4: effect(convertFilesToMp4),
|
|
5475
|
+
convertSelectionToMp4: effect(convertFileSelectionToMp4),
|
|
5476
|
+
createUploadRequest: effect(createFileUploadRequest),
|
|
5477
|
+
createFolder: effect(createFolder),
|
|
5478
|
+
deleteExtraction: effect(deleteFileExtraction),
|
|
5479
|
+
deleteMp4: effect(deleteFileMp4),
|
|
5480
|
+
deleteSelection: effect(deleteFileSelection),
|
|
5481
|
+
delete: effect(deleteFiles),
|
|
5482
|
+
extract: effect(extractFiles),
|
|
5483
|
+
findNext: effect(findNextFile),
|
|
5484
|
+
findNextVideo: effect(findNextVideo),
|
|
5485
|
+
getApiContentUrl: effect(getApiContentUrl),
|
|
5486
|
+
getApiDownloadUrl: effect(getApiDownloadUrl),
|
|
5487
|
+
getApiMp4DownloadUrl: effect(getApiMp4DownloadUrl),
|
|
5488
|
+
get: effect(getFile),
|
|
5489
|
+
getChild: effect(getFileChild),
|
|
5490
|
+
getDownloadUrl: effect(getDownloadUrl),
|
|
5491
|
+
getHlsMasterPlaylist: effect(getHlsMasterPlaylist),
|
|
5492
|
+
getHlsStreamUrl: effect(getHlsStreamUrl),
|
|
5493
|
+
getXspfPlaylistUrl: effect(getXspfPlaylistUrl),
|
|
5494
|
+
getMp4Status: effect(getMp4Status),
|
|
5495
|
+
getStartFrom: effect(getStartFrom),
|
|
5496
|
+
list: effect(queryFiles),
|
|
5497
|
+
listActiveConversions: effect(listActiveMp4Conversions),
|
|
5498
|
+
listExtractions: effect(listFileExtractions),
|
|
5499
|
+
listSubtitles: effect(listFileSubtitles),
|
|
5500
|
+
move: effect(moveFiles),
|
|
5501
|
+
moveSelection: effect(moveFileSelection),
|
|
5502
|
+
putMp4ToMyFiles: effect(putMp4ToMyFiles),
|
|
5503
|
+
rename: effect(renameFile),
|
|
5504
|
+
resetSortSettings: effect(resetFileSortSettings),
|
|
5505
|
+
resetStartFrom: effect(resetStartFrom),
|
|
5506
|
+
search: effect(searchFiles),
|
|
5507
|
+
setSort: effect(setFileSort),
|
|
5508
|
+
setWatchStatus: effect(setFilesWatchStatus),
|
|
5509
|
+
setStartFrom: effect(setStartFrom),
|
|
5510
|
+
touch: effect(touchFiles),
|
|
5511
|
+
upload: effect(uploadFile)
|
|
5690
5512
|
},
|
|
5691
5513
|
friendInvites: {
|
|
5692
|
-
create:
|
|
5693
|
-
list:
|
|
5514
|
+
create: effect(createFriendInvite),
|
|
5515
|
+
list: effect(listFriendInvites)
|
|
5694
5516
|
},
|
|
5695
5517
|
friends: {
|
|
5696
|
-
approve:
|
|
5697
|
-
countWaitingRequests:
|
|
5698
|
-
deny:
|
|
5699
|
-
list:
|
|
5700
|
-
listSentRequests:
|
|
5701
|
-
listWaitingRequests:
|
|
5702
|
-
remove:
|
|
5703
|
-
search:
|
|
5704
|
-
sendRequest:
|
|
5705
|
-
sharedFolder:
|
|
5518
|
+
approve: effect(approveFriendRequest),
|
|
5519
|
+
countWaitingRequests: effect(countWaitingRequests),
|
|
5520
|
+
deny: effect(denyFriendRequest),
|
|
5521
|
+
list: effect(listFriends),
|
|
5522
|
+
listSentRequests: effect(listSentRequests),
|
|
5523
|
+
listWaitingRequests: effect(listWaitingRequests),
|
|
5524
|
+
remove: effect(removeFriend),
|
|
5525
|
+
search: effect(searchFriends),
|
|
5526
|
+
sendRequest: effect(sendFriendRequest),
|
|
5527
|
+
sharedFolder: effect(getFriendSharedFolder)
|
|
5706
5528
|
},
|
|
5707
5529
|
oauth: {
|
|
5708
5530
|
buildAuthorizeUrl: pure(buildOAuthAuthorizeUrl),
|
|
5709
5531
|
buildIconUrl: pure(buildOAuthAppIconUrl),
|
|
5710
|
-
create:
|
|
5711
|
-
delete:
|
|
5712
|
-
get:
|
|
5713
|
-
getPopularApps:
|
|
5714
|
-
query:
|
|
5715
|
-
regenerateToken:
|
|
5716
|
-
setIcon:
|
|
5717
|
-
update:
|
|
5532
|
+
create: effect(createOAuthApp),
|
|
5533
|
+
delete: effect(deleteOAuthApp),
|
|
5534
|
+
get: effect(getOAuthApp),
|
|
5535
|
+
getPopularApps: effect(getPopularOAuthApps),
|
|
5536
|
+
query: effect(queryOAuthApps),
|
|
5537
|
+
regenerateToken: effect(regenerateOAuthAppToken),
|
|
5538
|
+
setIcon: effect(setOAuthAppIcon),
|
|
5539
|
+
update: effect(updateOAuthApp)
|
|
5718
5540
|
},
|
|
5719
5541
|
payment: {
|
|
5720
5542
|
changePlan: {
|
|
5721
5543
|
classifyResponse: pure(classifyPaymentChangePlanResponse),
|
|
5722
|
-
preview:
|
|
5723
|
-
submit:
|
|
5724
|
-
},
|
|
5725
|
-
confirmFastspringOrder:
|
|
5726
|
-
getInfo:
|
|
5727
|
-
listHistory:
|
|
5728
|
-
listInvites:
|
|
5729
|
-
listOptions:
|
|
5730
|
-
listPlans:
|
|
5544
|
+
preview: effect(previewPaymentChangePlan),
|
|
5545
|
+
submit: effect(submitPaymentChangePlan)
|
|
5546
|
+
},
|
|
5547
|
+
confirmFastspringOrder: effect(confirmFastspringOrder),
|
|
5548
|
+
getInfo: effect(getPaymentInfo),
|
|
5549
|
+
listHistory: effect(listPaymentHistory),
|
|
5550
|
+
listInvites: effect(listPaymentInvites),
|
|
5551
|
+
listOptions: effect(listPaymentOptions),
|
|
5552
|
+
listPlans: effect(listPaymentPlans),
|
|
5731
5553
|
methods: {
|
|
5732
|
-
addPaddleWaitingPayment:
|
|
5733
|
-
createOpenNodeCharge:
|
|
5734
|
-
createPaddleBillingUpdatePaymentMethodTransaction:
|
|
5735
|
-
getPaddleBillingInvoiceUrl:
|
|
5554
|
+
addPaddleWaitingPayment: effect(createPaddleWaitingPayment),
|
|
5555
|
+
createOpenNodeCharge: effect(createOpenNodeCharge),
|
|
5556
|
+
createPaddleBillingUpdatePaymentMethodTransaction: effect(createPaddleBillingUpdatePaymentMethodTransaction),
|
|
5557
|
+
getPaddleBillingInvoiceUrl: effect(getPaddleBillingInvoiceUrl)
|
|
5736
5558
|
},
|
|
5737
|
-
report:
|
|
5738
|
-
stopSubscription:
|
|
5559
|
+
report: effect(reportPayments),
|
|
5560
|
+
stopSubscription: effect(stopPaymentSubscription),
|
|
5739
5561
|
voucher: {
|
|
5740
|
-
getInfo:
|
|
5741
|
-
redeem:
|
|
5562
|
+
getInfo: effect(getPaymentVoucherInfo),
|
|
5563
|
+
redeem: effect(redeemPaymentVoucher)
|
|
5742
5564
|
}
|
|
5743
5565
|
},
|
|
5744
|
-
rateLimits: { removeBan:
|
|
5566
|
+
rateLimits: { removeBan: effect(removeRateLimitBan) },
|
|
5745
5567
|
rss: {
|
|
5746
|
-
clearLogs:
|
|
5747
|
-
create:
|
|
5748
|
-
delete:
|
|
5749
|
-
get:
|
|
5750
|
-
list:
|
|
5751
|
-
listItems:
|
|
5752
|
-
pause:
|
|
5753
|
-
resume:
|
|
5754
|
-
retryAll:
|
|
5755
|
-
retryItem:
|
|
5756
|
-
update:
|
|
5568
|
+
clearLogs: effect(clearRssFeedLogs),
|
|
5569
|
+
create: effect(createRssFeed),
|
|
5570
|
+
delete: effect(deleteRssFeed),
|
|
5571
|
+
get: effect(getRssFeed),
|
|
5572
|
+
list: effect(listRssFeeds),
|
|
5573
|
+
listItems: effect(listRssFeedItems),
|
|
5574
|
+
pause: effect(pauseRssFeed),
|
|
5575
|
+
resume: effect(resumeRssFeed),
|
|
5576
|
+
retryAll: effect(retryAllRssFeedItems),
|
|
5577
|
+
retryItem: effect(retryRssFeedItem),
|
|
5578
|
+
update: effect(updateRssFeed)
|
|
5757
5579
|
},
|
|
5758
5580
|
sharing: {
|
|
5759
|
-
clone:
|
|
5760
|
-
getCloneInfo:
|
|
5761
|
-
getSharedWith:
|
|
5762
|
-
listSharedFiles:
|
|
5581
|
+
clone: effect(cloneSharedFiles),
|
|
5582
|
+
getCloneInfo: effect(getSharingCloneInfo),
|
|
5583
|
+
getSharedWith: effect(getSharedWith),
|
|
5584
|
+
listSharedFiles: effect(listSharedFiles),
|
|
5763
5585
|
publicAccess: {
|
|
5764
|
-
continueFiles:
|
|
5765
|
-
get:
|
|
5766
|
-
getFileUrl:
|
|
5767
|
-
listFiles:
|
|
5586
|
+
continueFiles: effect(continuePublicShareFiles),
|
|
5587
|
+
get: effect(getPublicShare),
|
|
5588
|
+
getFileUrl: effect(getPublicShareFileUrl),
|
|
5589
|
+
listFiles: effect(listPublicShareFiles)
|
|
5768
5590
|
},
|
|
5769
5591
|
publicShares: {
|
|
5770
|
-
create:
|
|
5771
|
-
delete:
|
|
5772
|
-
list:
|
|
5592
|
+
create: effect(createPublicShare),
|
|
5593
|
+
delete: effect(deletePublicShare),
|
|
5594
|
+
list: effect(listPublicShares)
|
|
5773
5595
|
},
|
|
5774
|
-
shareFiles:
|
|
5775
|
-
unshare:
|
|
5596
|
+
shareFiles: effect(shareFiles),
|
|
5597
|
+
unshare: effect(unshareFile)
|
|
5776
5598
|
},
|
|
5777
|
-
tunnel: { listRoutes:
|
|
5599
|
+
tunnel: { listRoutes: effect(listTunnelRoutes) },
|
|
5778
5600
|
trash: {
|
|
5779
|
-
continue:
|
|
5780
|
-
delete:
|
|
5781
|
-
empty:
|
|
5782
|
-
list:
|
|
5783
|
-
restore:
|
|
5601
|
+
continue: effect(continueTrash),
|
|
5602
|
+
delete: effect(deleteTrash),
|
|
5603
|
+
empty: effect(emptyTrash),
|
|
5604
|
+
list: effect(listTrash),
|
|
5605
|
+
restore: effect(restoreTrash)
|
|
5784
5606
|
},
|
|
5785
5607
|
transfers: {
|
|
5786
|
-
add:
|
|
5787
|
-
addMany:
|
|
5788
|
-
addTrackers:
|
|
5789
|
-
cancel:
|
|
5790
|
-
clean:
|
|
5791
|
-
continue:
|
|
5792
|
-
count:
|
|
5793
|
-
get:
|
|
5794
|
-
getTorrent:
|
|
5795
|
-
info:
|
|
5796
|
-
list:
|
|
5797
|
-
reannounce:
|
|
5798
|
-
remove:
|
|
5799
|
-
retry:
|
|
5800
|
-
stopRecording:
|
|
5608
|
+
add: effect(addTransfer),
|
|
5609
|
+
addMany: effect(addManyTransfers),
|
|
5610
|
+
addTrackers: effect(addTransferTrackers),
|
|
5611
|
+
cancel: effect(cancelTransfers),
|
|
5612
|
+
clean: effect(cleanTransfers),
|
|
5613
|
+
continue: effect(continueTransfers),
|
|
5614
|
+
count: effect(countTransfers),
|
|
5615
|
+
get: effect(getTransfer),
|
|
5616
|
+
getTorrent: effect(getTransferTorrent),
|
|
5617
|
+
info: effect(getTransferInfo),
|
|
5618
|
+
list: effect(listTransfers),
|
|
5619
|
+
reannounce: effect(reannounceTransfer),
|
|
5620
|
+
remove: effect(removeTransfers),
|
|
5621
|
+
retry: effect(retryTransfer),
|
|
5622
|
+
stopRecording: effect(stopTransferRecording)
|
|
5801
5623
|
},
|
|
5802
5624
|
zips: {
|
|
5803
|
-
cancel:
|
|
5804
|
-
create:
|
|
5805
|
-
get:
|
|
5806
|
-
list:
|
|
5625
|
+
cancel: effect(cancelZip),
|
|
5626
|
+
create: effect(createZip),
|
|
5627
|
+
get: effect(getZip),
|
|
5628
|
+
list: effect(listZips)
|
|
5807
5629
|
}
|
|
5808
5630
|
};
|
|
5809
|
-
|
|
5810
|
-
const createPutioSdkEffectClient = () => cloneOperationTree(sharedOperationTree);
|
|
5631
|
+
const createPutioSdkEffectClient = () => mapOperationTree(sharedOperationTree, (entry) => entry.run);
|
|
5811
5632
|
var PutioSdk = class extends Context.Service()("PutioSdk") {};
|
|
5812
5633
|
const makePutioSdkEffectClientLayer = () => Layer.succeed(PutioSdk, createPutioSdkEffectClient());
|
|
5813
|
-
const makePutioSdkLiveClientLayer = (config) => Layer.mergeAll(makePutioSdkEffectClientLayer(),
|
|
5634
|
+
const makePutioSdkLiveClientLayer = (config) => Layer.mergeAll(makePutioSdkEffectClientLayer(), putioSdkLiveLayer(config));
|
|
5814
5635
|
const createPutioSdkPromiseClient = (initialConfig = {}) => {
|
|
5815
|
-
const normalizedConfig = makePutioSdkConfig({
|
|
5816
|
-
...initialConfig,
|
|
5817
|
-
baseUrl: snapshotUrl(initialConfig.baseUrl),
|
|
5818
|
-
headers: snapshotHeaders(initialConfig.headers),
|
|
5819
|
-
uploadBaseUrl: snapshotUrl(initialConfig.uploadBaseUrl),
|
|
5820
|
-
webAppUrl: snapshotUrl(initialConfig.webAppUrl)
|
|
5821
|
-
});
|
|
5822
|
-
const runtimeConfig = {
|
|
5823
|
-
baseUrl: normalizedConfig.baseUrl,
|
|
5824
|
-
headers: normalizedConfig.headers,
|
|
5825
|
-
uploadBaseUrl: normalizedConfig.uploadBaseUrl,
|
|
5826
|
-
webAppUrl: normalizedConfig.webAppUrl
|
|
5827
|
-
};
|
|
5828
5636
|
const config = {
|
|
5829
5637
|
accessToken: initialConfig.accessToken,
|
|
5830
|
-
|
|
5638
|
+
disposed: false,
|
|
5639
|
+
runtime: void 0,
|
|
5640
|
+
runtimeConfig: Struct.omit(normalizePutioSdkOptions({
|
|
5641
|
+
...initialConfig,
|
|
5642
|
+
baseUrl: snapshotUrl(initialConfig.baseUrl),
|
|
5643
|
+
headers: snapshotHeaders(initialConfig.headers),
|
|
5644
|
+
uploadBaseUrl: snapshotUrl(initialConfig.uploadBaseUrl),
|
|
5645
|
+
webAppUrl: snapshotUrl(initialConfig.webAppUrl)
|
|
5646
|
+
}), ["accessToken"])
|
|
5831
5647
|
};
|
|
5832
5648
|
function getInfo(query = {}) {
|
|
5833
5649
|
return provideSdk(config, getAccountInfo(query));
|
|
@@ -5838,7 +5654,7 @@ const createPutioSdkPromiseClient = (initialConfig = {}) => {
|
|
|
5838
5654
|
function getChildByName(input) {
|
|
5839
5655
|
return provideSdk(config, getFileChild(input));
|
|
5840
5656
|
}
|
|
5841
|
-
const operations =
|
|
5657
|
+
const operations = mapOperationTree(sharedOperationTree, (entry) => entry.toPromise(config));
|
|
5842
5658
|
return {
|
|
5843
5659
|
dispose: () => disposePromiseClientRuntime(config),
|
|
5844
5660
|
setAccessToken: (accessToken) => {
|
|
@@ -5869,7 +5685,6 @@ const createPutioSdkPromiseClient = (initialConfig = {}) => {
|
|
|
5869
5685
|
}
|
|
5870
5686
|
};
|
|
5871
5687
|
};
|
|
5872
|
-
//#endregion
|
|
5873
|
-
export { AccountClearOptionsSchema, AccountConfirmationSchema, AccountConfirmationsErrorSpec, AccountDiskSchema, AccountInfoBaseSchema, AccountInfoBroadSchema, AccountInfoQuerySchema, AccountSettingsSchema, AccountSubtitleLanguageSchema, AccountTwoFactorSettingsSchema, AccountWarningsSchema, AddManyTransfersErrorSpec, AddTransferErrorSpec, AddTransferTrackersErrorSpec, AppSpecificPasswordSchema, ApproveFriendRequestErrorSpec, AuthorizationCodeSchema, CanWriteFileErrorSpec, CancelZipErrorSpec, ClearEventsErrorSpec, ClearRssFeedLogsErrorSpec, ClientsErrorSpec, ConfirmFastspringOrderErrorSpec, ContinueFilesErrorSpec, ContinuePublicShareFilesErrorSpec, ContinueTrashErrorSpec, CopyFileErrorSpec, CountWaitingRequestsErrorSpec, CreateAppSpecificPasswordErrorSpec, CreateAppSpecificPasswordInputSchema, CreateDownloadLinksErrorSpec, CreateFamilyInviteErrorSpec, CreateFolderErrorSpec, CreateFriendInviteErrorSpec, CreateOAuthAppErrorSpec, CreateOpenNodeChargeErrorSpec, CreatePaddleBillingUpdatePaymentMethodTransactionErrorSpec, CreatePaddleWaitingPaymentErrorSpec, CreatePublicShareErrorSpec, CreateRssFeedErrorSpec, CreateSharingCloneErrorSpec, CreateZipErrorSpec, DEFAULT_PUTIO_API_BASE_URL, DEFAULT_PUTIO_UPLOAD_BASE_URL, DEFAULT_PUTIO_WEB_APP_URL, DeleteAllAppSpecificPasswordsErrorSpec, DeleteAppSpecificPasswordErrorSpec, DeleteEventErrorSpec, DeleteOAuthAppErrorSpec, DeletePublicShareErrorSpec, DeleteRssFeedErrorSpec, DeleteTrashErrorSpec, DenyFriendRequestErrorSpec, DownloadLinksCreateInputSchema, DownloadLinksInfoSchema, DownloadLinksPayloadSchema, DownloadLinksStatusSchema, DownloadUrlErrorSpec, EmptyTrashErrorSpec, EventsListQuerySchema, FamilyInviteLookupErrorSpec, FamilyInviteSchema, FamilyMemberSchema, FileActiveConversionSchema, FileActiveConversionsErrorSpec, FileBaseSchema, FileBreadcrumbSchema, FileBroadSchema, FileConversionStatusSchema, FileCopyInputSchema, FileExtractionSchema, FileExtractionStatusSchema, FileExtractionsErrorSpec, FileGetChildInputSchema, FileMediaInfoFormatSchema, FileMediaInfoSchema, FileMediaInfoStreamSchema, FileMediaMetadataSchema, FileMp4ErrorSpec, FileMp4MutationErrorSpec, FileQuerySchema, FileSetSortInputSchema, FileSortSchema, FileSubtitleSchema, FileSubtitlesErrorSpec, FileTouchInputSchema, FileTypeSchema, FileUploadErrorSpec, FileWatchStatusErrorSpec, FilesListEnvelopeSchema, FilesListQuerySchema, FilesMoveErrorSchema, FilesSearchQuerySchema, FolderTypeSchema, ForgotPasswordErrorSpec, FriendBaseSchema, FriendInviteJoinedUserSchema, FriendInviteJoinedUserStatusSchema, FriendInviteLookupErrorSpec, FriendInviteSchema, FriendSchema, FriendSharedFolderErrorSpec, GenerateTOTPErrorSpec, GenerateTOTPResponseSchema, GetDownloadLinksErrorSpec, GetEventTorrentErrorSpec, GetFileChildErrorSpec, GetFileErrorSpec, GetHlsMasterPlaylistErrorSpec, GetIftttStatusErrorSpec, GetOAuthAppErrorSpec, GetPaddleBillingInvoiceUrlErrorSpec, GetPaymentInfoErrorSpec, GetPaymentVoucherInfoErrorSpec, GetPublicShareErrorSpec, GetPublicShareFileUrlErrorSpec, GetRssFeedErrorSpec, GetSharedWithErrorSpec, GetSharingCloneInfoErrorSpec, GetTransferErrorSpec, GetTransferTorrentErrorSpec, GetZipErrorSpec, GiftCardLookupErrorSpec, GrantsErrorSpec, HistoryEventSchema, HistoryFileFromRssDeletedEventSchema, HistoryFileSharedEventSchema, HistoryKnownEventTypeSchema, HistoryPrivateTorrentPinEventSchema, HistoryRssFilterPausedEventSchema, HistoryTransferCallbackErrorEventSchema, HistoryTransferCompletedEventSchema, HistoryTransferErrorEventSchema, HistoryTransferFromRssErrorEventSchema, HistoryUploadEventSchema, HistoryVoucherEventSchema, HistoryZipCreatedEventSchema, JoinFamilyErrorSpec, JsonObjectSchema, JsonValueSchema, LinkDeviceErrorSpec, ListAppSpecificPasswordsErrorSpec, ListEventsErrorSpec, ListFamilyInvitesErrorSpec, ListFamilyMembersErrorSpec, ListFriendInvitesErrorSpec, ListFriendsErrorSpec, ListPaymentHistoryErrorSpec, ListPaymentInvitesErrorSpec, ListPaymentOptionsErrorSpec, ListPaymentPlansErrorSpec, ListPublicShareFilesErrorSpec, ListPublicSharesErrorSpec, ListRssFeedItemsErrorSpec, ListRssFeedsErrorSpec, ListSentRequestsErrorSpec, ListSharedFilesErrorSpec, ListTransfersErrorSpec, ListTrashErrorSpec, ListTunnelRoutesErrorSpec, ListWaitingRequestsErrorSpec, ListZipsErrorSpec, LoginErrorSpec, LoginResponseSchema, MyOAuthAppSchema, OAuthAppCreateInputSchema, OAuthAppSchema, OAuthAppSessionSchema, OAuthAppUpdateInputSchema, OAuthAppWithTokenSchema, OAuthAuthorizationCodeExchangeError, OAuthAuthorizationCodeExchangeErrorCodeSchema, OAuthAuthorizationCodeExchangeInputSchema, OAuthSetIconInputSchema, OkResponseSchema, OwnedOAuthAppSchema, PasInfoSchema, PauseRssFeedErrorSpec, PaymentChangePlanPreviewSchema, PaymentChangePlanSubmitSchema, PaymentHistoryItemSchema, PaymentInfoPlanSchema, PaymentInfoSchema, PaymentInviteSchema, PaymentOptionPlanTypeSchema, PaymentOptionSchema, PaymentPlanGroupSchema, PaymentPlanTypeSchema, PaymentProviderNameSchema, PaymentProviderSchema, PaymentSubscriptionInfoSchema, PaymentTypeSchema, PaymentVoucherInfoSchema, PodcastGetLinksInputSchema, PodcastLinkTypeSchema, PodcastLinksSchema, PopularOAuthAppSchema, PreviewPaymentChangePlanErrorSpec, PublicShareListQuerySchema, PublicShareSchema, PutioApiError, PutioAuthError, PutioConfigurationError, PutioErrorEnvelopeSchema, PutioHttpClient, PutioOperationError, PutioRateLimitError, PutioSdk, PutioSdkConfig, PutioTransportError, PutioValidationError, QueryFilesErrorSpec, QueryOAuthAppsErrorSpec, ReannounceTransferErrorSpec, RecoveryCodesErrorSpec, RedeemPaymentVoucherErrorSpec, RegenerateOAuthAppTokenErrorSpec, RegenerateRecoveryCodesErrorSpec, RegisterErrorSpec, RegisterInputSchema, RemoveFamilyMemberErrorSpec, RemoveFriendErrorSpec, RemoveRateLimitBanErrorSpec, RemoveTransfersErrorSpec, RenameFileErrorSpec, ReportPaymentsErrorSpec, ResetPasswordErrorSpec, RestoreTrashErrorSpec, ResumeRssFeedErrorSpec, RetryAllRssFeedItemsErrorSpec, RetryRssFeedItemErrorSpec, RetryTransferErrorSpec, RevokeAllOAuthClientsErrorSpec, RevokeOAuthClientErrorSpec, RevokeOAuthGrantErrorSpec, RssFeedItemFailedSchema, RssFeedItemSchema, RssFeedItemSucceededSchema, RssFeedParamsSchema, RssFeedSchema, SHARED_WITH_YOU_ROOT_ID, SaveAccountSettingsErrorSpec, SaveAccountSettingsPayloadSchema, SearchFilesErrorSpec, SearchFriendsErrorSpec, SendFriendRequestErrorSpec, SendIftttEventErrorSpec, ShareFilesErrorSpec, SharedFileSchema, SharedFileShareSchema, SharedFileSharedWithSchema, SharingCloneInfoSchema, SharingCloneInputSchema, SharingCloneStatusSchema, SharingShareInputSchema, SharingUnshareInputSchema, StartFromErrorSpec, StopRecordingTransferErrorSpec, StopSubscriptionErrorSpec, SubmitPaymentChangePlanErrorSpec, TouchFilesErrorSpec, TransferAddInputSchema, TransferAddTrackersInputSchema, TransferBaseSchema, TransferRemoveInputSchema, TransferSchema, TransferStatusSchema, TransferTypeSchema, TransfersListQuerySchema, TrashFileSchema, TunnelRouteSchema, TwoFactorRecoveryCodesSchema, UnshareFileErrorSpec, UpdateOAuthAppErrorSpec, UpdateRssFeedErrorSpec, UserSearchResultSchema, UserSubscriptionStatusSchema, ValidateTokenResponseSchema, VerifyTOTPErrorSpec, VerifyTOTPResponseSchema, VoucherLookupErrorSpec, ZipStatusSchema, addManyTransfers, addTransfer, addTransferTrackers, approveFriendRequest, buildAuthLoginUrl, buildFileApiContentUrl, buildFileApiDownloadUrl, buildFileApiMp4DownloadUrl, buildFileHlsStreamUrl, buildFileXspfPlaylistUrl, buildOAuthAppIconUrl, buildOAuthAuthorizeUrl, buildPutioUrl, canWriteFile, cancelTransfers, cancelZip, checkCodeMatch, classifyPaymentChangePlanResponse, cleanTransfers, clearAccount, clearEvents, clearRssFeedLogs, clients, cloneSharedFiles, confirmFastspringOrder, continueFiles, continuePublicShareFiles, continueSearch, continueTransfers, continueTrash, convertFileSelectionToMp4, convertFileToMp4, convertFilesToMp4, copyFile, countTransfers, countWaitingRequests, createAppSpecificPassword, createDownloadLinks, createFamilyInvite, createFileUploadFormData, createFileUploadRequest, createFolder, createFriendInvite, createOAuthApp, createOpenNodeCharge, createPaddleBillingUpdatePaymentMethodTransaction, createPaddleWaitingPayment, createPublicShare, createPutioSdkEffectClient, createPutioSdkPromiseClient, createRssFeed, createZip, decodePutioErrorEnvelope, definePutioOperationErrorSpec, deleteAllAppSpecificPasswords, deleteAppSpecificPassword, deleteConfigKey, deleteEvent, deleteFileExtraction, deleteFileMp4, deleteFileSelection, deleteFiles, deleteOAuthApp, deletePublicShare, deleteRssFeed, deleteTrash, denyFriendRequest, destroyAccount, emptyTrash, encodePathSegment, exchangeOAuthAuthorizationCode, exists, extractFiles, fallbackPutioErrorEnvelope, findNextFile, findNextVideo, forgotPassword, generateTOTP, getAccountInfo, getAccountSettings, getApiContentUrl, getApiDownloadUrl, getApiMp4DownloadUrl, getCode, getConfigKey, getConfigKeyWith, getDownloadLinks, getDownloadUrl, getEventTorrent, getFamilyInvite, getFile, getFileChild, getFriendInvite, getFriendSharedFolder, getGiftCard, getHlsMasterPlaylist, getHlsStreamUrl, getIftttStatus, getMp4Status, getOAuthApp, getPaddleBillingInvoiceUrl, getPaymentInfo, getPaymentVoucherInfo, getPodcastLinks, getPopularOAuthApps, getPublicShare, getPublicShareFileUrl, getRecoveryCodes, getRssFeed, getSharedWith, getSharingCloneInfo, getStartFrom, getTransfer, getTransferInfo, getTransferTorrent, getVoucher, getXspfPlaylistUrl, getZip, grants, isPutioApiError, isPutioAuthError, isPutioErrorEnvelope, isPutioOperationError, isPutioRateLimitError, joinFamily, linkDevice, listAccountConfirmations, listAccountSubtitleLanguages, listActiveMp4Conversions, listAppSpecificPasswords, listEvents, listFamilyInvites, listFamilyMembers, listFileExtractions, listFileSubtitles, listFriendInvites, listFriends, listPaymentHistory, listPaymentInvites, listPaymentOptions, listPaymentPlans, listPublicShareFiles, listPublicShares, listRssFeedItems, listRssFeeds, listSentRequests, listSharedFiles, listTransfers, listTrash, listTunnelRoutes, listWaitingRequests, listZips, login, logout, makePutioFetchClient, makePutioFetchLayer, makePutioSdkConfig, makePutioSdkEffectClientLayer, makePutioSdkLayer, makePutioSdkLiveClientLayer, makePutioSdkLiveLayer, makeResponseError, mapConfigurationError, mapDecodeErrorToValidationError, mapTransportError, moveFileSelection, moveFiles, parseErrorBody, pauseRssFeed, previewPaymentChangePlan, putMp4ToMyFiles, queryFiles, queryOAuthApps, readConfig, readConfigWith, reannounceTransfer, redeemPaymentVoucher, regenerateOAuthAppToken, regenerateRecoveryCodes, register, removeFamilyMember, removeFriend, removeRateLimitBan, removeTransfers, renameFile, reportPayments, requestArrayBuffer, requestJson, requestText, requestVoid, resetFileSortSettings, resetPassword, resetStartFrom, responseRateLimitHeaders, restoreTrash, resumeRssFeed, retryAllRssFeedItems, retryRssFeedItem, retryTransfer, revokeAllClients, revokeApp, revokeClient, saveAccountSettings, searchFiles, searchFriends, selectJsonField, selectJsonFields, sendFriendRequest, sendIftttEvent, setConfigKey, setFileSort, setFilesWatchStatus, setOAuthAppIcon, setStartFrom, shareFiles, stopPaymentSubscription, stopTransferRecording, submitPaymentChangePlan, touchFiles, unshareFile, updateOAuthApp, updateRssFeed, uploadFile, validateToken, verifyTOTP, withOperationErrors, writeConfig };
|
|
5688
|
+
export { AccountClearOptionsSchema, AccountConfirmationSchema, AccountConfirmationsErrorSpec, AccountDiskSchema, AccountInfoBaseSchema, AccountInfoBroadSchema, AccountInfoQuerySchema, AccountSettingsSchema, AccountSubtitleLanguageSchema, AccountTwoFactorSettingsSchema, AccountWarningsSchema, AddManyTransfersErrorSpec, AddTransferErrorSpec, AddTransferTrackersErrorSpec, AppSpecificPasswordSchema, ApproveFriendRequestErrorSpec, AuthorizationCodeSchema, CanWriteFileErrorSpec, CancelZipErrorSpec, ClearEventsErrorSpec, ClearRssFeedLogsErrorSpec, ClientsErrorSpec, ConfirmFastspringOrderErrorSpec, ContinueFilesErrorSpec, ContinuePublicShareFilesErrorSpec, ContinueTrashErrorSpec, CopyFileErrorSpec, CountWaitingRequestsErrorSpec, CreateAppSpecificPasswordErrorSpec, CreateAppSpecificPasswordInputSchema, CreateDownloadLinksErrorSpec, CreateFamilyInviteErrorSpec, CreateFolderErrorSpec, CreateFriendInviteErrorSpec, CreateOAuthAppErrorSpec, CreateOpenNodeChargeErrorSpec, CreatePaddleBillingUpdatePaymentMethodTransactionErrorSpec, CreatePaddleWaitingPaymentErrorSpec, CreatePublicShareErrorSpec, CreateRssFeedErrorSpec, CreateSharingCloneErrorSpec, CreateZipErrorSpec, DEFAULT_PUTIO_API_BASE_URL, DEFAULT_PUTIO_UPLOAD_BASE_URL, DEFAULT_PUTIO_WEB_APP_URL, DeleteAllAppSpecificPasswordsErrorSpec, DeleteAppSpecificPasswordErrorSpec, DeleteEventErrorSpec, DeleteOAuthAppErrorSpec, DeletePublicShareErrorSpec, DeleteRssFeedErrorSpec, DeleteTrashErrorSpec, DenyFriendRequestErrorSpec, DownloadLinksCreateInputSchema, DownloadLinksInfoSchema, DownloadLinksPayloadSchema, DownloadLinksStatusSchema, DownloadUrlErrorSpec, EmptyTrashErrorSpec, EventsListQuerySchema, FamilyInviteLookupErrorSpec, FamilyInviteSchema, FamilyMemberSchema, FileActiveConversionSchema, FileActiveConversionsErrorSpec, FileBaseSchema, FileBreadcrumbSchema, FileBroadSchema, FileConversionStatusSchema, FileCopyInputSchema, FileExtractionSchema, FileExtractionStatusSchema, FileExtractionsErrorSpec, FileGetChildInputSchema, FileMediaInfoFormatSchema, FileMediaInfoSchema, FileMediaInfoStreamSchema, FileMediaMetadataSchema, FileMp4ErrorSpec, FileMp4MutationErrorSpec, FileQuerySchema, FileSetSortInputSchema, FileSortSchema, FileSubtitleSchema, FileSubtitlesErrorSpec, FileTouchInputSchema, FileTypeSchema, FileUploadErrorSpec, FileWatchStatusErrorSpec, FilesListEnvelopeSchema, FilesListQuerySchema, FilesMoveErrorSchema, FilesSearchQuerySchema, FolderTypeSchema, ForgotPasswordErrorSpec, FriendBaseSchema, FriendInviteJoinedUserSchema, FriendInviteJoinedUserStatusSchema, FriendInviteLookupErrorSpec, FriendInviteSchema, FriendSchema, FriendSharedFolderErrorSpec, GenerateTOTPErrorSpec, GenerateTOTPResponseSchema, GetDownloadLinksErrorSpec, GetEventTorrentErrorSpec, GetFileChildErrorSpec, GetFileErrorSpec, GetHlsMasterPlaylistErrorSpec, GetIftttStatusErrorSpec, GetOAuthAppErrorSpec, GetPaddleBillingInvoiceUrlErrorSpec, GetPaymentInfoErrorSpec, GetPaymentVoucherInfoErrorSpec, GetPublicShareErrorSpec, GetPublicShareFileUrlErrorSpec, GetRssFeedErrorSpec, GetSharedWithErrorSpec, GetSharingCloneInfoErrorSpec, GetTransferErrorSpec, GetTransferTorrentErrorSpec, GetZipErrorSpec, GiftCardLookupErrorSpec, GrantsErrorSpec, HistoryEventSchema, HistoryFileFromRssDeletedEventSchema, HistoryFileSharedEventSchema, HistoryKnownEventTypeSchema, HistoryPrivateTorrentPinEventSchema, HistoryRssFilterPausedEventSchema, HistoryTransferCallbackErrorEventSchema, HistoryTransferCompletedEventSchema, HistoryTransferErrorEventSchema, HistoryTransferFromRssErrorEventSchema, HistoryUploadEventSchema, HistoryVoucherEventSchema, HistoryZipCreatedEventSchema, JoinFamilyErrorSpec, JsonObjectSchema, JsonValueSchema, LinkDeviceErrorSpec, ListAppSpecificPasswordsErrorSpec, ListEventsErrorSpec, ListFamilyInvitesErrorSpec, ListFamilyMembersErrorSpec, ListFriendInvitesErrorSpec, ListFriendsErrorSpec, ListPaymentHistoryErrorSpec, ListPaymentInvitesErrorSpec, ListPaymentOptionsErrorSpec, ListPaymentPlansErrorSpec, ListPublicShareFilesErrorSpec, ListPublicSharesErrorSpec, ListRssFeedItemsErrorSpec, ListRssFeedsErrorSpec, ListSentRequestsErrorSpec, ListSharedFilesErrorSpec, ListTransfersErrorSpec, ListTrashErrorSpec, ListTunnelRoutesErrorSpec, ListWaitingRequestsErrorSpec, ListZipsErrorSpec, LoginErrorSpec, LoginResponseSchema, MyOAuthAppSchema, OAuthAppCreateInputSchema, OAuthAppSchema, OAuthAppSessionSchema, OAuthAppUpdateInputSchema, OAuthAppWithTokenSchema, OAuthAuthorizationCodeExchangeError, OAuthAuthorizationCodeExchangeErrorCodeSchema, OAuthAuthorizationCodeExchangeInputSchema, OAuthSetIconInputSchema, OkResponseSchema, OwnedOAuthAppSchema, PasInfoSchema, PauseRssFeedErrorSpec, PaymentChangePlanPreviewSchema, PaymentChangePlanSubmitSchema, PaymentHistoryItemSchema, PaymentInfoPlanSchema, PaymentInfoSchema, PaymentInviteSchema, PaymentOptionPlanTypeSchema, PaymentOptionSchema, PaymentPlanGroupSchema, PaymentPlanTypeSchema, PaymentProviderNameSchema, PaymentProviderSchema, PaymentSubscriptionInfoSchema, PaymentTypeSchema, PaymentVoucherInfoSchema, PodcastGetLinksInputSchema, PodcastLinkTypeSchema, PodcastLinksSchema, PopularOAuthAppSchema, PreviewPaymentChangePlanErrorSpec, PublicShareListQuerySchema, PublicShareSchema, PutioApiError, PutioAuthError, PutioConfigurationError, PutioErrorEnvelopeSchema, PutioHttpClient, PutioOperationError, PutioRateLimitError, PutioSdk, PutioSdkConfig, PutioTransportError, PutioValidationError, QueryFilesErrorSpec, QueryOAuthAppsErrorSpec, ReannounceTransferErrorSpec, RecoveryCodesErrorSpec, RedeemPaymentVoucherErrorSpec, RegenerateOAuthAppTokenErrorSpec, RegenerateRecoveryCodesErrorSpec, RegisterErrorSpec, RegisterInputSchema, RemoveFamilyMemberErrorSpec, RemoveFriendErrorSpec, RemoveRateLimitBanErrorSpec, RemoveTransfersErrorSpec, RenameFileErrorSpec, ReportPaymentsErrorSpec, ResetPasswordErrorSpec, RestoreTrashErrorSpec, ResumeRssFeedErrorSpec, RetryAllRssFeedItemsErrorSpec, RetryRssFeedItemErrorSpec, RetryTransferErrorSpec, RevokeAllOAuthClientsErrorSpec, RevokeOAuthClientErrorSpec, RevokeOAuthGrantErrorSpec, RssFeedItemFailedSchema, RssFeedItemSchema, RssFeedItemSucceededSchema, RssFeedParamsSchema, RssFeedSchema, SHARED_WITH_YOU_ROOT_ID, SaveAccountSettingsErrorSpec, SaveAccountSettingsPayloadSchema, SearchFilesErrorSpec, SearchFriendsErrorSpec, SendFriendRequestErrorSpec, SendIftttEventErrorSpec, ShareFilesErrorSpec, SharedFileSchema, SharedFileShareSchema, SharedFileSharedWithSchema, SharingCloneInfoSchema, SharingCloneInputSchema, SharingCloneStatusSchema, SharingShareInputSchema, SharingUnshareInputSchema, StartFromErrorSpec, StopRecordingTransferErrorSpec, StopSubscriptionErrorSpec, SubmitPaymentChangePlanErrorSpec, TouchFilesErrorSpec, TransferAddInputSchema, TransferAddTrackersInputSchema, TransferBaseSchema, TransferRemoveInputSchema, TransferSchema, TransferStatusSchema, TransferTypeSchema, TransfersListQuerySchema, TrashFileSchema, TunnelRouteSchema, TwoFactorRecoveryCodesSchema, UnshareFileErrorSpec, UpdateOAuthAppErrorSpec, UpdateRssFeedErrorSpec, UserSearchResultSchema, UserSubscriptionStatusSchema, ValidateTokenResponseSchema, VerifyTOTPErrorSpec, VerifyTOTPResponseSchema, VoucherLookupErrorSpec, ZipStatusSchema, addManyTransfers, addTransfer, addTransferTrackers, approveFriendRequest, buildAuthLoginUrl, buildFileApiContentUrl, buildFileApiDownloadUrl, buildFileApiMp4DownloadUrl, buildFileHlsStreamUrl, buildFileXspfPlaylistUrl, buildOAuthAppIconUrl, buildOAuthAuthorizeUrl, buildPutioUrl, canWriteFile, cancelTransfers, cancelZip, checkCodeMatch, classifyPaymentChangePlanResponse, cleanTransfers, clearAccount, clearEvents, clearRssFeedLogs, clients, cloneSharedFiles, confirmFastspringOrder, continueFiles, continuePublicShareFiles, continueSearch, continueTransfers, continueTrash, convertFileSelectionToMp4, convertFileToMp4, convertFilesToMp4, copyFile, countTransfers, countWaitingRequests, createAppSpecificPassword, createDownloadLinks, createFamilyInvite, createFileUploadFormData, createFileUploadRequest, createFolder, createFriendInvite, createOAuthApp, createOpenNodeCharge, createPaddleBillingUpdatePaymentMethodTransaction, createPaddleWaitingPayment, createPublicShare, createPutioSdkEffectClient, createPutioSdkPromiseClient, createRssFeed, createZip, decodePutioErrorEnvelope, definePutioOperationErrorSpec, deleteAllAppSpecificPasswords, deleteAppSpecificPassword, deleteConfigKey, deleteEvent, deleteFileExtraction, deleteFileMp4, deleteFileSelection, deleteFiles, deleteOAuthApp, deletePublicShare, deleteRssFeed, deleteTrash, denyFriendRequest, destroyAccount, emptyTrash, encodePathSegment, exchangeOAuthAuthorizationCode, exists, extractFiles, fallbackPutioErrorEnvelope, findNextFile, findNextVideo, forgotPassword, generateTOTP, getAccountInfo, getAccountSettings, getApiContentUrl, getApiDownloadUrl, getApiMp4DownloadUrl, getCode, getConfigKey, getConfigKeyWith, getDownloadLinks, getDownloadUrl, getEventTorrent, getFamilyInvite, getFile, getFileChild, getFriendInvite, getFriendSharedFolder, getGiftCard, getHlsMasterPlaylist, getHlsStreamUrl, getIftttStatus, getMp4Status, getOAuthApp, getPaddleBillingInvoiceUrl, getPaymentInfo, getPaymentVoucherInfo, getPodcastLinks, getPopularOAuthApps, getPublicShare, getPublicShareFileUrl, getRecoveryCodes, getRssFeed, getSharedWith, getSharingCloneInfo, getStartFrom, getTransfer, getTransferInfo, getTransferTorrent, getVoucher, getXspfPlaylistUrl, getZip, grants, isPutioApiError, isPutioAuthError, isPutioErrorEnvelope, isPutioOperationError, isPutioRateLimitError, joinFamily, linkDevice, listAccountConfirmations, listAccountSubtitleLanguages, listActiveMp4Conversions, listAppSpecificPasswords, listEvents, listFamilyInvites, listFamilyMembers, listFileExtractions, listFileSubtitles, listFriendInvites, listFriends, listPaymentHistory, listPaymentInvites, listPaymentOptions, listPaymentPlans, listPublicShareFiles, listPublicShares, listRssFeedItems, listRssFeeds, listSentRequests, listSharedFiles, listTransfers, listTrash, listTunnelRoutes, listWaitingRequests, listZips, login, logout, makePutioFetchClient, makePutioFetchLayer, makePutioSdkEffectClientLayer, makePutioSdkLiveClientLayer, mapConfigurationError, mapDecodeErrorToValidationError, mapTransportError, moveFileSelection, moveFiles, normalizePutioSdkOptions, parseErrorBody, pauseRssFeed, previewPaymentChangePlan, putMp4ToMyFiles, putioSdkLayer, putioSdkLiveLayer, queryFiles, queryOAuthApps, readConfig, readConfigWith, reannounceTransfer, redeemPaymentVoucher, regenerateOAuthAppToken, regenerateRecoveryCodes, register, removeFamilyMember, removeFriend, removeRateLimitBan, removeTransfers, renameFile, reportPayments, requestArrayBuffer, requestJson, requestText, requestVoid, resetFileSortSettings, resetPassword, resetStartFrom, responseRateLimitHeaders, restoreTrash, resumeRssFeed, retryAllRssFeedItems, retryRssFeedItem, retryTransfer, revokeAllClients, revokeApp, revokeClient, saveAccountSettings, searchFiles, searchFriends, selectJsonField, selectJsonFields, sendFriendRequest, sendIftttEvent, setConfigKey, setFileSort, setFilesWatchStatus, setOAuthAppIcon, setStartFrom, shareFiles, stopPaymentSubscription, stopTransferRecording, submitPaymentChangePlan, toPutioResponseError, touchFiles, unshareFile, updateOAuthApp, updateRssFeed, uploadFile, validateToken, verifyTOTP, withOperationErrors, writeConfig };
|
|
5874
5689
|
|
|
5875
5690
|
//# sourceMappingURL=index.js.map
|