Skip to content

Auto-generate Stellar contract reference from contract source #25

Description

@truthixify

Tier: L (1-2 weeks) Type: tooling

Context

docs/contracts/stellar.mdx is hand-maintained and drifts. The contract source has all the type info. Generate the reference section automatically from contract WASM or TypeScript bindings.

Scope

Build scripts/generate-stellar-reference.ts:

  • Reads bindings from wraith-protocol/contracts/stellar/bindings/typescript/ (or queries deployed contracts via stellar contract inspect)
  • For each contract emits MDX section: title + addresses, function table (name, params, types, return, auth-required), event signatures, storage keys
  • Inserts between marker comments in docs/contracts/stellar.mdx, preserving hand-written prose around the markers
  • CI fails when generated section is stale

Acceptance criteria

  • Script runs locally against current testnet deployments
  • Marker-based insertion preserves prose
  • CI drift-check job in place
  • Documented in docs/CONTRIBUTING.md (when changing a Stellar contract, run this)

Files to start with

  • New: scripts/generate-stellar-reference.ts
  • docs/contracts/stellar.mdx

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave programdocsDocumentationdripsFunded via Drips Networkhelp wantedExtra attention is neededtoolingBuild / tooling work

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions