Skip to content

Latest commit

 

History

History
459 lines (336 loc) · 14.7 KB

PaymentDetailsApi.md

File metadata and controls

459 lines (336 loc) · 14.7 KB

PaymentDetailsApi

All URIs are relative to https://{customerId}.billabear.cloud/api/v1

Method HTTP request Description
completeFrontendPaymentDetails POST /customer/{customerId}/payment-methods/frontend-payment-token Complete Frontend Detail Collection
deletePaymentDetails DELETE /payment-methods/{paymentDetailsId} Delete
deletePaymentDetailsCustomer DELETE /customer/{customerId}/payment-methods/{paymentDetailsId} Delete With Customer
getPaymentDetails GET /payment-methods/{paymentDetailsId} Fetch
listPaymentDetails GET /customer/{customerId}/payment-methods List Customer's Payment Details
makeDefaultPaymentDetails POST /payment-methods/{paymentDetailsId}/default Make Default
makeDefaultPaymentDetailsCustomer POST /customer/{customerId}/payment-methods/{paymentDetailsId}/default Make Default With Customer
startFrontendPaymentDetails GET /customer/{customerId}/payment-methods/frontend-payment-token Start Frontend Detail Collection

completeFrontendPaymentDetails

PaymentDetails completeFrontendPaymentDetails(body, customerId)

Complete Frontend Detail Collection

Complete frontend payment details

Example

// Import classes:
//import com.billabear.sdk.invoker.ApiClient;
//import com.billabear.sdk.invoker.ApiException;
//import com.billabear.sdk.invoker.Configuration;
//import com.billabear.sdk.invoker.auth.*;
//import com.billabear.sdk.api.PaymentDetailsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: ApiKeyAuth
ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
ApiKeyAuth.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.setApiKeyPrefix("Token");

