Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Supply chain | Supply Chain Management, Commerce
Unanswered

use inventory visibility API to fetch stock for a WMSLocation

(3) ShareShare
ReportReport
Posted on by 96
I am developing an integration where i need to fetch stock levels for products from particular locations and then transfer this to a 3rd party system.
As i have checked it is not possible to use or /in operator with the api while using getonhand.
as per requirement, i need stock quantities for all WMS locations except one particular location.
In Inventory visibility , i can acheive this with putting filters like below.
I want to know, how can i acheive the same with Inventory visibility API.
 
i use a logicapp workflow to get data from IV and then send it further to third party.
  • Subhad365 Profile Picture
    19 User Group Leader on at
    use inventory visibility API to fetch stock for a WMSLocation
    My Apologies for this delayed response -- just I happened to bump across your post :=)
    Just in case you are still looking for an answer, you can also get this done by calling the version 2.0 of the inventory endpoint:
    {{IVUrl}}/api/environment/{{environment}}/onhand/indexquery
    And then you can keep passing your WMSLocations as array in the JSON body:
    {
      "filters": {
        "OrganizationId": [
          "USMF"
        ],
        "ProductId": [
          "1000", "10002"
        ],
        "SiteId": [
          "1"
        ],
        "LocationId": [
          "13", "15", "18"
        ]
      },
      "groupByValues": [],
      "returnNegative": true
    }
    Whereby you can get the result as an array response, for all WMSLocations, except the one(s) you are not interested. 
    Don't forget to set the Version as 2.0 in the header :-)
    api-version: 2.0
  • Kevin Xia Profile Picture
    Microsoft Employee on at
    use inventory visibility API to fetch stock for a WMSLocation
    Hi,
    You need to use the API to get the inventory quantity of the product from all WMS locations. Once you retrieve the inventory count, you can code out the data for specific locations to exclude in the integration code. Finally, the filtered inventory quantity data is transferred to your third-party system.
    Best regards,
    Kevin

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Jonas ”Jones” Melgaard – Community Spotlight

We are honored to recognize Jonas "Jones" Melgaard as our April 2025…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 294,069 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 232,858 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,158 Moderator

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans