Today we have launched support for consignment of offline/in-store orders!
We have been mindful to add this without introducing any breaking changes to our APIs, and the only breaking change to our React Widget being the removal of 3 deprecated properties:
  • renderAccepted
  • renderConsigned
  • renderWithdrawn
We have added a
type
parameter to the AuthentifiedButton component which enables developers to distinguish between an offline and an online order. This results in 3 ways to consign an item:
Shopify by lineItemId
This method is best for brands using the Admin GraphQL API to retrieve a customer's orders. This is our preferred method.
import { AuthentifiedButton } from "@authentified/react-widget"
const ConsignmentButton = ({ lineItemId, productId, orderId, shopId }) => {
return (
<AuthentifiedButton
lineItemId={lineItemId}
productId={productId}
orderId={orderId}
shopId={shopId}
type="shopify"
/>
)
}
Shopify by variantId
This is best for brands using the Shopify storefront API to display a customer's orders. The storefront API does not have a
lineItemId
available, so we need to use the
variantId
.
import { AuthentifiedButton } from "@authentified/react-widget"
const ConsignmentButton = ({ variantId, productId, orderId, shopId }) => {
return (
<AuthentifiedButton
variantId={variantId}
productId={productId}
orderId={orderId}
shopId={shopId}
type="shopify"
/>
)
}
Offline by variantId
This is best for brands who display a customer's offline orders alongside online orders, for example via DotApparel integration. NOTE: You must have data mapped to Shopify products and variants for this to work.
import { AuthentifiedButton } from "@authentified/react-widget"
const OfflineConsignmentButton = ({ variantId, productId, orderId, shopId }) => {
return (
<AuthentifiedButton
variantId={variantId}
productId={productId}
orderId={orderId}
shopId={shopId}
type="offline"
/>
)
}
For more information, read the Authentified docs or visit the @authentified/react-widget NPM package