Application Commands

Commands for managing Tailor Platform applications. These commands work with tailor.config.ts.

init

Initialize a new project using create-sdk.

<span><span style="color: var(--shiki-token-function)">tailor-sdk</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">init</span><span style="color: var(--shiki-color-text)"> [name] [options]</span></span>
<span></span>

Arguments:

  • name - Project name

Options:

  • -t, --template - Template name

generate

Generate files using Tailor configuration.

<span><span style="color: var(--shiki-token-function)">tailor-sdk</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">generate</span><span style="color: var(--shiki-color-text)"> [options]</span></span>
<span></span>

Options:

  • -c, --config - Path to the SDK config file (default: tailor.config.ts)
  • -w, --watch - Watch for type/resolver changes and regenerate

apply

Apply Tailor configuration to deploy your application.

<span><span style="color: var(--shiki-token-function)">tailor-sdk</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">apply</span><span style="color: var(--shiki-color-text)"> [options]</span></span>
<span></span>

Options:

  • -w, --workspace-id - ID of the workspace to apply the configuration to
  • -p, --profile - Workspace profile to use
  • -c, --config - Path to the SDK config file (default: tailor.config.ts)
  • -d, --dryRun - Run the command without making any changes
  • -y, --yes - Skip confirmation prompt

remove

Remove all resources managed by the application from the workspace.

<span><span style="color: var(--shiki-token-function)">tailor-sdk</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">remove</span><span style="color: var(--shiki-color-text)"> [options]</span></span>
<span></span>

Options:

  • -w, --workspace-id - ID of the workspace to remove resources from
  • -p, --profile - Workspace profile to use
  • -c, --config - Path to the SDK config file (default: tailor.config.ts)
  • -y, --yes - Skip confirmation prompt

show

Show information about the deployed application.

<span><span style="color: var(--shiki-token-function)">tailor-sdk</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">show</span><span style="color: var(--shiki-color-text)"> [options]</span></span>
<span></span>

Options:

  • -w, --workspace-id - ID of the workspace to show the application from
  • -p, --profile - Workspace profile to use
  • -c, --config - Path to the SDK config file (default: tailor.config.ts)
  • --json - Output as JSON

tailordb

Manage TailorDB tables and data.

<span><span style="color: var(--shiki-token-function)">tailor-sdk</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">tailordb</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-keyword)">&lt;</span><span style="color: var(--shiki-token-string)">subcomman</span><span style="color: var(--shiki-color-text)">d</span><span style="color: var(--shiki-token-keyword)">&gt;</span><span style="color: var(--shiki-color-text)"> [options]</span></span>
<span></span>

tailordb truncate

Truncate (delete all records from) TailorDB tables.

<span><span style="color: var(--shiki-token-function)">tailor-sdk</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">tailordb</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">truncate</span><span style="color: var(--shiki-color-text)"> [types...] [options]</span></span>
<span></span>

Arguments:

  • types... - Space-separated list of type names to truncate (optional)

Options:

  • -a, --all - Truncate all tables in all namespaces
  • -n, --namespace - Truncate all tables in the specified namespace
  • -y, --yes - Skip confirmation prompt
  • -w, --workspace-id - ID of the workspace
  • -p, --profile - Workspace profile to use
  • -c, --config - Path to the SDK config file (default: tailor.config.ts)

Usage Examples:

<span><span style="color: var(--shiki-token-comment)"># Truncate all tables in all namespaces (requires confirmation)</span></span>
<span><span style="color: var(--shiki-token-function)">tailor-sdk</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">tailordb</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">truncate</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">--all</span></span>
<span></span>
<span><span style="color: var(--shiki-token-comment)"># Truncate all tables in all namespaces (skip confirmation)</span></span>
<span><span style="color: var(--shiki-token-function)">tailor-sdk</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">tailordb</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">truncate</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">--all</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">--yes</span></span>
<span></span>
<span><span style="color: var(--shiki-token-comment)"># Truncate all tables in a specific namespace</span></span>
<span><span style="color: var(--shiki-token-function)">tailor-sdk</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">tailordb</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">truncate</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">--namespace</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">myNamespace</span></span>
<span></span>
<span><span style="color: var(--shiki-token-comment)"># Truncate specific types (namespace is auto-detected)</span></span>
<span><span style="color: var(--shiki-token-function)">tailor-sdk</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">tailordb</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">truncate</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">User</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">Post</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">Comment</span></span>
<span></span>
<span><span style="color: var(--shiki-token-comment)"># Truncate specific types with confirmation skipped</span></span>
<span><span style="color: var(--shiki-token-function)">tailor-sdk</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">tailordb</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">truncate</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">User</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">Post</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">--yes</span></span>
<span></span>

Notes:

  • You must specify exactly one of: --all, --namespace, or type names
  • When truncating specific types, the namespace is automatically detected from your config
  • Confirmation prompts vary based on the operation:
    • --all: requires typing truncate all
    • --namespace: requires typing truncate <namespace-name>
    • Specific types: requires typing yes
  • Use --yes flag to skip confirmation prompts (useful for scripts and CI/CD)