@steamsets/client-ts 0.33.4 → 0.33.6

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 (202) hide show
  1. package/README.md +20 -4
  2. package/funcs/accountAccountGetTrending.d.ts +16 -0
  3. package/funcs/accountAccountGetTrending.d.ts.map +1 -0
  4. package/funcs/accountAccountGetTrending.js +134 -0
  5. package/funcs/accountAccountGetTrending.js.map +1 -0
  6. package/funcs/accountGetInfo.d.ts +1 -2
  7. package/funcs/accountGetInfo.d.ts.map +1 -1
  8. package/funcs/accountGetInfo.js +11 -3
  9. package/funcs/accountGetInfo.js.map +1 -1
  10. package/funcs/accountGetViewStats.d.ts +16 -0
  11. package/funcs/accountGetViewStats.d.ts.map +1 -0
  12. package/funcs/accountGetViewStats.js +134 -0
  13. package/funcs/accountGetViewStats.js.map +1 -0
  14. package/funcs/{activityActivityListAccountFeed.d.ts → activityListAccountFeed.d.ts} +2 -2
  15. package/funcs/activityListAccountFeed.d.ts.map +1 -0
  16. package/funcs/{activityActivityListAccountFeed.js → activityListAccountFeed.js} +5 -5
  17. package/funcs/activityListAccountFeed.js.map +1 -0
  18. package/funcs/analyticsTrackEvent.d.ts +15 -0
  19. package/funcs/analyticsTrackEvent.d.ts.map +1 -0
  20. package/funcs/analyticsTrackEvent.js +144 -0
  21. package/funcs/analyticsTrackEvent.js.map +1 -0
  22. package/funcs/badgeSearch.js +8 -0
  23. package/funcs/badgeSearch.js.map +1 -1
  24. package/funcs/leaderboardGetBucketLeaders.d.ts +16 -0
  25. package/funcs/leaderboardGetBucketLeaders.d.ts.map +1 -0
  26. package/funcs/leaderboardGetBucketLeaders.js +134 -0
  27. package/funcs/leaderboardGetBucketLeaders.js.map +1 -0
  28. package/funcs/{leaderboardLeaderboardGetChanges.d.ts → leaderboardGetChanges.d.ts} +2 -2
  29. package/funcs/leaderboardGetChanges.d.ts.map +1 -0
  30. package/funcs/{leaderboardLeaderboardGetChanges.js → leaderboardGetChanges.js} +5 -5
  31. package/funcs/leaderboardGetChanges.js.map +1 -0
  32. package/funcs/searchSearchGetTrending.d.ts +16 -0
  33. package/funcs/searchSearchGetTrending.d.ts.map +1 -0
  34. package/funcs/searchSearchGetTrending.js +134 -0
  35. package/funcs/searchSearchGetTrending.js.map +1 -0
  36. package/jsr.json +1 -1
  37. package/lib/config.d.ts +2 -2
  38. package/lib/config.js +2 -2
  39. package/models/components/accountgettrendingrequestbody.d.ts +35 -0
  40. package/models/components/accountgettrendingrequestbody.d.ts.map +1 -0
  41. package/models/components/accountgettrendingrequestbody.js +61 -0
  42. package/models/components/accountgettrendingrequestbody.js.map +1 -0
  43. package/models/components/accountgettrendingresponsebody.d.ts +15 -0
  44. package/models/components/accountgettrendingresponsebody.d.ts.map +1 -0
  45. package/models/components/accountgettrendingresponsebody.js +57 -0
  46. package/models/components/accountgettrendingresponsebody.js.map +1 -0
  47. package/models/components/accountviewstats.d.ts +37 -0
  48. package/models/components/accountviewstats.d.ts.map +1 -0
  49. package/models/components/accountviewstats.js +61 -0
  50. package/models/components/accountviewstats.js.map +1 -0
  51. package/models/components/analyticstrackeventrequestbody.d.ts +38 -0
  52. package/models/components/analyticstrackeventrequestbody.d.ts.map +1 -0
  53. package/models/components/analyticstrackeventrequestbody.js +59 -0
  54. package/models/components/analyticstrackeventrequestbody.js.map +1 -0
  55. package/models/components/analyticstrackeventresponsebody.d.ts +14 -0
  56. package/models/components/analyticstrackeventresponsebody.d.ts.map +1 -0
  57. package/models/components/analyticstrackeventresponsebody.js +56 -0
  58. package/models/components/analyticstrackeventresponsebody.js.map +1 -0
  59. package/models/components/bucketleader.d.ts +26 -0
  60. package/models/components/bucketleader.d.ts.map +1 -0
  61. package/models/components/bucketleader.js +57 -0
  62. package/models/components/bucketleader.js.map +1 -0
  63. package/models/components/index.d.ts +11 -0
  64. package/models/components/index.d.ts.map +1 -1
  65. package/models/components/index.js +11 -0
  66. package/models/components/index.js.map +1 -1
  67. package/models/components/leaderboardgetchangesrequestbody.d.ts +4 -4
  68. package/models/components/leaderboardgetchangesrequestbody.d.ts.map +1 -1
  69. package/models/components/leaderboardgetchangesrequestbody.js +4 -5
  70. package/models/components/leaderboardgetchangesrequestbody.js.map +1 -1
  71. package/models/components/searchgettrendingrequestbody.d.ts +54 -0
  72. package/models/components/searchgettrendingrequestbody.d.ts.map +1 -0
  73. package/models/components/searchgettrendingrequestbody.js +72 -0
  74. package/models/components/searchgettrendingrequestbody.js.map +1 -0
  75. package/models/components/searchgettrendingresponsebody.d.ts +15 -0
  76. package/models/components/searchgettrendingresponsebody.d.ts.map +1 -0
  77. package/models/components/searchgettrendingresponsebody.js +57 -0
  78. package/models/components/searchgettrendingresponsebody.js.map +1 -0
  79. package/models/components/trendingaccount.d.ts +20 -0
  80. package/models/components/trendingaccount.d.ts.map +1 -0
  81. package/models/components/trendingaccount.js +54 -0
  82. package/models/components/trendingaccount.js.map +1 -0
  83. package/models/components/trendingsearch.d.ts +21 -0
  84. package/models/components/trendingsearch.d.ts.map +1 -0
  85. package/models/components/trendingsearch.js +52 -0
  86. package/models/components/trendingsearch.js.map +1 -0
  87. package/models/components/v1leaderboardgetbucketleadersrequestbody.d.ts +34 -0
  88. package/models/components/v1leaderboardgetbucketleadersrequestbody.d.ts.map +1 -0
  89. package/models/components/v1leaderboardgetbucketleadersrequestbody.js +59 -0
  90. package/models/components/v1leaderboardgetbucketleadersrequestbody.js.map +1 -0
  91. package/models/operations/accountgetinfo.d.ts +16 -0
  92. package/models/operations/accountgetinfo.d.ts.map +1 -1
  93. package/models/operations/accountgetinfo.js +19 -1
  94. package/models/operations/accountgetinfo.js.map +1 -1
  95. package/models/operations/accountgettrending.d.ts +15 -0
  96. package/models/operations/accountgettrending.d.ts.map +1 -0
  97. package/models/operations/accountgettrending.js +59 -0
  98. package/models/operations/accountgettrending.js.map +1 -0
  99. package/models/operations/badgesearchbadges.d.ts +4 -0
  100. package/models/operations/badgesearchbadges.d.ts.map +1 -1
  101. package/models/operations/badgesearchbadges.js +4 -0
  102. package/models/operations/badgesearchbadges.js.map +1 -1
  103. package/models/operations/getbucketleaders.d.ts +15 -0
  104. package/models/operations/getbucketleaders.d.ts.map +1 -0
  105. package/models/operations/getbucketleaders.js +59 -0
  106. package/models/operations/getbucketleaders.js.map +1 -0
  107. package/models/operations/{leaderboardgetchanges.d.ts → getchanges.d.ts} +4 -4
  108. package/models/operations/getchanges.d.ts.map +1 -0
  109. package/models/operations/{leaderboardgetchanges.js → getchanges.js} +6 -6
  110. package/models/operations/getchanges.js.map +1 -0
  111. package/models/operations/getviewstats.d.ts +15 -0
  112. package/models/operations/getviewstats.d.ts.map +1 -0
  113. package/models/operations/getviewstats.js +58 -0
  114. package/models/operations/getviewstats.js.map +1 -0
  115. package/models/operations/index.d.ts +7 -2
  116. package/models/operations/index.d.ts.map +1 -1
  117. package/models/operations/index.js +7 -2
  118. package/models/operations/index.js.map +1 -1
  119. package/models/operations/{activitylistaccountfeed.d.ts → listaccountfeed.d.ts} +4 -4
  120. package/models/operations/listaccountfeed.d.ts.map +1 -0
  121. package/models/operations/{activitylistaccountfeed.js → listaccountfeed.js} +6 -6
  122. package/models/operations/listaccountfeed.js.map +1 -0
  123. package/models/operations/searchgettrending.d.ts +15 -0
  124. package/models/operations/searchgettrending.d.ts.map +1 -0
  125. package/models/operations/searchgettrending.js +59 -0
  126. package/models/operations/searchgettrending.js.map +1 -0
  127. package/models/operations/trackevent.d.ts +31 -0
  128. package/models/operations/trackevent.d.ts.map +1 -0
  129. package/models/operations/trackevent.js +77 -0
  130. package/models/operations/trackevent.js.map +1 -0
  131. package/package.json +1 -1
  132. package/sdk/account.d.ts +9 -1
  133. package/sdk/account.d.ts.map +1 -1
  134. package/sdk/account.js +14 -0
  135. package/sdk/account.js.map +1 -1
  136. package/sdk/activity.d.ts +1 -1
  137. package/sdk/activity.d.ts.map +1 -1
  138. package/sdk/activity.js +3 -3
  139. package/sdk/activity.js.map +1 -1
  140. package/sdk/analytics.d.ts +9 -0
  141. package/sdk/analytics.d.ts.map +1 -0
  142. package/sdk/analytics.js +19 -0
  143. package/sdk/analytics.js.map +1 -0
  144. package/sdk/leaderboard.d.ts +5 -1
  145. package/sdk/leaderboard.d.ts.map +1 -1
  146. package/sdk/leaderboard.js +10 -3
  147. package/sdk/leaderboard.js.map +1 -1
  148. package/sdk/sdk.d.ts +6 -0
  149. package/sdk/sdk.d.ts.map +1 -1
  150. package/sdk/sdk.js +8 -0
  151. package/sdk/sdk.js.map +1 -1
  152. package/sdk/search.d.ts +10 -0
  153. package/sdk/search.d.ts.map +1 -0
  154. package/sdk/search.js +19 -0
  155. package/sdk/search.js.map +1 -0
  156. package/src/funcs/accountAccountGetTrending.ts +188 -0
  157. package/src/funcs/accountGetInfo.ts +18 -6
  158. package/src/funcs/accountGetViewStats.ts +187 -0
  159. package/src/funcs/{activityActivityListAccountFeed.ts → activityListAccountFeed.ts} +6 -6
  160. package/src/funcs/analyticsTrackEvent.ts +201 -0
  161. package/src/funcs/badgeSearch.ts +8 -0
  162. package/src/funcs/leaderboardGetBucketLeaders.ts +190 -0
  163. package/src/funcs/{leaderboardLeaderboardGetChanges.ts → leaderboardGetChanges.ts} +6 -6
  164. package/src/funcs/searchSearchGetTrending.ts +188 -0
  165. package/src/lib/config.ts +2 -2
  166. package/src/models/components/accountgettrendingrequestbody.ts +60 -0
  167. package/src/models/components/accountgettrendingresponsebody.ts +45 -0
  168. package/src/models/components/accountviewstats.ts +69 -0
  169. package/src/models/components/analyticstrackeventrequestbody.ts +62 -0
  170. package/src/models/components/analyticstrackeventresponsebody.ts +41 -0
  171. package/src/models/components/bucketleader.ts +56 -0
  172. package/src/models/components/index.ts +11 -0
  173. package/src/models/components/leaderboardgetchangesrequestbody.ts +10 -6
  174. package/src/models/components/searchgettrendingrequestbody.ts +86 -0
  175. package/src/models/components/searchgettrendingresponsebody.ts +45 -0
  176. package/src/models/components/trendingaccount.ts +47 -0
  177. package/src/models/components/trendingsearch.ts +44 -0
  178. package/src/models/components/v1leaderboardgetbucketleadersrequestbody.ts +64 -0
  179. package/src/models/operations/accountgetinfo.ts +42 -0
  180. package/src/models/operations/accountgettrending.ts +46 -0
  181. package/src/models/operations/badgesearchbadges.ts +8 -0
  182. package/src/models/operations/getbucketleaders.ts +44 -0
  183. package/src/models/operations/{leaderboardgetchanges.ts → getchanges.ts} +7 -7
  184. package/src/models/operations/getviewstats.ts +43 -0
  185. package/src/models/operations/index.ts +7 -2
  186. package/src/models/operations/{activitylistaccountfeed.ts → listaccountfeed.ts} +7 -7
  187. package/src/models/operations/searchgettrending.ts +46 -0
  188. package/src/models/operations/trackevent.ts +90 -0
  189. package/src/sdk/account.ts +31 -1
  190. package/src/sdk/activity.ts +4 -4
  191. package/src/sdk/analytics.ts +24 -0
  192. package/src/sdk/leaderboard.ts +19 -4
  193. package/src/sdk/sdk.ts +12 -0
  194. package/src/sdk/search.ts +25 -0
  195. package/funcs/activityActivityListAccountFeed.d.ts.map +0 -1
  196. package/funcs/activityActivityListAccountFeed.js.map +0 -1
  197. package/funcs/leaderboardLeaderboardGetChanges.d.ts.map +0 -1
  198. package/funcs/leaderboardLeaderboardGetChanges.js.map +0 -1
  199. package/models/operations/activitylistaccountfeed.d.ts.map +0 -1
  200. package/models/operations/activitylistaccountfeed.js.map +0 -1
  201. package/models/operations/leaderboardgetchanges.d.ts.map +0 -1
  202. package/models/operations/leaderboardgetchanges.js.map +0 -1
