How to add a tax using api cart transform?

Hello! I’m new to shopify apps.
using the transform cart api, how to add a fee for each product in the cart? the value of the tax comes from the property of the product.
What would the run.ts and run.grapql files look like?