rozod 6.0.1 → 6.1.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 +126 -4
- package/lib/cache.js +11 -1
- package/lib/endpoints/accountinformationv1.js +3 -67
- package/lib/endpoints/assetdeliveryv1.js +272 -6
- package/lib/endpoints/assetdeliveryv2.js +31 -5
- package/lib/endpoints/authv1.js +28 -21
- package/lib/endpoints/authv2.js +2 -1
- package/lib/endpoints/avatarv1.js +74 -451
- package/lib/endpoints/avatarv2.js +39 -2
- package/lib/endpoints/avatarv3.js +39 -2
- package/lib/endpoints/badgesv1.js +1 -40
- package/lib/endpoints/catalogv1.js +20 -4
- package/lib/endpoints/catalogv2.js +17 -1
- package/lib/endpoints/clientsettingsv1.js +6 -5
- package/lib/endpoints/clientsettingsv2.js +54 -1
- package/lib/endpoints/developv1.js +1 -1
- package/lib/endpoints/developv2.js +1 -0
- package/lib/endpoints/friendsv1.js +9 -161
- package/lib/endpoints/gameinternationalizationv1.js +115 -72
- package/lib/endpoints/gameinternationalizationv2.js +4 -0
- package/lib/endpoints/gamesv1.js +8 -91
- package/lib/endpoints/gamesv2.js +1 -0
- package/lib/endpoints/groupsv1.js +610 -47
- package/lib/endpoints/groupsv2.js +163 -1
- package/lib/endpoints/inventoryv1.js +8 -4
- package/lib/endpoints/inventoryv2.js +5 -0
- package/lib/endpoints/localev1.js +43 -2
- package/lib/endpoints/localizationtablesv1.js +15 -0
- package/lib/endpoints/matchmakingv1.js +458 -0
- package/lib/endpoints/notificationsv2.js +4 -8
- package/lib/endpoints/presencev1.js +34 -17
- package/lib/endpoints/thumbnailsv1.js +2 -4
- package/lib/endpoints/tradesv2.js +72 -1
- package/lib/endpoints/twostepverificationv1.js +5 -0
- package/lib/endpoints/usersv1.js +4 -2
- package/lib/index.d.ts +84 -4
- package/lib/index.js +190 -21
- package/lib/opencloud/v1/asset-permissions.d.ts +25 -0
- package/lib/opencloud/v1/asset-permissions.js +75 -0
- package/lib/opencloud/v1/assets.d.ts +11 -0
- package/lib/opencloud/v1/assets.js +3 -0
- package/lib/opencloud/v1/developer-products.d.ts +108 -0
- package/lib/opencloud/v1/developer-products.js +249 -0
- package/lib/opencloud/v1/game-passes.d.ts +98 -0
- package/lib/opencloud/v1/game-passes.js +236 -0
- package/lib/opencloud/v1/open-eval.d.ts +57 -0
- package/lib/opencloud/v1/open-eval.js +91 -0
- package/lib/opencloud/v1/secrets-store.d.ts +148 -0
- package/lib/opencloud/v1/secrets-store.js +247 -0
- package/lib/opencloud/v1/toolbox.d.ts +167 -0
- package/lib/opencloud/v1/toolbox.js +236 -0
- package/lib/opencloud/v2/cloud.d.ts +221 -132
- package/lib/opencloud/v2/cloud.js +167 -73
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -200,12 +200,120 @@ const userInfo = await fetchApi(getUsersUserdetails, { userIds: [123456] });
|
|
|
200
200
|
|
|
201
201
|
### Server Environments (Node.js/Bun/Deno)
|
|
202
202
|
|
|
203
|
-
For server environments,
|
|
203
|
+
For server environments, use `configureServer()` to set up authentication once:
|
|
204
204
|
|
|
205
205
|
```ts
|
|
206
|
-
import { fetchApi } from 'rozod';
|
|
206
|
+
import { configureServer, fetchApi } from 'rozod';
|
|
207
207
|
import { getUsersUserdetails } from 'rozod/lib/endpoints/usersv1';
|
|
208
208
|
|
|
209
|
+
// Configure once at startup
|
|
210
|
+
configureServer({ cookies: 'your_roblosecurity_cookie_here' });
|
|
211
|
+
|
|
212
|
+
// All subsequent requests automatically include the cookie
|
|
213
|
+
const userInfo = await fetchApi(getUsersUserdetails, { userIds: [123456] });
|
|
214
|
+
```
|
|
215
|
+
|
|
216
|
+
#### Multiple Accounts (Cookie Pool)
|
|
217
|
+
|
|
218
|
+
Use multiple Roblox accounts for load distribution or fallback:
|
|
219
|
+
|
|
220
|
+
```ts
|
|
221
|
+
import { configureServer } from 'rozod';
|
|
222
|
+
|
|
223
|
+
// Multiple accounts with round-robin rotation (default)
|
|
224
|
+
configureServer({
|
|
225
|
+
cookies: [
|
|
226
|
+
'account1_roblosecurity_cookie',
|
|
227
|
+
'account2_roblosecurity_cookie',
|
|
228
|
+
'account3_roblosecurity_cookie',
|
|
229
|
+
],
|
|
230
|
+
});
|
|
231
|
+
|
|
232
|
+
// Requests automatically cycle through accounts: 1 → 2 → 3 → 1 → 2 → ...
|
|
233
|
+
```
|
|
234
|
+
|
|
235
|
+
#### Rotation Modes
|
|
236
|
+
|
|
237
|
+
Control how cookies and user agents are selected:
|
|
238
|
+
|
|
239
|
+
```ts
|
|
240
|
+
import { configureServer } from 'rozod';
|
|
241
|
+
|
|
242
|
+
configureServer({
|
|
243
|
+
cookies: ['cookie1', 'cookie2', 'cookie3'],
|
|
244
|
+
cookieRotation: 'round-robin', // Cycle sequentially (default for multiple)
|
|
245
|
+
// cookieRotation: 'random', // Pick randomly per request
|
|
246
|
+
// cookieRotation: 'none', // Always use first cookie
|
|
247
|
+
|
|
248
|
+
userAgents: ['CustomBot/1.0', 'CustomBot/2.0'], // Optional custom UAs
|
|
249
|
+
userAgentRotation: 'none', // Consistent per session (default)
|
|
250
|
+
// userAgentRotation: 'random',
|
|
251
|
+
// userAgentRotation: 'round-robin',
|
|
252
|
+
});
|
|
253
|
+
```
|
|
254
|
+
|
|
255
|
+
#### User Agent Pool
|
|
256
|
+
|
|
257
|
+
RoZod includes built-in browser user agents applied automatically in server environments. Customize or disable:
|
|
258
|
+
|
|
259
|
+
```ts
|
|
260
|
+
// Use custom user agents
|
|
261
|
+
configureServer({
|
|
262
|
+
cookies: '...',
|
|
263
|
+
userAgents: ['MyBot/1.0', 'MyService/2.0'],
|
|
264
|
+
userAgentRotation: 'round-robin',
|
|
265
|
+
});
|
|
266
|
+
|
|
267
|
+
// Disable user agent injection
|
|
268
|
+
configureServer({ cookies: '...', userAgents: [] });
|
|
269
|
+
```
|
|
270
|
+
|
|
271
|
+
#### OpenCloud API Key
|
|
272
|
+
|
|
273
|
+
For OpenCloud endpoints (`apis.roblox.com`), set your API key once:
|
|
274
|
+
|
|
275
|
+
```ts
|
|
276
|
+
import { configureServer } from 'rozod';
|
|
277
|
+
import { v2 } from 'rozod/lib/opencloud';
|
|
278
|
+
|
|
279
|
+
// Configure OpenCloud API key
|
|
280
|
+
configureServer({ cloudKey: 'your_opencloud_api_key_here' });
|
|
281
|
+
|
|
282
|
+
// All OpenCloud requests automatically include x-api-key header
|
|
283
|
+
const universeInfo = await fetchApi(v2.getCloudV2UniversesUniverseId, {
|
|
284
|
+
universe_id: '123456789',
|
|
285
|
+
});
|
|
286
|
+
```
|
|
287
|
+
|
|
288
|
+
You can configure both classic API cookies and OpenCloud keys together:
|
|
289
|
+
|
|
290
|
+
```ts
|
|
291
|
+
configureServer({
|
|
292
|
+
cookies: ['account1', 'account2'], // For classic *.roblox.com APIs
|
|
293
|
+
cloudKey: 'your_opencloud_key', // For apis.roblox.com
|
|
294
|
+
});
|
|
295
|
+
```
|
|
296
|
+
|
|
297
|
+
> **Note:** The API key is only applied to OpenCloud endpoints (URLs containing `/cloud/`). Cookies are applied to all other Roblox APIs, including undocumented cookie-based APIs on `apis.roblox.com`.
|
|
298
|
+
|
|
299
|
+
#### Configuration Management
|
|
300
|
+
|
|
301
|
+
```ts
|
|
302
|
+
import { configureServer, clearServerConfig, getServerConfig } from 'rozod';
|
|
303
|
+
|
|
304
|
+
// Check current configuration
|
|
305
|
+
const config = getServerConfig();
|
|
306
|
+
console.log(config.cookies, config.cloudKey);
|
|
307
|
+
|
|
308
|
+
// Clear all server configuration
|
|
309
|
+
clearServerConfig();
|
|
310
|
+
```
|
|
311
|
+
|
|
312
|
+
#### Manual Headers (Legacy)
|
|
313
|
+
|
|
314
|
+
You can still pass headers manually per-request if needed:
|
|
315
|
+
|
|
316
|
+
```ts
|
|
209
317
|
const userInfo = await fetchApi(
|
|
210
318
|
getUsersUserdetails,
|
|
211
319
|
{ userIds: [123456] },
|
|
@@ -217,6 +325,8 @@ const userInfo = await fetchApi(
|
|
|
217
325
|
);
|
|
218
326
|
```
|
|
219
327
|
|
|
328
|
+
> **Note:** Manual headers take precedence over `configureServer()` defaults.
|
|
329
|
+
|
|
220
330
|
### Security Features
|
|
221
331
|
|
|
222
332
|
RoZod automatically handles advanced Roblox security requirements:
|
|
@@ -266,12 +376,24 @@ changeHBAKeys(keyPair);
|
|
|
266
376
|
|
|
267
377
|
### OpenCloud Authentication
|
|
268
378
|
|
|
269
|
-
OpenCloud APIs require API keys
|
|
379
|
+
OpenCloud APIs require API keys. Use `configureServer()` for automatic injection:
|
|
270
380
|
|
|
271
381
|
```ts
|
|
272
|
-
import { fetchApi } from 'rozod';
|
|
382
|
+
import { configureServer, fetchApi } from 'rozod';
|
|
273
383
|
import { v2 } from 'rozod/lib/opencloud';
|
|
274
384
|
|
|
385
|
+
// Configure once at startup
|
|
386
|
+
configureServer({ cloudKey: 'your_opencloud_api_key_here' });
|
|
387
|
+
|
|
388
|
+
// All OpenCloud requests automatically include x-api-key
|
|
389
|
+
const universeInfo = await fetchApi(v2.getCloudV2UniversesUniverseId, {
|
|
390
|
+
universe_id: '123456789',
|
|
391
|
+
});
|
|
392
|
+
```
|
|
393
|
+
|
|
394
|
+
Or pass headers manually per-request:
|
|
395
|
+
|
|
396
|
+
```ts
|
|
275
397
|
const universeInfo = await fetchApi(
|
|
276
398
|
v2.getCloudV2UniversesUniverseId,
|
|
277
399
|
{ universe_id: '123456789' },
|
package/lib/cache.js
CHANGED
|
@@ -68,7 +68,17 @@ class ChromeStore {
|
|
|
68
68
|
return new Promise((resolve) => {
|
|
69
69
|
// @ts-ignore
|
|
70
70
|
chrome?.storage?.local?.get?.(null, (result) => {
|
|
71
|
-
|
|
71
|
+
if (!result) {
|
|
72
|
+
resolve({});
|
|
73
|
+
return;
|
|
74
|
+
}
|
|
75
|
+
const filtered = {};
|
|
76
|
+
for (const key of Object.keys(result)) {
|
|
77
|
+
if (key.startsWith('rozod_cache:')) {
|
|
78
|
+
filtered[key] = result[key];
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
resolve(filtered);
|
|
72
82
|
});
|
|
73
83
|
});
|
|
74
84
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.getUsersUseridRobloxBadges = exports.getUsersUseridPromotionChannels = exports.deleteStarCodeAffiliates = exports.postStarCodeAffiliates = exports.getStarCodeAffiliates = exports.postPromotionChannels = exports.getPromotionChannels = exports.postPhoneVerify = exports.postPhoneResend = exports.postPhoneDelete = exports.postPhone = exports.getPhone = exports.getMetadata = exports.postGender = exports.getGender = exports.postEmailVerify = exports.postDescription = exports.getDescription = exports.getBirthdate = void 0;
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
5
|
const __1 = require("..");
|
|
6
6
|
const Roblox_AccountInformation_Api_Models_BirthdateResponse = zod_1.z.object({
|
|
@@ -8,13 +8,6 @@ const Roblox_AccountInformation_Api_Models_BirthdateResponse = zod_1.z.object({
|
|
|
8
8
|
birthDay: zod_1.z.number().int(),
|
|
9
9
|
birthYear: zod_1.z.number().int(),
|
|
10
10
|
});
|
|
11
|
-
const Roblox_AccountInformation_Api_Models_BirthdateRequest = zod_1.z.object({
|
|
12
|
-
birthMonth: zod_1.z.number().int(),
|
|
13
|
-
birthDay: zod_1.z.number().int(),
|
|
14
|
-
birthYear: zod_1.z.number().int(),
|
|
15
|
-
password: zod_1.z.string(),
|
|
16
|
-
});
|
|
17
|
-
const Roblox_Web_WebAPI_ApiEmptyResponseModel = zod_1.z.object({});
|
|
18
11
|
const Roblox_AccountInformation_Api_Models_DescriptionResponse = zod_1.z.object({
|
|
19
12
|
description: zod_1.z.string(),
|
|
20
13
|
});
|
|
@@ -27,6 +20,7 @@ const Roblox_AccountInformation_Api_Models_GenderResponse = zod_1.z.object({
|
|
|
27
20
|
const Roblox_AccountInformation_Api_Models_GenderRequest = zod_1.z.object({
|
|
28
21
|
gender: zod_1.z.string(),
|
|
29
22
|
});
|
|
23
|
+
const Roblox_Web_WebAPI_ApiEmptyResponseModel = zod_1.z.object({});
|
|
30
24
|
const Roblox_AccountInformation_Api_Models_MetadataResponse = zod_1.z.object({
|
|
31
25
|
isAllowedNotificationsEndpointDisabled: zod_1.z.boolean(),
|
|
32
26
|
isAccountSettingsPolicyEnabled: zod_1.z.boolean(),
|
|
@@ -34,9 +28,9 @@ const Roblox_AccountInformation_Api_Models_MetadataResponse = zod_1.z.object({
|
|
|
34
28
|
MaxUserDescriptionLength: zod_1.z.number().int(),
|
|
35
29
|
isUserDescriptionEnabled: zod_1.z.boolean(),
|
|
36
30
|
isUserBlockEndpointsUpdated: zod_1.z.boolean(),
|
|
37
|
-
isPasswordRequiredForAgingDown: zod_1.z.boolean(),
|
|
38
31
|
shouldUsePersonaForIdVerification: zod_1.z.boolean(),
|
|
39
32
|
shouldDisplaySessionManagement: zod_1.z.boolean(),
|
|
33
|
+
isPasswordRequiredForAgingDown: zod_1.z.boolean(),
|
|
40
34
|
});
|
|
41
35
|
const Roblox_AccountInformation_Api_Models_PhoneResponse = zod_1.z.object({
|
|
42
36
|
countryCode: zod_1.z.string(),
|
|
@@ -94,7 +88,6 @@ const Roblox_AccountInformation_Api_RobloxBadgeResponse = zod_1.z.object({
|
|
|
94
88
|
description: zod_1.z.string(),
|
|
95
89
|
imageUrl: zod_1.z.string(),
|
|
96
90
|
});
|
|
97
|
-
const Roblox_AccountInformation_Api_Models_ConsecutiveLoginDaysResponse = zod_1.z.object({ count: zod_1.z.number().int() });
|
|
98
91
|
const Roblox_AccountInformation_Api_Models_VerifyEmailRequest = zod_1.z.object({
|
|
99
92
|
ticket: zod_1.z.string(),
|
|
100
93
|
});
|
|
@@ -126,45 +119,6 @@ exports.getBirthdate = (0, __1.endpoint)({
|
|
|
126
119
|
},
|
|
127
120
|
],
|
|
128
121
|
});
|
|
129
|
-
/**
|
|
130
|
-
* @api POST https://accountinformation.roblox.com/v1/birthdate
|
|
131
|
-
* @summary Update the user's birthdate
|
|
132
|
-
* @param body The Roblox.AccountInformation.Api.Models.BirthdateRequest
|
|
133
|
-
*/
|
|
134
|
-
exports.postBirthdate = (0, __1.endpoint)({
|
|
135
|
-
method: 'POST',
|
|
136
|
-
path: '/v1/birthdate',
|
|
137
|
-
baseUrl: 'https://accountinformation.roblox.com',
|
|
138
|
-
requestFormat: 'json',
|
|
139
|
-
serializationMethod: {
|
|
140
|
-
body: {},
|
|
141
|
-
},
|
|
142
|
-
parameters: {},
|
|
143
|
-
body: Roblox_AccountInformation_Api_Models_BirthdateRequest,
|
|
144
|
-
response: zod_1.z.object({}),
|
|
145
|
-
errors: [
|
|
146
|
-
{
|
|
147
|
-
status: 400,
|
|
148
|
-
description: `1: User not found.
|
|
149
|
-
4: The birthdate provided is invalid.
|
|
150
|
-
8: Password is incorrect.`,
|
|
151
|
-
},
|
|
152
|
-
{
|
|
153
|
-
status: 401,
|
|
154
|
-
description: `0: Authorization has been denied for this request.`,
|
|
155
|
-
},
|
|
156
|
-
{
|
|
157
|
-
status: 403,
|
|
158
|
-
description: `0: Token Validation Failed
|
|
159
|
-
5: Invalid birthdate change.`,
|
|
160
|
-
},
|
|
161
|
-
{
|
|
162
|
-
status: 500,
|
|
163
|
-
description: `0: An unknown error occured.
|
|
164
|
-
5: Invalid birthdate change.`,
|
|
165
|
-
},
|
|
166
|
-
],
|
|
167
|
-
});
|
|
168
122
|
/**
|
|
169
123
|
* @api GET https://accountinformation.roblox.com/v1/description
|
|
170
124
|
* @summary Get the user's description
|
|
@@ -729,21 +683,3 @@ exports.getUsersUseridRobloxBadges = (0, __1.endpoint)({
|
|
|
729
683
|
response: zod_1.z.array(Roblox_AccountInformation_Api_RobloxBadgeResponse),
|
|
730
684
|
errors: [],
|
|
731
685
|
});
|
|
732
|
-
/**
|
|
733
|
-
* @api GET https://accountinformation.roblox.com/v1/xbox-live/consecutive-login-days
|
|
734
|
-
* @summary Returns number of consecutive login days for xbox users
|
|
735
|
-
*/
|
|
736
|
-
exports.getXboxLiveConsecutiveLoginDays = (0, __1.endpoint)({
|
|
737
|
-
method: 'GET',
|
|
738
|
-
path: '/v1/xbox-live/consecutive-login-days',
|
|
739
|
-
baseUrl: 'https://accountinformation.roblox.com',
|
|
740
|
-
requestFormat: 'json',
|
|
741
|
-
response: zod_1.z.object({ count: zod_1.z.number().int() }),
|
|
742
|
-
errors: [
|
|
743
|
-
{
|
|
744
|
-
status: 401,
|
|
745
|
-
description: `0: Authorization has been denied for this request.
|
|
746
|
-
7: The account is not connected to an Xbox Live account`,
|
|
747
|
-
},
|
|
748
|
-
],
|
|
749
|
-
});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getMarassethashMarassethashMarchecksumMarchecksum = exports.postAssetsBatch = exports.getAssetidAssetidVersionVersionnumber = exports.getAssetidAssetid = exports.getAsset = exports.getAliasAlias = void 0;
|
|
3
|
+
exports.getOpencloudAssetidAssetidVersionVersionnumber = exports.getOpencloudAssetidAssetid = exports.getMarassethashMarassethashMarchecksumMarchecksum = exports.postAssetsBatch = exports.getAssetidAssetidVersionVersionnumber = exports.getAssetidAssetid = exports.getAsset = exports.getAliasAlias = void 0;
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
5
|
const __1 = require("..");
|
|
6
6
|
const Roblox_Web_Assets_IAssetItemError = zod_1.z.object({
|
|
@@ -24,6 +24,11 @@ const Roblox_Web_Assets_IAssetItemError = zod_1.z.object({
|
|
|
24
24
|
zod_1.z.literal(14),
|
|
25
25
|
zod_1.z.literal(15),
|
|
26
26
|
zod_1.z.literal(16),
|
|
27
|
+
zod_1.z.literal(17),
|
|
28
|
+
zod_1.z.literal(18),
|
|
29
|
+
zod_1.z.literal(19),
|
|
30
|
+
zod_1.z.literal(20),
|
|
31
|
+
zod_1.z.literal(21),
|
|
27
32
|
]),
|
|
28
33
|
});
|
|
29
34
|
const Roblox_Web_Assets_AssetContentRepresentationSpecifier = zod_1.z.object({
|
|
@@ -64,6 +69,8 @@ const Roblox_Web_Assets_BatchAssetRequestItem = zod_1.z.object({
|
|
|
64
69
|
modulePlaceId: zod_1.z.number().int(),
|
|
65
70
|
assetFormat: zod_1.z.string(),
|
|
66
71
|
'roblox-assetFormat': zod_1.z.string(),
|
|
72
|
+
assetResolutionMode: zod_1.z.string(),
|
|
73
|
+
accessContext: zod_1.z.string(),
|
|
67
74
|
contentRepresentationPriorityList: zod_1.z.string(),
|
|
68
75
|
doNotFallbackToBaselineRepresentation: zod_1.z.boolean(),
|
|
69
76
|
});
|
|
@@ -83,6 +90,7 @@ const Roblox_Web_Assets_BatchAssetRequestItem = zod_1.z.object({
|
|
|
83
90
|
* @param modulePlaceId
|
|
84
91
|
* @param serverplaceid
|
|
85
92
|
* @param expectedAssetType
|
|
93
|
+
* @param accessContext
|
|
86
94
|
*/
|
|
87
95
|
exports.getAliasAlias = (0, __1.endpoint)({
|
|
88
96
|
method: 'GET',
|
|
@@ -135,6 +143,10 @@ exports.getAliasAlias = (0, __1.endpoint)({
|
|
|
135
143
|
style: 'form',
|
|
136
144
|
explode: true,
|
|
137
145
|
},
|
|
146
|
+
accessContext: {
|
|
147
|
+
style: 'form',
|
|
148
|
+
explode: true,
|
|
149
|
+
},
|
|
138
150
|
},
|
|
139
151
|
parameters: {
|
|
140
152
|
alias: zod_1.z.string().regex(/^[0-9]+\/.+/),
|
|
@@ -150,6 +162,7 @@ exports.getAliasAlias = (0, __1.endpoint)({
|
|
|
150
162
|
modulePlaceId: zod_1.z.number().int().optional(),
|
|
151
163
|
serverplaceid: zod_1.z.number().int().optional(),
|
|
152
164
|
expectedAssetType: zod_1.z.string().optional(),
|
|
165
|
+
accessContext: zod_1.z.string().optional(),
|
|
153
166
|
},
|
|
154
167
|
response: Roblox_Web_Assets_AssetResponseItemV1,
|
|
155
168
|
errors: [],
|
|
@@ -180,6 +193,8 @@ exports.getAliasAlias = (0, __1.endpoint)({
|
|
|
180
193
|
* @param permissionContext
|
|
181
194
|
* @param doNotFallbackToBaselineRepresentation
|
|
182
195
|
* @param contentRepresentationPriorityList
|
|
196
|
+
* @param assetResolutionMode
|
|
197
|
+
* @param accessContext
|
|
183
198
|
*/
|
|
184
199
|
exports.getAsset = (0, __1.endpoint)({
|
|
185
200
|
method: 'GET',
|
|
@@ -277,6 +292,14 @@ exports.getAsset = (0, __1.endpoint)({
|
|
|
277
292
|
style: 'form',
|
|
278
293
|
explode: true,
|
|
279
294
|
},
|
|
295
|
+
assetResolutionMode: {
|
|
296
|
+
style: 'form',
|
|
297
|
+
explode: true,
|
|
298
|
+
},
|
|
299
|
+
accessContext: {
|
|
300
|
+
style: 'form',
|
|
301
|
+
explode: true,
|
|
302
|
+
},
|
|
280
303
|
},
|
|
281
304
|
parameters: {
|
|
282
305
|
'Accept-Encoding': zod_1.z.string(),
|
|
@@ -303,6 +326,8 @@ exports.getAsset = (0, __1.endpoint)({
|
|
|
303
326
|
permissionContext: zod_1.z.string().optional(),
|
|
304
327
|
doNotFallbackToBaselineRepresentation: zod_1.z.boolean().optional(),
|
|
305
328
|
contentRepresentationPriorityList: zod_1.z.string().optional(),
|
|
329
|
+
assetResolutionMode: zod_1.z.string().optional(),
|
|
330
|
+
accessContext: zod_1.z.string().optional(),
|
|
306
331
|
},
|
|
307
332
|
response: zod_1.z.void(),
|
|
308
333
|
errors: [],
|
|
@@ -325,6 +350,7 @@ exports.getAsset = (0, __1.endpoint)({
|
|
|
325
350
|
* @param expectedAssetType
|
|
326
351
|
* @param doNotFallbackToBaselineRepresentation
|
|
327
352
|
* @param contentRepresentationPriorityList
|
|
353
|
+
* @param accessContext
|
|
328
354
|
*/
|
|
329
355
|
exports.getAssetidAssetid = (0, __1.endpoint)({
|
|
330
356
|
method: 'GET',
|
|
@@ -385,6 +411,10 @@ exports.getAssetidAssetid = (0, __1.endpoint)({
|
|
|
385
411
|
style: 'form',
|
|
386
412
|
explode: true,
|
|
387
413
|
},
|
|
414
|
+
accessContext: {
|
|
415
|
+
style: 'form',
|
|
416
|
+
explode: true,
|
|
417
|
+
},
|
|
388
418
|
},
|
|
389
419
|
parameters: {
|
|
390
420
|
assetId: zod_1.z.number().int(),
|
|
@@ -402,6 +432,7 @@ exports.getAssetidAssetid = (0, __1.endpoint)({
|
|
|
402
432
|
expectedAssetType: zod_1.z.string().optional(),
|
|
403
433
|
doNotFallbackToBaselineRepresentation: zod_1.z.boolean().optional(),
|
|
404
434
|
contentRepresentationPriorityList: zod_1.z.string().optional(),
|
|
435
|
+
accessContext: zod_1.z.string().optional(),
|
|
405
436
|
},
|
|
406
437
|
response: Roblox_Web_Assets_AssetResponseItemV1,
|
|
407
438
|
errors: [],
|
|
@@ -425,6 +456,7 @@ exports.getAssetidAssetid = (0, __1.endpoint)({
|
|
|
425
456
|
* @param expectedAssetType
|
|
426
457
|
* @param doNotFallbackToBaselineRepresentation
|
|
427
458
|
* @param contentRepresentationPriorityList
|
|
459
|
+
* @param accessContext
|
|
428
460
|
*/
|
|
429
461
|
exports.getAssetidAssetidVersionVersionnumber = (0, __1.endpoint)({
|
|
430
462
|
method: 'GET',
|
|
@@ -488,6 +520,10 @@ exports.getAssetidAssetidVersionVersionnumber = (0, __1.endpoint)({
|
|
|
488
520
|
style: 'form',
|
|
489
521
|
explode: true,
|
|
490
522
|
},
|
|
523
|
+
accessContext: {
|
|
524
|
+
style: 'form',
|
|
525
|
+
explode: true,
|
|
526
|
+
},
|
|
491
527
|
},
|
|
492
528
|
parameters: {
|
|
493
529
|
assetId: zod_1.z.number().int(),
|
|
@@ -506,6 +542,7 @@ exports.getAssetidAssetidVersionVersionnumber = (0, __1.endpoint)({
|
|
|
506
542
|
expectedAssetType: zod_1.z.string().optional(),
|
|
507
543
|
doNotFallbackToBaselineRepresentation: zod_1.z.boolean().optional(),
|
|
508
544
|
contentRepresentationPriorityList: zod_1.z.string().optional(),
|
|
545
|
+
accessContext: zod_1.z.string().optional(),
|
|
509
546
|
},
|
|
510
547
|
response: Roblox_Web_Assets_AssetResponseItemV1,
|
|
511
548
|
errors: [],
|
|
@@ -515,7 +552,6 @@ exports.getAssetidAssetidVersionVersionnumber = (0, __1.endpoint)({
|
|
|
515
552
|
* @param body
|
|
516
553
|
* @param Roblox-Place-Id
|
|
517
554
|
* @param Accept
|
|
518
|
-
* @param Roblox-Browser-Asset-Request
|
|
519
555
|
*/
|
|
520
556
|
exports.postAssetsBatch = (0, __1.endpoint)({
|
|
521
557
|
method: 'POST',
|
|
@@ -530,14 +566,10 @@ exports.postAssetsBatch = (0, __1.endpoint)({
|
|
|
530
566
|
Accept: {
|
|
531
567
|
style: 'simple',
|
|
532
568
|
},
|
|
533
|
-
'Roblox-Browser-Asset-Request': {
|
|
534
|
-
style: 'simple',
|
|
535
|
-
},
|
|
536
569
|
},
|
|
537
570
|
parameters: {
|
|
538
571
|
'Roblox-Place-Id': zod_1.z.number().int(),
|
|
539
572
|
Accept: zod_1.z.string(),
|
|
540
|
-
'Roblox-Browser-Asset-Request': zod_1.z.string(),
|
|
541
573
|
},
|
|
542
574
|
body: zod_1.z.array(Roblox_Web_Assets_BatchAssetRequestItem),
|
|
543
575
|
response: zod_1.z.array(Roblox_Web_Assets_AssetResponseItemV1),
|
|
@@ -645,3 +677,237 @@ exports.getMarassethashMarassethashMarchecksumMarchecksum = (0, __1.endpoint)({
|
|
|
645
677
|
},
|
|
646
678
|
],
|
|
647
679
|
});
|
|
680
|
+
/**
|
|
681
|
+
* @api GET https://assetdelivery.roblox.com/v1/openCloud/assetId/:assetId
|
|
682
|
+
* @summary Retrieves an asset by its ID with OpenCloud auth.
|
|
683
|
+
* @param assetId The ID of the asset to retrieve.
|
|
684
|
+
* @param Accept-Encoding The Accept-Encoding header value specifying compression formats (e.g., "gzip, deflate"). Defaults to "gzip, deflate" if not provided.
|
|
685
|
+
* @param Roblox-Place-Id The Roblox-Place-Id header value identifying the place making the request.
|
|
686
|
+
* @param AssetType The AssetType header value specifying the expected asset type.
|
|
687
|
+
* @param Accept The Accept header value specifying the preferred response content type.
|
|
688
|
+
* @param AssetFormat The AssetFormat header value specifying the desired asset format. Overridden by robloxAssetFormat if both are provided.
|
|
689
|
+
* @param Roblox-AssetFormat The Roblox-AssetFormat header value specifying the preferred Roblox-specific asset format. Takes precedence over assetFormat.
|
|
690
|
+
* @param skipSigningScripts Whether to skip script signing for the returned asset. Used for script assets that don't require signing.
|
|
691
|
+
* @param clientInsert Set to 1 to indicate this is a client insert request.
|
|
692
|
+
* @param scriptinsert Set to 1 to indicate this is a script insert request.
|
|
693
|
+
* @param modulePlaceId The place ID of the module making the request.
|
|
694
|
+
* @param serverplaceid The server place ID making the request.
|
|
695
|
+
* @param expectedAssetType The expected asset type as a fallback when assetType header is not provided.
|
|
696
|
+
* @param doNotFallbackToBaselineRepresentation Whether to prevent fallback to baseline representation when specific content representations are not available.
|
|
697
|
+
* @param contentRepresentationPriorityList Base64URL-encoded JSON string specifying the priority list of desired content representations (format, version, fidelity).
|
|
698
|
+
* @param accessContext
|
|
699
|
+
* @description Returns an object containing a `location` property which is a temporary CDN URL for the asset content. All asset types are supported.
|
|
700
|
+
You should request that URL with the `Accept-Encoding: gzip` header and decompress the result if the response is gzipped. If you are using cURL, the `--compressed` flag will automate these steps for you.
|
|
701
|
+
This endpoint is expected to be called with API key authentication through `apis.roblox.com/asset-delivery-api/v1/assetId/{assetId}`.
|
|
702
|
+
While you are able to make requests to this endpoint with Cookie authentication via `assetdelivery.roblox.com/v1/openCloud/assetId/{assetId}`, we highly discourage use this way.
|
|
703
|
+
Expect unannounced removal of this second route in the future.
|
|
704
|
+
*/
|
|
705
|
+
exports.getOpencloudAssetidAssetid = (0, __1.endpoint)({
|
|
706
|
+
method: 'GET',
|
|
707
|
+
path: '/v1/openCloud/assetId/:assetId',
|
|
708
|
+
baseUrl: 'https://assetdelivery.roblox.com',
|
|
709
|
+
requestFormat: 'json',
|
|
710
|
+
serializationMethod: {
|
|
711
|
+
assetId: {
|
|
712
|
+
style: 'simple',
|
|
713
|
+
},
|
|
714
|
+
'Accept-Encoding': {
|
|
715
|
+
style: 'simple',
|
|
716
|
+
},
|
|
717
|
+
'Roblox-Place-Id': {
|
|
718
|
+
style: 'simple',
|
|
719
|
+
},
|
|
720
|
+
AssetType: {
|
|
721
|
+
style: 'simple',
|
|
722
|
+
},
|
|
723
|
+
Accept: {
|
|
724
|
+
style: 'simple',
|
|
725
|
+
},
|
|
726
|
+
AssetFormat: {
|
|
727
|
+
style: 'simple',
|
|
728
|
+
},
|
|
729
|
+
'Roblox-AssetFormat': {
|
|
730
|
+
style: 'simple',
|
|
731
|
+
},
|
|
732
|
+
skipSigningScripts: {
|
|
733
|
+
style: 'form',
|
|
734
|
+
explode: true,
|
|
735
|
+
},
|
|
736
|
+
clientInsert: {
|
|
737
|
+
style: 'form',
|
|
738
|
+
explode: true,
|
|
739
|
+
},
|
|
740
|
+
scriptinsert: {
|
|
741
|
+
style: 'form',
|
|
742
|
+
explode: true,
|
|
743
|
+
},
|
|
744
|
+
modulePlaceId: {
|
|
745
|
+
style: 'form',
|
|
746
|
+
explode: true,
|
|
747
|
+
},
|
|
748
|
+
serverplaceid: {
|
|
749
|
+
style: 'form',
|
|
750
|
+
explode: true,
|
|
751
|
+
},
|
|
752
|
+
expectedAssetType: {
|
|
753
|
+
style: 'form',
|
|
754
|
+
explode: true,
|
|
755
|
+
},
|
|
756
|
+
doNotFallbackToBaselineRepresentation: {
|
|
757
|
+
style: 'form',
|
|
758
|
+
explode: true,
|
|
759
|
+
},
|
|
760
|
+
contentRepresentationPriorityList: {
|
|
761
|
+
style: 'form',
|
|
762
|
+
explode: true,
|
|
763
|
+
},
|
|
764
|
+
accessContext: {
|
|
765
|
+
style: 'form',
|
|
766
|
+
explode: true,
|
|
767
|
+
},
|
|
768
|
+
},
|
|
769
|
+
parameters: {
|
|
770
|
+
assetId: zod_1.z.number().int(),
|
|
771
|
+
'Accept-Encoding': zod_1.z.string().optional(),
|
|
772
|
+
'Roblox-Place-Id': zod_1.z.number().int().optional(),
|
|
773
|
+
AssetType: zod_1.z.string().optional(),
|
|
774
|
+
Accept: zod_1.z.string().optional(),
|
|
775
|
+
AssetFormat: zod_1.z.string().optional(),
|
|
776
|
+
'Roblox-AssetFormat': zod_1.z.string().optional(),
|
|
777
|
+
skipSigningScripts: zod_1.z.boolean().optional(),
|
|
778
|
+
clientInsert: zod_1.z.number().int().optional(),
|
|
779
|
+
scriptinsert: zod_1.z.number().int().optional(),
|
|
780
|
+
modulePlaceId: zod_1.z.number().int().optional(),
|
|
781
|
+
serverplaceid: zod_1.z.number().int().optional(),
|
|
782
|
+
expectedAssetType: zod_1.z.string().optional(),
|
|
783
|
+
doNotFallbackToBaselineRepresentation: zod_1.z.boolean().optional(),
|
|
784
|
+
contentRepresentationPriorityList: zod_1.z.string().optional(),
|
|
785
|
+
accessContext: zod_1.z.string().optional(),
|
|
786
|
+
},
|
|
787
|
+
response: Roblox_Web_Assets_AssetResponseItemV1,
|
|
788
|
+
errors: [
|
|
789
|
+
{
|
|
790
|
+
status: 401,
|
|
791
|
+
description: `0: Authorization has been denied for this request.`,
|
|
792
|
+
},
|
|
793
|
+
],
|
|
794
|
+
});
|
|
795
|
+
/**
|
|
796
|
+
* @api GET https://assetdelivery.roblox.com/v1/openCloud/assetId/:assetId/version/:versionNumber
|
|
797
|
+
* @summary Retrieves an asset by its ID and version number with OpenCloud auth.
|
|
798
|
+
* @param assetId The ID of the asset to retrieve.
|
|
799
|
+
* @param versionNumber The version number of the asset to retrieve.
|
|
800
|
+
* @param Accept-Encoding
|
|
801
|
+
* @param Roblox-Place-Id
|
|
802
|
+
* @param AssetType
|
|
803
|
+
* @param Accept
|
|
804
|
+
* @param AssetFormat
|
|
805
|
+
* @param Roblox-AssetFormat
|
|
806
|
+
* @param skipSigningScripts
|
|
807
|
+
* @param clientInsert
|
|
808
|
+
* @param scriptinsert
|
|
809
|
+
* @param modulePlaceId
|
|
810
|
+
* @param serverplaceid
|
|
811
|
+
* @param expectedAssetType
|
|
812
|
+
* @param doNotFallbackToBaselineRepresentation
|
|
813
|
+
* @param contentRepresentationPriorityList
|
|
814
|
+
* @param accessContext
|
|
815
|
+
* @description Refer to the assetId endpoint for details on usage.
|
|
816
|
+
This endpoint is expected to be called with API key authentication through `apis.roblox.com/asset-delivery-api/v1/assetId/{assetId}/version/{versionNumber}`.
|
|
817
|
+
While you are able to make requests to this endpoint with Cookie authentication via `assetdelivery.roblox.com/v1/openCloud/assetId/{assetId}/version/{versionNumber}`, we highly discourage use this way.
|
|
818
|
+
Expect unannounced removal of this second route in the future.
|
|
819
|
+
*/
|
|
820
|
+
exports.getOpencloudAssetidAssetidVersionVersionnumber = (0, __1.endpoint)({
|
|
821
|
+
method: 'GET',
|
|
822
|
+
path: '/v1/openCloud/assetId/:assetId/version/:versionNumber',
|
|
823
|
+
baseUrl: 'https://assetdelivery.roblox.com',
|
|
824
|
+
requestFormat: 'json',
|
|
825
|
+
serializationMethod: {
|
|
826
|
+
assetId: {
|
|
827
|
+
style: 'simple',
|
|
828
|
+
},
|
|
829
|
+
versionNumber: {
|
|
830
|
+
style: 'simple',
|
|
831
|
+
},
|
|
832
|
+
'Accept-Encoding': {
|
|
833
|
+
style: 'simple',
|
|
834
|
+
},
|
|
835
|
+
'Roblox-Place-Id': {
|
|
836
|
+
style: 'simple',
|
|
837
|
+
},
|
|
838
|
+
AssetType: {
|
|
839
|
+
style: 'simple',
|
|
840
|
+
},
|
|
841
|
+
Accept: {
|
|
842
|
+
style: 'simple',
|
|
843
|
+
},
|
|
844
|
+
AssetFormat: {
|
|
845
|
+
style: 'simple',
|
|
846
|
+
},
|
|
847
|
+
'Roblox-AssetFormat': {
|
|
848
|
+
style: 'simple',
|
|
849
|
+
},
|
|
850
|
+
skipSigningScripts: {
|
|
851
|
+
style: 'form',
|
|
852
|
+
explode: true,
|
|
853
|
+
},
|
|
854
|
+
clientInsert: {
|
|
855
|
+
style: 'form',
|
|
856
|
+
explode: true,
|
|
857
|
+
},
|
|
858
|
+
scriptinsert: {
|
|
859
|
+
style: 'form',
|
|
860
|
+
explode: true,
|
|
861
|
+
},
|
|
862
|
+
modulePlaceId: {
|
|
863
|
+
style: 'form',
|
|
864
|
+
explode: true,
|
|
865
|
+
},
|
|
866
|
+
serverplaceid: {
|
|
867
|
+
style: 'form',
|
|
868
|
+
explode: true,
|
|
869
|
+
},
|
|
870
|
+
expectedAssetType: {
|
|
871
|
+
style: 'form',
|
|
872
|
+
explode: true,
|
|
873
|
+
},
|
|
874
|
+
doNotFallbackToBaselineRepresentation: {
|
|
875
|
+
style: 'form',
|
|
876
|
+
explode: true,
|
|
877
|
+
},
|
|
878
|
+
contentRepresentationPriorityList: {
|
|
879
|
+
style: 'form',
|
|
880
|
+
explode: true,
|
|
881
|
+
},
|
|
882
|
+
accessContext: {
|
|
883
|
+
style: 'form',
|
|
884
|
+
explode: true,
|
|
885
|
+
},
|
|
886
|
+
},
|
|
887
|
+
parameters: {
|
|
888
|
+
assetId: zod_1.z.number().int(),
|
|
889
|
+
versionNumber: zod_1.z.number().int(),
|
|
890
|
+
'Accept-Encoding': zod_1.z.string().optional(),
|
|
891
|
+
'Roblox-Place-Id': zod_1.z.number().int().optional(),
|
|
892
|
+
AssetType: zod_1.z.string().optional(),
|
|
893
|
+
Accept: zod_1.z.string().optional(),
|
|
894
|
+
AssetFormat: zod_1.z.string().optional(),
|
|
895
|
+
'Roblox-AssetFormat': zod_1.z.string().optional(),
|
|
896
|
+
skipSigningScripts: zod_1.z.boolean().optional(),
|
|
897
|
+
clientInsert: zod_1.z.number().int().optional(),
|
|
898
|
+
scriptinsert: zod_1.z.number().int().optional(),
|
|
899
|
+
modulePlaceId: zod_1.z.number().int().optional(),
|
|
900
|
+
serverplaceid: zod_1.z.number().int().optional(),
|
|
901
|
+
expectedAssetType: zod_1.z.string().optional(),
|
|
902
|
+
doNotFallbackToBaselineRepresentation: zod_1.z.boolean().optional(),
|
|
903
|
+
contentRepresentationPriorityList: zod_1.z.string().optional(),
|
|
904
|
+
accessContext: zod_1.z.string().optional(),
|
|
905
|
+
},
|
|
906
|
+
response: Roblox_Web_Assets_AssetResponseItemV1,
|
|
907
|
+
errors: [
|
|
908
|
+
{
|
|
909
|
+
status: 401,
|
|
910
|
+
description: `0: Authorization has been denied for this request.`,
|
|
911
|
+
},
|
|
912
|
+
],
|
|
913
|
+
});
|