cointrader.net 0.8.0 → 0.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/cointrader.net/client.rb +1 -0
- data/lib/cointrader.net/client/error.rb +6 -0
- data/lib/cointrader.net/client/request.rb +30 -1
- data/lib/cointrader.net/version.rb +1 -1
- data/spec/client_spec.rb +49 -79
- data/spec/fixtures/vcr_cassettes/{balance.yml → Cointrader_Client/account/_balance/returns_a_balance.yml} +6 -6
- data/spec/fixtures/vcr_cassettes/{tradehistory.yml → Cointrader_Client/account/_tradehistory/returns_trade_history.yml} +6 -6
- data/spec/fixtures/vcr_cassettes/{cancel.yml → Cointrader_Client/order/_cancel/cancels_an_order.yml} +12 -12
- data/spec/fixtures/vcr_cassettes/Cointrader_Client/order/_limit_buy/returns_an_order.yml +66 -0
- data/spec/fixtures/vcr_cassettes/Cointrader_Client/order/_limit_buy/throws_an_error_when_there_are_insufficient_funds.yml +66 -0
- data/spec/fixtures/vcr_cassettes/Cointrader_Client/order/_limit_sell/returns_an_order.yml +66 -0
- data/spec/fixtures/vcr_cassettes/{list.yml → Cointrader_Client/order/_list/when_there_are_no_orders/throws_an_error.yml} +6 -6
- data/spec/fixtures/vcr_cassettes/Cointrader_Client/order/_list/when_there_are_orders/lists_open_limit_orders.yml +129 -0
- data/spec/fixtures/vcr_cassettes/Cointrader_Client/order/_market_buy/returns_an_order.yml +67 -0
- data/spec/fixtures/vcr_cassettes/Cointrader_Client/order/_market_sell/returns_an_order.yml +66 -0
- data/spec/fixtures/vcr_cassettes/{trades.yml → Cointrader_Client/order/_trades/lists_recent_trades_executed.yml} +11 -9
- data/spec/fixtures/vcr_cassettes/{orders.yml → Cointrader_Client/stats/_orders/returns_open_orders.yml} +12 -12
- data/spec/fixtures/vcr_cassettes/{stats_24h.yml → Cointrader_Client/stats/_stats_24h/returns_24_hour_sliding_statistics.yml} +11 -11
- data/spec/fixtures/vcr_cassettes/{stats_7d.yml → Cointrader_Client/stats/_stats_7d/returns_7_day_sliding_statistics.yml} +10 -10
- data/spec/fixtures/vcr_cassettes/{symbol.yml → Cointrader_Client/stats/_symbol/returns_supported_currencies.yml} +6 -6
- data/spec/spec_helper.rb +1 -0
- metadata +33 -28
- data/spec/fixtures/vcr_cassettes/limit_buy.yml +0 -65
- data/spec/fixtures/vcr_cassettes/limit_sell.yml +0 -58
- data/spec/fixtures/vcr_cassettes/market_buy.yml +0 -71
- data/spec/fixtures/vcr_cassettes/market_sell.yml +0 -72
| @@ -0,0 +1,66 @@ | |
| 1 | 
            +
            ---
         | 
| 2 | 
            +
            http_interactions:
         | 
| 3 | 
            +
            - request:
         | 
| 4 | 
            +
                method: post
         | 
| 5 | 
            +
                uri: https://sandbox.cointrader.net/api4/order/BTCUSD/buy
         | 
| 6 | 
            +
                body:
         | 
| 7 | 
            +
                  encoding: UTF-8
         | 
| 8 | 
            +
                  string: '{"total_quantity":"1.00000000","price":"1000000.00","secret":"2MlxW8mUU9MG4bvq7C6M4PSd5J8SaauW4H2dXnyJyAcN","t":"2015-07-06
         | 
| 9 | 
            +
                    00:33:17 UTC"}'
         | 
| 10 | 
            +
                headers:
         | 
| 11 | 
            +
                  Accept:
         | 
| 12 | 
            +
                  - "*/*; q=0.5, application/xml"
         | 
| 13 | 
            +
                  Accept-Encoding:
         | 
| 14 | 
            +
                  - gzip, deflate
         | 
| 15 | 
            +
                  Content-Type:
         | 
| 16 | 
            +
                  - application/json
         | 
| 17 | 
            +
                  X-Auth:
         | 
| 18 | 
            +
                  - nCsNvmrxTpYFnJQyU16gq6R9ncOUA6UhF4wZnuf7IqkL
         | 
| 19 | 
            +
                  X-Auth-Hash:
         | 
| 20 | 
            +
                  - bf49911188e34b57a97eda8a885a911429e031ad9458d6979f5fa68657fd278a
         | 
| 21 | 
            +
                  Content-Length:
         | 
| 22 | 
            +
                  - '138'
         | 
| 23 | 
            +
                  User-Agent:
         | 
| 24 | 
            +
                  - Ruby
         | 
| 25 | 
            +
              response:
         | 
| 26 | 
            +
                status:
         | 
| 27 | 
            +
                  code: 200
         | 
| 28 | 
            +
                  message: OK
         | 
| 29 | 
            +
                headers:
         | 
| 30 | 
            +
                  Date:
         | 
| 31 | 
            +
                  - Mon, 06 Jul 2015 00:33:20 GMT
         | 
| 32 | 
            +
                  Server:
         | 
| 33 | 
            +
                  - Apache
         | 
| 34 | 
            +
                  X-Frame-Options:
         | 
| 35 | 
            +
                  - SAMEORIGIN
         | 
| 36 | 
            +
                  X-Xss-Protection:
         | 
| 37 | 
            +
                  - 1; mode=block
         | 
| 38 | 
            +
                  X-Content-Type-Options:
         | 
| 39 | 
            +
                  - nosniff
         | 
| 40 | 
            +
                  X-Powered-By:
         | 
| 41 | 
            +
                  - ''
         | 
| 42 | 
            +
                  Set-Cookie:
         | 
| 43 | 
            +
                  - CTXIDSCK=3j0c95nnjvrac7cnlq6e84e7h3; path=/; HttpOnly
         | 
| 44 | 
            +
                  Expires:
         | 
| 45 | 
            +
                  - Thu, 19 Nov 1981 08:52:00 GMT
         | 
| 46 | 
            +
                  Cache-Control:
         | 
| 47 | 
            +
                  - no-store, no-cache, must-revalidate, post-check=0, pre-check=0
         | 
| 48 | 
            +
                  Pragma:
         | 
| 49 | 
            +
                  - no-cache
         | 
| 50 | 
            +
                  Vary:
         | 
| 51 | 
            +
                  - Accept-Encoding
         | 
| 52 | 
            +
                  Content-Encoding:
         | 
| 53 | 
            +
                  - gzip
         | 
| 54 | 
            +
                  Content-Length:
         | 
| 55 | 
            +
                  - '131'
         | 
| 56 | 
            +
                  Content-Type:
         | 
| 57 | 
            +
                  - application/json
         | 
| 58 | 
            +
                body:
         | 
| 59 | 
            +
                  encoding: ASCII-8BIT
         | 
| 60 | 
            +
                  string: !binary |-
         | 
| 61 | 
            +
                    H4sIAAAAAAAAA6tWKi5NTk4tLlaySkvMKU7VUcoFchLTU5WslJxKKxX8i1JS
         | 
| 62 | 
            +
                    ixRci4ryi6wUPPOKS9PSMpMzU/NKFNxK81KK9RSCUnMTM/My89KtFAz0DKBA
         | 
| 63 | 
            +
                    QUlHKSWxJFHJqlopFaTXOT8FZKKFgZESsg0kGFhbywUAxhnDjqwAAAA=
         | 
| 64 | 
            +
                http_version: 
         | 
| 65 | 
            +
              recorded_at: Mon, 06 Jul 2015 00:33:21 GMT
         | 
| 66 | 
            +
            recorded_with: VCR 2.9.3
         | 
| @@ -0,0 +1,66 @@ | |
| 1 | 
            +
            ---
         | 
| 2 | 
            +
            http_interactions:
         | 
| 3 | 
            +
            - request:
         | 
| 4 | 
            +
                method: post
         | 
| 5 | 
            +
                uri: https://sandbox.cointrader.net/api4/order/BTCUSD/sell
         | 
| 6 | 
            +
                body:
         | 
| 7 | 
            +
                  encoding: UTF-8
         | 
| 8 | 
            +
                  string: '{"total_quantity":"1.00000000","price":"10.00","secret":"2MlxW8mUU9MG4bvq7C6M4PSd5J8SaauW4H2dXnyJyAcN","t":"2015-07-06
         | 
| 9 | 
            +
                    00:33:21 UTC"}'
         | 
| 10 | 
            +
                headers:
         | 
| 11 | 
            +
                  Accept:
         | 
| 12 | 
            +
                  - "*/*; q=0.5, application/xml"
         | 
| 13 | 
            +
                  Accept-Encoding:
         | 
| 14 | 
            +
                  - gzip, deflate
         | 
| 15 | 
            +
                  Content-Type:
         | 
| 16 | 
            +
                  - application/json
         | 
| 17 | 
            +
                  X-Auth:
         | 
| 18 | 
            +
                  - nCsNvmrxTpYFnJQyU16gq6R9ncOUA6UhF4wZnuf7IqkL
         | 
| 19 | 
            +
                  X-Auth-Hash:
         | 
| 20 | 
            +
                  - 95aafb4b9218ba49aa2047ab1967d613190e7aa2187ea5f15c090f32d5931d86
         | 
| 21 | 
            +
                  Content-Length:
         | 
| 22 | 
            +
                  - '133'
         | 
| 23 | 
            +
                  User-Agent:
         | 
| 24 | 
            +
                  - Ruby
         | 
| 25 | 
            +
              response:
         | 
| 26 | 
            +
                status:
         | 
| 27 | 
            +
                  code: 200
         | 
| 28 | 
            +
                  message: OK
         | 
| 29 | 
            +
                headers:
         | 
| 30 | 
            +
                  Date:
         | 
| 31 | 
            +
                  - Mon, 06 Jul 2015 00:33:23 GMT
         | 
| 32 | 
            +
                  Server:
         | 
| 33 | 
            +
                  - Apache
         | 
| 34 | 
            +
                  X-Frame-Options:
         | 
| 35 | 
            +
                  - SAMEORIGIN
         | 
| 36 | 
            +
                  X-Xss-Protection:
         | 
| 37 | 
            +
                  - 1; mode=block
         | 
| 38 | 
            +
                  X-Content-Type-Options:
         | 
| 39 | 
            +
                  - nosniff
         | 
| 40 | 
            +
                  X-Powered-By:
         | 
| 41 | 
            +
                  - ''
         | 
| 42 | 
            +
                  Set-Cookie:
         | 
| 43 | 
            +
                  - CTXIDSCK=e40olep7ks6uvfp1g24j0a8572; path=/; HttpOnly
         | 
| 44 | 
            +
                  Expires:
         | 
| 45 | 
            +
                  - Thu, 19 Nov 1981 08:52:00 GMT
         | 
| 46 | 
            +
                  Cache-Control:
         | 
| 47 | 
            +
                  - no-store, no-cache, must-revalidate, post-check=0, pre-check=0
         | 
| 48 | 
            +
                  Pragma:
         | 
| 49 | 
            +
                  - no-cache
         | 
| 50 | 
            +
                  Vary:
         | 
| 51 | 
            +
                  - Accept-Encoding
         | 
| 52 | 
            +
                  Content-Encoding:
         | 
| 53 | 
            +
                  - gzip
         | 
| 54 | 
            +
                  Content-Length:
         | 
| 55 | 
            +
                  - '132'
         | 
| 56 | 
            +
                  Content-Type:
         | 
| 57 | 
            +
                  - application/json
         | 
| 58 | 
            +
                body:
         | 
| 59 | 
            +
                  encoding: ASCII-8BIT
         | 
| 60 | 
            +
                  string: !binary |-
         | 
| 61 | 
            +
                    H4sIAAAAAAAAA6tWKi5NTk4tLlaySkvMKU7VUcoFchLTU5WslIJTc3IU/ItS
         | 
| 62 | 
            +
                    UosUXIuK8ousFDzzikvT0jKTM1PzShTcSvNSivUUglJzEzPzMvPSrRQM9Ayg
         | 
| 63 | 
            +
                    QEFJRyklsSRRyapaKRWk1zk/BWSkhYGxErIVJBhYW8sFAJVCnnqtAAAA
         | 
| 64 | 
            +
                http_version: 
         | 
| 65 | 
            +
              recorded_at: Mon, 06 Jul 2015 00:33:24 GMT
         | 
| 66 | 
            +
            recorded_with: VCR 2.9.3
         | 
| @@ -5,8 +5,8 @@ http_interactions: | |
| 5 5 | 
             
                uri: https://sandbox.cointrader.net/api4/order/BTCUSD/list
         | 
| 6 6 | 
             
                body:
         | 
| 7 7 | 
             
                  encoding: UTF-8
         | 
| 8 | 
            -
                  string: '{"secret":"2MlxW8mUU9MG4bvq7C6M4PSd5J8SaauW4H2dXnyJyAcN","t":"2015-06 | 
| 9 | 
            -
                     | 
| 8 | 
            +
                  string: '{"secret":"2MlxW8mUU9MG4bvq7C6M4PSd5J8SaauW4H2dXnyJyAcN","t":"2015-07-06
         | 
| 9 | 
            +
                    00:33:31 UTC"}'
         | 
| 10 10 | 
             
                headers:
         | 
| 11 11 | 
             
                  Accept:
         | 
| 12 12 | 
             
                  - "*/*; q=0.5, application/xml"
         | 
| @@ -17,7 +17,7 @@ http_interactions: | |
| 17 17 | 
             
                  X-Auth:
         | 
| 18 18 | 
             
                  - nCsNvmrxTpYFnJQyU16gq6R9ncOUA6UhF4wZnuf7IqkL
         | 
| 19 19 | 
             
                  X-Auth-Hash:
         | 
| 20 | 
            -
                  -  | 
| 20 | 
            +
                  - fd87c6d284ee7c6da6acac927938d72525bceba305124349e445987ea3faaff4
         | 
| 21 21 | 
             
                  Content-Length:
         | 
| 22 22 | 
             
                  - '87'
         | 
| 23 23 | 
             
                  User-Agent:
         | 
| @@ -28,7 +28,7 @@ http_interactions: | |
| 28 28 | 
             
                  message: OK
         | 
| 29 29 | 
             
                headers:
         | 
| 30 30 | 
             
                  Date:
         | 
| 31 | 
            -
                  -  | 
| 31 | 
            +
                  - Mon, 06 Jul 2015 00:33:33 GMT
         | 
| 32 32 | 
             
                  Server:
         | 
| 33 33 | 
             
                  - Apache
         | 
| 34 34 | 
             
                  X-Frame-Options:
         | 
| @@ -40,7 +40,7 @@ http_interactions: | |
| 40 40 | 
             
                  X-Powered-By:
         | 
