If you want to, you can replace the implementation of how we take products/discounts from Dynamics and pass them to Oneflow with your own.
This is an advanced tutorial for experienced Dynamics CRM Developers.
So, in order for us to replace the implementation we’ll need to register a plugin step for a ‘of_GetProductsPayload' message :
It should be synchronous and should execute on PostOperation.
When the Execute method of your plug-in is called, you’ll get the following input and output parameters:
JSON string, contains the agreementId in oneflow and opportunityId of the opportunity in Dynamics to take the products from.
indicates whether an error occurred during the oob’s operation
Error details if an exception occurred
resulting JSON string of products to add to the oneflow contract.
the payload field contains a JSON that’s passed to Oneflow API directly.
You can read more about the object structure in Oneflow API docs at https://developer.oneflow.com/docs/product-group
Now, if you want to have your own implementation of products, you’ll just need to replace the original result json with your own, like so: