---
name: azion-how-to-provision-files
description: >-
  Add Text and Shell Script resources to an Orchestrator edge service with Azion Console or API v3.
---

# How to provision files

> Platform versions: this page applies to API v3.x only, not to API v4.x.
> Equivalent page for API v4.x: [How to provision files](/en/documentation/guides/application-development/automation/provision-files.md)
> Release stage: Deprecated.

To be able to orchestrate services on your device, you need to configure all the resources. These resources can be:

- **Text**: for content being copied as plain text to the edge node.
- **Shell Script**: for resources that will be installed and run according to the selected *trigger*.

You can create a resource in Azion Console or with the Azion API.

---

## Create the resource

### Console

1. Access [Azion Console](https://console.azion.com/) > **Edge Services**.
2. Select the edge service to which you want to add a resource.
3. Go to the **Resources** tab and select **+ Resource**.
4. Enter the **Path** of the resource.
5. Choose the type **Text**.
6. Add the following content to the content block:

```bash
My name is {{name}}, and this is my first added resource
```

> **Note**
>
> The tag `{{name}}` will be replaced by the environment configured for the service or the variable configured on the node. The edge node variable will override the variable configure on the edge service.

7. Select **Save**.

### API

1. Run the following `GET` request in your terminal, replacing `[TOKEN VALUE]` with your [personal token](/en/documentation/guides/platform/account-and-billing/personal-tokens/) and retrieve the edge service ID:

```bash
curl --location 'https://api.azionapi.net/edge_services/' \
--header 'Accept: application/json; version=3' \
--header 'Authorization: Token [TOKEN VALUE]'
```

2. Run the following `POST` request in your terminal:

```bash
curl --location 'https://api.azionapi.net/edge_services/:id/resources' \
--header 'Accept: application/json; version=3' \
--header 'Authorization: Token [TOKEN VALUE]' \
--header 'Content-Type: application/json' \
--data '{
  "content_type": "Text",
  "name": "/resource",
  "content": "My name is {{name}}, and this is my first added resource"
}'
```

Replace `[TOKEN VALUE]` with your [personal token](/en/documentation/guides/platform/account-and-billing/personal-tokens/), `:id` with the ID of the edge service and inform the following parameters in the request body:

| Property       | Description                                                                             | Required |
| -------------- | --------------------------------------------------------------------------------------- | -------- |
| `content_type` | Content type of the resource being created                                              | Yes      |
| `name`         | Name of the resource being created                                                      | Yes      |
| `content`      | Content that defines actions performed when the resource state changes in the edge node | Yes      |

Now, your resource is created and able to work with the edge nodes related to the service in specific.

> **Tip**
>
> Check the [Azion API documentation](https://api.azion.com/v3) and the [OpenAPI specification](https://github.com/aziontech/azionapi-openapi/) to know more about all features available via API.

[Go to Work with Variables Guide](/en/documentation/guides/application-development/automation/work-with-variables-v3/)