| 41 41 | 
             
                  - ''
         | 
| 42 42 | 
             
                  Set-Cookie:
         | 
| 43 | 
            -
                  - CTXIDSCK= | 
| 43 | 
            +
                  - CTXIDSCK=rf0m2fjbi932cvi0bdu95fifi6; path=/; HttpOnly
         | 
| 44 44 | 
             
                  Expires:
         | 
| 45 45 | 
             
                  - Thu, 19 Nov 1981 08:52:00 GMT
         | 
| 46 46 | 
             
                  Cache-Control:
         | 
| @@ -62,5 +62,5 @@ http_interactions: | |
| 62 62 | 
             
                    74Ke40iqsJNblGKsb7iZYNGwaXfaTNGXQ1eZVjyJmprPzSOGd4eDvUAiLCX7
         | 
| 63 63 | 
             
                    IPI0w+/A4cAfnQJNcN/RA2AZKkJ3AAAA
         | 
| 64 64 | 
             
                http_version: 
         | 
| 65 | 
            -
              recorded_at:  | 
| 65 | 
            +
              recorded_at: Mon, 06 Jul 2015 00:33:34 GMT
         | 
| 66 66 | 
             
            recorded_with: VCR 2.9.3
         | 
| @@ -0,0 +1,129 @@ | |
| 1 | 
            +
            ---
         | 
| 2 | 
            +
            http_interactions:
         | 
| 3 | 
            +
            - request:
         | 
| 4 | 
            +
                method: post
         | 
| 5 | 
            +
                uri: https://sandbox.cointrader.net/api4/order/BTCUSD/buy
         | 
| 6 | 
            +
                body:
         | 
| 7 | 
            +
                  encoding: UTF-8
         | 
| 8 | 
            +
                  string: '{"total_quantity":"1.00000000","price":"10.00","secret":"2MlxW8mUU9MG4bvq7C6M4PSd5J8SaauW4H2dXnyJyAcN","t":"2015-07-06
         | 
| 9 | 
            +
                    00:33:27 UTC"}'
         | 
| 10 | 
            +
                headers:
         | 
| 11 | 
            +
                  Accept:
         | 
| 12 | 
            +
                  - "*/*; q=0.5, application/xml"
         | 
| 13 | 
            +
                  Accept-Encoding:
         | 
| 14 | 
            +
                  - gzip, deflate
         | 
| 15 | 
            +
                  Content-Type:
         | 
| 16 | 
            +
                  - application/json
         | 
| 17 | 
            +
                  X-Auth:
         | 
| 18 | 
            +
                  - nCsNvmrxTpYFnJQyU16gq6R9ncOUA6UhF4wZnuf7IqkL
         | 
| 19 | 
            +
                  X-Auth-Hash:
         | 
| 20 | 
            +
                  - 9481a4f6d2a4cc3f1162b20c6f7928e24997976d141c3761a274bbb9442bce54
         | 
| 21 | 
            +
                  Content-Length:
         | 
| 22 | 
            +
                  - '133'
         | 
| 23 | 
            +
                  User-Agent:
         | 
| 24 | 
            +
                  - Ruby
         | 
| 25 | 
            +
              response:
         | 
| 26 | 
            +
                status:
         | 
| 27 | 
            +
                  code: 200
         | 
| 28 | 
            +
                  message: OK
         | 
| 29 | 
            +
                headers:
         | 
| 30 | 
            +
                  Date:
         | 
| 31 | 
            +
                  - Mon, 06 Jul 2015 00:33:28 GMT
         | 
| 32 | 
            +
                  Server:
         | 
| 33 | 
            +
                  - Apache
         | 
| 34 | 
            +
                  X-Frame-Options:
         | 
| 35 | 
            +
                  - SAMEORIGIN
         | 
| 36 | 
            +
                  X-Xss-Protection:
         | 
| 37 | 
            +
                  - 1; mode=block
         | 
| 38 | 
            +
                  X-Content-Type-Options:
         | 
| 39 | 
            +
                  - nosniff
         | 
| 40 | 
            +
                  X-Powered-By:
         | 
| 41 | 
            +
                  - ''
         | 
| 42 | 
            +
                  Set-Cookie:
         | 
| 43 | 
            +
                  - CTXIDSCK=n1k2phoqepg6s3fo7plki50ko6; path=/; HttpOnly
         | 
| 44 | 
            +
                  Expires:
         | 
| 45 | 
            +
                  - Thu, 19 Nov 1981 08:52:00 GMT
         | 
| 46 | 
            +
                  Cache-Control:
         | 
| 47 | 
            +
                  - no-store, no-cache, must-revalidate, post-check=0, pre-check=0
         | 
| 48 | 
            +
                  Pragma:
         | 
| 49 | 
            +
                  - no-cache
         | 
| 50 | 
            +
                  Vary:
         | 
| 51 | 
            +
                  - Accept-Encoding
         | 
| 52 | 
            +
                  Content-Encoding:
         | 
| 53 | 
            +
                  - gzip
         | 
| 54 | 
            +
                  Content-Length:
         | 
| 55 | 
            +
                  - '131'
         | 
| 56 | 
            +
                  Content-Type:
         | 
| 57 | 
            +
                  - application/json
         | 
| 58 | 
            +
                body:
         | 
| 59 | 
            +
                  encoding: ASCII-8BIT
         | 
| 60 | 
            +
                  string: !binary |-
         | 
| 61 | 
            +
                    H4sIAAAAAAAAA6tWKi5NTk4tLlaySkvMKU7VUcoFchLTU5WslJxKKxX8i1JS
         | 
| 62 | 
            +
                    ixRci4ryi6wUPPOKS9PSMpMzU/NKFNxK81KK9RSCUnMTM/My89KtFAz0DKBA
         | 
| 63 | 
            +
                    QUlHKSWxJFHJqlopFaTXOT8FZKKFgZESsg0kGFhbywUAxhnDjqwAAAA=
         | 
| 64 | 
            +
                http_version: 
         | 
| 65 | 
            +
              recorded_at: Mon, 06 Jul 2015 00:33:29 GMT
         | 
| 66 | 
            +
            - request:
         | 
| 67 | 
            +
                method: post
         | 
| 68 | 
            +
                uri: https://sandbox.cointrader.net/api4/order/BTCUSD/buy
         | 
| 69 | 
            +
                body:
         | 
| 70 | 
            +
                  encoding: UTF-8
         | 
| 71 | 
            +
                  string: '{"total_quantity":"1.00000000","price":"10.00","secret":"2MlxW8mUU9MG4bvq7C6M4PSd5J8SaauW4H2dXnyJyAcN","t":"2015-07-06
         | 
| 72 | 
            +
                    00:33:29 UTC"}'
         | 
| 73 | 
            +
                headers:
         | 
| 74 | 
            +
                  Accept:
         | 
| 75 | 
            +
                  - "*/*; q=0.5, application/xml"
         | 
| 76 | 
            +
                  Accept-Encoding:
         | 
| 77 | 
            +
                  - gzip, deflate
         | 
| 78 | 
            +
                  Content-Type:
         | 
| 79 | 
            +
                  - application/json
         | 
| 80 | 
            +
                  X-Auth:
         | 
| 81 | 
            +
                  - nCsNvmrxTpYFnJQyU16gq6R9ncOUA6UhF4wZnuf7IqkL
         | 
| 82 | 
            +
                  X-Auth-Hash:
         | 
| 83 | 
            +
                  - b682a2e081f9a38d855b1524b66c5d59e1248a071210c73fbf98b5dc0a123172
         | 
| 84 | 
            +
                  Content-Length:
         | 
| 85 | 
            +
                  - '133'
         | 
| 86 | 
            +
                  User-Agent:
         | 
| 87 | 
            +
                  - Ruby
         | 
| 88 | 
            +
              response:
         | 
| 89 | 
            +
                status:
         | 
| 90 | 
            +
                  code: 200
         | 
| 91 | 
            +
                  message: OK
         | 
| 92 | 
            +
                headers:
         | 
| 93 | 
            +
                  Date:
         | 
| 94 | 
            +
                  - Mon, 06 Jul 2015 00:33:30 GMT
         | 
| 95 | 
            +
                  Server:
         | 
| 96 | 
            +
                  - Apache
         | 
| 97 | 
            +
                  X-Frame-Options:
         | 
| 98 | 
            +
                  - SAMEORIGIN
         | 
| 99 | 
            +
                  X-Xss-Protection:
         | 
| 100 | 
            +
                  - 1; mode=block
         | 
| 101 | 
            +
                  X-Content-Type-Options:
         | 
| 102 | 
            +
                  - nosniff
         | 
| 103 | 
            +
                  X-Powered-By:
         | 
| 104 | 
            +
                  - ''
         | 
| 105 | 
            +
                  Set-Cookie:
         | 
| 106 | 
            +
                  - CTXIDSCK=8mql68atg9kgidsdsaquv425c6; path=/; HttpOnly
         | 
| 107 | 
            +
                  Expires:
         | 
| 108 | 
            +
                  - Thu, 19 Nov 1981 08:52:00 GMT
         | 
| 109 | 
            +
                  Cache-Control:
         | 
| 110 | 
            +
                  - no-store, no-cache, must-revalidate, post-check=0, pre-check=0
         | 
| 111 | 
            +
                  Pragma:
         | 
| 112 | 
            +
                  - no-cache
         | 
| 113 | 
            +
                  Vary:
         | 
| 114 | 
            +
                  - Accept-Encoding
         | 
| 115 | 
            +
                  Content-Encoding:
         | 
| 116 | 
            +
                  - gzip
         | 
| 117 | 
            +
                  Content-Length:
         | 
| 118 | 
            +
                  - '131'
         | 
| 119 | 
            +
                  Content-Type:
         | 
| 120 | 
            +
                  - application/json
         | 
| 121 | 
            +
                body:
         | 
| 122 | 
            +
                  encoding: ASCII-8BIT
         | 
| 123 | 
            +
                  string: !binary |-
         | 
| 124 | 
            +
                    H4sIAAAAAAAAA6tWKi5NTk4tLlaySkvMKU7VUcoFchLTU5WslJxKKxX8i1JS
         | 
| 125 | 
            +
                    ixRci4ryi6wUPPOKS9PSMpMzU/NKFNxK81KK9RSCUnMTM/My89KtFAz0DKBA
         | 
| 126 | 
            +
                    QUlHKSWxJFHJqlopFaTXOT8FZKKFgZESsg0kGFhbywUAxhnDjqwAAAA=
         | 
| 127 | 
            +
                http_version: 
         | 
| 128 | 
            +
              recorded_at: Mon, 06 Jul 2015 00:33:31 GMT
         | 
| 129 | 
            +
            recorded_with: VCR 2.9.3
         | 
| @@ -0,0 +1,67 @@ | |
| 1 | 
            +
            ---
         | 
| 2 | 
            +
            http_interactions:
         | 
| 3 | 
            +
            - request:
         | 
| 4 | 
            +
                method: post
         | 
| 5 | 
            +
                uri: https://sandbox.cointrader.net/api4/order/BTCUSD/marketbuy
         | 
| 6 | 
            +
                body:
         | 
| 7 | 
            +
                  encoding: UTF-8
         | 
| 8 | 
            +
                  string: '{"total_amount":"1.00","secret":"2MlxW8mUU9MG4bvq7C6M4PSd5J8SaauW4H2dXnyJyAcN","t":"2015-07-06
         | 
| 9 | 
            +
                    00:33:34 UTC"}'
         | 
| 10 | 
            +
                headers:
         | 
| 11 | 
            +
                  Accept:
         | 
| 12 | 
            +
                  - "*/*; q=0.5, application/xml"
         | 
| 13 | 
            +
                  Accept-Encoding:
         | 
| 14 | 
            +
                  - gzip, deflate
         | 
| 15 | 
            +
                  Content-Type:
         | 
| 16 | 
            +
                  - application/json
         | 
| 17 | 
            +
                  X-Auth:
         | 
| 18 | 
            +
                  - nCsNvmrxTpYFnJQyU16gq6R9ncOUA6UhF4wZnuf7IqkL
         | 
| 19 | 
            +
                  X-Auth-Hash:
         | 
| 20 | 
            +
                  - 279099c1b651634f15b65a99177d0bab73a10651e02547bee6965011fd0e90e8
         | 
| 21 | 
            +
                  Content-Length:
         | 
| 22 | 
            +
                  - '109'
         | 
| 23 | 
            +
                  User-Agent:
         | 
| 24 | 
            +
                  - Ruby
         | 
| 25 | 
            +
              response:
         | 
| 26 | 
            +
                status:
         | 
| 27 | 
            +
                  code: 200
         | 
| 28 | 
            +
                  message: OK
         | 
| 29 | 
            +
                headers:
         | 
| 30 | 
            +
                  Date:
         | 
| 31 | 
            +
                  - Mon, 06 Jul 2015 00:33:42 GMT
         | 
| 32 | 
            +
                  Server:
         | 
| 33 | 
            +
                  - Apache
         | 
| 34 | 
            +
                  X-Frame-Options:
         | 
| 35 | 
            +
                  - SAMEORIGIN
         | 
| 36 | 
            +
                  X-Xss-Protection:
         | 
| 37 | 
            +
                  - 1; mode=block
         | 
| 38 | 
            +
                  X-Content-Type-Options:
         | 
| 39 | 
            +
                  - nosniff
         | 
| 40 | 
            +
                  X-Powered-By:
         | 
| 41 | 
            +
                  - ''
         | 
| 42 | 
            +
                  Set-Cookie:
         | 
| 43 | 
            +
                  - CTXIDSCK=uioc369ir679ugkd8mea33vba4; path=/; HttpOnly
         | 
| 44 | 
            +
                  Expires:
         | 
| 45 | 
            +
                  - Thu, 19 Nov 1981 08:52:00 GMT
         | 
| 46 | 
            +
                  Cache-Control:
         | 
| 47 | 
            +
                  - no-store, no-cache, must-revalidate, post-check=0, pre-check=0
         | 
| 48 | 
            +
                  Pragma:
         | 
| 49 | 
            +
                  - no-cache
         | 
| 50 | 
            +
                  Vary:
         | 
| 51 | 
            +
                  - Accept-Encoding
         | 
| 52 | 
            +
                  Content-Encoding:
         | 
| 53 | 
            +
                  - gzip
         | 
| 54 | 
            +
                  Content-Length:
         | 
| 55 | 
            +
                  - '136'
         | 
| 56 | 
            +
                  Content-Type:
         | 
| 57 | 
            +
                  - application/json
         | 
| 58 | 
            +
                body:
         | 
| 59 | 
            +
                  encoding: ASCII-8BIT
         | 
| 60 | 
            +
                  string: !binary |-
         | 
| 61 | 
            +
                    H4sIAAAAAAAAA02MsQrCMBRFd7/icXEsJYODZLOVgoOT+gHP5EWCNYW8RJDS
         | 
| 62 | 
            +
                    f7dujgfOOTO0OieqsIFHlQavFfghsDhzfkqh7trfLkfq6ocGjqN4NPBcGHaG
         | 
| 63 | 
            +
                    5DzlfvI/fW92+M9PSWsI0UVJhYaavLZ0eK8Hvo9iaWtaY7Asmy8UakItgwAA
         | 
| 64 | 
            +
                    AA==
         | 
| 65 | 
            +
                http_version: 
         | 
| 66 | 
            +
              recorded_at: Mon, 06 Jul 2015 00:33:43 GMT
         | 
| 67 | 
            +
            recorded_with: VCR 2.9.3
         | 
| @@ -0,0 +1,66 @@ | |
| 1 | 
            +
            ---
         | 
| 2 | 
            +
            http_interactions:
         | 
| 3 | 
            +
            - request:
         | 
| 4 | 
            +
                method: post
         | 
| 5 | 
            +
                uri: https://sandbox.cointrader.net/api4/order/BTCUSD/marketsell
         | 
| 6 | 
            +
                body:
         | 
| 7 | 
            +
                  encoding: UTF-8
         | 
| 8 | 
            +
                  string: '{"total_amount":"1.00","secret":"2MlxW8mUU9MG4bvq7C6M4PSd5J8SaauW4H2dXnyJyAcN","t":"2015-07-06
         | 
| 9 | 
            +
                    00:33:43 UTC"}'
         | 
| 10 | 
            +
                headers:
         | 
| 11 | 
            +
                  Accept:
         | 
| 12 | 
            +
                  - "*/*; q=0.5, application/xml"
         | 
| 13 | 
            +
                  Accept-Encoding:
         | 
| 14 | 
            +
                  - gzip, deflate
         | 
| 15 | 
            +
                  Content-Type:
         | 
| 16 | 
            +
                  - application/json
         | 
| 17 | 
            +
                  X-Auth:
         | 
| 18 | 
            +
                  - nCsNvmrxTpYFnJQyU16gq6R9ncOUA6UhF4wZnuf7IqkL
         | 
| 19 | 
            +
                  X-Auth-Hash:
         | 
| 20 | 
            +
                  - 49706dd12ca9012046613e835318fff8005b375bb1b12aa9acf7edc1a6d6f176
         | 
| 21 | 
            +
                  Content-Length:
         | 
| 22 | 
            +
                  - '109'
         | 
| 23 | 
            +
                  User-Agent:
         | 
| 24 | 
            +
                  - Ruby
         | 
| 25 | 
            +
              response:
         | 
| 26 | 
            +
                status:
         | 
| 27 | 
            +
                  code: 200
         | 
| 28 | 
            +
                  message: OK
         | 
| 29 | 
            +
                headers:
         | 
| 30 | 
            +
                  Date:
         | 
| 31 | 
            +
                  - Mon, 06 Jul 2015 00:33:44 GMT
         | 
| 32 | 
            +
                  Server:
         | 
| 33 | 
            +
                  - Apache
         | 
| 34 | 
            +
                  X-Frame-Options:
         | 
| 35 | 
            +
                  - SAMEORIGIN
         | 
| 36 | 
            +
                  X-Xss-Protection:
         | 
| 37 | 
            +
                  - 1; mode=block
         | 
| 38 | 
            +
                  X-Content-Type-Options:
         | 
| 39 | 
            +
                  - nosniff
         | 
| 40 | 
            +
                  X-Powered-By:
         | 
| 41 | 
            +
                  - ''
         | 
| 42 | 
            +
                  Set-Cookie:
         | 
| 43 | 
            +
                  - CTXIDSCK=gvjkams63j9tc9m0bvo9fop8m2; path=/; HttpOnly
         | 
| 44 | 
            +
                  Expires:
         | 
| 45 | 
            +
                  - Thu, 19 Nov 1981 08:52:00 GMT
         | 
| 46 | 
            +
                  Cache-Control:
         | 
| 47 | 
            +
                  - no-store, no-cache, must-revalidate, post-check=0, pre-check=0
         | 
| 48 | 
            +
                  Pragma:
         | 
| 49 | 
            +
                  - no-cache
         | 
| 50 | 
            +
                  Vary:
         | 
| 51 | 
            +
                  - Accept-Encoding
         | 
| 52 | 
            +
                  Content-Encoding:
         | 
| 53 | 
            +
                  - gzip
         | 
| 54 | 
            +
                  Content-Length:
         | 
| 55 | 
            +
                  - '132'
         | 
| 56 | 
            +
                  Content-Type:
         | 
| 57 | 
            +
                  - application/json
         | 
| 58 | 
            +
                body:
         | 
| 59 | 
            +
                  encoding: ASCII-8BIT
         | 
| 60 | 
            +
                  string: !binary |-
         | 
| 61 | 
            +
                    H4sIAAAAAAAAA02MsQrCMBRFd7/iceciXQTJppWCQ6e2H/BMXiQYU8hLXEr/
         | 
| 62 | 
            +
                    3bo5HjjnrNBqrajCeI4qDd478FNgMHB+SaHr1M3jjUaJkXoOURwaOC4Ms0Jy
         | 
