digiwin_dsp 0.4.0 → 0.4.2

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8b74fbc1739d80f99a563f002be9ab06212eb0ffce531ddf9144c9c8ceb28b34
4
- data.tar.gz: 363e1faecee60d9a4c8f5cfe03b00bf2febd35f015f0034451e1c9c9e191308a
3
+ metadata.gz: 7ea76bd5a8bb2c25914e0f9bd6c40ff1fdf5ac6c6c0e83b6652b9a4c20f26a33
4
+ data.tar.gz: bca70e0fd5ba6f33831f2aaf4cf61aa29987a241d958dadd20539a34490bbf53
5
5
  SHA512:
6
- metadata.gz: b14060dbe2c6d65890ffb925c1ee9f499a7870db0c4eb301646eaf0ea2907869e0e331d8ff14b76e1a6bd474a2de5bf75f97d9bdf5073d856a5c55b6753dd225
7
- data.tar.gz: 1f1f7ab22cd0e077e455ce7cc6451442e5285ccf7e1c94a1abcb0c6e284e3fc86f94cf879170b4ddd2cc3d747ca532ba64a6082bf89be972aacadef23df33e7c
6
+ metadata.gz: dc0e854bc169fda091248b0048c9cf79ab0cad639b0cd431dfce867d3f9eaeaab737bad0f8103975bf9311efe99cd737b9bb05d65019cabfcb27ac8d77d1da7f
7
+ data.tar.gz: 619d56aa98ec48df0055bad21448618a244b8e29623429a07adaa8ca236229d7501ade6f978c69d7df3a495de1d5be6b5d6951e25f3ba050a18a9f6c4826176e
data/CHANGELOG.md CHANGED
@@ -6,6 +6,19 @@ The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and
6
6
 
7
7
  ## [Unreleased]
8
8
 
9
+ ## [0.4.2] - 2026-06-18
10
+
11
+ ### Added
12
+
13
+ - **`Enums::TaxType`** — `TAXABLE` (`"1"` 應稅) / `TAX_FREE` (`"2"` 免稅), with a frozen `ALL`. The enum is documented only on the order endpoint (DSPOOFFICIAL001); the `tax_type` field on the return/invoice endpoints is assumed to share these values but isn't enumerated in their specs. `docs/dsp-api-spec.md` gains the matching table.
14
+ - **`Enums::ShippingType::FACE_TO_FACE_PICKUP`** (`"9109"` 面交自取) — synced from DSPOOFFICIAL001 rev 5 (2026/06/18), which newly documented this code alongside the pay_type 9115–9130 codes already shipped in 0.4.1. `ShippingType::ALL` grows from 9 to 10 entries; the spec mirror and `docs/dsp-api-spec.md` are updated.
15
+
16
+ ## [0.4.1] - 2026-06-13
17
+
18
+ ### Added
19
+
20
+ - **`pay_type` codes 9115–9130** (16 new payment methods) synced from the updated DSPOOFFICIAL001 spec into `Enums::PayType`, `docs/dsp-api-spec.md`, and `docs/dsp-specs/DSPOOFFICIAL001.yaml`: POS結帳, Zingala 零卡分期, 現金, 悠遊卡, 一卡通, 愛金卡, 台灣 Pay, Pi 錢包, 歐付寶, 微信, 全支付, iCashPay, 全盈支付, 支付寶, 台新 Pay, 貨到信用卡一次付款. `Enums::PayType::ALL` now has 31 entries.
21
+
9
22
  ## [0.4.0] - 2026-06-12
10
23
 
11
24
  Ergonomics + cleanup release. One breaking change (dead config removal).
@@ -251,7 +264,9 @@ Initial release. Covers the four Self-hosted Website Module (自有官網模組)
251
264
  - The gem is **synchronous on purpose**. Callers wrap requests in their own background job runner (e.g. ActiveJob) when needed.
252
265
  - Idempotency: clients can send `X-Idempotency-Key` via the `idempotency_key:` kwarg. DSP also dedupes server-side by `form_no + platform_id`.
253
266
 
254
- [Unreleased]: https://github.com/7a6163/digiwin_dsp/compare/v0.4.0...HEAD
267
+ [Unreleased]: https://github.com/7a6163/digiwin_dsp/compare/v0.4.2...HEAD
268
+ [0.4.2]: https://github.com/7a6163/digiwin_dsp/compare/v0.4.1...v0.4.2
269
+ [0.4.1]: https://github.com/7a6163/digiwin_dsp/compare/v0.4.0...v0.4.1
255
270
  [0.4.0]: https://github.com/7a6163/digiwin_dsp/compare/v0.3.1...v0.4.0
256
271
  [0.3.1]: https://github.com/7a6163/digiwin_dsp/compare/v0.3.0...v0.3.1
257
272
  [0.3.0]: https://github.com/7a6163/digiwin_dsp/compare/v0.2.4...v0.3.0
@@ -20,7 +20,7 @@ module DigiwinDsp
20
20
  ALL = [CANCEL, NEW_ORDER, INVOICE, RETURN].freeze
21
21
  end
22
22
 
23
- # request_detail.pay_type on Resources::Order (DSPOOFFICIAL001:163-179).
23
+ # request_detail.pay_type on Resources::Order (DSPOOFFICIAL001:163-195).
24
24
  module PayType
25
25
  OTHER = "9100" # 其他收款方式
26
26
  JKO_PAY = "9101" # 街口支付
@@ -32,32 +32,64 @@ module DigiwinDsp
32
32
  APPLE_PAY = "9107"
33
33
  ATM = "9108" # ATM 付款
34
34
  CREDIT_CARD_INSTALLMENT = "9109" # 信用卡分期付款
