discord-slim
Advanced tools
Comparing version 2.6.7 to 2.6.8
@@ -301,3 +301,3 @@ import { RequestOptions } from '../request'; | ||
export declare const DeleteWithToken: (webhook_id: string, webhook_token: string, requestOptions?: RequestOptions | undefined) => Promise<null>; | ||
export declare const Execute: (webhook_id: string, webhook_token: string, params1: { | ||
export declare const Execute: <T extends boolean>(webhook_id: string, webhook_token: string, params1: { | ||
content?: string; | ||
@@ -312,5 +312,5 @@ username?: string; | ||
}, params2?: { | ||
wait?: boolean | undefined; | ||
wait?: T | undefined; | ||
thread_id?: string | undefined; | ||
} | undefined, requestOptions?: RequestOptions | undefined) => Promise<types.Message | null>; | ||
} | undefined, requestOptions?: RequestOptions | undefined) => Promise<T extends true ? types.Message : null>; | ||
export declare const ExecuteSlack: (webhook_id: string, webhook_token: string, params?: { | ||
@@ -317,0 +317,0 @@ thread_id?: string | undefined; |
/// <reference types="node" /> | ||
import { EventEmitter } from 'events'; | ||
import { Intents, ActivityTypes, StatusTypes } from './helpers'; | ||
import { Authorization } from './request'; | ||
import { Authorization } from './authorization'; | ||
import { Events, EventTypes, EventHandler } from './events'; | ||
import type { User } from './types'; | ||
declare type Session = { | ||
id: string; | ||
seq: number; | ||
}; | ||
declare type DispatchPacket<E extends Events> = { | ||
@@ -13,12 +17,11 @@ t: E; | ||
export declare class Client extends EventEmitter { | ||
private _sessionId?; | ||
private _lastSequence; | ||
private _lastHeartbeatAck; | ||
private _heartbeatTimer?; | ||
private _ws?; | ||
private _authorization?; | ||
private _intents?; | ||
private _eventHandler; | ||
private _user?; | ||
private _shard?; | ||
private _eventHandler; | ||
private _heartbeatTimer?; | ||
private _lastHeartbeatAck; | ||
private _session?; | ||
private _props?; | ||
@@ -41,2 +44,3 @@ constructor(); | ||
} | undefined) => void; | ||
Resume: (authorization: Authorization, session: Session) => void; | ||
Disconnect: (code?: number | undefined) => void; | ||
@@ -73,2 +77,3 @@ RequestGuildMembers: (params: { | ||
set props(value: object | null | undefined); | ||
get session(): Session | undefined; | ||
} | ||
@@ -75,0 +80,0 @@ export declare enum ClientEvents { |
@@ -65,6 +65,3 @@ /// <reference types="node" /> | ||
shard?: [shard_id: number, num_shards: number]; | ||
application: { | ||
id: string; | ||
flags: number; | ||
}; | ||
application: Required<Pick<types.Application, ('id' | 'flags')>>; | ||
}; | ||
@@ -71,0 +68,0 @@ [Events.RESUMED]: {}; |
export { Client, ClientEvents } from './client'; | ||
export { Authorization } from './request'; | ||
export { Authorization } from './authorization'; | ||
export { Events } from './events'; | ||
@@ -4,0 +4,0 @@ export * as Actions from './actions'; |
@@ -1,15 +0,2 @@ | ||
import { TokenTypes } from './helpers'; | ||
export declare class Authorization { | ||
private _type; | ||
private _token; | ||
private _cache; | ||
constructor(token: string, type?: TokenTypes); | ||
private _update; | ||
get type(): TokenTypes; | ||
set type(value: TokenTypes); | ||
get token(): string; | ||
set token(value: string); | ||
get value(): string; | ||
toString: () => string; | ||
} | ||
import { Authorization } from './authorization'; | ||
export declare type RateLimitResponse = { | ||
@@ -16,0 +3,0 @@ message: string; |
{ | ||
"name": "discord-slim", | ||
"version": "2.6.7", | ||
"version": "2.6.8", | ||
"description": "Lightweight Discord API library for Node.js.", | ||
@@ -5,0 +5,0 @@ "author": "Hanabishi", |
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
219665
38
4909