Skip to content

parseCustomerPricingMetaobject

parseCustomerPricingMetaobject(node): CustomerPricingEntry | null

Defined in: .pnpm/@[email protected]_graphql@[email protected]_typescript@6.0.3/node_modules/@storesynk/core/dist/product/customer-pricing.d.ts:83

Parse one $app:customer_pricing metaobject node. Tolerant by design (a metaobject can be stale or hand-authored under a merchant’s own type): a missing/blank title, a tags json with an unknown v or no usable tags, a pricing json with an unknown v/type/source or an out-of-range value, or an unknown applies_to.type all skip the WHOLE rule rather than half-rendering it (never wrong math, never guessed targeting); unknown extra json keys pass through. Returns null when the node doesn’t parse.

"Metaobject"

{ value: string | null; } | null

{ references: { nodes: ({ __typename: "Product"; } | { __typename: "ProductVariant"; } | { __typename: "MediaImage"; } | { __typename: "Video"; } | { __typename: "Model3d"; } | { __typename: "Collection"; id: string; } | { __typename: "Metaobject"; } | { __typename: "GenericFile"; } | { __typename: "Article"; } | { __typename: "Page"; })[]; } | null; } | null

{ value: string | null; } | null

string

string

{ value: string | null; } | null

{ references: { nodes: ({ __typename: "Product"; id: string; } | { __typename: "ProductVariant"; } | { __typename: "MediaImage"; } | { __typename: "Video"; } | { __typename: "Model3d"; } | { __typename: "Collection"; } | { __typename: "Metaobject"; } | { __typename: "GenericFile"; } | { __typename: "Article"; } | { __typename: "Page"; })[]; } | null; } | null

{ value: string | null; } | null

{ value: string | null; } | null

{ value: string | null; } | null

{ value: string | null; } | null

CustomerPricingEntry | null