MCPcopy Create free account
hub / github.com/CodebuffAI/codebuff / convertStripeGrantAmountToCredits

Function convertStripeGrantAmountToCredits

common/src/util/currency.ts:20–25  ·  view source on GitHub ↗
(
  amountInCents: number,
  centsPerCredit: number,
)

Source from the content-addressed store, hash-verified

18 * @returns The number of credits
19 */
20export function convertStripeGrantAmountToCredits(
21 amountInCents: number,
22 centsPerCredit: number,
23): number {
24 return Math.floor(amountInCents / centsPerCredit)
25}

Callers 1

useAutoTopupFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected