4
0
forked from crowetic/commerce
Catalin Pinte c75b0fc001
Dynamic API routes (#836)
* Add dynamic API endpoints

* Add missing dependency

* Update api handlers

* Updates

* Fix build errors

* Update package.json

* Add checkout endpoint parser & update errors

* Update tsconfig.json

* Update cart.ts

* Update parser

* Update errors.ts

* Update errors.ts

* Move to Edge runtime

* Revert to local

* Fix switchable runtimes

* Make nodejs default runtime

* Update pnpm-lock.yaml

* Update handlers

* Fix build errors

* Change headers
2022-10-30 13:41:21 -05:00
..
2022-10-30 13:41:21 -05:00
2022-02-01 14:14:05 -05:00
2022-02-01 14:14:05 -05:00
2022-02-01 14:14:05 -05:00
2022-10-30 13:41:21 -05:00
2022-02-01 14:14:05 -05:00
2022-02-01 14:14:05 -05:00
2022-02-01 14:14:05 -05:00
2022-02-01 14:14:05 -05:00

Saleor Provider

Demo: https://saleor.vercel.store/

You need a Saleor instance, either in the cloud or self-hosted.

This provider requires Saleor 3.x or higher.

Copy the .env.template file in this directory to .env.local in the main directory (which will be ignored by Git):

cp packages/saleor/.env.template .env.local

Then, set the environment following variables in your .env.local. Both, NEXT_PUBLIC_SALEOR_API_URL and COMMERCE_IMAGE_HOST must point to your own Saleor instance.

COMMERCE_PROVIDER=saleor
NEXT_PUBLIC_SALEOR_API_URL=https://vercel.saleor.cloud/graphql/
NEXT_PUBLIC_SALEOR_CHANNEL=default-channel
COMMERCE_IMAGE_HOST=vercel.saleor.cloud