Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
// DO NOT EDIT: File is generated by code generator.
package jp.pokepay.pokepaylib.BankAPI.autogen.requests;

import java.util.HashMap;
import java.util.Map;

import jp.pokepay.pokepaylib.BankAPI.BankRequest;
import jp.pokepay.pokepaylib.BankAPI.BankRequestError;
import jp.pokepay.pokepaylib.ProcessingError;
import jp.pokepay.pokepaylib.Request;
import jp.pokepay.pokepaylib.BankAPI.autogen.responses.*;

public class BankPayTopUp extends BankRequest {
private String accountId;
private String bankId;
private Integer amount;
private String requestId;
private Integer topupQuotaId;
private String userId;

public BankPayTopUp(String userId, String accountId, String bankId, int amount) {
this.userId = userId;
this.accountId = accountId;
this.bankId = bankId;
this.amount = amount;
}

public BankPayTopUp requestId(String requestId) {
this.requestId = requestId;
return this;
}

public BankPayTopUp topupQuotaId(Integer topupQuotaId) {
this.topupQuotaId = topupQuotaId;
return this;
}

@Override
protected final Request.Method method() {
return Request.Method.POST;
}

@Override
public String path() {
return "/users" + "/" + this.userId + "/banks" + "/topup";
}

@Override
protected final Map<String, Object> parameters() {
return new HashMap<String, Object>() {{
if (accountId != null) {
put("account_id", accountId);
}
if (bankId != null) {
put("bank_id", bankId);
}
if (amount != null) {
put("amount", amount);
}
if (requestId != null) {
put("request_id", requestId);
}
if (topupQuotaId != null) {
put("topup_quota_id", topupQuotaId);
}
}};
}

public final UserTransaction send(String accessToken) throws ProcessingError, BankRequestError {
return super.send(UserTransaction.class, accessToken);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
// DO NOT EDIT: File is generated by code generator.
package jp.pokepay.pokepaylib.BankAPI.autogen.requests;

import java.util.HashMap;
import java.util.Map;

import jp.pokepay.pokepaylib.BankAPI.BankRequest;
import jp.pokepay.pokepaylib.BankAPI.BankRequestError;
import jp.pokepay.pokepaylib.ProcessingError;
import jp.pokepay.pokepaylib.Request;
import jp.pokepay.pokepaylib.BankAPI.autogen.responses.*;

public class CreateAccount extends BankRequest {
private String name;
private String privateMoneyId;
private String externalId;

public CreateAccount(String privateMoneyId) {
this.privateMoneyId = privateMoneyId;
}

public CreateAccount name(String name) {
this.name = name;
return this;
}

public CreateAccount externalId(String externalId) {
this.externalId = externalId;
return this;
}

@Override
protected final Request.Method method() {
return Request.Method.POST;
}

@Override
public String path() {
return "/accounts";
}

@Override
protected final Map<String, Object> parameters() {
return new HashMap<String, Object>() {{
if (name != null) {
put("name", name);
}
if (privateMoneyId != null) {
put("private_money_id", privateMoneyId);
}
if (externalId != null) {
put("external_id", externalId);
}
}};
}

public final AccountDetail send(String accessToken) throws ProcessingError, BankRequestError {
return super.send(AccountDetail.class, accessToken);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
// DO NOT EDIT: File is generated by code generator.
package jp.pokepay.pokepaylib.BankAPI.autogen.requests;

import java.util.HashMap;
import java.util.Map;

import jp.pokepay.pokepaylib.BankAPI.BankRequest;
import jp.pokepay.pokepaylib.BankAPI.BankRequestError;
import jp.pokepay.pokepaylib.ProcessingError;
import jp.pokepay.pokepaylib.Request;
import jp.pokepay.pokepaylib.BankAPI.autogen.responses.*;

public class CreateAccountCpmToken extends BankRequest {
private String[] scopes;
private Integer expiresIn;
private String metadata;
private Boolean keepAlive;
private Boolean isShortToken;
private String strategy;
private String couponId;
private String accountId;

public CreateAccountCpmToken(String accountId) {
this.accountId = accountId;
}

public CreateAccountCpmToken scopes(String[] scopes) {
this.scopes = scopes;
return this;
}

public CreateAccountCpmToken expiresIn(Integer expiresIn) {
this.expiresIn = expiresIn;
return this;
}

public CreateAccountCpmToken metadata(String metadata) {
this.metadata = metadata;
return this;
}

public CreateAccountCpmToken keepAlive(Boolean keepAlive) {
this.keepAlive = keepAlive;
return this;
}

public CreateAccountCpmToken isShortToken(Boolean shortToken) {
isShortToken = shortToken;
return this;
}

public CreateAccountCpmToken strategy(String strategy) {
this.strategy = strategy;
return this;
}

public CreateAccountCpmToken couponId(String couponId) {
this.couponId = couponId;
return this;
}

@Override
protected final Request.Method method() {
return Request.Method.POST;
}

@Override
public String path() {
return "/accounts" + "/" + this.accountId + "/cpm";
}

@Override
protected final Map<String, Object> parameters() {
return new HashMap<String, Object>() {{
if (scopes != null) {
put("scopes", scopes);
}
if (expiresIn != null) {
put("expires_in", expiresIn);
}
if (metadata != null) {
put("metadata", metadata);
}
if (keepAlive != null) {
put("keep_alive", keepAlive);
}
if (isShortToken != null) {
put("is_short_token", isShortToken);
}
if (strategy != null) {
put("strategy", strategy);
}
if (couponId != null) {
put("coupon_id", couponId);
}
}};
}

public final CpmToken send(String accessToken) throws ProcessingError, BankRequestError {
return super.send(CpmToken.class, accessToken);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
// DO NOT EDIT: File is generated by code generator.
package jp.pokepay.pokepaylib.BankAPI.autogen.requests;

import java.util.HashMap;
import java.util.Map;

import jp.pokepay.pokepaylib.BankAPI.BankRequest;
import jp.pokepay.pokepaylib.BankAPI.BankRequestError;
import jp.pokepay.pokepaylib.ProcessingError;
import jp.pokepay.pokepaylib.Request;
import jp.pokepay.pokepaylib.BankAPI.autogen.responses.*;

public class CreateBankPay extends BankRequest {
private String privateMoneyId;
private String callbackUrl;
private String kana;
private String userId;

public CreateBankPay(String userId, String privateMoneyId, String callbackUrl) {
this.userId = userId;
this.privateMoneyId = privateMoneyId;
this.callbackUrl = callbackUrl;
}

public CreateBankPay kana(String kana) {
this.kana = kana;
return this;
}

@Override
protected final Request.Method method() {
return Request.Method.POST;
}

@Override
public String path() {
return "/users" + "/" + this.userId + "/banks";
}

@Override
protected final Map<String, Object> parameters() {
return new HashMap<String, Object>() {{
if (privateMoneyId != null) {
put("private_money_id", privateMoneyId);
}
if (callbackUrl != null) {
put("callback_url", callbackUrl);
}
if (kana != null) {
put("kana", kana);
}
}};
}

public final BankPaySession send(String accessToken) throws ProcessingError, BankRequestError {
return super.send(BankPaySession.class, accessToken);
}
}
Loading