# Blob Storage (Azure)

**Blob Storage (Azure)** allows you to work with files stored in Azure Blob Storage containers.

## Parameters

Configure the connector using the parameters below. Fields that support [Double Braces expressions](https://docs.digibee.com/documentation/connectors-and-triggers/double-braces/overview) are marked in the Supports DB column.&#x20;

<table data-full-width="true"><thead><tr><th width="166">Parameter</th><th width="372">Description</th><th>Type</th><th>Supports DB</th><th width="132">Default</th></tr></thead><tbody><tr><td><strong>Alias</strong></td><td>Name (alias) for this connector’s output, allowing you to reference it later in the flow using Double Braces expressions.</td><td>String</td><td>✅</td><td>az-blob-storage-1</td></tr><tr><td><strong>Use Dynamic Account</strong></td><td>When active, the connector will use the account dynamically. Otherwise, it will use the account statically. Learn more about <a href="https://app.gitbook.com/s/jvO5S91EQURCEhbZOuuZ/development-cycle/overview/runtime/pipeline-engine/dynamic-accounts">Dynamic Accounts</a>.</td><td>Boolean</td><td>❌</td><td>False</td></tr><tr><td><strong>Scoped</strong></td><td>When active, the stored account is isolated from other subprocesses. In this case, the subprocesses see their own version of the stored account data. It is only available if the Use Dynamic Account parameter is enabled.</td><td>Boolean</td><td>❌</td><td>False</td></tr><tr><td><strong>Account name</strong></td><td>The name of the dynamic account used by the connector. This account must have been previously configured in a Store Account connector in the pipeline for this process to take effect. It is only available if the Use Dynamic Account parameter is enabled.</td><td>String</td><td>✅</td><td>N/A</td></tr><tr><td><strong>Account</strong></td><td>The account to be used by the component (list the accounts supported by the component). Supported accounts are: Basic and Public key. Basic is used to connect via ConnectionString; the storage account name must be passed in the "user" field and key1 in the "password" field. Public key is used if you want to authenticate via SAS token; use the public-key in the "key" field, then pass the SAS token generated by Azure. <a href="https://app.gitbook.com/s/jvO5S91EQURCEhbZOuuZ/platform-administration/settings/accounts">Read the Accounts documentation</a> to learn more about these and other existing account types.</td><td>String</td><td>❌</td><td>N/A</td></tr><tr><td><strong>Operation</strong></td><td>Defines which operation will the component perform (List, Download, Upload, and Delete). Completion of this field is mandatory.</td><td>String</td><td>❌</td><td>Upload</td></tr><tr><td><strong>Container Name</strong></td><td>Name of the Blob Storage container (Azure) that will handle the files. Completion of this field is mandatory.</td><td>String</td><td>❌</td><td>container</td></tr><tr><td><strong>Container Account</strong></td><td>Azure account name that Blob Storage uses. Completion of this field is mandatory.</td><td>String</td><td>❌</td><td>N/A</td></tr><tr><td><strong>Remote File Name</strong> <code>(DB)</code></td><td>Destination name of your file, the same name that the file will have in Blob Storage (Azure). Completion of this field is mandatory only when Upload, Download or Delete operations are selected.</td><td>String</td><td>✅</td><td>test.csv</td></tr><tr><td><strong>File Name</strong> <code>(DB)</code></td><td>Name of the file you want to upload to your Blob Storage (Azure). Completion of this field is mandatory.</td><td>String</td><td>✅</td><td>file.csv</td></tr><tr><td><strong>Generate a Download Link</strong></td><td>If the option is enabled, you will be able to generate a file download link. This parameter is shown only when the Upload operation is selected.</td><td>Boolean</td><td>❌</td><td>True</td></tr><tr><td><strong>Page Size</strong> <code>(DB)</code></td><td>Number of records you want to bring per page. This parameter is shown only when the List operation is selected.</td><td>Integer</td><td>✅</td><td>N/A</td></tr><tr><td><strong>Prefix</strong> </td><td>Filters the results to return only blobs whose names begin with the specified prefix. This parameter is shown only when the List operation is selected.</td><td>String</td><td>❌</td><td>N/A</td></tr><tr><td><strong>Next Page Token</strong> <code>(DB)</code></td><td>NextToken that will be used to bring the records from the next page. This parameter  is shown only when the List operation is selected.</td><td>String</td><td>✅</td><td>N/A</td></tr><tr><td><strong>Next Token Type</strong> <code>(DB)</code></td><td>Type of the next record that will be listed on the next page. This parameter is shown only when the List operation is selected.</td><td>String</td><td>✅</td><td>N/A</td></tr><tr><td><strong>Overwrite File on Upload</strong> </td><td>Overwrite the file at the time of upload. This parameter is shown only when the Upload operation is selected.</td><td>Boolean</td><td>❌</td><td>True</td></tr><tr><td><strong>Snapshot</strong></td><td>If the option is activated, it will include snapshots on the blobs' response. Available only for the List operation.</td><td>Boolean</td><td>❌</td><td>False</td></tr><tr><td><strong>Metadata</strong></td><td>If the option is activated, it will include metadata on the blobs' response. Available only for the List operation.</td><td>Boolean</td><td>❌</td><td>False</td></tr><tr><td><strong>Uncommited</strong></td><td>If the option is activated, it will include uncommited blobs on response. Available only for the List operation.</td><td>Boolean</td><td>❌</td><td>False</td></tr><tr><td><strong>Copy</strong></td><td>If the option is activated, it will include copy blobs on response. Available only for the List operation.</td><td>Boolean</td><td>❌</td><td>False</td></tr><tr><td><strong>Delete</strong></td><td>If the option is activated, it will include delete blobs on response. Available only for the List operation.</td><td>Boolean</td><td>❌</td><td>False</td></tr><tr><td><strong>Fail On Error</strong></td><td>If the option is enabled, the execution of the pipeline with error will be interrupted; otherwise, the pipeline execution proceeds, but the result will show a false value for the “success” property.</td><td>Boolean</td><td>❌</td><td>False</td></tr></tbody></table>

## **Messages flow**

### Operation List <a href="#h_a1c2c9351f" id="h_a1c2c9351f"></a>

```
{
"success": true,
"content": [
{
"fileName": "my-remote-file.txt",
"containerName": "newcontainer",
"properties": {
"createdDate": "Fri May 20 13:41:12 UTC 2022",
"lastUpdated": "Wed May 25 14:59:26 UTC 2022",
"contentType": "application/octet-stream",
"length": 23
}
},
{
"fileName": "testeOverwrite.txt",
"containerName": "newcontainer",
"properties": {
"createdDate": "Tue Jun 14 18:11:35 UTC 2022",
"lastUpdated": "Tue Jun 14 18:11:47 UTC 2022",
"contentType": "application/octet-stream",
"length": 76952
}
}
],
"count": 2,
"containerName": "newcontainer"
}
```

### Operation Upload <a href="#h_c329e1bb13" id="h_c329e1bb13"></a>

```
{
"success": true,
"fileName": "teste-upload.jpeg",
"containerName": "teste",
"remoteFileName": "teste-upload.jpeg",
"urlGenerated": "
https://digibeeblobstorage.blob.core.windows.net/teste/teste-upload.jpeg
"
}
```

### Operation Download <a href="#h_102322c40a" id="h_102322c40a"></a>

{% hint style="info" icon="right-from-line" %}
Use the [**File Reader**](https://docs.digibee.com/documentation/connectors-and-triggers/connectors/files/file-reader) connector to handle the base64 returned.
{% endhint %}

### Operation Delete <a href="#h_b69dcf01ae" id="h_b69dcf01ae"></a>

```
{
"success": true,
"containerName": "newcontainer",
"remoteFileName": "teste-upload.jpeg"
}
```
