billingCustomerLinkPreview
Shows what billingCustomerLink would do for a company and a customer that already
exists in Stripe: the subscription it would link, what each line would grant, and why
linking would be refused. Reads from Stripe without changing anything.
Business Rules
- Only an active, trialing, or past-due subscription can be linked.
- The subscription needs exactly one line on a catalog plan. Old Stripe products are not mapped, so a subscription without one has to move to a catalog plan in Stripe first.
- When several subscriptions qualify, the one on the highest plan is linked: the highest catalog price, with plans that have no catalog price (Enterprise, Custom) above every priced plan. A tie goes to the larger amount.
- The other subscriptions keep billing in Stripe and are not linked.
- Lines that are not on a catalog product grant nothing and are listed in
warnings.
Error Scenarios
Login required- No authenticated party on the request.Not authorized- The caller is not a system admin.Company not found- Refusals are returned in
problems, not raised.
Permissions Required
- System admin
billingCustomerLinkPreview(
companyId: ID!
externalCustomerId: String!
): BillingCustomerLinkPreview!
Arguments
billingCustomerLinkPreview.companyId ● ID! non-null scalar common
The company (party) to link.
billingCustomerLinkPreview.externalCustomerId ● String! non-null scalar common
The Stripe customer id, e.g. cus_123.
Type
BillingCustomerLinkPreview object billing
What linking a company to an existing provider customer would do, read from the provider without changing anything.