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

com.cardpay.sdk.api.InvoicesApi Maven / Gradle / Ivy

The newest version!
package com.cardpay.sdk.api;

import com.cardpay.sdk.client.CollectionFormats.*;
import com.cardpay.sdk.model.InvoiceCreationResponse;
import com.cardpay.sdk.model.InvoiceGetResponse;
import com.cardpay.sdk.model.InvoiceRequest;
import retrofit2.Call;
import retrofit2.http.*;

public interface InvoicesApi {
  /**
   * Create invoice
   * Endpoint for invoice creation
   * @param invoiceRequest invoiceRequest (required)
   * @return Call<InvoiceCreationResponse>
   */
  @Headers({
    "Content-Type:application/json"
  })
  @POST("api/invoices")
  Call createInvoice(
    @retrofit2.http.Body InvoiceRequest invoiceRequest
  );

  /**
   * Get invoice information
   * Method allows to get information about single invoice.
   * @param invoiceId Invoice ID (required)
   * @return Call<InvoiceGetResponse>
   */
  @GET("api/invoices/{invoiceId}")
  Call getInvoice(
    @retrofit2.http.Path("invoiceId") String invoiceId
  );

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy