from __future__ import print_function
import time
import authorizenet_rest
from authorizenet_rest.rest import ApiException

from authorizenet_rest.apis.customers_api import CustomersApi
from pprint import pprint
import os
import sys

ExternalConfig = imp.load_source('modulename', '.\ExternalConfiguration.py')

def get_all_customer():
    # create an instance of the API class
    ExternalConfig.setConfig();
    apiclient = ExternalConfig.configureApiClient();
    authorization = ExternalConfig.getAuthorization()
    api_instance = authorizenet_rest.apis.customers_api.CustomersApi(apiclient)
    print("Check Output")
    try:
        api_response = api_instance.get_all_customers()
        pprint(api_response)
    except ApiException as e:
        print("Exception when calling AddressesApi->create_customer_address: %s\n" % e)


if (os.path.basename(__file__) == os.path.basename(sys.argv[0])):
    get_all_customer()
