koishi-plugin-weibo-fetcher
Version:
一个微博内容获取与订阅的 Koishi 插件,支持链接实时解析和用户后台订阅推送。
46 lines (45 loc) • 1.14 kB
TypeScript
import { Context, Schema } from 'koishi';
export declare const name = "koishi-plugin-weibo-fetcher";
export declare const inject: {
required: string[];
};
declare module 'koishi' {
interface Tables {
weibo_subscriptions: {
uid: string;
last_post_url: string;
};
}
}
export type Config = BaseConfig & SubscriptionConfig;
interface BaseConfig {
cookie: string;
splitMessages: boolean;
showScreenshot: boolean;
sendText: boolean;
sendMedia: boolean;
useForward: boolean;
sub_showLink: boolean;
sub_showScreenshot: boolean;
sub_sendText: boolean;
sub_sendMedia: boolean;
sub_useForward: boolean;
logDetails: boolean;
}
type SubscriptionConfig = {
enableSubscription: false;
} | {
enableSubscription: true;
platform: string;
selfId: string;
updateInterval: number;
test_authority: number;
subscriptions: {
uid: string;
name: string;
channelIds: string[];
}[];
};
export declare const Config: Schema<Config>;
export declare function apply(ctx: Context, config: Config): void;
export {};