@steamsets/client-ts 0.11.0 → 0.11.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (46) hide show
  1. package/README.md +0 -2
  2. package/docs/sdks/badge/README.md +0 -175
  3. package/lib/config.d.ts +2 -2
  4. package/lib/config.js +2 -2
  5. package/models/components/accountinfobody.d.ts +15 -10
  6. package/models/components/accountinfobody.d.ts.map +1 -1
  7. package/models/components/accountinfobody.js +12 -10
  8. package/models/components/accountinfobody.js.map +1 -1
  9. package/models/components/index.d.ts +0 -1
  10. package/models/components/index.d.ts.map +1 -1
  11. package/models/components/index.js +0 -1
  12. package/models/components/index.js.map +1 -1
  13. package/models/components/role.d.ts +6 -0
  14. package/models/components/role.d.ts.map +1 -1
  15. package/models/components/role.js +2 -0
  16. package/models/components/role.js.map +1 -1
  17. package/models/operations/index.d.ts +0 -1
  18. package/models/operations/index.d.ts.map +1 -1
  19. package/models/operations/index.js +0 -1
  20. package/models/operations/index.js.map +1 -1
  21. package/package.json +1 -1
  22. package/sdk/badge.d.ts +0 -4
  23. package/sdk/badge.d.ts.map +1 -1
  24. package/sdk/badge.js +0 -7
  25. package/sdk/badge.js.map +1 -1
  26. package/src/lib/config.ts +2 -2
  27. package/src/models/components/accountinfobody.ts +36 -23
  28. package/src/models/components/index.ts +0 -1
  29. package/src/models/components/role.ts +2 -0
  30. package/src/models/operations/index.ts +0 -1
  31. package/src/sdk/badge.ts +0 -15
  32. package/funcs/badgeBadgeV1Search.d.ts +0 -14
  33. package/funcs/badgeBadgeV1Search.d.ts.map +0 -1
  34. package/funcs/badgeBadgeV1Search.js +0 -97
  35. package/funcs/badgeBadgeV1Search.js.map +0 -1
  36. package/models/components/badgesearch.d.ts +0 -86
  37. package/models/components/badgesearch.d.ts.map +0 -1
  38. package/models/components/badgesearch.js +0 -70
  39. package/models/components/badgesearch.js.map +0 -1
  40. package/models/operations/badgev1search.d.ts +0 -26
  41. package/models/operations/badgev1search.d.ts.map +0 -1
  42. package/models/operations/badgev1search.js +0 -60
  43. package/models/operations/badgev1search.js.map +0 -1
  44. package/src/funcs/badgeBadgeV1Search.ts +0 -127
  45. package/src/models/components/badgesearch.ts +0 -118
  46. package/src/models/operations/badgev1search.ts +0 -55
