Nomod
Links/Create Link

Create Link

posthttps://api.nomod.com/v1/links

Generate link.

curl -X POST 'https://api.nomod.com/v1/links' \
  -H 'X-API-KEY: $NOMOD_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{
    "currency": "string",
    "items": [
      {
        "name": "string",
        "amount": "0.00",
        "quantity": 1
      }
    ],
    "title": "string",
    "note": "string",
    "discount_percentage": 0,
    "shipping_address_required": false,
    "allow_tip": false,
    "custom_fields": [
      {
        "name": "string"
      }
    ],
    "success_url": "https://example.com",
    "failure_url": "https://example.com",
    "allow_tabby": false,
    "allow_tamara": false,
    "allow_service_fee": false,
    "payment_expiry_limit": 1,
    "expiry_date": "2026-01-01"
  }'

Request body

currencystringrequired

ISO 4217 currency code for the link. Supported: AED, USD, EUR, GBP and SAR. Retrieve codes from the /currencies endpoint.

Max length: 3

itemsarrayrequired

List of items associated with this link, including name and amount.

titlestring

Craft a beautiful name for your link

Max length: 50

notestring

Type out a quick note describing what you're selling

Max length: 280

discount_percentageinteger

Discount percentage.

Max: 100

Min: 0

shipping_address_requiredboolean

Whether shipping address is required.

allow_tipboolean

Allow tips.

custom_fieldsarray

Custom fields to add. Maximum of 5 allowed

success_urlstring <uri>

URL to redirect to upon successful transaction completion

failure_urlstring <uri>

URL to redirect to if the transaction fails.

allow_tabbyboolean

Whether to enable Tabby payment method for the link. Default == true

allow_tamaraboolean

Whether to enable Tamara payment method for the link. Default == true

allow_service_feeboolean

Whether to enable service fee for the link. Default == true

payment_expiry_limitinteger

Set number of payments as link expiry. Link will auto-expire after the set number of payments expiry is reached. Note: Only one parameter can be set at one time, either payment_expiry_limit or expiry_date

Min: 1

expiry_datestring <date>

Set any of the future date as the expiry date. Link will auto expire at the end of the day (11:59 PM) of the set expiry date. Note: Only one parameter can be set at one time, either payment_expiry_limit or expiry_date

Responses

payment_block_reasonstringread-only

Currency-only payment block reason. currency_unavailable means the link or invoice is open for payment but its currency is inactive. null means no currency block applies, including objects whose checkout status is already closed. It is not a guarantee that other payment eligibility checks pass. The existing status, currency and amounts are unchanged.

Enum: currency_unavailable, null

idstring <uuid>requiredread-only
reference_idstringrequiredread-only
titlestringrequiredread-only
urlstring <uri>requiredread-only
amountstring <decimal>requiredread-only
currencystringrequired
statusobjectrequiredread-only
discountstring <decimal>requiredread-only
service_feestring <decimal>requiredread-only
allow_tipbooleanrequiredread-only
shipping_address_requiredbooleanrequiredread-only
itemsarrayrequired
taxstring <decimal>requiredread-only
notestringrequiredread-only
taxesarrayrequiredread-only
discount_percentageintegerrequiredread-only
service_fee_percentagestring <decimal>requiredread-only
tipstring <decimal>requiredread-only
tip_percentageintegerrequiredread-only
due_datestring <date-time>requiredread-only
custom_fieldsarrayrequiredread-only
sourceobjectrequiredread-only
allow_tabbybooleanrequiredread-only
allow_tamarabooleanrequiredread-only
allow_service_feebooleanrequiredread-only
payment_expiry_limitintegerrequiredread-only
expiry_datestring <date>requiredread-only

Example response

{
  "payment_block_reason": "currency_unavailable",
  "id": "00000000-0000-0000-0000-000000000000",
  "reference_id": "string",
  "title": "string",
  "url": "https://example.com",
  "amount": "0.00",
  "currency": "string",
  "status": "enabled",
  "discount": "0.00",
  "service_fee": "0.00",
  "allow_tip": false,
  "shipping_address_required": false,
  "items": [
    {
      "id": "00000000-0000-0000-0000-000000000000",
      "amount": "0.00",
      "name": "string",
      "total_amount": "0.00",
      "quantity": 0,
      "sku": "string"
    }
  ],
  "tax": "0.00",
  "note": "string",
  "taxes": [
    {
      "name": "string",
      "mode": "string",
      "mode_value": "0.000",
      "value": "0.000"
    }
  ],
  "discount_percentage": 0,
  "service_fee_percentage": "0.00",
  "tip": "0.00",
  "tip_percentage": 0,
  "due_date": "2026-01-01T00:00:00Z",
  "custom_fields": [
    {
      "name": "string",
      "is_required": false
    }
  ],
  "source": "nomod_hosted",
  "allow_tabby": false,
  "allow_tamara": false,
  "allow_service_fee": false,
  "payment_expiry_limit": 0,
  "expiry_date": "2026-01-01"
}