{"record":{"id":"3b8823567522f118","repo":"nautechsystems/nautilus_trader","slug":"kraken-spot-trailing-stops-do-not-support-activati","errorCode":null,"errorMessage":"Kraken Spot trailing stops do not support activation trigger prices","messagePattern":"Kraken Spot trailing stops do not support activation trigger prices","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/adapters/kraken/src/http/spot/client.rs","lineNumber":3082,"sourceCode":"\n        let is_conditional = matches!(\n            order_type,\n            OrderType::StopMarket\n                | OrderType::StopLimit\n                | OrderType::MarketIfTouched\n                | OrderType::LimitIfTouched\n                | OrderType::TrailingStopMarket\n                | OrderType::TrailingStopLimit\n        );\n\n        let is_trailing = matches!(\n            order_type,\n            OrderType::TrailingStopMarket | OrderType::TrailingStopLimit\n        );\n\n        if is_trailing {\n            if trigger_price.is_some() {\n                anyhow::bail!(\n                    \"Kraken Spot trailing stops do not support activation trigger prices\"\n                );\n            }\n\n            if let Some(offset) = trailing_offset {\n                builder.price(offset.to_string());\n            }\n\n            if let Some(offset) = limit_offset {\n                builder.price2(offset.to_string());\n            }\n        } else if is_conditional {\n            if let Some(trigger) = trigger_price {\n                builder.price(trigger.to_string());\n            }\n\n            if let Some(limit) = price {\n                builder.price2(limit.to_string());","sourceCodeStart":3064,"sourceCodeEnd":3100,"githubUrl":"https://github.com/nautechsystems/nautilus_trader/blob/18893faf8b356be3320add8de2f861b0b647cf06/crates/adapters/kraken/src/http/spot/client.rs#L3064-L3100","documentation":"Kraken Spot trailing-stop orders (TrailingStopMarket / TrailingStopLimit) define their activation level via a trailing offset only. The adapter rejects any request that also supplies an activation trigger price, because Kraken's spot API has no field for it and silently ignoring it would change order semantics.","triggerScenarios":"Submitting a TrailingStopMarket or TrailingStopLimit order via the Kraken Spot HTTP client with trigger_price set to Some(...) while a trailing_offset is intended to define activation.","commonSituations":"Porting strategy code from futures or other spot exchanges where stop orders always take an explicit trigger price; copying a generic order-request builder that populates trigger_price for all stop-order types.","solutions":["Remove trigger_price from the request and supply trailing_offset instead, which Kraken uses as the activation distance.","If an exact activation price is required, use a regular StopMarket/StopLimit order with trigger_price instead of a trailing-stop order type.","Wrap order construction in a venue-specific validation that clears trigger_price for trailing order types before calling the Kraken adapter."],"exampleFix":"// before\nsubmit(OrderType::TrailingStopMarket, trigger_price: Some(price), trailing_offset: Some(offset))\n// after\nsubmit(OrderType::TrailingStopMarket, trigger_price: None, trailing_offset: Some(offset))","handlingStrategy":"validation","validationCode":"if matches!(order_type, OrderType::TrailingStopMarket | OrderType::TrailingStopLimit) && trigger_price.is_some() {\n    return Err(\"Kraken Spot trailing stops use trailing_offset, not trigger_price\");\n}","typeGuard":null,"tryCatchPattern":"match client.submit_order(req) {\n    Err(e) if e.to_string().contains(\"activation trigger prices\") => {\n        // rebuild request without trigger_price and retry\n    }\n    result => result?,\n}","preventionTips":["Keep a venue-capability table that lists which order parameters each venue/order-type combination accepts.","Never blanket-populate trigger_price for all stop-order types in shared order builders.","Add unit tests covering every order type x parameter combination you submit to Kraken Spot."],"tags":["kraken","spot","trailing-stop","order-submission"],"backgroundTag":"unsupported-operation","analyzedSha":"18893faf8b356be3320add8de2f861b0b647cf06","analyzedAt":"2026-09-08T20:49:34.690Z","contentChangedAt":"2026-09-08T20:49:34.690Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}