PaymentDetailsApi apiInstance = new PaymentDetailsApi();
FrontendToken body = new FrontendToken(); // FrontendToken | 
String customerId = "customerId_example"; // String | The id of the customer to retrieve
try {
    PaymentDetails result = apiInstance.completeFrontendPaymentDetails(body, customerId);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling PaymentDetailsApi#completeFrontendPaymentDetails");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
body FrontendToken
customerId String The id of the customer to retrieve

Return type

PaymentDetails

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

deletePaymentDetails

deletePaymentDetails(paymentDetailsId)

Delete

Delete Payment Details

Example

// Import classes:
//import com.billabear.sdk.invoker.ApiClient;
//import com.billabear.sdk.invoker.ApiException;
//import com.billabear.sdk.invoker.Configuration;
//import com.billabear.sdk.invoker.auth.*;
//import com.billabear.sdk.api.PaymentDetailsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: ApiKeyAuth
ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
ApiKeyAuth.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.setApiKeyPrefix("Token");

PaymentDetailsApi apiInstance = new PaymentDetailsApi();
String paymentDetailsId = "paymentDetailsId_example"; // String | The id of the payment details
try {
    apiInstance.deletePaymentDetails(paymentDetailsId);
} catch (ApiException e) {
    System.err.println("Exception when calling PaymentDetailsApi#deletePaymentDetails");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
paymentDetailsId String The id of the payment details

Return type

null (empty response body)

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

deletePaymentDetailsCustomer

deletePaymentDetailsCustomer(customerId, paymentDetailsId)

Delete With Customer

Delete Payment Details

Example

// Import classes:
//import com.billabear.sdk.invoker.ApiClient;
//import com.billabear.sdk.invoker.ApiException;
//import com.billabear.sdk.invoker.Configuration;
//import com.billabear.sdk.invoker.auth.*;
//import com.billabear.sdk.api.PaymentDetailsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: ApiKeyAuth
ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
ApiKeyAuth.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.setApiKeyPrefix("Token");

PaymentDetailsApi apiInstance = new PaymentDetailsApi();
String customerId = "customerId_example"; // String | The id of the customer to retrieve
String paymentDetailsId = "paymentDetailsId_example"; // String | The id of the payment details
try {
    apiInstance.deletePaymentDetailsCustomer(customerId, paymentDetailsId);
} catch (ApiException e) {
    System.err.println("Exception when calling PaymentDetailsApi#deletePaymentDetailsCustomer");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
customerId String The id of the customer to retrieve
paymentDetailsId String The id of the payment details

Return type

null (empty response body)

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

getPaymentDetails

PaymentDetails getPaymentDetails(paymentDetailsId)

Fetch

Fetch the payment cards

Example

// Import classes:
//import com.billabear.sdk.invoker.ApiClient;
//import com.billabear.sdk.invoker.ApiException;
//import com.billabear.sdk.invoker.Configuration;
//import com.billabear.sdk.invoker.auth.*;
//import com.billabear.sdk.api.PaymentDetailsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: ApiKeyAuth
ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
ApiKeyAuth.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.setApiKeyPrefix("Token");

PaymentDetailsApi apiInstance = new PaymentDetailsApi();
String paymentDetailsId = "paymentDetailsId_example"; // String | The id of the payment details
try {
    PaymentDetails result = apiInstance.getPaymentDetails(paymentDetailsId);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling PaymentDetailsApi#getPaymentDetails");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
paymentDetailsId String The id of the payment details

Return type

PaymentDetails

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

listPaymentDetails

InlineResponse2007 listPaymentDetails(customerId)

List Customer's Payment Details

List all customers <br><br>Added in version 1.1

Example

// Import classes:
//import com.billabear.sdk.invoker.ApiClient;
//import com.billabear.sdk.invoker.ApiException;
//import com.billabear.sdk.invoker.Configuration;
//import com.billabear.sdk.invoker.auth.*;
//import com.billabear.sdk.api.PaymentDetailsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: ApiKeyAuth
ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
ApiKeyAuth.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.setApiKeyPrefix("Token");

PaymentDetailsApi apiInstance = new PaymentDetailsApi();
String customerId = "customerId_example"; // String | The id of the customer to retrieve
try {
    InlineResponse2007 result = apiInstance.listPaymentDetails(customerId);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling PaymentDetailsApi#listPaymentDetails");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
customerId String The id of the customer to retrieve

Return type

InlineResponse2007

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

makeDefaultPaymentDetails

makeDefaultPaymentDetails(customerId, paymentDetailsId)

Make Default

Delete Payment Details

Example

// Import classes:
//import com.billabear.sdk.invoker.ApiClient;
//import com.billabear.sdk.invoker.ApiException;
//import com.billabear.sdk.invoker.Configuration;
//import com.billabear.sdk.invoker.auth.*;
//import com.billabear.sdk.api.PaymentDetailsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: ApiKeyAuth
ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
ApiKeyAuth.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.setApiKeyPrefix("Token");

PaymentDetailsApi apiInstance = new PaymentDetailsApi();
String customerId = "customerId_example"; // String | The id of the customer to retrieve
String paymentDetailsId = "paymentDetailsId_example"; // String | The id of the payment details
try {
    apiInstance.makeDefaultPaymentDetails(customerId, paymentDetailsId);
} catch (ApiException e) {
    System.err.println("Exception when calling PaymentDetailsApi#makeDefaultPaymentDetails");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
customerId String The id of the customer to retrieve
paymentDetailsId String The id of the payment details

Return type

null (empty response body)

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

makeDefaultPaymentDetailsCustomer

makeDefaultPaymentDetailsCustomer(customerId, paymentDetailsId)

Make Default With Customer

Delete Payment Details

Example

// Import classes:
//import com.billabear.sdk.invoker.ApiClient;
//import com.billabear.sdk.invoker.ApiException;
//import com.billabear.sdk.invoker.Configuration;
//import com.billabear.sdk.invoker.auth.*;
//import com.billabear.sdk.api.PaymentDetailsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: ApiKeyAuth
ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
ApiKeyAuth.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.setApiKeyPrefix("Token");

PaymentDetailsApi apiInstance = new PaymentDetailsApi();
String customerId = "customerId_example"; // String | The id of the customer to retrieve
String paymentDetailsId = "paymentDetailsId_example"; // String | The id of the payment details
try {
    apiInstance.makeDefaultPaymentDetailsCustomer(customerId, paymentDetailsId);
} catch (ApiException e) {
    System.err.println("Exception when calling PaymentDetailsApi#makeDefaultPaymentDetailsCustomer");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
customerId String The id of the customer to retrieve
paymentDetailsId String The id of the payment details

Return type

null (empty response body)

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

startFrontendPaymentDetails

FrontendToken startFrontendPaymentDetails(customerId)

Start Frontend Detail Collection

Start frontend payment details

Example

// Import classes:
//import com.billabear.sdk.invoker.ApiClient;
//import com.billabear.sdk.invoker.ApiException;
//import com.billabear.sdk.invoker.Configuration;
//import com.billabear.sdk.invoker.auth.*;
//import com.billabear.sdk.api.PaymentDetailsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: ApiKeyAuth
ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
ApiKeyAuth.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.setApiKeyPrefix("Token");

PaymentDetailsApi apiInstance = new PaymentDetailsApi();
String customerId = "customerId_example"; // String | The id of the customer to retrieve
try {
    FrontendToken result = apiInstance.startFrontendPaymentDetails(customerId);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling PaymentDetailsApi#startFrontendPaymentDetails");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
customerId String The id of the customer to retrieve

Return type

FrontendToken

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json