@@ -0,0 +1,64 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { ClosedEnum } from "../../types/enums.js";
7
+
8
+ /**
9
+ * xp buckets by level; apps buckets by the game-collector badge thresholds.
10
+ */
11
+ export const V1LeaderboardGetBucketLeadersRequestBodyLeaderboard = {
12
+ Xp: "xp",
13
+ Apps: "apps",
14
+ } as const;
15
+ /**
16
+ * xp buckets by level; apps buckets by the game-collector badge thresholds.
17
+ */
18
+ export type V1LeaderboardGetBucketLeadersRequestBodyLeaderboard = ClosedEnum<
19
+ typeof V1LeaderboardGetBucketLeadersRequestBodyLeaderboard
20
+ >;
21
+
22
+ export type V1LeaderboardGetBucketLeadersRequestBody = {
23
+ /**
24
+ * xp only: levels per bucket (default 10). Ignored for apps.
25
+ */
26
+ bucketSize?: number | undefined;
27
+ /**
28
+ * xp buckets by level; apps buckets by the game-collector badge thresholds.
29
+ */
30
+ leaderboard: V1LeaderboardGetBucketLeadersRequestBodyLeaderboard;
31
+ };
32
+
33
+ /** @internal */
34
+ export const V1LeaderboardGetBucketLeadersRequestBodyLeaderboard$outboundSchema:
35
+ z.ZodNativeEnum<typeof V1LeaderboardGetBucketLeadersRequestBodyLeaderboard> =
36
+ z.nativeEnum(V1LeaderboardGetBucketLeadersRequestBodyLeaderboard);
37
+
38
+ /** @internal */
39
+ export type V1LeaderboardGetBucketLeadersRequestBody$Outbound = {
40
+ bucketSize?: number | undefined;
41
+ leaderboard: string;
42
+ };
43
+
44
+ /** @internal */
45
+ export const V1LeaderboardGetBucketLeadersRequestBody$outboundSchema: z.ZodType<
46
+ V1LeaderboardGetBucketLeadersRequestBody$Outbound,
47
+ z.ZodTypeDef,
48
+ V1LeaderboardGetBucketLeadersRequestBody
49
+ > = z.object({
50
+ bucketSize: z.number().int().optional(),
51
+ leaderboard:
52
+ V1LeaderboardGetBucketLeadersRequestBodyLeaderboard$outboundSchema,
53
+ });
54
+
55
+ export function v1LeaderboardGetBucketLeadersRequestBodyToJSON(
56
+ v1LeaderboardGetBucketLeadersRequestBody:
57
+ V1LeaderboardGetBucketLeadersRequestBody,
58
+ ): string {
59
+ return JSON.stringify(
60
+ V1LeaderboardGetBucketLeadersRequestBody$outboundSchema.parse(
61
+ v1LeaderboardGetBucketLeadersRequestBody,
62
+ ),
63
+ );
64
+ }
@@ -9,6 +9,13 @@ import { Result as SafeParseResult } from "../../types/fp.js";
9
9
  import * as components from "../components/index.js";
