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
8 changes: 3 additions & 5 deletions src/main/java/com/alipay/global/api/Http2JsonTransport.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
import java.util.concurrent.TimeUnit;
import java.util.concurrent.TimeoutException;
import org.apache.commons.lang3.StringUtils;
import org.apache.hc.client5.http.config.ConnectionConfig;
import org.apache.hc.client5.http.async.methods.SimpleHttpRequest;
import org.apache.hc.client5.http.async.methods.SimpleHttpResponse;
import org.apache.hc.client5.http.config.ConnectionConfig;
import org.apache.hc.client5.http.impl.async.CloseableHttpAsyncClient;
import org.apache.hc.client5.http.impl.async.HttpAsyncClients;
import org.apache.hc.client5.http.impl.nio.PoolingAsyncClientConnectionManagerBuilder;
Expand All @@ -36,8 +36,7 @@ static String post(String gatewayUrl, String path, String sessionId, String requ
request.setHeader("X-Session-Id", sessionId);
request.setHeader("Accept", "application/json");
request.setHeader("User-Agent", SdkVersion.getUserAgent());
request.setBody(
requestBody, ContentType.create("application/json", StandardCharsets.UTF_8));
request.setBody(requestBody, ContentType.create("application/json", StandardCharsets.UTF_8));

Future<SimpleHttpResponse> responseFuture = HTTP_CLIENT.execute(request, null);
SimpleHttpResponse response;
Expand Down Expand Up @@ -115,8 +114,7 @@ private static URI buildRequestUri(String gatewayUrl, String path) throws Alipay
throw new AlipayApiException(
"gatewayUrl must be an HTTPS origin without path, query, fragment, or user info.");
}
return new URI(
"https", null, gateway.getHost(), gateway.getPort(), path, null, null);
return new URI("https", null, gateway.getHost(), gateway.getPort(), path, null, null);
} catch (URISyntaxException e) {
throw new AlipayApiException("gatewayUrl is invalid.", e);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,22 @@ public class AuthorizationControl {
*/
private List<String> allowedCurrencies;

/**
* An ordered list of ISO 4217 currency codes that defines the card-level balance-consumption
* priority. Only applyCard accepts this field in a request; do not send it to updateCard. For
* applyCard, the list must not contain duplicates and every currency must be supported by Antom.
* Omission, null, or an empty list configures no card-level preference. The field participates in
* requestId idempotency, and invalid values, more than 9 entries, duplicates, or
* capability-disabled use return PARAM_ILLEGAL. For inquireCardDetail, a configured list is
* returned in stored order; an enabled merchant without a card-level preference receives null,
* and a disabled merchant does not receive the field. For inquireCardSensitiveInfo, a whitelisted
* merchant receives the configured list, the child field is omitted when no card-level preference
* exists, and a non-whitelisted merchant does not receive the parent cardDetail object. The
* initially supported currencies are USD, EUR, GBP, HKD, AUD, CAD, CNH, JPY, and NZD; the
* supported set is configuration-driven and can change without an API contract change.
*/
private List<String> paymentPreferenceCurrencies;

private CardLimitDetail cardLimitDetail;

private CardLimitInfo cardLimitInfo;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
/*
* v1_billing_subscription_update
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/

package com.alipay.global.api.model.ams;

import lombok.*;

/** BillingSubscriptionStatusChange */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class BillingSubscriptionStatusChange {

/**
* The subscription status change action. The currently supported value is PAUSE, which pauses
* payment collection and changes the subscription status from ACTIVE to PAUSED. To reactivate a
* paused subscription, call the resume subscription API. Maximum length: 10 characters.
*/
private String action;
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* aba-inquireCardDetail
* aba-inquireCardSensitiveInfo
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
Expand Down
48 changes: 48 additions & 0 deletions src/main/java/com/alipay/global/api/model/ams/FundsType.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
/*
* v1_payments_reserve_updateRule
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/

package com.alipay.global.api.model.ams;

import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
import lombok.*;

/** The funds type. The current version supports COLLATERAL only. */
public enum FundsType {
COLLATERAL("COLLATERAL");

private String value;

FundsType(String value) {
this.value = value;
}

@JsonValue
public String getValue() {
return value;
}

@Override
public String toString() {
return String.valueOf(value);
}

@JsonCreator
public static FundsType fromValue(String value) {
for (FundsType b : FundsType.values()) {
if (b.value.equals(value)) {
return b;
}
}
throw new IllegalArgumentException("Unexpected value '" + value + "'");
}
}
8 changes: 4 additions & 4 deletions src/main/java/com/alipay/global/api/model/ams/Paginator.java
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,15 @@
@AllArgsConstructor
public class Paginator {

/** The current page number, start from 1. */
/** The current page number, starting from 1. */
private Integer currentPage;

/** The maximum records returned per page. */
/** The number of records returned per page. */
private Integer pageSize;

/** Total number of pages. */
/** The total number of pages. */
private Integer totalPage;

/** Total items that match the criteria. */
/** The total number of records that match the query criteria. */
private Integer totalCount;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
/*
* v1_payments_reserve_updateRule
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/

package com.alipay.global.api.model.ams;

import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
import lombok.*;

/** The payment method scope to which the reserve rule applies. */
public enum PaymentMethodScope {
ALL("ALL"),

CARD("CARD");

private String value;

PaymentMethodScope(String value) {
this.value = value;
}

@JsonValue
public String getValue() {
return value;
}

@Override
public String toString() {
return String.valueOf(value);
}

@JsonCreator
public static PaymentMethodScope fromValue(String value) {
for (PaymentMethodScope b : PaymentMethodScope.values()) {
if (b.value.equals(value)) {
return b;
}
}
throw new IllegalArgumentException("Unexpected value '" + value + "'");
}
}
50 changes: 50 additions & 0 deletions src/main/java/com/alipay/global/api/model/ams/ReleaseType.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
/*
* v1_payments_reserve_updateRule
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/

package com.alipay.global.api.model.ams;

import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
import lombok.*;

/** The release schedule type. FIXED_TIME uses releaseTime and INTERVAL_TIME uses retentionTime. */
public enum ReleaseType {
FIXED_TIME("FIXED_TIME"),

INTERVAL_TIME("INTERVAL_TIME");

private String value;

ReleaseType(String value) {
this.value = value;
}

@JsonValue
public String getValue() {
return value;
}

@Override
public String toString() {
return String.valueOf(value);
}

@JsonCreator
public static ReleaseType fromValue(String value) {
for (ReleaseType b : ReleaseType.values()) {
if (b.value.equals(value)) {
return b;
}
}
throw new IllegalArgumentException("Unexpected value '" + value + "'");
}
}
76 changes: 76 additions & 0 deletions src/main/java/com/alipay/global/api/model/ams/ReserveRule.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
/*
* v1_payments_reserve_inquireRuleList
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/

package com.alipay.global.api.model.ams;

import lombok.*;

/** ReserveRule */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class ReserveRule {

/**
* The Antom-assigned positive numeric reserve rule identifier. Save and return this value
* unchanged for updates, cancellation, and cursor pagination. Returned only when
* result.resultCode is SUCCESS.
*/
private String ruleId;

/**
* The ID of the merchant that owns the reserve rule. Returned only when result.resultCode is
* SUCCESS.
*/
private String merchantId;

private FundsType fundsType;

private TakeType takeType;

private PaymentMethodScope paymentMethodScope;

/**
* The rolling reserve percentage. Returned when takeType is ROLLING and result.resultCode is
* SUCCESS.
*/
private Integer ratio;

private ReleaseType releaseType;

/**
* The fixed release instant as an ISO 8601 UTC string, for example 2026-12-31T16:00:00Z. Returned
* when releaseType is FIXED_TIME and result.resultCode is SUCCESS.
*/
private String releaseTime;

/**
* The rolling retention period in days. Returned when releaseType is INTERVAL_TIME and
* result.resultCode is SUCCESS.
*/
private Integer retentionTime;

private RuleStatus ruleStatus;

/**
* The rule creation time as an ISO 8601 UTC string. Returned only when result.resultCode is
* SUCCESS.
*/
private String createTime;

/**
* The rule last-update time as an ISO 8601 UTC string. Returned only when result.resultCode is
* SUCCESS.
*/
private String updateTime;
}
53 changes: 53 additions & 0 deletions src/main/java/com/alipay/global/api/model/ams/RuleStatus.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
/*
* v1_payments_reserve_updateRule
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/

package com.alipay.global.api.model.ams;

import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
import lombok.*;

/**
* The reserve rule configuration status. This status does not indicate whether retained funds have
* been released.
*/
public enum RuleStatus {
ACTIVE("ACTIVE"),

DISABLED("DISABLED");

private String value;

RuleStatus(String value) {
this.value = value;
}

@JsonValue
public String getValue() {
return value;
}

@Override
public String toString() {
return String.valueOf(value);
}

@JsonCreator
public static RuleStatus fromValue(String value) {
for (RuleStatus b : RuleStatus.values()) {
if (b.value.equals(value)) {
return b;
}
}
throw new IllegalArgumentException("Unexpected value '" + value + "'");
}
}
Loading
Loading