pokepay_partner_ruby_sdk 0.2.0 → 0.3.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.
- checksums.yaml +4 -4
- data/Gemfile.lock +6 -8
- data/docs/index.md +1011 -147
- data/lib/pokepay_partner_ruby_sdk/client.rb +11 -1
- data/lib/pokepay_partner_ruby_sdk/request/get_account_transfer_summary.rb +15 -0
- data/lib/pokepay_partner_ruby_sdk/request/get_bulk_transaction.rb +5 -5
- data/lib/pokepay_partner_ruby_sdk/request/list_transfers_v2.rb +15 -0
- data/lib/pokepay_partner_ruby_sdk/request/request_user_stats.rb +16 -0
- data/lib/pokepay_partner_ruby_sdk/response/account_detail.rb +2 -0
- data/lib/pokepay_partner_ruby_sdk/response/account_transfer_summary.rb +11 -0
- data/lib/pokepay_partner_ruby_sdk/response/account_transfer_summary_element.rb +17 -0
- data/lib/pokepay_partner_ruby_sdk/response/bulk_transaction_job.rb +42 -0
- data/lib/pokepay_partner_ruby_sdk/response/campaign.rb +2 -0
- data/lib/pokepay_partner_ruby_sdk/response/check.rb +6 -0
- data/lib/pokepay_partner_ruby_sdk/response/paginated_bulk_transaction_job.rb +16 -0
- data/lib/pokepay_partner_ruby_sdk/response/paginated_transfers_v2.rb +19 -0
- data/lib/pokepay_partner_ruby_sdk/response/unpermitted_admin_user.rb +13 -0
- data/lib/pokepay_partner_ruby_sdk/response/user_stats_operation.rb +25 -0
- data/lib/pokepay_partner_ruby_sdk/response/user_stats_operation_service_unavailable.rb +13 -0
- data/lib/pokepay_partner_ruby_sdk/version.rb +1 -1
- data/lib/pokepay_partner_ruby_sdk.rb +12 -0
- data/partner.yaml +1017 -6
- data/pokepay_partner_ruby_sdk.gemspec +1 -1
- metadata +16 -5
data/docs/index.md
CHANGED
@@ -168,7 +168,11 @@ response.body
|
|
168
168
|
- [GetTransaction](#get-transaction): 取引情報を取得する
|
169
169
|
- [RefundTransaction](#refund-transaction): 取引をキャンセルする
|
170
170
|
- [GetTransactionByRequestId](#get-transaction-by-request-id): リクエストIDから取引情報を取得する
|
171
|
+
- [RequestUserStats](#request-user-stats): 指定期間内の顧客が行った取引の統計情報をCSVでダウンロードする
|
172
|
+
- [GetAccountTransferSummary](#get-account-transfer-summary):
|
171
173
|
- [ListTransfers](#list-transfers):
|
174
|
+
- [ListTransfersV2](#list-transfers-v2):
|
175
|
+
- [CreateCheck](#create-check): チャージQRコードの発行
|
172
176
|
- [CreateTopupTransactionWithCheck](#create-topup-transaction-with-check): チャージQRコードを読み取ることでチャージする
|
173
177
|
- [ListBills](#list-bills): 支払いQRコード一覧を表示する
|
174
178
|
- [CreateBill](#create-bill): 支払いQRコードの発行
|
@@ -182,9 +186,9 @@ response.body
|
|
182
186
|
- [DeleteAccount](#delete-account): ウォレットを退会する
|
183
187
|
- [ListAccountBalances](#list-account-balances): エンドユーザーの残高内訳を表示する
|
184
188
|
- [ListAccountExpiredBalances](#list-account-expired-balances): エンドユーザーの失効済みの残高内訳を表示する
|
185
|
-
- [UpdateCustomerAccount](#update-customer-account):
|
189
|
+
- [UpdateCustomerAccount](#update-customer-account): エンドユーザーのウォレット情報を更新する
|
186
190
|
- [GetCustomerAccounts](#get-customer-accounts): エンドユーザーのウォレット一覧を表示する
|
187
|
-
- [CreateCustomerAccount](#create-customer-account):
|
191
|
+
- [CreateCustomerAccount](#create-customer-account): 新規エンドユーザーをウォレットと共に追加する
|
188
192
|
- [GetShopAccounts](#get-shop-accounts): 店舗ユーザーのウォレット一覧を表示する
|
189
193
|
- [ListCustomerTransactions](#list-customer-transactions): 取引履歴を取得する
|
190
194
|
- [ListShops](#list-shops): 店舗一覧を取得する
|
@@ -210,7 +214,7 @@ response.body
|
|
210
214
|
CPMトークンの現在の状態を取得します。CPMトークンの有効期限やCPM取引の状態を返します。
|
211
215
|
```ruby
|
212
216
|
response = $client.send(Pokepay::Request::GetCpmToken.new(
|
213
|
-
"
|
217
|
+
"lMKFHkTHEGRWUBVUZa1rmA" # cpm_token: CPMトークン
|
214
218
|
))
|
215
219
|
```
|
216
220
|
|
@@ -232,18 +236,18 @@ CPM取引時にエンドユーザーが店舗に提示するバーコードを
|
|
232
236
|
取引一覧を返します。
|
233
237
|
```ruby
|
234
238
|
response = $client.send(Pokepay::Request::ListTransactions.new(
|
235
|
-
from: "
|
236
|
-
to: "
|
239
|
+
from: "2024-08-03T15:38:40.000000+09:00", # 開始日時
|
240
|
+
to: "2017-05-16T05:26:01.000000+09:00", # 終了日時
|
237
241
|
page: 1, # ページ番号
|
238
242
|
per_page: 50, # 1ページ分の取引数
|
239
243
|
shop_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # 店舗ID
|
240
244
|
customer_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # エンドユーザーID
|
241
245
|
customer_name: "太郎", # エンドユーザー名
|
242
246
|
terminal_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # 端末ID
|
243
|
-
transaction_id: "
|
247
|
+
transaction_id: "UF6ihvl", # 取引ID
|
244
248
|
organization_code: "pocketchange", # 組織コード
|
245
249
|
private_money_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # マネーID
|
246
|
-
is_modified:
|
250
|
+
is_modified: false, # キャンセルフラグ
|
247
251
|
types: ["topup", "payment"], # 取引種別 (複数指定可)、チャージ=topup、支払い=payment
|
248
252
|
description: "店頭QRコードによる支払い" # 取引説明文
|
249
253
|
))
|
@@ -444,10 +448,10 @@ response = $client.send(Pokepay::Request::CreateTransaction.new(
|
|
444
448
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
445
449
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
446
450
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
447
|
-
money_amount:
|
448
|
-
point_amount:
|
449
|
-
point_expires_at: "2023-
|
450
|
-
description: "
|
451
|
+
money_amount: 969,
|
452
|
+
point_amount: 895,
|
453
|
+
point_expires_at: "2023-04-29T23:13:39.000000+09:00", # ポイント有効期限
|
454
|
+
description: "uoOEnKr"
|
451
455
|
))
|
452
456
|
```
|
453
457
|
|
@@ -476,11 +480,11 @@ response = $client.send(Pokepay::Request::ListTransactionsV2.new(
|
|
476
480
|
customer_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # エンドユーザーID
|
477
481
|
customer_name: "太郎", # エンドユーザー名
|
478
482
|
description: "店頭QRコードによる支払い", # 取引説明文
|
479
|
-
transaction_id: "
|
480
|
-
is_modified:
|
483
|
+
transaction_id: "Nj", # 取引ID
|
484
|
+
is_modified: false, # キャンセルフラグ
|
481
485
|
types: ["topup", "payment"], # 取引種別 (複数指定可)、チャージ=topup、支払い=payment
|
482
|
-
from: "
|
483
|
-
to: "
|
486
|
+
from: "2024-12-04T20:21:27.000000+09:00", # 開始日時
|
487
|
+
to: "2023-09-19T17:27:20.000000+09:00", # 終了日時
|
484
488
|
next_page_cursor_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # 次ページへ遷移する際に起点となるtransactionのID
|
485
489
|
prev_page_cursor_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # 前ページへ遷移する際に起点となるtransactionのID
|
486
490
|
per_page: 50 # 1ページ分の取引数
|
@@ -709,9 +713,9 @@ response = $client.send(Pokepay::Request::CreateTopupTransaction.new(
|
|
709
713
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # customer_id: エンドユーザーのID
|
710
714
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
711
715
|
bear_point_shop_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # ポイント支払時の負担店舗ID
|
712
|
-
money_amount:
|
713
|
-
point_amount:
|
714
|
-
point_expires_at: "
|
716
|
+
money_amount: 4113, # マネー額
|
717
|
+
point_amount: 1839, # ポイント額
|
718
|
+
point_expires_at: "2023-11-03T06:21:47.000000+09:00", # ポイント有効期限
|
715
719
|
description: "初夏のチャージキャンペーン", # 取引履歴に表示する説明文
|
716
720
|
metadata: "{\"key\":\"value\"}", # 取引メタデータ
|
717
721
|
request_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" # リクエストID
|
@@ -853,7 +857,7 @@ response = $client.send(Pokepay::Request::CreatePaymentTransaction.new(
|
|
853
857
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # shop_id: 店舗ID
|
854
858
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # customer_id: エンドユーザーID
|
855
859
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
856
|
-
|
860
|
+
7737, # amount: 支払い額
|
857
861
|
description: "たい焼き(小倉)", # 取引履歴に表示する説明文
|
858
862
|
metadata: "{\"key\":\"value\"}", # 取引メタデータ
|
859
863
|
products: [{"jan_code":"abc",
|
@@ -979,9 +983,9 @@ CPMトークンに設定されたスコープの取引を作ることができ
|
|
979
983
|
|
980
984
|
```ruby
|
981
985
|
response = $client.send(Pokepay::Request::CreateCpmTransaction.new(
|
982
|
-
"
|
986
|
+
"jDxtxrgs7e0dkiAAa8jwX6", # cpm_token: CPMトークン
|
983
987
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # shop_id: 店舗ID
|
984
|
-
|
988
|
+
7305.0, # amount: 取引金額
|
985
989
|
description: "たい焼き(小倉)", # 取引説明文
|
986
990
|
metadata: "{\"key\":\"value\"}", # 店舗側メタデータ
|
987
991
|
products: [{"jan_code":"abc",
|
@@ -1101,7 +1105,7 @@ response = $client.send(Pokepay::Request::CreateTransferTransaction.new(
|
|
1101
1105
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # sender_id: 送金元ユーザーID
|
1102
1106
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # receiver_id: 受取ユーザーID
|
1103
1107
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
1104
|
-
|
1108
|
+
8870.0, # amount: 送金額
|
1105
1109
|
metadata: "{\"key\":\"value\"}", # 取引メタデータ
|
1106
1110
|
description: "たい焼き(小倉)", # 取引履歴に表示する説明文
|
1107
1111
|
request_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" # リクエストID
|
@@ -1203,8 +1207,8 @@ response = $client.send(Pokepay::Request::CreateExchangeTransaction.new(
|
|
1203
1207
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
1204
1208
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
1205
1209
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
1206
|
-
|
1207
|
-
description: "
|
1210
|
+
6442.0,
|
1211
|
+
description: "LCB1XlvzBazSCE1hEG2EkkP2VIPy7HW7Ee7skB9BB1YNClE0n87A30l6vspNWH9u8x4Yq2mxjIub5W9d4fa79SnOHSfjKkp3QkI11kPUOWIOCC9XRXSkWvgwMdC6YsQVBM615BSLRTB4phpjbt6QHeDKxXdEg3OxGlsZaVSpjoQ6ffYAe6kpXiCTiSBUIe5iqIMOcjy",
|
1208
1212
|
request_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" # リクエストID
|
1209
1213
|
))
|
1210
1214
|
```
|
@@ -1260,9 +1264,22 @@ response = $client.send(Pokepay::Request::GetTransaction.new(
|
|
1260
1264
|
```ruby
|
1261
1265
|
response = $client.send(Pokepay::Request::RefundTransaction.new(
|
1262
1266
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # transaction_id: 取引ID
|
1263
|
-
description: "返品対応のため"
|
1267
|
+
description: "返品対応のため", # 取引履歴に表示する返金事由
|
1268
|
+
returning_point_expires_at: "2020-06-14T12:44:07.000000+09:00" # 返却ポイントの有効期限
|
1264
1269
|
))
|
1265
1270
|
```
|
1271
|
+
|
1272
|
+
---
|
1273
|
+
`returning_point_expires_at`
|
1274
|
+
```json
|
1275
|
+
{
|
1276
|
+
"type": "string",
|
1277
|
+
"format": "date-time"
|
1278
|
+
}
|
1279
|
+
```
|
1280
|
+
ポイント支払いを含む支払い取引をキャンセルする際にユーザへ返却されるポイントの有効期限です。デフォルトでは未指定です。
|
1281
|
+
|
1282
|
+
---
|
1266
1283
|
成功したときは[TransactionDetail](#transaction-detail)オブジェクトを返します
|
1267
1284
|
<a name="get-transaction-by-request-id"></a>
|
1268
1285
|
#### リクエストIDから取引情報を取得する
|
@@ -1287,23 +1304,145 @@ response = $client.send(Pokepay::Request::GetTransactionByRequestId.new(
|
|
1287
1304
|
|
1288
1305
|
---
|
1289
1306
|
成功したときは[TransactionDetail](#transaction-detail)オブジェクトを返します
|
1307
|
+
<a name="request-user-stats"></a>
|
1308
|
+
#### 指定期間内の顧客が行った取引の統計情報をCSVでダウンロードする
|
1309
|
+
期間を指定して、期間内に発行マネーの全顧客が行った取引の総額・回数などをCSVでダウンロードする機能です。
|
1310
|
+
CSVの作成は非同期で行われるため完了まで少しの間待つ必要がありますが、完了時にダウンロードできるURLをレスポンスとして返します。
|
1311
|
+
このURLの有効期限はリクエスト日時から7日間です。
|
1312
|
+
|
1313
|
+
ダウンロードできるCSVのデータは以下のものです。
|
1314
|
+
|
1315
|
+
* organization_code: 取引を行った組織コード
|
1316
|
+
* private_money_id: 取引されたマネーのID
|
1317
|
+
* private_money_name: 取引されたマネーの名前
|
1318
|
+
* user_id: 決済したユーザーID
|
1319
|
+
* user_external_id: 決済したユーザーの外部ID
|
1320
|
+
* payment_money_amount: 指定期間内に決済に使ったマネーの総額
|
1321
|
+
* payment_point_amount: 指定期間内に決済に使ったポイントの総額
|
1322
|
+
* payment_transaction_count: 指定期間内に決済した回数。キャンセルされた取引は含まない
|
1323
|
+
|
1324
|
+
また、指定期間より前の決済を時間をおいてキャンセルした場合などには payment_money_amount, payment_point_amount, payment_transaction_count が負の値になることもあることに留意してください。
|
1325
|
+
```ruby
|
1326
|
+
response = $client.send(Pokepay::Request::RequestUserStats.new(
|
1327
|
+
"2019-01-18T03:32:22.000000+09:00", # from: 集計期間の開始時刻
|
1328
|
+
"2024-09-16T20:10:59.000000+09:00" # to: 集計期間の終了時刻
|
1329
|
+
))
|
1330
|
+
```
|
1331
|
+
|
1332
|
+
---
|
1333
|
+
`from`
|
1334
|
+
```json
|
1335
|
+
{
|
1336
|
+
"type": "string",
|
1337
|
+
"format": "date-time"
|
1338
|
+
}
|
1339
|
+
```
|
1340
|
+
集計する期間の開始時刻をISO8601形式で指定します。
|
1341
|
+
時刻は現在時刻、及び `to` で指定する時刻以前である必要があります。
|
1342
|
+
|
1343
|
+
---
|
1344
|
+
`to`
|
1345
|
+
```json
|
1346
|
+
{
|
1347
|
+
"type": "string",
|
1348
|
+
"format": "date-time"
|
1349
|
+
}
|
1350
|
+
```
|
1351
|
+
集計する期間の終了時刻をISO8601形式で指定します。
|
1352
|
+
時刻は現在時刻、及び `from` で指定する時刻の間である必要があります。
|
1353
|
+
|
1354
|
+
---
|
1355
|
+
成功したときは[UserStatsOperation](#user-stats-operation)オブジェクトを返します
|
1356
|
+
### Transfer
|
1357
|
+
<a name="get-account-transfer-summary"></a>
|
1358
|
+
####
|
1359
|
+
ウォレットを指定して取引明細種別毎の集計を返す
|
1360
|
+
```ruby
|
1361
|
+
response = $client.send(Pokepay::Request::GetAccountTransferSummary.new(
|
1362
|
+
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # account_id: ウォレットID
|
1363
|
+
from: "2024-12-27T07:40:11.000000+09:00", # 集計期間の開始時刻
|
1364
|
+
to: "2025-04-08T20:21:35.000000+09:00", # 集計期間の終了時刻
|
1365
|
+
transfer_types: ["topup", "payment"] # 取引明細種別 (複数指定可)
|
1366
|
+
))
|
1367
|
+
```
|
1368
|
+
|
1369
|
+
---
|
1370
|
+
`account_id`
|
1371
|
+
```json
|
1372
|
+
{
|
1373
|
+
"type": "string",
|
1374
|
+
"format": "uuid"
|
1375
|
+
}
|
1376
|
+
```
|
1377
|
+
ウォレットIDです。
|
1378
|
+
|
1379
|
+
ここで指定したウォレットIDの取引明細レベルでの集計を取得します。
|
1380
|
+
|
1381
|
+
---
|
1382
|
+
`transfer_types`
|
1383
|
+
```json
|
1384
|
+
{
|
1385
|
+
"type": "array",
|
1386
|
+
"items": {
|
1387
|
+
"type": "string",
|
1388
|
+
"enum": {
|
1389
|
+
"payment": "topup",
|
1390
|
+
"campaign-topup": "use-coupon",
|
1391
|
+
"refund-payment": "refund-topup",
|
1392
|
+
"refund-campaign": "refund-coupon",
|
1393
|
+
"exchange-inflow": "exchange-outflow",
|
1394
|
+
"refund-exchange-inflow": "refund-exchange-outflow"
|
1395
|
+
}
|
1396
|
+
}
|
1397
|
+
}
|
1398
|
+
```
|
1399
|
+
取引明細の種別でフィルターします。
|
1400
|
+
以下の種別を指定できます。
|
1401
|
+
|
1402
|
+
- payment
|
1403
|
+
エンドユーザーから店舗への送金取引(支払い取引)
|
1404
|
+
- topup
|
1405
|
+
店舗からエンドユーザーへの送金取引(チャージ取引)
|
1406
|
+
- campaign-topup
|
1407
|
+
キャンペーンによるエンドユーザーへのポイント付与取引(ポイントチャージ)
|
1408
|
+
- use-coupon
|
1409
|
+
支払い時のクーポン使用による値引き取引
|
1410
|
+
- refund-payment
|
1411
|
+
支払い取引に対するキャンセル取引
|
1412
|
+
- refund-topup
|
1413
|
+
チャージ取引に対するキャンセル取引
|
1414
|
+
- refund-campaign
|
1415
|
+
キャンペーンによるポイント付与取引に対するキャンセル取引
|
1416
|
+
- refund-coupon
|
1417
|
+
クーポン使用による値引き取引に対するキャンセル取引
|
1418
|
+
- exchange-inflow
|
1419
|
+
交換による他マネーからの流入取引
|
1420
|
+
- exchange-outflow
|
1421
|
+
交換による他マネーへの流出取引
|
1422
|
+
- refund-exchange-inflow
|
1423
|
+
交換による他マネーからの流入取引に対するキャンセル取引
|
1424
|
+
- refund-exchange-outflow
|
1425
|
+
交換による他マネーへの流出取引に対するキャンセル取引
|
1426
|
+
|
1427
|
+
---
|
1428
|
+
成功したときは[AccountTransferSummary](#account-transfer-summary)オブジェクトを返します
|
1290
1429
|
<a name="list-transfers"></a>
|
1291
1430
|
####
|
1292
1431
|
```ruby
|
1293
1432
|
response = $client.send(Pokepay::Request::ListTransfers.new(
|
1294
|
-
from: "
|
1295
|
-
to: "
|
1296
|
-
page:
|
1297
|
-
per_page:
|
1433
|
+
from: "2024-11-08T00:10:16.000000+09:00",
|
1434
|
+
to: "2021-09-21T12:28:04.000000+09:00",
|
1435
|
+
page: 4030,
|
1436
|
+
per_page: 3629,
|
1298
1437
|
shop_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
1299
|
-
shop_name: "
|
1438
|
+
shop_name: "qDn2oMYRFh8cqnV2spFoKb7jYgx3gTJKy6dBb3ykYYVRZ4jdyfDGYQa0QPCC60HT399N8hkxoSQFYDUU0HuG332kYdREQC39nZBUv4F8J7UzyDYEv7bctcmIqdmvTV8RBzp0gixsKZWoUeORL98QDv9TW",
|
1300
1439
|
customer_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
1301
|
-
customer_name: "
|
1440
|
+
customer_name: "tonru5DxxR1kiR4daTST401zYU9O5bmxo5R8HDeIrg38UDixRQOsOxJyiut30oRsSLi4FAWjvNFlMGhO7MjoFiHLtN9Yqy7R5Sel4rqjqD6mB2gz0FIdNSbIrXOBo1I3rdkLB5vuUQlHHWHdfJKJGJOe4o3A7Ast7GZKKewMQbpvWdRIf0j2",
|
1302
1441
|
transaction_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
1303
1442
|
private_money_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
|
1304
1443
|
is_modified: false,
|
1305
|
-
transaction_types: ["topup", "payment"],
|
1306
|
-
transfer_types: ["
|
1444
|
+
transaction_types: ["expire", "cashback", "topup", "payment", "exchange"],
|
1445
|
+
transfer_types: ["payment", "transfer", "campaign", "expire", "coupon", "cashback", "topup", "exchange"], # 取引明細の種類でフィルターします。
|
1307
1446
|
description: "店頭QRコードによる支払い" # 取引詳細説明文
|
1308
1447
|
))
|
1309
1448
|
```
|
@@ -1363,6 +1502,272 @@ response = $client.send(Pokepay::Request::ListTransfers.new(
|
|
1363
1502
|
|
1364
1503
|
---
|
1365
1504
|
成功したときは[PaginatedTransfers](#paginated-transfers)オブジェクトを返します
|
1505
|
+
<a name="list-transfers-v2"></a>
|
1506
|
+
####
|
1507
|
+
```ruby
|
1508
|
+
response = $client.send(Pokepay::Request::ListTransfersV2.new(
|
1509
|
+
shop_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # 店舗ID
|
1510
|
+
shop_name: "bzWuGj28bjzoMkUfQZyG6ql9kvIc3ugQfVcwKEOAlMUYblAnOJUw5uYgLUj2LWIHcZ5Kh7Upt9fM2ThdFR4ZGmC3lYSdkRdIHlBo7iM", # 店舗名
|
1511
|
+
customer_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # エンドユーザーID
|
1512
|
+
customer_name: "slQeLzTg9FCP6boJkANEWZ0xko5rtXdkjCZ6KXkiMx1kHTVbpRx79qoFTViWGk7rsKgu2ihoMxDsfU3TC1A8fV5nkzyaMo6HNFjN16Mt1NNT0LSnWyLCIiaSmxOiabyCFBUZkKwMvzRhZdC9PIbxRIokrSMcAe6DLpfhwjho9qAj035em2B0e1zQxL4LWrEkUrKUADYa", # エンドユーザー名
|
1513
|
+
transaction_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # 取引ID
|
1514
|
+
private_money_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # マネーID
|
1515
|
+
is_modified: false, # キャンセルフラグ
|
1516
|
+
transaction_types: ["expire", "payment", "topup", "exchange"], # 取引種別 (複数指定可)、チャージ=topup、支払い=payment
|
1517
|
+
next_page_cursor_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # 次ページへ遷移する際に起点となるtransferのID
|
1518
|
+
prev_page_cursor_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # 前ページへ遷移する際に起点となるtransferのID
|
1519
|
+
per_page: 50, # 1ページ分の取引数
|
1520
|
+
transfer_types: ["cashback", "coupon", "transfer", "topup"], # 取引明細種別 (複数指定可)
|
1521
|
+
description: "店頭QRコードによる支払い", # 取引詳細説明文
|
1522
|
+
from: "2022-12-06T00:04:18.000000+09:00", # 開始日時
|
1523
|
+
to: "2018-02-12T04:05:18.000000+09:00" # 終了日時
|
1524
|
+
))
|
1525
|
+
```
|
1526
|
+
|
1527
|
+
---
|
1528
|
+
`shop_id`
|
1529
|
+
```json
|
1530
|
+
{
|
1531
|
+
"type": "string",
|
1532
|
+
"format": "uuid"
|
1533
|
+
}
|
1534
|
+
```
|
1535
|
+
店舗IDです。
|
1536
|
+
|
1537
|
+
フィルターとして使われ、指定された店舗での取引のみ一覧に表示されます。
|
1538
|
+
|
1539
|
+
---
|
1540
|
+
`shop_name`
|
1541
|
+
```json
|
1542
|
+
{
|
1543
|
+
"type": "string",
|
1544
|
+
"maxLength": 256
|
1545
|
+
}
|
1546
|
+
```
|
1547
|
+
店舗名です。
|
1548
|
+
|
1549
|
+
フィルターとして使われ、入力された名前に部分一致する店舗での取引のみ一覧に表示されます。
|
1550
|
+
|
1551
|
+
---
|
1552
|
+
`customer_id`
|
1553
|
+
```json
|
1554
|
+
{
|
1555
|
+
"type": "string",
|
1556
|
+
"format": "uuid"
|
1557
|
+
}
|
1558
|
+
```
|
1559
|
+
エンドユーザーIDです。
|
1560
|
+
|
1561
|
+
フィルターとして使われ、指定されたエンドユーザーの取引のみ一覧に表示されます。
|
1562
|
+
|
1563
|
+
---
|
1564
|
+
`customer_name`
|
1565
|
+
```json
|
1566
|
+
{
|
1567
|
+
"type": "string",
|
1568
|
+
"maxLength": 256
|
1569
|
+
}
|
1570
|
+
```
|
1571
|
+
エンドユーザー名です。
|
1572
|
+
|
1573
|
+
フィルターとして使われ、入力された名前に部分一致するエンドユーザーでの取引のみ一覧に表示されます。
|
1574
|
+
|
1575
|
+
---
|
1576
|
+
`transaction_id`
|
1577
|
+
```json
|
1578
|
+
{
|
1579
|
+
"type": "string",
|
1580
|
+
"format": "uuid"
|
1581
|
+
}
|
1582
|
+
```
|
1583
|
+
取引IDです。
|
1584
|
+
|
1585
|
+
フィルターとして使われ、指定された取引IDに部分一致(前方一致)する取引のみが一覧に表示されます。
|
1586
|
+
|
1587
|
+
---
|
1588
|
+
`private_money_id`
|
1589
|
+
```json
|
1590
|
+
{
|
1591
|
+
"type": "string",
|
1592
|
+
"format": "uuid"
|
1593
|
+
}
|
1594
|
+
```
|
1595
|
+
マネーIDです。
|
1596
|
+
|
1597
|
+
指定したマネーでの取引が一覧に表示されます。
|
1598
|
+
|
1599
|
+
---
|
1600
|
+
`is_modified`
|
1601
|
+
```json
|
1602
|
+
{ "type": "boolean" }
|
1603
|
+
```
|
1604
|
+
キャンセルフラグです。
|
1605
|
+
|
1606
|
+
これにtrueを指定するとキャンセルされた取引のみ一覧に表示されます。
|
1607
|
+
デフォルト値はfalseで、キャンセルの有無にかかわらず一覧に表示されます。
|
1608
|
+
|
1609
|
+
---
|
1610
|
+
`transaction_types`
|
1611
|
+
```json
|
1612
|
+
{
|
1613
|
+
"type": "array",
|
1614
|
+
"items": {
|
1615
|
+
"type": "string",
|
1616
|
+
"enum": {
|
1617
|
+
"topup": "payment",
|
1618
|
+
"transfer": "exchange",
|
1619
|
+
"cashback": "expire"
|
1620
|
+
}
|
1621
|
+
}
|
1622
|
+
}
|
1623
|
+
```
|
1624
|
+
取引の種類でフィルターします。
|
1625
|
+
|
1626
|
+
以下の種類を指定できます。
|
1627
|
+
|
1628
|
+
1. topup
|
1629
|
+
店舗からエンドユーザーへの送金取引(チャージ)
|
1630
|
+
|
1631
|
+
2. payment
|
1632
|
+
エンドユーザーから店舗への送金取引(支払い)
|
1633
|
+
|
1634
|
+
3. exchange-outflow
|
1635
|
+
他マネーへの流出
|
1636
|
+
private_money_idが指定されたとき、そのマネーから見て流出方向の交換取引が抽出されます。
|
1637
|
+
private_money_idを省略した場合は表示されません。
|
1638
|
+
|
1639
|
+
4. exchange-inflow
|
1640
|
+
他マネーからの流入
|
1641
|
+
private_money_idが指定されたとき、そのマネーから見て流入方向の交換取引が抽出されます。
|
1642
|
+
private_money_idを省略した場合は表示されません。
|
1643
|
+
|
1644
|
+
5. cashback
|
1645
|
+
退会時返金取引
|
1646
|
+
|
1647
|
+
6. expire
|
1648
|
+
退会時失効取引
|
1649
|
+
|
1650
|
+
---
|
1651
|
+
`next_page_cursor_id`
|
1652
|
+
```json
|
1653
|
+
{
|
1654
|
+
"type": "string",
|
1655
|
+
"format": "uuid"
|
1656
|
+
}
|
1657
|
+
```
|
1658
|
+
次ページへ遷移する際に起点となるtransferのID(前ページの末尾要素のID)です。
|
1659
|
+
本APIのレスポンスにもnext_page_cursor_idが含まれており、これがnull値の場合は最後のページであることを意味します。
|
1660
|
+
UUIDである場合は次のページが存在することを意味し、このnext_page_cursor_idをリクエストパラメータに含めることで次ページに遷移します。
|
1661
|
+
|
1662
|
+
next_page_cursor_idのtransfer自体は次のページには含まれません。
|
1663
|
+
|
1664
|
+
---
|
1665
|
+
`prev_page_cursor_id`
|
1666
|
+
```json
|
1667
|
+
{
|
1668
|
+
"type": "string",
|
1669
|
+
"format": "uuid"
|
1670
|
+
}
|
1671
|
+
```
|
1672
|
+
前ページへ遷移する際に起点となるtransferのID(次ページの先頭要素のID)です。
|
1673
|
+
|
1674
|
+
本APIのレスポンスにもprev_page_cursor_idが含まれており、これがnull値の場合は先頭のページであることを意味します。
|
1675
|
+
UUIDである場合は前のページが存在することを意味し、このprev_page_cursor_idをリクエストパラメータに含めることで前ページに遷移します。
|
1676
|
+
|
1677
|
+
prev_page_cursor_idのtransfer自体は前のページには含まれません。
|
1678
|
+
|
1679
|
+
---
|
1680
|
+
`per_page`
|
1681
|
+
```json
|
1682
|
+
{
|
1683
|
+
"type": "integer",
|
1684
|
+
"minimum": 1,
|
1685
|
+
"maximum": 1000
|
1686
|
+
}
|
1687
|
+
```
|
1688
|
+
1ページ分の取引数です。
|
1689
|
+
|
1690
|
+
デフォルト値は50です。
|
1691
|
+
|
1692
|
+
---
|
1693
|
+
`transfer_types`
|
1694
|
+
```json
|
1695
|
+
{
|
1696
|
+
"type": "array",
|
1697
|
+
"items": {
|
1698
|
+
"type": "string",
|
1699
|
+
"enum": {
|
1700
|
+
"topup": "payment",
|
1701
|
+
"exchange": "transfer",
|
1702
|
+
"coupon": "campaign",
|
1703
|
+
"cashback": "expire"
|
1704
|
+
}
|
1705
|
+
}
|
1706
|
+
}
|
1707
|
+
```
|
1708
|
+
取引明細の種類でフィルターします。
|
1709
|
+
|
1710
|
+
以下の種類を指定できます。
|
1711
|
+
|
1712
|
+
1. topup
|
1713
|
+
店舗からエンドユーザーへの送金取引(チャージ)、またはそのキャンセル取引
|
1714
|
+
|
1715
|
+
2. payment
|
1716
|
+
エンドユーザーから店舗への送金取引(支払い)、またはそのキャンセル取引
|
1717
|
+
|
1718
|
+
3. exchange
|
1719
|
+
他マネーへの流出/流入
|
1720
|
+
|
1721
|
+
4. campaign
|
1722
|
+
取引に対するポイント還元キャンペーンによるポイント付与、またはそのキャンセル取引
|
1723
|
+
|
1724
|
+
5. coupon
|
1725
|
+
クーポンによる値引き処理、またはそのキャンセル取引
|
1726
|
+
|
1727
|
+
6. cashback
|
1728
|
+
退会時の返金取引
|
1729
|
+
|
1730
|
+
7. expire
|
1731
|
+
退会時失効取引
|
1732
|
+
|
1733
|
+
---
|
1734
|
+
`description`
|
1735
|
+
```json
|
1736
|
+
{
|
1737
|
+
"type": "string",
|
1738
|
+
"maxLength": 200
|
1739
|
+
}
|
1740
|
+
```
|
1741
|
+
取引詳細を指定の取引詳細説明文でフィルターします。
|
1742
|
+
|
1743
|
+
取引詳細説明文が完全一致する取引のみ抽出されます。取引詳細説明文は最大200文字で記録されています。
|
1744
|
+
|
1745
|
+
---
|
1746
|
+
`from`
|
1747
|
+
```json
|
1748
|
+
{
|
1749
|
+
"type": "string",
|
1750
|
+
"format": "date-time"
|
1751
|
+
}
|
1752
|
+
```
|
1753
|
+
抽出期間の開始日時です。
|
1754
|
+
|
1755
|
+
フィルターとして使われ、開始日時以降に発生した取引のみ一覧に表示されます。
|
1756
|
+
|
1757
|
+
---
|
1758
|
+
`to`
|
1759
|
+
```json
|
1760
|
+
{
|
1761
|
+
"type": "string",
|
1762
|
+
"format": "date-time"
|
1763
|
+
}
|
1764
|
+
```
|
1765
|
+
抽出期間の終了日時です。
|
1766
|
+
|
1767
|
+
フィルターとして使われ、終了日時以前に発生した取引のみ一覧に表示されます。
|
1768
|
+
|
1769
|
+
---
|
1770
|
+
成功したときは[PaginatedTransfersV2](#paginated-transfers-v2)オブジェクトを返します
|
1366
1771
|
### Check
|
1367
1772
|
店舗ユーザが発行し、エンドユーザーがポケペイアプリから読み取ることでチャージ取引が発生するQRコードです。
|
1368
1773
|
|
@@ -1372,6 +1777,46 @@ response = $client.send(Pokepay::Request::ListTransfers.new(
|
|
1372
1777
|
|
1373
1778
|
QRコードを読み取る方法以外にも、このURLリンクを直接スマートフォン(iOS/Android)上で開くことによりアプリが起動して取引が行われます。(注意: 上記URLはsandbox環境であるため、アプリもsandbox環境のものである必要があります) 上記URL中の `xxxxxxxx-xxxx-xxxxxxxxx-xxxxxxxxxxxx` の部分がチャージQRコードのIDです。
|
1374
1779
|
|
1780
|
+
<a name="create-check"></a>
|
1781
|
+
#### チャージQRコードの発行
|
1782
|
+
```ruby
|
1783
|
+
response = $client.send(Pokepay::Request::CreateCheck.new(
|
1784
|
+
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # account_id: 送金元の店舗アカウントID
|
1785
|
+
money_amount: 3666.0, # 付与マネー額
|
1786
|
+
point_amount: 2047.0, # 付与ポイント額
|
1787
|
+
description: "test check", # 説明文(アプリ上で取引の説明文として表示される)
|
1788
|
+
is_onetime: true, # ワンタイムかどうか。真の場合1度読み込まれた時点でそのチャージQRは失効する(デフォルト値は真)
|
1789
|
+
usage_limit: 4725, # ワンタイムでない場合、複数ユーザから読み取られ得る。その場合の最大読み取り回数
|
1790
|
+
expires_at: "2019-12-04T11:27:19.000000+09:00", # チャージQR自体の失効日時
|
1791
|
+
point_expires_at: "2016-01-26T14:10:39.000000+09:00", # チャージQRによって付与されるポイントの失効日時
|
1792
|
+
point_expires_in_days: 60, # チャージQRによって付与されるポイントの有効期限(相対指定、単位は日)
|
1793
|
+
bear_point_account: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" # ポイント額を負担する店舗アカウントのID
|
1794
|
+
))
|
1795
|
+
```
|
1796
|
+
`money_amount`と`point_amount`の少なくとも一方は指定する必要があります。
|
1797
|
+
|
1798
|
+
|
1799
|
+
---
|
1800
|
+
`is_onetime`
|
1801
|
+
```json
|
1802
|
+
{ "type": "boolean" }
|
1803
|
+
```
|
1804
|
+
チャージQRコードが一度の読み取りで失効するときに`true`にします。デフォルト値は`true`です。
|
1805
|
+
`false`の場合、そのチャージQRコードは1ユーザについては1回きりですが、複数ユーザによって読み取り可能なQRコードになります。
|
1806
|
+
|
1807
|
+
|
1808
|
+
---
|
1809
|
+
`usage_limit`
|
1810
|
+
```json
|
1811
|
+
{ "type": "integer" }
|
1812
|
+
```
|
1813
|
+
複数ユーザによって読み取り可能なチャージQRコードの読み取り回数に制限をつけるために指定します。
|
1814
|
+
省略すると無制限に読み取り可能なチャージQRコードになります。
|
1815
|
+
チャージQRコードは管理画面からいつでも無効化(有効化)することができます。
|
1816
|
+
|
1817
|
+
|
1818
|
+
---
|
1819
|
+
成功したときは[Check](#check)オブジェクトを返します
|
1375
1820
|
<a name="create-topup-transaction-with-check"></a>
|
1376
1821
|
#### チャージQRコードを読み取ることでチャージする
|
1377
1822
|
通常チャージQRコードはエンドユーザーのアプリによって読み取られ、アプリとポケペイサーバとの直接通信によって取引が作られます。 もしエンドユーザーとの通信をパートナーのサーバのみに限定したい場合、パートナーのサーバがチャージQRの情報をエンドユーザーから代理受けして、サーバ間連携APIによって実際のチャージ取引をリクエストすることになります。
|
@@ -1418,18 +1863,18 @@ QRコード生成時に送金元店舗のウォレット情報や、送金額な
|
|
1418
1863
|
支払いQRコード一覧を表示します。
|
1419
1864
|
```ruby
|
1420
1865
|
response = $client.send(Pokepay::Request::ListBills.new(
|
1421
|
-
page:
|
1422
|
-
per_page:
|
1423
|
-
bill_id: "
|
1866
|
+
page: 5194, # ページ番号
|
1867
|
+
per_page: 366, # 1ページの表示数
|
1868
|
+
bill_id: "Q77By", # 支払いQRコードのID
|
1424
1869
|
private_money_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # マネーID
|
1425
|
-
organization_code: "
|
1870
|
+
organization_code: "---6-e", # 組織コード
|
1426
1871
|
description: "test bill", # 取引説明文
|
1427
|
-
created_from: "
|
1428
|
-
created_to: "
|
1872
|
+
created_from: "2023-11-13T16:02:56.000000+09:00", # 作成日時(起点)
|
1873
|
+
created_to: "2022-10-18T15:01:29.000000+09:00", # 作成日時(終点)
|
1429
1874
|
shop_name: "bill test shop1", # 店舗名
|
1430
1875
|
shop_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # 店舗ID
|
1431
|
-
lower_limit_amount:
|
1432
|
-
upper_limit_amount:
|
1876
|
+
lower_limit_amount: 3786, # 金額の範囲によるフィルタ(下限)
|
1877
|
+
upper_limit_amount: 2781, # 金額の範囲によるフィルタ(上限)
|
1433
1878
|
is_disabled: true # 支払いQRコードが無効化されているかどうか
|
1434
1879
|
))
|
1435
1880
|
```
|
@@ -1574,7 +2019,7 @@ response = $client.send(Pokepay::Request::ListBills.new(
|
|
1574
2019
|
response = $client.send(Pokepay::Request::CreateBill.new(
|
1575
2020
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: 支払いマネーのマネーID
|
1576
2021
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # shop_id: 支払い先(受け取り人)の店舗ID
|
1577
|
-
amount:
|
2022
|
+
amount: 4980.0, # 支払い額
|
1578
2023
|
description: "test bill" # 説明文(アプリ上で取引の説明文として表示される)
|
1579
2024
|
))
|
1580
2025
|
```
|
@@ -1598,7 +2043,7 @@ response = $client.send(Pokepay::Request::CreateBill.new(
|
|
1598
2043
|
```ruby
|
1599
2044
|
response = $client.send(Pokepay::Request::UpdateBill.new(
|
1600
2045
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # bill_id: 支払いQRコードのID
|
1601
|
-
amount:
|
2046
|
+
amount: 630.0, # 支払い額
|
1602
2047
|
description: "test bill", # 説明文
|
1603
2048
|
is_disabled: true # 無効化されているかどうか
|
1604
2049
|
))
|
@@ -1663,9 +2108,9 @@ Cashtrayを作成します。
|
|
1663
2108
|
response = $client.send(Pokepay::Request::CreateCashtray.new(
|
1664
2109
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
1665
2110
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # shop_id: 店舗ユーザーID
|
1666
|
-
|
2111
|
+
5106.0, # amount: 金額
|
1667
2112
|
description: "たい焼き(小倉)", # 取引履歴に表示する説明文
|
1668
|
-
expires_in:
|
2113
|
+
expires_in: 6496 # 失効時間(秒)
|
1669
2114
|
))
|
1670
2115
|
```
|
1671
2116
|
|
@@ -1826,9 +2271,9 @@ Cashtrayの内容を更新します。bodyパラメーターは全て省略可
|
|
1826
2271
|
```ruby
|
1827
2272
|
response = $client.send(Pokepay::Request::UpdateCashtray.new(
|
1828
2273
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # cashtray_id: CashtrayのID
|
1829
|
-
amount:
|
2274
|
+
amount: 4728.0, # 金額
|
1830
2275
|
description: "たい焼き(小倉)", # 取引履歴に表示する説明文
|
1831
|
-
expires_in:
|
2276
|
+
expires_in: 3819 # 失効時間(秒)
|
1832
2277
|
))
|
1833
2278
|
```
|
1834
2279
|
|
@@ -1899,13 +2344,19 @@ response = $client.send(Pokepay::Request::GetAccount.new(
|
|
1899
2344
|
成功したときは[AccountDetail](#account-detail)オブジェクトを返します
|
1900
2345
|
<a name="update-account"></a>
|
1901
2346
|
#### ウォレット情報を更新する
|
1902
|
-
|
2347
|
+
ウォレットの状態を更新します。
|
2348
|
+
以下の項目が変更できます。
|
2349
|
+
|
2350
|
+
- ウォレットの凍結/凍結解除の切り替え(エンドユーザー、店舗ユーザー共通)
|
2351
|
+
- 店舗でチャージ可能かどうか(店舗ユーザのみ)
|
2352
|
+
|
2353
|
+
エンドユーザーのウォレット情報更新には UpdateCustomerAccount が使用できます。
|
1903
2354
|
```ruby
|
1904
2355
|
response = $client.send(Pokepay::Request::UpdateAccount.new(
|
1905
2356
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # account_id: ウォレットID
|
1906
2357
|
is_suspended: false, # ウォレットが凍結されているかどうか
|
1907
2358
|
status: "active", # ウォレット状態
|
1908
|
-
can_transfer_topup:
|
2359
|
+
can_transfer_topup: false # チャージ可能かどうか
|
1909
2360
|
))
|
1910
2361
|
```
|
1911
2362
|
|
@@ -1984,11 +2435,11 @@ response = $client.send(Pokepay::Request::DeleteAccount.new(
|
|
1984
2435
|
```ruby
|
1985
2436
|
response = $client.send(Pokepay::Request::ListAccountBalances.new(
|
1986
2437
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # account_id: ウォレットID
|
1987
|
-
page:
|
1988
|
-
per_page:
|
1989
|
-
expires_at_from: "
|
1990
|
-
expires_at_to: "
|
1991
|
-
direction: "
|
2438
|
+
page: 1587, # ページ番号
|
2439
|
+
per_page: 3237, # 1ページ分の取引数
|
2440
|
+
expires_at_from: "2024-02-28T15:45:22.000000+09:00", # 有効期限の期間によるフィルター(開始時点)
|
2441
|
+
expires_at_to: "2022-07-08T07:38:31.000000+09:00", # 有効期限の期間によるフィルター(終了時点)
|
2442
|
+
direction: "asc" # 有効期限によるソート順序
|
1992
2443
|
))
|
1993
2444
|
```
|
1994
2445
|
|
@@ -2062,11 +2513,11 @@ response = $client.send(Pokepay::Request::ListAccountBalances.new(
|
|
2062
2513
|
```ruby
|
2063
2514
|
response = $client.send(Pokepay::Request::ListAccountExpiredBalances.new(
|
2064
2515
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # account_id: ウォレットID
|
2065
|
-
page:
|
2066
|
-
per_page:
|
2067
|
-
expires_at_from: "
|
2068
|
-
expires_at_to: "
|
2069
|
-
direction: "
|
2516
|
+
page: 7573, # ページ番号
|
2517
|
+
per_page: 483, # 1ページ分の取引数
|
2518
|
+
expires_at_from: "2018-03-21T18:13:55.000000+09:00", # 有効期限の期間によるフィルター(開始時点)
|
2519
|
+
expires_at_to: "2025-07-28T15:04:14.000000+09:00", # 有効期限の期間によるフィルター(終了時点)
|
2520
|
+
direction: "desc" # 有効期限によるソート順序
|
2070
2521
|
))
|
2071
2522
|
```
|
2072
2523
|
|
@@ -2135,14 +2586,15 @@ response = $client.send(Pokepay::Request::ListAccountExpiredBalances.new(
|
|
2135
2586
|
---
|
2136
2587
|
成功したときは[PaginatedAccountBalance](#paginated-account-balance)オブジェクトを返します
|
2137
2588
|
<a name="update-customer-account"></a>
|
2138
|
-
####
|
2139
|
-
|
2589
|
+
#### エンドユーザーのウォレット情報を更新する
|
2590
|
+
エンドユーザーのウォレットの状態を更新します。
|
2140
2591
|
```ruby
|
2141
2592
|
response = $client.send(Pokepay::Request::UpdateCustomerAccount.new(
|
2142
2593
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # account_id: ウォレットID
|
2143
|
-
status: "
|
2144
|
-
account_name: "
|
2145
|
-
external_id: "
|
2594
|
+
status: "active", # ウォレット状態
|
2595
|
+
account_name: "lI7ca3oyQQIsUl3rCM2ZMpE4WDor4IADTHdTPsjhUsWbuhnbIUFlfvobOclFXKfvdQivs3hjtD1VYnThEQOLtlkRPIAeI3C1kLwoSJ0t0xwzgZ3SAsjpAuPQwOMEx", # アカウント名
|
2596
|
+
external_id: "C1w6ifl9ZUstqj7jJ1Xa", # 外部ID
|
2597
|
+
metadata: "{\"key1\":\"foo\",\"key2\":\"bar\"}" # ウォレットに付加するメタデータ
|
2146
2598
|
))
|
2147
2599
|
```
|
2148
2600
|
|
@@ -2188,6 +2640,31 @@ response = $client.send(Pokepay::Request::UpdateCustomerAccount.new(
|
|
2188
2640
|
```
|
2189
2641
|
変更する外部IDです。
|
2190
2642
|
|
2643
|
+
---
|
2644
|
+
`metadata`
|
2645
|
+
```json
|
2646
|
+
{
|
2647
|
+
"type": "string",
|
2648
|
+
"format": "json"
|
2649
|
+
}
|
2650
|
+
```
|
2651
|
+
ウォレットに付加するメタデータをJSON文字列で指定します。
|
2652
|
+
指定できるJSON文字列には以下のような制約があります。
|
2653
|
+
- フラットな構造のJSONを文字列化したものであること。
|
2654
|
+
- keyは最大32文字の文字列(同じkeyを複数指定することはできません)
|
2655
|
+
- valueには128文字以下の文字列が指定できます
|
2656
|
+
|
2657
|
+
更新時に指定した内容でメタデータ全体が置き換えられることに注意してください。
|
2658
|
+
例えば、元々のメタデータが以下だったときに、
|
2659
|
+
|
2660
|
+
'{"key1":"foo","key2":"bar"}'
|
2661
|
+
|
2662
|
+
更新APIで以下のように更新するとします。
|
2663
|
+
|
2664
|
+
'{"key1":"baz"}'
|
2665
|
+
|
2666
|
+
このときkey1はfooからbazに更新され、key2に対するデータは消去されます。
|
2667
|
+
|
2191
2668
|
---
|
2192
2669
|
成功したときは[AccountWithUser](#account-with-user)オブジェクトを返します
|
2193
2670
|
<a name="get-customer-accounts"></a>
|
@@ -2196,15 +2673,15 @@ response = $client.send(Pokepay::Request::UpdateCustomerAccount.new(
|
|
2196
2673
|
```ruby
|
2197
2674
|
response = $client.send(Pokepay::Request::GetCustomerAccounts.new(
|
2198
2675
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
2199
|
-
page:
|
2200
|
-
per_page:
|
2201
|
-
created_at_from: "
|
2202
|
-
created_at_to: "2019-
|
2203
|
-
is_suspended:
|
2204
|
-
status: "
|
2205
|
-
external_id: "
|
2206
|
-
tel: "
|
2207
|
-
email: "
|
2676
|
+
page: 7035, # ページ番号
|
2677
|
+
per_page: 3301, # 1ページ分のウォレット数
|
2678
|
+
created_at_from: "2016-05-19T22:14:32.000000+09:00", # ウォレット作成日によるフィルター(開始時点)
|
2679
|
+
created_at_to: "2019-01-09T22:39:55.000000+09:00", # ウォレット作成日によるフィルター(終了時点)
|
2680
|
+
is_suspended: true, # ウォレットが凍結状態かどうかでフィルターする
|
2681
|
+
status: "suspended", # ウォレット状態
|
2682
|
+
external_id: "E8si7WktomTSIs3sss0bSZ", # 外部ID
|
2683
|
+
tel: "030404-7685", # エンドユーザーの電話番号
|
2684
|
+
email: "0iBD2et6R8@9vRe.com" # エンドユーザーのメールアドレス
|
2208
2685
|
))
|
2209
2686
|
```
|
2210
2687
|
|
@@ -2310,14 +2787,17 @@ response = $client.send(Pokepay::Request::GetCustomerAccounts.new(
|
|
2310
2787
|
---
|
2311
2788
|
成功したときは[PaginatedAccountWithUsers](#paginated-account-with-users)オブジェクトを返します
|
2312
2789
|
<a name="create-customer-account"></a>
|
2313
|
-
####
|
2314
|
-
|
2790
|
+
#### 新規エンドユーザーをウォレットと共に追加する
|
2791
|
+
指定したマネーのウォレットを作成し、同時にそのウォレットを保有するユーザも新規に作成します。
|
2792
|
+
このAPIにより作成されたユーザは認証情報を持たないため、モバイルSDKやポケペイ標準アプリからはログインすることはできません。
|
2793
|
+
Partner APIのみから操作可能な特殊なユーザになります。
|
2794
|
+
システム全体をPartner APIのみで構成する場合にのみ使用してください。
|
2315
2795
|
```ruby
|
2316
2796
|
response = $client.send(Pokepay::Request::CreateCustomerAccount.new(
|
2317
2797
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
2318
2798
|
user_name: "ポケペイ太郎", # ユーザー名
|
2319
2799
|
account_name: "ポケペイ太郎のアカウント", # アカウント名
|
2320
|
-
external_id: "
|
2800
|
+
external_id: "YIZbMh6MfShA8D4Ev7O7TGT70LQ2epxhXvfJrqwCw" # 外部ID
|
2321
2801
|
))
|
2322
2802
|
```
|
2323
2803
|
|
@@ -2371,10 +2851,10 @@ PAPIクライアントシステムから利用するPokepayユーザーのIDで
|
|
2371
2851
|
```ruby
|
2372
2852
|
response = $client.send(Pokepay::Request::GetShopAccounts.new(
|
2373
2853
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
2374
|
-
page:
|
2375
|
-
per_page:
|
2376
|
-
created_at_from: "
|
2377
|
-
created_at_to: "
|
2854
|
+
page: 812, # ページ番号
|
2855
|
+
per_page: 379, # 1ページ分のウォレット数
|
2856
|
+
created_at_from: "2023-02-09T04:32:37.000000+09:00", # ウォレット作成日によるフィルター(開始時点)
|
2857
|
+
created_at_to: "2024-06-26T08:50:23.000000+09:00", # ウォレット作成日によるフィルター(終了時点)
|
2378
2858
|
is_suspended: false # ウォレットが凍結状態かどうかでフィルターする
|
2379
2859
|
))
|
2380
2860
|
```
|
@@ -2449,9 +2929,9 @@ response = $client.send(Pokepay::Request::ListCustomerTransactions.new(
|
|
2449
2929
|
sender_customer_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # 送金エンドユーザーID
|
2450
2930
|
receiver_customer_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # 受取エンドユーザーID
|
2451
2931
|
type: "transfer", # 取引種別
|
2452
|
-
is_modified:
|
2453
|
-
from: "2019-
|
2454
|
-
to: "
|
2932
|
+
is_modified: false, # キャンセル済みかどうか
|
2933
|
+
from: "2019-04-18T16:04:36.000000+09:00", # 開始日時
|
2934
|
+
to: "2022-11-03T14:24:11.000000+09:00", # 終了日時
|
2455
2935
|
page: 1, # ページ番号
|
2456
2936
|
per_page: 50 # 1ページ分の取引数
|
2457
2937
|
))
|
@@ -2587,11 +3067,11 @@ response = $client.send(Pokepay::Request::ListShops.new(
|
|
2587
3067
|
organization_code: "pocketchange", # 組織コード
|
2588
3068
|
private_money_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # マネーID
|
2589
3069
|
name: "oxスーパー三田店", # 店舗名
|
2590
|
-
postal_code: "
|
3070
|
+
postal_code: "829-4114", # 店舗の郵便番号
|
2591
3071
|
address: "東京都港区芝...", # 店舗の住所
|
2592
|
-
tel: "
|
2593
|
-
email: "
|
2594
|
-
external_id: "
|
3072
|
+
tel: "01-63220", # 店舗の電話番号
|
3073
|
+
email: "jD2CPBEg6q@DXhS.com", # 店舗のメールアドレス
|
3074
|
+
external_id: "8hafJy0sD", # 店舗の外部ID
|
2595
3075
|
page: 1, # ページ番号
|
2596
3076
|
per_page: 50 # 1ページ分の取引数
|
2597
3077
|
))
|
@@ -2716,11 +3196,11 @@ response = $client.send(Pokepay::Request::ListShops.new(
|
|
2716
3196
|
```ruby
|
2717
3197
|
response = $client.send(Pokepay::Request::CreateShop.new(
|
2718
3198
|
"oxスーパー三田店", # shop_name: 店舗名
|
2719
|
-
shop_postal_code: "
|
3199
|
+
shop_postal_code: "9824004", # 店舗の郵便番号
|
2720
3200
|
shop_address: "東京都港区芝...", # 店舗の住所
|
2721
|
-
shop_tel: "
|
2722
|
-
shop_email: "
|
2723
|
-
shop_external_id: "
|
3201
|
+
shop_tel: "076532541", # 店舗の電話番号
|
3202
|
+
shop_email: "C8JZcqIcqZ@B2nk.com", # 店舗のメールアドレス
|
3203
|
+
shop_external_id: "hw5Vunnh29qWQZz14xB891rPV7FcdDe", # 店舗の外部ID
|
2724
3204
|
organization_code: "ox-supermarket" # 組織コード
|
2725
3205
|
))
|
2726
3206
|
```
|
@@ -2730,14 +3210,14 @@ response = $client.send(Pokepay::Request::CreateShop.new(
|
|
2730
3210
|
```ruby
|
2731
3211
|
response = $client.send(Pokepay::Request::CreateShopV2.new(
|
2732
3212
|
"oxスーパー三田店", # name: 店舗名
|
2733
|
-
postal_code: "
|
3213
|
+
postal_code: "2021634", # 店舗の郵便番号
|
2734
3214
|
address: "東京都港区芝...", # 店舗の住所
|
2735
|
-
tel: "
|
2736
|
-
email: "
|
2737
|
-
external_id: "
|
3215
|
+
tel: "0015-8224-4206", # 店舗の電話番号
|
3216
|
+
email: "lfzbfqKlns@G40w.com", # 店舗のメールアドレス
|
3217
|
+
external_id: "o0RT90mTv9imeNiY62Bc0n5yxxX", # 店舗の外部ID
|
2738
3218
|
organization_code: "ox-supermarket", # 組織コード
|
2739
|
-
private_money_ids: ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"], # 店舗で有効にするマネーIDの配列
|
2740
|
-
can_topup_private_money_ids: ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"] # 店舗でチャージ可能にするマネーIDの配列
|
3219
|
+
private_money_ids: ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"], # 店舗で有効にするマネーIDの配列
|
3220
|
+
can_topup_private_money_ids: ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"] # 店舗でチャージ可能にするマネーIDの配列
|
2741
3221
|
))
|
2742
3222
|
```
|
2743
3223
|
|
@@ -2808,11 +3288,11 @@ response = $client.send(Pokepay::Request::GetShop.new(
|
|
2808
3288
|
response = $client.send(Pokepay::Request::UpdateShop.new(
|
2809
3289
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # shop_id: 店舗ユーザーID
|
2810
3290
|
name: "oxスーパー三田店", # 店舗名
|
2811
|
-
postal_code: "
|
3291
|
+
postal_code: "644-8037", # 店舗の郵便番号
|
2812
3292
|
address: "東京都港区芝...", # 店舗の住所
|
2813
|
-
tel: "
|
2814
|
-
email: "
|
2815
|
-
external_id: "
|
3293
|
+
tel: "05651650-4895", # 店舗の電話番号
|
3294
|
+
email: "wois43hKOt@AoX7.com", # 店舗のメールアドレス
|
3295
|
+
external_id: "uae7lO58Ae6hTnrFSjbB1", # 店舗の外部ID
|
2816
3296
|
private_money_ids: ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"], # 店舗で有効にするマネーIDの配列
|
2817
3297
|
can_topup_private_money_ids: ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"] # 店舗でチャージ可能にするマネーIDの配列
|
2818
3298
|
))
|
@@ -2915,8 +3395,8 @@ response = $client.send(Pokepay::Request::UpdateShop.new(
|
|
2915
3395
|
```ruby
|
2916
3396
|
response = $client.send(Pokepay::Request::ListUserAccounts.new(
|
2917
3397
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # user_id: ユーザーID
|
2918
|
-
page:
|
2919
|
-
per_page:
|
3398
|
+
page: 6633, # ページ番号
|
3399
|
+
per_page: 3434 # 1ページ分の取引数
|
2920
3400
|
))
|
2921
3401
|
```
|
2922
3402
|
|
@@ -2956,12 +3436,14 @@ response = $client.send(Pokepay::Request::ListUserAccounts.new(
|
|
2956
3436
|
成功したときは[PaginatedAccountDetails](#paginated-account-details)オブジェクトを返します
|
2957
3437
|
<a name="create-user-account"></a>
|
2958
3438
|
#### エンドユーザーのウォレットを作成する
|
3439
|
+
既存のエンドユーザーに対して、指定したマネーのウォレットを新規作成します
|
2959
3440
|
```ruby
|
2960
3441
|
response = $client.send(Pokepay::Request::CreateUserAccount.new(
|
2961
3442
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # user_id: ユーザーID
|
2962
3443
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
2963
|
-
name: "
|
2964
|
-
external_id: "
|
3444
|
+
name: "jTNSU46DKPvyktKcWCyKm4tG2FzeWXxPN6RiMVhZmmGj0TMjPFLM0DLdwVX1nfPZtzGunVJbtCnsdFVcjFx", # ウォレット名
|
3445
|
+
external_id: "pkr7nBijaa4uqZKlbpHQT4mZQDB6u1kMJt8otXLMwiqJK6M", # 外部ID
|
3446
|
+
metadata: "{\"key1\":\"foo\",\"key2\":\"bar\"}" # ウォレットに付加するメタデータ
|
2965
3447
|
))
|
2966
3448
|
```
|
2967
3449
|
|
@@ -2987,6 +3469,20 @@ response = $client.send(Pokepay::Request::CreateUserAccount.new(
|
|
2987
3469
|
|
2988
3470
|
作成するウォレットのマネーを指定します。このパラメータは必須です。
|
2989
3471
|
|
3472
|
+
---
|
3473
|
+
`metadata`
|
3474
|
+
```json
|
3475
|
+
{
|
3476
|
+
"type": "string",
|
3477
|
+
"format": "json"
|
3478
|
+
}
|
3479
|
+
```
|
3480
|
+
ウォレットに付加するメタデータをJSON文字列で指定します。
|
3481
|
+
指定できるJSON文字列には以下のような制約があります。
|
3482
|
+
- フラットな構造のJSONを文字列化したものであること。
|
3483
|
+
- keyは最大32文字の文字列(同じkeyを複数指定することはできません)
|
3484
|
+
- valueには128文字以下の文字列が指定できます
|
3485
|
+
|
2990
3486
|
---
|
2991
3487
|
成功したときは[AccountDetail](#account-detail)オブジェクトを返します
|
2992
3488
|
### Private Money
|
@@ -3021,8 +3517,8 @@ response = $client.send(Pokepay::Request::GetPrivateMoneys.new(
|
|
3021
3517
|
```ruby
|
3022
3518
|
response = $client.send(Pokepay::Request::GetPrivateMoneyOrganizationSummaries.new(
|
3023
3519
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
3024
|
-
from: "
|
3025
|
-
to: "
|
3520
|
+
from: "2019-03-23T03:00:57.000000+09:00", # 開始日時(toと同時に指定する必要有)
|
3521
|
+
to: "2021-02-12T06:53:47.000000+09:00", # 終了日時(fromと同時に指定する必要有)
|
3026
3522
|
page: 1, # ページ番号
|
3027
3523
|
per_page: 50 # 1ページ分の取引数
|
3028
3524
|
))
|
@@ -3035,8 +3531,8 @@ response = $client.send(Pokepay::Request::GetPrivateMoneyOrganizationSummaries.n
|
|
3035
3531
|
```ruby
|
3036
3532
|
response = $client.send(Pokepay::Request::GetPrivateMoneySummary.new(
|
3037
3533
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
3038
|
-
from: "2016-
|
3039
|
-
to: "
|
3534
|
+
from: "2016-11-05T09:26:12.000000+09:00", # 開始日時
|
3535
|
+
to: "2018-11-09T05:48:32.000000+09:00" # 終了日時
|
3040
3536
|
))
|
3041
3537
|
```
|
3042
3538
|
成功したときは[PrivateMoneySummary](#private-money-summary)オブジェクトを返します
|
@@ -3046,10 +3542,11 @@ response = $client.send(Pokepay::Request::GetPrivateMoneySummary.new(
|
|
3046
3542
|
CSVファイルから一括取引をします。
|
3047
3543
|
```ruby
|
3048
3544
|
response = $client.send(Pokepay::Request::BulkCreateTransaction.new(
|
3049
|
-
"
|
3050
|
-
"
|
3051
|
-
"
|
3052
|
-
description: "
|
3545
|
+
"J9APWVf0nkI2cpiZrwht02d", # name: 一括取引タスク名
|
3546
|
+
"TsSxNXBuh", # content: 取引する情報のCSV
|
3547
|
+
"LAxPxLgPF7PH9jsPo3qRbXC06hH5q5N6rSql", # request_id: リクエストID
|
3548
|
+
description: "hclxbbI1pwNVNkX1w", # 一括取引の説明
|
3549
|
+
private_money_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" # マネーID
|
3053
3550
|
))
|
3054
3551
|
```
|
3055
3552
|
|
@@ -3112,6 +3609,16 @@ response = $client.send(Pokepay::Request::BulkCreateTransaction.new(
|
|
3112
3609
|
```
|
3113
3610
|
重複したリクエストを判断するためのユニークID。ランダムな36字の文字列を生成して渡してください。
|
3114
3611
|
|
3612
|
+
---
|
3613
|
+
`private_money_id`
|
3614
|
+
```json
|
3615
|
+
{
|
3616
|
+
"type": "string",
|
3617
|
+
"format": "uuid"
|
3618
|
+
}
|
3619
|
+
```
|
3620
|
+
マネーIDです。 マネーを指定します。
|
3621
|
+
|
3115
3622
|
---
|
3116
3623
|
成功したときは[BulkTransaction](#bulk-transaction)オブジェクトを返します
|
3117
3624
|
### Event
|
@@ -3126,7 +3633,7 @@ response = $client.send(Pokepay::Request::CreateExternalTransaction.new(
|
|
3126
3633
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # shop_id: 店舗ID
|
3127
3634
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # customer_id: エンドユーザーID
|
3128
3635
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
3129
|
-
|
3636
|
+
1428, # amount: 取引額
|
3130
3637
|
description: "たい焼き(小倉)", # 取引説明文
|
3131
3638
|
metadata: "{\"key\":\"value\"}", # ポケペイ外部取引メタデータ
|
3132
3639
|
products: [{"jan_code":"abc",
|
@@ -3275,17 +3782,17 @@ response = $client.send(Pokepay::Request::RefundExternalTransaction.new(
|
|
3275
3782
|
|
3276
3783
|
```ruby
|
3277
3784
|
response = $client.send(Pokepay::Request::CreateCampaign.new(
|
3278
|
-
"
|
3785
|
+
"tHq7h4XHkBbxR0RnLtirGJS2N5S6EEO5Bp0TaBrmndiCNxXXwjFaRAeTxfe0YQCHzm8OG8zcqkOxIGcWZjjM6j3edDcpZu9iiEwcokneeQ36NR2IjhyB4vKQ7cGl", # name: キャンペーン名
|
3279
3786
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # private_money_id: マネーID
|
3280
|
-
"
|
3281
|
-
"
|
3282
|
-
|
3283
|
-
"
|
3787
|
+
"2020-09-07T04:46:17.000000+09:00", # starts_at: キャンペーン開始日時
|
3788
|
+
"2018-06-24T05:34:48.000000+09:00", # ends_at: キャンペーン終了日時
|
3789
|
+
8515, # priority: キャンペーンの適用優先度
|
3790
|
+
"external-transaction", # event: イベント種別
|
3284
3791
|
bear_point_shop_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # ポイント負担先店舗ID
|
3285
|
-
description: "
|
3792
|
+
description: "dlgwn9qvauQ2kDhj5HLJcSNTCm30yK3y8WItCe9VYgMydEalG76qE4T1vOrKA4IwgS5AgijWRyxneekV8cIDT0hnm8h8evW68NKpdkq0PMSo6i", # キャンペーンの説明文
|
3286
3793
|
status: "enabled", # キャンペーン作成時の状態
|
3287
|
-
point_expires_at: "
|
3288
|
-
point_expires_in_days:
|
3794
|
+
point_expires_at: "2022-04-09T19:30:01.000000+09:00", # ポイント有効期限(絶対日時指定)
|
3795
|
+
point_expires_in_days: 8021, # ポイント有効期限(相対日数指定)
|
3289
3796
|
is_exclusive: true, # キャンペーンの重複設定
|
3290
3797
|
subject: "all", # ポイント付与の対象金額の種別
|
3291
3798
|
amount_based_point_rules: [{
|
@@ -3301,17 +3808,27 @@ response = $client.send(Pokepay::Request::CreateCampaign.new(
|
|
3301
3808
|
"is_multiply_by_count": true,
|
3302
3809
|
"required_count": 2
|
3303
3810
|
}], # 商品情報ベースのポイント付与ルール
|
3304
|
-
applicable_days_of_week: [
|
3811
|
+
applicable_days_of_week: [5, 6], # キャンペーンを適用する曜日 (複数指定)
|
3305
3812
|
applicable_time_ranges: [{
|
3306
3813
|
"from": "12:00",
|
3307
3814
|
"to": "23:59"
|
3308
3815
|
}, {
|
3309
3816
|
"from": "12:00",
|
3310
3817
|
"to": "23:59"
|
3818
|
+
}, {
|
3819
|
+
"from": "12:00",
|
3820
|
+
"to": "23:59"
|
3311
3821
|
}], # キャンペーンを適用する時間帯 (複数指定)
|
3312
|
-
applicable_shop_ids: ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
|
3313
|
-
minimum_number_for_combination_purchase:
|
3314
|
-
|
3822
|
+
applicable_shop_ids: ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"], # キャンペーン適用対象となる店舗IDのリスト
|
3823
|
+
minimum_number_for_combination_purchase: 4943, # 複数種類の商品を同時購入するときの商品種別数の下限
|
3824
|
+
exist_in_each_product_groups: false, # 複数の商品グループにつき1種類以上の商品購入によって発火するキャンペーンの指定フラグ
|
3825
|
+
max_point_amount: 6825, # キャンペーンによって付与されるポイントの上限
|
3826
|
+
max_total_point_amount: 1448, # キャンペーンによって付与されるの1人当たりの累計ポイントの上限
|
3827
|
+
dest_private_money_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # ポイント付与先となるマネーID
|
3828
|
+
applicable_account_metadata: {
|
3829
|
+
"key": "sex",
|
3830
|
+
"value": "male"
|
3831
|
+
} # ウォレットに紐付くメタデータが特定の値を持つときにのみ発火するキャンペーンを登録します。
|
3315
3832
|
))
|
3316
3833
|
```
|
3317
3834
|
|
@@ -3645,6 +4162,116 @@ event が payment か external-transaction の時のみ有効です。
|
|
3645
4162
|
}
|
3646
4163
|
```
|
3647
4164
|
|
4165
|
+
---
|
4166
|
+
`exist_in_each_product_groups`
|
4167
|
+
```json
|
4168
|
+
{ "type": "boolean" }
|
4169
|
+
```
|
4170
|
+
複数の商品グループの各グループにつき1種類以上の商品が購入されることによって発火するキャンペーンであるときに真を指定します。デフォルトは偽です。
|
4171
|
+
|
4172
|
+
このパラメータを指定するときは product_based_point_rules で商品毎のルールが指定され、さらにその中でgroup_idが指定されている必要があります。group_idは正の整数です。
|
4173
|
+
exist_in_each_product_groupsが指定されているにも関わらず商品毎のルールでgroup_idが指定されていないものが含まれている場合はinvalid_parametersエラー(missing group_id, エラーコード400)が返ります。
|
4174
|
+
|
4175
|
+
例えば、商品グループA(商品コードa1, a2)、商品グループB(商品コードb1, b2)の2つの商品グループがあるとします。
|
4176
|
+
このとき、各商品グループからそれぞれ少なくとも1種類以上の商品が購入されることにより発火するキャンペーンに対するリクエストパラメータは以下のようなものになります。
|
4177
|
+
|
4178
|
+
```javascript
|
4179
|
+
{
|
4180
|
+
exist_in_each_product_groups: true,
|
4181
|
+
product_based_point_rules: [
|
4182
|
+
{
|
4183
|
+
"point_amount": 100,
|
4184
|
+
"point_amount_unit": "absolute",
|
4185
|
+
"product_code": "a1",
|
4186
|
+
"group_id": 1
|
4187
|
+
},
|
4188
|
+
{
|
4189
|
+
"point_amount": 100,
|
4190
|
+
"point_amount_unit": "absolute",
|
4191
|
+
"product_code": "a2",
|
4192
|
+
"group_id": 1
|
4193
|
+
},
|
4194
|
+
{
|
4195
|
+
"point_amount": 200,
|
4196
|
+
"point_amount_unit": "absolute",
|
4197
|
+
"product_code": "b1",
|
4198
|
+
"group_id": 2
|
4199
|
+
},
|
4200
|
+
{
|
4201
|
+
"point_amount": 200,
|
4202
|
+
"point_amount_unit": "absolute",
|
4203
|
+
"product_code": "b2",
|
4204
|
+
"group_id": 2
|
4205
|
+
}
|
4206
|
+
]
|
4207
|
+
}
|
4208
|
+
```
|
4209
|
+
|
4210
|
+
このキャンペーンが設定された状態で、商品a1、b1が同時に購入された場合、各商品に対する個別のルールが適用された上での総和がポイント付与値になります。つまり100 + 200=300がポイント付与値になります。商品a1、a2、 b1、b2が同時に購入された場合は100 + 100 + 200 + 200=600がポイント付与値になります。 商品a1、a2が同時に購入された場合は全商品グループから1種以上購入されるという条件を満たしていないためポイントは付与されません。
|
4211
|
+
|
4212
|
+
ポイント付与値を各商品毎のルールの総和ではなく固定値にしたい場合には、max_point_amountを指定します。
|
4213
|
+
例えば以下のようなリクエストパラメータ指定の場合を考えます。
|
4214
|
+
|
4215
|
+
```javascript
|
4216
|
+
{
|
4217
|
+
max_point_amount: 100,
|
4218
|
+
exist_in_each_product_groups: true,
|
4219
|
+
product_based_point_rules: [
|
4220
|
+
{
|
4221
|
+
"point_amount": 100,
|
4222
|
+
"point_amount_unit": "absolute",
|
4223
|
+
"product_code": "a1",
|
4224
|
+
"group_id": 1
|
4225
|
+
},
|
4226
|
+
{
|
4227
|
+
"point_amount": 100,
|
4228
|
+
"point_amount_unit": "absolute",
|
4229
|
+
"product_code": "a2",
|
4230
|
+
"group_id": 1
|
4231
|
+
},
|
4232
|
+
{
|
4233
|
+
"point_amount": 100,
|
4234
|
+
"point_amount_unit": "absolute",
|
4235
|
+
"product_code": "b1",
|
4236
|
+
"group_id": 2
|
4237
|
+
},
|
4238
|
+
{
|
4239
|
+
"point_amount": 100,
|
4240
|
+
"point_amount_unit": "absolute",
|
4241
|
+
"product_code": "b2",
|
4242
|
+
"group_id": 2
|
4243
|
+
}
|
4244
|
+
]
|
4245
|
+
}
|
4246
|
+
```
|
4247
|
+
|
4248
|
+
このキャンペーンが設定された状態で、商品a1、b1が同時に購入された場合、各商品に対する個別のルールが適用された上での総和がポイント付与値になりますが、付与値の上限が100ポイントになります。つまり100 + 200=300と計算されますが上限額の100ポイントが実際の付与値になります。商品a1、a2、 b1、b2が同時に購入された場合は100 + 100 + 200 + 200=600ですが上限額の100がポイント付与値になります。 商品a1、a2が同時に購入された場合は全商品グループから1種以上購入されるという条件を満たしていないためポイントは付与されません。
|
4249
|
+
|
4250
|
+
---
|
4251
|
+
`max_point_amount`
|
4252
|
+
```json
|
4253
|
+
{
|
4254
|
+
"type": "integer",
|
4255
|
+
"minimum": 1
|
4256
|
+
}
|
4257
|
+
```
|
4258
|
+
キャンペーンによって付与されるポイントの上限を指定します。デフォルトは未指定です。
|
4259
|
+
|
4260
|
+
このパラメータが指定されている場合、amount_based_point_rules や product_based_point_rules によって計算されるポイント付与値がmax_point_amountを越えている場合、max_point_amountの値がポイント付与値となり、越えていない場合はその値がポイント付与値となります。
|
4261
|
+
|
4262
|
+
---
|
4263
|
+
`max_total_point_amount`
|
4264
|
+
```json
|
4265
|
+
{
|
4266
|
+
"type": "integer",
|
4267
|
+
"minimum": 1
|
4268
|
+
}
|
4269
|
+
```
|
4270
|
+
キャンペーンによって付与される1人当たりの累計ポイント数の上限を指定します。デフォルトは未指定です。
|
4271
|
+
|
4272
|
+
このパラメータが指定されている場合、各ユーザに対してそのキャンペーンによって過去付与されたポイントの累積値が記録されるようになります。
|
4273
|
+
累積ポイント数がmax_total_point_amountを超えない限りにおいてキャンペーンで算出されたポイントが付与されます。
|
4274
|
+
|
3648
4275
|
---
|
3649
4276
|
`dest_private_money_id`
|
3650
4277
|
```json
|
@@ -3663,6 +4290,37 @@ event が payment か external-transaction の時のみ有効です。
|
|
3663
4290
|
|
3664
4291
|
別マネーに対するポイント付与は別のtransactionとなります。 RefundTransaction で元のイベントをキャンセルしたときはポイント付与のtransactionもキャンセルされ、逆にポイント付与のtransactionをキャンセルしたときは連動して元のイベントがキャンセルされます。
|
3665
4292
|
|
4293
|
+
---
|
4294
|
+
`applicable_account_metadata`
|
4295
|
+
```json
|
4296
|
+
{ "type": "object" }
|
4297
|
+
```
|
4298
|
+
ウォレットに紐付くメタデータが特定の値を持つときにのみ発火するキャンペーンを登録します。
|
4299
|
+
メタデータの属性名 key とメタデータの値 value の組をオブジェクトとして指定します。
|
4300
|
+
ウォレットのメタデータはCreateUserAccountやUpdateCustomerAccountで登録できます。
|
4301
|
+
|
4302
|
+
オプショナルパラメータtestによって比較方法を指定することができます。
|
4303
|
+
デフォルトは equal で、その他に not-equalを指定可能です。
|
4304
|
+
|
4305
|
+
例1: 取引が行なわれたウォレットのメタデータに住所として東京が指定されているときのみ発火
|
4306
|
+
|
4307
|
+
```javascript
|
4308
|
+
{
|
4309
|
+
"key": "prefecture",
|
4310
|
+
"value": "tokyo"
|
4311
|
+
}
|
4312
|
+
```
|
4313
|
+
|
4314
|
+
例2: 取引が行なわれたウォレットのメタデータに住所として東京以外が指定されているときのみ発火
|
4315
|
+
|
4316
|
+
```javascript
|
4317
|
+
{
|
4318
|
+
"key": "prefecture",
|
4319
|
+
"value": "tokyo",
|
4320
|
+
"test": "not-equal"
|
4321
|
+
}
|
4322
|
+
```
|
4323
|
+
|
3666
4324
|
---
|
3667
4325
|
成功したときは[Campaign](#campaign)オブジェクトを返します
|
3668
4326
|
<a name="list-campaigns"></a>
|
@@ -3754,36 +4412,32 @@ response = $client.send(Pokepay::Request::GetCampaign.new(
|
|
3754
4412
|
```ruby
|
3755
4413
|
response = $client.send(Pokepay::Request::UpdateCampaign.new(
|
3756
4414
|
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", # campaign_id: キャンペーンID
|
3757
|
-
name: "
|
3758
|
-
starts_at: "
|
3759
|
-
ends_at: "
|
3760
|
-
priority:
|
3761
|
-
event: "
|
3762
|
-
description: "
|
4415
|
+
name: "OxFwqhkpZVaDhpFPp5bfKVt9DPYJAVzV6vyI6ywfpyKilj5zg8pn57kF0DYbPLXjuwrpeD0A9IDYP4sAiFNwaac9r9GBqh0SVIl9M1spjv4mKXU1rVLf6U0K44BovHKqYzk7GBG1DZKj2tBRFerhSuL22gGga7pF0nmLMfnIYTQdqHJZ8WnDHEVfpIBtEOMP2U7IkYygmkkDxd3MzpkzvPsPo", # キャンペーン名
|
4416
|
+
starts_at: "2023-06-03T23:52:26.000000+09:00", # キャンペーン開始日時
|
4417
|
+
ends_at: "2020-01-31T18:01:01.000000+09:00", # キャンペーン終了日時
|
4418
|
+
priority: 5110, # キャンペーンの適用優先度
|
4419
|
+
event: "topup", # イベント種別
|
4420
|
+
description: "af470Dw5YI6SeAOBDBgRAgmjxZGGCqaBwJ9iXjXSEfbkdsvlfnd1NOUEcUOGTeYua5DveJsn8lhIUcgIkY0oNU4ZtZZObHmdr0N6vylnlZRhGDMxuj8A7eDOAWeoDpeF6vcSyg1N9plx7jjHK1E1PUQiuVzdT2YVVNgkhGiOa", # キャンペーンの説明文
|
3763
4421
|
status: "enabled", # キャンペーン作成時の状態
|
3764
|
-
point_expires_at: "
|
3765
|
-
point_expires_in_days:
|
3766
|
-
is_exclusive:
|
3767
|
-
subject: "
|
4422
|
+
point_expires_at: "2018-01-18T02:18:26.000000+09:00", # ポイント有効期限(絶対日時指定)
|
4423
|
+
point_expires_in_days: 9491, # ポイント有効期限(相対日数指定)
|
4424
|
+
is_exclusive: true, # キャンペーンの重複設定
|
4425
|
+
subject: "all", # ポイント付与の対象金額の種別
|
3768
4426
|
amount_based_point_rules: [{
|
3769
4427
|
"point_amount": 5,
|
3770
4428
|
"point_amount_unit": "percent",
|
3771
4429
|
"subject_more_than_or_equal": 1000,
|
3772
4430
|
"subject_less_than": 5000
|
3773
|
-
},
|
4431
|
+
}], # 取引金額ベースのポイント付与ルール
|
4432
|
+
product_based_point_rules: [{
|
3774
4433
|
"point_amount": 5,
|
3775
4434
|
"point_amount_unit": "percent",
|
3776
|
-
"
|
3777
|
-
"
|
4435
|
+
"product_code": "4912345678904",
|
4436
|
+
"is_multiply_by_count": true,
|
4437
|
+
"required_count": 2
|
3778
4438
|
}, {
|
3779
4439
|
"point_amount": 5,
|
3780
4440
|
"point_amount_unit": "percent",
|
3781
|
-
"subject_more_than_or_equal": 1000,
|
3782
|
-
"subject_less_than": 5000
|
3783
|
-
}], # 取引金額ベースのポイント付与ルール
|
3784
|
-
product_based_point_rules: [{
|
3785
|
-
"point_amount": 5,
|
3786
|
-
"point_amount_unit": "percent",
|
3787
4441
|
"product_code": "4912345678904",
|
3788
4442
|
"is_multiply_by_count": true,
|
3789
4443
|
"required_count": 2
|
@@ -3794,16 +4448,26 @@ response = $client.send(Pokepay::Request::UpdateCampaign.new(
|
|
3794
4448
|
"is_multiply_by_count": true,
|
3795
4449
|
"required_count": 2
|
3796
4450
|
}], # 商品情報ベースのポイント付与ルール
|
3797
|
-
applicable_days_of_week: [
|
4451
|
+
applicable_days_of_week: [6], # キャンペーンを適用する曜日 (複数指定)
|
3798
4452
|
applicable_time_ranges: [{
|
3799
4453
|
"from": "12:00",
|
3800
4454
|
"to": "23:59"
|
3801
4455
|
}, {
|
3802
4456
|
"from": "12:00",
|
3803
4457
|
"to": "23:59"
|
4458
|
+
}, {
|
4459
|
+
"from": "12:00",
|
4460
|
+
"to": "23:59"
|
3804
4461
|
}], # キャンペーンを適用する時間帯 (複数指定)
|
3805
4462
|
applicable_shop_ids: ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"], # キャンペーン適用対象となる店舗IDのリスト
|
3806
|
-
minimum_number_for_combination_purchase:
|
4463
|
+
minimum_number_for_combination_purchase: 7796, # 複数種類の商品を同時購入するときの商品種別数の下限
|
4464
|
+
exist_in_each_product_groups: false, # 複数の商品グループにつき1種類以上の商品購入によって発火するキャンペーンの指定フラグ
|
4465
|
+
max_point_amount: 9422, # キャンペーンによって付与されるポイントの上限
|
4466
|
+
max_total_point_amount: 3295, # キャンペーンによって付与されるの1人当たりの累計ポイントの上限
|
4467
|
+
applicable_account_metadata: {
|
4468
|
+
"key": "sex",
|
4469
|
+
"value": "male"
|
4470
|
+
} # ウォレットに紐付くメタデータが特定の値を持つときにのみ発火するキャンペーンを登録します。
|
3807
4471
|
))
|
3808
4472
|
```
|
3809
4473
|
|
@@ -4128,6 +4792,147 @@ event が payment か external-transaction の時のみ有効です。
|
|
4128
4792
|
}
|
4129
4793
|
```
|
4130
4794
|
|
4795
|
+
---
|
4796
|
+
`exist_in_each_product_groups`
|
4797
|
+
```json
|
4798
|
+
{ "type": "boolean" }
|
4799
|
+
```
|
4800
|
+
複数の商品グループの各グループにつき1種類以上の商品が購入されることによって発火するキャンペーンであるときに真を指定します。デフォルトは偽です。
|
4801
|
+
|
4802
|
+
このパラメータを指定するときは product_based_point_rules で商品毎のルールが指定され、さらにその中でgroup_idが指定されている必要があります。group_idは正の整数です。
|
4803
|
+
exist_in_each_product_groupsが指定されているにも関わらず商品毎のルールでgroup_idが指定されていないものが含まれている場合はinvalid_parametersエラー(missing group_id, エラーコード400)が返ります。
|
4804
|
+
|
4805
|
+
例えば、商品グループA(商品コードa1, a2)、商品グループB(商品コードb1, b2)の2つの商品グループがあるとします。
|
4806
|
+
このとき、各商品グループからそれぞれ少なくとも1種類以上の商品が購入されることにより発火するキャンペーンに対するリクエストパラメータは以下のようなものになります。
|
4807
|
+
|
4808
|
+
```javascript
|
4809
|
+
{
|
4810
|
+
exist_in_each_product_groups: true,
|
4811
|
+
product_based_point_rules: [
|
4812
|
+
{
|
4813
|
+
"point_amount": 100,
|
4814
|
+
"point_amount_unit": "absolute",
|
4815
|
+
"product_code": "a1",
|
4816
|
+
"group_id": 1
|
4817
|
+
},
|
4818
|
+
{
|
4819
|
+
"point_amount": 100,
|
4820
|
+
"point_amount_unit": "absolute",
|
4821
|
+
"product_code": "a2",
|
4822
|
+
"group_id": 1
|
4823
|
+
},
|
4824
|
+
{
|
4825
|
+
"point_amount": 200,
|
4826
|
+
"point_amount_unit": "absolute",
|
4827
|
+
"product_code": "b1",
|
4828
|
+
"group_id": 2
|
4829
|
+
},
|
4830
|
+
{
|
4831
|
+
"point_amount": 200,
|
4832
|
+
"point_amount_unit": "absolute",
|
4833
|
+
"product_code": "b2",
|
4834
|
+
"group_id": 2
|
4835
|
+
}
|
4836
|
+
]
|
4837
|
+
}
|
4838
|
+
```
|
4839
|
+
|
4840
|
+
このキャンペーンが設定された状態で、商品a1、b1が同時に購入された場合、各商品に対する個別のルールが適用された上での総和がポイント付与値になります。つまり100 + 200=300がポイント付与値になります。商品a1、a2、 b1、b2が同時に購入された場合は100 + 100 + 200 + 200=600がポイント付与値になります。 商品a1、a2が同時に購入された場合は全商品グループから1種以上購入されるという条件を満たしていないためポイントは付与されません。
|
4841
|
+
|
4842
|
+
ポイント付与値を各商品毎のルールの総和ではなく固定値にしたい場合には、max_point_amountを指定します。
|
4843
|
+
例えば以下のようなリクエストパラメータ指定の場合を考えます。
|
4844
|
+
|
4845
|
+
```javascript
|
4846
|
+
{
|
4847
|
+
max_point_amount: 100,
|
4848
|
+
exist_in_each_product_groups: true,
|
4849
|
+
product_based_point_rules: [
|
4850
|
+
{
|
4851
|
+
"point_amount": 100,
|
4852
|
+
"point_amount_unit": "absolute",
|
4853
|
+
"product_code": "a1",
|
4854
|
+
"group_id": 1
|
4855
|
+
},
|
4856
|
+
{
|
4857
|
+
"point_amount": 100,
|
4858
|
+
"point_amount_unit": "absolute",
|
4859
|
+
"product_code": "a2",
|
4860
|
+
"group_id": 1
|
4861
|
+
},
|
4862
|
+
{
|
4863
|
+
"point_amount": 100,
|
4864
|
+
"point_amount_unit": "absolute",
|
4865
|
+
"product_code": "b1",
|
4866
|
+
"group_id": 2
|
4867
|
+
},
|
4868
|
+
{
|
4869
|
+
"point_amount": 100,
|
4870
|
+
"point_amount_unit": "absolute",
|
4871
|
+
"product_code": "b2",
|
4872
|
+
"group_id": 2
|
4873
|
+
}
|
4874
|
+
]
|
4875
|
+
}
|
4876
|
+
```
|
4877
|
+
|
4878
|
+
このキャンペーンが設定された状態で、商品a1、b1が同時に購入された場合、各商品に対する個別のルールが適用された上での総和がポイント付与値になりますが、付与値の上限が100ポイントになります。つまり100 + 200=300と計算されますが上限額の100ポイントが実際の付与値になります。商品a1、a2、 b1、b2が同時に購入された場合は100 + 100 + 200 + 200=600ですが上限額の100がポイント付与値になります。 商品a1、a2が同時に購入された場合は全商品グループから1種以上購入されるという条件を満たしていないためポイントは付与されません。
|
4879
|
+
|
4880
|
+
---
|
4881
|
+
`max_point_amount`
|
4882
|
+
```json
|
4883
|
+
{
|
4884
|
+
"type": "integer",
|
4885
|
+
"minimum": 1
|
4886
|
+
}
|
4887
|
+
```
|
4888
|
+
キャンペーンによって付与される1取引当たりのポイント数の上限を指定します。デフォルトは未指定です。
|
4889
|
+
|
4890
|
+
このパラメータが指定されている場合、amount_based_point_rules や product_based_point_rules によって計算されるポイント付与値がmax_point_amountを越えている場合、max_point_amountの値がポイント付与値となり、越えていない場合はその値がポイント付与値となります。
|
4891
|
+
|
4892
|
+
---
|
4893
|
+
`max_total_point_amount`
|
4894
|
+
```json
|
4895
|
+
{
|
4896
|
+
"type": "integer",
|
4897
|
+
"minimum": 1
|
4898
|
+
}
|
4899
|
+
```
|
4900
|
+
キャンペーンによって付与される1人当たりの累計ポイント数の上限を指定します。デフォルトは未指定です。
|
4901
|
+
|
4902
|
+
このパラメータが指定されている場合、各ユーザに対してそのキャンペーンによって過去付与されたポイントの累積値が記録されるようになります。
|
4903
|
+
累積ポイント数がmax_total_point_amountを超えない限りにおいてキャンペーンで算出されたポイントが付与されます。
|
4904
|
+
|
4905
|
+
---
|
4906
|
+
`applicable_account_metadata`
|
4907
|
+
```json
|
4908
|
+
{ "type": "object" }
|
4909
|
+
```
|
4910
|
+
ウォレットに紐付くメタデータが特定の値を持つときにのみ発火するキャンペーンを登録します。
|
4911
|
+
メタデータの属性名 key とメタデータの値 value の組をオブジェクトとして指定します。
|
4912
|
+
ウォレットのメタデータはCreateUserAccountやUpdateCustomerAccountで登録できます。
|
4913
|
+
|
4914
|
+
オプショナルパラメータtestによって比較方法を指定することができます。
|
4915
|
+
デフォルトは equal で、その他に not-equalを指定可能です。
|
4916
|
+
|
4917
|
+
例1: 取引が行なわれたウォレットのメタデータに住所として東京が指定されているときのみ発火
|
4918
|
+
|
4919
|
+
```javascript
|
4920
|
+
{
|
4921
|
+
"key": "prefecture",
|
4922
|
+
"value": "tokyo"
|
4923
|
+
}
|
4924
|
+
```
|
4925
|
+
|
4926
|
+
例2: 取引が行なわれたウォレットのメタデータに住所として東京以外が指定されているときのみ発火
|
4927
|
+
|
4928
|
+
```javascript
|
4929
|
+
{
|
4930
|
+
"key": "prefecture",
|
4931
|
+
"value": "tokyo",
|
4932
|
+
"test": "not-equal"
|
4933
|
+
}
|
4934
|
+
```
|
4935
|
+
|
4131
4936
|
---
|
4132
4937
|
成功したときは[Campaign](#campaign)オブジェクトを返します
|
4133
4938
|
## Responses
|
@@ -4155,6 +4960,7 @@ event が payment か external-transaction の時のみ有効です。
|
|
4155
4960
|
* `balance (double)`:
|
4156
4961
|
* `money_balance (double)`:
|
4157
4962
|
* `point_balance (double)`:
|
4963
|
+
* `point_debt (double)`:
|
4158
4964
|
* `private_money (PrivateMoney)`:
|
4159
4965
|
* `user (User)`:
|
4160
4966
|
* `external_id (string)`:
|
@@ -4179,6 +4985,29 @@ event が payment か external-transaction の時のみ有効です。
|
|
4179
4985
|
|
4180
4986
|
`account`は [AccountWithUser](#account-with-user) オブジェクトを返します。
|
4181
4987
|
|
4988
|
+
<a name="check"></a>
|
4989
|
+
## Check
|
4990
|
+
* `id (string)`: チャージQRコードのID
|
4991
|
+
* `created_at (string)`: チャージQRコードの作成日時
|
4992
|
+
* `amount (double)`: チャージマネー額 (deprecated)
|
4993
|
+
* `money_amount (double)`: チャージマネー額
|
4994
|
+
* `point_amount (double)`: チャージポイント額
|
4995
|
+
* `description (string)`: チャージQRコードの説明文(アプリ上で取引の説明文として表示される)
|
4996
|
+
* `user (User)`: 送金元ユーザ情報
|
4997
|
+
* `is_onetime (boolean)`: 使用回数が一回限りかどうか
|
4998
|
+
* `is_disabled (boolean)`: 無効化されているかどうか
|
4999
|
+
* `expires_at (string)`: チャージQRコード自体の失効日時
|
5000
|
+
* `private_money (PrivateMoney)`: 対象マネー情報
|
5001
|
+
* `usage_limit (integer)`: 一回限りでない場合の最大読み取り回数
|
5002
|
+
* `usage_count (double)`: 一回限りでない場合の現在までに読み取られた回数
|
5003
|
+
* `point_expires_at (string)`: ポイント有効期限(絶対日数指定)
|
5004
|
+
* `point_expires_in_days (integer)`: ポイント有効期限(相対日数指定)
|
5005
|
+
* `token (string)`: チャージQRコードを解析したときに出てくるURL
|
5006
|
+
|
5007
|
+
`user`は [User](#user) オブジェクトを返します。
|
5008
|
+
|
5009
|
+
`private_money`は [PrivateMoney](#private-money) オブジェクトを返します。
|
5010
|
+
|
4182
5011
|
<a name="cpm-token"></a>
|
4183
5012
|
## CpmToken
|
4184
5013
|
* `cpm_token (string)`:
|
@@ -4317,6 +5146,17 @@ event が payment か external-transaction の時のみ有効です。
|
|
4317
5146
|
* `exchange_outflow_amount (double)`:
|
4318
5147
|
* `transaction_count (integer)`:
|
4319
5148
|
|
5149
|
+
<a name="user-stats-operation"></a>
|
5150
|
+
## UserStatsOperation
|
5151
|
+
* `id (string)`: 集計処理ID
|
5152
|
+
* `from (string)`: 集計期間の開始時刻
|
5153
|
+
* `to (string)`: 集計期間の終了時刻
|
5154
|
+
* `status (string)`: 集計処理の実行ステータス
|
5155
|
+
* `error_reason (string)`: エラーとなった理由
|
5156
|
+
* `done_at (string)`: 集計処理の完了時刻
|
5157
|
+
* `file_url (string)`: 集計結果のCSVのダウンロードURL
|
5158
|
+
* `requested_at (string)`: 集計リクエストを行った時刻
|
5159
|
+
|
4320
5160
|
<a name="paginated-transaction"></a>
|
4321
5161
|
## PaginatedTransaction
|
4322
5162
|
* `rows (array of Transactions)`:
|
@@ -4347,6 +5187,16 @@ event が payment か external-transaction の時のみ有効です。
|
|
4347
5187
|
|
4348
5188
|
`pagination`は [Pagination](#pagination) オブジェクトを返します。
|
4349
5189
|
|
5190
|
+
<a name="paginated-transfers-v2"></a>
|
5191
|
+
## PaginatedTransfersV2
|
5192
|
+
* `rows (array of Transfers)`:
|
5193
|
+
* `per_page (integer)`:
|
5194
|
+
* `count (integer)`:
|
5195
|
+
* `next_page_cursor_id (string)`:
|
5196
|
+
* `prev_page_cursor_id (string)`:
|
5197
|
+
|
5198
|
+
`rows`は [Transfer](#transfer) オブジェクトの配列を返します。
|
5199
|
+
|
4350
5200
|
<a name="paginated-account-with-users"></a>
|
4351
5201
|
## PaginatedAccountWithUsers
|
4352
5202
|
* `rows (array of AccountWithUsers)`:
|
@@ -4422,6 +5272,7 @@ event が payment か external-transaction の時のみ有効です。
|
|
4422
5272
|
* `bear_point_shop (User)`: ポイントを負担する店舗
|
4423
5273
|
* `private_money (PrivateMoney)`: キャンペーンを適用するマネー
|
4424
5274
|
* `dest_private_money (PrivateMoney)`: ポイントを付与するマネー
|
5275
|
+
* `max_total_point_amount (integer)`: 一人当たりの累計ポイント上限
|
4425
5276
|
* `point_calculation_rule (string)`: ポイント計算ルール (banklisp表記)
|
4426
5277
|
* `point_calculation_rule_object (string)`: ポイント計算ルール (JSON文字列による表記)
|
4427
5278
|
* `status (string)`: キャンペーンの現在の状態
|
@@ -4442,6 +5293,12 @@ event が payment か external-transaction の時のみ有効です。
|
|
4442
5293
|
|
4443
5294
|
`pagination`は [Pagination](#pagination) オブジェクトを返します。
|
4444
5295
|
|
5296
|
+
<a name="account-transfer-summary"></a>
|
5297
|
+
## AccountTransferSummary
|
5298
|
+
* `summaries (array of AccountTransferSummaryElements)`:
|
5299
|
+
|
5300
|
+
`summaries`は [AccountTransferSummaryElement](#account-transfer-summary-element) オブジェクトの配列を返します。
|
5301
|
+
|
4445
5302
|
<a name="private-money"></a>
|
4446
5303
|
## PrivateMoney
|
4447
5304
|
* `id (string)`: マネーID
|
@@ -4557,6 +5414,13 @@ event が payment か external-transaction の時のみ有効です。
|
|
4557
5414
|
* `email (string)`: 店舗のメールアドレス
|
4558
5415
|
* `external_id (string)`: 店舗の外部ID
|
4559
5416
|
|
5417
|
+
<a name="account-transfer-summary-element"></a>
|
5418
|
+
## AccountTransferSummaryElement
|
5419
|
+
* `transfer_type (string)`:
|
5420
|
+
* `money_amount (double)`:
|
5421
|
+
* `point_amount (double)`:
|
5422
|
+
* `count (double)`:
|
5423
|
+
|
4560
5424
|
<a name="organization"></a>
|
4561
5425
|
## Organization
|
4562
5426
|
* `code (string)`: 組織コード
|