@satorijs/adapter-dingtalk 1.0.0

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.
Files changed (53) hide show
  1. package/lib/api/alitrip.d.ts +396 -0
  2. package/lib/api/attendance.d.ts +62 -0
  3. package/lib/api/badge.d.ts +232 -0
  4. package/lib/api/blackboard.d.ts +16 -0
  5. package/lib/api/calendar.d.ts +620 -0
  6. package/lib/api/card.d.ts +184 -0
  7. package/lib/api/conference.d.ts +403 -0
  8. package/lib/api/connector.d.ts +78 -0
  9. package/lib/api/contact.d.ts +39 -0
  10. package/lib/api/convFile.d.ts +134 -0
  11. package/lib/api/crm.d.ts +661 -0
  12. package/lib/api/customerService.d.ts +127 -0
  13. package/lib/api/datacenter.d.ts +505 -0
  14. package/lib/api/devicemng.d.ts +160 -0
  15. package/lib/api/diot.d.ts +12 -0
  16. package/lib/api/doc.d.ts +140 -0
  17. package/lib/api/drive.d.ts +87 -0
  18. package/lib/api/edu.d.ts +22 -0
  19. package/lib/api/esign.d.ts +33 -0
  20. package/lib/api/exclusive.d.ts +303 -0
  21. package/lib/api/h3yun.d.ts +437 -0
  22. package/lib/api/hrm.d.ts +214 -0
  23. package/lib/api/im.d.ts +772 -0
  24. package/lib/api/industry.d.ts +117 -0
  25. package/lib/api/jzcrm.d.ts +254 -0
  26. package/lib/api/link.d.ts +72 -0
  27. package/lib/api/live.d.ts +131 -0
  28. package/lib/api/microApp.d.ts +239 -0
  29. package/lib/api/oapi.d.ts +3361 -0
  30. package/lib/api/oauth2.d.ts +114 -0
  31. package/lib/api/pedia.d.ts +185 -0
  32. package/lib/api/project.d.ts +1118 -0
  33. package/lib/api/resident.d.ts +106 -0
  34. package/lib/api/robot.d.ts +255 -0
  35. package/lib/api/rooms.d.ts +255 -0
  36. package/lib/api/serviceGroup.d.ts +175 -0
  37. package/lib/api/storage.d.ts +1240 -0
  38. package/lib/api/swform.d.ts +70 -0
  39. package/lib/api/todo.d.ts +168 -0
  40. package/lib/api/wiki.d.ts +194 -0
  41. package/lib/api/workbench.d.ts +45 -0
  42. package/lib/api/yida.d.ts +1837 -0
  43. package/lib/bot.d.ts +30 -0
  44. package/lib/http.d.ts +7 -0
  45. package/lib/index.d.ts +7 -0
  46. package/lib/index.js +1814 -0
  47. package/lib/index.js.map +7 -0
  48. package/lib/internal.d.ts +7 -0
  49. package/lib/message.d.ts +17 -0
  50. package/lib/types/index.d.ts +133 -0
  51. package/lib/utils.d.ts +4 -0
  52. package/lib/ws.d.ts +12 -0
  53. package/package.json +31 -0
package/lib/bot.d.ts ADDED
@@ -0,0 +1,30 @@
1
+ /// <reference types="node" />
2
+ import { Bot, Context, Quester, Schema } from '@satorijs/satori';
3
+ import { DingtalkMessageEncoder } from './message';
4
+ import { WsClient } from './ws';
5
+ import { Internal } from './internal';
6
+ export declare class DingtalkBot extends Bot<DingtalkBot.Config> {
7
+ static MessageEncoder: typeof DingtalkMessageEncoder;
8
+ oldHttp: Quester;
9
+ http: Quester;
10
+ refreshTokenTimer: NodeJS.Timeout;
11
+ internal: Internal;
12
+ constructor(ctx: Context, config: DingtalkBot.Config);
13
+ initialize(): Promise<void>;
14
+ stop(): Promise<void>;
15
+ token: string;
16
+ refreshToken(): Promise<void>;
17
+ downloadFile(downloadCode: string): Promise<string>;
18
+ deleteMessage(channelId: string, messageId: string): Promise<void>;
19
+ }
20
+ export declare namespace DingtalkBot {
21
+ interface Config extends Bot.Config, WsClient.Config {
22
+ secret: string;
23
+ protocol: string;
24
+ appkey: string;
25
+ agentId: number;
26
+ api: Quester.Config;
27
+ oldApi: Quester.Config;
28
+ }
29
+ const Config: Schema<Config>;
30
+ }
package/lib/http.d.ts ADDED
@@ -0,0 +1,7 @@
1
+ import { Adapter, Context, Logger } from '@satorijs/satori';
2
+ import { DingtalkBot } from './bot';
3
+ export declare class HttpServer extends Adapter.Server<DingtalkBot> {
4
+ logger: Logger;
5
+ constructor(ctx: Context, bot: DingtalkBot);
6
+ start(bot: DingtalkBot): Promise<void>;
7
+ }
package/lib/index.d.ts ADDED
@@ -0,0 +1,7 @@
1
+ import { DingtalkBot } from './bot';
2
+ export * from './bot';
3
+ export * from './utils';
4
+ export * from './types';
5
+ export * from './http';
6
+ export * from './message';
7
+ export default DingtalkBot;