How to handle dynamic pricing in consumable in app purchase programatically in swift?

In an application feature where users can purchase resources to enhance the exposure, visibility, or engagement of specific content (such as boosting videos, posts, or other user-generated content), the price needs to adjust dynamically based on the user-selected budget. How can this type of In-App Purchase flow be implemented in iOS Swift?

Also checked link for tax category: https://developer.apple.com/help/app-store-connect/manage-app-information/set-a-tax-category

How to handle dynamic pricing in consumable in app purchase programatically in swift?
 
 
Q