mirror of
https://github.com/tiramisulabs/seyfert.git
synced 2025-07-02 04:56:07 +00:00
update api handler
This commit is contained in:
parent
4a95cc962f
commit
c97eb19869
@ -27,6 +27,8 @@ export class ApiHandler {
|
||||
|
||||
constructor(options: ApiHandlerOptions) {
|
||||
this.options = {
|
||||
baseUrl: 'api/v10',
|
||||
domain: 'https://discord.com',
|
||||
...options,
|
||||
userAgent: DefaultUserAgent,
|
||||
};
|
||||
|
@ -1,18 +1,20 @@
|
||||
import type { MakeRequired } from '../common';
|
||||
|
||||
export * from './api';
|
||||
export * from './utils/constants';
|
||||
export * from './utils/types';
|
||||
export { calculateUserDefaultAvatarIndex } from './utils/utils';
|
||||
|
||||
export interface ApiHandlerOptions {
|
||||
baseUrl: string;
|
||||
domain: string;
|
||||
baseUrl?: string;
|
||||
domain?: string;
|
||||
token: string;
|
||||
debug?: boolean;
|
||||
agent?: string;
|
||||
smartBucket?: boolean;
|
||||
}
|
||||
|
||||
export interface ApiHandlerInternalOptions extends ApiHandlerOptions {
|
||||
export interface ApiHandlerInternalOptions extends MakeRequired<ApiHandlerOptions, 'baseUrl' | 'domain'> {
|
||||
userAgent: string;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user