mirror of
https://github.com/vercel/commerce.git
synced 2025-06-20 06:01:21 +00:00
* Add codegen, update fragments & schemas * Update checkout-create.ts * Update checkout-create.ts * Update README.md * Update product mutations & queries * Uptate customer fetch types * Update schemas * Start updates * Moved Page, AllPages & Site Info * Moved product, all products (paths) * Add translations, update operations & fixes * Update api endpoints, types & fixes * Add api checkout endpoint * Updates * Fixes * Update commerce.config.json Co-authored-by: B <curciobelen@gmail.com>
23 lines
516 B
TypeScript
23 lines
516 B
TypeScript
import { checkoutDetailsFragment } from '../queries/get-checkout-query'
|
|
|
|
const checkoutLineItemAddMutation = /* GraphQL */ `
|
|
mutation checkoutLineItemAdd(
|
|
$checkoutId: ID!
|
|
$lineItems: [CheckoutLineItemInput!]!
|
|
) {
|
|
checkoutLineItemsAdd(checkoutId: $checkoutId, lineItems: $lineItems) {
|
|
checkoutUserErrors {
|
|
code
|
|
field
|
|
message
|
|
}
|
|
checkout {
|
|
...checkoutDetails
|
|
}
|
|
}
|
|
}
|
|
|
|
${checkoutDetailsFragment}
|
|
`
|
|
export default checkoutLineItemAddMutation
|