---
title: "Codeunit 30195 Shpfy Inventory API, extension points 29"
author: "JOP-AL"
url: https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/points/
object: https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/
app: "Shopify Connector"
major: 29
source: https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/
checked: 2026-11-20
changed: 2026-10-05
subject: "Microsoft Dynamics 365 Business Central"
license: "Metadata from Microsoft's symbol packages. AL source MIT, Copyright (c) Microsoft Corporation. Selection and wording © 2026 JOP-AL. https://jonas-paprotka.de/licenses/"
---

# Codeunit 30195 Shpfy Inventory API, extension points 29

JOP-AL, https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/points/

12 procedures and triggers with a step in src/Apps/W1/Shopify/App/src/Inventory/Codeunits/ShpfyInventoryAPI.Codeunit.al, in source order, read from the text, not from a run.

## GetStock

[Line 27](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L27), internal.

- [38](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L38) calls `SetShop`
- [51](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L51) calls `StockCalculationFactory`
- [72](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L72) calls [Codeunit 30196 Shpfy Inventory Events](https://jonas-paprotka.de/ref/codeunit/30196-shpfy-inventory-events/) `OnAfterCalculationStock`

## GetId

[Line 76](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L76), local.

- [82](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L82) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonValue`

## GetInventoryLevels

[Line 90](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L90), local.

- [95](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L95) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonObject`
- [96](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L96) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonObject`
- [97](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L97) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonObject`

## RemoveUnusedInventoryIds

[Line 113](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L113), internal.

- [121](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L121) writes [Table 30112 Shpfy Shop Inventory](https://jonas-paprotka.de/ref/table/30112-shpfy-shop-inventory/) Delete

## ExportStock

[Line 124](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L124), internal.

- [135](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L135) calls [Codeunit 30154 Shpfy GraphQL Queries](https://jonas-paprotka.de/ref/codeunit/30154-shpfy-graphql-queries/) `GetQueryWithCost`
- [137](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L137) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonArray`
- [140](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L140) calls `CalcStock`
- [145](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L145) calls `ExecuteInventoryGraphQL`
- [148](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L148) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonArray`
- [155](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L155) calls `ExecuteInventoryGraphQL`

## ExecuteInventoryGraphQL

[Line 159](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L159), local.

- [180](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L180) calls [Codeunit 30103 Shpfy Communication Mgt.](https://jonas-paprotka.de/ref/codeunit/30103-shpfy-communication-mgt/) `ExecuteGraphQL`
- [182](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L182) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonArray`
- [184](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L184) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetValueAsText`
- [195](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L195) calls `LogSkippedInventoryUpdate`

## LogSkippedInventoryUpdate

[Line 198](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L198), local.

- [205](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L205) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonArray`
- [207](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L207) calls [Codeunit 30313 Shpfy Skipped Record](https://jonas-paprotka.de/ref/codeunit/30313-shpfy-skipped-record/) `LogSkippedRecord`

## CalcStock

[Line 210](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L210), local.

- [224](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L224) writes [Table 30112 Shpfy Shop Inventory](https://jonas-paprotka.de/ref/table/30112-shpfy-shop-inventory/) Delete
- [231](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L231) validates [Table 30112 Shpfy Shop Inventory](https://jonas-paprotka.de/ref/table/30112-shpfy-shop-inventory/) `Stock`
- [231](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L231) calls `GetStock`
- [232](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L232) writes [Table 30112 Shpfy Shop Inventory](https://jonas-paprotka.de/ref/table/30112-shpfy-shop-inventory/) Modify

## HasNextResults

[Line 250](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L250), local.

- [255](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L255) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonObject`
- [256](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L256) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonValue`

## ImportInventoryLevels

[Line 260](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L260), internal.

- [279](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L279) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonArray`
- [281](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L281) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonValue`
- [285](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L285) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonObject`
- [286](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L286) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonArray`
- [288](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L288) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonValue`
- [295](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L295) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonObject`
- [296](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L296) calls `GetId`
- [297](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L297) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonObject`
- [298](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L298) calls `GetId`
- [301](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L301) calls [Codeunit 30157 Shpfy Json Helper](https://jonas-paprotka.de/ref/codeunit/30157-shpfy-json-helper/) `GetJsonObject`
- [302](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L302) calls `GetId`
- [304](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L304) validates [Table 30112 Shpfy Shop Inventory](https://jonas-paprotka.de/ref/table/30112-shpfy-shop-inventory/) `Shopify Stock`
- [306](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L306) writes [Table 30112 Shpfy Shop Inventory](https://jonas-paprotka.de/ref/table/30112-shpfy-shop-inventory/) Modify
- [315](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L315) validates [Table 30112 Shpfy Shop Inventory](https://jonas-paprotka.de/ref/table/30112-shpfy-shop-inventory/) `Shopify Stock`
- [316](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L316) writes [Table 30112 Shpfy Shop Inventory](https://jonas-paprotka.de/ref/table/30112-shpfy-shop-inventory/) Insert

## ImportStock

[Line 331](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L331), internal.

- [341](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L341) calls [Codeunit 30103 Shpfy Communication Mgt.](https://jonas-paprotka.de/ref/codeunit/30103-shpfy-communication-mgt/) `ExecuteGraphQL`
- [342](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L342) calls `GetInventoryLevels`
- [343](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L343) calls `ImportInventoryLevels`
- [344](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L344) calls `HasNextResults`

## SetShop

[Line 347](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L347), internal.

- [351](https://jonas-paprotka.de/ref/codeunit/30195-shpfy-inventory-api/source/#L351) calls [Codeunit 30103 Shpfy Communication Mgt.](https://jonas-paprotka.de/ref/codeunit/30103-shpfy-communication-mgt/) `SetShop`

## Source

AL source 29: https://github.com/microsoft/BCApps, MIT, releases/29.x at 4303e5e584d3aa5d9e98cbc615525a5396ad6ed7.

JOP-AL, 2026-11-20.
