Description and Steps
I made an API call to create a product whose variant id you can see in the screenshot below

I then pass that product object into my function below. I'm converting the admin_graphql_api_id for the variant to base64 to create a valid variantId to pass into the addLineItems function
export async function ShopifyCheckout(box) {
console.log(box);
const boxVariantId = btoa(box.data.variants[0].admin_graphql_api_id);
// const { boxDescription } = box.data;
const checkoutId = await client.checkout.create().then(checkout => checkout.id);
const checkoutLineItems = [{ variantId: boxVariantId, quantity: 1 }];
console.log(`Before Adding: ${checkoutId}`);
client.checkout.addLineItems(checkoutId, checkoutLineItems).then((checkout) => {
console.log(`After Adding: ${checkout.id}`);
console.log(checkout);
console.log(checkout.lineItems);
console.log('why wont u adddddd');
}).catch((err) => {
console.log(err);
});
}
After calling the function. I see that I made a successful call to add the line items. The checkout I created is the same checkout that I attempted to add line items to. However I see an empty array of line items, meaning nothing was added.

Expected behavior
I expected line items to be added to my checkout
Environment (please complete the following information):
v1.6.0Bug Report Checklist
do you have any data from the network, as to what the data returned looks like?
Have you verified that you can fetch the product using the SDK? This would check to ensure that the product is published to the storefront channel you've created.
Now I feel a bit embarrassed. You were right about the storefront channel. I had thought that a product created using the API would be available on all sales channels by default. I made it available before testing the addLineItems function and it worked perfectly. Thank you!
Great! Glad it worked 馃槃
Most helpful comment
do you have any data from the network, as to what the data returned looks like?
Have you verified that you can fetch the product using the SDK? This would check to ensure that the product is published to the storefront channel you've created.