Socket
Socket
Sign inDemoInstall

discord-api-types

Package Overview
Dependencies
Maintainers
3
Versions
949
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

discord-api-types - npm Package Compare versions

Comparing version 0.37.99 to 0.37.100-next.3de4ca8.1725550009

3

gateway/v10.js

@@ -259,4 +259,7 @@ "use strict";

GatewayDispatchEvents["EntitlementDelete"] = "ENTITLEMENT_DELETE";
GatewayDispatchEvents["SubscriptionCreate"] = "SUBSCRIPTION_CREATE";
GatewayDispatchEvents["SubscriptionUpdate"] = "SUBSCRIPTION_UPDATE";
GatewayDispatchEvents["SubscriptionDelete"] = "SUBSCRIPTION_DELETE";
})(GatewayDispatchEvents || (exports.GatewayDispatchEvents = GatewayDispatchEvents = {}));
// #endregion Shared
//# sourceMappingURL=v10.js.map

@@ -258,4 +258,7 @@ "use strict";

GatewayDispatchEvents["EntitlementDelete"] = "ENTITLEMENT_DELETE";
GatewayDispatchEvents["SubscriptionCreate"] = "SUBSCRIPTION_CREATE";
GatewayDispatchEvents["SubscriptionUpdate"] = "SUBSCRIPTION_UPDATE";
GatewayDispatchEvents["SubscriptionDelete"] = "SUBSCRIPTION_DELETE";
})(GatewayDispatchEvents || (exports.GatewayDispatchEvents = GatewayDispatchEvents = {}));
// #endregion Shared
//# sourceMappingURL=v9.js.map

@@ -91,3 +91,15 @@ /**

readonly StyledTimestamp: RegExp;
/**
* Regular expression for matching a guild navigation mention
*
* The `type` group property is present on the `exec` result of this expression
*/
readonly GuildNavigation: RegExp;
/**
* Regular expression for matching a linked role mention
*
* The `id` group property is present on the `exec` result of this expression
*/
readonly LinkedRole: RegExp;
};
//# sourceMappingURL=globals.d.ts.map

@@ -87,2 +87,14 @@ "use strict";

StyledTimestamp: /<t:(?<timestamp>-?\d{1,13}):(?<style>[DFRTdft])>/,
/**
* Regular expression for matching a guild navigation mention
*
* The `type` group property is present on the `exec` result of this expression
*/
GuildNavigation: /<id:(?<type>customize|browse|guide|linked-roles)>/,
/**
* Regular expression for matching a linked role mention
*
* The `id` group property is present on the `exec` result of this expression
*/
LinkedRole: /<id:linked-roles:(?<id>\d{17,20})>/,
};

@@ -89,0 +101,0 @@ /**

2

package.json
{
"name": "discord-api-types",
"version": "0.37.99",
"version": "0.37.100-next.3de4ca8.1725550009",
"description": "Discord API typings that are kept up to date for use in bot library creation.",

@@ -5,0 +5,0 @@ "homepage": "https://discord-api-types.dev",

@@ -121,3 +121,3 @@ /**

*/
interactions_endpoint_url?: string;
interactions_endpoint_url?: string | null;
/**

@@ -127,3 +127,3 @@ * The application's role connection verification entry point,

*/
role_connections_verification_url?: string;
role_connections_verification_url?: string | null;
/**

@@ -130,0 +130,0 @@ * Up to 5 tags of max 20 characters each describing the content and functionality of the application

@@ -1755,2 +1755,9 @@ /**

* Id of the origin message's guild
*
* @deprecated This field doesn't accurately reflect the Discord API as it doesn't exist nor is documented and will
* be removed in the next major version.
*
* It was added in {@link https://github.com/discord/discord-api-docs/pull/6833/commits/d18f72d06d62e6b1d51ca2c1ef308ddc29ff3348 | d18f72d}
* but was later removed before the PR ({@link https://github.com/discord/discord-api-docs/pull/6833 | discord-api-docs#6833}) was merged.
* See {@link https://github.com/discordjs/discord-api-types/pull/1084 | discord-api-types#1084} for more information.
*/

@@ -1812,3 +1819,3 @@ guild_id?: Snowflake;

export type APIModalActionRowComponent = APITextInputComponent;
export type APIMessageSnapshotFields = Pick<APIMessage, 'attachments' | 'content' | 'edited_timestamp' | 'embeds' | 'flags' | 'mention_roles' | 'mentions' | 'timestamp' | 'type'>;
export type APIMessageSnapshotFields = Pick<APIMessage, 'attachments' | 'components' | 'content' | 'edited_timestamp' | 'embeds' | 'flags' | 'mention_roles' | 'mentions' | 'sticker_items' | 'stickers' | 'timestamp' | 'type'>;
//# sourceMappingURL=channel.d.ts.map

