Sign Customiser

Navigation

Dark mode

Pricing

delete_customiser_length_pricing

destructive write

Delete customiser length pricing

Copy page

Remove a length pricing that nothing prices by any more, after the merchant has agreed to it.

Overview

Deletes one length pricing of a customiser permanently, so the call requires confirm true and changes nothing without it. A price list that a font or the icon settings still price by is refused with resource_in_use, which lists the referencing records; references are never cleared silently. Calling with dry_run true first returns the same verdict without deleting anything. The result carries the price list as it was. It requires the pricing:write scope and an idempotency_key.

Permission

Requires thepricing:writepermission. A connection without it answersinsufficient_scopenaming the permission to approve.

Annotations

readOnlyHintfalse
destructiveHinttrue
idempotentHinttrue
openWorldHintfalse

Prerequisites

  • A customiser id from list_customisers and a length pricing id from list_customiser_length_pricings.
  • The merchant explicit agreement, sent as confirm true.
  • A merchant has connected this store and approved the pricing:write scope.

Side effects

  • Deletes one length pricing and its rows permanently.
  • Clears the customiser cached storefront configuration.
  • Spends one unit of the store option-write budget.
  • Claims the idempotency_key for at least 24 hours.

Arguments

customiser_idintegerrequired

The customiser id, from list_customisers.

length_pricing_idintegerrequired

The length pricing id, from list_customiser_length_pricings.

confirmbooleanrequired unless dry_run is true

Must be true to apply the change, because the price list and its rows are removed permanently and cannot be restored through this connector. Without it the call returns a confirmation_required error and changes nothing.

idempotency_keystringrequired unless dry_run is true

A client-generated key unique to this logical write, such as a UUID. Required: repeating the call with the same key and the same arguments replays the original result instead of writing twice, and the same key with different arguments is an idempotency_key_conflict.

dry_runboolean

When true, the deletion is checked against every font and setting that still prices by the list is checked and nothing is written: the result is the same verdict the apply would have reached, and a problem the apply would have raised comes back as the same tool error. Defaults to false. A dry run claims no key. A dry run does not require the confirm argument.

Result

The deleted price list id and the price list as it was, with every row. A dry run returns the delete verdict instead and deletes nothing.

request_idstringalways present
storeobjectalways present
store.idintegeralways present
store.namestringalways present
customiser_idintegeralways present
length_pricing_idintegeralways present
deletedboolean

True when the price list was deleted. Absent on a dry run, where nothing is deleted.

length_pricingobject

The price list as it was when it was deleted, so the caller can report or recreate it. Absent on a dry run.

length_pricing.idintegeralways present
length_pricing.customiser_idintegeralways present
length_pricing.namestring or null
length_pricing.letter_pricing_modestring or null

One of: every_letter_cost, price_by_position

length_pricing.letter_pricing_methodstring or null

One of: material_length, fixed_letter

length_pricing.shippingobject
length_pricing.shipping.calculationstring or null
length_pricing.shipping.volumetric_divisorinteger or null
length_pricing.shipping.volumetric_divisor_authoredinteger or null
length_pricing.shipping.volumetric_divisor_unitstring or null
length_pricing.shipping.volumetric_divisor_canonicalnumber or null
length_pricing.shipping.authored_unitsobject
length_pricing.shipping.add_weight_to_productboolean
length_pricing.currencystring or null

The ISO 4217 currency of every integer minor-unit amount on the record.

