@ccw-api/api 0.11.0 → 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 (117) hide show
  1. package/LICENSE +9 -0
  2. package/README.md +58 -10
  3. package/dist/account-_e06LVHE.d.cts +6 -0
  4. package/dist/account-_e06LVHE.d.ts +6 -0
  5. package/dist/{api-eD9o12yg.d.cts → api-DK7ohLa7.d.cts} +9 -18
  6. package/dist/{api-eD9o12yg.d.ts → api-DK7ohLa7.d.ts} +9 -18
  7. package/dist/bfs-web-BtWTiGvL.cjs +1 -0
  8. package/dist/bfs-web-xFSpR-s6.js +1 -0
  9. package/dist/bfs.cjs +1 -0
  10. package/dist/bfs.d.cts +2 -0
  11. package/dist/bfs.d.ts +2 -0
  12. package/dist/bfs.js +1 -0
  13. package/dist/community-web-B7SGi5-y.cjs +1 -0
  14. package/dist/community-web-Dzl0mbbh.js +1 -0
  15. package/dist/community-web-cloud-database-BkH9wp1u.cjs +1 -0
  16. package/dist/community-web-cloud-database-D9IZZIjN.js +1 -0
  17. package/dist/communityWeb.cjs +1 -0
  18. package/dist/communityWeb.d.cts +2 -0
  19. package/dist/communityWeb.d.ts +2 -0
  20. package/dist/communityWeb.js +1 -0
  21. package/dist/communityWebDB.cjs +1 -0
  22. package/dist/communityWebDB.d.cts +2 -0
  23. package/dist/communityWebDB.d.ts +2 -0
  24. package/dist/communityWebDB.js +1 -0
  25. package/dist/extensions-BhEKLZ5I.d.cts +617 -0
  26. package/dist/extensions-D1JeVkuw.d.ts +617 -0
  27. package/dist/gandi-main-Bdq3vj-l.js +1 -0
  28. package/dist/gandi-main-CVC31Jom.cjs +1 -0
  29. package/dist/gandiMain.cjs +1 -0
  30. package/dist/gandiMain.d.cts +2 -0
  31. package/dist/gandiMain.d.ts +2 -0
  32. package/dist/gandiMain.js +1 -0
  33. package/dist/index-B8SvUvok.d.ts +112 -0
  34. package/dist/{index-DHBvF_JC.d.ts → index-BVdJi7l7.d.ts} +12 -10
  35. package/dist/{index-Df4POgQq.d.ts → index-CDuyecw5.d.ts} +12 -10
  36. package/dist/index-CV03H74N.d.cts +2351 -0
  37. package/dist/index-CobjrinB.d.ts +2351 -0
  38. package/dist/index-CwWMFbgH.d.cts +112 -0
  39. package/dist/{index-BE998Kka.d.cts → index-DCDRwVC2.d.cts} +79 -74
  40. package/dist/{index-BDpiLiUN.d.ts → index-DXMyzE0v.d.ts} +79 -74
  41. package/dist/{index-DBnhnINQ.d.cts → index-IcG5LsGk.d.cts} +12 -10
  42. package/dist/{index-CTK9UFeW.d.cts → index-JnYvwWhY.d.cts} +33 -30
  43. package/dist/{index-CTK9UFeW.d.ts → index-JnYvwWhY.d.ts} +33 -30
  44. package/dist/{index-DcBdyIv0.d.cts → index-sOyHrix1.d.cts} +12 -10
  45. package/dist/index.cjs +1 -2
  46. package/dist/index.d.cts +167 -164
  47. package/dist/index.d.ts +167 -164
  48. package/dist/index.js +1 -2
  49. package/dist/op-parent-api-BC6-0rS8.js +1 -0
  50. package/dist/op-parent-api-BZbZzfJ6.cjs +1 -0
  51. package/dist/opParent.cjs +1 -0
  52. package/dist/opParent.d.cts +2 -0
  53. package/dist/opParent.d.ts +2 -0
  54. package/dist/opParent.js +1 -0
  55. package/dist/pages-K5jlky49.d.cts +42 -0
  56. package/dist/pages-K5jlky49.d.ts +42 -0
  57. package/dist/queryPages-CfywLB4S.cjs +1 -0
  58. package/dist/queryPages-Cj4eQL4Q.js +1 -0
  59. package/dist/request-CIq4GGVU.cjs +1 -0
  60. package/dist/request-CzgJtv9u.js +1 -0
  61. package/dist/session-Cw37kR-m.d.ts +43 -0
  62. package/dist/session-D8sffvmq.d.cts +43 -0
  63. package/dist/sso-C0ZWQvKo.cjs +1 -0
  64. package/dist/sso-DUoym0qZ.js +1 -0
  65. package/dist/sso.cjs +1 -0
  66. package/dist/sso.d.cts +2 -0
  67. package/dist/sso.d.ts +2 -0
  68. package/dist/sso.js +1 -0
  69. package/package.json +9 -9
  70. package/dist/account-Dk_iscrW.d.cts +0 -8
  71. package/dist/account-Dk_iscrW.d.ts +0 -8
  72. package/dist/bfs-web/index.cjs +0 -2
  73. package/dist/bfs-web/index.d.cts +0 -5
  74. package/dist/bfs-web/index.d.ts +0 -5
  75. package/dist/bfs-web/index.global.js +0 -29
  76. package/dist/bfs-web/index.js +0 -2
  77. package/dist/community-web/index.cjs +0 -2
  78. package/dist/community-web/index.d.cts +0 -6
  79. package/dist/community-web/index.d.ts +0 -6
  80. package/dist/community-web/index.global.js +0 -29
  81. package/dist/community-web/index.js +0 -2
  82. package/dist/community-web-cloud-database/index.cjs +0 -2
  83. package/dist/community-web-cloud-database/index.d.cts +0 -2
  84. package/dist/community-web-cloud-database/index.d.ts +0 -2
  85. package/dist/community-web-cloud-database/index.global.js +0 -29
  86. package/dist/community-web-cloud-database/index.js +0 -2
  87. package/dist/extensions-Bj9XMupR.d.cts +0 -662
  88. package/dist/extensions-zuu8XVBR.d.ts +0 -662
  89. package/dist/gandi-main/index.cjs +0 -2
  90. package/dist/gandi-main/index.d.cts +0 -3
  91. package/dist/gandi-main/index.d.ts +0 -3
  92. package/dist/gandi-main/index.global.js +0 -29
  93. package/dist/gandi-main/index.js +0 -2
  94. package/dist/index-BrxSkWbg.d.cts +0 -2289
  95. package/dist/index-CYQhPzUX.d.ts +0 -108
  96. package/dist/index-Ci0X9uqV.d.cts +0 -108
  97. package/dist/index-DBAUdwJo.d.ts +0 -2289
  98. package/dist/index.global.js +0 -29
  99. package/dist/op-parent-api/index.cjs +0 -2
  100. package/dist/op-parent-api/index.d.cts +0 -1
  101. package/dist/op-parent-api/index.d.ts +0 -1
  102. package/dist/op-parent-api/index.global.js +0 -29
  103. package/dist/op-parent-api/index.js +0 -2
  104. package/dist/pages-BgT6bhJd.d.cts +0 -46
  105. package/dist/pages-BgT6bhJd.d.ts +0 -46
  106. package/dist/session-Cq-kUclp.d.ts +0 -48
  107. package/dist/session-DGUV-m-G.d.cts +0 -48
  108. package/dist/setToken.cjs +0 -1
  109. package/dist/setToken.d.cts +0 -1
  110. package/dist/setToken.d.ts +0 -1
  111. package/dist/setToken.global.js +0 -29
  112. package/dist/setToken.js +0 -1
  113. package/dist/sso/index.cjs +0 -2
  114. package/dist/sso/index.d.cts +0 -4
  115. package/dist/sso/index.d.ts +0 -4
  116. package/dist/sso/index.global.js +0 -29
  117. package/dist/sso/index.js +0 -2