@@ -133,2 +133,5 @@ import type { Snowflake } from '../../globals';

}
/**
* https://discord.com/developers/docs/resources/sku#sku-object-sku-types
*/
export declare enum SKUType {

@@ -152,2 +155,60 @@ /**

}
/**
* https://discord.com/developers/docs/resources/subscription#subscription-object
*/
export interface APISubscription {
/**
* ID of the subscription
*/
id: Snowflake;
/**
* ID of the user who is subscribed
*/
user_id: Snowflake;
/**
* List of SKUs subscribed to
*/
sku_ids: Snowflake[];
/**
* List of entitlements granted for this subscription
*/
entitlement_ids: Snowflake[];
/**
* Start of the current subscription period
*/
current_period_start: string;
/**
* End of the current subscription period
*/
current_period_end: string;
/**
* Current status of the subscription
*/
status: SubscriptionStatus;
/**
* When the subscription was canceled
*/
canceled_at: string | null;
/**
* ISO3166-1 alpha-2 country code of the payment source used to purchase the subscription. Missing unless queried with a private OAuth scope.
*/
country?: string;
}
/**
* https://discord.com/developers/docs/resources/subscription#subscription-statuses
*/
export declare enum SubscriptionStatus {
/**
* Subscription is active and scheduled to renew.
*/
Active = 0,
/**
* Subscription is active but will not renew.
*/
Ending = 1,
/**
* Subscription is inactive and not being charged.
*/
Inactive = 2
}
//# sourceMappingURL=monetization.d.ts.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.SKUType = exports.SKUFlags = exports.EntitlementType = void 0;
exports.SubscriptionStatus = exports.SKUType = exports.SKUFlags = exports.EntitlementType = void 0;
/**

@@ -61,2 +61,5 @@ * https://discord.com/developers/docs/monetization/entitlements#entitlement-object-entitlement-types

})(SKUFlags || (exports.SKUFlags = SKUFlags = {}));
/**
* https://discord.com/developers/docs/resources/sku#sku-object-sku-types
*/
var SKUType;

@@ -81,2 +84,20 @@ (function (SKUType) {

})(SKUType || (exports.SKUType = SKUType = {}));
/**
* https://discord.com/developers/docs/resources/subscription#subscription-statuses
*/
var SubscriptionStatus;
(function (SubscriptionStatus) {
/**
* Subscription is active and scheduled to renew.
*/
SubscriptionStatus[SubscriptionStatus["Active"] = 0] = "Active";
/**
* Subscription is active but will not renew.
*/
SubscriptionStatus[SubscriptionStatus["Ending"] = 1] = "Ending";
/**
* Subscription is inactive and not being charged.
*/
SubscriptionStatus[SubscriptionStatus["Inactive"] = 2] = "Inactive";
})(SubscriptionStatus || (exports.SubscriptionStatus = SubscriptionStatus = {}));
//# sourceMappingURL=monetization.js.map

@@ -270,2 +270,3 @@ /**

export declare enum ConnectionService {
AmazonMusic = "amazon-music",
BattleNet = "battlenet",

@@ -272,0 +273,0 @@ BungieNet = "bungie",

@@ -130,2 +130,3 @@ "use strict";

(function (ConnectionService) {
ConnectionService["AmazonMusic"] = "amazon-music";
ConnectionService["BattleNet"] = "battlenet";

@@ -132,0 +133,0 @@ ConnectionService["BungieNet"] = "bungie";

@@ -121,3 +121,3 @@ /**

*/
interactions_endpoint_url?: string;
interactions_endpoint_url?: string | null;
/**

@@ -127,3 +127,3 @@ * The application's role connection verification entry point,

*/
role_connections_verification_url?: string;
role_connections_verification_url?: string | null;
/**

@@ -130,0 +130,0 @@ * Up to 5 tags of max 20 characters each describing the content and functionality of the application

@@ -1724,2 +1724,9 @@ /**

* Id of the origin message's guild
*
* @deprecated This field doesn't accurately reflect the Discord API as it doesn't exist nor is documented and will
* be removed in the next major version.
*
* It was added in {@link https://github.com/discord/discord-api-docs/pull/6833/commits/d18f72d06d62e6b1d51ca2c1ef308ddc29ff3348 | d18f72d}
* but was later removed before the PR ({@link https://github.com/discord/discord-api-docs/pull/6833 | discord-api-docs#6833}) was merged.
* See {@link https://github.com/discordjs/discord-api-types/pull/1084 | discord-api-types#1084} for more information.
*/

@@ -1781,3 +1788,3 @@ guild_id?: Snowflake;

export type APIModalActionRowComponent = APITextInputComponent;
export type APIMessageSnapshotFields = Pick<APIMessage, 'attachments' | 'content' | 'edited_timestamp' | 'embeds' | 'flags' | 'mention_roles' | 'mentions' | 'timestamp' | 'type'>;
export type APIMessageSnapshotFields = Pick<APIMessage, 'attachments' | 'components' | 'content' | 'edited_timestamp' | 'embeds' | 'flags' | 'mention_roles' | 'mentions' | 'sticker_items' | 'stickers' | 'timestamp' | 'type'>;
//# sourceMappingURL=channel.d.ts.map

@@ -133,2 +133,5 @@ import type { Snowflake } from '../../globals';

}
/**
* https://discord.com/developers/docs/resources/sku#sku-object-sku-types
*/
export declare enum SKUType {

@@ -152,2 +155,60 @@ /**

}
/**
* https://discord.com/developers/docs/resources/subscription#subscription-object
*/
export interface APISubscription {
/**
* ID of the subscription
*/
id: Snowflake;
/**
* ID of the user who is subscribed
*/
user_id: Snowflake;
/**
* List of SKUs subscribed to
*/
sku_ids: Snowflake[];
/**
* List of entitlements granted for this subscription
*/
entitlement_ids: Snowflake[];
/**
* Start of the current subscription period
*/
current_period_start: string;
/**
* End of the current subscription period
*/
current_period_end: string;
/**
* Current status of the subscription
*/
status: SubscriptionStatus;
/**
* When the subscription was canceled
*/
canceled_at: string | null;
/**
* ISO3166-1 alpha-2 country code of the payment source used to purchase the subscription. Missing unless queried with a private OAuth scope.
*/
country?: string;
}
/**
* https://discord.com/developers/docs/resources/subscription#subscription-statuses
*/
export declare enum SubscriptionStatus {
/**
* Subscription is active and scheduled to renew.
*/
Active = 0,
/**
* Subscription is active but will not renew.
*/
Ending = 1,
/**
* Subscription is inactive and not being charged.
*/
Inactive = 2
}
//# sourceMappingURL=monetization.d.ts.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.SKUType = exports.SKUFlags = exports.EntitlementType = void 0;
exports.SubscriptionStatus = exports.SKUType = exports.SKUFlags = exports.EntitlementType = void 0;
/**

@@ -61,2 +61,5 @@ * https://discord.com/developers/docs/monetization/entitlements#entitlement-object-entitlement-types

})(SKUFlags || (exports.SKUFlags = SKUFlags = {}));
/**
* https://discord.com/developers/docs/resources/sku#sku-object-sku-types
*/
var SKUType;

@@ -81,2 +84,20 @@ (function (SKUType) {

})(SKUType || (exports.SKUType = SKUType = {}));
/**
* https://discord.com/developers/docs/resources/subscription#subscription-statuses
*/
var SubscriptionStatus;
(function (SubscriptionStatus) {
/**
* Subscription is active and scheduled to renew.
*/
SubscriptionStatus[SubscriptionStatus["Active"] = 0] = "Active";
/**
* Subscription is active but will not renew.
*/
SubscriptionStatus[SubscriptionStatus["Ending"] = 1] = "Ending";
/**
* Subscription is inactive and not being charged.
*/
SubscriptionStatus[SubscriptionStatus["Inactive"] = 2] = "Inactive";
})(SubscriptionStatus || (exports.SubscriptionStatus = SubscriptionStatus = {}));
//# sourceMappingURL=monetization.js.map

@@ -270,2 +270,3 @@ /**

export declare enum ConnectionService {
AmazonMusic = "amazon-music",
BattleNet = "battlenet",

@@ -272,0 +273,0 @@ BungieNet = "bungie",

@@ -130,2 +130,3 @@ "use strict";

(function (ConnectionService) {
ConnectionService["AmazonMusic"] = "amazon-music";
ConnectionService["BattleNet"] = "battlenet";

@@ -132,0 +133,0 @@ ConnectionService["BungieNet"] = "bungie";

@@ -664,2 +664,12 @@ import type { Snowflake } from '../../globals';

applicationEmoji(applicationId: Snowflake, emojiId: Snowflake): `/applications/${string}/emojis/${string}`;
/**
* Route for:
* - GET `/skus/{sku.id}/subscriptions`
*/
skuSubscriptions(skuId: Snowflake): `/skus/${string}/subscriptions`;
/**
* Route for:
* - GET `/skus/{sku.id}/subscriptions/${subscription.id}`
*/
skuSubscription(skuId: Snowflake, subscriptionId: Snowflake): `/skus/${string}/subscriptions/${string}`;
};

