Package ru.loolzaaa.youkassa.processors
Class RefundProcessor
- java.lang.Object
-
- ru.loolzaaa.youkassa.processors.RefundProcessor
-
public class RefundProcessor extends java.lang.Object
Processor forRefund
entity.Using the API, you can return payments - in full or in part. The refund procedure depends on the payment method (payment_method) of the original payment. When paying with a bank card, the money is returned to the card that was used to make the payment.
Some payment methods (for example, cash) do not support returns.
Use
ApiClient
for API server communication.
-
-
Constructor Summary
Constructors Constructor Description RefundProcessor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Refund
create(Refund refundParams, java.lang.String idempotencyKey)
Creates newRefund
entity with certain parameters.PaginatedResponse<Refund>
findAll(RefundList refundList)
Receive information about all refunds with some filter conditions.Refund
findById(java.lang.String refundId)
Receive information about someRefund
by its identifier.
-
-
-
Method Detail
-
findById
public Refund findById(java.lang.String refundId)
Receive information about someRefund
by its identifier.- Parameters:
refundId
- refund identifier- Returns:
- refund entity with actual status
- Throws:
java.lang.IllegalArgumentException
- if refund id is null or empty
-
findAll
public PaginatedResponse<Refund> findAll(RefundList refundList)
Receive information about all refunds with some filter conditions.- Parameters:
refundList
- collection with filter conditions- Returns:
- listed refund entities
- See Also:
PaginatedResponse
-
create
public Refund create(Refund refundParams, java.lang.String idempotencyKey)
Creates newRefund
entity with certain parameters.Generate random idempotency key if corresponding argument is null.
- Parameters:
refundParams
- parameters for new refundidempotencyKey
- idempotency key- Returns:
- new refund entity with actual status
- Throws:
java.lang.IllegalArgumentException
- if refund parameters is null
-
-