@@ -1,60 +0,0 @@
1
- "use strict";
2
- /*
3
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
4
- */
5
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
- if (k2 === undefined) k2 = k;
7
- var desc = Object.getOwnPropertyDescriptor(m, k);
8
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
- desc = { enumerable: true, get: function() { return m[k]; } };
10
- }
11
- Object.defineProperty(o, k2, desc);
12
- }) : (function(o, m, k, k2) {
13
- if (k2 === undefined) k2 = k;
14
- o[k2] = m[k];
15
- }));
16
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
- Object.defineProperty(o, "default", { enumerable: true, value: v });
18
- }) : function(o, v) {
19
- o["default"] = v;
20
- });
21
- var __importStar = (this && this.__importStar) || function (mod) {
22
- if (mod && mod.__esModule) return mod;
23
- var result = {};
24
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
25
- __setModuleDefault(result, mod);
26
- return result;
27
- };
28
- Object.defineProperty(exports, "__esModule", { value: true });
29
- exports.BadgeV1SearchResponse$ = exports.BadgeV1SearchResponse$outboundSchema = exports.BadgeV1SearchResponse$inboundSchema = void 0;
30
- const z = __importStar(require("zod"));
31
- const primitives_js_1 = require("../../lib/primitives.js");
32
- const components = __importStar(require("../components/index.js"));
33
- /** @internal */
34
- exports.BadgeV1SearchResponse$inboundSchema = z.object({
35
- HttpMeta: components.HTTPMetadata$inboundSchema,
36
- }).transform((v) => {
37
- return (0, primitives_js_1.remap)(v, {
38
- "HttpMeta": "httpMeta",
39
- });
40
- });
41
- /** @internal */
42
- exports.BadgeV1SearchResponse$outboundSchema = z.object({
43
- httpMeta: components.HTTPMetadata$outboundSchema,
44
- }).transform((v) => {
45
- return (0, primitives_js_1.remap)(v, {
46
- httpMeta: "HttpMeta",
47
- });
48
- });
49
- /**
50
- * @internal
51
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
52
- */
53
- var BadgeV1SearchResponse$;
54
- (function (BadgeV1SearchResponse$) {
55
- /** @deprecated use `BadgeV1SearchResponse$inboundSchema` instead. */
56
- BadgeV1SearchResponse$.inboundSchema = exports.BadgeV1SearchResponse$inboundSchema;
57
- /** @deprecated use `BadgeV1SearchResponse$outboundSchema` instead. */
58
- BadgeV1SearchResponse$.outboundSchema = exports.BadgeV1SearchResponse$outboundSchema;
59
- })(BadgeV1SearchResponse$ || (exports.BadgeV1SearchResponse$ = BadgeV1SearchResponse$ = {}));
60
- //# sourceMappingURL=badgev1search.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"badgev1search.js","sourceRoot":"","sources":["../../src/models/operations/badgev1search.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAyB;AACzB,2DAA0D;AAC1D,mEAAqD;AAMrD,gBAAgB;AACH,QAAA,mCAAmC,GAI5C,CAAC,CAAC,MAAM,CAAC;IACX,QAAQ,EAAE,UAAU,CAAC,0BAA0B;CAChD,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,IAAA,qBAAM,EAAC,CAAC,EAAE;QACf,UAAU,EAAE,UAAU;KACvB,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAOH,gBAAgB;AACH,QAAA,oCAAoC,GAI7C,CAAC,CAAC,MAAM,CAAC;IACX,QAAQ,EAAE,UAAU,CAAC,2BAA2B;CACjD,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,IAAA,qBAAM,EAAC,CAAC,EAAE;QACf,QAAQ,EAAE,UAAU;KACrB,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAEH;;;GAGG;AACH,IAAiB,sBAAsB,CAOtC;AAPD,WAAiB,sBAAsB;IACrC,qEAAqE;IACxD,oCAAa,GAAG,2CAAmC,CAAC;IACjE,sEAAsE;IACzD,qCAAc,GAAG,4CAAoC,CAAC;AAGrE,CAAC,EAPgB,sBAAsB,sCAAtB,sBAAsB,QAOtC"}
@@ -1,127 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import { SteamSetsCore } from "../core.js";
6
- import { encodeJSON } from "../lib/encodings.js";
7
- import * as M from "../lib/matchers.js";
8
- import { safeParse } 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 * as components from "../models/components/index.js";
13
- import {
14
- ConnectionError,
15
- InvalidRequestError,
16
- RequestAbortedError,
17
- RequestTimeoutError,
18
- UnexpectedClientError,
19
- } from "../models/errors/httpclienterrors.js";
20
- import * as errors from "../models/errors/index.js";
21
- import { SDKError } from "../models/errors/sdkerror.js";
22
- import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
23
- import * as operations from "../models/operations/index.js";
24
- import { Result } from "../types/fp.js";
25
-
26
- /**
27
- * Search for badges
28
- */
29
- export async function badgeBadgeV1Search(
30
- client: SteamSetsCore,
31
- request: components.BadgeSearch,
32
- options?: RequestOptions,
33
- ): Promise<
34
- Result<
35
- operations.BadgeV1SearchResponse,
36
- | errors.ErrorModel
37
- | SDKError
38
- | SDKValidationError
39
- | UnexpectedClientError
40
- | InvalidRequestError
41
- | RequestAbortedError
42
- | RequestTimeoutError
43
- | ConnectionError
44
- >
45
- > {
46
- const input = request;
47
-
48
- const parsed = safeParse(
49
- input,
50
- (value) => components.BadgeSearch$outboundSchema.parse(value),
51
- "Input validation failed",
52
- );
53
- if (!parsed.ok) {
54
- return parsed;
55
- }
56
- const payload = parsed.value;
57
- const body = encodeJSON("body", payload, { explode: true });
58
-
59
- const path = pathToFunc("/badge.v1.BadgeService/Search")();
60
-
61
- const headers = new Headers({
62
- "Content-Type": "application/json",
63
- Accept: "application/problem+json",
64
- });
65
-
66
- const secConfig = await extractSecurity(client._options.session);
67
- const securityInput = secConfig == null ? {} : { session: secConfig };
68
- const context = {
69
- operationID: "badge.v1.search",
70
- oAuth2Scopes: [],
71
- securitySource: client._options.session,
72
- };
73
- const requestSecurity = resolveGlobalSecurity(securityInput);
74
-
75
- const requestRes = client._createRequest(context, {
76
- security: requestSecurity,
77
- method: "POST",
78
- path: path,
79
- headers: headers,
80
- body: body,
81
- uaHeader: "x-speakeasy-user-agent",
82
- timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
83
- }, options);
84
- if (!requestRes.ok) {
85
- return requestRes;
86
- }
87
- const req = requestRes.value;
88
-
89
- const doResult = await client._do(req, {
90
- context,
91
- errorCodes: ["403", "404", "422", "4XX", "500", "5XX"],
92
- retryConfig: options?.retries
93
- || client._options.retryConfig,
94
- retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
95
- });
96
- if (!doResult.ok) {
97
- return doResult;
98
- }
99
- const response = doResult.value;
100
-
101
- const responseFields = {
102
- HttpMeta: { Response: response, Request: req },
103
- };
104
-
105
- const [result] = await M.match<
106
- operations.BadgeV1SearchResponse,
107
- | errors.ErrorModel
108
- | SDKError
109
- | SDKValidationError
110
- | UnexpectedClientError
111
- | InvalidRequestError
112
- | RequestAbortedError
113
- | RequestTimeoutError
114
- | ConnectionError
115
- >(
116
- M.nil(204, operations.BadgeV1SearchResponse$inboundSchema),
117
- M.jsonErr([403, 404, 422, 500], errors.ErrorModel$inboundSchema, {
118
- ctype: "application/problem+json",
119
- }),
120
- M.fail(["4XX", "5XX"]),
121
- )(response, req, { extraFields: responseFields });
122
- if (!result.ok) {
123
- return result;
124
- }
125
-
126
- return result;
127
- }
@@ -1,118 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import * as z from "zod";
6
-
7
- export type BadgeSearch = {
8
- /**
9
- * The app id
10
- */
11
- appId: number | null;
12
- /**
13
- * The app ids
14
- */
15
- appIds: Array<number> | null;
16
- /**
17
- * The badge id
18
- */
19
- badgeId: string | null;
20
- /**
21
- * The badge ids
22
- */
23
- badgeIds: Array<string> | null;
24
- /**
25
- * The color tags you want to search for
26
- */
27
- colorSearch: Array<{ [k: string]: Array<string> }> | null;
28
- /**
29
- * Whether to include/exclude event badges
30
- */
31
- isEvent: boolean | null;
32
- /**
33
- * Whether to include/exclude foil badges
34
- */
35
- isFoil: boolean | null;
36
- /**
37
- * Whether to include/exclude sale badges
38
- */
39
- isSale: boolean | null;
40
- /**
41
- * The limit of results
42
- */
43
- limit: number | null;
44
- /**
45
- * The offset of results
46
- */
47
- offset: number | null;
48
- /**
49
- * The tags you want to search for
50
- */
51
- typeSearch: Array<{ [k: string]: Array<string> }> | null;
52
- };
53
-
54
- /** @internal */
55
- export const BadgeSearch$inboundSchema: z.ZodType<
56
- BadgeSearch,
57
- z.ZodTypeDef,
58
- unknown
59
- > = z.object({
60
- appId: z.nullable(z.number().int()),
61
- appIds: z.nullable(z.array(z.number().int())),
62
- badgeId: z.nullable(z.string()),
63
- badgeIds: z.nullable(z.array(z.string())),
64
- colorSearch: z.nullable(z.array(z.record(z.array(z.string())))),
65
- isEvent: z.nullable(z.boolean()),
66
- isFoil: z.nullable(z.boolean()),
67
- isSale: z.nullable(z.boolean()),
68
- limit: z.nullable(z.number().int()),
69
- offset: z.nullable(z.number().int()),
70
- typeSearch: z.nullable(z.array(z.record(z.array(z.string())))),
71
- });
72
-
73
- /** @internal */
74
- export type BadgeSearch$Outbound = {
75
- appId: number | null;
76
- appIds: Array<number> | null;
77
- badgeId: string | null;
78
- badgeIds: Array<string> | null;
79
- colorSearch: Array<{ [k: string]: Array<string> }> | null;
80
- isEvent: boolean | null;
81
- isFoil: boolean | null;
82
- isSale: boolean | null;
83
- limit: number | null;
84
- offset: number | null;
85
- typeSearch: Array<{ [k: string]: Array<string> }> | null;
86
- };
87
-
88
- /** @internal */
89
- export const BadgeSearch$outboundSchema: z.ZodType<
90
- BadgeSearch$Outbound,
91
- z.ZodTypeDef,
92
- BadgeSearch
93
- > = z.object({
94
- appId: z.nullable(z.number().int()),
95
- appIds: z.nullable(z.array(z.number().int())),
96
- badgeId: z.nullable(z.string()),
97
- badgeIds: z.nullable(z.array(z.string())),
98
- colorSearch: z.nullable(z.array(z.record(z.array(z.string())))),
99
- isEvent: z.nullable(z.boolean()),
100
- isFoil: z.nullable(z.boolean()),
101
- isSale: z.nullable(z.boolean()),
102
- limit: z.nullable(z.number().int()),
103
- offset: z.nullable(z.number().int()),
104
- typeSearch: z.nullable(z.array(z.record(z.array(z.string())))),
105
- });
106
-
107
- /**
108
- * @internal
109
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
110
- */
111
- export namespace BadgeSearch$ {
112
- /** @deprecated use `BadgeSearch$inboundSchema` instead. */
113
- export const inboundSchema = BadgeSearch$inboundSchema;
114
- /** @deprecated use `BadgeSearch$outboundSchema` instead. */
115
- export const outboundSchema = BadgeSearch$outboundSchema;
116
- /** @deprecated use `BadgeSearch$Outbound` instead. */
117
- export type Outbound = BadgeSearch$Outbound;
118
- }
@@ -1,55 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import * as z from "zod";
6
- import { remap as remap$ } from "../../lib/primitives.js";
7
- import * as components from "../components/index.js";
8
-
9
- export type BadgeV1SearchResponse = {
10
- httpMeta: components.HTTPMetadata;
11
- };
12
-
13
- /** @internal */
14
- export const BadgeV1SearchResponse$inboundSchema: z.ZodType<
15
- BadgeV1SearchResponse,
16
- z.ZodTypeDef,
17
- unknown
18
- > = z.object({
19
- HttpMeta: components.HTTPMetadata$inboundSchema,
20
- }).transform((v) => {
21
- return remap$(v, {
22
- "HttpMeta": "httpMeta",
23
- });
24
- });
25
-
26
- /** @internal */
27
- export type BadgeV1SearchResponse$Outbound = {
28
- HttpMeta: components.HTTPMetadata$Outbound;
29
- };
30
-
31
- /** @internal */
32
- export const BadgeV1SearchResponse$outboundSchema: z.ZodType<
33
- BadgeV1SearchResponse$Outbound,
34
- z.ZodTypeDef,
35
- BadgeV1SearchResponse
36
- > = z.object({
37
- httpMeta: components.HTTPMetadata$outboundSchema,
38
- }).transform((v) => {
39
- return remap$(v, {
40
- httpMeta: "HttpMeta",
41
- });
42
- });
43
-
44
- /**
45
- * @internal
46
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
47
- */
48
- export namespace BadgeV1SearchResponse$ {
49
- /** @deprecated use `BadgeV1SearchResponse$inboundSchema` instead. */
50
- export const inboundSchema = BadgeV1SearchResponse$inboundSchema;
51
- /** @deprecated use `BadgeV1SearchResponse$outboundSchema` instead. */
52
- export const outboundSchema = BadgeV1SearchResponse$outboundSchema;
53
- /** @deprecated use `BadgeV1SearchResponse$Outbound` instead. */
54
- export type Outbound = BadgeV1SearchResponse$Outbound;
55
- }