1
0
mirror of https://github.com/vercel/commerce.git synced 2025-07-27 12:11:23 +00:00
Files
.vscode
assets
components
config
framework
bigcommerce
api
definitions
endpoints
cart
catalog
checkout
get-checkout.ts
index.ts
customer
login
logout
signup
wishlist
fragments
operations
utils
index.ts
auth
cart
checkout
customer
lib
product
scripts
types
wishlist
.env.template
README.md
commerce.config.json
fetcher.ts
index.tsx
next.config.js
provider.ts
schema.d.ts
schema.graphql
commerce
commercejs
kibocommerce
local
ordercloud
saleor
shopify
spree
swell
vendure
lib
pages
public
.editorconfig
.env.template
.eslintrc
.gitignore
.prettierignore
.prettierrc
README.md
codegen.bigcommerce.json
codegen.json
commerce.config.json
global.d.ts
license.md
next-env.d.ts
next.config.js
package-lock.json
package.json
postcss.config.js
swell-js.d.ts
tailwind.config.js
tsconfig.json
commerce/framework/bigcommerce/api/endpoints/checkout/index.ts
Gonzalo Pozzo 8e7b942240 Fix redirect checkout ()
* Fix redirect checkout

* Don't use checkout for saleor
2021-09-24 11:42:09 -05:00

19 lines
594 B
TypeScript

import { GetAPISchema, createEndpoint } from '@commerce/api'
import checkoutEndpoint from '@commerce/api/endpoints/checkout'
import type { CheckoutSchema } from '../../../types/checkout'
import type { BigcommerceAPI } from '../..'
import getCheckout from './get-checkout'
export type CheckoutAPI = GetAPISchema<BigcommerceAPI, CheckoutSchema>
export type CheckoutEndpoint = CheckoutAPI['endpoint']
export const handlers: CheckoutEndpoint['handlers'] = { getCheckout }
const checkoutApi = createEndpoint<CheckoutAPI>({
handler: checkoutEndpoint,
handlers,
})
export default checkoutApi