tmc.js 0.3.34 → 0.3.36

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 (48) hide show
  1. package/lib/message.js +3 -3
  2. package/package.json +1 -1
  3. package/types/ae.d.ts +12 -0
  4. package/types/ali.d.ts +61 -0
  5. package/types/alibaba.d.ts +2665 -189
  6. package/types/alicom.d.ts +127 -1
  7. package/types/aliexpress.d.ts +153 -11
  8. package/types/alihealth.d.ts +189 -3
  9. package/types/alihouse.d.ts +169 -0
  10. package/types/alios.d.ts +45 -0
  11. package/types/alipay.d.ts +479 -0
  12. package/types/alisports.d.ts +18 -0
  13. package/types/alitrip.d.ts +264 -16
  14. package/types/aliyun.d.ts +94 -1
  15. package/types/alsc.d.ts +329 -0
  16. package/types/ascp.d.ts +26 -1
  17. package/types/banma.d.ts +1 -1
  18. package/types/cainiao.d.ts +979 -2
  19. package/types/damai.d.ts +102 -8
  20. package/types/ele.d.ts +10 -0
  21. package/types/eleme.d.ts +71 -0
  22. package/types/fliggy.d.ts +95 -5
  23. package/types/fuwu.d.ts +2 -2
  24. package/types/gaode.d.ts +16 -0
  25. package/types/genie.d.ts +22 -0
  26. package/types/global.d.ts +22 -0
  27. package/types/gov.d.ts +160 -2
  28. package/types/icbu.d.ts +124 -0
  29. package/types/idle.d.ts +74 -16
  30. package/types/index.d.ts +3430 -14
  31. package/types/intime.d.ts +37 -0
  32. package/types/jae.d.ts +1 -1
  33. package/types/jym.d.ts +12 -0
  34. package/types/lst.d.ts +2 -2
  35. package/types/message.in.d.ts +3475 -78
  36. package/types/message.out.d.ts +1107 -26
  37. package/types/niaochao.d.ts +3 -3
  38. package/types/taobao.d.ts +3717 -239
  39. package/types/taotao.d.ts +44 -0
  40. package/types/tmall.d.ts +893 -36
  41. package/types/tobao.d.ts +26 -0
  42. package/types/trip.d.ts +6 -6
  43. package/types/umeng.d.ts +10 -0
  44. package/types/wdk.d.ts +30 -4
  45. package/types/xhotel.d.ts +16 -0
  46. package/types/xianyu.d.ts +33 -9
  47. package/types/youku.d.ts +18 -1
  48. package/types/yunos.d.ts +27 -2
package/lib/message.js CHANGED
@@ -131,13 +131,13 @@ class Encoder {
131
131
 
132
132
  if (type === 'number') {
133
133
  switch (true) {
134
- case value >= -128 && value < 128: //[-(2**7), 2**7)
134
+ case value >= -128 && value < 128: // [-(2**7), 2**7)
135
135
  return this.put(Byte).put(value);
136
136
 
137
- case value >= -32_768 && value < 32_768: //[-(2**15), 2**15)
137
+ case value >= -32_768 && value < 32_768: // [-(2**15), 2**15)
138
138
  return this.put(Int16).putShort(value);
139
139
 
140
- case value >= -2_147_483_648 && value < 2_147_483_648: //[-(2**31), 2**31)
140
+ case value >= -2_147_483_648 && value < 2_147_483_648: // [-(2**31), 2**31)
141
141
  return this.put(Int32).putInt(value);
142
142
 
143
143
  default:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tmc.js",
3
- "version": "0.3.34",
3
+ "version": "0.3.36",
4
4
  "description": "Event driven and chained Taobao Message Channel(TMC) for NodeJS",
5
5
  "author": "James ZHANG",
6
6
  "license": "MIT",
package/types/ae.d.ts ADDED
@@ -0,0 +1,12 @@
1
+ /** AE */
2
+ declare namespace Ae.Logistics {
3
+ /** {@link https://open.taobao.com/tmc.htm?docId=2209&docType=9 运单号修改} */
4
+ interface TrackingNoUpdate {
5
+ /** 新运单号 */
6
+ new_logistics_no: string;
7
+ /** 老运单号 */
8
+ old_logistics_no: string;
9
+ /** 商家ID */
10
+ seller_id: number;
11
+ }
12
+ }
package/types/ali.d.ts ADDED
@@ -0,0 +1,61 @@
1
+ /** 阿里金融 */
2
+ declare namespace Ali.Fin {
3
+ /** {@link https://open.taobao.com/tmc.htm?docId=2391&docType=9 阿里场景金融大延保理赔结果通知给服务商} */
4
+ interface DybClaimResult {
5
+ /** 理赔通过金额,单位分 */
6
+ claimFee?: string;
7
+ /** 理赔收单id */
8
+ claimNo: string;
9
+ /** 理赔结果,WAIT_UPDATE/FINISHED */
10
+ claimStatus: string;
11
+ /** 退回原因 */
12
+ reason?: string;
13
+ }
14
+ }
15
+
16
+ /** 网上法庭 */
17
+ declare namespace Ali.Infodept {
18
+ /** {@link https://open.taobao.com/tmc.htm?docId=867&docType=9 网上法庭数据交换消息} */
19
+ interface CaseFilingInfo {
20
+ /** 附件url列表 */
21
+ attachment_files?: string;
22
+ /** 附件url */
23
+ attachment_url?: string;
24
+ /** 加密后案件id */
25
+ biz_id: string;
26
+ /** messageBody格式 */
27
+ format: string;
28
+ /** 消息体 */
29
+ message_body: string;
30
+ /** 签名 */
31
+ message_body_signature?: string;
32
+ /** 消息唯一的id */
33
+ message_id: string;
34
+ /** 消息路由 */
35
+ message_router: string;
36
+ /** 消息唯一标示符 */
37
+ peer_id: string;
38
+ /** biz_id对应 */
39
+ ref_biz_id?: string;
40
+ /** 消息类型 */
41
+ topic: string;
42
+ /** 版本,消息去向 */
43
+ version?: string;
44
+ }
45
+
46
+ /** {@link https://open.taobao.com/tmc.htm?docId=833&docType=9 证件保全通知} */
47
+ interface PreserveEvidence {
48
+ /** 案件Id */
49
+ case_id?: string;
50
+ }
51
+
52
+ /** {@link https://open.taobao.com/tmc.htm?docId=943&docType=9 网上法庭开放平台消息} */
53
+ interface YuncourtMsg {
54
+ /** 业务id */
55
+ biz_id: string;
56
+ /** 消息内容 */
57
+ content: string;
58
+ /** 消息类型 */
59
+ type: string;
60
+ }
61
+ }