10
10
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
11
 
12
+ export type AccountGetInfoRequest = {
13
+ xForwardedFor?: string | undefined;
14
+ userAgent?: string | undefined;
15
+ xVisitorId?: string | undefined;
16
+ accountSearch: components.AccountSearch;
17
+ };
18
+
12
19
  export type AccountGetInfoResponse = {
13
20
  httpMeta: components.HTTPMetadata;
14
21
  /**
@@ -19,6 +26,41 @@ export type AccountGetInfoResponse = {
19
26
  | undefined;
20
27
  };
21
28
 
29
+ /** @internal */
30
+ export type AccountGetInfoRequest$Outbound = {
31
+ "X-Forwarded-For"?: string | undefined;
32
+ "User-Agent"?: string | undefined;
33
+ "X-Visitor-Id"?: string | undefined;
34
+ AccountSearch: components.AccountSearch$Outbound;
35
+ };
36
+
37
+ /** @internal */
38
+ export const AccountGetInfoRequest$outboundSchema: z.ZodType<
39
+ AccountGetInfoRequest$Outbound,
40
+ z.ZodTypeDef,
41
+ AccountGetInfoRequest
42
+ > = z.object({
43
+ xForwardedFor: z.string().optional(),
44
+ userAgent: z.string().optional(),
45
+ xVisitorId: z.string().optional(),
46
+ accountSearch: components.AccountSearch$outboundSchema,
47
+ }).transform((v) => {
48
+ return remap$(v, {
49
+ xForwardedFor: "X-Forwarded-For",
50
+ userAgent: "User-Agent",
51
+ xVisitorId: "X-Visitor-Id",
52
+ accountSearch: "AccountSearch",
53
+ });
54
+ });
55
+
56
+ export function accountGetInfoRequestToJSON(
57
+ accountGetInfoRequest: AccountGetInfoRequest,
58
+ ): string {
59
+ return JSON.stringify(
60
+ AccountGetInfoRequest$outboundSchema.parse(accountGetInfoRequest),
61
+ );
62
+ }
63
+
22
64
  /** @internal */
23
65
  export const AccountGetInfoResponse$inboundSchema: z.ZodType<
24
66
  AccountGetInfoResponse,
@@ -0,0 +1,46 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import * as components from "../components/index.js";
10
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
+
12
+ export type AccountGetTrendingResponse = {
13
+ httpMeta: components.HTTPMetadata;
14
+ /**
15
+ * OK
16
+ */
17
+ accountGetTrendingResponseBody?:
18
+ | components.AccountGetTrendingResponseBody
19
+ | undefined;
20
+ };
21
+
22
+ /** @internal */
23
+ export const AccountGetTrendingResponse$inboundSchema: z.ZodType<
24
+ AccountGetTrendingResponse,
25
+ z.ZodTypeDef,
26
+ unknown
27
+ > = z.object({
28
+ HttpMeta: components.HTTPMetadata$inboundSchema,
29
+ AccountGetTrendingResponseBody: components
30
+ .AccountGetTrendingResponseBody$inboundSchema.optional(),
31
+ }).transform((v) => {
32
+ return remap$(v, {
33
+ "HttpMeta": "httpMeta",
34
+ "AccountGetTrendingResponseBody": "accountGetTrendingResponseBody",
35
+ });
36
+ });
37
+
38
+ export function accountGetTrendingResponseFromJSON(
39
+ jsonString: string,
40
+ ): SafeParseResult<AccountGetTrendingResponse, SDKValidationError> {
41
+ return safeParse(
42
+ jsonString,
43
+ (x) => AccountGetTrendingResponse$inboundSchema.parse(JSON.parse(x)),
44
+ `Failed to parse 'AccountGetTrendingResponse' from JSON`,
45
+ );
46
+ }
@@ -11,6 +11,8 @@ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
11
 
12
12
  export type BadgeSearchBadgesRequest = {
13
13
  xForwardedFor?: string | undefined;
14
+ userAgent?: string | undefined;
15
+ xVisitorId?: string | undefined;
14
16
  v1SearchRequest: components.V1SearchRequest;
15
17
  };
16
18
 
@@ -27,6 +29,8 @@ export type BadgeSearchBadgesResponse = {
27
29
  /** @internal */
28
30
  export type BadgeSearchBadgesRequest$Outbound = {
29
31
  "X-Forwarded-For"?: string | undefined;
32
+ "User-Agent"?: string | undefined;
33
+ "X-Visitor-Id"?: string | undefined;
30
34
  V1SearchRequest: components.V1SearchRequest$Outbound;
31
35
  };
32
36
 
@@ -37,10 +41,14 @@ export const BadgeSearchBadgesRequest$outboundSchema: z.ZodType<
37
41
  BadgeSearchBadgesRequest
38
42
  > = z.object({
39
43
  xForwardedFor: z.string().optional(),
44
+ userAgent: z.string().optional(),
45
+ xVisitorId: z.string().optional(),
40
46
  v1SearchRequest: components.V1SearchRequest$outboundSchema,
41
47
  }).transform((v) => {
42
48
  return remap$(v, {
43
49
  xForwardedFor: "X-Forwarded-For",
50
+ userAgent: "User-Agent",
51
+ xVisitorId: "X-Visitor-Id",
44
52
  v1SearchRequest: "V1SearchRequest",
45
53
  });
46
54
  });
@@ -0,0 +1,44 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import * as components from "../components/index.js";
10
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
+
12
+ export type GetBucketLeadersResponse = {
13
+ httpMeta: components.HTTPMetadata;
14
+ /**
15
+ * OK
16
+ */
17
+ bucketLeaders?: Array<components.BucketLeader> | null | undefined;
18
+ };
19
+
20
+ /** @internal */
21
+ export const GetBucketLeadersResponse$inboundSchema: z.ZodType<
22
+ GetBucketLeadersResponse,
23
+ z.ZodTypeDef,
24
+ unknown
25
+ > = z.object({
26
+ HttpMeta: components.HTTPMetadata$inboundSchema,
27
+ BucketLeaders: z.nullable(z.array(components.BucketLeader$inboundSchema))
28
+ .optional(),
29
+ }).transform((v) => {
30
+ return remap$(v, {
31
+ "HttpMeta": "httpMeta",
32
+ "BucketLeaders": "bucketLeaders",
33
+ });
34
+ });
35
+
36
+ export function getBucketLeadersResponseFromJSON(
37
+ jsonString: string,
38
+ ): SafeParseResult<GetBucketLeadersResponse, SDKValidationError> {
39
+ return safeParse(
40
+ jsonString,
41
+ (x) => GetBucketLeadersResponse$inboundSchema.parse(JSON.parse(x)),
42
+ `Failed to parse 'GetBucketLeadersResponse' from JSON`,
43
+ );
44
+ }
@@ -9,7 +9,7 @@ import { Result as SafeParseResult } from "../../types/fp.js";
9
9
  import * as components from "../components/index.js";
10
10
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
11
 
12
- export type LeaderboardGetChangesResponse = {
12
+ export type GetChangesResponse = {
13
13
  httpMeta: components.HTTPMetadata;
14
14
  /**
15
15
  * OK
@@ -20,8 +20,8 @@ export type LeaderboardGetChangesResponse = {
20
20
  };
21
21
 
22
22
  /** @internal */
23
- export const LeaderboardGetChangesResponse$inboundSchema: z.ZodType<
24
- LeaderboardGetChangesResponse,
23
+ export const GetChangesResponse$inboundSchema: z.ZodType<
24
+ GetChangesResponse,
25
25
  z.ZodTypeDef,
26
26
  unknown
27
27
  > = z.object({
@@ -35,12 +35,12 @@ export const LeaderboardGetChangesResponse$inboundSchema: z.ZodType<
35
35
  });
36
36
  });
37
37
 
38
- export function leaderboardGetChangesResponseFromJSON(
38
+ export function getChangesResponseFromJSON(
39
39
  jsonString: string,
40
- ): SafeParseResult<LeaderboardGetChangesResponse, SDKValidationError> {
40
+ ): SafeParseResult<GetChangesResponse, SDKValidationError> {
41
41
  return safeParse(
42
42
  jsonString,
43
- (x) => LeaderboardGetChangesResponse$inboundSchema.parse(JSON.parse(x)),
44
- `Failed to parse 'LeaderboardGetChangesResponse' from JSON`,
43
+ (x) => GetChangesResponse$inboundSchema.parse(JSON.parse(x)),
44
+ `Failed to parse 'GetChangesResponse' from JSON`,
45
45
  );
46
46
  }
@@ -0,0 +1,43 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import * as components from "../components/index.js";
10
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
+
12
+ export type GetViewStatsResponse = {
13
+ httpMeta: components.HTTPMetadata;
14
+ /**
15
+ * OK
16
+ */
17
+ accountViewStats?: components.AccountViewStats | undefined;
18
+ };
19
+
20
+ /** @internal */
21
+ export const GetViewStatsResponse$inboundSchema: z.ZodType<
22
+ GetViewStatsResponse,
23
+ z.ZodTypeDef,
24
+ unknown
25
+ > = z.object({
26
+ HttpMeta: components.HTTPMetadata$inboundSchema,
27
+ AccountViewStats: components.AccountViewStats$inboundSchema.optional(),
28
+ }).transform((v) => {
29
+ return remap$(v, {
30
+ "HttpMeta": "httpMeta",
31
+ "AccountViewStats": "accountViewStats",
32
+ });
33
+ });
34
+
35
+ export function getViewStatsResponseFromJSON(
36
+ jsonString: string,
37
+ ): SafeParseResult<GetViewStatsResponse, SDKValidationError> {
38
+ return safeParse(
39
+ jsonString,
40
+ (x) => GetViewStatsResponse$inboundSchema.parse(JSON.parse(x)),
41
+ `Failed to parse 'GetViewStatsResponse' from JSON`,
42
+ );
43
+ }
@@ -17,6 +17,7 @@ export * from "./accountgetinfo.js";
17
17
  export * from "./accountgetmeta.js";
18
18
  export * from "./accountgetsession.js";
19
19
  export * from "./accountgetsettings.js";
20
+ export * from "./accountgettrending.js";
20
21
  export * from "./accountlistapps.js";
21
22
  export * from "./accountlistbadgebookmarks.js";
22
23
  export * from "./accountlistbadges.js";
@@ -43,7 +44,6 @@ export * from "./accountupdatevanity.js";
43
44
  export * from "./accountuploadimages.js";
44
45
  export * from "./accountverifyconnection.js";
45
46
  export * from "./accountverifyemail.js";
46
- export * from "./activitylistaccountfeed.js";
47
47
  export * from "./admingetaccount.js";
48
48
  export * from "./adminremovevanity.js";
49
49
  export * from "./adminupdateresources.js";
@@ -65,18 +65,23 @@ export * from "./cmsreorder.js";
65
65
  export * from "./cmsupdatedraft.js";
66
66
  export * from "./cmsuploadimage.js";
67
67
  export * from "./cmsversions.js";
68
+ export * from "./getbucketleaders.js";
69
+ export * from "./getchanges.js";
70
+ export * from "./getviewstats.js";
68
71
  export * from "./leaderboardgetaccountleaderboard.js";
69
72
  export * from "./leaderboardgetaccountsmeta.js";
70
- export * from "./leaderboardgetchanges.js";
71
73
  export * from "./leaderboardgetgroupleaderboard.js";
72
74
  export * from "./leaderboardgetgroupsmeta.js";
73
75
  export * from "./leaderboardgetlowestranks.js";
74
76
  export * from "./leaderboardlistbadges.js";
75
77
  export * from "./leaderboardpreviewaccountrank.js";
76
78
  export * from "./list.js";
79
+ export * from "./listaccountfeed.js";
77
80
  export * from "./listglobalfeed.js";
78
81
  export * from "./locationgetlocations.js";
82
+ export * from "./searchgettrending.js";
79
83
  export * from "./staffliststaff.js";
80
84
  export * from "./statsgetstats.js";
81
85
  export * from "./streamglobalfeed.js";
86
+ export * from "./trackevent.js";
82
87
  export * from "./vanityverify.js";
@@ -9,7 +9,7 @@ import { Result as SafeParseResult } from "../../types/fp.js";
9
9
  import * as components from "../components/index.js";
10
10
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
11
 
12
- export type ActivityListAccountFeedResponse = {
12
+ export type ListAccountFeedResponse = {
13
13
  httpMeta: components.HTTPMetadata;
14
14
  /**
15
15
  * OK
@@ -20,8 +20,8 @@ export type ActivityListAccountFeedResponse = {
20
20
  };
21
21
 
22
22
  /** @internal */
23
- export const ActivityListAccountFeedResponse$inboundSchema: z.ZodType<
24
- ActivityListAccountFeedResponse,
23
+ export const ListAccountFeedResponse$inboundSchema: z.ZodType<
24
+ ListAccountFeedResponse,
25
25
  z.ZodTypeDef,
26
26
  unknown
27
27
  > = z.object({
@@ -36,12 +36,12 @@ export const ActivityListAccountFeedResponse$inboundSchema: z.ZodType<
36
36
  });
37
37
  });
38
38
 
39
- export function activityListAccountFeedResponseFromJSON(
39
+ export function listAccountFeedResponseFromJSON(
40
40
  jsonString: string,
41
- ): SafeParseResult<ActivityListAccountFeedResponse, SDKValidationError> {
41
+ ): SafeParseResult<ListAccountFeedResponse, SDKValidationError> {
42
42
  return safeParse(
43
43
  jsonString,
44
- (x) => ActivityListAccountFeedResponse$inboundSchema.parse(JSON.parse(x)),
45
- `Failed to parse 'ActivityListAccountFeedResponse' from JSON`,
44
+ (x) => ListAccountFeedResponse$inboundSchema.parse(JSON.parse(x)),
45
+ `Failed to parse 'ListAccountFeedResponse' from JSON`,
46
46
  );
47
47
  }
@@ -0,0 +1,46 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import * as components from "../components/index.js";
10
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
+
12
+ export type SearchGetTrendingResponse = {
13
+ httpMeta: components.HTTPMetadata;
14
+ /**
15
+ * OK
16
+ */
17
+ searchGetTrendingResponseBody?:
18
+ | components.SearchGetTrendingResponseBody
19
+ | undefined;
20
+ };
21
+
22
+ /** @internal */
23
+ export const SearchGetTrendingResponse$inboundSchema: z.ZodType<
24
+ SearchGetTrendingResponse,
25
+ z.ZodTypeDef,
26
+ unknown
27
+ > = z.object({
28
+ HttpMeta: components.HTTPMetadata$inboundSchema,
29
+ SearchGetTrendingResponseBody: components
30
+ .SearchGetTrendingResponseBody$inboundSchema.optional(),
31
+ }).transform((v) => {
32
+ return remap$(v, {
33
+ "HttpMeta": "httpMeta",
34
+ "SearchGetTrendingResponseBody": "searchGetTrendingResponseBody",
35
+ });
36
+ });
37
+
38
+ export function searchGetTrendingResponseFromJSON(
39
+ jsonString: string,
40
+ ): SafeParseResult<SearchGetTrendingResponse, SDKValidationError> {
41
+ return safeParse(
42
+ jsonString,
43
+ (x) => SearchGetTrendingResponse$inboundSchema.parse(JSON.parse(x)),
44
+ `Failed to parse 'SearchGetTrendingResponse' from JSON`,
45
+ );
46
+ }
@@ -0,0 +1,90 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import * as components from "../components/index.js";
10
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
+
12
+ export type TrackEventRequest = {
13
+ xForwardedFor?: string | undefined;
14
+ userAgent?: string | undefined;
15
+ xVisitorId?: string | undefined;
16
+ analyticsTrackEventRequestBody: components.AnalyticsTrackEventRequestBody;
17
+ };
18
+
19
+ export type TrackEventResponse = {
20
+ httpMeta: components.HTTPMetadata;
21
+ /**
22
+ * OK
23
+ */
24
+ analyticsTrackEventResponseBody?:
25
+ | components.AnalyticsTrackEventResponseBody
26
+ | undefined;
27
+ };
28
+
29
+ /** @internal */
30
+ export type TrackEventRequest$Outbound = {
31
+ "X-Forwarded-For"?: string | undefined;
32
+ "User-Agent"?: string | undefined;
33
+ "X-Visitor-Id"?: string | undefined;
34
+ AnalyticsTrackEventRequestBody:
35
+ components.AnalyticsTrackEventRequestBody$Outbound;
36
+ };
37
+
38
+ /** @internal */
39
+ export const TrackEventRequest$outboundSchema: z.ZodType<
40
+ TrackEventRequest$Outbound,
41
+ z.ZodTypeDef,
42
+ TrackEventRequest
43
+ > = z.object({
44
+ xForwardedFor: z.string().optional(),
45
+ userAgent: z.string().optional(),
46
+ xVisitorId: z.string().optional(),
47
+ analyticsTrackEventRequestBody:
48
+ components.AnalyticsTrackEventRequestBody$outboundSchema,
49
+ }).transform((v) => {
50
+ return remap$(v, {
51
+ xForwardedFor: "X-Forwarded-For",
52
+ userAgent: "User-Agent",
53
+ xVisitorId: "X-Visitor-Id",
54
+ analyticsTrackEventRequestBody: "AnalyticsTrackEventRequestBody",
55
+ });
56
+ });
57
+
58
+ export function trackEventRequestToJSON(
59
+ trackEventRequest: TrackEventRequest,
60
+ ): string {
61
+ return JSON.stringify(
62
+ TrackEventRequest$outboundSchema.parse(trackEventRequest),
63
+ );
64
+ }
65
+
66
+ /** @internal */
67
+ export const TrackEventResponse$inboundSchema: z.ZodType<
68
+ TrackEventResponse,
69
+ z.ZodTypeDef,
70
+ unknown
71
+ > = z.object({
72
+ HttpMeta: components.HTTPMetadata$inboundSchema,
73
+ AnalyticsTrackEventResponseBody: components
74
+ .AnalyticsTrackEventResponseBody$inboundSchema.optional(),
75
+ }).transform((v) => {
76
+ return remap$(v, {
77
+ "HttpMeta": "httpMeta",
78
+ "AnalyticsTrackEventResponseBody": "analyticsTrackEventResponseBody",
79
+ });
80
+ });
81
+
82
+ export function trackEventResponseFromJSON(
83
+ jsonString: string,
84
+ ): SafeParseResult<TrackEventResponse, SDKValidationError> {
85
+ return safeParse(
86
+ jsonString,
87
+ (x) => TrackEventResponse$inboundSchema.parse(JSON.parse(x)),
88
+ `Failed to parse 'TrackEventResponse' from JSON`,
89
+ );
90
+ }
@@ -4,6 +4,7 @@
4
4
 
5
5
  import { accountAccountFindFriendPath } from "../funcs/accountAccountFindFriendPath.js";
6
6
  import { accountAccountGetBadgeHeatmap } from "../funcs/accountAccountGetBadgeHeatmap.js";
7
+ import { accountAccountGetTrending } from "../funcs/accountAccountGetTrending.js";
7
8
  import { accountAccountListOwnedGroups } from "../funcs/accountAccountListOwnedGroups.js";
8
9
  import { accountBookmarkBadge } from "../funcs/accountBookmarkBadge.js";
9
10
  import { accountCreateConnection } from "../funcs/accountCreateConnection.js";
@@ -18,6 +19,7 @@ import { accountGetInfo } from "../funcs/accountGetInfo.js";
18
19
  import { accountGetMeta } from "../funcs/accountGetMeta.js";
19
20
  import { accountGetSession } from "../funcs/accountGetSession.js";
20
21
  import { accountGetSettings } from "../funcs/accountGetSettings.js";
22
+ import { accountGetViewStats } from "../funcs/accountGetViewStats.js";
21
23
  import { accountListApps } from "../funcs/accountListApps.js";
22
24
  import { accountListBadgeBookmarks } from "../funcs/accountListBadgeBookmarks.js";
23
25
  import { accountListBadges } from "../funcs/accountListBadges.js";
@@ -207,7 +209,7 @@ export class Account extends ClientSDK {
207
209
  * Get account profile information
208
210
  */
209
211
  async getInfo(
210
- request: components.AccountSearch,
212
+ request: operations.AccountGetInfoRequest,
211
213
  options?: RequestOptions,
212
214
  ): Promise<operations.AccountGetInfoResponse> {
213
215
  return unwrapAsync(accountGetInfo(
@@ -255,6 +257,34 @@ export class Account extends ClientSDK {
255
257
  ));
256
258
  }
257
259
 
260
+ /**
261
+ * Top accounts by unique viewers in a window
262
+ */
263
+ async accountGetTrending(
264
+ request: components.AccountGetTrendingRequestBody,
265
+ options?: RequestOptions,
266
+ ): Promise<operations.AccountGetTrendingResponse> {
267
+ return unwrapAsync(accountAccountGetTrending(
268
+ this,
269
+ request,
270
+ options,
271
+ ));
272
+ }
273
+
274
+ /**
275
+ * Get profile view counts (24h/7d/30d × unique/total) for an account
276
+ */
277
+ async getViewStats(
278
+ request: components.AccountSearch,
279
+ options?: RequestOptions,
280
+ ): Promise<operations.GetViewStatsResponse> {
281
+ return unwrapAsync(accountGetViewStats(
282
+ this,
283
+ request,
284
+ options,
285
+ ));
286
+ }
287
+
258
288
  /**
259
289
  * List account owned apps
260
290
  */
@@ -2,7 +2,7 @@
2
2
  * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
3
  */
4
4
 
5
- import { activityActivityListAccountFeed } from "../funcs/activityActivityListAccountFeed.js";
5
+ import { activityListAccountFeed } from "../funcs/activityListAccountFeed.js";
6
6
  import { activityListGlobalFeed } from "../funcs/activityListGlobalFeed.js";
7
7
  import {
8
8
  activityStreamGlobalFeed,
@@ -19,11 +19,11 @@ export class Activity extends ClientSDK {
19
19
  /**
20
20
  * List the activity feed for a single account (profile timeline)
21
21
  */
22
- async activityListAccountFeed(
22
+ async listAccountFeed(
23
23
  request: components.V1ActivityListAccountFeedRequestBody,
24
24
  options?: RequestOptions,
25
- ): Promise<operations.ActivityListAccountFeedResponse> {
26
- return unwrapAsync(activityActivityListAccountFeed(
25
+ ): Promise<operations.ListAccountFeedResponse> {
26
+ return unwrapAsync(activityListAccountFeed(
27
27
  this,
28
28
  request,
29
29
  options,
@@ -0,0 +1,24 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import { analyticsTrackEvent } from "../funcs/analyticsTrackEvent.js";
6
+ import { ClientSDK, RequestOptions } from "../lib/sdks.js";
7
+ import * as operations from "../models/operations/index.js";
8
+ import { unwrapAsync } from "../types/fp.js";
9
+
10
+ export class Analytics extends ClientSDK {
11
+ /**
12
+ * Track a frontend-only analytics event (profile view, search). Frontend API key + logged-in users only.
13
+ */
14
+ async trackEvent(
15
+ request: operations.TrackEventRequest,
16
+ options?: RequestOptions,
17
+ ): Promise<operations.TrackEventResponse> {
18
+ return unwrapAsync(analyticsTrackEvent(
19
+ this,
20
+ request,
21
+ options,
22
+ ));
23
+ }
24
+ }