{"id":20001897,"url":"https://github.com/pooltogether/v4-cli","last_synced_at":"2025-10-17T13:18:41.571Z","repository":{"id":37791718,"uuid":"456615195","full_name":"pooltogether/v4-cli","owner":"pooltogether","description":"PoolTogether V4 Command Line Interface","archived":false,"fork":false,"pushed_at":"2023-04-27T16:37:53.000Z","size":290,"stargazers_count":6,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-04-20T12:41:27.505Z","etag":null,"topics":["cli","ethereum","pooltogether","web3"],"latest_commit_sha":null,"homepage":"https://github.com/pooltogether/v4-cli","language":"TypeScript","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/pooltogether.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":"2022-02-07T17:50:07.000Z","updated_at":"2023-04-27T03:44:54.000Z","dependencies_parsed_at":"2024-10-30T15:45:15.282Z","dependency_job_id":null,"html_url":"https://github.com/pooltogether/v4-cli","commit_stats":{"total_commits":43,"total_committers":4,"mean_commits":10.75,"dds":0.5348837209302326,"last_synced_commit":"a959edd5aff9945f09cb27025cdb362807c6350a"},"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pooltogether%2Fv4-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pooltogether%2Fv4-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pooltogether%2Fv4-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pooltogether%2Fv4-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pooltogether","download_url":"https://codeload.github.com/pooltogether/v4-cli/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251859959,"owners_count":21655648,"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":["cli","ethereum","pooltogether","web3"],"created_at":"2024-11-13T05:19:03.159Z","updated_at":"2025-10-17T13:18:41.501Z","avatar_url":"https://github.com/pooltogether.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/pooltogether/pooltogether--brand-assets\"\u003e\n    \u003cimg src=\"https://github.com/pooltogether/pooltogether--brand-assets/blob/977e03604c49c63314450b5d432fe57d34747c66/logo/pooltogether-logo--purple-gradient.png?raw=true\" alt=\"PoolTogether Brand\" style=\"max-width:100%;\" width=\"200\"\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n\u003cbr /\u003e\n\n\n# 📇 PoolTogether V4 CLI\n\n![CI](https://github.com/pooltogether/v4-cli/actions/workflows/main.yml/badge.svg)\n[![Version](https://img.shields.io/npm/v/@pooltogether/v4-cli.svg)](https://npmjs.org/package/@pooltogether/v4-cli)\n[![Downloads/week](https://img.shields.io/npm/dw/@pooltogether/v4-cli.svg)](https://npmjs.org/package/@pooltogether/v4-cli)\n[![License](https://img.shields.io/npm/l/@pooltogether/v4-cli.svg)](https://github.com/oclif/hello-world/blob/main/package.json)\n![ts](https://badgen.net/badge/-/TypeScript?icon=typescript\u0026label\u0026labelColor=blue\u0026color=555555)\n[![GPLv3 license](https://img.shields.io/badge/License-GPLv3-blue.svg)](http://perso.crans.org/besson/LICENSE.html)\n[![oclif](https://img.shields.io/badge/cli-oclif-brightgreen.svg)](https://oclif.io)\n\n\nThe `@pooltogether/v4-cli` [node module package](https://www.npmjs.com/package/@pooltogether/v4-cli) is a NODE command line interface (CLI) to interact with the **PoolTogether V4 protocol**. The CLI uses the `v4-client-js` and `v4-utils-js` modules to fetch and run calculations/computations for essential PoolTogether V4 tasks.\n\nPrimary CLI Commands (help)\n\n```sh\nnpx @pooltogether/v4-cli help compute drawPrizes\nnpx @pooltogether/v4-cli help compute poolPrizes\nnpx @pooltogether/v4-cli help compute networkPrizes\n```\n\n# ⌨️ CLI Installation\n\u003c!-- usage --\u003e\n```sh-session\n$ npm install -g @pooltogether/v4-cli\n$ ptv4 COMMAND\nrunning command...\n$ ptv4 (--version)\n@pooltogether/v4-cli/0.1.11-beta.1 darwin-arm64 node-v16.17.0\n$ ptv4 --help [COMMAND]\nUSAGE\n  $ ptv4 COMMAND\n...\n```\n\u003c!-- usagestop --\u003e\n# Commands\n\n## Compute Draw Prizes\n\n```sh-session\nptv4 compute drawPrizes\n```\n\nComputes single Draw prizes for a PrizePool to a target output directory.\n\nSimply pass a `chainId`, `ticket` `drawId` and `outDir` to compute and locally save the results.\n\n```\nUSAGE\n  $ ptv4 compute drawPrizes --chainId 1 --drawId 65 --outDir ./temp --ticket '0xdd4d117723C257CEe402285D3aCF218E9A8236E1'\n\nDESCRIPTION\n  Computes single Draw prizes for a PrizePool to a target output directory.\n\nEXAMPLES\n  $ ptv4 compute drawPrizes --chainId 1 --drawId 1 --ticket 0x0000000000000000000000000000000000000000 --outDir ./temp\n    Running compute:drawPrizes on chainId: 1 using drawID: 1\n```\n\n## Status File (status.json)\n\n```json\n{\n  \"status\": \"LOADING\",\n  \"createdAt\": \"11\"\n}\n```\n\n### Success\n\n```json\n{\n  \"status\": \"SUCCESS\",\n  \"createdAt\": \"11\",\n  \"updatedAt\": \"33\",\n  \"runtime\": \"22\",\n  \"meta\": {\n    \"prizeLength\": \"10\",\n    \"amountsTotal\": \"5000000\"\n  }\n}\n```\n\n### Failure\n\n```json\n{\n  \"status\": \"FAILURE\",\n  \"createdAt\": \"11\",\n  \"updatedAt\": \"33\",\n  \"runtime\": \"22\",\n  \"error\": \"ErrorCode\"\n}\n```\n\n\n## Compute PrizePool Prizes\n\nComputes all historical Draw prizes for a PrizePool to a target output directory.\n\n```sh-session\nptv4 compute poolPrizes\n```\n\n```\nUSAGE\n  $ ptv4 compute poolPrizes --chainId 1 --outDir ./temp --ticket '0xdd4d117723C257CEe402285D3aCF218E9A8236E1'\n\nDESCRIPTION\n  Computes all historical Draw prizes for a PrizePool to a target output directory.\n\nEXAMPLES\n  $ ptv4 compute poolPrizes --chainId 1--ticket 0x0000000000000000000000000000000000000000 --outDir ./temp\n    Running compute:drawPrizes on chainId: 1 using drawID: 1\n```\n\n## Compute Network of PrizePool Prizes\n\nComputes Draw prizes for all PoolTogether V4 network PrizePools to a target output directory.\n\n```sh-session\nptv4 compute networkPrizes\n```\n\n```\nUSAGE\n  $ ptv4 compute networkPrizes --outDir ./temp\n\nDESCRIPTION\n  Computes Draw prizes for all PoolTogether V4 network PrizePools to a target output directory.\n\nEXAMPLES\n  $ ptv4 compute poolPrizes --chainId 1 --ticket 0x0000000000000000000000000000000000000000 --outDir ./temp\n    Running compute:drawPrizes on chainId: 1 using drawID: 1\n```\n\n## Help\n\n```sh-session\nptv4 help [COMMAND]\n```\n\nDisplay help for ptv4.\n\n```\nUSAGE\n  $ ptv4 help [COMMAND] [-n]\n\nARGUMENTS\n  COMMAND  Command to show help for.\n\nFLAGS\n  -n, --nested-commands  Include all nested commands in the output.\n\nDESCRIPTION\n  Display help for ptv4.\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpooltogether%2Fv4-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpooltogether%2Fv4-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpooltogether%2Fv4-cli/lists"}