com.truelayer.java.merchantaccounts.entities.transactions.Refund Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of truelayer-java Show documentation
Show all versions of truelayer-java Show documentation
TrueLayer Java SDK for https://truelayer.com
package com.truelayer.java.merchantaccounts.entities.transactions;
import com.fasterxml.jackson.annotation.JsonGetter;
import com.truelayer.java.entities.CurrencyCode;
import com.truelayer.java.entities.beneficiary.PaymentSource;
import java.time.ZonedDateTime;
import java.util.Optional;
import lombok.EqualsAndHashCode;
import lombok.Value;
@Value
@EqualsAndHashCode(callSuper = false)
public class Refund extends Transaction {
Type type = Type.REFUND;
String id;
CurrencyCode currency;
int amountInMinor;
/**
* Represents the refund status, either pending
or executed
.
*/
Transaction.Status status;
ZonedDateTime createdAt;
ZonedDateTime executedAt;
PaymentSource beneficiary;
Payout.ContextCode contextCode;
String refundId;
String paymentId;
@JsonGetter
public Optional getExecutedAt() {
return Optional.ofNullable(executedAt);
}
}