Okay
  Public Ticket #2641897
REST API integration with an ERP
Closed

Comments

  •  1
    Curro Pérez started the conversation

    Hello,
    I am interested in your B2B plugin for its complete features.
    We want to integrate it with an ERP and work integrating the online store with our ERP, but I don't see any documentation on the use of REST API.
    The main problem is the different discount levels according to the different types of customers, could they be related via api?
    Where can I see information about REST API integration?
  •  2,214
    WebWizards replied

    Hello Curro,

    Thank you for getting in touch. 


    We have many customers using various ERPs and integration solutions such as Infor, Acumatica, DEAR, Integromat, etc. Our plugin uses metadata and wp posts of custom post types for almost everything, so REST API can be used to control the plugin.


    That being said, I'm afraid at the moment we don't have documentation for REST API integration. 


    To set different prices for different groups for a product, this can be controlled through product metadata, which we describe here in detail: https://woocommerce-b2b-plugin.com/docs/release-1-8-0-price-lists-csv-import-export-pricing-in-the-product-page/


    To set discounts for groups (e.g. 10% for 1 group, 20% for another group), this would have to be done through the plugin's dynamic rules. A rule is a post of custom post type b2bking_rule, with a few metadata such as "b2bking_howmuch" and "b2bking_applies" that describe the details of the discounts. There are hundreds of meta key options and combinations however so I can't go through all here. The best way to see the meta keys of a rule would be to create it in the backend, and then check the wp_postmeta table for the meta.

    If I can help with anything, let me know.


    All the best for the Holidays. 

    Kind Regards,
    Stefan


  •  1
    Curro Pérez replied

    Hi Stefan,

    Thanks for your quick response.
    I will contact the company that manages the ERP to study how to integrate it.

    It is an important decision that must be studied thoroughly

    Best regards

  •  2,214
    WebWizards replied

    If we can help with anything, let us know.

    Happy Holidays!

  •  5
    Andreas replied

    Hi Curro,

    We are also in the process of integating b2bking with the ERP of our client, and we are facing an issue with the custom post type b2bking_rule not being available from the REST API.

    Did you manage to make it work?


    Appreciate any help you can provide


    Thanks