@@ -666,0 +676,0 @@ export declare const StickerPackApplicationId = "710982414301790216";

@@ -902,2 +902,16 @@ "use strict";

},
/**
* Route for:
* - GET `/skus/{sku.id}/subscriptions`
*/
skuSubscriptions(skuId) {
return `/skus/${skuId}/subscriptions`;
},
/**
* Route for:
* - GET `/skus/{sku.id}/subscriptions/${subscription.id}`
*/
skuSubscription(skuId, subscriptionId) {
return `/skus/${skuId}/subscriptions/${subscriptionId}`;
},
};

@@ -904,0 +918,0 @@ exports.StickerPackApplicationId = '710982414301790216';

import type { Snowflake } from '../../globals';
import type { APIEntitlement, APISKU } from '../../v10';
import type { APIEntitlement, APISKU, APISubscription } from '../../v10';
/**
* https://discord.com/developers/docs/monetization/entitlements#list-entitlements
* https://discord.com/developers/docs/resources/entitlement#list-entitlements
*/

@@ -40,7 +40,7 @@ export interface RESTGetAPIEntitlementsQuery {

/**
* https://discord.com/developers/docs/monetization/entitlements#list-entitlements
* https://discord.com/developers/docs/resources/entitlement#list-entitlements
*/
export type RESTGetAPIEntitlementsResult = APIEntitlement[];
/**
* https://discord.com/developers/docs/monetization/entitlements#create-test-entitlement
* https://discord.com/developers/docs/resources/entitlement#create-test-entitlement
*/

@@ -66,7 +66,7 @@ export interface RESTPostAPIEntitlementJSONBody {

/**
* https://discord.com/developers/docs/monetization/entitlements#create-test-entitlement
* https://discord.com/developers/docs/resources/entitlement#create-test-entitlement
*/
export type RESTPostAPIEntitlementResult = Partial<Omit<APIEntitlement, 'ends_at' | 'starts_at'>>;
/**
* https://discord.com/developers/docs/monetization/entitlements#create-test-entitlement
* https://discord.com/developers/docs/resources/entitlement#create-test-entitlement
*/

@@ -78,13 +78,44 @@ export declare enum EntitlementOwnerType {

/**
* https://discord.com/developers/docs/monetization/entitlements#delete-test-entitlement
* https://discord.com/developers/docs/resources/entitlement#delete-test-entitlement
*/
export type RESTDeleteAPIEntitlementResult = never;
/**
* https://discord.com/developers/docs/monetization/skus#list-skus
* https://discord.com/developers/docs/resources/sku#list-skus
*/
export type RESTGetAPISKUsResult = APISKU[];
/**
* https://discord.com/developers/docs/monetization/entitlements#consume-an-entitlement
* https://discord.com/developers/docs/resources/entitlement#consume-an-entitlement
*/
export type RESTPostAPIEntitlementConsumeResult = never;
/**
* https://discord.com/developers/docs/resources/subscription#query-string-params
*/
export interface RESTGetAPISKUSubscriptionsQuery {
/**
* List subscriptions before this ID
*/
before?: Snowflake | undefined;
/**
* List subscriptions after this ID
*/
after?: Snowflake | undefined;
/**
* Number of subscriptions to return (1-100)
*
* @default 50
*/
limit?: number | undefined;
/**
* User ID for which to return subscriptions. Required except for OAuth queries.
*/
user_id?: Snowflake | undefined;
}
/**
* https://discord.com/developers/docs/resources/subscription#list-sku-subscriptions
*/
export type RESTGetAPISKUSubscriptionsResult = APISubscription[];
/**
* https://discord.com/developers/docs/resources/subscription#get-sku-subscription
*/
export type RESTGetAPISKUSubscriptionResult = APISubscription;
//# sourceMappingURL=monetization.d.ts.map

@@ -5,3 +5,3 @@ "use strict";

/**
* https://discord.com/developers/docs/monetization/entitlements#create-test-entitlement
* https://discord.com/developers/docs/resources/entitlement#create-test-entitlement
*/

@@ -8,0 +8,0 @@ var EntitlementOwnerType;

@@ -666,2 +666,12 @@ import type { Snowflake } from '../../globals';

applicationEmoji(applicationId: Snowflake, emojiId: Snowflake): `/applications/${string}/emojis/${string}`;
/**
* Route for:
* - GET `/skus/{sku.id}/subscriptions`
*/
skuSubscriptions(skuId: Snowflake): `/skus/${string}/subscriptions`;
/**
* Route for:
* - GET `/skus/{sku.id}/subscriptions/${subscription.id}`
*/
skuSubscription(skuId: Snowflake, subscriptionId: Snowflake): `/skus/${string}/subscriptions/${string}`;
};

@@ -668,0 +678,0 @@ export declare const StickerPackApplicationId = "710982414301790216";

@@ -909,2 +909,16 @@ "use strict";

},
/**
* Route for:
* - GET `/skus/{sku.id}/subscriptions`
*/
skuSubscriptions(skuId) {
return `/skus/${skuId}/subscriptions`;
},
/**
* Route for:
* - GET `/skus/{sku.id}/subscriptions/${subscription.id}`
*/
skuSubscription(skuId, subscriptionId) {
return `/skus/${skuId}/subscriptions/${subscriptionId}`;
},
};