length_pricing.rows_revisioninteger
length_pricing.rowsarray of object
length_pricing.rows[].idstring
length_pricing.rows[].base_pricenumber or null
length_pricing.rows[].price_per_letternumber or null
length_pricing.rows[].price_per_cmnumber or null
length_pricing.rows[].price_per_innumber or null
length_pricing.rows[].price_per_sq_cmnumber or null
length_pricing.rows[].price_per_sq_innumber or null
length_pricing.rows[].price_per_lbnumber or null
length_pricing.rows[].max_price_multipliernumber or null
length_pricing.rows[].width_limit_cmnumber or null
length_pricing.rows[].width_limit_innumber or null
length_pricing.rows[].height_limit_cmnumber or null
length_pricing.rows[].height_limit_innumber or null
length_pricing.rows[].length_limit_cmnumber or null
length_pricing.rows[].length_limit_innumber or null
length_pricing.rows[].fixed_length_cmnumber or null
length_pricing.rows[].fixed_length_innumber or null
length_pricing.rows[].width_modifiernumber or null
length_pricing.rows[].width_modifier_innumber or null
length_pricing.rows[].height_modifiernumber or null
length_pricing.rows[].height_modifier_innumber or null
length_pricing.rows[].length_modifiernumber or null
length_pricing.rows[].length_modifier_innumber or null
length_pricing.rows[].price_per_sq_cm_basisstring

One of: per_sq_cm, per_kg_volumetric

length_pricing.rows[].price_per_letter_by_positionarray of integer
length_pricing.rows[].authored_unitsobject
length_pricing.created_atstring or null
length_pricing.updated_atstring or null
idempotent_replayboolean

True when this call replayed a previously recorded response for the same idempotency_key instead of applying the write again.

dry_runboolean

Present and true only when dry_run was requested.

validboolean

Present only on a dry run, and always true: a failing dry run returns a tool error instead.

verdictobject

Present only on a dry run: the delete verdict.

Error cases

confirmation_required

Send confirm true once the merchant has agreed to the deletion. Nothing was deleted.

idempotency_subject_changed

The price list lifecycle changed after the recorded deletion. Issue a new key and re-check the resource before writing again.

insufficient_scope

The connection was approved without pricing:write.

rate_limited

The store option-write budget is spent. Wait retry_after seconds.

resource_in_use

A font or the icon settings still price by this list. referenced_by lists them; move them to another price list first.

resource_not_found

No length pricing with that id belongs to that customiser in this store.

Delete a price list the merchant confirmed

tools/call
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "delete_customiser_length_pricing",
    "arguments": {
      "customiser_id": 42,
      "length_pricing_id": 9,
      "confirm": true,
      "idempotency_key": "c3d4e5f6-a7b8-4c9d-8e0f-1a2b3c4d5e6f"
    }
  }
}
result
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {
    "structuredContent": {
      "request_id": "req_01jz9x2k7c8f3m5n6p7q8r9s0t",
      "store": {
        "id": 12,
        "name": "Demo Signs"
      },
      "customiser_id": 42,
      "length_pricing_id": 9,
      "deleted": true,
      "length_pricing": {
        "id": 9,
        "customiser_id": 42,
        "name": "Standard",
        "letter_pricing_mode": "every_letter_cost",
        "letter_pricing_method": "fixed_letter",
        "shipping": {
          "calculation": "physical",
          "volumetric_divisor": null,
          "add_weight_to_product": false
        },
        "currency": "USD",
        "rows": [],
        "created_at": "2026-08-13T00:00:00Z",
        "updated_at": "2026-08-13T00:00:00Z"
      },
      "idempotent_replay": false
    }
  }
}

A price list a font still uses (error)

tools/call
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "delete_customiser_length_pricing",
    "arguments": {
      "customiser_id": 42,
      "length_pricing_id": 9,
      "dry_run": true
    }
  }
}
result
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {
    "isError": true,
    "structuredContent": {
      "error": {
        "code": "resource_in_use",
        "title": "Resource in use",
        "detail": "This length pricing is still referenced by font records.",
        "recovery": "Other records still reference this one. Call the same tool with dry_run: true to enumerate them, clear those references, then retry.",
        "referenced_by": [
          {
            "type": "font",
            "id": 19,
            "name": "Modern Sans"
          }
        ]
      }
    }
  }
}

Type a question and press Enter. Use the arrow keys to move between the results.