Skip to main content
PATCH
/
fee-rules
/
{feeRuleId}
curl --request PATCH \
  --url https://api.lightspark.com/grid/2025-10-13/fee-rules/{feeRuleId} \
  --header 'Authorization: Basic <encoded-value>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "enabled": false
}
'
{
  "id": "FeeRule:019c6a2b-4f8e-7d01-0000-000000000001",
  "transactionType": "CROSS_BORDER_PAYOUT",
  "feeType": "HYBRID",
  "enabled": true,
  "createdAt": "2026-01-15T00:00:00Z",
  "updatedAt": "2026-02-01T12:30:00Z",
  "fixedFee": 150,
  "variableFeeRate": 0.005
}

Authorizations

Authorization
string
header
required

API token authentication using format <api token id>:<api client secret>

Path Parameters

feeRuleId
string
required

System-generated unique fee rule identifier

Body

application/json

Partial update for an existing fee rule. Only provided fields are updated. The transactionType and feeType cannot be changed — delete and recreate the rule instead.

fixedFee
integer<int64>

Updated fixed fee in the smallest unit of USD (cents). Must be between 0 and 10000.

Required range: 0 <= x <= 10000
Example:

200

variableFeeRate
number<double>

Updated variable fee as a decimal rate. Must be between 0 and 0.20.

Required range: 0 <= x <= 0.2
Example:

0.01

enabled
boolean

Enable or disable the fee rule

Example:

false

Response

Fee rule updated successfully

A platform fee rule defines the markup a platform charges its customers on a specific transaction type, on top of Lightspark and counterparty fees. Rules are evaluated at quote creation and the resulting platform fee is collected in real time during settlement.

id
string
required

System-generated unique identifier

Example:

"FeeRule:019c6a2b-4f8e-7d01-0000-000000000001"

transactionType
enum<string>
required

The type of transaction the fee rule applies to. Platform fee rules are scoped to a single transaction type — only one rule per type is allowed.

Available options:
TRANSFER_IN,
TRANSFER_OUT,
RAMP_ON,
RAMP_OFF,
CROSS_BORDER_PAYOUT
Example:

"CROSS_BORDER_PAYOUT"

feeType
enum<string>
required

Determines which fee components apply. FIXED charges a flat amount per transaction. PERCENTAGE charges a rate of the transaction amount. HYBRID applies both a fixed amount and a percentage rate.

Available options:
FIXED,
PERCENTAGE,
HYBRID
Example:

"HYBRID"

enabled
boolean
required

Whether this fee rule is actively applied to new transactions. Disabled rules are retained for reporting but do not affect new quotes.

Example:

true

createdAt
string<date-time>
required

When the fee rule was created

Example:

"2026-01-15T00:00:00Z"

updatedAt
string<date-time>
required

When the fee rule was last modified

Example:

"2026-02-01T12:30:00Z"

fixedFee
integer<int64>

Fixed fee in the smallest unit of USD (cents). Applied per transaction. Required when feeType is FIXED or HYBRID.

Required range: x >= 0
Example:

150

variableFeeRate
number<double>

Variable fee as a decimal rate of the transaction amount (e.g., 0.005 = 0.5%). Applied to the sending amount at quote creation. Required when feeType is PERCENTAGE or HYBRID.

Required range: 0 <= x <= 0.2
Example:

0.005