For the complete documentation index, see llms.txt. This page is also available as Markdown.

Overview

Relay reads data from a merchant's ecom platform at the moment you ask for it. Nothing comes from Violet's catalog or order tables, so every response is the platform's current state, and it takes as long as the platform's own API does.

New to Relay? Start with What is Relay? in the guides.

Endpoints

Group
What it reads

Products as Violet offers: list, get by platform ID, search

One order in Violet's order model, by platform ID

The merchant's store profile

Shipping zones and their methods

Before you call

Send X-Violet-Token, X-Violet-App-Secret and X-Violet-App-Id on every request. The token must belong to the developer that owns the app, and the app must be connected to the merchant. Every endpoint except Get Shipping Zones also needs the app on the Relay plan. To get an app Relay-enabled, contact support@violet.io.

Platform support

Each endpoint page lists the platforms it supports. What happens on any other platform depends on the endpoint, and the page says which.

Pagination

List endpoints paginate by cursor or by page number, depending on the platform.

  • Cursor platforms (Shopify, for example) return next_page_cursor. Send it back as the next_page_cursor query parameter to get the next page, and stop when last is true. The cursor carries the filters of your first request, so filters sent along with it are ignored.

  • Page-number platforms (WooCommerce and BigCommerce, for example) use page and size, and you send the filters again on every request. Keep requesting pages until one comes back empty. Don't rely on last or the totals here. last is not set reliably, and some platforms report totals for the current page only.

Filters

A filter applies only on the platforms named in its description. Other platforms ignore it without returning an error, so results can come back unfiltered.

Errors

Errors use Violet's standard body with error, code and message. When a merchant's platform rejects the connection Violet has stored, some platforms and endpoints answer 400 invalid_merchant_credentials, and the rest return a 500. Handle both.

Guides

Last updated

Was this helpful?