Skip to content

Conversation

@frankie567
Copy link
Member

No description provided.

Copy link
Collaborator

@psincraian psincraian left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Really nice writeup François!


- Store presentment amount and currency in the current amount fields.
- When receiving a payment or refund from Stripe, we'll need to get the converted amount in `usd` Stripe calculated (from the balance transaction), to impact the merchant's Account balance.
- Revamp metrics so amount are always computed in `usd`, directly from the Account transactions amount.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How will history work with exchange rates?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So, the idea is to store the converted amount (say usd for simplicity) in the account transactions (at the moment we receive the payment), and use them not only for payouts like we do today, but for metrics.

Effectively, if you look at MRR, a single subscription might fluctuate over months following exchange rates.


## Technical Considerations and Open Questions

### Polar fees
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@birkjernstrom to bring some wisdom here


When issuing a refund, we'll issue it in the original presentment currency. If the exchange rate has changed since the original payment, we might have to withdwraw more money from the merchant's balance than the original payment amount (in settlement currency).

For example, if a customer paid 100 EUR when the exchange rate was 1 EUR = 1.1 USD, the merchant received 110 USD. If we refund the customer later when the exchange rate is 1 EUR = 1.2 USD, we need to withdraw 120 USD from the merchant's balance to refund the customer.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What will happen if the merchant doesn't have enough balance?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They'll go negative. It can already happen today if we do a refund after the funds have been paid out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants