From cfd16ec58b0c3045ddf7b610a8fd7c8cac286d3a Mon Sep 17 00:00:00 2001 From: nyg Date: Thu, 28 Mar 2024 21:52:57 +0100 Subject: [PATCH] Example of nested body params --- .../main/java/dev/andstuff/kraken/example/SimpleExamples.java | 2 ++ .../dev/andstuff/kraken/api/model/endpoint/priv/PostParams.java | 2 -- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/src/main/java/dev/andstuff/kraken/example/SimpleExamples.java b/examples/src/main/java/dev/andstuff/kraken/example/SimpleExamples.java index dd2863f..8374700 100644 --- a/examples/src/main/java/dev/andstuff/kraken/example/SimpleExamples.java +++ b/examples/src/main/java/dev/andstuff/kraken/example/SimpleExamples.java @@ -64,6 +64,8 @@ public static void main(String[] args) { "pair", "XLTCZUSD", "price", "1000", "oflags", "post,fciq", + "close[ordertype]", "limit", + "close[price]", "1500", "validate", "true")); log.info("{}", order); } diff --git a/library/src/main/java/dev/andstuff/kraken/api/model/endpoint/priv/PostParams.java b/library/src/main/java/dev/andstuff/kraken/api/model/endpoint/priv/PostParams.java index 02f3c82..3852d14 100644 --- a/library/src/main/java/dev/andstuff/kraken/api/model/endpoint/priv/PostParams.java +++ b/library/src/main/java/dev/andstuff/kraken/api/model/endpoint/priv/PostParams.java @@ -16,9 +16,7 @@ public String initNonce() { return nonce; } - // TODO handle nested props public String encoded() { - Map params = params(); params.put("nonce", nonce);