Product documentation
In This Topic
    Dynamics Slim4 Integration-Webservice procedure
    In This Topic

     Important

    The webservice procedure is fast but remember that several steps are near real-time: it can take 1-5 minutes before a process starts. In case the data does not show up correctly in Slim4, always test with Postman whether the expected data is retrieved in the JSON message. If the data is correct in the JSON message, please contact the SlimStock consultant.   
       

    Procedure high level

    1. Update export data

    Batch job that reads data (items, orders, stock) from Microsoft Dynamics 365 for Finance and Operations tables, aggregates, pre-processes and writes to outbound staging tables (article code master, article filter, logistics, confirmed demand, purchase orders etc.).

     

    2. Start export process

    Auto-created DMF export project sends the data to BYOD.

    Can be activated automatically with a check mark in the before mentioned Update export data dialog.

     

    3. Webservice (GET)

    Slim4 Integration calls the webservices to retrieve the data from BYOD and writes to Slim4 Integration internal staging database.

     

    4. External calculation of planned orders

    Slim4 Integration calculates the optimal set if planned orders.

     

    5. Webservice (POST)

    Slim4 Integration posts the optimal set of planned orders. These orders are written to the Planned order import staging table in Microsoft Dynamics 365 for Finance and Operations.

     

    6. Create planned orders

    The Planned order import staging orders can be processed to Planned orders, visible in Master planning, immediately in the previous process, or in batch.

     

    7. Firm planned orders

    Planned orders can be firmed manually or in batch.

     

    Data pre-processing

    Data from Microsoft Dynamics 365 for Finance and Operations to Slim4 Integration

    Slim4 Integration > Periodic task > Update export data

     Important

    In the dialog, set batch processing = yes. The status can be viewed in System administration > Inquiries > Batch jobs. For the best performance the processing is split into parts. Therefor the progress percentage on the batch job might start again several times, but the processing continues.
       
    Field Description Remark
    Update purchase order export Fill staging table Purchase order export

    Update confirmed demand data

    Fill staging table Confirmed demand export

    Update BOM data

    Fill staging table BOM data

    Update variant generic data

    Fill staging table Variant generic data

    Update transaction data

    Fill staging table Transaction data

    Update suppliers export data

    Update the vendor specific order settings

    Price, name, vendor item ID

    Update historical purchase data

    Fill staging data Historical purchase orders

    Update stock details

    Fill staging data with stock details

    Start export process

    Run the data management export project

     

    Microsoft Dynamics 365 for Finance and Operations preprocesses static and dynamic data.

     

    Export

    Optional: Data management > Export project

    Advice is to start the export process automatically in the previous step.

    Microsoft Dynamics 365 for Finance and Operations exports static and dynamic data (open confirmed demand, open supply, historical transactions, stock) to BYOD.

    The data is retrieved by a webservice that is called from Slim4 and imported into the import database.

     

    Data processing in Slim4 Integration

    Slim4 Integration DB retrieves the data from the import DB and with or without user interaction processes the data in the Slim4 DB.

    The mapping of many data fields can be configured in the connector, and on top of that the Slim4 Integration consultant can configure the mapping e.g. from UDF fields that need to be mapped to standard interface fields.

     

    Import

    Data from Slim4 Integration to Microsoft Dynamics 365 for Finance and Operations

    Slim4 Integration calls the webservice to send planned orders to Microsoft Dynamics 365 for Finance and Operations.

     

    Data processing in Microsoft Dynamics 365 for Finance and Operations

    Optional: Slim4 Integration > Import data > Planned order import table

    The planned orders are staged in Planned order import table, and processed immedately or in batch. NB: it can take a few minutes until the data is visible.

    A planned order import record can be in status:

     

    Optional: Slim4 Integration > Periodic tasks > Create planned orders

    Process the Planned order import table to create planned orders, immediately or in batch.

    Include in error if the records must be reprocessed after the problem was solved by setting up an item etc. 

     

    Firm planned orders in batch

    The planned orders in the master planning can be firmed automatically:

    In the planned orders screen, select the plan in which the orders are imported

    Press Firm all, check the selection, and switch on Batch processing and setup a recurrence.

     

    Admin form

    The staging tables are updated when the update export data runs.

    In exceptional cases an admin user can delete the content from the staging tables, through the menu item DYSSlim4ServicesAdmin. This menu item is not part of the regular menu. The admin user can select which staging tables to purge.

     Important

    Do not clear the following data (unless you are absolutely certain), because it can not be rebuilt: Article code master additional fields, Article code master additional UDF fields, Suppliers. If you try to delete these data elements, an extra warning message pops up.
       

    Until Microsoft will release functionality to support order settings per vendor, the Vendor specific order settings Slim4 Integration (Suppliers data) reside in the staging table only, so do not purge it! Depending on the implementation of that new functionality, the staging table will be connected to the new standard fields.  

     

    Copy data between environments

    When data is copied e.g. from PROD to UAT (or TEST or DEV), make sure to change the connection string in the created copy and regenerate the data.

    Add these steps to the script copy data between environments:

    1. If there is old data in the UAT's BYOD, purge that data first.
    2. Work space Data management > Configure entity export to database. Click on Source name. Fast tab Configure. Change the Connection string to the UAT's BYOD.
    3. Work space Data management > Export project > Selected entities, Refresh type
      1. Set the refresh type to Full push only on all entities in the DMF project
    4. Slim4 integration parameters
      1. temporarily set the days history to a larger value 
    5. Update export data and run project
    6. Work space Data management > Export project > Selected entities, Refresh type 
      1. Stock warehouse/batch export: Full push only
      2. Warehouse export: Full push only
      3. Other entities: set back to Incremental push only
    7. Slim4 integration parameters
      1. set the days history back to the original value
    8. Add a connection on Postman for the UAT.
    9. Also on the Slim4 side, make sure that the Slim4 UAT environment is connected to the UAT environment

     

    FAQ

    Question: The data does not show up in Slim4 Integration
    Answer:

    Check whether the data is present in the staging tables in Microsoft Dynamics 365 for Finance and Operations in the Slim4 Integration Integration.

    • First check the Article filter.
    • If not check that the coverage group or warehouse group of the item has a Slim4 Integration stocked or noon-stocked setup.
    • If the item - warehouse combination is present in the Article filter but not in Confirmed demand, verify that the customer is not excluded from Slim4 Integration.

    Check whether the webservice in the Postman collection returns the data in the JSON message.

    • If not, check that the Export project has run in the Update export data
    • Wait 1-5 minutes

    If the JSON shows the correct data, please contact the Slim4 Integration consultant.

    Question: Are the stock details retrieved near real time?
    Answer:

    Stock details are aggregated per warehouse, product variant and batch number, and filled in a staging table, in the same mechanism and frequency as the other data.

    Before March 2023, the stock details were retrieved near real time from InventSum without a staging table, but to avoid timing issues, a staging table is added. 

    Question: I want to populate user defined fields (UDF) and analysis code fields in the article code master. Can I export any of the 120 UDFs that exist in Slim4 Integration?
    Answer:

    In Slim4 Integration > Setup > Article code master additional data press the office symbol and select Open in Excel. Fill / copy the data to in the Excel and publish the data.

    Note that UDF 1 to 15 and analysis codes 1 to 6 can be maintained in and exported from Microsoft Dynamics 365 for Finance and Operations. Slim4 Integration has more UDF fields but those are used for interal calculations only.

    The UDF 1 to 15 fields and the criteria 1 to 8 fields and analysis codes 1 to 6 can also be updated through automatic mapping from existing standard fields or customized fields.   

    Question: Some other Slim4 Integration fields are not mapped to Microsoft Dynamics 365 for Finance and Operations fields. These fields are flagged as Empty. Can these fields be filled in a project specific way?
    Answer: Yes, the project developer can add a customized process as an extension, and overwrite any of the fields in the export staging tables. This process should run after Update export data. Please feel free to contact HSO Innovation.
    Question: Specific item is not exported.
    Answer: Check that the release product has a coverage group that is planned by Slim4 and run Update export data and start the export process.
    Question: Planned order import shows no results. 
    Answer: The service is near-real time, so it can take 1 to 3 minutes until the planned orders submitted by the webservice are processed. First these planned orders are inserted in the Planned order import table, then they can be processed into planned orders automatically or in batch.
    Question: Planned orders for a specific warehouse are not imported.  
    Answer: Check that the warehouse exists. NB: the warehouse itself does not have to be Slim4-active. E.g. for a production warehouse for which any existing inventory should not be exported, Slim4 could still generate planned production orders. 
    Question: Planned orders for a specific vendor are not imported.
    Answer: Check that the vendor ID exists.
    Question: Create planned orders fails.
    Answer:

    Creating a planned order from the planned order import table can be simulated through manual entry in the planned orders. If manual entry is not possible either, the create planned orders functionality will fail too.

    There can be a few minutes delay until the planned orders are visible in Microsoft Dynamics 365 for Finance and Operations.

    Question: The number of planned orders in Microsoft Dynamics 365 for Finance and Operations is greater than the number of planned orders submitted by the webservice.
    Answer: The creation of a planned order in Microsoft Dynamics 365 for Finance and Operations can automatically trigger other planned orders, e.g. if a planned production order is submitted: planned purchase orders for the components, or if a planned transfer order is submitted: planned purchase order in the source warehouse.