@steamsets/client-ts 0.4.1 → 0.5.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 +4 -37
- package/docs/sdks/account/README.md +95 -13
- package/docs/sdks/session/README.md +81 -7
- package/funcs/accountAccountV1GetApps.d.ts +1 -2
- package/funcs/accountAccountV1GetApps.d.ts.map +1 -1
- package/funcs/accountAccountV1GetApps.js +6 -3
- package/funcs/accountAccountV1GetApps.js.map +1 -1
- package/funcs/accountAccountV1GetBadges.d.ts +1 -2
- package/funcs/accountAccountV1GetBadges.d.ts.map +1 -1
- package/funcs/accountAccountV1GetBadges.js +6 -3
- package/funcs/accountAccountV1GetBadges.js.map +1 -1
- package/funcs/accountAccountV1SessionCreate.d.ts +13 -0
- package/funcs/accountAccountV1SessionCreate.d.ts.map +1 -0
- package/funcs/accountAccountV1SessionCreate.js +112 -0
- package/funcs/accountAccountV1SessionCreate.js.map +1 -0
- package/funcs/accountAccountV1SessionLogin.d.ts +1 -1
- package/funcs/accountAccountV1SessionLogin.d.ts.map +1 -1
- package/funcs/accountAccountV1SessionLogin.js +5 -12
- package/funcs/accountAccountV1SessionLogin.js.map +1 -1
- package/funcs/sessionAccountV1SessionCreate.d.ts +13 -0
- package/funcs/sessionAccountV1SessionCreate.d.ts.map +1 -0
- package/funcs/sessionAccountV1SessionCreate.js +112 -0
- package/funcs/sessionAccountV1SessionCreate.js.map +1 -0
- package/funcs/sessionAccountV1SessionLogin.d.ts +1 -1
- package/funcs/sessionAccountV1SessionLogin.d.ts.map +1 -1
- package/funcs/sessionAccountV1SessionLogin.js +5 -12
- package/funcs/sessionAccountV1SessionLogin.js.map +1 -1
- package/lib/config.d.ts +2 -2
- package/lib/config.js +2 -2
- package/models/components/accountsearchvanitystruct.d.ts +4 -4
- package/models/components/accountsearchvanitystruct.d.ts.map +1 -1
- package/models/components/accountsearchvanitystruct.js +4 -4
- package/models/components/accountsearchvanitystruct.js.map +1 -1
- package/models/components/index.d.ts +1 -0
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +1 -0
- package/models/components/index.js.map +1 -1
- package/models/components/security.d.ts +2 -2
- package/models/components/security.d.ts.map +1 -1
- package/models/components/security.js +2 -2
- package/models/components/security.js.map +1 -1
- package/models/components/v1createsessionbody.d.ts +33 -0
- package/models/components/v1createsessionbody.d.ts.map +1 -0
- package/models/components/v1createsessionbody.js +65 -0
- package/models/components/v1createsessionbody.js.map +1 -0
- package/models/operations/accountv1getapps.d.ts +25 -0
- package/models/operations/accountv1getapps.d.ts.map +1 -1
- package/models/operations/accountv1getapps.js +36 -1
- package/models/operations/accountv1getapps.js.map +1 -1
- package/models/operations/accountv1getbadges.d.ts +25 -0
- package/models/operations/accountv1getbadges.d.ts.map +1 -1
- package/models/operations/accountv1getbadges.js +36 -1
- package/models/operations/accountv1getbadges.js.map +1 -1
- package/models/operations/accountv1sessioncreate.d.ts +60 -0
- package/models/operations/accountv1sessioncreate.d.ts.map +1 -0
- package/models/operations/accountv1sessioncreate.js +111 -0
- package/models/operations/accountv1sessioncreate.js.map +1 -0
- package/models/operations/accountv1sessionlogin.d.ts +0 -23
- package/models/operations/accountv1sessionlogin.d.ts.map +1 -1
- package/models/operations/accountv1sessionlogin.js +1 -20
- package/models/operations/accountv1sessionlogin.js.map +1 -1
- package/models/operations/index.d.ts +1 -0
- package/models/operations/index.d.ts.map +1 -1
- package/models/operations/index.js +1 -0
- package/models/operations/index.js.map +1 -1
- package/package.json +1 -1
- package/sdk/account.d.ts +7 -3
- package/sdk/account.d.ts.map +1 -1
- package/sdk/account.js +9 -2
- package/sdk/account.js.map +1 -1
- package/sdk/session.d.ts +5 -1
- package/sdk/session.d.ts.map +1 -1
- package/sdk/session.js +9 -2
- package/sdk/session.js.map +1 -1
- package/src/funcs/accountAccountV1GetApps.ts +8 -5
- package/src/funcs/accountAccountV1GetBadges.ts +8 -5
- package/src/funcs/accountAccountV1SessionCreate.ts +146 -0
- package/src/funcs/accountAccountV1SessionLogin.ts +5 -13
- package/src/funcs/sessionAccountV1SessionCreate.ts +146 -0
- package/src/funcs/sessionAccountV1SessionLogin.ts +5 -13
- package/src/lib/config.ts +2 -2
- package/src/models/components/accountsearchvanitystruct.ts +8 -8
- package/src/models/components/index.ts +1 -0
- package/src/models/components/security.ts +4 -4
- package/src/models/components/v1createsessionbody.ts +68 -0
- package/src/models/operations/accountv1getapps.ts +58 -0
- package/src/models/operations/accountv1getbadges.ts +58 -0
- package/src/models/operations/accountv1sessioncreate.ts +138 -0
- package/src/models/operations/accountv1sessionlogin.ts +0 -40
- package/src/models/operations/index.ts +1 -0
- package/src/sdk/account.ts +14 -4
- package/src/sdk/session.ts +12 -2
package/sdk/account.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"account.d.ts","sourceRoot":"","sources":["../src/sdk/account.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"account.d.ts","sourceRoot":"","sources":["../src/sdk/account.ts"],"names":[],"mappings":"AAsBA,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAG5D,qBAAa,OAAQ,SAAQ,SAAS;IAClC;;OAEG;IACG,0BAA0B,CAC5B,OAAO,EAAE,UAAU,CAAC,oBAAoB,EACxC,OAAO,CAAC,EAAE,cAAc,GACzB,OAAO,CAAC,UAAU,CAAC,kCAAkC,CAAC;IAIzD;;OAEG;IACG,mCAAmC,CACrC,OAAO,EAAE,UAAU,CAAC,6BAA6B,EACjD,OAAO,CAAC,EAAE,cAAc,GACzB,OAAO,CAAC,UAAU,CAAC,2CAA2C,CAAC;IAIlE;;OAEG;IACG,6BAA6B,CAC/B,OAAO,EAAE,UAAU,CAAC,yBAAyB,EAC7C,OAAO,CAAC,EAAE,cAAc,GACzB,OAAO,CAAC,UAAU,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,wBAAwB,EAC5C,OAAO,CAAC,EAAE,cAAc,GACzB,OAAO,CAAC,UAAU,CAAC,oCAAoC,CAAC;IAI3D;;OAEG;IACG,uBAAuB,CACzB,OAAO,EAAE,UAAU,CAAC,8BAA8B,EAClD,OAAO,CAAC,EAAE,cAAc,GACzB,OAAO,CAAC,UAAU,CAAC,+BAA+B,CAAC;IAItD;;OAEG;IACG,6BAA6B,CAC/B,OAAO,EAAE,UAAU,CAAC,yBAAyB,EAC7C,OAAO,CAAC,EAAE,cAAc,GACzB,OAAO,CAAC,UAAU,CAAC,qCAAqC,CAAC;IAI5D;;OAEG;IACG,mCAAmC,CACrC,OAAO,EAAE,UAAU,CAAC,6BAA6B,EACjD,OAAO,CAAC,EAAE,cAAc,GACzB,OAAO,CAAC,UAAU,CAAC,2CAA2C,CAAC;IAIlE;;OAEG;IACG,2BAA2B,CAC7B,OAAO,EAAE,UAAU,CAAC,wBAAwB,EAC5C,OAAO,CAAC,EAAE,cAAc,GACzB,OAAO,CAAC,UAAU,CAAC,mCAAmC,CAAC;IAI1D;;OAEG;IACG,sBAAsB,CACxB,OAAO,EAAE,UAAU,CAAC,6BAA6B,EACjD,OAAO,CAAC,EAAE,cAAc,GACzB,OAAO,CAAC,UAAU,CAAC,8BAA8B,CAAC;CAGxD"}
|
package/sdk/account.js
CHANGED
|
@@ -10,6 +10,7 @@ const accountAccountV1ConnectionUpdateConnection_js_1 = require("../funcs/accoun
|
|
|
10
10
|
const accountAccountV1ConnectionVerifyConnection_js_1 = require("../funcs/accountAccountV1ConnectionVerifyConnection.js");
|
|
11
11
|
const accountAccountV1GetApps_js_1 = require("../funcs/accountAccountV1GetApps.js");
|
|
12
12
|
const accountAccountV1GetBadges_js_1 = require("../funcs/accountAccountV1GetBadges.js");
|
|
13
|
+
const accountAccountV1SessionCreate_js_1 = require("../funcs/accountAccountV1SessionCreate.js");
|
|
13
14
|
const accountAccountV1SessionDelete_js_1 = require("../funcs/accountAccountV1SessionDelete.js");
|
|
14
15
|
const accountAccountV1SessionGet_js_1 = require("../funcs/accountAccountV1SessionGet.js");
|
|
15
16
|
const accountAccountV1SessionLogin_js_1 = require("../funcs/accountAccountV1SessionLogin.js");
|
|
@@ -81,8 +82,8 @@ class Account extends sdks_js_1.ClientSDK {
|
|
|
81
82
|
/**
|
|
82
83
|
* Logs a user in and creates a new session
|
|
83
84
|
*/
|
|
84
|
-
async accountV1SessionLogin(request,
|
|
85
|
-
return (0, fp_js_1.unwrapAsync)((0, accountAccountV1SessionLogin_js_1.accountAccountV1SessionLogin)(this, request,
|
|
85
|
+
async accountV1SessionLogin(request, options) {
|
|
86
|
+
return (0, fp_js_1.unwrapAsync)((0, accountAccountV1SessionLogin_js_1.accountAccountV1SessionLogin)(this, request, options));
|
|
86
87
|
}
|
|
87
88
|
/**
|
|
88
89
|
* Resend the verification code for an email
|
|
@@ -126,6 +127,12 @@ class Account extends sdks_js_1.ClientSDK {
|
|
|
126
127
|
async accountV1SettingsVerfyEmail(request, options) {
|
|
127
128
|
return (0, fp_js_1.unwrapAsync)((0, accountAccountV1SettingsVerfyEmail_js_1.accountAccountV1SettingsVerfyEmail)(this, request, options));
|
|
128
129
|
}
|
|
130
|
+
/**
|
|
131
|
+
* Create a new session for non logged in users
|
|
132
|
+
*/
|
|
133
|
+
async accountV1SessionCreate(request, options) {
|
|
134
|
+
return (0, fp_js_1.unwrapAsync)((0, accountAccountV1SessionCreate_js_1.accountAccountV1SessionCreate)(this, request, options));
|
|
135
|
+
}
|
|
129
136
|
}
|
|
130
137
|
exports.Account = Account;
|
|
131
138
|
//# sourceMappingURL=account.js.map
|
package/sdk/account.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"account.js","sourceRoot":"","sources":["../src/sdk/account.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,wGAAkG;AAClG,0HAAoH;AACpH,0HAAoH;AACpH,0HAAoH;AACpH,oFAA8E;AAC9E,wFAAkF;AAClF,gGAA0F;AAC1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C,EAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC;IACpF,CAAC;IAED;;OAEG;IACH,KAAK,CAAC,uBAAuB,CACzB,OAAkD,EAClD,OAAwB;QAExB,OAAO,IAAA,mBAAW,EAAC,IAAA,kEAA8B,EAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC;IAC/E,CAAC;IAED;;OAEG;IACH,KAAK,CAAC,6BAA6B,CAC/B,OAA6C,EAC7C,OAAwB;QAExB,OAAO,IAAA,mBAAW,EAAC,IAAA,8EAAoC,EAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC;IACrF,CAAC;IAED;;OAEG;IACH,KAAK,CAAC,mCAAmC,CACrC,OAAiD,EACjD,OAAwB;QAExB,OAAO,IAAA,mBAAW,EAAC,IAAA,0FAA0C,EAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC;IAC3F,CAAC;IAED;;OAEG;IACH,KAAK,CAAC,2BAA2B,CAC7B,OAA4C,EAC5C,OAAwB;QAExB,OAAO,IAAA,mBAAW,EAAC,IAAA,0EAAkC,EAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC;IACnF,CAAC;IAED;;OAEG;IACH,KAAK,CAAC,sBAAsB,CACxB,OAAiD,EACjD,OAAwB;QAExB,OAAO,IAAA,mBAAW,EAAC,IAAA,gEAA6B,EAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC;IAC9E,CAAC;CACJ;AAjLD,0BAiLC"}
|
package/sdk/session.d.ts
CHANGED
|
@@ -13,6 +13,10 @@ export declare class Session extends ClientSDK {
|
|
|
13
13
|
/**
|
|
14
14
|
* Logs a user in and creates a new session
|
|
15
15
|
*/
|
|
16
|
-
accountV1SessionLogin(request: operations.AccountV1SessionLoginRequest,
|
|
16
|
+
accountV1SessionLogin(request: operations.AccountV1SessionLoginRequest, options?: RequestOptions): Promise<operations.AccountV1SessionLoginResponse>;
|
|
17
|
+
/**
|
|
18
|
+
* Create a new session for non logged in users
|
|
19
|
+
*/
|
|
20
|
+
accountV1SessionCreate(request: operations.AccountV1SessionCreateRequest, options?: RequestOptions): Promise<operations.AccountV1SessionCreateResponse>;
|
|
17
21
|
}
|
|
18
22
|
//# sourceMappingURL=session.d.ts.map
|
package/sdk/session.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"session.d.ts","sourceRoot":"","sources":["../src/sdk/session.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"session.d.ts","sourceRoot":"","sources":["../src/sdk/session.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAG5D,qBAAa,OAAQ,SAAQ,SAAS;IAClC;;OAEG;IACG,sBAAsB,CACxB,OAAO,EAAE,UAAU,CAAC,0BAA0B,EAC9C,OAAO,CAAC,EAAE,cAAc,GACzB,OAAO,CAAC,UAAU,CAAC,8BAA8B,CAAC;IAIrD;;OAEG;IACG,mBAAmB,CACrB,OAAO,CAAC,EAAE,cAAc,GACzB,OAAO,CAAC,UAAU,CAAC,2BAA2B,CAAC;IAIlD;;OAEG;IACG,qBAAqB,CACvB,OAAO,EAAE,UAAU,CAAC,4BAA4B,EAChD,OAAO,CAAC,EAAE,cAAc,GACzB,OAAO,CAAC,UAAU,CAAC,6BAA6B,CAAC;IAIpD;;OAEG;IACG,sBAAsB,CACxB,OAAO,EAAE,UAAU,CAAC,6BAA6B,EACjD,OAAO,CAAC,EAAE,cAAc,GACzB,OAAO,CAAC,UAAU,CAAC,8BAA8B,CAAC;CAGxD"}
|
package/sdk/session.js
CHANGED
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.Session = void 0;
|
|
7
|
+
const sessionAccountV1SessionCreate_js_1 = require("../funcs/sessionAccountV1SessionCreate.js");
|
|
7
8
|
const sessionAccountV1SessionDelete_js_1 = require("../funcs/sessionAccountV1SessionDelete.js");
|
|
8
9
|
const sessionAccountV1SessionGet_js_1 = require("../funcs/sessionAccountV1SessionGet.js");
|
|
9
10
|
const sessionAccountV1SessionLogin_js_1 = require("../funcs/sessionAccountV1SessionLogin.js");
|
|
@@ -25,8 +26,14 @@ class Session extends sdks_js_1.ClientSDK {
|
|
|
25
26
|
/**
|
|
26
27
|
* Logs a user in and creates a new session
|
|
27
28
|
*/
|
|
28
|
-
async accountV1SessionLogin(request,
|
|
29
|
-
return (0, fp_js_1.unwrapAsync)((0, sessionAccountV1SessionLogin_js_1.sessionAccountV1SessionLogin)(this, request,
|
|
29
|
+
async accountV1SessionLogin(request, options) {
|
|
30
|
+
return (0, fp_js_1.unwrapAsync)((0, sessionAccountV1SessionLogin_js_1.sessionAccountV1SessionLogin)(this, request, options));
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Create a new session for non logged in users
|
|
34
|
+
*/
|
|
35
|
+
async accountV1SessionCreate(request, options) {
|
|
36
|
+
return (0, fp_js_1.unwrapAsync)((0, sessionAccountV1SessionCreate_js_1.sessionAccountV1SessionCreate)(this, request, options));
|
|
30
37
|
}
|
|
31
38
|
}
|
|
32
39
|
exports.Session = Session;
|
package/sdk/session.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"session.js","sourceRoot":"","sources":["../src/sdk/session.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,gGAA0F;AAC1F,0FAAoF;AACpF,8FAAwF;AACxF,4CAA2D;AAG3D,0CAA6C;AAE7C,MAAa,OAAQ,SAAQ,mBAAS;IAClC;;OAEG;IACH,KAAK,CAAC,sBAAsB,CACxB,OAA8C,EAC9C,OAAwB;QAExB,OAAO,IAAA,m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-3,13 +3,12 @@
|
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
5
|
import { SteamSetsCore } from "../core.js";
|
|
6
|
-
import { encodeJSON as encodeJSON$ } from "../lib/encodings.js";
|
|
6
|
+
import { encodeJSON as encodeJSON$, encodeSimple as encodeSimple$ } from "../lib/encodings.js";
|
|
7
7
|
import * as m$ from "../lib/matchers.js";
|
|
8
8
|
import * as schemas$ from "../lib/schemas.js";
|
|
9
9
|
import { RequestOptions } from "../lib/sdks.js";
|
|
10
10
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
11
11
|
import { pathToFunc } from "../lib/url.js";
|
|
12
|
-
import * as components from "../models/components/index.js";
|
|
13
12
|
import {
|
|
14
13
|
ConnectionError,
|
|
15
14
|
InvalidRequestError,
|
|
@@ -28,7 +27,7 @@ import { Result } from "../types/fp.js";
|
|
|
28
27
|
*/
|
|
29
28
|
export async function accountAccountV1GetApps(
|
|
30
29
|
client$: SteamSetsCore,
|
|
31
|
-
request:
|
|
30
|
+
request: operations.AccountV1GetAppsRequest,
|
|
32
31
|
options?: RequestOptions
|
|
33
32
|
): Promise<
|
|
34
33
|
Result<
|
|
@@ -47,20 +46,24 @@ export async function accountAccountV1GetApps(
|
|
|
47
46
|
|
|
48
47
|
const parsed$ = schemas$.safeParse(
|
|
49
48
|
input$,
|
|
50
|
-
(value$) =>
|
|
49
|
+
(value$) => operations.AccountV1GetAppsRequest$outboundSchema.parse(value$),
|
|
51
50
|
"Input validation failed"
|
|
52
51
|
);
|
|
53
52
|
if (!parsed$.ok) {
|
|
54
53
|
return parsed$;
|
|
55
54
|
}
|
|
56
55
|
const payload$ = parsed$.value;
|
|
57
|
-
const body$ = encodeJSON$("body", payload
|
|
56
|
+
const body$ = encodeJSON$("body", payload$.AccountSearch, { explode: true });
|
|
58
57
|
|
|
59
58
|
const path$ = pathToFunc("/account.v1.AccountService/GetApps")();
|
|
60
59
|
|
|
61
60
|
const headers$ = new Headers({
|
|
62
61
|
"Content-Type": "application/json",
|
|
63
62
|
Accept: "application/json",
|
|
63
|
+
"X-Forwarded-For": encodeSimple$("X-Forwarded-For", payload$["X-Forwarded-For"], {
|
|
64
|
+
explode: false,
|
|
65
|
+
charEncoding: "none",
|
|
66
|
+
}),
|
|
64
67
|
});
|
|
65
68
|
|
|
66
69
|
const session$ = await extractSecurity(client$.options$.session);
|
|
@@ -3,13 +3,12 @@
|
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
5
|
import { SteamSetsCore } from "../core.js";
|
|
6
|
-
import { encodeJSON as encodeJSON$ } from "../lib/encodings.js";
|
|
6
|
+
import { encodeJSON as encodeJSON$, encodeSimple as encodeSimple$ } from "../lib/encodings.js";
|
|
7
7
|
import * as m$ from "../lib/matchers.js";
|
|
8
8
|
import * as schemas$ from "../lib/schemas.js";
|
|
9
9
|
import { RequestOptions } from "../lib/sdks.js";
|
|
10
10
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
11
11
|
import { pathToFunc } from "../lib/url.js";
|
|
12
|
-
import * as components from "../models/components/index.js";
|
|
13
12
|
import {
|
|
14
13
|
ConnectionError,
|
|
15
14
|
InvalidRequestError,
|
|
@@ -28,7 +27,7 @@ import { Result } from "../types/fp.js";
|
|
|
28
27
|
*/
|
|
29
28
|
export async function accountAccountV1GetBadges(
|
|
30
29
|
client$: SteamSetsCore,
|
|
31
|
-
request:
|
|
30
|
+
request: operations.AccountV1GetBadgesRequest,
|
|
32
31
|
options?: RequestOptions
|
|
33
32
|
): Promise<
|
|
34
33
|
Result<
|
|
@@ -47,20 +46,24 @@ export async function accountAccountV1GetBadges(
|
|
|
47
46
|
|
|
48
47
|
const parsed$ = schemas$.safeParse(
|
|
49
48
|
input$,
|
|
50
|
-
(value$) =>
|
|
49
|
+
(value$) => operations.AccountV1GetBadgesRequest$outboundSchema.parse(value$),
|
|
51
50
|
"Input validation failed"
|
|
52
51
|
);
|
|
53
52
|
if (!parsed$.ok) {
|
|
54
53
|
return parsed$;
|
|
55
54
|
}
|
|
56
55
|
const payload$ = parsed$.value;
|
|
57
|
-
const body$ = encodeJSON$("body", payload
|
|
56
|
+
const body$ = encodeJSON$("body", payload$.AccountSearch, { explode: true });
|
|
58
57
|
|
|
59
58
|
const path$ = pathToFunc("/account.v1.AccountService/GetBadges")();
|
|
60
59
|
|
|
61
60
|
const headers$ = new Headers({
|
|
62
61
|
"Content-Type": "application/json",
|
|
63
62
|
Accept: "application/json",
|
|
63
|
+
"X-Forwarded-For": encodeSimple$("X-Forwarded-For", payload$["X-Forwarded-For"], {
|
|
64
|
+
explode: false,
|
|
65
|
+
charEncoding: "none",
|
|
66
|
+
}),
|
|
64
67
|
});
|
|
65
68
|
|
|
66
69
|
const session$ = await extractSecurity(client$.options$.session);
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import { SteamSetsCore } from "../core.js";
|
|
6
|
+
import { encodeSimple as encodeSimple$ } from "../lib/encodings.js";
|
|
7
|
+
import * as m$ from "../lib/matchers.js";
|
|
8
|
+
import * as schemas$ from "../lib/schemas.js";
|
|
9
|
+
import { RequestOptions } from "../lib/sdks.js";
|
|
10
|
+
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
11
|
+
import { pathToFunc } from "../lib/url.js";
|
|
12
|
+
import {
|
|
13
|
+
ConnectionError,
|
|
14
|
+
InvalidRequestError,
|
|
15
|
+
RequestAbortedError,
|
|
16
|
+
RequestTimeoutError,
|
|
17
|
+
UnexpectedClientError,
|
|
18
|
+
} from "../models/errors/httpclienterrors.js";
|
|
19
|
+
import * as errors from "../models/errors/index.js";
|
|
20
|
+
import { SDKError } from "../models/errors/sdkerror.js";
|
|
21
|
+
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
22
|
+
import * as operations from "../models/operations/index.js";
|
|
23
|
+
import { Result } from "../types/fp.js";
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* Create a new session for non logged in users
|
|
27
|
+
*/
|
|
28
|
+
export async function accountAccountV1SessionCreate(
|
|
29
|
+
client$: SteamSetsCore,
|
|
30
|
+
request: operations.AccountV1SessionCreateRequest,
|
|
31
|
+
options?: RequestOptions
|
|
32
|
+
): Promise<
|
|
33
|
+
Result<
|
|
34
|
+
operations.AccountV1SessionCreateResponse,
|
|
35
|
+
| errors.ErrorModel
|
|
36
|
+
| SDKError
|
|
37
|
+
| SDKValidationError
|
|
38
|
+
| UnexpectedClientError
|
|
39
|
+
| InvalidRequestError
|
|
40
|
+
| RequestAbortedError
|
|
41
|
+
| RequestTimeoutError
|
|
42
|
+
| ConnectionError
|
|
43
|
+
>
|
|
44
|
+
> {
|
|
45
|
+
const input$ = typeof request === "undefined" ? {} : request;
|
|
46
|
+
|
|
47
|
+
const parsed$ = schemas$.safeParse(
|
|
48
|
+
input$,
|
|
49
|
+
(value$) => operations.AccountV1SessionCreateRequest$outboundSchema.parse(value$),
|
|
50
|
+
"Input validation failed"
|
|
51
|
+
);
|
|
52
|
+
if (!parsed$.ok) {
|
|
53
|
+
return parsed$;
|
|
54
|
+
}
|
|
55
|
+
const payload$ = parsed$.value;
|
|
56
|
+
const body$ = null;
|
|
57
|
+
|
|
58
|
+
const path$ = pathToFunc("/account.v1.AccountService/createSession")();
|
|
59
|
+
|
|
60
|
+
const headers$ = new Headers({
|
|
61
|
+
Accept: "application/json",
|
|
62
|
+
"User-Agent": encodeSimple$("User-Agent", payload$["User-Agent"], {
|
|
63
|
+
explode: false,
|
|
64
|
+
charEncoding: "none",
|
|
65
|
+
}),
|
|
66
|
+
"X-Fingerprint": encodeSimple$("X-Fingerprint", payload$["X-Fingerprint"], {
|
|
67
|
+
explode: false,
|
|
68
|
+
charEncoding: "none",
|
|
69
|
+
}),
|
|
70
|
+
"X-Forwarded-For": encodeSimple$("X-Forwarded-For", payload$["X-Forwarded-For"], {
|
|
71
|
+
explode: false,
|
|
72
|
+
charEncoding: "none",
|
|
73
|
+
}),
|
|
74
|
+
"X-Signed": encodeSimple$("X-Signed", payload$["X-Signed"], {
|
|
75
|
+
explode: false,
|
|
76
|
+
charEncoding: "none",
|
|
77
|
+
}),
|
|
78
|
+
});
|
|
79
|
+
|
|
80
|
+
const session$ = await extractSecurity(client$.options$.session);
|
|
81
|
+
const security$ = session$ == null ? {} : { session: session$ };
|
|
82
|
+
const context = {
|
|
83
|
+
operationID: "account.v1.session.create",
|
|
84
|
+
oAuth2Scopes: [],
|
|
85
|
+
securitySource: client$.options$.session,
|
|
86
|
+
};
|
|
87
|
+
const securitySettings$ = resolveGlobalSecurity(security$);
|
|
88
|
+
|
|
89
|
+
const requestRes = client$.createRequest$(
|
|
90
|
+
context,
|
|
91
|
+
{
|
|
92
|
+
security: securitySettings$,
|
|
93
|
+
method: "POST",
|
|
94
|
+
path: path$,
|
|
95
|
+
headers: headers$,
|
|
96
|
+
body: body$,
|
|
97
|
+
uaHeader: "x-speakeasy-user-agent",
|
|
98
|
+
timeoutMs: options?.timeoutMs || client$.options$.timeoutMs || -1,
|
|
99
|
+
},
|
|
100
|
+
options
|
|
101
|
+
);
|
|
102
|
+
if (!requestRes.ok) {
|
|
103
|
+
return requestRes;
|
|
104
|
+
}
|
|
105
|
+
const request$ = requestRes.value;
|
|
106
|
+
|
|
107
|
+
const doResult = await client$.do$(request$, {
|
|
108
|
+
context,
|
|
109
|
+
errorCodes: ["422", "4XX", "500", "5XX"],
|
|
110
|
+
retryConfig: options?.retries || client$.options$.retryConfig,
|
|
111
|
+
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
|
|
112
|
+
});
|
|
113
|
+
if (!doResult.ok) {
|
|
114
|
+
return doResult;
|
|
115
|
+
}
|
|
116
|
+
const response = doResult.value;
|
|
117
|
+
|
|
118
|
+
const responseFields$ = {
|
|
119
|
+
HttpMeta: { Response: response, Request: request$ },
|
|
120
|
+
};
|
|
121
|
+
|
|
122
|
+
const [result$] = await m$.match<
|
|
123
|
+
operations.AccountV1SessionCreateResponse,
|
|
124
|
+
| errors.ErrorModel
|
|
125
|
+
| SDKError
|
|
126
|
+
| SDKValidationError
|
|
127
|
+
| UnexpectedClientError
|
|
128
|
+
| InvalidRequestError
|
|
129
|
+
| RequestAbortedError
|
|
130
|
+
| RequestTimeoutError
|
|
131
|
+
| ConnectionError
|
|
132
|
+
>(
|
|
133
|
+
m$.json(200, operations.AccountV1SessionCreateResponse$inboundSchema, {
|
|
134
|
+
key: "V1CreateSessionBody",
|
|
135
|
+
}),
|
|
136
|
+
m$.jsonErr([422, 500], errors.ErrorModel$inboundSchema, {
|
|
137
|
+
ctype: "application/problem+json",
|
|
138
|
+
}),
|
|
139
|
+
m$.fail(["4XX", "5XX"])
|
|
140
|
+
)(response, request$, { extraFields: responseFields$ });
|
|
141
|
+
if (!result$.ok) {
|
|
142
|
+
return result$;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
return result$;
|
|
146
|
+
}
|
|
@@ -7,7 +7,7 @@ import { encodeJSON as encodeJSON$, encodeSimple as encodeSimple$ } from "../lib
|
|
|
7
7
|
import * as m$ from "../lib/matchers.js";
|
|
8
8
|
import * as schemas$ from "../lib/schemas.js";
|
|
9
9
|
import { RequestOptions } from "../lib/sdks.js";
|
|
10
|
-
import {
|
|
10
|
+
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
11
11
|
import { pathToFunc } from "../lib/url.js";
|
|
12
12
|
import {
|
|
13
13
|
ConnectionError,
|
|
@@ -28,7 +28,6 @@ import { Result } from "../types/fp.js";
|
|
|
28
28
|
export async function accountAccountV1SessionLogin(
|
|
29
29
|
client$: SteamSetsCore,
|
|
30
30
|
request: operations.AccountV1SessionLoginRequest,
|
|
31
|
-
security: operations.AccountV1SessionLoginSecurity,
|
|
32
31
|
options?: RequestOptions
|
|
33
32
|
): Promise<
|
|
34
33
|
Result<
|
|
@@ -71,21 +70,14 @@ export async function accountAccountV1SessionLogin(
|
|
|
71
70
|
}),
|
|
72
71
|
});
|
|
73
72
|
|
|
74
|
-
const
|
|
75
|
-
|
|
76
|
-
{
|
|
77
|
-
fieldName: "Authorization",
|
|
78
|
-
type: "http:bearer",
|
|
79
|
-
value: security?.anonymous,
|
|
80
|
-
},
|
|
81
|
-
],
|
|
82
|
-
];
|
|
83
|
-
const securitySettings$ = resolveSecurity(...security$);
|
|
73
|
+
const session$ = await extractSecurity(client$.options$.session);
|
|
74
|
+
const security$ = session$ == null ? {} : { session: session$ };
|
|
84
75
|
const context = {
|
|
85
76
|
operationID: "account.v1.session.login",
|
|
86
77
|
oAuth2Scopes: [],
|
|
87
|
-
securitySource:
|
|
78
|
+
securitySource: client$.options$.session,
|
|
88
79
|
};
|
|
80
|
+
const securitySettings$ = resolveGlobalSecurity(security$);
|
|
89
81
|
|
|
90
82
|
const requestRes = client$.createRequest$(
|
|
91
83
|
context,
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import { SteamSetsCore } from "../core.js";
|
|
6
|
+
import { encodeSimple as encodeSimple$ } from "../lib/encodings.js";
|
|
7
|
+
import * as m$ from "../lib/matchers.js";
|
|
8
|
+
import * as schemas$ from "../lib/schemas.js";
|
|
9
|
+
import { RequestOptions } from "../lib/sdks.js";
|
|
10
|
+
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
11
|
+
import { pathToFunc } from "../lib/url.js";
|
|
12
|
+
import {
|
|
13
|
+
ConnectionError,
|
|
14
|
+
InvalidRequestError,
|
|
15
|
+
RequestAbortedError,
|
|
16
|
+
RequestTimeoutError,
|
|
17
|
+
UnexpectedClientError,
|
|
18
|
+
} from "../models/errors/httpclienterrors.js";
|
|
19
|
+
import * as errors from "../models/errors/index.js";
|
|
20
|
+
import { SDKError } from "../models/errors/sdkerror.js";
|
|
21
|
+
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
22
|
+
import * as operations from "../models/operations/index.js";
|
|
23
|
+
import { Result } from "../types/fp.js";
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* Create a new session for non logged in users
|
|
27
|
+
*/
|
|
28
|
+
export async function sessionAccountV1SessionCreate(
|
|
29
|
+
client$: SteamSetsCore,
|
|
30
|
+
request: operations.AccountV1SessionCreateRequest,
|
|
31
|
+
options?: RequestOptions
|
|
32
|
+
): Promise<
|
|
33
|
+
Result<
|
|
34
|
+
operations.AccountV1SessionCreateResponse,
|
|
35
|
+
| errors.ErrorModel
|
|
36
|
+
| SDKError
|
|
37
|
+
| SDKValidationError
|
|
38
|
+
| UnexpectedClientError
|
|
39
|
+
| InvalidRequestError
|
|
40
|
+
| RequestAbortedError
|
|
41
|
+
| RequestTimeoutError
|
|
42
|
+
| ConnectionError
|
|
43
|
+
>
|
|
44
|
+
> {
|
|
45
|
+
const input$ = typeof request === "undefined" ? {} : request;
|
|
46
|
+
|
|
47
|
+
const parsed$ = schemas$.safeParse(
|
|
48
|
+
input$,
|
|
49
|
+
(value$) => operations.AccountV1SessionCreateRequest$outboundSchema.parse(value$),
|
|
50
|
+
"Input validation failed"
|
|
51
|
+
);
|
|
52
|
+
if (!parsed$.ok) {
|
|
53
|
+
return parsed$;
|
|
54
|
+
}
|
|
55
|
+
const payload$ = parsed$.value;
|
|
56
|
+
const body$ = null;
|
|
57
|
+
|
|
58
|
+
const path$ = pathToFunc("/account.v1.AccountService/createSession")();
|
|
59
|
+
|
|
60
|
+
const headers$ = new Headers({
|
|
61
|
+
Accept: "application/json",
|
|
62
|
+
"User-Agent": encodeSimple$("User-Agent", payload$["User-Agent"], {
|
|
63
|
+
explode: false,
|
|
64
|
+
charEncoding: "none",
|
|
65
|
+
}),
|
|
66
|
+
"X-Fingerprint": encodeSimple$("X-Fingerprint", payload$["X-Fingerprint"], {
|
|
67
|
+
explode: false,
|
|
68
|
+
charEncoding: "none",
|
|
69
|
+
}),
|
|
70
|
+
"X-Forwarded-For": encodeSimple$("X-Forwarded-For", payload$["X-Forwarded-For"], {
|
|
71
|
+
explode: false,
|
|
72
|
+
charEncoding: "none",
|
|
73
|
+
}),
|
|
74
|
+
"X-Signed": encodeSimple$("X-Signed", payload$["X-Signed"], {
|
|
75
|
+
explode: false,
|
|
76
|
+
charEncoding: "none",
|
|
77
|
+
}),
|
|
78
|
+
});
|
|
79
|
+
|
|
80
|
+
const session$ = await extractSecurity(client$.options$.session);
|
|
81
|
+
const security$ = session$ == null ? {} : { session: session$ };
|
|
82
|
+
const context = {
|
|
83
|
+
operationID: "account.v1.session.create",
|
|
84
|
+
oAuth2Scopes: [],
|
|
85
|
+
securitySource: client$.options$.session,
|
|
86
|
+
};
|
|
87
|
+
const securitySettings$ = resolveGlobalSecurity(security$);
|
|
88
|
+
|
|
89
|
+
const requestRes = client$.createRequest$(
|
|
90
|
+
context,
|
|
91
|
+
{
|
|
92
|
+
security: securitySettings$,
|
|
93
|
+
method: "POST",
|
|
94
|
+
path: path$,
|
|
95
|
+
headers: headers$,
|
|
96
|
+
body: body$,
|
|
97
|
+
uaHeader: "x-speakeasy-user-agent",
|
|
98
|
+
timeoutMs: options?.timeoutMs || client$.options$.timeoutMs || -1,
|
|
99
|
+
},
|
|
100
|
+
options
|
|
101
|
+
);
|
|
102
|
+
if (!requestRes.ok) {
|
|
103
|
+
return requestRes;
|
|
104
|
+
}
|
|
105
|
+
const request$ = requestRes.value;
|
|
106
|
+
|
|
107
|
+
const doResult = await client$.do$(request$, {
|
|
108
|
+
context,
|
|
109
|
+
errorCodes: ["422", "4XX", "500", "5XX"],
|
|
110
|
+
retryConfig: options?.retries || client$.options$.retryConfig,
|
|
111
|
+
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
|
|
112
|
+
});
|
|
113
|
+
if (!doResult.ok) {
|
|
114
|
+
return doResult;
|
|
115
|
+
}
|
|
116
|
+
const response = doResult.value;
|
|
117
|
+
|
|
118
|
+
const responseFields$ = {
|
|
119
|
+
HttpMeta: { Response: response, Request: request$ },
|
|
120
|
+
};
|
|
121
|
+
|
|
122
|
+
const [result$] = await m$.match<
|
|
123
|
+
operations.AccountV1SessionCreateResponse,
|
|
124
|
+
| errors.ErrorModel
|
|
125
|
+
| SDKError
|
|
126
|
+
| SDKValidationError
|
|
127
|
+
| UnexpectedClientError
|
|
128
|
+
| InvalidRequestError
|
|
129
|
+
| RequestAbortedError
|
|
130
|
+
| RequestTimeoutError
|
|
131
|
+
| ConnectionError
|
|
132
|
+
>(
|
|
133
|
+
m$.json(200, operations.AccountV1SessionCreateResponse$inboundSchema, {
|
|
134
|
+
key: "V1CreateSessionBody",
|
|
135
|
+
}),
|
|
136
|
+
m$.jsonErr([422, 500], errors.ErrorModel$inboundSchema, {
|
|
137
|
+
ctype: "application/problem+json",
|
|
138
|
+
}),
|
|
139
|
+
m$.fail(["4XX", "5XX"])
|
|
140
|
+
)(response, request$, { extraFields: responseFields$ });
|
|
141
|
+
if (!result$.ok) {
|
|
142
|
+
return result$;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
return result$;
|
|
146
|
+
}
|
|
@@ -7,7 +7,7 @@ import { encodeJSON as encodeJSON$, encodeSimple as encodeSimple$ } from "../lib
|
|
|
7
7
|
import * as m$ from "../lib/matchers.js";
|
|
8
8
|
import * as schemas$ from "../lib/schemas.js";
|
|
9
9
|
import { RequestOptions } from "../lib/sdks.js";
|
|
10
|
-
import {
|
|
10
|
+
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
11
11
|
import { pathToFunc } from "../lib/url.js";
|
|
12
12
|
import {
|
|
13
13
|
ConnectionError,
|
|
@@ -28,7 +28,6 @@ import { Result } from "../types/fp.js";
|
|
|
28
28
|
export async function sessionAccountV1SessionLogin(
|
|
29
29
|
client$: SteamSetsCore,
|
|
30
30
|
request: operations.AccountV1SessionLoginRequest,
|
|
31
|
-
security: operations.AccountV1SessionLoginSecurity,
|
|
32
31
|
options?: RequestOptions
|
|
33
32
|
): Promise<
|
|
34
33
|
Result<
|
|
@@ -71,21 +70,14 @@ export async function sessionAccountV1SessionLogin(
|
|
|
71
70
|
}),
|
|
72
71
|
});
|
|
73
72
|
|
|
74
|
-
const
|
|
75
|
-
|
|
76
|
-
{
|
|
77
|
-
fieldName: "Authorization",
|
|
78
|
-
type: "http:bearer",
|
|
79
|
-
value: security?.anonymous,
|
|
80
|
-
},
|
|
81
|
-
],
|
|
82
|
-
];
|
|
83
|
-
const securitySettings$ = resolveSecurity(...security$);
|
|
73
|
+
const session$ = await extractSecurity(client$.options$.session);
|
|
74
|
+
const security$ = session$ == null ? {} : { session: session$ };
|
|
84
75
|
const context = {
|
|
85
76
|
operationID: "account.v1.session.login",
|
|
86
77
|
oAuth2Scopes: [],
|
|
87
|
-
securitySource:
|
|
78
|
+
securitySource: client$.options$.session,
|
|
88
79
|
};
|
|
80
|
+
const securitySettings$ = resolveGlobalSecurity(security$);
|
|
89
81
|
|
|
90
82
|
const requestRes = client$.createRequest$(
|
|
91
83
|
context,
|
package/src/lib/config.ts
CHANGED
|
@@ -52,7 +52,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
|
|
|
52
52
|
export const SDK_METADATA = {
|
|
53
53
|
language: "typescript",
|
|
54
54
|
openapiDocVersion: "1.0.0",
|
|
55
|
-
sdkVersion: "0.
|
|
55
|
+
sdkVersion: "0.5.0",
|
|
56
56
|
genVersion: "2.404.3",
|
|
57
|
-
userAgent: "speakeasy-sdk/typescript 0.
|
|
57
|
+
userAgent: "speakeasy-sdk/typescript 0.5.0 2.404.3 1.0.0 @steamsets/client-ts",
|
|
58
58
|
} as const;
|
|
@@ -21,11 +21,11 @@ export type AccountSearchVanityStruct = {
|
|
|
21
21
|
/**
|
|
22
22
|
* Which type of vanity to search for
|
|
23
23
|
*/
|
|
24
|
-
type
|
|
24
|
+
type: Type;
|
|
25
25
|
/**
|
|
26
26
|
* Vanity to search for
|
|
27
27
|
*/
|
|
28
|
-
value
|
|
28
|
+
value: string;
|
|
29
29
|
};
|
|
30
30
|
|
|
31
31
|
/** @internal */
|
|
@@ -51,14 +51,14 @@ export const AccountSearchVanityStruct$inboundSchema: z.ZodType<
|
|
|
51
51
|
z.ZodTypeDef,
|
|
52
52
|
unknown
|
|
53
53
|
> = z.object({
|
|
54
|
-
type: Type$inboundSchema
|
|
55
|
-
value: z.string()
|
|
54
|
+
type: Type$inboundSchema,
|
|
55
|
+
value: z.string(),
|
|
56
56
|
});
|
|
57
57
|
|
|
58
58
|
/** @internal */
|
|
59
59
|
export type AccountSearchVanityStruct$Outbound = {
|
|
60
|
-
type
|
|
61
|
-
value
|
|
60
|
+
type: string;
|
|
61
|
+
value: string;
|
|
62
62
|
};
|
|
63
63
|
|
|
64
64
|
/** @internal */
|
|
@@ -67,8 +67,8 @@ export const AccountSearchVanityStruct$outboundSchema: z.ZodType<
|
|
|
67
67
|
z.ZodTypeDef,
|
|
68
68
|
AccountSearchVanityStruct
|
|
69
69
|
> = z.object({
|
|
70
|
-
type: Type$outboundSchema
|
|
71
|
-
value: z.string()
|
|
70
|
+
type: Type$outboundSchema,
|
|
71
|
+
value: z.string(),
|
|
72
72
|
});
|
|
73
73
|
|
|
74
74
|
/**
|
|
@@ -22,6 +22,7 @@ export * from "./v1badge.js";
|
|
|
22
22
|
export * from "./v1badgesresponsebody.js";
|
|
23
23
|
export * from "./v1connectrequestbody.js";
|
|
24
24
|
export * from "./v1connectresponsebody.js";
|
|
25
|
+
export * from "./v1createsessionbody.js";
|
|
25
26
|
export * from "./v1deleteconnectionrequestbody.js";
|
|
26
27
|
export * from "./v1deleteconnectionresponsebody.js";
|
|
27
28
|
export * from "./v1deleteimagesrequestbody.js";
|