{"id":13816573,"url":"https://github.com/Milerius/mm2-client","last_synced_at":"2025-05-15T15:32:45.122Z","repository":{"id":45063134,"uuid":"381934028","full_name":"Milerius/mm2-client","owner":"Milerius","description":"my own mm2 client / tooling","archived":false,"fork":false,"pushed_at":"2025-05-07T12:03:10.000Z","size":3528,"stargazers_count":9,"open_issues_count":13,"forks_count":12,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-10T07:48:42.705Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Milerius.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,"zenodo":null}},"created_at":"2021-07-01T06:35:53.000Z","updated_at":"2024-12-17T00:18:07.000Z","dependencies_parsed_at":"2024-01-04T14:38:02.666Z","dependency_job_id":"51a2a30b-1bb4-40a7-a8c6-e56bf3fb804b","html_url":"https://github.com/Milerius/mm2-client","commit_stats":{"total_commits":433,"total_committers":4,"mean_commits":108.25,"dds":0.04157043879907618,"last_synced_commit":"b703e7d14541095a378769e3df1b453a16e5100e"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Milerius%2Fmm2-client","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Milerius%2Fmm2-client/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Milerius%2Fmm2-client/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Milerius%2Fmm2-client/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Milerius","download_url":"https://codeload.github.com/Milerius/mm2-client/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254367706,"owners_count":22059557,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":[],"created_at":"2024-08-04T05:00:46.136Z","updated_at":"2025-05-15T15:32:44.441Z","avatar_url":"https://github.com/Milerius.png","language":"Go","funding_links":[],"categories":["Applications"],"sub_categories":["Terminal"],"readme":"# mm2-client\nmy own mm2 client / tooling\n\nFuture tasks:\n\n- [ ] Wallet + encryption seed\n- [ ] cancel_all_order\n- [x] setprice\n- [ ] buy\n- [ ] sell  \n- [x] my_recent_swaps\n- [x] my_orders\n- [x] prompt use DB desktop\n- [x] cancel (if i want to cancel by UUID)\n- [x] update_maker_order (want to track UUID)\n- [x] gecko price service\n- [x] paprika price service\n- [x] binance websocket service\n- [x] add total in my_balance_all\n- [x] add am_i_seed in MM2.json if user wants it  \n- [x] get_binance_supported_pairs\n- [x] add a way to start mm2 without extra services\n- [x] generic price service that use in order (binance, gecko, paprika)\n- [x] simple bot cfg\n\n## How to use the trading bot on linux:\n\n```\nwget https://golang.org/dl/go1.16.5.linux-amd64.tar.gz\nsudo rm -rf /usr/local/go \u0026\u0026 sudo tar -C /usr/local -xzf go1.16.5.linux-amd64.tar.gz\nexport PATH=$PATH:/usr/local/go/bin\ngit clone https://github.com/Milerius/mm2-client\ncd mm2-client \u0026\u0026 go build cmd/mm2_cli_native/mm2_client.go\nmkdir -p mm2\ncp assets/simple_market_bot.template.json mm2/simple_market_bot.json\n# edit the cfg if you want and remove the commentary\n./mm2_client\n\n\u003e help\n\u003e init # you need to do only the first time\n\u003e start\n\u003e enable_active_coins\n\u003e enable COIN_FROM_CFG COIN_2_FROM_CFG # use that if they are not enable yet - you can use active coins next run\n\u003e get_binance_supported_pairs COIN_FROM_CFG # you can see if your coin is supported\n\n# Be sure your balance is funded before starting the bot\n\u003e start_simple_market_maker_bot\n\n\u003e my_orders\n\n# later\n\u003e stop_simple_market_maker_bot\n\u003e stop\n\u003e exit\n\n## from another terminal\ntail -f ~/.atomicdex_cli/logs/mm2.client.log\n```\n\n### How to use the simple market maker bot with an existing atomicdex instance\n\n```\ngo build -o mm2_tools_server_bin cmd/mm2_tools_server/mm2_tools_server.go\n./mm2_tools_server_bin\n\n# Assuming your userpass for the session is foobar\n# Starting the simple market maker bot\ncurl --location --request POST 'localhost:1313/api/v1/start_simple_market_maker_bot' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{\n  \"desktop_cfg_path\": \"/Users/milerius/Library/Application Support/AtomicDex Desktop/config/0.5.0-coins.Roman.json\",\n  \"mm2_coins_cfg_path\": \"/Users/milerius/Library/Application Support/AtomicDex Desktop/0.5.0/configs/coins.json\",\n  \"market_maker_cfg_path\": \"/Users/milerius/GolandProjects/mm2-client/mm2/simple_market_bot.json\",\n  \"mm2_userpass\": \"foobar\"\n}'\n\n# stopping the bot\ncurl --location --request POST 'localhost:1313/api/v1/stop_simple_market_maker_bot'\n```\n\n### How to use the server on Ios\n\n#### building\n\n```\ncd mm2_tools_server\ngomobile bind -v --target=ios .\n```\n\n#### using in an ios project:\n```obj-c\n//\n//  main.m\n//  FooBar\n//\n//  Created by Sztergbaum Roman on 15/07/2021.\n//\n\n#import \u003cUIKit/UIKit.h\u003e\n#import \"AppDelegate.h\"\n#import \"Mm2_tools_server.h\"\n\nint main(int argc, char * argv[]) {\n    NSString * appDelegateClassName;\n    @autoreleasepool {\n        // Setup code that might create autoreleased objects goes here.\n        appDelegateClassName = NSStringFromClass([AppDelegate class]);\n    }\n    dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), ^{\n        Mm2_tools_serverLaunchServer(@\"atomic_dex\");\n\n    });\n\n    return UIApplicationMain(argc, argv, nil, appDelegateClassName);\n}\n```\n\n### using in an android project:\n\n#### building\n\n```\ncd mm2_tools_server\ngomobile bind -v --target=android .\n```\n\n#### Using in an android-studio (kotlin) project:\n\n```kt\nimport mm2_tools_server.Mm2_tools_server\nimport kotlin.concurrent.thread\n\nclass MainActivity : AppCompatActivity() {\n\n    private lateinit var binding: ActivityMainBinding\n\n    override fun onCreate(savedInstanceState: Bundle?) {\n        super.onCreate(savedInstanceState)\n\n        binding = ActivityMainBinding.inflate(layoutInflater)\n        setContentView(binding.root)\n\n        val navView: BottomNavigationView = binding.navView\n\n        val navController = findNavController(R.id.nav_host_fragment_activity_main)\n        // Passing each menu ID as a set of Ids because each\n        // menu should be considered as top level destinations.\n        val appBarConfiguration = AppBarConfiguration(\n            setOf(\n                R.id.navigation_home, R.id.navigation_dashboard, R.id.navigation_notifications\n            )\n        )\n\n        thread {\n            Mm2_tools_server.launchServer(\"atomicDex\")\n        }\n        //print(\"hello world\\n\")\n        setupActionBarWithNavController(navController, appBarConfiguration)\n        navView.setupWithNavController(navController)\n    }\n}\n```\n\n#### miscs\n```\n#you may want for testing purpose to forward localhost port of the server\n# for android simulator devices please start the emulator and run then start your app\nadb forward tcp:1313 tcp:1313\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FMilerius%2Fmm2-client","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FMilerius%2Fmm2-client","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FMilerius%2Fmm2-client/lists"}