I think i understand how this is handled.
If you build and deploy the app in the device directly from a mac with Xcode then the payment api will take the sandbox tester you have on the client.
If you get the app from TestFlight then the payment api will take the main account of the client.
Hope will help someone