All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.truelayer.java.payouts.IPayoutsApi Maven / Gradle / Ivy

There is a newer version: 16.0.0
Show newest version
package com.truelayer.java.payouts;

import com.truelayer.java.entities.RequestScopes;
import com.truelayer.java.http.entities.ApiResponse;
import com.truelayer.java.payouts.entities.CreatePayoutRequest;
import com.truelayer.java.payouts.entities.CreatePayoutResponse;
import com.truelayer.java.payouts.entities.Payout;
import java.util.Map;
import java.util.concurrent.CompletableFuture;
import retrofit2.http.*;

public interface IPayoutsApi {

    /**
     * Pay out from one of your merchant accounts.
     * @param scopes the scopes to be used by the underlying Oauth token
     * @param headers map representing custom HTTP headers to be sent
     * @param request a create payout request payload
     * @return the response of the Create Payout operation
     * @see Create Payout API reference
     */
    @POST("/payouts")
    CompletableFuture> createPayout(
            @Tag RequestScopes scopes, @HeaderMap Map headers, @Body CreatePayoutRequest request);

    /**
     * Returns payout details.
     * @param scopes the scopes to be used by the underlying Oauth token
     * @param payoutId the payout identifier
     * @return the response of the Get Payout operation
     * @see Get Payout API reference
     */
    @GET("/payouts/{id}")
    CompletableFuture> getPayout(@Tag RequestScopes scopes, @Path("id") String payoutId);
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy