33 lines
799 B
Java
33 lines
799 B
Java
package com.test.payment.dto;
|
|
|
|
import jakarta.validation.constraints.DecimalMin;
|
|
import jakarta.validation.constraints.NotBlank;
|
|
import jakarta.validation.constraints.NotNull;
|
|
import lombok.Data;
|
|
|
|
import java.math.BigDecimal;
|
|
|
|
/**
|
|
* Upsert body for a configurable provider ceiling
|
|
* (PUT /api/payments/limits).
|
|
*/
|
|
@Data
|
|
public class ProviderLimitDto {
|
|
|
|
@NotBlank(message = "provider is required")
|
|
private String provider;
|
|
|
|
@NotBlank(message = "period is required")
|
|
private String period;
|
|
|
|
/** PER_PAYER (default) or MERCHANT. */
|
|
private String scope;
|
|
|
|
@NotNull(message = "maxAmount is required")
|
|
@DecimalMin(value = "0.01", message = "maxAmount must be greater than 0")
|
|
private BigDecimal maxAmount;
|
|
|
|
private String currency;
|
|
|
|
private Boolean active;
|
|
} |