Skip to content



This function loads a list of customers from a business account.

Request Parameters#

Type Description
count Number Count is used to tell Miva how many records to return.
offset Offset Used in conjunction with the Count parameter for paginating results of large datasets. Default is 0.
sort String Field to sort results by. Available sorting fields listed below. Use - prefix for a descending sort.
filter Object Array of Object containing search filters. See usage here
The business id updated account
The business name for the updated account
The business name for the updated account
assigned String String indicating if assigned customers be returned.
unassigned String String indicating if unassigned customers be returned.

Supported Sort Columns#

One of these values would be passed in the sort request parameter to have the results sorted by that column. Value may be preceded by - for a descending sort.

Sort Description
id Customer ID

Response Parameters#

Type Description
success Boolean Boolean value indicating if the API request was successful
total_count Number The number of customers returned for the business account
start_offset Number The offset starting point for pagination of return data
id Number The customer id
account_id Number The account id for the customer
login String Customer login name
pw_email String Customer email for password
ship_id Number The shipping id for the customer
ship_res Boolean Boolean value indicating if the shipping address is residential
ship_fname String Customer shipping first name
ship_lname String Customer shipping last name
ship_email String Email address for shipping
ship_comp String Company name for shipping
ship_phone String Phone number for shipping
ship_fax String Fax number for shipping
ship_addr1 String First field for shipping address
ship_addr2 String Second field for shipping address
ship_city String City for shipping
ship_state String State for shipping
ship_zip String Zip code for shipping
ship_cntry String Country for shipping
bill_id Number The billing id for the customer
bill_fname String First name for billing
bill_lname String Last name for billing
bill_email String Email address for billing
bill_comp String Company Name for billing
bill_phone String Phone number for billing
bill_fax String Fax number for billing
bill_addr1 String First field for billing address
bill_addr2 String Second field for billing address
bill_city String City for billing
bill_state String State for billing
bill_zip String Zip code for billing
bill_cntry String Country for billing
tax_exempt Boolean Boolean value indicating if the customer is tax exempt
order_cnt Number Number of orders placed by the customer
order_avg Number Average order value for the customer
formatted_order_avg String Currency formatted average order value for the customer
order_tot Number Total order value for the customer
formatted_order_tot String Currency formatted total order value for the customer
note_count Number Number of notes associated with the customer
dt_created Number Unix timestamp for the date the customer was created
dt_login Number Unix timestamp for the last customer login date
dt_pwchg Number Unix timestamp for the last password change
credit Number Total credit for the customer
formatted_credit String Currency formatted total credit for the customer
assigned Boolean Boolean value indicating if the customer is assigned to an employee
business_title String Business title for the customer

Example Request#

    "Store_code": "beta",
    "Function": "BusinessAccountCustomerList_Load_Query",
    "BusinessAccount_ID": 2,
    "Assigned": "true",
    "Count": 39,
    "Filter": "",
    "Offset": 0,
    "Sort": "id",
    "Unassigned": "true"

Example Response#

    "success": 1,
    "data": {
        "total_count": 18,
        "start_offset": 0,
        "data": [
                "id": 1,
                "account_id": 4,
                "login": "jondoe",
                "pw_email": "",
                "ship_id": 1,
                "ship_res": true,
                "ship_fname": "Maynard",
                "ship_lname": "Batalla",
                "ship_email": "",
                "ship_comp": "MivaCorp",
                "ship_phone": "555-555-5555",
                "ship_fax": "555-555-1212",
                "ship_addr1": "5060 Santa Fe St",
                "ship_addr2": "",
                "ship_city": "San Diego",
                "ship_state": "CA",
                "ship_zip": "92109",
                "ship_cntry": "US",
                "bill_id": 1,
                "bill_fname": "Maynard",
                "bill_lname": "Batalla",
                "bill_email": "",
                "bill_comp": "MivaCorp",
                "bill_phone": "555-555-5555",
                "bill_fax": "555-555-1212",
                "bill_addr1": "5060 Santa Fe St",
                "bill_addr2": "",
                "bill_city": "San Diego",
                "bill_state": "CA",
                "bill_zip": "92109",
                "bill_cntry": "US",
                "tax_exempt": false,
                "order_cnt": 100,
                "order_avg": 385.16,
                "formatted_order_avg": "$385.16",
                "order_tot": 38515.6,
                "formatted_order_tot": "$38,515.60",
                "note_count": 2,
                "dt_created": 1623693375,
                "dt_login": 0,
                "dt_pwchg": 1623693375,
                "credit": 0.0,
                "formatted_credit": "$0.00",
                "assigned": false,
                "business_title": ""
                "id": 2,
                "account_id": 4,
                "login": "realm",
                "pw_email": "",
                "ship_id": 3,
                "ship_res": true,
                "ship_fname": "Victor",
                "ship_lname": "Lamay",
                "ship_email": "",
                "ship_comp": "Fellowship of the sword",
                "ship_phone": "555-555-5555",
                "ship_fax": "",
                "ship_addr1": "Bear and Ogre",
                "ship_addr2": "",
                "ship_city": "Sidsilver",
                "ship_state": "NV",
                "ship_zip": "89701",
                "ship_cntry": "US",
                "bill_id": 4,
                "bill_fname": "Krusk",
                "bill_lname": "Eroogdush",
                "bill_email": "",
                "bill_comp": "Fellowship of the sword",
                "bill_phone": "555-555-5555",
                "bill_fax": "",
                "bill_addr1": "Bear and Ogre",
                "bill_addr2": "",
                "bill_city": "Sidsilver",
                "bill_state": "NV",
                "bill_zip": "89701",
                "bill_cntry": "US",
                "tax_exempt": false,
                "order_cnt": 0,
                "order_avg": 0.0,
                "formatted_order_avg": "$0.00",
                "order_tot": 0.0,
                "formatted_order_tot": "$0.00",
                "note_count": 0,
                "dt_created": 1623693375,
                "dt_login": 0,
                "dt_pwchg": 1623693375,
                "credit": 0.0,
                "formatted_credit": "$0.00",
                "assigned": false,
                "business_title": ""

Error Responses#

Error Code Error Message Error Description
MER-JSN-00024 Missing required parameter Function Missing required parameter Function
MER-CUS-JSN-00019 Business account not found Business account not found by ID