Store settings
Summary of store settings endpoints
- GET /admin/api/ecommerce/v1/settings - fetch store settings.
- PUT /admin/api/ecommerce/v1/settings - update store settings.
All endpoints take optional query parameters that enhance the response objects:
include
— enhance the response objects (e.g.include=translations
). Supported values are:translations
— includes translations for all translatable objects and keys.
language_code
— display all top-level values in the given language context.
Get store settings data
GET /admin/api/ecommerce/v1/settings
Example response:
Status: 200 OK
{
"uuid": "48a094e9-de92-471d-812a-8894b724731a",
"id": 1,
"notification_email": "admin@mystore.com",
"notification_email_with_idn": "admin@mystore.com",
"notification_language": "en",
"reply_email": "admin@mystore.com",
"reply_email_with_idn": "admin@mystore.com",
"cancel_url": "http://helloworld.voog.com",
"return_url": "http://helloworld.voog.com",
"currency": "EUR",
"currency_symbol": "€",
"tax_rate": "20.0",
"value_date_days": 14,
"created_at": "2016-11-21T12:24:36.000Z",
"updated_at": "2017-03-29T14:11:59.000Z",
"missing_required_settings?": false,
"missing_required_settings": [],
"enabled": true,
"default_language": "en",
"image_id": 1,
"decimal_places": 2,
"company_name": "MyStore (EN)",
"bank_details": "http://helloworld.voog.com",
"terms_url": "http://helloworld.voog.com/terms",
"products_url_slug": "products",
"invoice_branding": true,
"min_cart_total": "12.0",
"shopping_cart_version": 2,
"mountpoint_node_id": null,
"preferred_payment_types": [],
"is_publicly_unavailable": false,
"robots_header": null,
"address": {
"id": 1,
"name": "MyStore Admin",
"company_name": "MyStore",
"address1": "W 5th Ave, 1",
"address2": "",
"city": "Anchorage",
"zip_code": "99507",
"state": "Alaska",
"country_code": "US",
"phone": null,
"instructions": null,
"created_at": "2016-10-11T14:24:21.000Z",
"updated_at": "2017-03-27T08:20:59.000Z"
},
"order_sequence": {
"prefix": "#",
"suffix": null,
"padding": 4,
"last_number": 0
},
"translations": {
"company_name": {
"et": "MyStore (EN)",
"en": "MyStore (ET)"
},
"bank_details": {
"et": "",
"en": ""
},
"terms_url": {
"et": "http://helloworld.voog.com/tingimused",
"en": "http://helloworld.voog.com/terms"
},
"products_url_slug": {
"et": "tooted",
"en": "products"
}
}
}
Attributes
notification_email
- all store notification emails are sent to this email addressnotification_email_with_idn
- Unicode version ofnotification_email
; equal tonotification_email
if the latter is not punycoded. This is a read-only field.notification_language
- all store notification emails are sent out in this languagereply_email
- used for the "Reply-To" address in customer emailsreply_email_with_idn
- Unicode version ofreply_email
; equal toreply_email
if the latter is not punycoded. This is a read-only field.return_url
- When paying with outside gateways (Paypal/Bank links), this address is used as a return path for successful paymentscancel_url
- Similar toreturn_url
, but used for cancelled or rejected paymentscurrency
- three-digit currency code, e.g "EUR", "USD" etc.currency_symbol
- this is used to compact prices, so instead of "200 EUR", we'd use "€200"tax_rate
- VAT percentage, e.g. "20.0"value_date_days
- used to determine the invoice's payment due datedecimal_places
- determines how numbers are rounded when displaying amountsmissing_required_settings?
- if this is true, all buy buttons are disabled and no purchases can be made in your storemissing_required_settings
- list of fields that are invalidenabled
- if set to "false", the whole store is disabled and no purchases can be madedefault_language
- language code that is used for default translation stringsimage_id
- points to an image asset that is used as the logo on the store's invoices. See the Assets API.company_name
- Your company's name that is used on the invoice and email notificationsbank_details
- payment data for offline invoices (Bank name, account no., reference codes etc.)terms_url
- URL that points to the Terms of Service of your storeinvoice_branding
- If "true", Voog branding is displayed on invoices, otherwise the branding is removed. Defaults to "true".min_cart_total
- The minimum cart total (incl. tax and shipping) required for checkout.shopping_cart_version
- The shopping cart version, either1
(legacy) or2
(default).mountpoint_node_id
— ID of the Node to consider the root of the canonical category and product pages structure, the root node by default.preferred_payment_types
- an array of preferred payment types to determine the order of payment type options in Checkout. Supported payment types arecard
,direct
,credit
,split
,gift
,offline
.is_publicly_unavailable
- if "true", all buy buttons are publicly disabled and no purchases can be made in your storerobots_header
- HTTPX-Robots-Tag
header value for store canonical product pages (read more). When set then HTTP headerX-Robots-Tag
is added to all store canonical product pages. Example values:noindex
ornoindex, nofollow
. Default value isnull
.address
- Your store's address that is shown on the invoiceorder_sequence
- this can be used to customize the order numbers in the storeprefix
- This is prepended to the order numbersuffix
- This is appended to the order numberpadding
- Minimum number of digits to displaylast_number
- Which number is used to start counting from-
{ "prefix": "#", "suffix": "-04-2017", "padding": 4, "last_number": 10 }
this will output
#0011-04-2017
as the next order numbertranslations
- Read more about translations.
Update store settings
PUT /admin/api/ecommerce/v1/settings
This request updates the store settings with the given attributes
Example request:
PUT http://helloworld.voog.co/admin/api/ecommerce/v1/settings?include=translations
Example data:
{
"notification_email": "notifications@mystore.com",
"value_date_days": 7,
"translations": {
"company_name": {
"et": "MyStore English",
"en": "MyStore Eesti"
},
}
}
Example response:
Status: 200 OK
{
"uuid": "48a094e9-de92-471d-812a-8894b724731a",
"id": 1,
"notification_email": "notifications@mystore.com",
"notification_email_with_idn": "notifications@mystore.com",
"notification_language": "en",
"reply_email": "admin@mystore.com",
"reply_email_with_idn": "admin@mystore.com",
"cancel_url": "http://helloworld.voog.com",
"return_url": "http://helloworld.voog.com",
"currency": "EUR",
"currency_symbol": "€",
"tax_rate": "20.0",
"value_date_days": 7,
"created_at": "2016-11-21T12:24:36.000Z",
"updated_at": "2017-03-29T14:11:59.000Z",
"missing_required_settings?": false,
"missing_required_settings": [],
"enabled": true,
"default_language": "en",
"image_id": 1,
"decimal_places": 2,
"company_name": "MyStore English",
"bank_details": "http://helloworld.voog.com",
"terms_url": "http://helloworld.voog.com/terms",
"products_url_slug": "products",
"invoice_branding": true,
"min_cart_total": "12.0",
"shopping_cart_version": 2,
"mountpoint_node_id": null,
"preferred_payment_types": [],
"is_publicly_unavailable": false,
"robots_header": null,
"address": {
"id": 1,
"name": "MyStore Admin",
"company_name": "MyStore",
"address1": "W 5th Ave, 1",
"address2": "",
"city": "Anchorage",
"zip_code": "99507",
"state": "Alaska",
"country_code": "US",
"phone": null,
"instructions": null,
"created_at": "2016-10-11T14:24:21.000Z",
"updated_at": "2017-03-27T08:20:59.000Z"
},
"order_sequence": {
"prefix": "#",
"suffix": null,
"padding": 4,
"last_number": 0
},
"translations": {
"company_name": {
"et": "MyStore English",
"en": "MyStore Eesti"
},
"bank_details": {
"et": "",
"en": ""
},
"terms_url": {
"et": "http://helloworld.voog.com/tingimused",
"en": "http://helloworld.voog.com/terms"
},
"products_url_slug": {
"et": "tooted",
"en": "products"
}
}
}