Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
189 lines (148 sloc) 5.33 KB

CSV Upload

File Formatting

  • Values must be UTF-8 encoded
  • Values must be comma delimited
  • Records must end with a newline (\n)
  • Any value may be optionally quoted via double quote (") characters
  • Any field containing a double quote must be quoted. The escape character for an embedded quote is a second quote character. (For example: "Customers think this product is ""Amazing!""")
  • Each record must contain exactly the same number of fields as the header does
  • No carriage return (\r) or newline (\n) may exist within a record
  • Date / Time fields must be formatted as follows:
Date Format Examples
Unix Timestamp / Epoch 1435708800
ISO 8601

2019-04-11T18:43:29+00:00

2019-04-11T18:43:29Z

2019-04-11

%Y-%m-%d %H:%M:%S%:z 2014-09-01 13:34:08+00:00
%Y-%m-%d %H:%M:%S 2014-09-01 13:34:08
'%m/%d/%y %H:%M 09/01/14 13:34
%m/%d/%y %H:%M:%S 09/01/14 13:34:08
%m/%d/%Y %H:%M:%S 09/01/2014 13:34:08
%m/%d/%Y %H:%M 09/01/2014 13:34
{% hint style="warning" %} If time and time zone are not provided the time is assumed be 12am UTC. {% endhint %}

Error Handling

Any record that contains an invalid field will be ignored. If more than 1% of the data is invalid, the entire file will be rejected. The Activity Log will show the status of the uploads, any errors generated, and a success entry if the data is loaded successfully.

File Naming

Object File Name Prefix
Products zaius_products
Customers zaius_customers
Orders zaius_orders
Events zaius_events
Lists zaius_list

Where to upload?

UI

  1. Go to Account Settings -> Integrations
  2. Select Upload CSV -> Browse
  3. Select the file that follows the file name and format conventions outlined below

Files can also be imported via Amazon S3:

{% page-ref page="s3.md" %}

Examples & Samples

{% hint style="info" %} The files below are only basic examples.

Refer to the Zaius schema section to learn about all available default fields and creating custom fields & objects. {% endhint %}

Customers

{% file src="../.gitbook/assets/zaius_customers_example.csv" %}

Products

{% file src="../.gitbook/assets/zaius_products_example.csv" %}

Orders

{% file src="../.gitbook/assets/zaius_orders_example.csv" %}

{% hint style="info" %} Refer to Orders documentation for field descriptions and data types. {% endhint %}

  • Shared Fields
    • action
      • value should be one of purchase | refund | return | cancel
    • order_id (REQUIRED)
    • ts (REQUIRED)
  • Order Summary Fields
    • total
    • discount
    • subtotal
    • tax
    • shipping
    • coupon_code
    • first_name
    • last_name
    • bill_address
    • ship_address

{% hint style="danger" %} Order Line Item fields (and the associated events) cannot be updated in the future, only summary fields (for refunds, returns, cancellations). {% endhint %}

  • Order Line Item Fields (one row per line item) - unavailable for refund, return & cancel
    • item_product_id
    • item_sku
    • item_price
    • item_quantity
    • item_discount
    • item_subtotal

{% hint style="success" %} Prefix all custom event fields with item_ to indicate the field exists on the Event object, otherwise it will be assumed you attempting to update the Orders object. {% endhint %}

Events

{% file src="../.gitbook/assets/zaius_events_example.csv" %}

Lists

{% hint style="warning" %} Uploading a List file without an "action" column assumes a subscription for each email {% endhint %}

Upload to Single List

{% file src="../.gitbook/assets/zaius_list_yourlistidhere.csv" %}

Upload to Multiple Lists

{% file src="../.gitbook/assets/zaius_list_example.csv" %}

Custom Objects

{% hint style="info" %} Replace customobject with the name of the custom object {% endhint %}

{% file src="../.gitbook/assets/zaius_customobject_example.csv" %}

{% hint style="warning" %} All custom object updates must include the primary key (or keys in the case of composite keys) in the file (e.g. id) {% endhint %}

You can’t perform that action at this time.