Mapping product from catalog with payment


I try to integrate payment with the product I created in the catalogue. 

I try to use and follow the step describe in the document:


Only part is missing for me is how I can connect product is user paying for with params I'm sending through payment params in javascript.


Anyone can help with this as I want to use unique product which was set in catalog and have stat when user is paying