---
title: "Create Payment Link"
method: POST
path: "/v1/paylinks"
tags: ["Paylinks"]
---

# Create Payment Link

`POST /v1/paylinks`

The **Create Payment Link** endpoint enables you to generate a new payment link for a specific product or service within the BoomFi platform. This link can be customized with various parameters, such as the amount, currency, and description, facilitating payments for a wide range of offerings. Use this endpoint to quickly create payment links you can share with customers to collect payments seamlessly.

> 📘 Note
> 
> When creating a payment link, you can implicitly create a plan by providing details such as `amount` and `currency`.

> 🚧  Account-specific Paylinks 
>
> Create an account-specific paylink by adding either `account_ref` or `account_ids`. Its important to note that you cannot add both.

## Request body

- PaylinksCreatePaymentLinkRequest
  - `account_ids` integer[] — A list of account IDs to associate with the payment link. Use this to attach specific accounts to the payment link, making it account-specific. <small>⚠️ Either `account_ids` or `account_ref` should be used, not both. ⚠️</small>
  - `account_ref` string — An account reference to associate with the payment link. Use this to attach accounts with the specified account reference to the payment link, making it account-specific. <small>⚠️ Either `account_ids` or `account_ref` should be used, not both. ⚠️</small>
  - `name` string, required — The name of the payment link.
  - `amount` string, required — The amount associated with the payment link.
  - `currency` string, required — The currency of the payment link.
  - `reference` string — The reference for the payment link.
  - `description` string — A description of the payment link.
  - `interval` 'Week' | 'Month' | 'Year' — The recurring interval for the payment link: - **Week** - **Month** - **Year**
  - `intervalCount` integer — The number of intervals for the recurring payment link.
  - `trial_period` string — The trial period for the payment link in a valid duration format. For example, for 1 day use 24h.
  - `image_url` string — An image URL to be used as the cover image for the payment link at the checkout.
  - `available_quantity` number — Limits the number of times the payment link can be used. When set to a positive non-zero value, the payment link becomes limited-usage. For example, set `available_quantity` to `1` to create a one-time use payment link. - A successful or failed payment decreases the counter by one. - A canceled payment reverts the counter (quantity is restored). - When the counter reaches zero, the payment link becomes invalid and no further checkouts are accepted.
  - `expires_at` string, date-time — Sets an expiration date and time for the payment link. Any checkout attempt after this timestamp will fail, as the payment link is no longer valid.
  - `metadata` PaylinksCreatePaymentLinkRequestMetadata
    - `payment_method_types` string[] — Specifies the payment methods available at checkout. By default, the system applies payment methods based on the merchant’s settlement account settings. If `Card` is included, the card payment option appears only if the merchant has a Card settlement account configured. Accepts an array with any or all of these values: - **MerchantContract** - **ProxyWallet** - **Card**
    - `after_completion` object — Defines post-checkout behavior. The configuration allows either a custom success message or a redirect to a specified URL upon payment completion.
      - `type` 'hosted' | 'redirect' — Sets the post-checkout behavior: - **hosted**: Displays a success message, customizable with `custom_message`. - **redirect**: Sends the user to a specified URL via `redirect_url`.
      - `custom_message` string — A custom success message shown after payment completion if `type` is set to `hosted`. If not provided, a default success message will be displayed.
      - `redirect_url` string, uri — URL to which the user is redirected after successful payment if `type` is set to `redirect`. A valid URL is required for this type.
    - `omit_possible_duplicate_acknowledgement` boolean — Determines if users should be notified when attempting multiple one-time payments. - **true**: A prompt will notify users of prior payments to the link, but they can proceed with an additional payment. - **false**: No prompt will be shown for repeated payments.

## Response `200`

OK

- InternalResponsePaylinksPaymentLinkResponse
  - `data` PaylinksPaymentLinkResponse
    - `id` string — The unique identifier for the paylink
    - `plan_id` string — The ID of the associated plan
    - `invoice_id` string — The ID of the associated invoice
    - `source` string — The source of the paylink
    - `customer_ident_collection` boolean — Indicates if customer identification collection is enabled
    - `shipping_address_collection` boolean — Indicates if shipping address collection is enabled
    - `tax_ident_collection` boolean — Indicates if tax identification collection is enabled
    - `enabled` boolean — Indicates if the paylink is enabled
    - `deleted_at` string, date-time — The timestamp when the paylink was deleted
    - `created_by` string — The ID of the user who created the paylink
    - `updated_by` string — The ID of the user who last updated the paylink
    - `created_at` string, date-time — The timestamp when the paylink was created
    - `updated_at` string, date-time — The timestamp when the paylink was last updated
    - `available_quantity` number — The remaining number of times this payment link can be used. `null` indicates unlimited usage. - Decremented on each successful or failed payment. - Restored when a payment is canceled. - When the value reaches zero, the payment link becomes invalid.
    - `expires_at` string, date-time — The expiration date and time of the payment link. Any checkout attempt after this timestamp will fail.
    - `metadata` object — Additional metadata associated with the paylink
    - `properties` object — Additional properties associated with the paylink
      - `short_code` string — The short code associated with the paylink
    - `plan` object — The details of the associated plan
      - `id` string — The unique identifier for the plan
      - `org_id` string — The organization ID associated with the plan
      - `source` string — The source of the plan
      - `name` string — The name of the plan
      - `type` string — The type of the plan
      - `billing_scheme` string — The billing scheme of the plan
      - `price` string — The price of the plan
      - `currency` string — The currency of the plan
      - `available_quantity` integer — The available quantity of the plan
      - `trial_period` string — The trial period of the plan
      - `recurring_interval` string — The recurring interval of the plan
      - `recurring_interval_count` integer — The recurring interval count of the plan
      - `recurring_usage_type` string — The recurring usage type of the plan
      - `reference` string — The reference of the plan
      - `enabled` boolean — Indicates if the plan is enabled
      - `v1` string — Additional information about the plan
      - `created_by` string — The ID of the user who created the plan
      - `created_at` string, date-time — The timestamp when the plan was created
      - `updated_at` string, date-time — The timestamp when the plan was last updated
      - `deleted_at` string, date-time — The timestamp when the plan was deleted
      - `metadata` object — Additional metadata associated with the plan
  - `error` boolean

## Other responses

- `400` — Bad Request
- `500` — Internal Server Error

---

[API](https://skmtc.net/boomfi/apis/boomfi-merchants-api.md) · [All operations](https://skmtc.net/boomfi/apis/boomfi-merchants-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/boomfi/boomfi-merchants-api/revisions/ace3c3df05fe/schema)
