AddThisFeature

Stripe Payment Link Creation

Generate Stripe payment links from records without letting anyone set their own price.

moderate Payments & Finance

What it adds

A server-side generator that turns an app record into a shareable Stripe payment link, with reuse rules, reconciliation metadata, and a defined expiry.

What your agent is told to do

5
  1. 1

    Generate links only on the server, from a record the requesting user is permitted to bill for. Price, currency, and quantity limits come from that record, never from the request.

  2. 2

    Decide per link whether it is single-use or reusable, and enforce it in the app rather than assuming the shared URL will be treated politely. A link posted publicly will be opened by people you did not send it to.

  3. 3

    Attach the app's own reference for the record so an incoming payment can be matched back without a human reading the description. Keep that reference opaque and free of names, emails, or anything else that should not travel with a public link.

  4. 4

    Recognise payment through verified server-side confirmations. The browser returning from a link proves only that a browser returned.

  5. 5

    Restrict who may create a link with a non-standard price, a discount, or a custom amount, and record who created each one. Without that, any user with access to the screen can quietly sell your product at whatever price they choose.

Edge cases it handles

8
  • Reusable and single-use links behave very differently once shared. A single-use link opened a second time must show a clear expired state, and a reusable link must state whether quantity is fixed or chosen by the payer.
  • Metadata travelling with a link is not private. Carry an internal identifier only, and resolve everything else server-side after payment.
  • When the underlying offer changes price, is withdrawn, or its record is deleted, existing links must be deactivated rather than left selling something at the old terms.
  • Payment confirmation must come from a verified server event, because payers frequently close the tab before being redirected back and the app would otherwise never learn they paid.
  • Link creation must be permission-gated per price variation, and the creator recorded, so a discounted or custom-amount link can be traced to whoever issued it.
  • The provider will resend confirmations. Match each one to the link and the payment it belongs to so a retry does not fulfil the same order twice.
  • Give every link an expiry, even a long one, so an abandoned link does not stay live indefinitely after everyone has forgotten it.
  • If the provider fails while a link is being created, do not leave a half-created record that shows a link the user cannot open.

Definition of done

9
  • Links are generated server-side with price and quantity taken only from the source record.
  • Single-use links refuse a second payment and show an explicit expired state.
  • Links carry an opaque internal reference and no personal or sensitive data.
  • Changing or withdrawing the underlying offer deactivates its outstanding links.
  • Fulfilment happens on a verified server confirmation and is idempotent across retries.
  • Creating a discounted or custom-price link requires an explicit permission and is attributed to its creator.
  • Every link has an expiry and the app shows its current status alongside the record.
  • The feature matches the existing design system.
  • No existing functionality is broken.

Related features

How it works

  1. 1

    Copy the link

    Grab the Markdown instruction URL for this feature.

  2. 2

    Give it to your AI

    Paste it into Claude Code, Cursor, v0, Lovable — whatever you build with.

  3. 3

    It inspects, then implements

    Your agent reads your existing app first, then adds the feature to fit it.

Works with your stack

These instructions are written to adapt. They tell the agent to detect your framework, match your existing design system, and reuse what you already have — rather than assuming a particular stack.

Need it tighter than that? Customize the feature and tell it exactly what you're running.