> For the complete documentation index, see [llms.txt](https://help.pixfizz.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.pixfizz.com/orders-and-fulfillment/ability-to-provide-file-content-directly-in-_additional_files-json.md).

# Ability to provide file content directly in \_additional\_files.json

You can now pass content for an additional file directly inside `_additional_files.json` instead of providing a URL to fetch the file from. To do that use `content` inside the `source` field:

```jsx
[
  {
    "destination": myfile.txt,
    "source": {
      "content": "Content for myfile.txt!"
    }
  }
]
```

* An example use-case is when you need to create a separate job ticket file for each orderline in the order.
* Liquid’s `capture` together with the `escape_json` filter can be useful when generated file content needs to be more complex:

  ```jsx
  [
  {% for line in orderlines %}
  {% capture file_content %}
  Content with newlines
  and liquid code: {{ line.barcode }}
  {% endcapture %}
    {
      "destination": myfile.txt,
      "source": {
        "content": "{{ file_content | escape_json }}"
      }
    }{% unless forloop.last %},{% endunless %}
  {% endfor %}
  ]
  ```

Example to add `file_upload` type Variants into a folder on the FTP.

```
{%- for line in orderlines -%}

	{%- comment %} Template options — file_upload type {%- endcomment -%}
	{%- for opt in line.chosen_template_options -%}
		{%- if opt.template_option.type == "file_upload" and opt.uploaded_file.url != blank -%}
		,
			{
				"source": "{{ opt.uploaded_file.url | escape_json }}",
				"destination": "/Artwork/{{ order.code | escape_json }}/Uploaded_Files/{{ forloop.parentloop.index }}-{{ opt.uploaded_file.filename | escape_json }}"
			}
		{%- endif -%}
	{%- endfor -%}

	{%- comment %} Product variants — file_upload type {%- endcomment -%}
	{%- for v in line.chosen_variants -%}
		{%- if v.variant.type == "file_upload" and v.uploaded_file.url != blank -%}
		,
			{
				"source": "{{ v.uploaded_file.url | escape_json }}",
				"destination": "/Artwork/{{ order.code | escape_json }}/Uploaded_Files/{{ forloop.parentloop.index }}-{{ v.uploaded_file.filename | escape_json }}"
			}
		{%- endif -%}
	{%- endfor -%}

{%- endfor -%}
```
