PaymentSource .update
PATCH /{namespace}/payment-sources/{id}
Changes the given properties of a Payment Source.
- Noun
- Payment Source
- Mode
do- Event
PaymentSource.updated
Update changes the given properties of a Payment Source. It is inherited: every Noun has get, list, create, update and delete.
Inputs
| Input | Type | Required | Description |
|---|---|---|---|
id | string | required | The id of the Payment Source. |
kind | string | How it pays: a card, a bank debit from the Customer’s account, or a wallet on the Customer’s phone or browser. | |
label | string | What the Customer sees, such as the card brand and last four digits; never the full number. | |
expiresOn | date | When a card expires; the billing portal asks for a new one 30 days before. | |
default | boolean | True for the one Payment Source that new Invoices and renewals charge. | |
removedAt | datetime | When the Customer removed it; nothing charges it after, and the record stays. |
Outputs
| Output | Type | Required | Description |
|---|---|---|---|
paymentSource | Payment Source | required | The Payment Source. |
Effects
- Emits
PaymentSource.updated. - Two-way:
try,send,do.
Refuses when
| Check | Error | Fix | Then call |
|---|---|---|---|
| The key is valid, but its scopes do not allow this operation. | forbidden | Use a key whose scopes cover the operation, or ask an owner of the namespace to grant them. | PaymentSource.update |
When it waits
| Gate | Default |
|---|---|
| Decision class | Low: two-way, nothing at stake |
| Delay window | None: it runs once review passes. |
| Limit | The call Limit of the Permission it runs under. |
| Over the Limit | It waits pending for an Approval from the Founder. Approved, it runs; refused, it ends refused with limit-exceeded; unanswered by its deadline, it ends canceled. |