@webriq/gatsby-source-ecwid
v2.0.2
Published
Gatsby source plugin for ecwid api
Downloads
6
Maintainers
Readme
@webriq/gatsby-source-ecwid
Gatsby source plugin for fetching api in ecwid
Install
yarn add @webriq/gatsby-source-ecwid
How to use
// In your gatsby-config.js
plugins: [
{
resolve: "@webriq/gatsby-source-ecwid",
options: {
storeId: "...",
token: "...",
endpoints: {
EcwidProducts: "/products?limit=100&enbled=true&baseUrl=/&cleanUrls=true",
EcwidCategories: "/categories?enabled=true&baseUrl=/&cleanUrls=true&hidden_categories=true",
}
},
}
],
How to query
You can query Document nodes created from your Ecwid API like the following:
{
allEcwidProducts {
nodes {
id
name
price
description
imageUrl
}
}
}
API Parameters
For more ecwid api parameters visit https://api-docs.ecwid.com/reference/rest-api