MCPcopy Index your code
hub / github.com/danpaquin/coinbasepro-python / get_products

Method get_products

cbpro/public_client.py:32–50  ·  view source on GitHub ↗

Get a list of available currency pairs for trading. Returns: list: Info about all currency pairs. Example:: [ { "id": "BTC-USD", "display_name": "BTC/USD", "base_currency"

(self)

Source from the content-addressed store, hash-verified

30 self.session = requests.Session()
31
32 def get_products(self):
33 """Get a list of available currency pairs for trading.
34
35 Returns:
36 list: Info about all currency pairs. Example::
37 [
38 {
39 "id": "BTC-USD",
40 "display_name": "BTC/USD",
41 "base_currency": "BTC",
42 "quote_currency": "USD",
43 "base_min_size": "0.01",
44 "base_max_size": "10000.00",
45 "quote_increment": "0.01"
46 }
47 ]
48
49 """
50 return self._send_message('get', '/products')
51
52 def get_product_order_book(self, product_id, level=1):
53 """Get a list of open orders for a product.

Callers 1

test_get_productsMethod · 0.80

Calls 1

_send_messageMethod · 0.95

Tested by 1

test_get_productsMethod · 0.64