code wiki / _hdl_build / nx_apistack_problem.nx

nx_apistack_problem.nx

buildroot/runtime/_hdl_build/nx_apistack_problem.nx

1799 B38 linesdepth 2pulls 2 transitivereach 1 importersview sourcekind librarytopic apistack
docsdependenciesstructsconstsfunctions

about

nx_apistack_problem.nx -- CAP-API-PROBLEM: RFC 7807 / RFC 9457 error contract (application/problem+json) for /api. Replaces ad-hoc {"error":..} with a stable machine-readable shape {type,title,status,detail} + stable type URIs, so clients can branch on `type` deterministically. Pure serializer (byte-reproducible), JSON-escaped. license_tier: ORIGINAL

dependencies 1 imports · 1 importers

nx_syscalls.nx nx_apistack_problem.nx nx_apistack_problem_gate.nx

imports: nx_syscalls.nx

imported by: nx_apistack_problem_gate.nx

structs

none

consts

none

functions

6func pr_cat(buf: *u8, off: i64, s: *u8) -> i64 { var i: i64=0; while s[i]!=(0 as u8){buf[off+i]=s[i];i=i+1} return off+i }
called by 1: pr_build_json
7func pr_catn(buf: *u8, off: i64, v: i64) -> i64
called by 1: pr_build_json calls 1: sys_mmap
15func pr_cat_esc(buf: *u8, off: i64, s: *u8) -> i64
called by 1: pr_build_json
27func pr_build_json(out: *u8, type_uri: *u8, title: *u8, status: i64, detail: *u8) -> i64
called by 1: main calls 3: pr_catpr_cat_escpr_catn