Commerce
Charm / psychological pricing API
Converts a raw price into a charm/psychological price (.99, .95, round, even, or a custom ending) and reports the left-digit and whether it crosses a dollar threshold. Answers 'What is the .99 charm price for $19.42?', 'How do I price-ladder to a .95 ending?'.
Price$0.01per request
MethodPOST
Route/v1/commerce/charm-pricing
StatusLive
MIME typeapplication/json
Rate limit120/minute
Cache0s public
commercepricingcharmpsychologicalprice-ending99-centretailrounding
API URL
Integration docshttps://x402.hexl.dev/v1/commerce/charm-pricingExample request
{
"price": 19.42,
"strategy": "charm99"
}Example response
{
"inputPrice": 19.42,
"strategy": "charm99",
"charmPrice": 19.99,
"deltaFromInput": 0.57,
"leftDigit": 19,
"crossesDollarThreshold": false,
"interpretation": "Charm price $19.99 (left-digit 19); above raw $19.42."
}Input schema
{
"type": "object",
"required": [
"price"
],
"properties": {
"price": {
"type": "number",
"examples": [
19.42
]
},
"strategy": {
"type": "string",
"enum": [
"charm99",
"charm95",
"round",
"even"
],
"examples": [
"charm99"
]
},
"ending": {
"type": "integer",
"examples": [
95
]
}
}
}Output schema
{
"type": "object",
"additionalProperties": true
}