Best answer

Using formatter to convert Stripe amount field to currency with dollars and cents.

  • 18 March 2020
  • 3 replies
  • 616 views

Userlevel 1

A line item amount comes out of Stripe in cents like below for a $22 sale:

 

2200

 

How does one use the Formatter currency function to convert 2200 to $22.00.
 

Zapier documentation directs me to this page but I can’t wrap my head around the unicode stuff.

 

http://www.unicode.org/reports/tr35/tr35-numbers.html#Number_Format_Patterns

 

Any help would be appreciated.

 

Thanks!

icon

Best answer by JamFeedChristian 19 March 2020, 15:54

That format didn’t work but I found a simple solution.

 

Take the 2200 amount from Stripe and use the Formatter Math Problem operation and divide that amount by 100 to get the decimals I wanted 2200 → 22 (i.e. if the amount was 750 dividing by 100 would yield 7.5).

 

22 → Formatter Currency gave me the $22.00 I was looking for (7.5 → $7.50).

 

Yay MATH!

View original

This topic has been closed for comments

3 replies

Userlevel 7
Badge +8

Hi @JamFeedChristian - thanks for writing in today! Happy to help out here.

 

Have you taken a look at our little nifty video of how to use Formatter by Zapier to format currency? It looks like the unicode to select is this one: #,##0.##

Could you give it a try and let me know if that worked for you?

Userlevel 1

That format didn’t work but I found a simple solution.

 

Take the 2200 amount from Stripe and use the Formatter Math Problem operation and divide that amount by 100 to get the decimals I wanted 2200 → 22 (i.e. if the amount was 750 dividing by 100 would yield 7.5).

 

22 → Formatter Currency gave me the $22.00 I was looking for (7.5 → $7.50).

 

Yay MATH!

Userlevel 7
Badge +8

@JamFeedChristian That’s fantastic and thank you so much for sharing your answer! Really appreciate it.

I hope you have a wonderful rest of your day!