Template Objects
Listed below are the SparkLayer objects available to use in templates and content zones. The objects available will depend on the themes template, refer to this documentation to see which objects are available for specific templates.
Address
Properties
Key | Type | Description | Example(s) |
|---|---|---|---|
name | string | - | - |
company | string | - | - |
address_line1 | string | - | - |
address_line2 | string,null | - | - |
city | string | - | - |
region_code | string,null | - | - |
postal_code | string,null | - | - |
country_code | string | - | - |
phone | string,null | - | - |
Customer
Properties
Key | Type | Description | Example(s) |
|---|---|---|---|
id | string | - | - |
title | string | - | - |
first_name | string | - | - |
last_name | string | - | - |
string | - | - | |
company_name | string,null | - | - |
external_id | string | - | - |
accounting_id | string | - | - |
ContentZone
Content zones can be configured as part of the invoicing feature
Note: Content zones may be configured to contain liquid variables and should be handled in templates accordingly
Properties
Key | Type | Description | Example(s) |
|---|---|---|---|
title | string,null | - | - |
content | string,null | - | - |
InvoiceSettings
Properties
Key | Type | Description | Example(s) |
|---|---|---|---|
content_zones.zone_1 | - | - | |
content_zones.zone_2 | - | - | |
content_zones.zone_3 | - | - |
LineItem
Properties
Key | Type | Description | Example(s) |
|---|---|---|---|
custom_attributes.[].key | string | - | - |
custom_attributes.[].value | string | - | - |
identifiers.sku | string,null | - | - |
name_child | string,null | - | - |
name_parent | string | - | - |
quantity | integer | - | - |
line_total | unknown | - | - |
unit_total | unknown | - | - |
image_url | string,null | - | - |
product_slug | string,null | - | - |
rrp | unknown | - | - |
barcode | string,null | - | - |
LineTotal
Properties
Merchant
Merchant details
Properties
Key | Type | Description | Example(s) |
|---|---|---|---|
address1 | string,null | The address line 1 associated to the merchants store address | - |
address2 | string,null | The address line 2 associated to the merchants store address | - |
base_currency | string,null | The base currency used by the store | USD,GBP |
city | string,null | The city associated to the merchants store address | - |
region | string,null | The region code associated to the merchants store address | - |
country | string,null | The country code associated to the merchants store address | GB |
string,null | The email associated to the merchant | - | |
phone | string,null | The phone number associated to the merchants store | - |
postcode | string,null | The postcode associated to the merchants store address | - |
store_name | string,null | The connected platforms store name | - |
timezone | string,null | - | - |
url | string,null | - | - |
locale | string,null | The default locale of the store | en,fr |
Money
Represents a monetary value
Properties
Key | Type | Description | Example(s) |
|---|---|---|---|
amount | string | - | - |
currency | string | - | GBP,USD |
Package
Properties
Purchase
Properties
Key | Type | Description | Example(s) |
|---|---|---|---|
currency_code | string | - | - |
billing_address | - | - | |
customers.sparklayer | - | - | |
custom_fields.[].name | string | - | - |
custom_fields.[].value | string,null | - | - |
customer_reference | string,null | - | - |
dates.created_at | string | - | - |
dates.updated_at | string | - | - |
dates.placed_at | string,null | - | - |
dates.calculated_submitted_at | string,null | - | - |
identifiers.visible | string | - | - |
packages | array of Package | - | - |
line_items | array of LineItem | - | - |
subtotal | - | - | |
tax | - | - | |
shipping_cost | - | - | |
calculated_total | - | - | |
tax_lines | array of TaxLine | - | - |
UnitTotal
Properties
TaxLine
Properties
Key | Type | Description | Example(s) |
|---|---|---|---|
title | string | - | - |
rate | number | - | - |
amount.number | string | - | - |
amount.currency | string | - | - |
PurchaseHistoryMessage
Properties
Key | Type | Description | Example(s) |
|---|---|---|---|
body | string | - | - |
created_at | string | - | - |
customer | - | - |
AssignmentDetails
Properties
Key | Type | Description | Example(s) |
|---|---|---|---|
assigned_by | - | - | |
assigned_on | string | - | - |
Note: This documentation is in beta and may not be accurate, please contact support if you have any issues or questions