@@ -1,108 +0,0 @@
1
- import { P as PageArgs, a as PagesRes, S as SortType } from './pages-BgT6bhJd.js';
2
- import { M as MongoDBId, C as CNameOssUrl } from './api-eD9o12yg.js';
3
-
4
- type Res$2 = number;
5
- /**
6
- * 获取服务端当前时间戳
7
- * @returns {Promise<Res>} 当前时间戳(毫秒)
8
- */
9
- declare function getCurrentTimestamp(): Promise<Res$2>;
10
-
11
- type BulletinItem = {
12
- createdAt: number;
13
- id: number;
14
- publishedAt: number;
15
- status: "PUBLISHED";
16
- title: string;
17
- updatedAt: number;
18
- };
19
- type SortField = "publishedAt";
20
- type Res$1 = PagesRes<BulletinItem>;
21
- /**
22
- * 获取公告分页列表
23
- * @param {'PUBLISHED' | S} status 公告状态过滤
24
- * @param {Partial<PageArgs<SortField | T>>} pageArgs_ 分页参数
25
- * @returns {Promise<Res>} 公告分页列表
26
- */
27
- declare function getBulletinsPage<T extends string, S extends string>(status?: "PUBLISHED" | S, pageArgs_?: Partial<PageArgs<SortField | T>>): Promise<Res$1>;
28
-
29
- type BulletinDetail = {
30
- createdAt: number;
31
- id: number;
32
- publishedAt: number;
33
- status: "PUBLISHED";
34
- title: string;
35
- updatedAt: number;
36
- };
37
- type Res = BulletinDetail;
38
- /**
39
- * 获取公告详情
40
- * @param {number} id 公告id
41
- * @returns {Promise<Res>} 公告详情
42
- */
43
- declare function getBulletinDetail(id: number): Promise<Res>;
44
-
45
- type SubmitRes = boolean;
46
- type LeaderboardUser = {
47
- avatar: null | CNameOssUrl;
48
- id: MongoDBId;
49
- locked: null | boolean;
50
- nickname: null | string;
51
- };
52
- type LeaderboardRecord = {
53
- createdAt: number;
54
- ext: string;
55
- leaderboardOid: MongoDBId;
56
- oid: MongoDBId;
57
- ranking: number;
58
- score: number;
59
- updatedAt: number;
60
- user: LeaderboardUser;
61
- userId: MongoDBId;
62
- };
63
- type ScoreFormat = "DECIMAL_WITH_SEPARATOR" | string;
64
- type ScoreStorageRule = "BEST" | string;
65
- type StatsCycle = "ALL_DAYS" | string;
66
- type LeaderboardRecordsRes = {
67
- coverLink: null | CNameOssUrl;
68
- createdAt: number;
69
- creationId: MongoDBId;
70
- curUserLeaderboardRecord: null | LeaderboardRecord;
71
- displayLines: number;
72
- leaderboardRecordTotalNum: number;
73
- leaderboardRecords: LeaderboardRecord[];
74
- oid: MongoDBId;
75
- scoreFormat: ScoreFormat;
76
- scoreStorageRule: ScoreStorageRule;
77
- scoreUnit: string;
78
- showPersonalRanking: boolean;
79
- sortType: SortType;
80
- statsCycle: StatsCycle;
81
- title: string;
82
- updatedAt: number;
83
- };
84
- /**
85
- * 向作品排行榜提交一条分数记录
86
- * @param {MongoDBId} leaderboardOid 排行榜id
87
- * @param {number} score 分数
88
- * @param {MongoDBId} userOid 用户id
89
- * @param {string} ext 扩展信息(可选)
90
- * @returns {Promise<SubmitRes>} 是否提交成功
91
- */
92
- declare function submitLeaderboardRecord(leaderboardOid: MongoDBId, score: number, userOid: MongoDBId, ext?: string): Promise<SubmitRes>;
93
- /**
94
- * 获取作品排行榜记录列表
95
- * @param {MongoDBId} leaderboardOid 排行榜id
96
- * @returns {Promise<LeaderboardRecordsRes>} 排行榜记录列表
97
- */
98
- declare function getLeaderboardRecords(leaderboardOid: MongoDBId): Promise<LeaderboardRecordsRes>;
99
-
100
- declare const gandiMain: {
101
- getCurrentTimestamp: typeof getCurrentTimestamp;
102
- getBulletinsPage: typeof getBulletinsPage;
103
- getBulletinDetail: typeof getBulletinDetail;
104
- submitLeaderboardRecord: typeof submitLeaderboardRecord;
105
- getLeaderboardRecords: typeof getLeaderboardRecords;
106
- };
107
-
108
- export { getBulletinsPage as a, getBulletinDetail as b, getLeaderboardRecords as c, gandiMain as d, getCurrentTimestamp as g, submitLeaderboardRecord as s };
@@ -1,108 +0,0 @@
1
- import { P as PageArgs, a as PagesRes, S as SortType } from './pages-BgT6bhJd.cjs';
2
- import { M as MongoDBId, C as CNameOssUrl } from './api-eD9o12yg.cjs';
3
-
4
- type Res$2 = number;
5
- /**
6
- * 获取服务端当前时间戳
7
- * @returns {Promise<Res>} 当前时间戳(毫秒)
8
- */
9
- declare function getCurrentTimestamp(): Promise<Res$2>;
10
-
11
- type BulletinItem = {
12
- createdAt: number;
13
- id: number;
14
- publishedAt: number;
15
- status: "PUBLISHED";
16
- title: string;
17
- updatedAt: number;
18
- };
19
- type SortField = "publishedAt";
20
- type Res$1 = PagesRes<BulletinItem>;
21
- /**
22
- * 获取公告分页列表
23
- * @param {'PUBLISHED' | S} status 公告状态过滤
24
- * @param {Partial<PageArgs<SortField | T>>} pageArgs_ 分页参数
25
- * @returns {Promise<Res>} 公告分页列表
26
- */
27
- declare function getBulletinsPage<T extends string, S extends string>(status?: "PUBLISHED" | S, pageArgs_?: Partial<PageArgs<SortField | T>>): Promise<Res$1>;
28
-
29
- type BulletinDetail = {
30
- createdAt: number;
31
- id: number;
32
- publishedAt: number;
33
- status: "PUBLISHED";
34
- title: string;
35
- updatedAt: number;
36
- };
37
- type Res = BulletinDetail;
38
- /**
39
- * 获取公告详情
40
- * @param {number} id 公告id
41
- * @returns {Promise<Res>} 公告详情
42
- */
43
- declare function getBulletinDetail(id: number): Promise<Res>;
44
-
45
- type SubmitRes = boolean;
46
- type LeaderboardUser = {
47
- avatar: null | CNameOssUrl;
48
- id: MongoDBId;
49
- locked: null | boolean;
50
- nickname: null | string;
51
- };
52
- type LeaderboardRecord = {
53
- createdAt: number;
54
- ext: string;
55
- leaderboardOid: MongoDBId;
56
- oid: MongoDBId;
57
- ranking: number;
58
- score: number;
59
- updatedAt: number;
60
- user: LeaderboardUser;
61
- userId: MongoDBId;
62
- };
63
- type ScoreFormat = "DECIMAL_WITH_SEPARATOR" | string;
64
- type ScoreStorageRule = "BEST" | string;
65
- type StatsCycle = "ALL_DAYS" | string;
66
- type LeaderboardRecordsRes = {
67
- coverLink: null | CNameOssUrl;
68
- createdAt: number;
69
- creationId: MongoDBId;
70
- curUserLeaderboardRecord: null | LeaderboardRecord;
71
- displayLines: number;
72
- leaderboardRecordTotalNum: number;
73
- leaderboardRecords: LeaderboardRecord[];
74
- oid: MongoDBId;
75
- scoreFormat: ScoreFormat;
76
- scoreStorageRule: ScoreStorageRule;
77
- scoreUnit: string;
78
- showPersonalRanking: boolean;
79
- sortType: SortType;
80
- statsCycle: StatsCycle;
81
- title: string;
82
- updatedAt: number;
83
- };
84
- /**
85
- * 向作品排行榜提交一条分数记录
86
- * @param {MongoDBId} leaderboardOid 排行榜id
87
- * @param {number} score 分数
88
- * @param {MongoDBId} userOid 用户id
89
- * @param {string} ext 扩展信息(可选)
90
- * @returns {Promise<SubmitRes>} 是否提交成功
91
- */
92
- declare function submitLeaderboardRecord(leaderboardOid: MongoDBId, score: number, userOid: MongoDBId, ext?: string): Promise<SubmitRes>;
93
- /**
94
- * 获取作品排行榜记录列表
95
- * @param {MongoDBId} leaderboardOid 排行榜id
96
- * @returns {Promise<LeaderboardRecordsRes>} 排行榜记录列表
97
- */
98
- declare function getLeaderboardRecords(leaderboardOid: MongoDBId): Promise<LeaderboardRecordsRes>;
99
-
100
- declare const gandiMain: {
101
- getCurrentTimestamp: typeof getCurrentTimestamp;
102
- getBulletinsPage: typeof getBulletinsPage;
103
- getBulletinDetail: typeof getBulletinDetail;
104
- submitLeaderboardRecord: typeof submitLeaderboardRecord;
105
- getLeaderboardRecords: typeof getLeaderboardRecords;
106
- };
107
-
108
- export { getBulletinsPage as a, getBulletinDetail as b, getLeaderboardRecords as c, gandiMain as d, getCurrentTimestamp as g, submitLeaderboardRecord as s };