Spenda.Services.AprilPayments

Accounts

linkPaymentSources

Link payment sources to an SPP customer account

This will link payment sources to the user's SPP customer account


/PaymentServices/SPP/LinkPaymentSources

Usage and SDK Samples

curl -X GET \
 -H "Accept: application/json" \
 "https://api.dev.spenda.co/api/PaymentServices/SPP/LinkPaymentSources"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.AccountsApi;

import java.io.File;
import java.util.*;

public class AccountsApiExample {
    public static void main(String[] args) {

        // Create an instance of the API class
        AccountsApi apiInstance = new AccountsApi();

        try {
            httpActionResult_linkPaymentSourcesResponse result = apiInstance.linkPaymentSources();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountsApi#linkPaymentSources");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();


try {
    final result = await api_instance.linkPaymentSources();
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->linkPaymentSources: $e\n');
}

import org.openapitools.client.api.AccountsApi;

public class AccountsApiExample {
    public static void main(String[] args) {
        AccountsApi apiInstance = new AccountsApi();

        try {
            httpActionResult_linkPaymentSourcesResponse result = apiInstance.linkPaymentSources();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountsApi#linkPaymentSources");
            e.printStackTrace();
        }
    }
}


// Create an instance of the API class
AccountsApi *apiInstance = [[AccountsApi alloc] init];

// Link payment sources to an SPP customer account
[apiInstance linkPaymentSourcesWithCompletionHandler: 
              ^(httpActionResult_linkPaymentSourcesResponse output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var SpendaServicesAprilPayments = require('spenda_services_april_payments');

// Create an instance of the API class
var api = new SpendaServicesAprilPayments.AccountsApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.linkPaymentSources(callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class linkPaymentSourcesExample
    {
        public void main()
        {

            // Create an instance of the API class
            var apiInstance = new AccountsApi();

            try {
                // Link payment sources to an SPP customer account
                httpActionResult_linkPaymentSourcesResponse result = apiInstance.linkPaymentSources();
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AccountsApi.linkPaymentSources: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AccountsApi();

try {
    $result = $api_instance->linkPaymentSources();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountsApi->linkPaymentSources: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::AccountsApi;

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::AccountsApi->new();

eval {
    my $result = $api_instance->linkPaymentSources();
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AccountsApi->linkPaymentSources: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Create an instance of the API class
api_instance = openapi_client.AccountsApi()

try:
    # Link payment sources to an SPP customer account
    api_response = api_instance.link_payment_sources()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AccountsApi->linkPaymentSources: %s\n" % e)
extern crate AccountsApi;

pub fn main() {

    let mut context = AccountsApi::Context::default();
    let result = client.linkPaymentSources(&context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Responses


newAccount

Create a new account

This will create a new account for the user


/PaymentServices/SPP/Account/{accountUsage}

Usage and SDK Samples

curl -X POST \
 -H "Accept: application/json" \
 -H "Content-Type: application/json" \
 "https://api.dev.spenda.co/api/PaymentServices/SPP/Account/{accountUsage}" \
 -d ''
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.AccountsApi;

import java.io.File;
import java.util.*;

public class AccountsApiExample {
    public static void main(String[] args) {

        // Create an instance of the API class
        AccountsApi apiInstance = new AccountsApi();
        String accountUsage = accountUsage_example; // String | The type of account to create
        NewSPPAccountRequest newSPPAccountRequest = {"tenantName":"string","tenantRefNumber":"string","emailAddress":"string","abn":"string","isAMLKYCed":true,"isCreditChecked":true,"cardholderName":"string","cardType":"string","cardNumber":"string","expiry":"string","ccv":"string","friendlyName":"string","accountUsage":"Supplier"}; // NewSPPAccountRequest | 

        try {
            httpActionResult_newSPPAccountResponse result = apiInstance.newAccount(accountUsage, newSPPAccountRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountsApi#newAccount");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final String accountUsage = new String(); // String | The type of account to create
final NewSPPAccountRequest newSPPAccountRequest = new NewSPPAccountRequest(); // NewSPPAccountRequest | 

try {
    final result = await api_instance.newAccount(accountUsage, newSPPAccountRequest);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->newAccount: $e\n');
}

import org.openapitools.client.api.AccountsApi;

public class AccountsApiExample {
    public static void main(String[] args) {
        AccountsApi apiInstance = new AccountsApi();
        String accountUsage = accountUsage_example; // String | The type of account to create
        NewSPPAccountRequest newSPPAccountRequest = {"tenantName":"string","tenantRefNumber":"string","emailAddress":"string","abn":"string","isAMLKYCed":true,"isCreditChecked":true,"cardholderName":"string","cardType":"string","cardNumber":"string","expiry":"string","ccv":"string","friendlyName":"string","accountUsage":"Supplier"}; // NewSPPAccountRequest | 

        try {
            httpActionResult_newSPPAccountResponse result = apiInstance.newAccount(accountUsage, newSPPAccountRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountsApi#newAccount");
            e.printStackTrace();
        }
    }
}


// Create an instance of the API class
AccountsApi *apiInstance = [[AccountsApi alloc] init];
String *accountUsage = accountUsage_example; // The type of account to create (default to supplier)
NewSPPAccountRequest *newSPPAccountRequest = {"tenantName":"string","tenantRefNumber":"string","emailAddress":"string","abn":"string","isAMLKYCed":true,"isCreditChecked":true,"cardholderName":"string","cardType":"string","cardNumber":"string","expiry":"string","ccv":"string","friendlyName":"string","accountUsage":"Supplier"}; //  (optional)

// Create a new account
[apiInstance newAccountWith:accountUsage
    newSPPAccountRequest:newSPPAccountRequest
              completionHandler: ^(httpActionResult_newSPPAccountResponse output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var SpendaServicesAprilPayments = require('spenda_services_april_payments');

// Create an instance of the API class
var api = new SpendaServicesAprilPayments.AccountsApi()
var accountUsage = accountUsage_example; // {String} The type of account to create
var opts = {
  'newSPPAccountRequest': {"tenantName":"string","tenantRefNumber":"string","emailAddress":"string","abn":"string","isAMLKYCed":true,"isCreditChecked":true,"cardholderName":"string","cardType":"string","cardNumber":"string","expiry":"string","ccv":"string","friendlyName":"string","accountUsage":"Supplier"} // {NewSPPAccountRequest} 
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.newAccount(accountUsage, opts, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class newAccountExample
    {
        public void main()
        {

            // Create an instance of the API class
            var apiInstance = new AccountsApi();
            var accountUsage = accountUsage_example;  // String | The type of account to create (default to supplier)
            var newSPPAccountRequest = new NewSPPAccountRequest(); // NewSPPAccountRequest |  (optional) 

            try {
                // Create a new account
                httpActionResult_newSPPAccountResponse result = apiInstance.newAccount(accountUsage, newSPPAccountRequest);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AccountsApi.newAccount: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AccountsApi();
$accountUsage = accountUsage_example; // String | The type of account to create
$newSPPAccountRequest = {"tenantName":"string","tenantRefNumber":"string","emailAddress":"string","abn":"string","isAMLKYCed":true,"isCreditChecked":true,"cardholderName":"string","cardType":"string","cardNumber":"string","expiry":"string","ccv":"string","friendlyName":"string","accountUsage":"Supplier"}; // NewSPPAccountRequest | 

try {
    $result = $api_instance->newAccount($accountUsage, $newSPPAccountRequest);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountsApi->newAccount: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::AccountsApi;

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::AccountsApi->new();
my $accountUsage = accountUsage_example; # String | The type of account to create
my $newSPPAccountRequest = WWW::OPenAPIClient::Object::NewSPPAccountRequest->new(); # NewSPPAccountRequest | 

eval {
    my $result = $api_instance->newAccount(accountUsage => $accountUsage, newSPPAccountRequest => $newSPPAccountRequest);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AccountsApi->newAccount: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Create an instance of the API class
api_instance = openapi_client.AccountsApi()
accountUsage = accountUsage_example # String | The type of account to create (default to supplier)
newSPPAccountRequest = {"tenantName":"string","tenantRefNumber":"string","emailAddress":"string","abn":"string","isAMLKYCed":true,"isCreditChecked":true,"cardholderName":"string","cardType":"string","cardNumber":"string","expiry":"string","ccv":"string","friendlyName":"string","accountUsage":"Supplier"} # NewSPPAccountRequest |  (optional)

try:
    # Create a new account
    api_response = api_instance.new_account(accountUsage, newSPPAccountRequest=newSPPAccountRequest)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AccountsApi->newAccount: %s\n" % e)
extern crate AccountsApi;

pub fn main() {
    let accountUsage = accountUsage_example; // String
    let newSPPAccountRequest = {"tenantName":"string","tenantRefNumber":"string","emailAddress":"string","abn":"string","isAMLKYCed":true,"isCreditChecked":true,"cardholderName":"string","cardType":"string","cardNumber":"string","expiry":"string","ccv":"string","friendlyName":"string","accountUsage":"Supplier"}; // NewSPPAccountRequest

    let mut context = AccountsApi::Context::default();
    let result = client.newAccount(accountUsage, newSPPAccountRequest, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Path parameters
Name Description
accountUsage*
String
The type of account to create
Required
Body parameters
Name Description
newSPPAccountRequest

Responses


signInCustomer

Sign in to an SPP customer account

This will sign in the user to their SPP customer account and return the token


/PaymentServices/SPP/SignInCustomer

Usage and SDK Samples

curl -X GET \
 -H "Accept: application/json" \
 "https://api.dev.spenda.co/api/PaymentServices/SPP/SignInCustomer"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.AccountsApi;

import java.io.File;
import java.util.*;

public class AccountsApiExample {
    public static void main(String[] args) {

        // Create an instance of the API class
        AccountsApi apiInstance = new AccountsApi();

        try {
            httpActionResult_signInTokenResponse result = apiInstance.signInCustomer();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountsApi#signInCustomer");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();


try {
    final result = await api_instance.signInCustomer();
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->signInCustomer: $e\n');
}

import org.openapitools.client.api.AccountsApi;

public class AccountsApiExample {
    public static void main(String[] args) {
        AccountsApi apiInstance = new AccountsApi();

        try {
            httpActionResult_signInTokenResponse result = apiInstance.signInCustomer();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountsApi#signInCustomer");
            e.printStackTrace();
        }
    }
}


// Create an instance of the API class
AccountsApi *apiInstance = [[AccountsApi alloc] init];

// Sign in to an SPP customer account
[apiInstance signInCustomerWithCompletionHandler: 
              ^(httpActionResult_signInTokenResponse output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var SpendaServicesAprilPayments = require('spenda_services_april_payments');

// Create an instance of the API class
var api = new SpendaServicesAprilPayments.AccountsApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.signInCustomer(callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class signInCustomerExample
    {
        public void main()
        {

            // Create an instance of the API class
            var apiInstance = new AccountsApi();

            try {
                // Sign in to an SPP customer account
                httpActionResult_signInTokenResponse result = apiInstance.signInCustomer();
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AccountsApi.signInCustomer: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AccountsApi();

try {
    $result = $api_instance->signInCustomer();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountsApi->signInCustomer: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::AccountsApi;

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::AccountsApi->new();

eval {
    my $result = $api_instance->signInCustomer();
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AccountsApi->signInCustomer: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Create an instance of the API class
api_instance = openapi_client.AccountsApi()

try:
    # Sign in to an SPP customer account
    api_response = api_instance.sign_in_customer()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AccountsApi->signInCustomer: %s\n" % e)
extern crate AccountsApi;

pub fn main() {

    let mut context = AccountsApi::Context::default();
    let result = client.signInCustomer(&context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Responses


BankAccount

verifyBankAccount

Verify a bank account

This will verify a bank account for the user


/PaymentServices/SPP/VerifyBankAccount

Usage and SDK Samples

curl -X POST \
 -H "Accept: application/json" \
 -H "Content-Type: application/json" \
 "https://api.dev.spenda.co/api/PaymentServices/SPP/VerifyBankAccount" \
 -d ''
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.BankAccountApi;

import java.io.File;
import java.util.*;

public class BankAccountApiExample {
    public static void main(String[] args) {

        // Create an instance of the API class
        BankAccountApi apiInstance = new BankAccountApi();
        BankAccountVerificationRequest bankAccountVerificationRequest = {"businessBankAccountID":0,"accountUsage":"Supplier"}; // BankAccountVerificationRequest | 

        try {
            httpActionResult_bankAccountVerificationResponse result = apiInstance.verifyBankAccount(bankAccountVerificationRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling BankAccountApi#verifyBankAccount");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final BankAccountVerificationRequest bankAccountVerificationRequest = new BankAccountVerificationRequest(); // BankAccountVerificationRequest | 

try {
    final result = await api_instance.verifyBankAccount(bankAccountVerificationRequest);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->verifyBankAccount: $e\n');
}

import org.openapitools.client.api.BankAccountApi;

public class BankAccountApiExample {
    public static void main(String[] args) {
        BankAccountApi apiInstance = new BankAccountApi();
        BankAccountVerificationRequest bankAccountVerificationRequest = {"businessBankAccountID":0,"accountUsage":"Supplier"}; // BankAccountVerificationRequest | 

        try {
            httpActionResult_bankAccountVerificationResponse result = apiInstance.verifyBankAccount(bankAccountVerificationRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling BankAccountApi#verifyBankAccount");
            e.printStackTrace();
        }
    }
}


// Create an instance of the API class
BankAccountApi *apiInstance = [[BankAccountApi alloc] init];
BankAccountVerificationRequest *bankAccountVerificationRequest = {"businessBankAccountID":0,"accountUsage":"Supplier"}; //  (optional)

// Verify a bank account
[apiInstance verifyBankAccountWith:bankAccountVerificationRequest
              completionHandler: ^(httpActionResult_bankAccountVerificationResponse output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var SpendaServicesAprilPayments = require('spenda_services_april_payments');

// Create an instance of the API class
var api = new SpendaServicesAprilPayments.BankAccountApi()
var opts = {
  'bankAccountVerificationRequest': {"businessBankAccountID":0,"accountUsage":"Supplier"} // {BankAccountVerificationRequest} 
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.verifyBankAccount(opts, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class verifyBankAccountExample
    {
        public void main()
        {

            // Create an instance of the API class
            var apiInstance = new BankAccountApi();
            var bankAccountVerificationRequest = new BankAccountVerificationRequest(); // BankAccountVerificationRequest |  (optional) 

            try {
                // Verify a bank account
                httpActionResult_bankAccountVerificationResponse result = apiInstance.verifyBankAccount(bankAccountVerificationRequest);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling BankAccountApi.verifyBankAccount: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\BankAccountApi();
$bankAccountVerificationRequest = {"businessBankAccountID":0,"accountUsage":"Supplier"}; // BankAccountVerificationRequest | 

try {
    $result = $api_instance->verifyBankAccount($bankAccountVerificationRequest);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling BankAccountApi->verifyBankAccount: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::BankAccountApi;

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::BankAccountApi->new();
my $bankAccountVerificationRequest = WWW::OPenAPIClient::Object::BankAccountVerificationRequest->new(); # BankAccountVerificationRequest | 

eval {
    my $result = $api_instance->verifyBankAccount(bankAccountVerificationRequest => $bankAccountVerificationRequest);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling BankAccountApi->verifyBankAccount: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Create an instance of the API class
api_instance = openapi_client.BankAccountApi()
bankAccountVerificationRequest = {"businessBankAccountID":0,"accountUsage":"Supplier"} # BankAccountVerificationRequest |  (optional)

try:
    # Verify a bank account
    api_response = api_instance.verify_bank_account(bankAccountVerificationRequest=bankAccountVerificationRequest)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling BankAccountApi->verifyBankAccount: %s\n" % e)
extern crate BankAccountApi;

pub fn main() {
    let bankAccountVerificationRequest = {"businessBankAccountID":0,"accountUsage":"Supplier"}; // BankAccountVerificationRequest

    let mut context = BankAccountApi::Context::default();
    let result = client.verifyBankAccount(bankAccountVerificationRequest, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Body parameters
Name Description
bankAccountVerificationRequest

Responses