togather-shared-protos
v1.0.0
Published
This repository contains the **common `.proto` definitions** used across all ToGather microservices.
Downloads
92
Readme
🧩 ToGather Shared Protos
This repository contains the common .proto definitions used across all ToGather microservices.
It serves as the single source of truth for shared gRPC and ConnectRPC message schemas, ensuring consistency and type safety between backend services and clients.
🚀 Overview
The ToGather Shared Protos package centralizes all protocol buffer (.proto) files.
Each microservice can import the generated TypeScript or python code directly from this package to avoid duplication and version drift.
📦 Usage
1. Install
pnpm add @togatherlabs/shared-protos2. Import in your service
import { AdminService } from "@togatherlabs/shared-protos/togather-shared-protos/authservice/admin/v1";🧠 Development Guide
1. Update proto definitions
Make your changes inside the appropriate proto/ folder (e.g., src/authservice/admin/v1/).
2. Generate TypeScript files
Run the generator to compile .proto files into TypeScript:
pnpm generateThis command runs scripts/generate_and_prepare.js, which regenerates and updates exports automatically.
3. Verify generated output
Check that new .ts and .js files were created correctly in the respective service folders under src/.
🧩 Common Guidelines
Always update .proto files before generating new code.
Use pnpm for all dependency management.
Do not manually modify generated files — regenerate instead.
Ensure consistent naming and versioning for services refer best practics
📝 Committing Changes
We use Commitizen to maintain clean and standardized commit messages.
To commit your changes:
pnpm commitThis will guide you through an interactive CLI to format your commit message properly (e.g., feat: add new admin proto definitions).
🚀 Publishing a New Version
After your changes are complete:
npm version patch
npm publishThen update in dependent services:
pnpm update @togatherlabs/shared-protos/togather-shared-protos🛠️ Stack Buf – Proto management and linting
ConnectRPC – RPC code generation
TypeScript – Generated bindings
pnpm – Package management
Commitizen – Commit message consistency
💡 Notes All services depending on this package should use the same >version to ensure consistent proto definitions.
Ensure your package.json exports are correctly updated to expose new services.
Made with ❤️ by the ToGather Team
Node.js Package
Current Status
currently the packge for node js is published under "@togatherlabs/shared-protos/togather-shared-protos""
pnpm i @togatherlabs/shared-protos/togather-shared-protosThis was for testing purpose and will be moved to company's name
