{"_id":"@ahmedrowaihi/openapi-core","_rev":"2-142cd539dab45f30c2c4e432abfa0baa","name":"@ahmedrowaihi/openapi-core","dist-tags":{"latest":"2.0.0"},"versions":{"2.0.0":{"name":"@ahmedrowaihi/openapi-core","version":"2.0.0","keywords":["openapi","codegen","sdk","shared"],"author":{"name":"Ahmed Rowaihi","email":"ahmedrowaihi@gmail.com"},"license":"MIT","_id":"@ahmedrowaihi/openapi-core@2.0.0","maintainers":[{"name":"ahmedrowaihi","email":"ahmedrowaihi1@gmail.com"}],"homepage":"https://github.com/ahmedrowaihi/contract-kit/tree/main/packages/openapi/core","bugs":{"url":"https://github.com/ahmedrowaihi/contract-kit/issues"},"dist":{"shasum":"a2a62067e44e3c45d54c943e2ab7827133b2899e","tarball":"https://registry.npmjs.org/@ahmedrowaihi/openapi-core/-/openapi-core-2.0.0.tgz","fileCount":51,"integrity":"sha512-j16J4FBZVuNlufIisiaR0ZViJUsSS6UYvMuXL/FLxwseXFFOY3iGG2/Ipn1ySAUlrwPYGhzsxKOW5scmdYeCcg==","signatures":[{"sig":"MEUCIASKxvNcVO3Ey+KjUNWb1RRYcmsiUo8Ve+ufo8mTBLtNAiEA/720iLKAeAIh6N8faJucrgcTChBAtQGXctXY2LI7Bx4=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@ahmedrowaihi%2fopenapi-core@2.0.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":68573},"main":"./dist/index.js","type":"module","_from":"file:ahmedrowaihi-openapi-core-2.0.0.tgz","types":"./dist/index.d.ts","engines":{"node":">=20.19.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./package.json":"./package.json"},"scripts":{"dev":"tsc -p tsconfig.build.json --watch","test":"vitest run","build":"tsc -p tsconfig.build.json","typecheck":"tsc --noEmit"},"_npmUser":{"name":"ahmedrowaihi","email":"ahmedrowaihi1@gmail.com"},"_resolved":"/tmp/be5cb642ea635d793685b881ce3dd7cc/ahmedrowaihi-openapi-core-2.0.0.tgz","_integrity":"sha512-j16J4FBZVuNlufIisiaR0ZViJUsSS6UYvMuXL/FLxwseXFFOY3iGG2/Ipn1ySAUlrwPYGhzsxKOW5scmdYeCcg==","repository":{"url":"git+https://github.com/ahmedrowaihi/contract-kit.git","type":"git","directory":"packages/openapi/core"},"_npmVersion":"10.8.2","description":"Shared building blocks for native-client SDK generators on top of OpenAPI 3.x — identifier transforms, security-scheme walkers, ref helpers, filesystem safety. Used by @ahmedrowaihi/openapi-go, @ahmedrowaihi/openapi-kotlin, @ahmedrowaihi/openapi-swift.","directories":{},"sideEffects":false,"_nodeVersion":"20.20.2","publishConfig":{"access":"public","provenance":true},"_hasShrinkwrap":false,"devDependencies":{"vitest":"^4.0.0","@types/node":"^22","@hey-api/shared":"^0.4.2","@ahmedrowaihi/tsconfig":"0.0.0"},"peerDependencies":{"@hey-api/shared":">=0.3.0"},"_npmOperationalInternal":{"tmp":"tmp/openapi-core_2.0.0_1777638932938_0.023795454915624514","host":"s3://npm-registry-packages-npm-production"},"deprecated":"Moved to @ir-kit/openapi-core. See https://github.com/ir-kit/ir-kit for migration."}},"time":{"created":"2026-05-01T12:35:32.824Z","modified":"2026-05-21T09:19:01.196Z","2.0.0":"2026-05-01T12:35:33.095Z"},"bugs":{"url":"https://github.com/ahmedrowaihi/contract-kit/issues"},"author":{"name":"Ahmed Rowaihi","email":"ahmedrowaihi@gmail.com"},"license":"MIT","homepage":"https://github.com/ahmedrowaihi/contract-kit/tree/main/packages/openapi/core","keywords":["openapi","codegen","sdk","shared"],"repository":{"url":"git+https://github.com/ahmedrowaihi/contract-kit.git","type":"git","directory":"packages/openapi/core"},"description":"Shared building blocks for native-client SDK generators on top of OpenAPI 3.x — identifier transforms, security-scheme walkers, ref helpers, filesystem safety. Used by @ahmedrowaihi/openapi-go, @ahmedrowaihi/openapi-kotlin, @ahmedrowaihi/openapi-swift.","maintainers":[{"name":"ahmedrowaihi","email":"ahmedrowaihi1@gmail.com"}],"readme":"# @ahmedrowaihi/openapi-core\n\nFoundational helpers shared by the native-client SDK generators in [contract-kit](https://github.com/ahmedrowaihi/contract-kit) — used by [`@ahmedrowaihi/openapi-go`](../openapi-go), [`@ahmedrowaihi/openapi-kotlin`](../openapi-kotlin), and [`@ahmedrowaihi/openapi-swift`](../openapi-swift).\n\nNot intended for direct consumption — the API surface here is whatever the three SDK generators happen to need in common, and may shift as new generators land.\n\n## What's in scope\n\n- **`pascal` / `camel` / `safeIdent` / `safeCaseName` / `synthName`** — pure string transforms (no reserved-word handling). Each generator layers its own `paramIdent` / `exportedIdent` / `enumEntryIdent` on top.\n- **`refName` / `isMeaningless`** — turn `#/components/schemas/Foo` into `Foo`; flag empty / unknown / void schemas.\n- **`extractSecuritySchemeNames` / `securityKey`** — walk the raw bundled spec to recover scheme names per (path, method), since hey-api's IR drops them.\n- **`HTTP_METHODS` / `HTTP_METHOD_LITERAL` / `JSON_MEDIA_RE` / `MULTIPART_FORM_MEDIA` / `FORM_URLENCODED_MEDIA`** — canonical constants.\n- **`assertSafeOutputDir` / `defaultProjectName`** — filesystem guardrails for the `clean: true` rm path, plus a sensible default for `rootProject.name` / `Package(name:)`.\n\n## What's *not* in scope\n\n- Per-language reserved-word sets, visibility rules, or DSL builders.\n- Schema → decl translation (`schemasToDecls`) and the per-tag interface orchestration loop. They're structurally identical across generators but tightly coupled to per-language Decl types — sharing them would require parameterising over every DSL builder, which obscures more than it dedupes.\n\n## Install\n\n```bash\npnpm add @ahmedrowaihi/openapi-core @hey-api/shared\n```\n\n`@hey-api/shared` is a peer dep so the IR types stay aligned with the generator's own version.\n","readmeFilename":"README.md"}