Payload
{
"action": "created",
"issue": {
"url": "https://api.github.com/repos/darkmatter/nixmac/issues/110",
"repository_url": "https://api.github.com/repos/darkmatter/nixmac",
"labels_url": "https://api.github.com/repos/darkmatter/nixmac/issues/110/labels{/name}",
"comments_url": "https://api.github.com/repos/darkmatter/nixmac/issues/110/comments",
"events_url": "https://api.github.com/repos/darkmatter/nixmac/issues/110/events",
"html_url": "https://github.com/darkmatter/nixmac/issues/110",
"id": 4402636248,
"node_id": "I_kwDOSB6EzM8AAAABBmrl2A",
"number": 110,
"title": "Native app hosted usage routing and credit-pack account flow",
"user": {
"login": "linear-code[bot]",
"id": 222613912,
"node_id": "BOT_kgDODUTRmA",
"avatar_url": "https://avatars.githubusercontent.com/in/1658531?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/linear-code%5Bbot%5D",
"html_url": "https://github.com/apps/linear-code",
"followers_url": "https://api.github.com/users/linear-code%5Bbot%5D/followers",
"following_url": "https://api.github.com/users/linear-code%5Bbot%5D/following{/other_user}",
"gists_url": "https://api.github.com/users/linear-code%5Bbot%5D/gists{/gist_id}",
"starred_url": "https://api.github.com/users/linear-code%5Bbot%5D/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/linear-code%5Bbot%5D/subscriptions",
"organizations_url": "https://api.github.com/users/linear-code%5Bbot%5D/orgs",
"repos_url": "https://api.github.com/users/linear-code%5Bbot%5D/repos",
"events_url": "https://api.github.com/users/linear-code%5Bbot%5D/events{/privacy}",
"received_events_url": "https://api.github.com/users/linear-code%5Bbot%5D/received_events",
"type": "Bot",
"user_view_type": "public",
"site_admin": false
},
"labels": [
{
"id": 10893040504,
"node_id": "LA_kwDOSB6EzM8AAAACiUabeA",
"url": "https://api.github.com/repos/darkmatter/nixmac/labels/Feature",
"name": "Feature",
"color": "ededed",
"default": false,
"description": null
}
],
"state": "open",
"locked": false,
"assignees": [],
"milestone": null,
"comments": 1,
"created_at": "2026-05-07T23:34:03Z",
"updated_at": "2026-06-03T16:24:46Z",
"closed_at": null,
"assignee": null,
"author_association": "NONE",
"issue_field_values": [],
"type": null,
"active_lock_reason": null,
"sub_issues_summary": {
"total": 0,
"completed": 0,
"percent_completed": 0
},
"parent_issue_url": "https://api.github.com/repos/darkmatter/nixmac/issues/100",
"issue_dependencies_summary": {
"blocked_by": 0,
"total_blocked_by": 0,
"blocking": 0,
"total_blocking": 0
},
"body": "## Context\n\nnixmac-web already appears to have real payment/credit plumbing: Polar checkout/webhooks and LiteLLM virtual-key generation/top-up. The missing monetization work is productizing that into the native app and cleaning up stale web checkout paths, not inventing checkout from scratch.\n\nClaude review guidance incorporated:\n\n* Treat existing Polar/LiteLLM plumbing as prior art and integration surface.\n* Do not ship paid hosted usage until the B200/model reliability question, hosted accounting, centralized proxy, and payment copy/policy readiness are resolved.\n* Clean up stale dashboard checkout code that still references a generic/pro plan if it conflicts with credit-pack products.\n\n## Scope\n\n* Add native account/hosted-usage state needed to select hosted nixmac compute when available.\n* Route hosted LLM requests through the centralized proxy/LiteLLM virtual key path rather than exposing provider keys directly in the app.\n* Show credit balance/status and useful fallback states in the app.\n* Link users to credit-pack checkout and account/portal flows from the native app.\n* Preserve BYO provider and local workflows as alternatives when hosted usage is unavailable or out of credits.\n* Audit nixmac-web dashboard checkout/product slugs and align them with the actual credit-pack catalog.\n\n## Acceptance criteria\n\n* Native app can distinguish BYO/local usage from Dark Matter-hosted usage.\n* User can reach checkout/account portal from the app when hosted usage needs credits.\n* Hosted calls use the centralized proxy/accounting path.\n* No/low credits, payment failure, hosted disabled, and BYO fallback states are handled clearly.\n* Existing nixmac-web Polar/LiteLLM credit-pack plumbing is reused or explicitly replaced with rationale.\n* Stale checkout/product slug paths are fixed before relying on the web dashboard for credit purchase.\n\n## Blocked by\n\n* ENG-420 centralized LLM proxy/provider consistency.\n* ENG-461 payment copy and policy readiness.\n* ENG-463 B200/gpt-oss-120b benchmark recommendation.\n* ENG-464 hosted usage credit accounting.",
"reactions": {
"url": "https://api.github.com/repos/darkmatter/nixmac/issues/110/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
},
"timeline_url": "https://api.github.com/repos/darkmatter/nixmac/issues/110/timeline",
"performed_via_github_app": null,
"state_reason": null,
"pinned_comment": null
},
"comment": {
"url": "https://api.github.com/repos/darkmatter/nixmac/issues/comments/4614541480",
"html_url": "https://github.com/darkmatter/nixmac/issues/110#issuecomment-4614541480",
"issue_url": "https://api.github.com/repos/darkmatter/nixmac/issues/110",
"id": 4614541480,
"node_id": "IC_kwDOSB6EzM8AAAABEwxQqA",
"user": {
"login": "evidai",
"id": 203315731,
"node_id": "U_kgDODB5aEw",
"avatar_url": "https://avatars.githubusercontent.com/u/203315731?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/evidai",
"html_url": "https://github.com/evidai",
"followers_url": "https://api.github.com/users/evidai/followers",
"following_url": "https://api.github.com/users/evidai/following{/other_user}",
"gists_url": "https://api.github.com/users/evidai/gists{/gist_id}",
"starred_url": "https://api.github.com/users/evidai/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/evidai/subscriptions",
"organizations_url": "https://api.github.com/users/evidai/orgs",
"repos_url": "https://api.github.com/users/evidai/repos",
"events_url": "https://api.github.com/users/evidai/events{/privacy}",
"received_events_url": "https://api.github.com/users/evidai/received_events",
"type": "User",
"user_view_type": "public",
"site_admin": false
},
"created_at": "2026-06-03T16:24:46Z",
"updated_at": "2026-06-03T16:24:46Z",
"body": "Sharing a data point for the monetization/payment-rail question — feel free to ignore if not useful.\n\nWe've been shipping **LemonCake** (https://lemoncake.xyz) as an **x402-native gateway** specifically for AI agents:\n\n- Your endpoint returns `402 + accepts[]` when budget/auth is missing\n- The agent presents a hard-capped Buyer Key (`bk_…`), mints a Pay Token (JWT), passes through with Bearer\n- Caps enforced server-side: per-mint / daily / monthly. Cannot exceed.\n- 0% fee for the first 3,000 calls, 3% after\n- Custody-free — we never hold funds (FSA-cleared design)\n- Production: $1 off-session card charge verified on 2026-06-02\n\nIf you're evaluating x402 / AgentaOS / pay-per-call options, this might be useful as a comparison point. The 30-second demo (no signup) walks the full flow: https://lemoncake.xyz/demo\n\n(Disclosure: I'm working on LemonCake. Just adding a data point, not pushing a takeover.)\n",
"author_association": "NONE",
"pin": null,
"reactions": {
"url": "https://api.github.com/repos/darkmatter/nixmac/issues/comments/4614541480/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
},
"performed_via_github_app": null
},
"repository": {
"id": 1209959628,
"node_id": "R_kgDOSB6EzA",
"name": "nixmac",
"full_name": "darkmatter/nixmac",
"private": false,
"owner": {
"login": "darkmatter",
"id": 17834193,
"node_id": "MDEyOk9yZ2FuaXphdGlvbjE3ODM0MTkz",
"avatar_url": "https://avatars.githubusercontent.com/u/17834193?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/darkmatter",
"html_url": "https://github.com/darkmatter",
"followers_url": "https://api.github.com/users/darkmatter/followers",
"following_url": "https://api.github.com/users/darkmatter/following{/other_user}",
"gists_url": "https://api.github.com/users/darkmatter/gists{/gist_id}",
"starred_url": "https://api.github.com/users/darkmatter/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/darkmatter/subscriptions",
"organizations_url": "https://api.github.com/users/darkmatter/orgs",
"repos_url": "https://api.github.com/users/darkmatter/repos",
"events_url": "https://api.github.com/users/darkmatter/events{/privacy}",
"received_events_url": "https://api.github.com/users/darkmatter/received_events",
"type": "Organization",
"user_view_type": "public",
"site_admin": false
},
"html_url": "https://github.com/darkmatter/nixmac",
"description": "Home manager and nix-darwin that understands plain English",
"fork": false,
"url": "https://api.github.com/repos/darkmatter/nixmac",
"forks_url": "https://api.github.com/repos/darkmatter/nixmac/forks",
"keys_url": "https://api.github.com/repos/darkmatter/nixmac/keys{/key_id}",
"collaborators_url": "https://api.github.com/repos/darkmatter/nixmac/collaborators{/collaborator}",
"teams_url": "https://api.github.com/repos/darkmatter/nixmac/teams",
"hooks_url": "https://api.github.com/repos/darkmatter/nixmac/hooks",
"issue_events_url": "https://api.github.com/repos/darkmatter/nixmac/issues/events{/number}",
"events_url": "https://api.github.com/repos/darkmatter/nixmac/events",
"assignees_url": "https://api.github.com/repos/darkmatter/nixmac/assignees{/user}",
"branches_url": "https://api.github.com/repos/darkmatter/nixmac/branches{/branch}",
"tags_url": "https://api.github.com/repos/darkmatter/nixmac/tags",
"blobs_url": "https://api.github.com/repos/darkmatter/nixmac/git/blobs{/sha}",
"git_tags_url": "https://api.github.com/repos/darkmatter/nixmac/git/tags{/sha}",
"git_refs_url": "https://api.github.com/repos/darkmatter/nixmac/git/refs{/sha}",
"trees_url": "https://api.github.com/repos/darkmatter/nixmac/git/trees{/sha}",
"statuses_url": "https://api.github.com/repos/darkmatter/nixmac/statuses/{sha}",
"languages_url": "https://api.github.com/repos/darkmatter/nixmac/languages",
"stargazers_url": "https://api.github.com/repos/darkmatter/nixmac/stargazers",
"contributors_url": "https://api.github.com/repos/darkmatter/nixmac/contributors",
"subscribers_url": "https://api.github.com/repos/darkmatter/nixmac/subscribers",
"subscription_url": "https://api.github.com/repos/darkmatter/nixmac/subscription",
"commits_url": "https://api.github.com/repos/darkmatter/nixmac/commits{/sha}",
"git_commits_url": "https://api.github.com/repos/darkmatter/nixmac/git/commits{/sha}",
"comments_url": "https://api.github.com/repos/darkmatter/nixmac/comments{/number}",
"issue_comment_url": "https://api.github.com/repos/darkmatter/nixmac/issues/comments{/number}",
"contents_url": "https://api.github.com/repos/darkmatter/nixmac/contents/{+path}",
"compare_url": "https://api.github.com/repos/darkmatter/nixmac/compare/{base}...{head}",
"merges_url": "https://api.github.com/repos/darkmatter/nixmac/merges",
"archive_url": "https://api.github.com/repos/darkmatter/nixmac/{archive_format}{/ref}",
"downloads_url": "https://api.github.com/repos/darkmatter/nixmac/downloads",
"issues_url": "https://api.github.com/repos/darkmatter/nixmac/issues{/number}",
"pulls_url": "https://api.github.com/repos/darkmatter/nixmac/pulls{/number}",
"milestones_url": "https://api.github.com/repos/darkmatter/nixmac/milestones{/number}",
"notifications_url": "https://api.github.com/repos/darkmatter/nixmac/notifications{?since,all,participating}",
"labels_url": "https://api.github.com/repos/darkmatter/nixmac/labels{/name}",
"releases_url": "https://api.github.com/repos/darkmatter/nixmac/releases{/id}",
"deployments_url": "https://api.github.com/repos/darkmatter/nixmac/deployments",
"created_at": "2026-04-14T00:37:13Z",
"updated_at": "2026-06-03T12:43:14Z",
"pushed_at": "2026-06-03T13:03:28Z",
"git_url": "git://github.com/darkmatter/nixmac.git",
"ssh_url": "git@github.com:darkmatter/nixmac.git",
"clone_url": "https://github.com/darkmatter/nixmac.git",
"svn_url": "https://github.com/darkmatter/nixmac",
"homepage": "https://nixmac.com",
"size": 679069,
"stargazers_count": 5,
"watchers_count": 5,
"language": "Rust",
"has_issues": true,
"has_projects": true,
"has_downloads": true,
"has_wiki": true,
"has_pages": false,
"has_discussions": false,
"forks_count": 1,
"mirror_url": null,
"archived": false,
"disabled": false,
"open_issues_count": 68,
"license": {
"key": "mit",
"name": "MIT License",
"spdx_id": "MIT",
"url": "https://api.github.com/licenses/mit",
"node_id": "MDc6TGljZW5zZTEz"
},
"allow_forking": true,
"is_template": false,
"web_commit_signoff_required": false,
"has_pull_requests": true,
"pull_request_creation_policy": "all",
"topics": [
"home-manager",
"nix",
"nix-darwin",
"nix-flake",
"opencode"
],
"visibility": "public",
"forks": 1,
"open_issues": 68,
"watchers": 5,
"default_branch": "develop",
"custom_properties": {}
},
"organization": {
"login": "darkmatter",
"id": 17834193,
"node_id": "MDEyOk9yZ2FuaXphdGlvbjE3ODM0MTkz",
"url": "https://api.github.com/orgs/darkmatter",
"repos_url": "https://api.github.com/orgs/darkmatter/repos",
"events_url": "https://api.github.com/orgs/darkmatter/events",
"hooks_url": "https://api.github.com/orgs/darkmatter/hooks",
"issues_url": "https://api.github.com/orgs/darkmatter/issues",
"members_url": "https://api.github.com/orgs/darkmatter/members{/member}",
"public_members_url": "https://api.github.com/orgs/darkmatter/public_members{/member}",
"avatar_url": "https://avatars.githubusercontent.com/u/17834193?v=4",
"description": ""
},
"enterprise": {
"id": 469843,
"slug": "darkmatter",
"name": "darkmatter",
"node_id": "E_kgDOAAcrUw",
"avatar_url": "https://avatars.githubusercontent.com/b/469843?v=4",
"description": "",
"website_url": "darkmatter.io",
"html_url": "https://github.com/enterprises/darkmatter",
"created_at": "2025-09-07T16:01:00Z",
"updated_at": "2026-05-09T15:34:55Z"
},
"sender": {
"login": "evidai",
"id": 203315731,
"node_id": "U_kgDODB5aEw",
"avatar_url": "https://avatars.githubusercontent.com/u/203315731?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/evidai",
"html_url": "https://github.com/evidai",
"followers_url": "https://api.github.com/users/evidai/followers",
"following_url": "https://api.github.com/users/evidai/following{/other_user}",
"gists_url": "https://api.github.com/users/evidai/gists{/gist_id}",
"starred_url": "https://api.github.com/users/evidai/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/evidai/subscriptions",
"organizations_url": "https://api.github.com/users/evidai/orgs",
"repos_url": "https://api.github.com/users/evidai/repos",
"events_url": "https://api.github.com/users/evidai/events{/privacy}",
"received_events_url": "https://api.github.com/users/evidai/received_events",
"type": "User",
"user_view_type": "public",
"site_admin": false
},
"installation": {
"id": 131074261,
"node_id": "MDIzOkludGVncmF0aW9uSW5zdGFsbGF0aW9uMTMxMDc0MjYx"
}
}