# Clink Documentation ## Docs - [Integrate with an AI Agent](https://docs.clinkbill.com/agent-integration.md): Hand a prompt to the agent already writing the code and let it do the integration. - [TypeScript SDK](https://docs.clinkbill.com/api-reference/SDK.md): The official Node.js library for the Clink API. - [Clink CLI](https://docs.clinkbill.com/api-reference/clink_cli.md): Use clink-cli to initialize customer wallets, manage card links, pay, refund, and inspect risk rules from the command line. - [Activate Promotion Code](https://docs.clinkbill.com/api-reference/endpoint/activate-promotion-code.md): Activate a promotion code. - [Advance Test Clock](https://docs.clinkbill.com/api-reference/endpoint/advance-test-clock.md): Advance a test clock to the target frozen timestamp - [Cancel Subscription](https://docs.clinkbill.com/api-reference/endpoint/cancel-subscription.md): Cancel a subscription either immediately or at the end of the current billing period. - [Cancel Subscription Update](https://docs.clinkbill.com/api-reference/endpoint/cancel-subscription-update.md): Cancel a pending subscription plan update that has not taken effect yet. - [Complete Test Clock](https://docs.clinkbill.com/api-reference/endpoint/complete-test-clock.md): Complete a test clock and stop further simulated execution - [Confirm Subscription Update](https://docs.clinkbill.com/api-reference/endpoint/confirm-subscription-update.md): Confirm a subscription upgrade or downgrade using the target price snapshot returned by the preview API. Immediate updates may require payment; period-end updates return success when no immediate payment is required. - [Create Agent Payment Session](https://docs.clinkbill.com/api-reference/endpoint/create-agent-payment-session.md): Create agent payment session - [Create Checkout Session](https://docs.clinkbill.com/api-reference/endpoint/create-checkout-session.md): Create a new checkout session for payment processing - [Create Coupon](https://docs.clinkbill.com/api-reference/endpoint/create-coupon.md): Create a coupon and optionally create promotion codes for it. - [Customer Portal Session](https://docs.clinkbill.com/api-reference/endpoint/create-customer-portal.md): Create a new customer portal session for billing management - [Create Payment](https://docs.clinkbill.com/api-reference/endpoint/create-payment.md): Create a one-time payment with an existing payment instrument, or omit paymentInstrumentId for payment methods that support automatic payment instrument creation. Use either productId and priceId, or amount and currency. To charge in a different payment currency, provide paymentCurrency and Clink wi… - [Create Payment Instrument](https://docs.clinkbill.com/api-reference/endpoint/create-payment-instrument.md): Create a new payment instrument for a customer. The request resolves or creates the customer first, then stores the payment instrument under that customer. - [Create Price](https://docs.clinkbill.com/api-reference/endpoint/create-price.md): Create a price for an existing product under your current merchant account. - [Create Product](https://docs.clinkbill.com/api-reference/endpoint/create-product.md): Create a product with one or more price configurations. Product names can include localized values for multiple languages. - [Create Promotion Code](https://docs.clinkbill.com/api-reference/endpoint/create-promotion-code.md): Create a promotion code for a coupon. - [Create Refund](https://docs.clinkbill.com/api-reference/endpoint/create-refund.md): Create a refund for an existing order. The refundMerchantOrderId is used for idempotency. - [Create Subscription](https://docs.clinkbill.com/api-reference/endpoint/create-subscription.md): Create a subscription and initiate its first payment. Provide an existing payment instrument, or omit paymentInstrumentId for payment methods that support automatic payment instrument creation. - [Create Test Clock](https://docs.clinkbill.com/api-reference/endpoint/create-test-clock.md): Create a new test clock for a subscription - [Create Webhook Endpoint](https://docs.clinkbill.com/api-reference/endpoint/create-webhook-endpoint.md): Create a webhook endpoint for the current merchant. The endpoint URL must use HTTPS and resolve to a public host. - [Deactivate Promotion Code](https://docs.clinkbill.com/api-reference/endpoint/deactivate-promotion-code.md): Deactivate a promotion code. - [Delete Webhook Endpoint](https://docs.clinkbill.com/api-reference/endpoint/delete-webhook-endpoint.md): Delete a webhook endpoint. Deleted endpoints stop receiving webhook events. - [Disable Webhook Endpoint](https://docs.clinkbill.com/api-reference/endpoint/disable-webhook-endpoint.md): Disable a webhook endpoint. Disabled endpoints are saved but do not receive webhook events. - [Enable Webhook Endpoint](https://docs.clinkbill.com/api-reference/endpoint/enable-webhook-endpoint.md): Enable a webhook endpoint. - [Ensure Webhook Endpoint](https://docs.clinkbill.com/api-reference/endpoint/ensure-webhook-endpoint.md): Create or update a webhook endpoint by URL. This endpoint is designed for idempotent setup flows where applications need to safely create or reconcile a webhook endpoint. For existing endpoints, Clink does not return the stored plaintext signing secret unless the secret is rotated. - [Get Agent Payment Session](https://docs.clinkbill.com/api-reference/endpoint/get-agent-payment-session.md): Get agent payment session - [Get Checkout Session](https://docs.clinkbill.com/api-reference/endpoint/get-checkout-session.md): Retrieve details of an existing checkout session - [Get Coupon](https://docs.clinkbill.com/api-reference/endpoint/get-coupon.md): Get detailed information about a specific coupon, including its promotion codes. - [Get Invoice](https://docs.clinkbill.com/api-reference/endpoint/get-invoice.md): Get detailed information about a specific invoice - [Get Order](https://docs.clinkbill.com/api-reference/endpoint/get-order.md): Get detailed information about a specific order - [Get Price](https://docs.clinkbill.com/api-reference/endpoint/get-price.md): Get price information under your current merchant account based on the price ID - [Get Price List](https://docs.clinkbill.com/api-reference/endpoint/get-price-list.md): Get all price information under your current merchant account - [Get Product](https://docs.clinkbill.com/api-reference/endpoint/get-product.md): Get product information under your current merchant account based on the product ID - [Get Product List](https://docs.clinkbill.com/api-reference/endpoint/get-product-list.md): Get all product information under your current merchant account - [Get Promotion Code](https://docs.clinkbill.com/api-reference/endpoint/get-promotion-code.md): Get detailed information about a specific promotion code. - [Get Refund](https://docs.clinkbill.com/api-reference/endpoint/get-refund.md): Get detailed information about a specific refund - [Get Subscription](https://docs.clinkbill.com/api-reference/endpoint/get-subscription.md): Get detailed information about a specific subscription - [Get Test Clock](https://docs.clinkbill.com/api-reference/endpoint/get-test-clock.md): Retrieve details of a specific test clock - [Get Webhook Endpoint](https://docs.clinkbill.com/api-reference/endpoint/get-webhook-endpoint.md): Get a webhook endpoint by ID. - [List Coupons](https://docs.clinkbill.com/api-reference/endpoint/list-coupons.md): List coupons under your current merchant account with optional filters. - [List Orders](https://docs.clinkbill.com/api-reference/endpoint/list-orders.md): List orders under your current merchant account. You can filter orders by subscription ID, customer ID, or merchant reference ID. - [List Promotion Codes by Coupon](https://docs.clinkbill.com/api-reference/endpoint/list-promotion-codes-by-coupon.md): List promotion codes attached to a coupon. - [List Test Clocks](https://docs.clinkbill.com/api-reference/endpoint/list-test-clocks.md): List all active test clocks under your current merchant account - [List Webhook Endpoints](https://docs.clinkbill.com/api-reference/endpoint/list-webhook-endpoints.md): Get webhook endpoints under the current merchant account. - [List Webhook Events](https://docs.clinkbill.com/api-reference/endpoint/list-webhook-events.md): Return supported webhook events and event aliases. Use event names in webhook endpoint management requests; numeric event codes are returned for reference only. - [Preview Subscription Update](https://docs.clinkbill.com/api-reference/endpoint/preview-subscription-update.md): Preview a subscription upgrade or downgrade before confirming it. The target price must be a recurring price owned by the current merchant and must support the subscription payment currency. - [Refresh Wallet QR Code](https://docs.clinkbill.com/api-reference/endpoint/refresh-wallet-qrcode.md): Refresh the wallet QR code for an existing order. Currently only supports CASHAPP wallet payments. - [Rename Coupon](https://docs.clinkbill.com/api-reference/endpoint/rename-coupon.md): Update the display name of a coupon. - [Rotate Webhook Signing Secret](https://docs.clinkbill.com/api-reference/endpoint/rotate-webhook-signing-secret.md): Rotate the signing secret for a webhook endpoint. The previous secret stops working immediately. - [Update Price](https://docs.clinkbill.com/api-reference/endpoint/update-price.md): Update a price under your current merchant account based on the price ID. - [Update Webhook Endpoint](https://docs.clinkbill.com/api-reference/endpoint/update-webhook-endpoint.md): Update URL, events, description, or enabled status for a webhook endpoint. Omitted fields remain unchanged. - [Upload Product Image](https://docs.clinkbill.com/api-reference/endpoint/upload-product-image.md): Upload a product image as multipart form data. The file must be an image and must not exceed 5 MB. - [Introduction](https://docs.clinkbill.com/api-reference/introduction.md): API Reference and Integration Guide - [JavaScript SDK](https://docs.clinkbill.com/api-reference/javascript_sdk.md): Launch Clink Checkout from browser applications with redirect or embedded flows. - [customer.verify](https://docs.clinkbill.com/api-reference/webhook/customer.verify.md): Webhook notification triggered when customer verification is required - [dispute](https://docs.clinkbill.com/api-reference/webhook/dispute.md): Webhook notification triggered when dispute status changes. When a dispute reaches won or lost, an additional dispute.closed event is sent. - [invoice](https://docs.clinkbill.com/api-reference/webhook/invoice.md): Webhook notification triggered when an invoice is created or updated - [order](https://docs.clinkbill.com/api-reference/webhook/order.md): Handles order lifecycle events. - [refund](https://docs.clinkbill.com/api-reference/webhook/refund.md): Webhook notification triggered when refund is created or updated - [session](https://docs.clinkbill.com/api-reference/webhook/session.md): Webhook notification triggered when session is completed or expired - [subscription](https://docs.clinkbill.com/api-reference/webhook/subscription.md): Webhook notification triggered when a subscription is created or updated - [Hosted Checkout](https://docs.clinkbill.com/build-integration.md): What to write on the backend, the frontend, and the webhook handler. - [July 2026 Changelog](https://docs.clinkbill.com/changelog/july-2026.md): Agentic Payment, Pay by Link, and cross-currency payment updates - [June 2026 Changelog](https://docs.clinkbill.com/changelog/june-2026.md): Subscription orchestration, smart routing, and product portfolio finance updates - [Choose an Integration](https://docs.clinkbill.com/choose-integration.md): Three ways to host checkout, four server-side paths, and when each one fits. - [Elements](https://docs.clinkbill.com/elements.md): Embed Clink payment inputs in a merchant-owned checkout page, with the server still creating the Session. - [Balance](https://docs.clinkbill.com/finance/balance.md): Understanding fund management and financial flows - [Payout](https://docs.clinkbill.com/finance/payout.md): Understanding payout processes and timing expectation - [Simple, transparent pricing](https://docs.clinkbill.com/finance/pricing.md): Simple, transparent pricing for global payments, billing, tax, compliance, and agentic commerce. - [Go Live](https://docs.clinkbill.com/go-live.md): What to verify, what to change, and how to debug when switching to production. - [Merchant](https://docs.clinkbill.com/guides/account/merchant.md): The operating unit for your business. - [User](https://docs.clinkbill.com/guides/account/user.md): Manage dashboard users and permissions - [Skill Marketplace](https://docs.clinkbill.com/guides/agent/skill_marketplace.md): Prepare, submit, publish, and manage Skills in the Clink Skill Marketplace. - [Customer Portal](https://docs.clinkbill.com/guides/billing/customer_portal.md): Empower customers to manage their own subscriptions and billing - [Checkout Session](https://docs.clinkbill.com/guides/payments/checkout_session.md): A hosted checkout page experience - [Currencies](https://docs.clinkbill.com/guides/payments/currencies.md): Enable customers to pay in their local currency - [Link External Account](https://docs.clinkbill.com/guides/payments/link_psp.md): Connect with your existing payment processors - [Coupon](https://docs.clinkbill.com/guides/resources/coupon.md): Create and manage discounts for bills, subscriptions, and customer accounts. - [Customer](https://docs.clinkbill.com/guides/resources/customer.md): Managing your customer base - [Order](https://docs.clinkbill.com/guides/resources/order.md): Understanding payment transactions - [Product & Price](https://docs.clinkbill.com/guides/resources/product.md): Managing products and pricing structures - [Refund](https://docs.clinkbill.com/guides/resources/refund.md): Refund and Chargeback Policies - [Subscription](https://docs.clinkbill.com/guides/resources/subscription.md): Understanding the recurring payment contract - [How Payments Work](https://docs.clinkbill.com/how-payments-work.md): Checkout Session, Order, and the merchant order — what each one actually means. - [Introduction](https://docs.clinkbill.com/index.md): Clink aims to provide a simplified but solid subscription and payment solution. - [API Keys & Webhooks](https://docs.clinkbill.com/integration.md): Generating, rotating, and restricting API keys; registering, verifying, and receiving webhooks. - [Discounts and Promotion Codes](https://docs.clinkbill.com/promotions.md): Creating coupons and codes, and applying them across every integration path. - [Quickstart](https://docs.clinkbill.com/quickstart.md): Run one complete payment in the sandbox, from creating a Session to confirming the money arrived. - [Subscriptions](https://docs.clinkbill.com/subscriptions.md): Recurring prices, the first subscription, renewals, cancellation, and plan changes. ## OpenAPI Specs - [openapi](https://docs.clinkbill.com/api-reference/openapi.json)