pokepay_partner_ruby_sdk 0.1.14 → 0.1.15
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 +4 -4
- data/Gemfile.lock +1 -1
- data/docs/index.md +338 -88
- data/lib/pokepay_partner_ruby_sdk/request/create_cpm_transaction.rb +17 -0
- data/lib/pokepay_partner_ruby_sdk/request/get_cpm_token.rb +15 -0
- data/lib/pokepay_partner_ruby_sdk/response/cashtray_attempt.rb +1 -1
- data/lib/pokepay_partner_ruby_sdk/response/cashtray_with_result.rb +2 -2
- data/lib/pokepay_partner_ruby_sdk/response/cpm_token.rb +26 -0
- data/lib/pokepay_partner_ruby_sdk/response/external_transaction.rb +31 -0
- data/lib/pokepay_partner_ruby_sdk/response/product.rb +21 -0
- data/lib/pokepay_partner_ruby_sdk/version.rb +1 -1
- data/lib/pokepay_partner_ruby_sdk.rb +5 -0
- data/partner.yaml +382 -6
- data/pokepay_partner_ruby_sdk.gemspec +3 -3
- metadata +11 -6
data/docs/index.md
CHANGED
@@ -142,14 +142,16 @@ response.body
|
|
142
142
|
<a name="api-operations"></a>
|
143
143
|
## API Operations
|
144
144
|
|
145
|
+
- [GetCpmToken](#get-cpm-token): CPMトークンの状態取得
|
145
146
|
- [ListTransactions](#list-transactions): 取引履歴を取得する
|
146
147
|
- [CreateTransaction](#create-transaction): チャージする(廃止予定)
|
147
148
|
- [CreateTopupTransaction](#create-topup-transaction): チャージする
|
148
149
|
- [CreatePaymentTransaction](#create-payment-transaction): 支払いする
|
150
|
+
- [CreateCpmTransaction](#create-cpm-transaction): CPMトークンによる取引作成
|
149
151
|
- [CreateTransferTransaction](#create-transfer-transaction): 個人間送金
|
150
152
|
- [CreateExchangeTransaction](#create-exchange-transaction):
|
151
153
|
- [GetTransaction](#get-transaction): 取引情報を取得する
|
152
|
-
- [RefundTransaction](#refund-transaction):
|
154
|
+
- [RefundTransaction](#refund-transaction): 取引をキャンセルする
|
153
155
|
- [ListTransfers](#list-transfers):
|
154
156
|
- [CreateTopupTransactionWithCheck](#create-topup-transaction-with-check): チャージQRコードを読み取ることでチャージする
|
155
157
|
- [ListBills](#list-bills): 支払いQRコード一覧を表示する
|
@@ -177,13 +179,35 @@ response.body
|
|
177
179
|
- [GetPrivateMoneyOrganizationSummaries](#get-private-money-organization-summaries): 決済加盟店の取引サマリを取得する
|
178
180
|
- [BulkCreateTransaction](#bulk-create-transaction): CSVファイル一括取引
|
179
181
|
### Transaction
|
182
|
+
<a name="get-cpm-token"></a>
|
183
|
+
#### CPMトークンの状態取得
|
184
|
+
CPMトークンの現在の状態を取得します。CPMトークンの有効期限やCPM取引の状態を返します。
|
185
|
+
```ruby
|
186
|
+
response = $client.send(Pokepay::Request::GetCpmToken.new(
|
187
|
+
"EKYDjBWPKCwbirzvScUvjs" # cpm_token: CPMトークン
|
188
|
+
))
|
189
|
+
```
|
190
|
+
|
191
|
+
---
|
192
|
+
`cpm_token`
|
193
|
+
```json
|
194
|
+
{
|
195
|
+
"type": "string",
|
196
|
+
"minLength": 22,
|
197
|
+
"maxLength": 22
|
198
|
+
}
|
199
|
+
```
|
200
|
+
CPM取引時にエンドユーザーが店舗に提示するバーコードを解析して得られる22桁の文字列です。
|
201
|
+
|
202
|
+
---
|
203
|
+
成功したときは[CpmToken](#cpm-token)オブジェクトを返します
|
180
204
|
<a name="list-transactions"></a>
|
181
205
|
#### 取引履歴を取得する
|
182
206
|
取引一覧を返します。
|
183
207
|
```ruby
|
184
208
|
response = $client.send(Pokepay::Request::ListTransactions.new(
|
185
|
-
from: "
|
186
|
-
to: "
|
209
|
+
from: "2023-06-11T07:51:21.000000+09:00", # 開始日時
|
210
|
+
to: "2022-06-22T01:22:59.000000+09:00", # 終了日時
|
187
211
|
page: 1, # ページ番号
|
188
212
|
per_page: 50, # 1ページ分の取引数
|
189
213
|
shop_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # 店舗ID
|
@@ -390,10 +414,10 @@ response = $client.send(Pokepay::Request::CreateTransaction.new(
|
|
390
414
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
391
415
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
392
416
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
393
|
-
money_amount:
|
394
|
-
point_amount:
|
395
|
-
point_expires_at: "
|
396
|
-
description: "
|
417
|
+
money_amount: 4169,
|
418
|
+
point_amount: 2565,
|
419
|
+
point_expires_at: "2022-07-08T13:32:38.000000+09:00", # ポイント有効期限
|
420
|
+
description: "jFPIL9qlVMwg0ANEHCj5eM805Swtsg2NkJBDvuxWoqdLq3QmHRbZpwbPRidVG7B6hajGJrCJBxTKH0YU"
|
397
421
|
))
|
398
422
|
```
|
399
423
|
|
@@ -419,10 +443,11 @@ response = $client.send(Pokepay::Request::CreateTopupTransaction.new(
|
|
419
443
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # customer_id: エンドユーザーのID
|
420
444
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
421
445
|
bear_point_shop_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # ポイント支払時の負担店舗ID
|
422
|
-
money_amount:
|
423
|
-
point_amount:
|
424
|
-
point_expires_at: "
|
446
|
+
money_amount: 6743, # マネー額
|
447
|
+
point_amount: 734, # ポイント額
|
448
|
+
point_expires_at: "2025-05-30T13:08:03.000000+09:00", # ポイント有効期限
|
425
449
|
description: "初夏のチャージキャンペーン", # 取引履歴に表示する説明文
|
450
|
+
metadata: "{\"key\":\"value\"}", # 取引メタデータ
|
426
451
|
request_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" # リクエストID
|
427
452
|
))
|
428
453
|
```
|
@@ -522,6 +547,18 @@ response = $client.send(Pokepay::Request::CreateTopupTransaction.new(
|
|
522
547
|
|
523
548
|
任意入力で、取引履歴に表示される説明文です。
|
524
549
|
|
550
|
+
---
|
551
|
+
`metadata`
|
552
|
+
```json
|
553
|
+
{
|
554
|
+
"type": "string",
|
555
|
+
"format": "json"
|
556
|
+
}
|
557
|
+
```
|
558
|
+
取引作成時に指定されるメタデータです。
|
559
|
+
|
560
|
+
任意入力で、全てのkeyとvalueが文字列であるようなフラットな構造のJSON文字列で指定します。
|
561
|
+
|
525
562
|
---
|
526
563
|
`request_id`
|
527
564
|
```json
|
@@ -548,8 +585,15 @@ response = $client.send(Pokepay::Request::CreatePaymentTransaction.new(
|
|
548
585
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # shop_id: 店舗ID
|
549
586
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # customer_id: エンドユーザーID
|
550
587
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
551
|
-
|
588
|
+
2221, # amount: 支払い額
|
552
589
|
description: "たい焼き(小倉)", # 取引履歴に表示する説明文
|
590
|
+
metadata: "{\"key\":\"value\"}", # 取引メタデータ
|
591
|
+
products: [{"jan_code":"abc",
|
592
|
+
"name":"name1",
|
593
|
+
"unit_price":100,
|
594
|
+
"price": 100,
|
595
|
+
"is_discounted": false,
|
596
|
+
"other":"{}"}], # 商品情報データ
|
553
597
|
request_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" # リクエストID
|
554
598
|
))
|
555
599
|
```
|
@@ -614,6 +658,160 @@ response = $client.send(Pokepay::Request::CreatePaymentTransaction.new(
|
|
614
658
|
|
615
659
|
任意入力で、取引履歴に表示される説明文です。
|
616
660
|
|
661
|
+
---
|
662
|
+
`metadata`
|
663
|
+
```json
|
664
|
+
{
|
665
|
+
"type": "string",
|
666
|
+
"format": "json"
|
667
|
+
}
|
668
|
+
```
|
669
|
+
取引作成時に指定されるメタデータです。
|
670
|
+
|
671
|
+
任意入力で、全てのkeyとvalueが文字列であるようなフラットな構造のJSON文字列で指定します。
|
672
|
+
|
673
|
+
---
|
674
|
+
`products`
|
675
|
+
```json
|
676
|
+
{
|
677
|
+
"type": "array",
|
678
|
+
"items": { "type": "object" }
|
679
|
+
}
|
680
|
+
```
|
681
|
+
一つの取引に含まれる商品情報データです。
|
682
|
+
以下の内容からなるJSONオブジェクトの配列で指定します。
|
683
|
+
|
684
|
+
- `jan_code`: JANコード。64字以下の文字列
|
685
|
+
- `name`: 商品名。256字以下の文字列
|
686
|
+
- `unit_price`: 商品単価。0以上の数値
|
687
|
+
- `price`: 全体の金額(例: 商品単価 × 個数)。0以上の数値
|
688
|
+
- `is_discounted`: 賞味期限が近いなどの理由で商品が値引きされているかどうかのフラグ。boolean
|
689
|
+
- `other`: その他商品に関する情報。JSONオブジェクトで指定します。
|
690
|
+
|
691
|
+
---
|
692
|
+
`request_id`
|
693
|
+
```json
|
694
|
+
{
|
695
|
+
"type": "string",
|
696
|
+
"format": "uuid"
|
697
|
+
}
|
698
|
+
```
|
699
|
+
取引作成APIの羃等性を担保するためのリクエスト固有のIDです。
|
700
|
+
|
701
|
+
取引作成APIで結果が受け取れなかったなどの理由で再試行する際に、二重に取引が作られてしまうことを防ぐために、クライアント側から指定されます。指定は任意で、UUID V4フォーマットでランダム生成した文字列です。リクエストIDは一定期間で削除されます。
|
702
|
+
|
703
|
+
リクエストIDを指定したとき、まだそのリクエストIDに対する取引がない場合、新規に取引が作られレスポンスとして返されます。もしそのリクエストIDに対する取引が既にある場合、既存の取引がレスポンスとして返されます。
|
704
|
+
|
705
|
+
---
|
706
|
+
成功したときは[Transaction](#transaction)オブジェクトを返します
|
707
|
+
<a name="create-cpm-transaction"></a>
|
708
|
+
#### CPMトークンによる取引作成
|
709
|
+
CPMトークンにより取引を作成します。
|
710
|
+
CPMトークンに設定されたスコープの取引を作ることができます。
|
711
|
+
|
712
|
+
```ruby
|
713
|
+
response = $client.send(Pokepay::Request::CreateCpmTransaction.new(
|
714
|
+
"iwJJuJPCjlaztijN3vebjT", # cpm_token: CPMトークン
|
715
|
+
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # shop_id: 店舗ID
|
716
|
+
9912, # amount: 取引金額
|
717
|
+
description: "たい焼き(小倉)", # 取引説明文
|
718
|
+
metadata: "{\"key\":\"value\"}", # 店舗側メタデータ
|
719
|
+
products: [{"jan_code":"abc",
|
720
|
+
"name":"name1",
|
721
|
+
"unit_price":100,
|
722
|
+
"price": 100,
|
723
|
+
"is_discounted": false,
|
724
|
+
"other":"{}"}, {"jan_code":"abc",
|
725
|
+
"name":"name1",
|
726
|
+
"unit_price":100,
|
727
|
+
"price": 100,
|
728
|
+
"is_discounted": false,
|
729
|
+
"other":"{}"}, {"jan_code":"abc",
|
730
|
+
"name":"name1",
|
731
|
+
"unit_price":100,
|
732
|
+
"price": 100,
|
733
|
+
"is_discounted": false,
|
734
|
+
"other":"{}"}], # 商品情報データ
|
735
|
+
request_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" # リクエストID
|
736
|
+
))
|
737
|
+
```
|
738
|
+
|
739
|
+
---
|
740
|
+
`cpm_token`
|
741
|
+
```json
|
742
|
+
{
|
743
|
+
"type": "string",
|
744
|
+
"minLength": 22,
|
745
|
+
"maxLength": 22
|
746
|
+
}
|
747
|
+
```
|
748
|
+
エンドユーザーによって作られ、アプリなどに表示され、店舗に対して提示される22桁の文字列です。
|
749
|
+
|
750
|
+
エンドユーザーによって許可された取引のスコープを持っています。
|
751
|
+
|
752
|
+
---
|
753
|
+
`shop_id`
|
754
|
+
```json
|
755
|
+
{
|
756
|
+
"type": "string",
|
757
|
+
"format": "uuid"
|
758
|
+
}
|
759
|
+
```
|
760
|
+
店舗IDです。
|
761
|
+
|
762
|
+
支払いやチャージを行う店舗を指定します。
|
763
|
+
|
764
|
+
---
|
765
|
+
`amount`
|
766
|
+
```json
|
767
|
+
{ "type": "number" }
|
768
|
+
```
|
769
|
+
取引金額を指定します。
|
770
|
+
|
771
|
+
正の値を与えるとチャージになり、負の値を与えると支払いとなります。
|
772
|
+
|
773
|
+
---
|
774
|
+
`description`
|
775
|
+
```json
|
776
|
+
{
|
777
|
+
"type": "string",
|
778
|
+
"maxLength": 200
|
779
|
+
}
|
780
|
+
```
|
781
|
+
取引説明文です。
|
782
|
+
|
783
|
+
エンドユーザーアプリの取引履歴などに表示されます。
|
784
|
+
|
785
|
+
---
|
786
|
+
`metadata`
|
787
|
+
```json
|
788
|
+
{
|
789
|
+
"type": "string",
|
790
|
+
"format": "json"
|
791
|
+
}
|
792
|
+
```
|
793
|
+
取引作成時に店舗側から指定されるメタデータです。
|
794
|
+
|
795
|
+
任意入力で、全てのkeyとvalueが文字列であるようなフラットな構造のJSON文字列で指定します。
|
796
|
+
|
797
|
+
---
|
798
|
+
`products`
|
799
|
+
```json
|
800
|
+
{
|
801
|
+
"type": "array",
|
802
|
+
"items": { "type": "object" }
|
803
|
+
}
|
804
|
+
```
|
805
|
+
一つの取引に含まれる商品情報データです。
|
806
|
+
以下の内容からなるJSONオブジェクトの配列で指定します。
|
807
|
+
|
808
|
+
- `jan_code`: JANコード。64字以下の文字列
|
809
|
+
- `name`: 商品名。256字以下の文字列
|
810
|
+
- `unit_price`: 商品単価。0以上の数値
|
811
|
+
- `price`: 全体の金額(例: 商品単価 × 個数)。0以上の数値
|
812
|
+
- `is_discounted`: 賞味期限が近いなどの理由で商品が値引きされているかどうかのフラグ。boolean
|
813
|
+
- `other`: その他商品に関する情報。JSONオブジェクトで指定します。
|
814
|
+
|
617
815
|
---
|
618
816
|
`request_id`
|
619
817
|
```json
|
@@ -640,7 +838,8 @@ response = $client.send(Pokepay::Request::CreateTransferTransaction.new(
|
|
640
838
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # sender_id: 送金元ユーザーID
|
641
839
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # receiver_id: 受取ユーザーID
|
642
840
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
643
|
-
|
841
|
+
1306, # amount: 送金額
|
842
|
+
metadata: "{\"key\":\"value\"}", # 取引メタデータ
|
644
843
|
description: "たい焼き(小倉)", # 取引履歴に表示する説明文
|
645
844
|
request_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" # リクエストID
|
646
845
|
))
|
@@ -694,6 +893,18 @@ response = $client.send(Pokepay::Request::CreateTransferTransaction.new(
|
|
694
893
|
|
695
894
|
送金するマネー額を指定します。
|
696
895
|
|
896
|
+
---
|
897
|
+
`metadata`
|
898
|
+
```json
|
899
|
+
{
|
900
|
+
"type": "string",
|
901
|
+
"format": "json"
|
902
|
+
}
|
903
|
+
```
|
904
|
+
取引作成時に指定されるメタデータです。
|
905
|
+
|
906
|
+
任意入力で、全てのkeyとvalueが文字列であるようなフラットな構造のJSON文字列で指定します。
|
907
|
+
|
697
908
|
---
|
698
909
|
`description`
|
699
910
|
```json
|
@@ -729,8 +940,8 @@ response = $client.send(Pokepay::Request::CreateExchangeTransaction.new(
|
|
729
940
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
730
941
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
731
942
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
732
|
-
|
733
|
-
description: "
|
943
|
+
9015,
|
944
|
+
description: "9RjYRPCqvnZ1YzdrhG",
|
734
945
|
request_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" # リクエストID
|
735
946
|
))
|
736
947
|
```
|
@@ -775,7 +986,14 @@ response = $client.send(Pokepay::Request::GetTransaction.new(
|
|
775
986
|
---
|
776
987
|
成功したときは[Transaction](#transaction)オブジェクトを返します
|
777
988
|
<a name="refund-transaction"></a>
|
778
|
-
####
|
989
|
+
#### 取引をキャンセルする
|
990
|
+
取引IDを指定して取引をキャンセルします。
|
991
|
+
|
992
|
+
発行体の管理者は自組織の直営店、または発行しているマネーの決済加盟店組織での取引をキャンセルできます。
|
993
|
+
キャンセル対象の取引に付随するポイント還元キャンペーンやクーポン適用も取り消されます。
|
994
|
+
|
995
|
+
チャージ取引のキャンセル時に返金すべき残高が足りないときは `account_balance_not_enough (422)` エラーが返ります。
|
996
|
+
取引をキャンセルできるのは1回きりです。既にキャンセルされた取引を重ねてキャンセルしようとすると `transaction_already_refunded (422)` エラーが返ります。
|
779
997
|
```ruby
|
780
998
|
response = $client.send(Pokepay::Request::RefundTransaction.new(
|
781
999
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # transaction_id: 取引ID
|
@@ -787,19 +1005,19 @@ response = $client.send(Pokepay::Request::RefundTransaction.new(
|
|
787
1005
|
####
|
788
1006
|
```ruby
|
789
1007
|
response = $client.send(Pokepay::Request::ListTransfers.new(
|
790
|
-
from: "
|
791
|
-
to: "2017-
|
792
|
-
page:
|
793
|
-
per_page:
|
1008
|
+
from: "2023-02-09T00:49:53.000000+09:00",
|
1009
|
+
to: "2017-04-28T12:45:45.000000+09:00",
|
1010
|
+
page: 6607,
|
1011
|
+
per_page: 6000,
|
794
1012
|
shop_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
795
|
-
shop_name: "
|
1013
|
+
shop_name: "GDpqqjYUa42NN7jWbTA8sT9CjYdhYyR9ZtWhMAKSZHQ2Tja",
|
796
1014
|
customer_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
797
|
-
customer_name: "
|
1015
|
+
customer_name: "hc0hASAcEibjku1fdQetgL0O7DlAFrkXVihIdQWu7J4NYirXryPP6taqbm6hsnA9hELkacVB4dzDqQ1LbTyVIgVP7fIz1xemnrDx9P7HPwLX5lwWZKuWWf4n5wNPq2rjN28QfQLnQ9Qr2gs4rAyEVt2ws7WkJzpgGUX4mtxobZ9ZCp",
|
798
1016
|
transaction_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
799
1017
|
private_money_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
800
1018
|
is_modified: true,
|
801
|
-
transaction_types: ["transfer"
|
802
|
-
transfer_types: ["
|
1019
|
+
transaction_types: ["transfer"],
|
1020
|
+
transfer_types: ["coupon"], # 取引明細の種類でフィルターします。
|
803
1021
|
description: "店頭QRコードによる支払い" # 取引詳細説明文
|
804
1022
|
))
|
805
1023
|
```
|
@@ -907,19 +1125,19 @@ QRコード生成時に送金元店舗のウォレット情報や、送金額な
|
|
907
1125
|
支払いQRコード一覧を表示します。
|
908
1126
|
```ruby
|
909
1127
|
response = $client.send(Pokepay::Request::ListBills.new(
|
910
|
-
page:
|
911
|
-
per_page:
|
912
|
-
bill_id: "
|
1128
|
+
page: 2359, # ページ番号
|
1129
|
+
per_page: 9119, # 1ページの表示数
|
1130
|
+
bill_id: "WIbd8", # 支払いQRコードのID
|
913
1131
|
private_money_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # マネーID
|
914
|
-
organization_code: "
|
1132
|
+
organization_code: "U5j-HH14BbFT54v-4FDv-si", # 組織コード
|
915
1133
|
description: "test bill", # 取引説明文
|
916
|
-
created_from: "
|
917
|
-
created_to: "
|
1134
|
+
created_from: "2023-07-11T01:18:59.000000+09:00", # 作成日時(起点)
|
1135
|
+
created_to: "2018-10-19T23:38:10.000000+09:00", # 作成日時(終点)
|
918
1136
|
shop_name: "bill test shop1", # 店舗名
|
919
1137
|
shop_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # 店舗ID
|
920
|
-
lower_limit_amount:
|
921
|
-
upper_limit_amount:
|
922
|
-
is_disabled:
|
1138
|
+
lower_limit_amount: 5189, # 金額の範囲によるフィルタ(下限)
|
1139
|
+
upper_limit_amount: 1460, # 金額の範囲によるフィルタ(上限)
|
1140
|
+
is_disabled: true # 支払いQRコードが無効化されているかどうか
|
923
1141
|
))
|
924
1142
|
```
|
925
1143
|
|
@@ -1063,7 +1281,7 @@ response = $client.send(Pokepay::Request::ListBills.new(
|
|
1063
1281
|
response = $client.send(Pokepay::Request::CreateBill.new(
|
1064
1282
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: 支払いマネーのマネーID
|
1065
1283
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # shop_id: 支払い先(受け取り人)の店舗ID
|
1066
|
-
amount:
|
1284
|
+
amount: 7969, # 支払い額
|
1067
1285
|
description: "test bill" # 説明文(アプリ上で取引の説明文として表示される)
|
1068
1286
|
))
|
1069
1287
|
```
|
@@ -1087,9 +1305,9 @@ response = $client.send(Pokepay::Request::CreateBill.new(
|
|
1087
1305
|
```ruby
|
1088
1306
|
response = $client.send(Pokepay::Request::UpdateBill.new(
|
1089
1307
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # bill_id: 支払いQRコードのID
|
1090
|
-
amount:
|
1308
|
+
amount: 9387, # 支払い額
|
1091
1309
|
description: "test bill", # 説明文
|
1092
|
-
is_disabled:
|
1310
|
+
is_disabled: true # 無効化されているかどうか
|
1093
1311
|
))
|
1094
1312
|
```
|
1095
1313
|
|
@@ -1152,9 +1370,9 @@ Cashtrayを作成します。
|
|
1152
1370
|
response = $client.send(Pokepay::Request::CreateCashtray.new(
|
1153
1371
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
1154
1372
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # shop_id: 店舗ユーザーID
|
1155
|
-
|
1373
|
+
4206, # amount: 金額
|
1156
1374
|
description: "たい焼き(小倉)", # 取引履歴に表示する説明文
|
1157
|
-
expires_in:
|
1375
|
+
expires_in: 2971 # 失効時間(秒)
|
1158
1376
|
))
|
1159
1377
|
```
|
1160
1378
|
|
@@ -1315,9 +1533,9 @@ Cashtrayの内容を更新します。bodyパラメーターは全て省略可
|
|
1315
1533
|
```ruby
|
1316
1534
|
response = $client.send(Pokepay::Request::UpdateCashtray.new(
|
1317
1535
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # cashtray_id: CashtrayのID
|
1318
|
-
amount:
|
1536
|
+
amount: 4180, # 金額
|
1319
1537
|
description: "たい焼き(小倉)", # 取引履歴に表示する説明文
|
1320
|
-
expires_in:
|
1538
|
+
expires_in: 5017 # 失効時間(秒)
|
1321
1539
|
))
|
1322
1540
|
```
|
1323
1541
|
|
@@ -1423,10 +1641,10 @@ response = $client.send(Pokepay::Request::UpdateAccount.new(
|
|
1423
1641
|
```ruby
|
1424
1642
|
response = $client.send(Pokepay::Request::ListAccountBalances.new(
|
1425
1643
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # account_id: ウォレットID
|
1426
|
-
page:
|
1427
|
-
per_page:
|
1428
|
-
expires_at_from: "
|
1429
|
-
expires_at_to: "
|
1644
|
+
page: 1398, # ページ番号
|
1645
|
+
per_page: 295, # 1ページ分の取引数
|
1646
|
+
expires_at_from: "2018-11-24T12:24:46.000000+09:00", # 有効期限の期間によるフィルター(開始時点)
|
1647
|
+
expires_at_to: "2021-02-20T21:10:32.000000+09:00", # 有効期限の期間によるフィルター(終了時点)
|
1430
1648
|
direction: "asc" # 有効期限によるソート順序
|
1431
1649
|
))
|
1432
1650
|
```
|
@@ -1501,10 +1719,10 @@ response = $client.send(Pokepay::Request::ListAccountBalances.new(
|
|
1501
1719
|
```ruby
|
1502
1720
|
response = $client.send(Pokepay::Request::ListAccountExpiredBalances.new(
|
1503
1721
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # account_id: ウォレットID
|
1504
|
-
page:
|
1505
|
-
per_page:
|
1506
|
-
expires_at_from: "
|
1507
|
-
expires_at_to: "
|
1722
|
+
page: 3542, # ページ番号
|
1723
|
+
per_page: 59, # 1ページ分の取引数
|
1724
|
+
expires_at_from: "2025-03-03T19:58:32.000000+09:00", # 有効期限の期間によるフィルター(開始時点)
|
1725
|
+
expires_at_to: "2022-07-08T21:11:40.000000+09:00", # 有効期限の期間によるフィルター(終了時点)
|
1508
1726
|
direction: "asc" # 有効期限によるソート順序
|
1509
1727
|
))
|
1510
1728
|
```
|
@@ -1579,14 +1797,14 @@ response = $client.send(Pokepay::Request::ListAccountExpiredBalances.new(
|
|
1579
1797
|
```ruby
|
1580
1798
|
response = $client.send(Pokepay::Request::GetCustomerAccounts.new(
|
1581
1799
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
1582
|
-
page:
|
1583
|
-
per_page:
|
1584
|
-
created_at_from: "
|
1585
|
-
created_at_to: "
|
1586
|
-
is_suspended:
|
1587
|
-
external_id: "
|
1588
|
-
tel: "
|
1589
|
-
email: "
|
1800
|
+
page: 1636, # ページ番号
|
1801
|
+
per_page: 2198, # 1ページ分のウォレット数
|
1802
|
+
created_at_from: "2020-07-10T06:47:52.000000+09:00", # ウォレット作成日によるフィルター(開始時点)
|
1803
|
+
created_at_to: "2023-01-18T13:26:30.000000+09:00", # ウォレット作成日によるフィルター(終了時点)
|
1804
|
+
is_suspended: false, # ウォレットが凍結状態かどうかでフィルターする
|
1805
|
+
external_id: "Izv8TjKb1dIcQKtgPEpt9Ynsu0LI4", # 外部ID
|
1806
|
+
tel: "01172-559", # エンドユーザーの電話番号
|
1807
|
+
email: "3YpOK96EoF@GxVJ.com" # エンドユーザーのメールアドレス
|
1590
1808
|
))
|
1591
1809
|
```
|
1592
1810
|
|
@@ -1689,7 +1907,7 @@ response = $client.send(Pokepay::Request::CreateCustomerAccount.new(
|
|
1689
1907
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
1690
1908
|
user_name: "ポケペイ太郎", # ユーザー名
|
1691
1909
|
account_name: "ポケペイ太郎のアカウント", # アカウント名
|
1692
|
-
external_id: "
|
1910
|
+
external_id: "NTeRlFM4Xw2YneFRtau24yc1kusN7qW2yhhPFbHNPhRgn" # 外部ID
|
1693
1911
|
))
|
1694
1912
|
```
|
1695
1913
|
|
@@ -1743,10 +1961,10 @@ PAPIクライアントシステムから利用するPokepayユーザーのIDで
|
|
1743
1961
|
```ruby
|
1744
1962
|
response = $client.send(Pokepay::Request::GetShopAccounts.new(
|
1745
1963
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
1746
|
-
page:
|
1747
|
-
per_page:
|
1748
|
-
created_at_from: "
|
1749
|
-
created_at_to: "
|
1964
|
+
page: 8690, # ページ番号
|
1965
|
+
per_page: 3606, # 1ページ分のウォレット数
|
1966
|
+
created_at_from: "2018-01-27T06:32:33.000000+09:00", # ウォレット作成日によるフィルター(開始時点)
|
1967
|
+
created_at_to: "2023-06-23T05:06:56.000000+09:00", # ウォレット作成日によるフィルター(終了時点)
|
1750
1968
|
is_suspended: false # ウォレットが凍結状態かどうかでフィルターする
|
1751
1969
|
))
|
1752
1970
|
```
|
@@ -1820,10 +2038,10 @@ response = $client.send(Pokepay::Request::ListCustomerTransactions.new(
|
|
1820
2038
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
1821
2039
|
sender_customer_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # 送金エンドユーザーID
|
1822
2040
|
receiver_customer_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # 受取エンドユーザーID
|
1823
|
-
type: "
|
2041
|
+
type: "JbOrM", # 取引種別、チャージ=topup、支払い=payment、個人間送金=transfer
|
1824
2042
|
is_modified: true, # キャンセル済みかどうか
|
1825
|
-
from: "
|
1826
|
-
to: "
|
2043
|
+
from: "2017-01-07T03:09:17.000000+09:00", # 開始日時
|
2044
|
+
to: "2021-09-27T18:17:33.000000+09:00", # 終了日時
|
1827
2045
|
page: 1, # ページ番号
|
1828
2046
|
per_page: 50 # 1ページ分の取引数
|
1829
2047
|
))
|
@@ -1948,11 +2166,11 @@ response = $client.send(Pokepay::Request::ListShops.new(
|
|
1948
2166
|
organization_code: "pocketchange", # 組織コード
|
1949
2167
|
private_money_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # マネーID
|
1950
2168
|
name: "oxスーパー三田店", # 店舗名
|
1951
|
-
postal_code: "
|
2169
|
+
postal_code: "6729142", # 店舗の郵便番号
|
1952
2170
|
address: "東京都港区芝...", # 店舗の住所
|
1953
|
-
tel: "
|
1954
|
-
email: "
|
1955
|
-
external_id: "
|
2171
|
+
tel: "05-7934492", # 店舗の電話番号
|
2172
|
+
email: "jt9M12BOno@1Acj.com", # 店舗のメールアドレス
|
2173
|
+
external_id: "M96oftC7mHhiSDgXKvVy5paxKD2XcOfyMo2", # 店舗の外部ID
|
1956
2174
|
page: 1, # ページ番号
|
1957
2175
|
per_page: 50 # 1ページ分の取引数
|
1958
2176
|
))
|
@@ -2077,11 +2295,11 @@ response = $client.send(Pokepay::Request::ListShops.new(
|
|
2077
2295
|
```ruby
|
2078
2296
|
response = $client.send(Pokepay::Request::CreateShop.new(
|
2079
2297
|
"oxスーパー三田店", # shop_name: 店舗名
|
2080
|
-
shop_postal_code: "
|
2298
|
+
shop_postal_code: "2691189", # 店舗の郵便番号
|
2081
2299
|
shop_address: "東京都港区芝...", # 店舗の住所
|
2082
|
-
shop_tel: "
|
2083
|
-
shop_email: "
|
2084
|
-
shop_external_id: "
|
2300
|
+
shop_tel: "0643430858", # 店舗の電話番号
|
2301
|
+
shop_email: "x6Ov6eGwjQ@Cqxd.com", # 店舗のメールアドレス
|
2302
|
+
shop_external_id: "tQnDY", # 店舗の外部ID
|
2085
2303
|
organization_code: "ox-supermarket" # 組織コード
|
2086
2304
|
))
|
2087
2305
|
```
|
@@ -2091,14 +2309,14 @@ response = $client.send(Pokepay::Request::CreateShop.new(
|
|
2091
2309
|
```ruby
|
2092
2310
|
response = $client.send(Pokepay::Request::CreateShopV2.new(
|
2093
2311
|
"oxスーパー三田店", # name: 店舗名
|
2094
|
-
postal_code: "
|
2312
|
+
postal_code: "4391483", # 店舗の郵便番号
|
2095
2313
|
address: "東京都港区芝...", # 店舗の住所
|
2096
|
-
tel: "
|
2097
|
-
email: "
|
2098
|
-
external_id: "
|
2314
|
+
tel: "088152-979", # 店舗の電話番号
|
2315
|
+
email: "CsXRcUZY47@cpIh.com", # 店舗のメールアドレス
|
2316
|
+
external_id: "03BvqB7CzLjYHoO28zEE65UlKtMCe12", # 店舗の外部ID
|
2099
2317
|
organization_code: "ox-supermarket", # 組織コード
|
2100
2318
|
private_money_ids: ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"], # 店舗で有効にするマネーIDの配列
|
2101
|
-
can_topup_private_money_ids: ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
|
2319
|
+
can_topup_private_money_ids: ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"] # 店舗でチャージ可能にするマネーIDの配列
|
2102
2320
|
))
|
2103
2321
|
```
|
2104
2322
|
|
@@ -2169,13 +2387,13 @@ response = $client.send(Pokepay::Request::GetShop.new(
|
|
2169
2387
|
response = $client.send(Pokepay::Request::UpdateShop.new(
|
2170
2388
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # shop_id: 店舗ユーザーID
|
2171
2389
|
name: "oxスーパー三田店", # 店舗名
|
2172
|
-
postal_code: "
|
2390
|
+
postal_code: "891-6024", # 店舗の郵便番号
|
2173
2391
|
address: "東京都港区芝...", # 店舗の住所
|
2174
|
-
tel: "
|
2175
|
-
email: "
|
2176
|
-
external_id: "
|
2177
|
-
private_money_ids: ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
|
2178
|
-
can_topup_private_money_ids: []
|
2392
|
+
tel: "0224-585", # 店舗の電話番号
|
2393
|
+
email: "WnFZLX87qt@edPz.com", # 店舗のメールアドレス
|
2394
|
+
external_id: "8NdiYCurcmVOPZzwMWHgQ0V", # 店舗の外部ID
|
2395
|
+
private_money_ids: ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"], # 店舗で有効にするマネーIDの配列
|
2396
|
+
can_topup_private_money_ids: ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"] # 店舗でチャージ可能にするマネーIDの配列
|
2179
2397
|
))
|
2180
2398
|
```
|
2181
2399
|
|
@@ -2325,8 +2543,8 @@ response = $client.send(Pokepay::Request::GetPrivateMoneys.new(
|
|
2325
2543
|
```ruby
|
2326
2544
|
response = $client.send(Pokepay::Request::GetPrivateMoneyOrganizationSummaries.new(
|
2327
2545
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
2328
|
-
from: "
|
2329
|
-
to: "
|
2546
|
+
from: "2024-01-30T11:08:00.000000+09:00", # 開始日時(toと同時に指定する必要有)
|
2547
|
+
to: "2023-12-25T17:27:23.000000+09:00", # 終了日時(fromと同時に指定する必要有)
|
2330
2548
|
page: 1, # ページ番号
|
2331
2549
|
per_page: 50 # 1ページ分の取引数
|
2332
2550
|
))
|
@@ -2340,10 +2558,10 @@ response = $client.send(Pokepay::Request::GetPrivateMoneyOrganizationSummaries.n
|
|
2340
2558
|
CSVファイルから一括取引をします。
|
2341
2559
|
```ruby
|
2342
2560
|
response = $client.send(Pokepay::Request::BulkCreateTransaction.new(
|
2343
|
-
"
|
2344
|
-
"
|
2345
|
-
"
|
2346
|
-
description: "
|
2561
|
+
"pW9b9NBdcz", # name: 一括取引タスク名
|
2562
|
+
"T", # content: 取引する情報のCSV
|
2563
|
+
"SynCfTiWLEN2pEbq7ZeB8PVJkE9NzaeTptZ5", # request_id: リクエストID
|
2564
|
+
description: "kX9rLpagdWQnEnTlLyubwibc5uG9Y4cn6ApRZ5NX6g" # 一括取引の説明
|
2347
2565
|
))
|
2348
2566
|
```
|
2349
2567
|
|
@@ -2451,6 +2669,22 @@ response = $client.send(Pokepay::Request::BulkCreateTransaction.new(
|
|
2451
2669
|
|
2452
2670
|
`account`は [AccountWithUser](#account-with-user) オブジェクトを返します。
|
2453
2671
|
|
2672
|
+
<a name="cpm-token"></a>
|
2673
|
+
## CpmToken
|
2674
|
+
* `cpm_token (string)`:
|
2675
|
+
* `account (AccountDetail)`:
|
2676
|
+
* `transaction (Transaction)`:
|
2677
|
+
* `event (ExternalTransaction)`:
|
2678
|
+
* `scopes (array of strings)`: 許可された取引種別
|
2679
|
+
* `expires_at (string)`: CPMトークンの失効日時
|
2680
|
+
* `metadata (string)`: エンドユーザー側メタデータ
|
2681
|
+
|
2682
|
+
`account`は [AccountDetail](#account-detail) オブジェクトを返します。
|
2683
|
+
|
2684
|
+
`transaction`は [Transaction](#transaction) オブジェクトを返します。
|
2685
|
+
|
2686
|
+
`event`は [ExternalTransaction](#external-transaction) オブジェクトを返します。
|
2687
|
+
|
2454
2688
|
<a name="cashtray"></a>
|
2455
2689
|
## Cashtray
|
2456
2690
|
* `id (string)`: Cashtray自体のIDです。
|
@@ -2639,6 +2873,22 @@ response = $client.send(Pokepay::Request::BulkCreateTransaction.new(
|
|
2639
2873
|
|
2640
2874
|
`organization`は [Organization](#organization) オブジェクトを返します。
|
2641
2875
|
|
2876
|
+
<a name="external-transaction"></a>
|
2877
|
+
## ExternalTransaction
|
2878
|
+
* `id (string)`: ポケペイ外部取引ID
|
2879
|
+
* `is_modified (boolean)`: 返金された取引かどうか
|
2880
|
+
* `sender (User)`: 送金者情報
|
2881
|
+
* `sender_account (Account)`: 送金ウォレット情報
|
2882
|
+
* `receiver (User)`: 受取者情報
|
2883
|
+
* `receiver_account (Account)`: 受取ウォレット情報
|
2884
|
+
* `amount (double)`: 決済額
|
2885
|
+
* `done_at (string)`: 取引日時
|
2886
|
+
* `description (string)`: 取引説明文
|
2887
|
+
|
2888
|
+
`receiver`と`sender`は [User](#user) オブジェクトを返します。
|
2889
|
+
|
2890
|
+
`receiver_account`と`sender_account`は [Account](#account) オブジェクトを返します。
|
2891
|
+
|
2642
2892
|
<a name="cashtray-attempt"></a>
|
2643
2893
|
## CashtrayAttempt
|
2644
2894
|
* `account (AccountWithUser)`: エンドユーザーのウォレット
|