Prerequisites
Prerequisites
- An application created with
fjall create app, so aninfrastructure.tsfile exists. - The resource you want to change is already declared (add it first with
fjall add). - Run the command from your project root, where the
fjall/directory lives.
Modify a resource
fjall modify changes the properties of an existing resource in an application’s infrastructure.ts. It edits the source file in place through the codemod engine, the same AST-based editor that powers fjall add and fjall remove.
--<property> <value> pair. The --name value is the PascalCase resource name, and <type> is the resource category.
Examples
Change a database instance class:What Happens
- Resolves the
infrastructure.tspath for the application you pass to--app. - Parses the file with the codemod engine (no AWS calls).
- Locates the resource named by
--nameand merges your--<property> <value>pairs into its declaration. - Writes the updated file and records a snapshot under
.fjall/history/.
fjall modify edits local source only. It never contacts AWS. To apply the change, deploy afterwards with fjall deploy <app>.
Property syntax
Every property is a flag with a trailing value. Value-less flags are rejected:Resource types
<type> must be one of the codemod resource categories:
| Value | |
|---|---|
database | messaging |
storage | cdn |
compute | network |
pattern | vpc-peer |
vpc-peer-accepter | cross-plan-connection |
Agent mode
Pass--agent to emit structured output for AI agents instead of the interactive UI. The command applies the change and returns a result describing the resource, file path, and lines changed. Combine with --budget, --fields, and --full to tune the output.
Options
| Option | Description | Default |
|---|---|---|
-a, --app <name> | Application that owns the resource. Required. | None |
-n, --name <name> | Resource name in PascalCase. Required. | None |
[properties...] | One or more --<property> <value> pairs to apply. | None |
-v, --verbose | Enable verbose logging. | false |
--non-interactive | Force plain CLI output (no UI). | false |
--agent | Enable agent output mode. | false |
--budget <level> | Output budget: minimal, compact, or a token count. | None |
--fields <fields> | Request additional fields in the output. | None |
--full | Disable content truncation. | false |
Next Steps
fjall add
Add a new resource to an application’s infrastructure.
fjall list
List the resources declared in an application.
fjall deploy
Deploy the changed infrastructure to AWS.
Add resources
Learn how Fjall resources map to AWS services.