---
id: object/codeunit/30189
type: object
title: Codeunit 30189 "Shpfy Variant API"
summary: Codeunit 30189 "Shpfy Variant API" in Shopify (Microsoft.Integration.Shopify). 18 public procedures. Introduced in BC29, still in BC30.
tier: official
language: en
tags:
  - codeunit
  - shopify
versions:
  introduced: "29"
  last_changed: null
  deprecated: null
review:
  state: derived
  by: null
  at: null
  flags: []
generated:
  at: "2026-10-11T00:31:51.816Z"
  pipeline: 0.2.0
  prompts: {}
  input_hash: b70b93d471cafcae7f1eef0d0a554a9b17ced1f1f8e0c7262d7c780826410ee8
evidence:
  - kind: code
    url: https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/Apps/W1/Shopify/app/src/Products/Codeunits/ShpfyVariantAPI.Codeunit.al
    title: src/Apps/W1/Shopify/app/src/Products/Codeunits/ShpfyVariantAPI.Codeunit.al (releases/29.x)
    date: null
    commit: ea08af5ef2d6a9b5c5af4a029288abbe2c883220
    t: null
    quote: null
links:
  learn: []
  objects: []
  features: []
  topics: []
  localizations: []
  videos: []
  posts: []
  guidelines: []
  changes:
    - change/bcapps/9320
    - change/bcapps/9313
    - change/bcapps/9126
object_type: codeunit
object_id: 30189
name: Shpfy Variant API
namespace: Microsoft.Integration.Shopify
app: Shopify
extends: null
first_version: "29"
last_version: "30"
present_in:
  - "29"
  - "30"
changed_in: []
source_major: "29"
obsolete: null
countries: []
ms_search_form_ids: []
counts:
  fields: 0
  procedures: 29
  events: 0
  subscribers: 0
relations:
  out: 0
  referenced_by: 0
  pages: 0
  extended_by: 0
  event_subscribers: 0
  calls: 0
  called_by: 0
  implements: 0
---

# Codeunit 30189 "Shpfy Variant API"

> Codeunit 30189 "Shpfy Variant API" in Shopify (Microsoft.Integration.Shopify). 18 public procedures. Introduced in BC29, still in BC30.

Shopify · Microsoft.Integration.Shopify · BC29-30 · [source at ea08af5e](https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/Apps/W1/Shopify/app/src/Products/Codeunits/ShpfyVariantAPI.Codeunit.al) · facts from BC29

## Properties

| Property | Value |
|---|---|
| Access | Internal |

## Procedures

- `FindShopifyProductVariant(var ShopifyProduct: Record "Shpfy Product"; var ShopifyVariant: Record "Shpfy Variant"): Boolean` (internal): Find Shopify Product Variant.
- `AddProductVariant(var ShopifyVariant: Record "Shpfy Variant" temporary; ProductId: BigInteger; Strategy: Enum "Shpfy Variant Create Strategy"): Boolean` (internal)
- `AddProductVariants(var ShopifyVariant: Record "Shpfy Variant" temporary; ProductId: BigInteger; Strategy: Enum "Shpfy Variant Create Strategy")` (internal)
- `FindShopifyVariantByBarcode(var ShopifyVariant: Record "Shpfy Variant"): Boolean` (internal): Find Shopify Variant By Barcode.
- `FindShopifyVariantBySKU(var ShopifyVariant: Record "Shpfy Variant"): Boolean` (internal): Find Shopify Variant By SKU.
- `RetrieveShopifyProductVariantImages(var ProductVariantImages: Dictionary of [BigInteger, Dictionary of [BigInteger, Text]])` (internal): Description for RetrieveShopifyProductVaraintImages.
- `RetrieveShopifyProductVariantIds(ShopifyProduct: Record "Shpfy Product"; var ProductVariantIds: Dictionary of [BigInteger, DateTime])` (internal): Retrieve Shopify Product Variant Ids.
- `RetrieveShopifyVariant(ShopifyProduct: Record "Shpfy Product"; var ShopifyVariant: Record "Shpfy Variant"; var ShopifyInventoryItem: Record "Shpfy Inventory Item"): Boolean` (internal): Retrieve Shopify Variant.
- `SetShop(ShopifyShop: Record "Shpfy Shop")` (internal): Set Shop.
- `UpdateProductVariants(var ShopifyVariant: Record "Shpfy Variant")` (internal)
- `UpdateProductPrice(ShopifyVariant: Record "Shpfy Variant"; xShopifyVariant: Record "Shpfy Variant"; var BulkOperationInput: TextBuilder; var GraphQueryList: Dictionary of [BigInteger, TextBuilder]; var JRequestData: JsonArray)` (internal)
- `UpdateProductPrice(VariantId: BigInteger; GraphQuery: TextBuilder): Boolean` (internal)
- `UpdateShopifyVariantFields(ShopifyProduct: Record "Shpfy Product"; var ShopifyVariant: Record "Shpfy Variant"; var ShopifyInventoryItem: Record "Shpfy Inventory Item"; JVariant: JsonObject)` (internal): Update Shopify Variant Fields.
- `CheckShopifyVariantImageExists(VariantId: BigInteger): Boolean` (internal)
- `SetVariantImage(ShopifyVariant: Record "Shpfy Variant"; ResourceUrl: Text): BigInteger` (internal)
- `SetVariantImage(ProductId: BigInteger; VariantId: BigInteger; ImageId: BigInteger): Boolean` (internal)
- `CreateShopifyVariantImage(Variant: Record "Shpfy Variant"; PictureGuid: Guid): BigInteger` (internal)
- `UpdateShopifyVariantImage(Variant: Record "Shpfy Variant"; PictureGuid: Guid): BigInteger` (internal)

Plus 11 local procedures.

## Recent changes

- 2026-07-16 [#9320 [Shopify] Import HS code and country of origin from Shopify](../../changes/bcapps/9320.md) (main, BC30, feature)
- 2026-07-13 [#9313 [Shopify] Fix Product Sync deleting mapped variants on stale Updated At timestamp](../../changes/bcapps/9313.md) (main, BC30, fix)
- 2026-07-09 [#9126 [Shopify] Base price-sync bulk threshold on changed price count](../../changes/bcapps/9126.md) (main, BC30, fix)

## Across versions

- Present in: BC29-30
- Changed (declaration) in: none

Source: AL metadata extracted from the code (names, ids, signatures, properties); no code bodies (D10).

## Ask your agent

Procedure bodies are not stored here (D10). For a procedure body or the calls of one procedure, ask bc-code-atlas (external, by Stefan Maron, MIT; default corpus w1-28), which the bc-observatory plugin connects: `bcatlas_resolve_node(object_type: "codeunit", object_name: "Shpfy Variant API")`, then `bcatlas_get_procedure_body` or `bcatlas_get_neighbors` on the returned id.
