@jacobhumston/roblox-openapi-ts 1.0.0 → 1.0.3

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 CHANGED
@@ -3,5 +3,3 @@
3
3
  An automatically updated [openapi-fetch](https://openapi-ts.dev/openapi-fetch/) client for Roblox's [OpenAPI](https://create.roblox.com/docs/cloud/reference/openapi) document.
4
4
 
5
5
  This package is intended for quickly testing the Roblox API.
6
-
7
- Docs: [https://jacobhumston.github.io/roblox-openapi-ts](https://jacobhumston.github.io/roblox-openapi-ts)
package/dist/index.d.ts CHANGED
@@ -1,4 +1,11 @@
1
- import { $defs, components, operations, paths, webhooks } from './types.js';
2
- export { $defs, components, operations, paths, webhooks };
3
- /** Roblox API client. */
4
- export declare const client: import("openapi-fetch").Client<paths, `${string}/${string}`>;
1
+ import { ClientOptions } from 'openapi-fetch';
2
+ import { paths } from './types.js';
3
+ export * from './types.js';
4
+ /**
5
+ * Create a new Roblox API client.
6
+ * @param url The URL for this client. Default is https://apis.roblox.com
7
+ * @param options Options to pass to the API client.
8
+ */
9
+ export declare function newRobloxAPIClient(url?: RobloxApiUrl, options?: ClientOptions): import("openapi-fetch").Client<paths, `${string}/${string}`>;
10
+ /** Roblox API urls. */
11
+ export type RobloxApiUrl = 'https://apis.roblox.com' | 'https://accountinformation.roblox.com' | 'https://accountsettings.roblox.com' | 'https://adconfiguration.roblox.com' | 'https://assetdelivery.roblox.com' | 'https://auth.roblox.com' | 'https://avatar.roblox.com' | 'https://badges.roblox.com' | 'https://catalog.roblox.com' | 'https://clientsettings.roblox.com' | 'https://contacts.roblox.com' | 'https://develop.roblox.com' | 'https://economy.roblox.com' | 'https://economycreatorstats.roblox.com' | 'https://engagementpayouts.roblox.com' | 'https://followings.roblox.com' | 'https://friends.roblox.com' | 'https://gameinternationalization.roblox.com' | 'https://games.roblox.com' | 'https://groups.roblox.com' | 'https://inventory.roblox.com' | 'https://itemconfiguration.roblox.com' | 'https://locale.roblox.com' | 'https://localizationtables.roblox.com' | 'https://notifications.roblox.com' | 'https://premiumfeatures.roblox.com' | 'https://presence.roblox.com' | 'https://privatemessages.roblox.com' | 'https://publish.roblox.com' | 'https://thumbnails.roblox.com' | 'https://thumbnailsresizer.roblox.com' | 'https://trades.roblox.com' | 'https://translationroles.roblox.com' | 'https://twostepverification.roblox.com' | 'https://users.roblox.com';
package/dist/index.js CHANGED
@@ -1,4 +1,11 @@
1
1
  import createClient from 'openapi-fetch';
2
- /** Roblox API client. */
3
- export const client = createClient({ baseUrl: 'https://apis.roblox.com' });
2
+ export * from './types.js';
3
+ /**
4
+ * Create a new Roblox API client.
5
+ * @param url The URL for this client. Default is https://apis.roblox.com
6
+ * @param options Options to pass to the API client.
7
+ */
8
+ export function newRobloxAPIClient(url, options) {
9
+ return createClient({ ...(options ?? {}), ...{ baseUrl: url ?? 'https://apis.roblox.com' } });
10
+ }
4
11
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,YAAY,MAAM,eAAe,CAAC;AAKzC,yBAAyB;AACzB,MAAM,CAAC,MAAM,MAAM,GAAG,YAAY,CAAQ,EAAE,OAAO,EAAE,yBAAyB,EAAE,CAAC,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,YAA+B,MAAM,eAAe,CAAC;AAG5D,cAAc,YAAY,CAAC;AAE3B;;;;GAIG;AACH,MAAM,UAAU,kBAAkB,CAAC,GAAkB,EAAE,OAAuB;IAC1E,OAAO,YAAY,CAAQ,EAAE,GAAG,CAAC,OAAO,IAAI,EAAE,CAAC,EAAE,GAAG,EAAE,OAAO,EAAE,GAAG,IAAI,yBAAyB,EAAE,EAAE,CAAC,CAAC;AACzG,CAAC"}
package/dist/types.d.ts CHANGED
@@ -11445,6 +11445,7 @@ export interface paths {
11445
11445
  * @description 3: The request did not contain a file to be uploaded.
11446
11446
  * 4: The file in the request is too large.
11447
11447
  * 5: The duration of the audio file is too long.
11448
+ * 7: Failed to parse the file.
11448
11449
  * 8: The file type is not supported.
11449
11450
  * 9: The file is corrupted
11450
11451
  * 11: Missing permissions to spend group funds.
@@ -11481,10 +11482,7 @@ export interface paths {
11481
11482
  };
11482
11483
  content?: never;
11483
11484
  };
11484
- /**
11485
- * @description 7: Failed to parse the file.
11486
- * 19: Asset creation was unavailable. Please try again.
11487
- */
11485
+ /** @description 19: Asset creation was unavailable. Please try again. */
11488
11486
  500: {
11489
11487
  headers: {
11490
11488
  [name: string]: unknown;
@@ -11538,6 +11536,7 @@ export interface paths {
11538
11536
  * @description 3: The request did not contain a file to be uploaded.
11539
11537
  * 4: The file in the request is too large.
11540
11538
  * 5: The duration of the audio file is too long.
11539
+ * 7: Failed to parse the file.
11541
11540
  * 8: The file type is not supported.
11542
11541
  * 9: The file is corrupted
11543
11542
  * 18: Too many requests. Try again later.
@@ -11565,13 +11564,6 @@ export interface paths {
11565
11564
  };
11566
11565
  content?: never;
11567
11566
  };
11568
- /** @description 7: Failed to parse the file. */
11569
- 500: {
11570
- headers: {
11571
- [name: string]: unknown;
11572
- };
11573
- content?: never;
11574
- };
11575
11567
  };
11576
11568
  };
11577
11569
  delete?: never;
@@ -19318,6 +19310,8 @@ export interface paths {
19318
19310
  query: {
19319
19311
  /** @description A list of universe Ids. Cannot exceed a maximum of 50 IDs. */
19320
19312
  universeIds: number[];
19313
+ /** @description Optional comma-separated list of field names to include in the response. When omitted, all fields are returned. */
19314
+ fields?: string;
19321
19315
  };
19322
19316
  header?: never;
19323
19317
  path?: never;
@@ -50354,6 +50348,17 @@ export interface components {
50354
50348
  */
50355
50349
  bypassSlowMode?: boolean;
50356
50350
  };
50351
+ "GroupsApi.Roblox.Web.Responses.RelatedEntityTypeResponse_Roblox.Platform.Assets.AssetType_": {
50352
+ /** Format: int64 */
50353
+ id?: number;
50354
+ /**
50355
+ * Format: int32
50356
+ * @description ['Image' = 1, 'TShirt' = 2, 'Audio' = 3, 'Mesh' = 4, 'Lua' = 5, 'HTML' = 6, 'Text' = 7, 'Hat' = 8, 'Place' = 9, 'Model' = 10, 'Shirt' = 11, 'Pants' = 12, 'Decal' = 13, 'Avatar' = 16, 'Head' = 17, 'Face' = 18, 'Gear' = 19, 'Badge' = 21, 'GroupEmblem' = 22, 'Animation' = 24, 'Arms' = 25, 'Legs' = 26, 'Torso' = 27, 'RightArm' = 28, 'LeftArm' = 29, 'LeftLeg' = 30, 'RightLeg' = 31, 'Package' = 32, 'YouTubeVideo' = 33, 'GamePass' = 34, 'App' = 35, 'Code' = 37, 'Plugin' = 38, 'SolidModel' = 39, 'MeshPart' = 40, 'HairAccessory' = 41, 'FaceAccessory' = 42, 'NeckAccessory' = 43, 'ShoulderAccessory' = 44, 'FrontAccessory' = 45, 'BackAccessory' = 46, 'WaistAccessory' = 47, 'ClimbAnimation' = 48, 'DeathAnimation' = 49, 'FallAnimation' = 50, 'IdleAnimation' = 51, 'JumpAnimation' = 52, 'RunAnimation' = 53, 'SwimAnimation' = 54, 'WalkAnimation' = 55, 'PoseAnimation' = 56, 'LocalizationTableManifest' = 59, 'LocalizationTableTranslation' = 60, 'EmoteAnimation' = 61, 'Video' = 62, 'TexturePack' = 63, 'TShirtAccessory' = 64, 'ShirtAccessory' = 65, 'PantsAccessory' = 66, 'JacketAccessory' = 67, 'SweaterAccessory' = 68, 'ShortsAccessory' = 69, 'LeftShoeAccessory' = 70, 'RightShoeAccessory' = 71, 'DressSkirtAccessory' = 72, 'FontFamily' = 73, 'FontFace' = 74, 'MeshHiddenSurfaceRemoval' = 75, 'EyebrowAccessory' = 76, 'EyelashAccessory' = 77, 'MoodAnimation' = 78, 'DynamicHead' = 79, 'CodeSnippet' = 80, 'AdsVideo' = 81, 'OtaUpdate' = 82, 'Screenshot' = 83, 'RuntimePropertySet' = 84, 'StorePreviewVideo' = 85, 'GamePreviewVideo' = 86, 'CreatorExperienceConfig' = 87, 'FaceMakeup' = 88, 'LipMakeup' = 89, 'EyeMakeup' = 90, 'VoxelFragment' = 91]
50357
+ * @enum {integer}
50358
+ */
50359
+ type?: 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 16 | 17 | 18 | 19 | 21 | 22 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91;
50360
+ name?: string;
50361
+ };
50357
50362
  HttpContent: {
50358
50363
  readonly headers?: components["schemas"]["StringStringIEnumerableKeyValuePair"][] | null;
50359
50364
  };
@@ -55617,6 +55622,7 @@ export interface components {
55617
55622
  product?: components["schemas"]["Roblox.Catalog.Api.BundleProductModel"];
55618
55623
  itemRestrictions?: (1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9)[];
55619
55624
  collectibleItemDetail?: components["schemas"]["Roblox.Catalog.Api.CollectibleItemDetail"];
55625
+ discountInformation?: components["schemas"]["Roblox.Catalog.Api.DiscountInformation"];
55620
55626
  };
55621
55627
  /** @description A model to represent bundle favorites. */
55622
55628
  "Roblox.Catalog.Api.BundleFavoriteModel": {
@@ -56005,6 +56011,23 @@ export interface components {
56005
56011
  */
56006
56012
  resaleRestriction?: 0 | 1 | 2;
56007
56013
  };
56014
+ "Roblox.Catalog.Api.Discount": {
56015
+ /** Format: int64 */
56016
+ robuxDiscountAmount?: number;
56017
+ /** Format: float */
56018
+ robuxDiscountPercentage?: number;
56019
+ discountCampaign?: string;
56020
+ localizedDiscountAttribution?: string;
56021
+ };
56022
+ "Roblox.Catalog.Api.DiscountInformation": {
56023
+ /** Format: int64 */
56024
+ originalPrice?: number;
56025
+ /** Format: float */
56026
+ totalDiscountPercentage?: number;
56027
+ /** Format: int64 */
56028
+ totalDiscountAmount?: number;
56029
+ discounts?: components["schemas"]["Roblox.Catalog.Api.Discount"][];
56030
+ };
56008
56031
  "Roblox.Catalog.Api.ElasticsearchDebugInfo": {
56009
56032
  /** @description Gets or sets the nest query that resulted from the operation. */
56010
56033
  elasticsearchQuery?: string;
@@ -56124,6 +56147,7 @@ export interface components {
56124
56147
  * @description The price for the timed option.
56125
56148
  */
56126
56149
  price?: number;
56150
+ discountInformation?: components["schemas"]["Roblox.Catalog.Api.DiscountInformation"];
56127
56151
  /** @description To indicate if this option is selected by the client. */
56128
56152
  selected?: boolean;
56129
56153
  };
@@ -57368,6 +57392,11 @@ export interface components {
57368
57392
  refundLink?: string;
57369
57393
  localizedFiatPrice?: string;
57370
57394
  refundPolicy?: components["schemas"]["Roblox.Games.Api.Models.Response.RefundPolicy"];
57395
+ /**
57396
+ * @description Canonical URL path for the game page, e.g. /games/{placeId}/{canonical-slug}.
57397
+ * It must be the same as the canonical URL (rel-canonical meta tag) on the game's EDP.
57398
+ */
57399
+ canonicalUrlPath?: string;
57371
57400
  };
57372
57401
  /** @description Game favorite response model. */
57373
57402
  "Roblox.Games.Api.Models.Response.GameFavoriteResponse": {
@@ -58365,7 +58394,7 @@ export interface components {
58365
58394
  /** @description The game description. */
58366
58395
  description?: string;
58367
58396
  creator?: components["schemas"]["Roblox.Web.Responses.RelatedEntityTypeResponse_Roblox.Platform.Core.CreatorType_"];
58368
- rootPlace?: components["schemas"]["Roblox.Web.Responses.RelatedEntityTypeResponse_Roblox.Platform.Assets.AssetType_"];
58397
+ rootPlace?: components["schemas"]["GroupsApi.Roblox.Web.Responses.RelatedEntityTypeResponse_Roblox.Platform.Assets.AssetType_"];
58369
58398
  /**
58370
58399
  * Format: date-time
58371
58400
  * @description When the game was created.
@@ -60999,10 +61028,10 @@ export interface components {
60999
61028
  id?: number;
61000
61029
  /**
61001
61030
  * Format: int32
61002
- * @description ['Image' = 1, 'TShirt' = 2, 'Audio' = 3, 'Mesh' = 4, 'Lua' = 5, 'HTML' = 6, 'Text' = 7, 'Hat' = 8, 'Place' = 9, 'Model' = 10, 'Shirt' = 11, 'Pants' = 12, 'Decal' = 13, 'Avatar' = 16, 'Head' = 17, 'Face' = 18, 'Gear' = 19, 'Badge' = 21, 'GroupEmblem' = 22, 'Animation' = 24, 'Arms' = 25, 'Legs' = 26, 'Torso' = 27, 'RightArm' = 28, 'LeftArm' = 29, 'LeftLeg' = 30, 'RightLeg' = 31, 'Package' = 32, 'YouTubeVideo' = 33, 'GamePass' = 34, 'App' = 35, 'Code' = 37, 'Plugin' = 38, 'SolidModel' = 39, 'MeshPart' = 40, 'HairAccessory' = 41, 'FaceAccessory' = 42, 'NeckAccessory' = 43, 'ShoulderAccessory' = 44, 'FrontAccessory' = 45, 'BackAccessory' = 46, 'WaistAccessory' = 47, 'ClimbAnimation' = 48, 'DeathAnimation' = 49, 'FallAnimation' = 50, 'IdleAnimation' = 51, 'JumpAnimation' = 52, 'RunAnimation' = 53, 'SwimAnimation' = 54, 'WalkAnimation' = 55, 'PoseAnimation' = 56, 'LocalizationTableManifest' = 59, 'LocalizationTableTranslation' = 60, 'EmoteAnimation' = 61, 'Video' = 62, 'TexturePack' = 63, 'TShirtAccessory' = 64, 'ShirtAccessory' = 65, 'PantsAccessory' = 66, 'JacketAccessory' = 67, 'SweaterAccessory' = 68, 'ShortsAccessory' = 69, 'LeftShoeAccessory' = 70, 'RightShoeAccessory' = 71, 'DressSkirtAccessory' = 72, 'FontFamily' = 73, 'FontFace' = 74, 'MeshHiddenSurfaceRemoval' = 75, 'EyebrowAccessory' = 76, 'EyelashAccessory' = 77, 'MoodAnimation' = 78, 'DynamicHead' = 79, 'CodeSnippet' = 80, 'AdsVideo' = 81, 'OtaUpdate' = 82, 'Screenshot' = 83, 'RuntimePropertySet' = 84, 'StorePreviewVideo' = 85, 'GamePreviewVideo' = 86, 'CreatorExperienceConfig' = 87, 'FaceMakeup' = 88, 'LipMakeup' = 89, 'EyeMakeup' = 90, 'VoxelFragment' = 91]
61031
+ * @description ['Image' = 1, 'TShirt' = 2, 'Audio' = 3, 'Mesh' = 4, 'Lua' = 5, 'HTML' = 6, 'Text' = 7, 'Hat' = 8, 'Place' = 9, 'Model' = 10, 'Shirt' = 11, 'Pants' = 12, 'Decal' = 13, 'Avatar' = 16, 'Head' = 17, 'Face' = 18, 'Gear' = 19, 'Badge' = 21, 'GroupEmblem' = 22, 'Animation' = 24, 'Arms' = 25, 'Legs' = 26, 'Torso' = 27, 'RightArm' = 28, 'LeftArm' = 29, 'LeftLeg' = 30, 'RightLeg' = 31, 'Package' = 32, 'YouTubeVideo' = 33, 'GamePass' = 34, 'App' = 35, 'Code' = 37, 'Plugin' = 38, 'SolidModel' = 39, 'MeshPart' = 40, 'HairAccessory' = 41, 'FaceAccessory' = 42, 'NeckAccessory' = 43, 'ShoulderAccessory' = 44, 'FrontAccessory' = 45, 'BackAccessory' = 46, 'WaistAccessory' = 47, 'ClimbAnimation' = 48, 'DeathAnimation' = 49, 'FallAnimation' = 50, 'IdleAnimation' = 51, 'JumpAnimation' = 52, 'RunAnimation' = 53, 'SwimAnimation' = 54, 'WalkAnimation' = 55, 'PoseAnimation' = 56, 'LocalizationTableManifest' = 59, 'LocalizationTableTranslation' = 60, 'EmoteAnimation' = 61, 'Video' = 62, 'TexturePack' = 63, 'TShirtAccessory' = 64, 'ShirtAccessory' = 65, 'PantsAccessory' = 66, 'JacketAccessory' = 67, 'SweaterAccessory' = 68, 'ShortsAccessory' = 69, 'LeftShoeAccessory' = 70, 'RightShoeAccessory' = 71, 'DressSkirtAccessory' = 72, 'FontFamily' = 73, 'FontFace' = 74, 'MeshHiddenSurfaceRemoval' = 75, 'EyebrowAccessory' = 76, 'EyelashAccessory' = 77, 'MoodAnimation' = 78, 'DynamicHead' = 79, 'CodeSnippet' = 80, 'AdsVideo' = 81, 'OtaUpdate' = 82, 'Screenshot' = 83, 'RuntimePropertySet' = 84, 'StorePreviewVideo' = 85, 'GamePreviewVideo' = 86, 'CreatorExperienceConfig' = 87, 'FaceMakeup' = 88, 'LipMakeup' = 89, 'EyeMakeup' = 90, 'VoxelFragment' = 91, 'AvatarBackground' = 92]
61003
61032
  * @enum {integer}
61004
61033
  */
61005
- type?: 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 16 | 17 | 18 | 19 | 21 | 22 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91;
61034
+ type?: 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 16 | 17 | 18 | 19 | 21 | 22 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92;
61006
61035
  name?: string;
61007
61036
  };
61008
61037
  "Roblox.Web.Responses.RelatedEntityTypeResponse_Roblox.Platform.Badges.BadgeAwarderType_": {
@@ -61398,8 +61427,8 @@ export interface components {
61398
61427
  /** @description The search terms used to filter the results. Only one of 'query' and 'image' can be present in a query. */
61399
61428
  query?: string | null;
61400
61429
  /**
61401
- * Format: binary
61402
- * @description The image file to search by. Only one of 'query' and 'image' can be present in a query.
61430
+ * Format: byte
61431
+ * @description The image file to search by. The image must be base64 encoded to be used in the search. Only one of 'query' and 'image' can be present in a query.
61403
61432
  */
61404
61433
  image?: string | null;
61405
61434
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jacobhumston/roblox-openapi-ts",
3
- "version": "1.0.0",
3
+ "version": "1.0.3",
4
4
  "description": "An automatically updated Roblox API client based on their OpenAPI documentation.",
5
5
  "keywords": [
6
6
  "roblox",
@@ -11,14 +11,13 @@
11
11
  "module": "dist/index.js",
12
12
  "types": "dist/index.d.ts",
13
13
  "license": "MIT",
14
- "homepage": "https://github.com/jacobhumston/flags.ts",
14
+ "homepage": "https://github.com/jacobhumston/roblox-openapi-ts",
15
15
  "repository": {
16
- "url": "https://github.com/jacobhumston/flags.ts"
16
+ "url": "https://github.com/jacobhumston/roblox-openapi-ts"
17
17
  },
18
18
  "scripts": {
19
19
  "format": "bun x prettier --write --cache .",
20
- "compile": "bun run tools/build.ts && del dist/ && bun x tsc && bun run tools/bundle.ts",
21
- "docs": "del docs/ && bun x typedoc src/index.ts --options typedoc.json && bun x prettier --write --ignore-path null docs/"
20
+ "compile": "bun run tools/build.ts && del dist/ && bun x tsc"
22
21
  },
23
22
  "devDependencies": {
24
23
  "@ianvs/prettier-plugin-sort-imports": "^4.7.1",