Thank you for your interest in contributing to Multicorn Shield. This document explains how to get involved.
This project follows the Contributor Covenant Code of Conduct. By participating, you agree to uphold these standards. Please report unacceptable behaviour to conduct@multicorn.ai.
- Search existing issues before opening a new one.
- Use the appropriate issue template (bug report, feature request).
- Include reproduction steps for bugs. Minimal, complete examples speed up resolution.
- Fork the repository and clone your fork locally.
- Branch from
mainusing the naming convention:feature/short-description fix/short-description docs/short-description chore/short-description - Make your changes. Keep PRs focused: one logical change per PR.
- Write tests. New code needs tests. The SDK targets 85% minimum coverage.
- Commit using Conventional Commits:
feat(consent): add keyboard shortcut for approve action fix(spending): correct daily reset at midnight boundary docs(readme): add Vue framework example test(mcp): add coverage for custom extractService function - Push and open a pull request against
main.
- All PRs are merged using Squash and merge on GitHub. This is the default and only allowed merge strategy for this repo.
- The squash commit message should follow Conventional Commits format:
feat(sdk): short description of the change (#PR_NUMBER). - Never merge
maininto your feature branch. Always rebase:git rebase main. - After rebasing, force push with lease:
git push --force-with-lease. - Version bumps and npm publish happen on main only, never on feature branches.
- Node.js 20+ (check
.nvmrc) - pnpm 9+
git clone https://github.com/<your-fork>/multicorn-shield.git
cd multicorn-shield
pnpm install
pnpm test
pnpm build| Command | What it does |
|---|---|
pnpm build |
Build ESM + CJS bundles |
pnpm dev |
Build in watch mode |
pnpm test |
Run the full test suite |
pnpm test:watch |
Run tests in watch mode |
pnpm test:coverage |
Run tests with coverage reporting |
pnpm lint |
Check lint and formatting |
pnpm lint:fix |
Auto-fix lint and formatting issues |
pnpm typecheck |
Type-check without emitting output |
pnpm docs |
Generate API documentation |
- Strict mode is always on. No
anytypes. Useunknownwith type guards. - No
!non-null assertions. Handle nulls explicitly. - No
enum. Useas constobjects with type inference. - Prefer
interfaceovertypefor object shapes. - Named exports only (no default exports).
- All async functions must have error handling.
- Use
readonlyon arrays and objects that should not be mutated.
- No file should exceed approximately 300 lines. Split if it does.
- One responsibility per file.
- Utility functions go in files named after what they do (
formatCurrency.ts), not in catch-allutils.tsfiles.
- Test names read like specifications:
"blocks action when agent exceeds spending limit". - Test happy paths, edge cases, and error paths.
- Do not test framework internals or write tests that only assert mocks were called.
- All public functions and types have JSDoc with
@exampleblocks. - Comments explain why, not what. The code should be self-explanatory.
- All tests pass (
pnpm test) - Lint passes (
pnpm lint) - Types check (
pnpm typecheck) - Build succeeds (
pnpm build) - Coverage meets or exceeds 85%
Include these sections in every PR description:
- What: one-sentence summary of the change
- Why: what problem this solves or what value it adds
- How: brief technical approach
- Testing: what was tested and how to verify
- Does the change follow the coding standards above?
- Are there tests for new behaviour?
- Are error messages clear and actionable?
- Is the public API surface intentional (not accidentally exposing internals)?
- Does the change introduce any security concerns?
| Label | Meaning |
|---|---|
good first issue |
Suitable for new contributors |
bug |
Confirmed defect |
enhancement |
Feature request or improvement |
documentation |
Documentation changes only |
security |
Security-related issue (handle with care) |
breaking |
Change that affects the public API |
This project follows Semantic Versioning:
- Patch (0.0.x): bug fixes, no API changes
- Minor (0.x.0): new features, backwards compatible
- Major (x.0.0): breaking changes to the public API
Releases are triggered by maintainers. The CHANGELOG is updated with every release using Keep a Changelog format.
Open a discussion or reach out at hello@multicorn.ai.