Clients

Clients are the accounts which have access via the API and control panel to the Vault Billing System. There are two types of clients:

  • Service Providers - Can create end user accounts, and edit/suspend/delete accounts which they have created.
  • End Users - Can only edit their own account.

Object Data

Variable Type Required Format/Example
id automatic 123456789
client_type int "1" = Service Provider, "2" = End User
parent_id int The client ID of the parent account, if available.
api_id api_id The client's API Identifier string.
secret_key string The secret key used in API requests.
username string The username of the client account.
first_name string yes Joe
last_name string yes Smith
company string yes John Smith's Body Shop
address_1 string 12345 Simulated St.
address_2 string For apartment/unit/suite #'s, eg. "Unit 2".
city string Toronto
state string The state/province/region of the customer. For the US and Canada, this must be supplied as the two letter abbreviation, eg. "ON"
country country The ISO 3166-1 alpha-2 code of the customer's country, e.g. "CA", "US".
postal_code string The zip or postal code of the user, e.g. "A1B2C3", "90210".
email email A valid email address for the customer.
phone string 1-555-555-0000
time zone string The time zone offset of the user (e.g., "UM12"). Available options: UM12 (-12 GMT) to UM1, UTC (GMT), and UP1 to UP12 (+12 GMT).

Method: NewClient

Create a new client. Only available to Service Providers.

Required data:

  • first_name
  • last_name
  • company
  • email
  • username
  • password

Optional data:

  • Any/all of the object data above, except id, secret_key, api_id.

Response data:

  • response_code of "300", upon success.
  • client_id - The ID of the new client.
  • api_id - The auto-generated API Identifier of the client.
  • secret_key - The auto-generated Secret Key of the client.

Method: UpdateClient

Update an existing client. You must have ownership of this account.

Required data:

  • client_id

Optional data:

  • Any/all of the object data above, except id, secret_key, api_id.

Response data:

  • response_code of "301", upon success.

Method: UpdateAccount

Update your own client account.

Required data:

  • n/a

Response data:

  • response_code of "301", upon success.

Method: SuspendClient

Suspend API and Control Panel access for a client. You must have ownership of this account.

Required data:

  • client_id - The ID of the client.

Response data:

  • response_code of "302", upon success.

Method: UnsuspendClient

Re-instate API and Control Panel access for a client. You must have ownership of this account.

Required data:

  • client_id - The ID of the client.

Response data:

  • response_code of "303", upon success.

Method: DeleteClient

Delete a client account. You must have ownership of this account.

Required data:

  • client_id - The ID of the client.

Response data:

  • response_code of "304", upon success.

Method: GetClient

Get data for a client account.

Required data:

  • client_id - The ID of the client.

Response data:

  • A client node with all data in Object Data.

Method: GetClients

Searches all clients. If a request is made without any filters all clients under your authenticated account are returned.

Optional filters:

  • suspended - Set to "1" to retrieve only suspended accounts, "0" to receive only non-suspended accounts. Default: All accounts.
  • username - The client's username.
  • email - The client's email.
  • sort - The field on which to sort retrieved records. Default: "id". Available values:
    • id
    • username
    • email
    • first_name
    • last_name
  • sort_dir - The direction in which to sort retrieved records. Default: "asc". Can also be "desc".

Response data:

  • results - Number of records in this response
  • total_results - Total # of records to retrieve. Use offset to gather all records over multiple iterated requests.
  • clients
    • A client node for each returned client.
      • All data available for the client, in the format of GetClient.

Compare our service and prices to our competitors and
Give Us A Call

(866) 927-7180


All rights reserved. Built on the CodeIgniter framework.