code wiki / (root) / nx_ghfetch.nx

nx_ghfetch.nx

buildroot/runtime/nx_ghfetch.nx

3916 B97 linesdepth 20pulls 128 transitivereach 0 importersview sourcekind tool
docsdependenciesstructsconstsfunctions

about

nx_ghfetch.nx -- sovereign GitHub API fetch WITH auth. LangIntel oracle throughput lever: unlocks the authed 5000/hr ceiling (vs 60/hr anon) for full-scale closed-bug + fix-diff answer-key capture. Reads a read-only-public PAT from knowledge/status/gh_oracle.dat, builds "Authorization: token <PAT>", fetches argv[1] (default /rate_limit) over OUR TLS via nx_https_fetch_hdr. NO curl, NO graphql, NO libc. Structured refusal (reason+fix) on every failure per feedback-refusals-carry-reason-and-fix. license_tier: ORIGINAL

dependencies 2 imports · 0 importers

nx_syscalls.nx nx_https_fetch.nx nx_ghfetch.nx

imports: nx_syscalls.nxnx_https_fetch.nx

imported by: nobody (leaf or entry point)

structs

none

consts

9const GHF_TOKFILE: *u8 = "knowledge/status/gh_oracle.dat" as *u8
10const GHF_OUTCAP: i64 = 4194304

functions

12func ghf_slen(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } return n }
called by 1: ghf_put
13func ghf_put(s: *u8) -> i64 { sys_write(1, s, ghf_slen(s)); return 0 }
14func ghf_putn(v: i64) -> i64
28func main(argc: i64, argv: *i64) -> i64