@@ -911,0 +925,0 @@ exports.StickerPackApplicationId = '710982414301790216';

import type { Snowflake } from '../../globals';
import type { APIEntitlement, APISKU } from '../../v10';
import type { APIEntitlement, APISKU, APISubscription } from '../../v9';
/**
* https://discord.com/developers/docs/monetization/entitlements#list-entitlements
* https://discord.com/developers/docs/resources/entitlement#list-entitlements
*/

@@ -40,7 +40,7 @@ export interface RESTGetAPIEntitlementsQuery {

/**
* https://discord.com/developers/docs/monetization/entitlements#list-entitlements
* https://discord.com/developers/docs/resources/entitlement#list-entitlements
*/
export type RESTGetAPIEntitlementsResult = APIEntitlement[];
/**
* https://discord.com/developers/docs/monetization/entitlements#create-test-entitlement
* https://discord.com/developers/docs/resources/entitlement#create-test-entitlement
*/

@@ -66,7 +66,7 @@ export interface RESTPostAPIEntitlementJSONBody {

/**
* https://discord.com/developers/docs/monetization/entitlements#create-test-entitlement
* https://discord.com/developers/docs/resources/entitlement#create-test-entitlement
*/
export type RESTPostAPIEntitlementResult = Partial<Omit<APIEntitlement, 'ends_at' | 'starts_at'>>;
/**
* https://discord.com/developers/docs/monetization/entitlements#create-test-entitlement
* https://discord.com/developers/docs/resources/entitlement#create-test-entitlement
*/

@@ -78,13 +78,44 @@ export declare enum EntitlementOwnerType {

/**
* https://discord.com/developers/docs/monetization/entitlements#delete-test-entitlement
* https://discord.com/developers/docs/resources/entitlement#delete-test-entitlement
*/
export type RESTDeleteAPIEntitlementResult = never;
/**
* https://discord.com/developers/docs/monetization/skus#list-skus
* https://discord.com/developers/docs/resources/sku#list-skus
*/
export type RESTGetAPISKUsResult = APISKU[];
/**
* https://discord.com/developers/docs/monetization/entitlements#consume-an-entitlement
* https://discord.com/developers/docs/resources/entitlement#consume-an-entitlement
*/
export type RESTPostAPIEntitlementConsumeResult = never;
/**
* https://discord.com/developers/docs/resources/subscription#query-string-params
*/
export interface RESTGetAPISKUSubscriptionsQuery {
/**
* List subscriptions before this ID
*/
before?: Snowflake | undefined;
/**
* List subscriptions after this ID
*/
after?: Snowflake | undefined;
/**
* Number of subscriptions to return (1-100)
*
* @default 50
*/
limit?: number | undefined;
/**
* User ID for which to return subscriptions. Required except for OAuth queries.
*/
user_id?: Snowflake | undefined;
}
/**
* https://discord.com/developers/docs/resources/subscription#list-sku-subscriptions
*/
export type RESTGetAPISKUSubscriptionsResult = APISubscription[];
/**
* https://discord.com/developers/docs/resources/subscription#get-sku-subscription
*/
export type RESTGetAPISKUSubscriptionResult = APISubscription;
//# sourceMappingURL=monetization.d.ts.map

@@ -5,3 +5,3 @@ "use strict";

/**
* https://discord.com/developers/docs/monetization/entitlements#create-test-entitlement
* https://discord.com/developers/docs/resources/entitlement#create-test-entitlement
*/

@@ -8,0 +8,0 @@ var EntitlementOwnerType;

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc