{"id":42306010,"url":"https://github.com/igomez10/tulip","last_synced_at":"2026-01-27T11:09:26.749Z","repository":{"id":133347828,"uuid":"118969671","full_name":"igomez10/tulip","owner":"igomez10","description":"🌷An API for buda.com written in Go","archived":false,"fork":false,"pushed_at":"2019-07-14T14:59:25.000Z","size":39,"stargazers_count":8,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-01T05:24:58.148Z","etag":null,"topics":["api","bitcoin","buda","ethereum","surbtc"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/igomez10.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-01-25T21:26:45.000Z","updated_at":"2022-12-24T01:12:50.000Z","dependencies_parsed_at":null,"dependency_job_id":"e5a063b6-2778-4234-b630-0a9051afc48f","html_url":"https://github.com/igomez10/tulip","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/igomez10/tulip","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/igomez10%2Ftulip","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/igomez10%2Ftulip/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/igomez10%2Ftulip/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/igomez10%2Ftulip/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/igomez10","download_url":"https://codeload.github.com/igomez10/tulip/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/igomez10%2Ftulip/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28812371,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-27T07:41:26.337Z","status":"ssl_error","status_checked_at":"2026-01-27T07:41:08.776Z","response_time":168,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api","bitcoin","buda","ethereum","surbtc"],"created_at":"2026-01-27T11:09:26.177Z","updated_at":"2026-01-27T11:09:26.735Z","avatar_url":"https://github.com/igomez10.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🌷 Tulip 🌷\n\n\n\nAn open source API client for Buda written in Go.\n\nYou can check the current Buda API documentation at http://api.buda.com\n\nNOTE: You need a developer account in order to make full use of this client.\nYou can make unauthenticated calls (http://api.buda.com/#llamadas-p-blicas)\n\n\n### Available Methods ✅\n- #### Public 🔓\n  - Get markets info `GetMarkets()`\n  - Get ticker info `GetTicker()`\n  - Get all available orders for a market `GetOrderBook()`\n  - Get info about recent trades `GetTrades()`\n- #### Private (Requires APIkey) 🔑\n  - Get your current balance `GetBalances()`\n  - Get your orders `GetOrders()`\n  - Crate a new order (bid or ask) `PostOrder()`\n  - Cancel a current order `CancelOrder()`\n  - Get info about a specific order `GetOrder()`\n  - Get historic info about deposits `GetDepositHistory()`\n  - Get historic info about withdrawals `GetWithdrawHistory()`\n\n\n#### TODO 👨🏻‍💻\n\n  - Do Deposits and Withdrawals\n  - Do string interpolation for queries instead of appending strings together\n  - ?? Make a suggestion\n\n## Get it working 🦄\n\nIn your terminal:\n```sh\n$ go get github.com/igomez10/tulip\n```\n\n\nIn your .go file:\n```GO\npackage main\n\nimport (\n\t\"fmt\"\n\t\"os\"\n\n\t\"github.com/igomez10/tulip\"\n)\n\nfunc main() {\n\n\tAPIKey := os.Getenv(\"BUDAKEY\")       // you can modify this variable and hardocde your own apikey\n\tAPISecret := os.Getenv(\"BUDASECRET\") // you can modify this variable and hardcode your own apisecret\n\n\tbuda := tulip.CreateClient(APIKey, APISecret)\n\tresults, err := buda.GetTicker(\"btc-clp\")\n\tif err != nil {\n\t\tfmt.Println(err)\n\t} else {\n\t\tfmt.Println(results.Market.ID)                 // \"BTC-CLP\"\n\t\tfmt.Println(results.Market.Name)               // \"btc-clp\"\n\t\tfmt.Println(results.Market.BaseCurrency)       // \"BTC\"\n\t\tfmt.Println(results.Market.QuoteCurrency)      // \"CLP\"\n\t\tfmt.Println(results.Market.MinimumOrderAmount) // [\"0.0001 BTC\"]\n\t}\n```\n\n\n\n# Documentation 📄\n\n## Public Calls\n\n### Get Ticker\nGetTicker Returns info about a specific market\n\n```GO\nbuda.GetTicker(\u003cmarketID\u003e)\n```\n\n###### marketID can be \"btc-clp\", \"btc-cop\" etc\n\n```json\n{\n   \"market\":{\n      \"id\":\"BTC-CLP\",\n      \"name\":\"btc-clp\",\n      \"base_currency\":\"BTC\",\n      \"quote_currency\":\"CLP\",\n      \"minimum_order_amount\":[\n         \"0.0001\",\n         \"BTC\"\n      ]\n   }\n}\n```\n\n\n### Get Markets\nGetMarkets Returns info about all markets\n```GO\nbuda.GetMarkets()\n ```\n\n ```json\n {\n    \"markets\":[\n       {\n          \"id\":\"BTC-CLP\",\n          \"name\":\"btc-clp\",\n          \"base_currency\":\"BTC\",\n          \"quote_currency\":\"CLP\",\n          \"minimum_order_amount\":[\n             \"0.0001\",\n             \"BTC\"\n          ]\n       },\n       {\n          \"id\":\"BCH-PEN\",\n          \"name\":\"bch-pen\",\n          \"base_currency\":\"BCH\",\n          \"quote_currency\":\"PEN\",\n          \"minimum_order_amount\":[\n             \"0.0001\",\n             \"BCH\"\n          ]\n       }\n    ]\n }\n ```\n\n### Get Order Book\nGetOrderBook is used to get current state of the market. It shows the best offers (bid, ask) and the price from the last transaction, daily volume and the price in the last 24 hours\n```GO\nbuda.GetOrderBook(\"btc-clp\")\n```\n\n```json\n{\n \"order_book\":{\n    \"asks\":[\n       [\n          \"7299998.0\",\n          \"0.0374176\"\n         ],\n       [\n          \"7299999.0\",\n          \"0.07844341\"\n        ]\n      ],\n    \"bids\":[\n       [\n          \"7217231.0\",\n          \"0.02699449\"\n       ],\n       [\n          \"7183000.0\",\n          \"0.28\"\n       ],\n       [\n          \"7181619.0\",\n          \"0.0688\"\n       ]\n    ]\n }\n}\n\n```\n### Get Trades\nGetTrades returns a list of recent trades in a specific market\n\n```Go\nbuda.GetTrades(\"btc-clp\")\n```\n```json\n{  \n  \"trades\":{  \n       \"market_id\":\"BTC-CLP\",\n       \"timestamp\":null,\n       \"last_timestamp\":\"1517177157715\",\n       \"entries\":[\n       [  \n          \"1517188555937\",\n          \"0.00300551\",\n          \"7217231.0\",\n          \"sell\",\n          316863\n        ],\n        [  \n          \"1517186567638\",\n          \"0.00206959\",\n          \"7300000.0\",\n          \"buy\",\n          316844\n        ]\n      ]\n    }\n}\n```\n\n## Private Calls\n#### NEEDS AN APIKEY/APISECRET\n\n### Get Balances/Balances\n  - GetBalances gets the wallet balances in all cryptocurrencies and fiat currencies\n  - GetBalance(currency) gets the wallet balance in a specific cryptocurrency or fiat currency\n\n\n```GO\nbuda.GetBalances()\n```\n```json\n{\n   \"balances\":[\n      {\n         \"id\":\"BTC\",\n         \"amount\":[\n            \"0.0000001\",\n            \"BTC\"\n         ],\n         \"available_amount\":[\n            \"0.0000001\",\n            \"BTC\"\n         ],\n         \"frozen_amount\":[\n            \"0.0\",\n            \"BTC\"\n         ],\n         \"pending_withdraw_amount\":[\n            \"0.0\",\n            \"BTC\"\n         ],\n         \"account_id\":1234567\n      },\n      {\n         \"id\":\"COP\",\n         \"amount\":[\n            \"1000.33\",\n            \"COP\"\n         ],\n         \"available_amount\":[\n            \"1000.33\",\n            \"COP\"\n         ],\n         \"frozen_amount\":[\n            \"0.0\",\n            \"COP\"\n         ],\n         \"pending_withdraw_amount\":[\n            \"0.0\",\n            \"COP\"\n         ],\n         \"account_id\":1234567\n      }\n   ]\n}\n```\n\n\n### Get info about all YOUR Orders\n##### Warning: GetOrderBook(A)  !=  GetOrders(A,B,C,D,E)\n\n- GetOrders gets your orders made in a specific market with a specific status or/and minimum amount\n\n\n```GO\nbuda.GetOrders(marketID, ordersPerPage, page, state, minimumExchanged)\n```\n\n##### Example:\n``` GO\nbuda.GetOrders(\"btc-cop\", 300, 1, \"pending\", float64(0))\n```\n\n```json\n{  \n   \"orders\":[  \n      {  \n         \"id\":123456,\n         \"market_id\":\"BTC-COP\",\n         \"account_id\":1234567,\n         \"type\":\"Bid\",\n         \"state\":\"pending\",\n         \"created_at\":\"2018-01-29T02:28:44.658Z\",\n         \"fee_currency\":\"BTC\",\n         \"price_type\":\"limit\",\n         \"limit\":[  \n            \"0.0\",\n            \"COP\"\n         ],\n         \"amount\":[  \n            \"0.0001\",\n            \"BTC\"\n         ],\n         \"original_amount\":[  \n            \"0.0001\",\n            \"BTC\"\n         ],\n         \"traded_amount\":[  \n            \"0.0\",\n            \"BTC\"\n         ],\n         \"total_exchanged\":[  \n            \"0.0\",\n            \"COP\"\n         ],\n         \"paid_fee\":[  \n            \"0.0\",\n            \"BTC\"\n         ]\n      }\n   ],\n   \"meta\":{  \n      \"total_pages\":1,\n      \"total_count\":1,\n      \"current_page\":1\n   }\n}\n```\n\n### Create a new order\n#### Warning: Be sure to understand this method: http://api.buda.com/#nueva-orden\n\n#### PostOrder creates a new order (bid or ask) in a specific market\n\n IMPORTANT: You can either crete a Limit of Market order specifying it on the _priceType_ parameter as \"limit\" or \"market\". Therefore, the parameter _limit_ is only read in the first case but it is necessary to make the call. In order to post a Market order, submit the limit as float(0) or float().\n\n```GO\nbuda.PostOrder(marketID string, orderType string, priceType string, limit float64, amount float64)\n```\n##### At the moment, only \"limit\" is available for priceType\n##### Example:\n``` GO\nbuda.PostOrder(\"btc-cop\", \"bid\", \"limit\", float64(0.00001), float64(0.0001)))\n```\n\n```json\n{\n   \"order\":{\n      \"id\":1234567,\n      \"market_id\":\"BTC-COP\",\n      \"account_id\":1234567,\n      \"type\":\"Bid\",\n      \"state\":\"received\",\n      \"created_at\":\"2018-01-29T02:28:44.658Z\",\n      \"fee_currency\":\"BTC\",\n      \"price_type\":\"limit\",\n      \"limit\":[\n         \"0.0\",\n         \"COP\"\n      ],\n      \"amount\":[\n         \"0.0001\",\n         \"BTC\"\n      ],\n      \"original_amount\":[\n         \"0.0001\",\n         \"BTC\"\n      ],\n      \"traded_amount\":[\n         \"0.0\",\n         \"BTC\"\n      ],\n      \"total_exchanged\":[\n         \"0.0\",\n         \"COP\"\n      ],\n      \"paid_fee\":[\n         \"0.0\",\n         \"BTC\"\n      ]\n   }\n}\n```\n\n\n### Cancel an order\n#### CancelOrder cancels a specified order\n\n```GO\nbuda.CancelOrder(orderID string)\n```\n#### CancelOrder cancels a specified order\n```json\n{  \n   \"order\":{  \n      \"id\":1234567,\n      \"market_id\":\"BTC-COP\",\n      \"account_id\":1234567,\n      \"type\":\"Bid\",\n      \"state\":\"canceled\",\n      \"created_at\":\"2018-01-29T02:28:44.658Z\",\n      \"fee_currency\":\"BTC\",\n      \"price_type\":\"limit\",\n      \"limit\":[  \n         \"0.0\",\n         \"COP\"\n      ],\n      \"amount\":[  \n         \"0.0001\",\n         \"BTC\"\n      ],\n      \"original_amount\":[  \n         \"0.0001\",\n         \"BTC\"\n      ],\n      \"traded_amount\":[  \n         \"0.0\",\n         \"BTC\"\n      ],\n      \"total_exchanged\":[  \n         \"0.0\",\n         \"COP\"\n      ],\n      \"paid_fee\":[  \n         \"0.0\",\n         \"BTC\"\n      ]\n   }\n}\n```\n\n\n### Get info about a specific order\n####GetOrder returns the current state of a specific order\n\n```GO\nbuda.GetOrder(orderID string)\n```\n\n```json\n{  \n   \"order\":{  \n      \"id\":1234567,\n      \"market_id\":\"BTC-COP\",\n      \"account_id\":1234567,\n      \"type\":\"Bid\",\n      \"state\":\"received\",\n      \"created_at\":\"2018-01-29T02:38:37.178Z\",\n      \"fee_currency\":\"BTC\",\n      \"price_type\":\"limit\",\n      \"limit\":[  \n         \"0.0\",\n         \"COP\"\n      ],\n      \"amount\":[  \n         \"0.0001\",\n         \"BTC\"\n      ],\n      \"original_amount\":[  \n         \"0.0001\",\n         \"BTC\"\n      ],\n      \"traded_amount\":[  \n         \"0.0\",\n         \"BTC\"\n      ],\n      \"total_exchanged\":[  \n         \"0.0\",\n         \"COP\"\n      ],\n      \"paid_fee\":[  \n         \"0.0\",\n         \"BTC\"\n      ]\n   }\n}\n```\n\n\n### Get historic deposits in a specific fiat currency\n\n```GO\nbuda.GetDepositHistory(currency string)\n```\n\n```json\n{  \n   \"deposits\":[  \n      {  \n         \"id\":1234567,\n         \"state\":\"confirmed\",\n         \"currency\":\"COP\",\n         \"created_at\":\"2018-01-26T03:01:34.791Z\",\n         \"deposit_data\":{  \n            \"type\":\"fiat_deposit_data\",\n            \"created_at\":\"2018-01-26T03:01:34.783Z\",\n            \"updated_at\":\"2018-01-26T03:01:34.783Z\",\n            \"upload_url\":null\n         },\n         \"amount\":[  \n            \"10000.0\",\n            \"COP\"\n         ],\n         \"fee\":[  \n            \"431.0\",\n            \"COP\"\n         ]\n      },\n      {  \n         \"id\":1234567,\n         \"state\":\"confirmed\",\n         \"currency\":\"COP\",\n         \"created_at\":\"2018-01-22T17:06:14.473Z\",\n         \"deposit_data\":{  \n            \"type\":\"fiat_deposit_data\",\n            \"created_at\":\"2018-01-22T17:06:14.465Z\",\n            \"updated_at\":\"2018-01-22T17:06:14.465Z\",\n            \"upload_url\":null\n         },\n         \"amount\":[  \n            \"1000.0\",\n            \"COP\"\n         ],\n         \"fee\":[  \n            \"431.0\",\n            \"COP\"\n         ]\n      }\n   ],\n   \"meta\":{  \n      \"total_pages\":1,\n      \"total_count\":2,\n      \"current_page\":1\n   }\n}\n```\n\n\n\n### Get historic withdrawals in a specific fiat currency\n\n```GO\nbuda.GetWithdrawHistory(currency string)\n```\n\n```json\n{  \n   \"withdrawals\":[  \n      {  \n         \"id\":1234567,\n         \"state\":\"pending_op_execution\",\n         \"currency\":\"COP\",\n         \"created_at\":\"2018-01-29T02:55:04.056Z\",\n         \"withdrawal_data\":{  \n            \"type\":\"fiat/withdrawal_data\",\n            \"id\":1234567,\n            \"created_at\":\"2018-01-29T02:55:04.048Z\",\n            \"updated_at\":\"2018-01-29T02:55:04.048Z\",\n            \"transacted_at\":null,\n            \"statement_ref\":null,\n            \"fiat_account\":{  \n               \"id\":1234567,\n               \"account_number\":\"000000000\",\n               \"account_type\":\"Account description\",\n               \"bank_id\":99,\n               \"created_at\":\"2018-01-22T16:57:32.949Z\",\n               \"currency\":\"COP\",\n               \"document_number\":\"000000000\",\n               \"email\":\"email@email.com\",\n               \"full_name\":\"Your name\",\n               \"national_number_identifier\":null,\n               \"phone\":\"+000000000000\",\n               \"updated_at\":\"2018-01-22T16:57:32.949Z\",\n               \"bank_name\":\"BankName\",\n               \"pe_cci_number\":null\n            },\n            \"source_account\":null\n         },\n         \"amount\":[  \n            \"9000.0\",\n            \"COP\"\n         ],\n         \"fee\":[  \n            \"0.0\",\n            \"COP\"\n         ]\n      }\n   ],\n   \"meta\":{  \n      \"total_pages\":1,\n      \"total_count\":1,\n      \"current_page\":1\n   }\n}\n```\n\n\n##### CONTRIBUTION ⚠️\n\nFEEL FREE TO OPEN AN ISSUE / PULL REQUEST IF YOU FIND BUGS OR IF YOU WANT TO INCLUDE NEW FEATURES.\nIf your pull request doesn't break any old code I will happily merge it.\n\nThis client works with v2 of the Buda API.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Figomez10%2Ftulip","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Figomez10%2Ftulip","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Figomez10%2Ftulip/lists"}