# Templates

Templates let you save commonly used line items and order attributes for instant reuse.

### What are templates?

Draft Order Magic supports two types of templates:

#### Line item property templates

Save bundles of line items with their properties:

* Product SKUs and quantities
* Line item properties
* Common bundles or kits

[Learn more about line item templates →](https://github.com/horselditty/draft-order-docs/blob/main/product/templates/line-item-templates/README.md)

#### Order attribute templates

Save sets of order-level attributes:

* Common tracking fields
* Approval workflows
* Department codes

[Learn more about attribute templates →](https://github.com/horselditty/draft-order-docs/blob/main/product/templates/attribute-templates/README.md)

### How templates work

#### Creating templates

Templates are stored as Shopify **metaobjects** which means:

* ✅ They persist across sessions
* ✅ They're backed up with your Shopify data
* ✅ They're accessible from any device
* ❌ They're specific to your store (not transferable between stores)

#### Applying templates

When you apply a template:

1. Click "Apply template" in the editor
2. Select from your saved templates
3. All items/attributes from the template are added at once
4. You can still edit, add, or remove items after applying

#### Editing templates

Templates can be:

* Created
* Edited
* Deleted
* Duplicated

Changes to templates don't affect draft orders where you've already applied the template (templates are copied, not linked).

### Managing templates

#### Accessing template management

1. Open Draft Order Magic
2. Click **Templates** in the navigation (or **Line item templates** / **Attribute templates**)
3. You'll see a list of all saved templates
4. Click any template to edit, or **Create template** to add new

#### Template list

The template list shows:

* Template name
* Number of items/attributes in the template
* Last modified date
* Actions (Edit, Delete, Duplicate)

#### Creating vs. editing

**Create a template:**

* From scratch in template management
* Or save current draft order as template (if available)

**Edit a template:**

* Open template management
* Click template to edit
* Modify items/attributes
* Save changes

{% hint style="warning" %}
Editing a template doesn't update draft orders where you've already applied it. Those orders keep their original values.
{% endhint %}

### Template storage limits

Templates are stored as Shopify metaobjects. Shopify limits:

* \~250 metaobject entries per definition
* Size per entry varies based on content

### What's next?

Dive deeper into each template type:

Create reusable product bundles with properties Save standard order-level attribute sets

Or explore how to use templates with other features:

Learn how to apply templates in the editor Alternative bulk method for large orders


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://responsive-media.gitbook.io/draft-order-magic/templates/index.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