35
- EASY_WALLET = "9110" # 悠遊付
35
+ EASY_WALLET = "9110" # 悠遊付 (EasyWallet app — distinct from 9118 悠遊卡)
36
36
  LINE_PAY = "9111"
37
37
  PAYPAL_EXPRESS = "9112"
38
38
  FREE_CHECKOUT = "9113" # 免費結帳
39
39
  CVS_PAYMENT_CODE = "9114" # 超商代碼繳費
40
+ POS_CHECKOUT = "9115" # POS結帳
41
+ ZINGALA = "9116" # Zingala 零卡分期付款
42
+ CASH = "9117" # 現金
43
+ EASYCARD = "9118" # 悠遊卡 (physical EasyCard)
44
+ IPASS = "9119" # 一卡通
45
+ ICASH_CARD = "9120" # 愛金卡
46
+ TAIWAN_PAY = "9121" # 台灣 Pay
47
+ PI_WALLET = "9122" # Pi 錢包
48
+ OPAY = "9123" # 歐付寶
49
+ WECHAT_PAY = "9124" # 微信
50
+ PX_PAY = "9125" # 全支付
51
+ ICASH_PAY = "9126" # iCashPay
52
+ PLUS_PAY = "9127" # 全盈支付
53
+ ALIPAY = "9128" # 支付寶
54
+ TAISHIN_PAY = "9129" # 台新 Pay
55
+ COD_CREDIT_CARD = "9130" # 貨到信用卡一次付款
40
56
 
41
57
  ALL = [OTHER, JKO_PAY, CVS_COD, GOOGLE_PAY, CREDIT_CARD, CASH_ON_DELIVERY,
42
58
  AFTEE, APPLE_PAY, ATM, CREDIT_CARD_INSTALLMENT, EASY_WALLET,
43
- LINE_PAY, PAYPAL_EXPRESS, FREE_CHECKOUT, CVS_PAYMENT_CODE].freeze
59
+ LINE_PAY, PAYPAL_EXPRESS, FREE_CHECKOUT, CVS_PAYMENT_CODE,
60
+ POS_CHECKOUT, ZINGALA, CASH, EASYCARD, IPASS, ICASH_CARD,
61
+ TAIWAN_PAY, PI_WALLET, OPAY, WECHAT_PAY, PX_PAY, ICASH_PAY,
62
+ PLUS_PAY, ALIPAY, TAISHIN_PAY, COD_CREDIT_CARD].freeze
44
63
  end
45
64
 
46
- # request_detail.shipping_type on Resources::Order (DSPOOFFICIAL001:186-200).
65
+ # request_detail.shipping_type on Resources::Order (DSPOOFFICIAL001:199-214).
47
66
  module ShippingType
48
- OTHER = "9100" # 其他取貨方式
49
- INTERNATIONAL = "9101" # 海外宅配
50
- HOME_DELIVERY_COD = "9102" # 宅配貨到付款
51
- STORE_PICKUP_PAID = "9103" # 付款後門市自取
52
- HOME_DELIVERY_PAID = "9104" # 宅配(含離島)已付款只取貨
53
- CVS_PICKUP_PAID = "9105" # 付款後超商取貨
54
- CVS_PICKUP_COD = "9106" # 超商取貨付款
55
- HOME_DELIVERY_CASH = "9107" # 宅配(含離島)貨到付現
56
- HOME_DELIVERY_CARD = "9108" # 宅配(含離島)貨到刷卡
67
+ OTHER = "9100" # 其他取貨方式
68
+ INTERNATIONAL = "9101" # 海外宅配
69
+ HOME_DELIVERY_COD = "9102" # 宅配貨到付款
70
+ STORE_PICKUP_PAID = "9103" # 付款後門市自取
71
+ HOME_DELIVERY_PAID = "9104" # 宅配(含離島)已付款只取貨
72
+ CVS_PICKUP_PAID = "9105" # 付款後超商取貨
73
+ CVS_PICKUP_COD = "9106" # 超商取貨付款
74
+ HOME_DELIVERY_CASH = "9107" # 宅配(含離島)貨到付現
75
+ HOME_DELIVERY_CARD = "9108" # 宅配(含離島)貨到刷卡
76
+ FACE_TO_FACE_PICKUP = "9109" # 面交自取 (added DSPOOFFICIAL001 rev 5, 2026/06/18)
57
77
 
58
78
  ALL = [OTHER, INTERNATIONAL, HOME_DELIVERY_COD, STORE_PICKUP_PAID,
59
79
  HOME_DELIVERY_PAID, CVS_PICKUP_PAID, CVS_PICKUP_COD,
60
- HOME_DELIVERY_CASH, HOME_DELIVERY_CARD].freeze
80
+ HOME_DELIVERY_CASH, HOME_DELIVERY_CARD, FACE_TO_FACE_PICKUP].freeze
81
+ end
82
+
83
+ # request_detail.tax_type — taxable vs tax-free. Enum is documented only
84
+ # on the order endpoint (DSPOOFFICIAL001:230); the same field on the
85
+ # return (005) and invoice (004) endpoints is described as "課稅別" with
86
+ # no enum listed, but is assumed to share these values. Field maxLength
87
+ # is 10 per spec.
88
+ module TaxType
89
+ TAXABLE = "1" # 應稅
90
+ TAX_FREE = "2" # 免稅
91
+
92
+ ALL = [TAXABLE, TAX_FREE].freeze
61
93
  end
62
94
 
63
95
  # request_detail.invoice_status on Resources::Invoice (DSPOOFFICIAL004:110-122).
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module DigiwinDsp
4
- VERSION = "0.4.0"
4
+ VERSION = "0.4.2"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: digiwin_dsp
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Zac
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2026-06-12 00:00:00.000000000 Z
11
+ date: 2026-06-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday