MCPcopy Index your code
hub / github.com/nitrictech/nitric

github.com/nitrictech/nitric @v1.27.6 sqlite

repository ↗ · DeepWiki ↗ · release v1.27.6 ↗
9,457 symbols 17,083 edges 861 files 2,527 documented · 27%
README

Nitric Logo

Effortless backends with infrastructure from code

GitHub release (latest SemVer) GitHub GitHub Workflow Status Codecov Discord

Nitric is a multi-language framework, with concise inline infrastructure from code. Modern applications should be robust, productive and a joy to build. Nitric solves common problems building for modern platforms:

We also know abstraction should mean building on existing layers, not hiding them. Nitric includes powerful escape hatches for when things get custom.

Supported Languages

Supported Clouds

These are supported out of the box, but you can also build custom providers as well

🧑‍💻 Get started

💿 Install Nitric:

macOS:

brew install nitrictech/tap/nitric

Linux:

curl -L "https://nitric.io/install?version=latest" | bash

Windows:

scoop bucket add nitric https://github.com/nitrictech/scoop-bucket.git
scoop install nitric

🚀 Start building your first app:

nitric new

🕹 See our example apps: Example Apps Repo.

📚 Prefer a walkthrough? Read through our guides.

👋 Any questions? Join our developer community on Discord.

Give us a star to help support our work!

🍿 Visual Learner?

To get up to speed quickly, take a look at our quick intro to Nitric.

🤷 So.. how does it work?

Nitric focuses on what you want to achieve as the developer:

What workflow do you need to be productive?

What system design are you trying to achieve?.

All you need to do is write your application code and your infrastructure requirements are inferred. Nitric then orchestrates and configures the deployment of your application, no need to manually write your Terraform or other IaC code. By abstracting these infrastructure requirements, it removes the need to write boilerplate and means your single application is portable across clouds including, AWS, GCP, and Azure.

And, it's all open-source

📝 Example: Note Taking

Creating production-ready services and resources is simple, with less than 10 lines to deploy an API endpoint and a bucket with all the IAM permissions automatically configured.

import { api, bucket } from "@nitric/sdk";

const main = api("main");
const notes = bucket("notes").allow("read", "write");

main.post("/notes/:title", async (ctx) => {
  const { title } = ctx.req.params;
  await notes.file(title).write(ctx.req.text());
});

This is the only code needed to deploy a working application to any cloud provider using nitric up. Nitric can deploy this application using automatically generated Pulumi, Terraform or any other automation tools of your choice.

Why use Nitric?

  1. Developer-Centric Workflow Nitric lets you design your application architecture, independent of the deployment automation tool or target platform. With highly declarative in-app infrastructure requirements.

  2. Making Implicit Requirements Explicit If your app needs storage, a database, or a message queue, Nitric ensures these resources are properly set up and integrated into your app, removing the friction of manual configuration.

  3. Cloud-Agnostic and Portable Nitric decouples your application from the underlying cloud infrastructure. Whether you're using AWS, Azure, GCP, or Kubernetes, Nitric allows you to map your application's requirements to the appropriate services across platforms.

  4. Automated Infrastructure, Best Practices Included One of the most error-prone aspects of cloud development is managing permissions, configurations, and security policies. Nitric automates this, making security best practices—like least privilege access and proper service configurations easy.

  5. Focus on Application Logic Nitric's approach allows you to focus on building your application, instead of the scaffolding required to run it in the cloud. By removing the manual steps from the IaC process, Nitric eliminates significant boilerplate and reduces the runtime checking needed to handle configuration errors.

  6. Plugin-Based Architecture Nitric's plugin-based architecture allows you to use the deployment plugins we provide, which use Pulumi or Terraform for deployment, or write your own. This flexibility allows you to use the tools you're comfortable with, while still benefiting from Nitric's infrastructure automation and cloud-agnostic approach.

Want more?

Nitric has full documentation at nitric.io/docs, including concepts, reference documentation for various languages and many tutorials/guides.

Contributing

We greatly appreciate contributions, consider starting with the contributions guide or development guide, and a chat on Discord or GitHub.

Extension points exported contracts — how you extend this code

IdentifiableMessage (Interface)
IdentifiableMessage is a message that has an ID, used to match requests and responses [16 implementers]
core/pkg/workers/request_broker.go
GenericIterator (Interface)
(no doc) [10 implementers]
cloud/gcp/runtime/resource/resource.go
AzqueueMessageIdUrlIface (Interface)
(no doc) [19 implementers]
cloud/azure/runtime/queue/iface/iface.go
SNSAPI (Interface)
(no doc) [10 implementers]
cloud/aws/ifaces/snsiface/sns.go
RuntimeProvider (FuncType)
A function that returns the runtime for a nitric provider
cloud/common/deploy/provider/runtime.go
MatchCallback (FuncType)
(no doc)
test/matcher.go
Resource (Interface)
(no doc)
docs/src/components/Resources.tsx
GatewayService (Interface)
GatewayService - The interface for a Nitric Gateway, which acts as provider specific adapter for all incoming requests. [7 …
core/pkg/gateway/plugin.go

Core symbols most depended-on inside this repo

Get
called by 974
cloud/gcp/ifaces/pubsub/ifaces.go
String
called by 948
cloud/gcp/ifaces/pubsub/ifaces.go
EXPECT
called by 137
cloud/gcp/mocks/pubsub/mock.go
Int
called by 102
core/pkg/env/env.go
cn
called by 89
docs/src/lib/utils.ts
EXPECT
called by 82
cloud/aws/mocks/s3/mock.go
Error
called by 80
cloud/azure/mocks/azblob/error.go
Bool
called by 78
core/pkg/env/env.go

Shape

Method 7,151
Function 1,307
Struct 726
Interface 247
FuncType 13
TypeAlias 11
Class 2

Languages

Go97%
TypeScript3%

Modules by API surface

core/pkg/proto/deployments/v1/deployments.pb.go401 symbols
core/pkg/proto/storage/v1/storage.pb.go192 symbols
core/pkg/proto/resources/v1/resources.pb.go171 symbols
core/pkg/proto/websockets/v1/websockets.pb.go166 symbols
cloud/azure/deploytf/generated/service/Service.go134 symbols
cloud/azure/deploytf/generated/stack/Stack.go132 symbols
cloud/gcp/deploytf/generated/service/Service.go128 symbols
core/pkg/proto/apis/v1/apis.pb.go116 symbols
cloud/azure/deploytf/generated/cdn/Cdn.go114 symbols
cloud/azure/deploytf/generated/sql/Sql.go106 symbols
cloud/aws/deploytf/generated/service/Service.go104 symbols
cloud/aws/deploytf/generated/sql/Sql.go102 symbols

Dependencies from manifests, versioned

4d63.com/gocheckcompilerdirectivesv1.2.1 · 1×
4d63.com/gochecknoglobalsv0.2.1 · 1×
cloud.google.com/gov0.115.1 · 1×
cloud.google.com/go/apigatewayv1.7.0 · 1×
cloud.google.com/go/auth/oauth2adaptv0.2.4 · 1×
cloud.google.com/go/batchv1.10.0 · 1×
cloud.google.com/go/cloudtasksv1.13.0 · 1×
cloud.google.com/go/compute/metadatav0.5.2 · 1×
cloud.google.com/go/firestorev1.16.0 · 1×
cloud.google.com/go/longrunningv0.6.0 · 1×

Datastores touched

(mongodb)Database · 1 repos

For agents

$ claude mcp add nitric \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact