#wery_ubb-price-names

1 messages ยท Page 1 of 1 (latest)

thorny saddleBOT
#

๐Ÿ‘‹ Welcome to your new thread!

โฒ๏ธ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.

โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.

๐Ÿ”— This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1440064936385449995

๐Ÿ“ Have more to share? Add more details, code, screenshots, videos, etc. below.

Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.

narrow portal
#

I had a thread before that, but after some research I really believe there should be a way to change at least how it shows on the invoice

#

For reference, this is how the Stripe checkout looks like right now

#

this is how it looks for other companies (as mentioned). this example shows one of the invoices generated today by railway (a hosting provider). they use stripe and PAYG as well.

normal heron
#

Hi ๐Ÿ‘‹

Are you creating separate meters?

thorny saddleBOT
narrow portal
#

Yes, each meter is separate

normal heron
#

Can you share the ID of a couple prices that all have the same name?

thorny saddleBOT
#

wery_ubb-price-names

narrow portal
#

Of course,

price_1SSjrXGxqtVxSNAzavLqQ46L
price_1SSjjRGxqtVxSNAzHuD7JWrW
price_1SSjfUGxqtVxSNAzkuRI3u4O

2 meters and one flat fee. These all relate to the same product (in this case, "Pro")

weary spoke
#

hi, I'm caught up and taking a look now

#

can you try different Products backing each of the Prices? I think the name on the Invoice is the Product name

#

try that and let me know if that gets you what you need

narrow portal
#

How to create a stripe checkout link using that approach?

  const session = await stripe.checkout.sessions.create({
      mode: "subscription",
      customer: customerId,
      line_items: [
        {
          // Base
          price: PRICES[product].base,
          quantity: 1,
        },
        {
          // AI Usage
          price: PRICES[product].ai,
        },
        {
          // Storage GB
          price: PRICES[product].storage,
        },
      ],
      success_url:
        "",
      cancel_url: "",
      metadata: {
        organizationId: user.organizationId,
        purchasedBy: user.id,
        referenceId: user.organizationId,
      },
      subscription_data: {
        trial_period_days: 14,

        metadata: {
          organizationId: user.organizationId,
          purchasedBy: user.id,
        },
      },
    });

Would the user have to subscribe to each meter, or could I just replace price IDs with product IDs?

weary spoke
#

what I'm saying is, create new test Products with the name that you want, then create Prices for them, then manually pass them in the Checkout Session creation

narrow portal
#

Okay yeah that worked. Thanks!