> ## Documentation Index
> Fetch the complete documentation index at: https://backstage.spotify.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Getting Started with Scaffolder

> Create your first Software Template in Portal using premade templates or from scratch, then preview and run it with dry-run mode.

This guide will help you create and run your first Software Templates using the Portal Scaffolder.

## Creating Your First Template

The Portal Scaffolder allows you to create templates directly in the UI without leaving Portal.

### Choose Your Starting Point

When creating a new template, you have two options:

1. **Create from a Premade Template**: Start with an existing template as a base
2. **Create from Scratch**: Build a template from the ground up

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/create-template-dropdown.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=9ff2f2fcb8a7c544f85123707f56c128" alt="Create template dropdown" width="1716" height="672" data-path="portal/core-features-and-plugins/scaffolder/assets/create-template-dropdown.png" />
</Frame>

### Creating from a Premade Template

1. **Navigate to Create Template**: Click the create new template button
2. **Select Source**: Choose to create from a premade template

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/premade-template-selector.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=7b19df4807944dea342194d0cf31124d" alt="Premade template selector" width="539" height="576" data-path="portal/core-features-and-plugins/scaffolder/assets/premade-template-selector.png" />
</Frame>

1. **Save the template**: Click on the save button

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/save-template-button.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=a18cf95cb09777fb533abd11727a2258" alt="Save template" width="448" height="286" data-path="portal/core-features-and-plugins/scaffolder/assets/save-template-button.png" />
</Frame>

1. **Preview the Template**: Review the template structure and configuration

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/click-template-preview.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=c9adeb59d5e35c6696287121ce2ac986" alt="click template preview" width="1712" height="1060" data-path="portal/core-features-and-plugins/scaffolder/assets/click-template-preview.png" />
</Frame>

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/dry-run-mode.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=51fcabab969e098aef99c4dfcc87e4f0" alt="dry-run mode" width="1714" height="908" data-path="portal/core-features-and-plugins/scaffolder/assets/dry-run-mode.png" />
</Frame>

### Editing Your Template

Once you have a template loaded, you can customize it using the Portal editor:

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/template-editor.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=658a2fea14d8e2f793cd4e8649f6a94b" alt="template editor" width="1715" height="979" data-path="portal/core-features-and-plugins/scaffolder/assets/template-editor.png" />
</Frame>

#### Configure Form Fields

1. Navigate to the form fields configuration section
2. View existing field configurations
3. Add new fields by clicking **Append**

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/template-editor-form-fields.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=00971ddf95ae0506fc8a1c7d59f1525b" alt="template editor form fields" width="1713" height="1070" data-path="portal/core-features-and-plugins/scaffolder/assets/template-editor-form-fields.png" />
</Frame>

4. Configure field properties:
   * Field type
   * Label and description
   * Validation rules
   * Default values

<Frame>
  <img
    src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/template-editor-form-fields-append.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=fd20fe11fcd93e042f48b4854a471d41"
    alt="template editor form fields
append"
    width="1710"
    height="1221"
    data-path="portal/core-features-and-plugins/scaffolder/assets/template-editor-form-fields-append.png"
  />
</Frame>

#### Add Actions

Actions define what the template does when executed.

1. Navigate to the actions section
2. Click to add a new action
3. Choose from available actions (e.g., `catalog:register`, `github:create`)

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/template-editor-actions.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=b538a29bea7ca29ee56b1f139a4de600" alt="template editor actions" width="1709" height="1087" data-path="portal/core-features-and-plugins/scaffolder/assets/template-editor-actions.png" />
</Frame>

4. Configure action parameters

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/template-editor-action-editing.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=f2ea505bf6a3a6d0f749ce56abc248aa" alt="template editor action editing" width="1713" height="1100" data-path="portal/core-features-and-plugins/scaffolder/assets/template-editor-action-editing.png" />
</Frame>

#### Use Extensions

Extensions provide additional functionality through data filters, functions, and custom values:

1. Navigate to the extensions section
2. Add filters to transform data
3. Define custom functions
4. Set up reusable values

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/template-editor-extensions.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=29d6bdc50f0a7084d12ffa0861785de7" alt="template editor extensions" width="1713" height="1091" data-path="portal/core-features-and-plugins/scaffolder/assets/template-editor-extensions.png" />
</Frame>

### Testing Your Template

Before publishing, test your template using the **Dry Run** feature:

1. Click **Dry Run** in the template editor

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/dry-run-1.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=3429bc64d13669c5fffc18aee6545d44" alt="dry run step" width="1715" height="908" data-path="portal/core-features-and-plugins/scaffolder/assets/dry-run-1.png" />
</Frame>

2. Fill in test values in the form
3. Click **Test** to simulate execution without creating resources

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/dry-run-2.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=28b76d5ff35d6a5101f032081879ff83" alt="dry run step" width="1714" height="997" data-path="portal/core-features-and-plugins/scaffolder/assets/dry-run-2.png" />
</Frame>

4. Review the output to verify expected behavior
5. The dry run shows what repository and resources would be created

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/dry-run-3.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=1690e4b5d675fbaeece824653664d77a" alt="dry run step" width="1715" height="754" data-path="portal/core-features-and-plugins/scaffolder/assets/dry-run-3.png" />
</Frame>

### Saving and Publishing

#### Save as Draft

* Click **Save** to save your changes as a draft
* Or click **Download** to download the template locally
* Draft templates can be edited further before publishing

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/draft-templates.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=dd88fb292dc43d157c82139320f43a34" alt="draft templates list" width="1719" height="810" data-path="portal/core-features-and-plugins/scaffolder/assets/draft-templates.png" />
</Frame>

#### Publish Template

1. When ready to make your template available, click **Publish**

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/publish-save-button.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=0f0ee10e9450eec2eeedb1fc59a9b30e" alt="publish save buttons" width="443" height="190" data-path="portal/core-features-and-plugins/scaffolder/assets/publish-save-button.png" />
</Frame>

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/publish-dialog.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=7c04dd4cfe2028c53ff52a90946cd727" alt="publish dialog" width="522" height="442" data-path="portal/core-features-and-plugins/scaffolder/assets/publish-dialog.png" />
</Frame>

2. The template will now appear in the templates list
3. Other users can now discover and run your template

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/published-template.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=8d87ef996ad2ef40936f6ea0ad9deea3" alt="published templates list" width="1709" height="730" data-path="portal/core-features-and-plugins/scaffolder/assets/published-template.png" />
</Frame>

## Running Your First Template

Once you have published templates available, running them is straightforward.

1. **Navigate to Templates**: Go to the Scaffolder templates page in Portal
2. **Select a Template**: Browse available templates and click **Run** on the template you want to use

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/template-card.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=e3d7e6b47ef7d96b526df988dc0e33cf" alt="template card" width="410" height="240" data-path="portal/core-features-and-plugins/scaffolder/assets/template-card.png" />
</Frame>

3. **Fill in Details**:
   * Select your organization from the dropdown
   * Enter the required information (e.g., repository name, description)
   * Review any additional configuration options

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/template-step-1.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=a743d395e7bfd29945dc251aa1550e5c" alt="wizard step 1" width="1714" height="813" data-path="portal/core-features-and-plugins/scaffolder/assets/template-step-1.png" />
</Frame>

4. **Review & Submit**:
   * Click **Review** to verify your inputs

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/template-step-2.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=6ace4f7eb95450885fd898f5c7ecbc66" alt="wizard step 2" width="1711" height="889" data-path="portal/core-features-and-plugins/scaffolder/assets/template-step-2.png" />
</Frame>

* Click **Submit** to execute the template

5. **Monitor Progress**:
   * View real-time logs as the template executes
   * Check the output section for created resources

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/in-progress.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=7892c4908b439c9d572739a70dd306da" alt="in progress" width="1711" height="798" data-path="portal/core-features-and-plugins/scaffolder/assets/in-progress.png" />
</Frame>

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/logs.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=171f9048822be931d8cc362654eae8bb" alt="in progress logs" width="1712" height="959" data-path="portal/core-features-and-plugins/scaffolder/assets/logs.png" />
</Frame>

* Once complete, you'll see confirmation of the created resources (e.g., repository, catalog entities)

<Frame>
  <img src="https://mintcdn.com/spotify-89f50c35/O6Aai2s7btF_z0wG/portal/core-features-and-plugins/scaffolder/assets/outputs.png?fit=max&auto=format&n=O6Aai2s7btF_z0wG&q=85&s=752fadd2e3e3ea12c5ee1450e51b1087" alt="outputs" width="1716" height="863" data-path="portal/core-features-and-plugins/scaffolder/assets/outputs.png" />
</Frame>

## Next Steps

* Learn more about [template configuration and advanced features](./how-to-guides.mdx)
* Explore the [technical reference and FAQ](./reference.mdx)