| 63 | 
            +
                    XnK3uJ9/bk/47+9Jq/fBBkmF+pqcHuny2Q/8iGKoxbYdvnYTGFKAAAAA
         | 
| 64 | 
            +
                http_version: 
         | 
| 65 | 
            +
              recorded_at: Mon, 06 Jul 2015 00:33:45 GMT
         | 
| 66 | 
            +
            recorded_with: VCR 2.9.3
         | 
| @@ -5,8 +5,8 @@ http_interactions: | |
| 5 5 | 
             
                uri: https://sandbox.cointrader.net/api4/stats/trades/BTCUSD
         | 
| 6 6 | 
             
                body:
         | 
| 7 7 | 
             
                  encoding: UTF-8
         | 
| 8 | 
            -
                  string: '{"secret":"2MlxW8mUU9MG4bvq7C6M4PSd5J8SaauW4H2dXnyJyAcN","t":"2015-06 | 
| 9 | 
            -
                     | 
| 8 | 
            +
                  string: '{"secret":"2MlxW8mUU9MG4bvq7C6M4PSd5J8SaauW4H2dXnyJyAcN","t":"2015-07-06
         | 
| 9 | 
            +
                    00:33:45 UTC"}'
         | 
| 10 10 | 
             
                headers:
         | 
| 11 11 | 
             
                  Accept:
         | 
| 12 12 | 
             
                  - "*/*; q=0.5, application/xml"
         | 
| @@ -17,7 +17,7 @@ http_interactions: | |
| 17 17 | 
             
                  X-Auth:
         | 
| 18 18 | 
             
                  - nCsNvmrxTpYFnJQyU16gq6R9ncOUA6UhF4wZnuf7IqkL
         | 
| 19 19 | 
             
                  X-Auth-Hash:
         | 
| 20 | 
            -
                  -  | 
| 20 | 
            +
                  - 23f70180832bc5de9b0f0fea3ef30759d724b8a275975e00676144716ea2cba7
         | 
| 21 21 | 
             
                  Content-Length:
         | 
| 22 22 | 
             
                  - '87'
         | 
| 23 23 | 
             
                  User-Agent:
         | 
| @@ -28,7 +28,7 @@ http_interactions: | |
| 28 28 | 
             
                  message: OK
         | 
| 29 29 | 
             
                headers:
         | 
| 30 30 | 
             
                  Date:
         | 
| 31 | 
            -
                  -  | 
| 31 | 
            +
                  - Mon, 06 Jul 2015 00:33:46 GMT
         | 
| 32 32 | 
             
                  Server:
         | 
| 33 33 | 
             
                  - Apache
         | 
| 34 34 | 
             
                  X-Frame-Options:
         | 
| @@ -40,7 +40,7 @@ http_interactions: | |
| 40 40 | 
             
                  X-Powered-By:
         | 
| 41 41 | 
             
                  - ''
         | 
| 42 42 | 
             
                  Set-Cookie:
         | 
| 43 | 
            -
                  - CTXIDSCK= | 
| 43 | 
            +
                  - CTXIDSCK=km29ekhg9lq49534r72eje5hc1; path=/; HttpOnly
         | 
| 44 44 | 
             
                  Expires:
         | 
| 45 45 | 
             
                  - Thu, 19 Nov 1981 08:52:00 GMT
         | 
| 46 46 | 
             
                  Cache-Control:
         | 
| @@ -52,14 +52,16 @@ http_interactions: | |
| 52 52 | 
             
                  Content-Encoding:
         | 
| 53 53 | 
             
                  - gzip
         | 
| 54 54 | 
             
                  Content-Length:
         | 
| 55 | 
            -
                  - ' | 
| 55 | 
            +
                  - '178'
         | 
| 56 56 | 
             
                  Content-Type:
         | 
| 57 57 | 
             
                  - text/html
         | 
| 58 58 | 
             
                body:
         | 
| 59 59 | 
             
                  encoding: ASCII-8BIT
         | 
| 60 60 | 
             
                  string: !binary |-
         | 
| 61 | 
            -
                     | 
| 62 | 
            -
                     | 
| 61 | 
            +
                    H4sIAAAAAAAAAy2NvQ6CMBSFd5+C3BlICxRCR3F0AydjTFMabKKA7W2UEN7d
         | 
| 62 | 
            +
                    S+J4vvO3gg9aG+9BogsmBpxQPZspjAgSOMTwIlMNhlT7mD52HKKz8hjxqHOq
         | 
| 63 | 
            +
                    N54SvUIF8rqCDs6ZUS/3WVlHhWPXXNoTJWZn9b6Q5TxljMA7qBEtLsRYmnGR
         | 
| 64 | 
            +
                    l1Vdwf+dYFGnlSBtvkYHNP3eZVwkrEy4iDIuWSG5gO22HX6kMqRUwgAAAA==
         | 
| 63 65 | 
             
                http_version: 
         | 
| 64 | 
            -
              recorded_at:  | 
| 66 | 
            +
              recorded_at: Mon, 06 Jul 2015 00:33:47 GMT
         | 
| 65 67 | 
             
            recorded_with: VCR 2.9.3
         |