mirror of
https://github.com/vercel/commerce.git
synced 2025-03-27 15:55:54 +00:00
* Add ordercloud provider * Fix provider errors * Make submit checkout optional * Make submit checkout optional * Remove nullables when creating endpoint type * Update readme * Log checkout error * Log error * Save token to cookie * Update fetch rest * Use token at checkout Co-authored-by: Luis Alvarez <luis@vercel.com>
15 lines
409 B
TypeScript
15 lines
409 B
TypeScript
import type { GraphQLFetcher } from '@commerce/api'
|
|
import type { OrdercloudConfig } from '../'
|
|
|
|
import { FetcherError } from '@commerce/utils/errors'
|
|
|
|
const fetchGraphqlApi: (getConfig: () => OrdercloudConfig) => GraphQLFetcher =
|
|
() => async () => {
|
|
throw new FetcherError({
|
|
errors: [{ message: 'GraphQL fetch is not implemented' }],
|
|
status: 500,
|
|
})
|
|
}
|
|
|
|
export default fetchGraphqlApi
|