{"action":"created","issue":{"url":"https://api.github.com/repos/knowm/XChange/issues/2774","repository_url":"https://api.github.com/repos/knowm/XChange","labels_url":"https://api.github.com/repos/knowm/XChange/issues/2774/labels{/name}","comments_url":"https://api.github.com/repos/knowm/XChange/issues/2774/comments","events_url":"https://api.github.com/repos/knowm/XChange/issues/2774/events","html_url":"https://github.com/knowm/XChange/pull/2774","id":354000273,"node_id":"MDExOlB1bGxSZXF1ZXN0MjEwODk1Njgz","number":2774,"title":"Make HitBTC client order id main id, since this id is used by the API.","user":{"login":"steventebrinke","id":1277338,"node_id":"MDQ6VXNlcjEyNzczMzg=","avatar_url":"https://avatars0.githubusercontent.com/u/1277338?v=4","gravatar_id":"","url":"https://api.github.com/users/steventebrinke","html_url":"https://github.com/steventebrinke","followers_url":"https://api.github.com/users/steventebrinke/followers","following_url":"https://api.github.com/users/steventebrinke/following{/other_user}","gists_url":"https://api.github.com/users/steventebrinke/gists{/gist_id}","starred_url":"https://api.github.com/users/steventebrinke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/steventebrinke/subscriptions","organizations_url":"https://api.github.com/users/steventebrinke/orgs","repos_url":"https://api.github.com/users/steventebrinke/repos","events_url":"https://api.github.com/users/steventebrinke/events{/privacy}","received_events_url":"https://api.github.com/users/steventebrinke/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-08-25T09:53:50Z","updated_at":"2018-08-25T19:43:36Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/knowm/XChange/pulls/2774","html_url":"https://github.com/knowm/XChange/pull/2774","diff_url":"https://github.com/knowm/XChange/pull/2774.diff","patch_url":"https://github.com/knowm/XChange/pull/2774.patch"},"body":"HitBTC uses the client order id for all API request. Therefore, after requesting an order it was impossible to do any other API requests with it, since not the client order id but the exchange id was returned. I updated the API such that now the id of an order can actually be used in the API requests that require an order id."},"comment":{"url":"https://api.github.com/repos/knowm/XChange/issues/comments/415992141","html_url":"https://github.com/knowm/XChange/pull/2774#issuecomment-415992141","issue_url":"https://api.github.com/repos/knowm/XChange/issues/2774","id":415992141,"node_id":"MDEyOklzc3VlQ29tbWVudDQxNTk5MjE0MQ==","user":{"login":"steventebrinke","id":1277338,"node_id":"MDQ6VXNlcjEyNzczMzg=","avatar_url":"https://avatars0.githubusercontent.com/u/1277338?v=4","gravatar_id":"","url":"https://api.github.com/users/steventebrinke","html_url":"https://github.com/steventebrinke","followers_url":"https://api.github.com/users/steventebrinke/followers","following_url":"https://api.github.com/users/steventebrinke/following{/other_user}","gists_url":"https://api.github.com/users/steventebrinke/gists{/gist_id}","starred_url":"https://api.github.com/users/steventebrinke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/steventebrinke/subscriptions","organizations_url":"https://api.github.com/users/steventebrinke/orgs","repos_url":"https://api.github.com/users/steventebrinke/repos","events_url":"https://api.github.com/users/steventebrinke/events{/privacy}","received_events_url":"https://api.github.com/users/steventebrinke/received_events","type":"User","site_admin":false},"created_at":"2018-08-25T19:43:36Z","updated_at":"2018-08-25T19:43:36Z","author_association":"CONTRIBUTOR","body":"That would indeed work, but IMO is not a very nice solution. Because that means that everyone who uses the HitBTC API must use such a check. For example, I wrote the following code (and assumed it would work until I tested it on HitBTC):\r\n```java\r\ntrade_service.cancelOrder(order.getId())\r\n```\r\nYou propose that I use the following code.\r\n```java\r\ntrade_service.cancelOrder(order instanceof HitbtcLimitOrder ? ((HitbtcLimitOrder)order).getClientOrderId() : order.getId())\r\n```\r\nWell this works, but it already looks very cluttered and I'm not supporting many exchanges yet. But if for every exchange that I want to support I have to change my code with an additional case, my code becomes quite unreadable."}}
{"actor":{"display_login":"steventebrinke"}}