[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M71RNA7564RN12ZBAS59SHRK":3,"skill-same:01M71RNA7564RN12ZBAS59SHRK":49},{"skillNo":4,"name":5,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":6,"repositoryNo":11,"starsCount":12,"licenseSpdxId":13,"licenseFileUrl":6,"sourceHtmlUrl":14,"categories":15,"keywords":16,"publishedAt":24,"linkOnly":25,"markdownContent":26,"markdownBody":27,"frontMatter":28,"refName":29,"commitSha":30,"skillDirectory":31,"forksCount":12,"repositoryHtmlUrl":32,"repositoryHomepageUrl":6,"ownerHtmlUrl":33,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":34,"install":35,"resources":48},"01M71RNA7564RN12ZBAS59SHRK","azure-storage-file-share-ts",null,"javiertarazon\u002Fide-agente-free-jt7-","javiertarazon","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F153141207?v=4","01M71R52TB3S9HXKH6WSNT8A7V","01M71R52VG5KS2DKDDH4GDQ30A",0,"MIT","https:\u002F\u002Fgithub.com\u002Fjaviertarazon\u002Fide-agente-free-jt7-\u002Fblob\u002Frelease\u002Fv4.2.11-panel-pro\u002F.github\u002Fskills\u002Fazure-storage-file-share-ts\u002FSKILL.md",[],[17,18,19,20,21,22,23],"azure storage file share ts","file share","storage","azure storage","azure","file","share","2026-11-10 13:02:02",false,"---\nname: azure-storage-file-share-ts\ndescription: \"|\"\n  Azure File Share JavaScript\u002FTypeScript SDK (@azure\u002Fstorage-file-share) for SMB file share operations. Use for creating shares, managing directories, uploading\u002Fdownloading files, and handling file metadata. Supports Azure Files SMB protocol scenarios. Triggers: \"file share\", \"@azure\u002Fstorage-file-share\", \"ShareServiceClient\", \"ShareClient\", \"SMB\", \"Azure Files\".\npackage: \"@azure\u002Fstorage-file-share\"\nrisk: unknown\nsource: community\n---\n\n# @azure\u002Fstorage-file-share (TypeScript\u002FJavaScript)\n\nSDK for Azure File Share operations — SMB file shares, directories, and file operations.\n\n## Installation\n\n```bash\nnpm install @azure\u002Fstorage-file-share @azure\u002Fidentity\n```\n\n**Current Version**: 12.x  \n**Node.js**: >= 18.0.0\n\n## Environment Variables\n\n```bash\nAZURE_STORAGE_ACCOUNT_NAME=\u003Caccount-name>\nAZURE_STORAGE_ACCOUNT_KEY=\u003Caccount-key>\n# OR connection string\nAZURE_STORAGE_CONNECTION_STRING=DefaultEndpointsProtocol=https;AccountName=...\n```\n\n## Authentication\n\n### Connection String (Simplest)\n\n```typescript\nimport { ShareServiceClient } from \"@azure\u002Fstorage-file-share\";\n\nconst client = ShareServiceClient.fromConnectionString(\n  process.env.AZURE_STORAGE_CONNECTION_STRING!\n);\n```\n\n### StorageSharedKeyCredential (Node.js only)\n\n```typescript\nimport { ShareServiceClient, StorageSharedKeyCredential } from \"@azure\u002Fstorage-file-share\";\n\nconst accountName = process.env.AZURE_STORAGE_ACCOUNT_NAME!;\nconst accountKey = process.env.AZURE_STORAGE_ACCOUNT_KEY!;\n\nconst sharedKeyCredential = new StorageSharedKeyCredential(accountName, accountKey);\nconst client = new ShareServiceClient(\n  `https:\u002F\u002F${accountName}.file.core.windows.net`,\n  sharedKeyCredential\n);\n```\n\n### DefaultAzureCredential\n\n```typescript\nimport { ShareServiceClient } from \"@azure\u002Fstorage-file-share\";\nimport { DefaultAzureCredential } from \"@azure\u002Fidentity\";\n\nconst accountName = process.env.AZURE_STORAGE_ACCOUNT_NAME!;\nconst client = new ShareServiceClient(\n  `https:\u002F\u002F${accountName}.file.core.windows.net`,\n  new DefaultAzureCredential()\n);\n```\n\n### SAS Token\n\n```typescript\nimport { ShareServiceClient } from \"@azure\u002Fstorage-file-share\";\n\nconst accountName = process.env.AZURE_STORAGE_ACCOUNT_NAME!;\nconst sasToken = process.env.AZURE_STORAGE_SAS_TOKEN!;\n\nconst client = new ShareServiceClient(\n  `https:\u002F\u002F${accountName}.file.core.windows.net${sasToken}`\n);\n```\n\n## Client Hierarchy\n\n```\nShareServiceClient (account level)\n└── ShareClient (share level)\n    └── ShareDirectoryClient (directory level)\n        └── ShareFileClient (file level)\n```\n\n## Share Operations\n\n### Create Share\n\n```typescript\nconst shareClient = client.getShareClient(\"my-share\");\nawait shareClient.create();\n\n\u002F\u002F Create with quota (in GB)\nawait shareClient.create({ quota: 100 });\n```\n\n### List Shares\n\n```typescript\nfor await (const share of client.listShares()) {\n  console.log(share.name, share.properties.quota);\n}\n\n\u002F\u002F With prefix filter\nfor await (const share of client.listShares({ prefix: \"logs-\" })) {\n  console.log(share.name);\n}\n```\n\n### Delete Share\n\n```typescript\nawait shareClient.delete();\n\n\u002F\u002F Delete if exists\nawait shareClient.deleteIfExists();\n```\n\n### Get Share Properties\n\n```typescript\nconst properties = await shareClient.getProperties();\nconsole.log(\"Quota:\", properties.quota, \"GB\");\nconsole.log(\"Last Modified:\", properties.lastModified);\n```\n\n### Set Share Quota\n\n```typescript\nawait shareClient.setQuota(200); \u002F\u002F 200 GB\n```\n\n## Directory Operations\n\n### Create Directory\n\n```typescript\nconst directoryClient = shareClient.getDirectoryClient(\"my-directory\");\nawait directoryClient.create();\n\n\u002F\u002F Create nested directory\nconst nestedDir = shareClient.getDirectoryClient(\"parent\u002Fchild\u002Fgrandchild\");\nawait nestedDir.create();\n```\n\n### List Directories and Files\n\n```typescript\nconst directoryClient = shareClient.getDirectoryClient(\"my-directory\");\n\nfor await (const item of directoryClient.listFilesAndDirectories()) {\n  if (item.kind === \"directory\") {\n    console.log(`[DIR] ${item.name}`);\n  } else {\n    console.log(`[FILE] ${item.name} (${item.properties.contentLength} bytes)`);\n  }\n}\n```\n\n### Delete Directory\n\n```typescript\nawait directoryClient.delete();\n\n\u002F\u002F Delete if exists\nawait directoryClient.deleteIfExists();\n```\n\n### Check if Directory Exists\n\n```typescript\nconst exists = await directoryClient.exists();\nif (!exists) {\n  await directoryClient.create();\n}\n```\n\n## File Operations\n\n### Upload File (Simple)\n\n```typescript\nconst fileClient = shareClient\n  .getDirectoryClient(\"my-directory\")\n  .getFileClient(\"my-file.txt\");\n\n\u002F\u002F Upload string\nconst content = \"Hello, World!\";\nawait fileClient.create(content.length);\nawait fileClient.uploadRange(content, 0, content.length);\n```\n\n### Upload File (Node.js - from local file)\n\n```typescript\nimport * as fs from \"fs\";\nimport * as path from \"path\";\n\nconst fileClient = shareClient.rootDirectoryClient.getFileClient(\"uploaded.txt\");\nconst localFilePath = \"\u002Fpath\u002Fto\u002Flocal\u002Ffile.txt\";\nconst fileSize = fs.statSync(localFilePath).size;\n\nawait fileClient.create(fileSize);\nawait fileClient.uploadFile(localFilePath);\n```\n\n### Upload File (Buffer)\n\n```typescript\nconst buffer = Buffer.from(\"Hello, Azure Files!\");\nconst fileClient = shareClient.rootDirectoryClient.getFileClient(\"buffer-file.txt\");\n\nawait fileClient.create(buffer.length);\nawait fileClient.uploadRange(buffer, 0, buffer.length);\n```\n\n### Upload File (Stream)\n\n```typescript\nimport * as fs from \"fs\";\n\nconst fileClient = shareClient.rootDirectoryClient.getFileClient(\"streamed.txt\");\nconst readStream = fs.createReadStream(\"\u002Fpath\u002Fto\u002Flocal\u002Ffile.txt\");\nconst fileSize = fs.statSync(\"\u002Fpath\u002Fto\u002Flocal\u002Ffile.txt\").size;\n\nawait fileClient.create(fileSize);\nawait fileClient.uploadStream(readStream, fileSize, 4 * 1024 * 1024, 4); \u002F\u002F 4MB buffer, 4 concurrency\n```\n\n### Download File\n\n```typescript\nconst fileClient = shareClient\n  .getDirectoryClient(\"my-directory\")\n  .getFileClient(\"my-file.txt\");\n\nconst downloadResponse = await fileClient.download();\n\n\u002F\u002F Read as string\nconst chunks: Buffer[] = [];\nfor await (const chunk of downloadResponse.readableStreamBody!) {\n  chunks.push(Buffer.from(chunk));\n}\nconst content = Buffer.concat(chunks).toString(\"utf-8\");\n```\n\n### Download to File (Node.js)\n\n```typescript\nconst fileClient = shareClient.rootDirectoryClient.getFileClient(\"my-file.txt\");\nawait fileClient.downloadToFile(\"\u002Fpath\u002Fto\u002Flocal\u002Fdestination.txt\");\n```\n\n### Download to Buffer (Node.js)\n\n```typescript\nconst fileClient = shareClient.rootDirectoryClient.getFileClient(\"my-file.txt\");\nconst buffer = await fileClient.downloadToBuffer();\nconsole.log(buffer.toString());\n```\n\n### Delete File\n\n```typescript\nconst fileClient = shareClient.rootDirectoryClient.getFileClient(\"my-file.txt\");\nawait fileClient.delete();\n\n\u002F\u002F Delete if exists\nawait fileClient.deleteIfExists();\n```\n\n### Copy File\n\n```typescript\nconst sourceUrl = \"https:\u002F\u002Faccount.file.core.windows.net\u002Fshare\u002Fsource.txt\";\nconst destFileClient = shareClient.rootDirectoryClient.getFileClient(\"destination.txt\");\n\n\u002F\u002F Start copy operation\nconst copyPoller = await destFileClient.startCopyFromURL(sourceUrl);\nawait copyPoller.pollUntilDone();\n```\n\n## File Properties & Metadata\n\n### Get File Properties\n\n```typescript\nconst fileClient = shareClient.rootDirectoryClient.getFileClient(\"my-file.txt\");\nconst properties = await fileClient.getProperties();\n\nconsole.log(\"Content-Length:\", properties.contentLength);\nconsole.log(\"Content-Type:\", properties.contentType);\nconsole.log(\"Last Modified:\", properties.lastModified);\nconsole.log(\"ETag:\", properties.etag);\n```\n\n### Set Metadata\n\n```typescript\nawait fileClient.setMetadata({\n  author: \"John Doe\",\n  category: \"documents\",\n});\n```\n\n### Set HTTP Headers\n\n```typescript\nawait fileClient.setHttpHeaders({\n  fileContentType: \"text\u002Fplain\",\n  fileCacheControl: \"max-age=3600\",\n  fileContentDisposition: \"attachment; filename=download.txt\",\n});\n```\n\n## Range Operations\n\n### Upload Range\n\n```typescript\nconst data = Buffer.from(\"partial content\");\nawait fileClient.uploadRange(data, 100, data.length); \u002F\u002F Write at offset 100\n```\n\n### Download Range\n\n```typescript\nconst downloadResponse = await fileClient.download(100, 50); \u002F\u002F offset 100, length 50\n```\n\n### Clear Range\n\n```typescript\nawait fileClient.clearRange(0, 100); \u002F\u002F Clear first 100 bytes\n```\n\n## Snapshot Operations\n\n### Create Snapshot\n\n```typescript\nconst snapshotResponse = await shareClient.createSnapshot();\nconsole.log(\"Snapshot:\", snapshotResponse.snapshot);\n```\n\n### Access Snapshot\n\n```typescript\nconst snapshotShareClient = shareClient.withSnapshot(snapshotResponse.snapshot!);\nconst snapshotFileClient = snapshotShareClient.rootDirectoryClient.getFileClient(\"file.txt\");\nconst content = await snapshotFileClient.downloadToBuffer();\n```\n\n### Delete Snapshot\n\n```typescript\nawait shareClient.delete({ deleteSnapshots: \"include\" });\n```\n\n## SAS Token Generation (Node.js only)\n\n### Generate File SAS\n\n```typescript\nimport {\n  generateFileSASQueryParameters,\n  FileSASPermissions,\n  StorageSharedKeyCredential,\n} from \"@azure\u002Fstorage-file-share\";\n\nconst sharedKeyCredential = new StorageSharedKeyCredential(accountName, accountKey);\n\nconst sasToken = generateFileSASQueryParameters(\n  {\n    shareName: \"my-share\",\n    filePath: \"my-directory\u002Fmy-file.txt\",\n    permissions: FileSASPermissions.parse(\"r\"), \u002F\u002F read only\n    expiresOn: new Date(Date.now() + 3600 * 1000), \u002F\u002F 1 hour\n  },\n  sharedKeyCredential\n).toString();\n\nconst sasUrl = `https:\u002F\u002F${accountName}.file.core.windows.net\u002Fmy-share\u002Fmy-directory\u002Fmy-file.txt?${sasToken}`;\n```\n\n### Generate Share SAS\n\n```typescript\nimport { ShareSASPermissions, generateFileSASQueryParameters } from \"@azure\u002Fstorage-file-share\";\n\nconst sasToken = generateFileSASQueryParameters(\n  {\n    shareName: \"my-share\",\n    permissions: ShareSASPermissions.parse(\"rcwdl\"), \u002F\u002F read, create, write, delete, list\n    expiresOn: new Date(Date.now() + 24 * 3600 * 1000), \u002F\u002F 24 hours\n  },\n  sharedKeyCredential\n).toString();\n```\n\n## Error Handling\n\n```typescript\nimport { RestError } from \"@azure\u002Fstorage-file-share\";\n\ntry {\n  await shareClient.create();\n} catch (error) {\n  if (error instanceof RestError) {\n    switch (error.statusCode) {\n      case 404:\n        console.log(\"Share not found\");\n        break;\n      case 409:\n        console.log(\"Share already exists\");\n        break;\n      case 403:\n        console.log(\"Access denied\");\n        break;\n      default:\n        console.error(`Storage error ${error.statusCode}: ${error.message}`);\n    }\n  }\n  throw error;\n}\n```\n\n## TypeScript Types Reference\n\n```typescript\nimport {\n  \u002F\u002F Clients\n  ShareServiceClient,\n  ShareClient,\n  ShareDirectoryClient,\n  ShareFileClient,\n\n  \u002F\u002F Authentication\n  StorageSharedKeyCredential,\n  AnonymousCredential,\n\n  \u002F\u002F SAS\n  FileSASPermissions,\n  ShareSASPermissions,\n  AccountSASPermissions,\n  AccountSASServices,\n  AccountSASResourceTypes,\n  generateFileSASQueryParameters,\n  generateAccountSASQueryParameters,\n\n  \u002F\u002F Options & Responses\n  ShareCreateResponse,\n  FileDownloadResponseModel,\n  DirectoryItem,\n  FileItem,\n  ShareProperties,\n  FileProperties,\n\n  \u002F\u002F Errors\n  RestError,\n} from \"@azure\u002Fstorage-file-share\";\n```\n\n## Best Practices\n\n1. **Use connection strings for simplicity** — Easiest setup for development\n2. **Use DefaultAzureCredential for production** — Enable managed identity in Azure\n3. **Set quotas on shares** — Prevent unexpected storage costs\n4. **Use streaming for large files** — `uploadStream`\u002F`downloadToFile` for files > 256MB\n5. **Use ranges for partial updates** — More efficient than full file replacement\n6. **Create snapshots before major changes** — Point-in-time recovery\n7. **Handle errors gracefully** — Check `RestError.statusCode` for specific handling\n8. **Use `*IfExists` methods** — For idempotent operations\n\n## Platform Differences\n\n| Feature | Node.js | Browser |\n|---------|---------|---------|\n| `StorageSharedKeyCredential` | ✅ | ❌ |\n| `uploadFile()` | ✅ | ❌ |\n| `uploadStream()` | ✅ | ❌ |\n| `downloadToFile()` | ✅ | ❌ |\n| `downloadToBuffer()` | ✅ | ❌ |\n| SAS generation | ✅ | ❌ |\n| DefaultAzureCredential | ✅ | ❌ |\n| Anonymous\u002FSAS access | ✅ | ✅ |\n\n## When to Use\nThis skill is applicable to execute the workflow or actions described in the overview.\n","# @azure\u002Fstorage-file-share (TypeScript\u002FJavaScript)\n\nSDK for Azure File Share operations — SMB file shares, directories, and file operations.\n\n## Installation\n\n```bash\nnpm install @azure\u002Fstorage-file-share @azure\u002Fidentity\n```\n\n**Current Version**: 12.x  \n**Node.js**: >= 18.0.0\n\n## Environment Variables\n\n```bash\nAZURE_STORAGE_ACCOUNT_NAME=\u003Caccount-name>\nAZURE_STORAGE_ACCOUNT_KEY=\u003Caccount-key>\n# OR connection string\nAZURE_STORAGE_CONNECTION_STRING=DefaultEndpointsProtocol=https;AccountName=...\n```\n\n## Authentication\n\n### Connection String (Simplest)\n\n```typescript\nimport { ShareServiceClient } from \"@azure\u002Fstorage-file-share\";\n\nconst client = ShareServiceClient.fromConnectionString(\n  process.env.AZURE_STORAGE_CONNECTION_STRING!\n);\n```\n\n### StorageSharedKeyCredential (Node.js only)\n\n```typescript\nimport { ShareServiceClient, StorageSharedKeyCredential } from \"@azure\u002Fstorage-file-share\";\n\nconst accountName = process.env.AZURE_STORAGE_ACCOUNT_NAME!;\nconst accountKey = process.env.AZURE_STORAGE_ACCOUNT_KEY!;\n\nconst sharedKeyCredential = new StorageSharedKeyCredential(accountName, accountKey);\nconst client = new ShareServiceClient(\n  `https:\u002F\u002F${accountName}.file.core.windows.net`,\n  sharedKeyCredential\n);\n```\n\n### DefaultAzureCredential\n\n```typescript\nimport { ShareServiceClient } from \"@azure\u002Fstorage-file-share\";\nimport { DefaultAzureCredential } from \"@azure\u002Fidentity\";\n\nconst accountName = process.env.AZURE_STORAGE_ACCOUNT_NAME!;\nconst client = new ShareServiceClient(\n  `https:\u002F\u002F${accountName}.file.core.windows.net`,\n  new DefaultAzureCredential()\n);\n```\n\n### SAS Token\n\n```typescript\nimport { ShareServiceClient } from \"@azure\u002Fstorage-file-share\";\n\nconst accountName = process.env.AZURE_STORAGE_ACCOUNT_NAME!;\nconst sasToken = process.env.AZURE_STORAGE_SAS_TOKEN!;\n\nconst client = new ShareServiceClient(\n  `https:\u002F\u002F${accountName}.file.core.windows.net${sasToken}`\n);\n```\n\n## Client Hierarchy\n\n```\nShareServiceClient (account level)\n└── ShareClient (share level)\n    └── ShareDirectoryClient (directory level)\n        └── ShareFileClient (file level)\n```\n\n## Share Operations\n\n### Create Share\n\n```typescript\nconst shareClient = client.getShareClient(\"my-share\");\nawait shareClient.create();\n\n\u002F\u002F Create with quota (in GB)\nawait shareClient.create({ quota: 100 });\n```\n\n### List Shares\n\n```typescript\nfor await (const share of client.listShares()) {\n  console.log(share.name, share.properties.quota);\n}\n\n\u002F\u002F With prefix filter\nfor await (const share of client.listShares({ prefix: \"logs-\" })) {\n  console.log(share.name);\n}\n```\n\n### Delete Share\n\n```typescript\nawait shareClient.delete();\n\n\u002F\u002F Delete if exists\nawait shareClient.deleteIfExists();\n```\n\n### Get Share Properties\n\n```typescript\nconst properties = await shareClient.getProperties();\nconsole.log(\"Quota:\", properties.quota, \"GB\");\nconsole.log(\"Last Modified:\", properties.lastModified);\n```\n\n### Set Share Quota\n\n```typescript\nawait shareClient.setQuota(200); \u002F\u002F 200 GB\n```\n\n## Directory Operations\n\n### Create Directory\n\n```typescript\nconst directoryClient = shareClient.getDirectoryClient(\"my-directory\");\nawait directoryClient.create();\n\n\u002F\u002F Create nested directory\nconst nestedDir = shareClient.getDirectoryClient(\"parent\u002Fchild\u002Fgrandchild\");\nawait nestedDir.create();\n```\n\n### List Directories and Files\n\n```typescript\nconst directoryClient = shareClient.getDirectoryClient(\"my-directory\");\n\nfor await (const item of directoryClient.listFilesAndDirectories()) {\n  if (item.kind === \"directory\") {\n    console.log(`[DIR] ${item.name}`);\n  } else {\n    console.log(`[FILE] ${item.name} (${item.properties.contentLength} bytes)`);\n  }\n}\n```\n\n### Delete Directory\n\n```typescript\nawait directoryClient.delete();\n\n\u002F\u002F Delete if exists\nawait directoryClient.deleteIfExists();\n```\n\n### Check if Directory Exists\n\n```typescript\nconst exists = await directoryClient.exists();\nif (!exists) {\n  await directoryClient.create();\n}\n```\n\n## File Operations\n\n### Upload File (Simple)\n\n```typescript\nconst fileClient = shareClient\n  .getDirectoryClient(\"my-directory\")\n  .getFileClient(\"my-file.txt\");\n\n\u002F\u002F Upload string\nconst content = \"Hello, World!\";\nawait fileClient.create(content.length);\nawait fileClient.uploadRange(content, 0, content.length);\n```\n\n### Upload File (Node.js - from local file)\n\n```typescript\nimport * as fs from \"fs\";\nimport * as path from \"path\";\n\nconst fileClient = shareClient.rootDirectoryClient.getFileClient(\"uploaded.txt\");\nconst localFilePath = \"\u002Fpath\u002Fto\u002Flocal\u002Ffile.txt\";\nconst fileSize = fs.statSync(localFilePath).size;\n\nawait fileClient.create(fileSize);\nawait fileClient.uploadFile(localFilePath);\n```\n\n### Upload File (Buffer)\n\n```typescript\nconst buffer = Buffer.from(\"Hello, Azure Files!\");\nconst fileClient = shareClient.rootDirectoryClient.getFileClient(\"buffer-file.txt\");\n\nawait fileClient.create(buffer.length);\nawait fileClient.uploadRange(buffer, 0, buffer.length);\n```\n\n### Upload File (Stream)\n\n```typescript\nimport * as fs from \"fs\";\n\nconst fileClient = shareClient.rootDirectoryClient.getFileClient(\"streamed.txt\");\nconst readStream = fs.createReadStream(\"\u002Fpath\u002Fto\u002Flocal\u002Ffile.txt\");\nconst fileSize = fs.statSync(\"\u002Fpath\u002Fto\u002Flocal\u002Ffile.txt\").size;\n\nawait fileClient.create(fileSize);\nawait fileClient.uploadStream(readStream, fileSize, 4 * 1024 * 1024, 4); \u002F\u002F 4MB buffer, 4 concurrency\n```\n\n### Download File\n\n```typescript\nconst fileClient = shareClient\n  .getDirectoryClient(\"my-directory\")\n  .getFileClient(\"my-file.txt\");\n\nconst downloadResponse = await fileClient.download();\n\n\u002F\u002F Read as string\nconst chunks: Buffer[] = [];\nfor await (const chunk of downloadResponse.readableStreamBody!) {\n  chunks.push(Buffer.from(chunk));\n}\nconst content = Buffer.concat(chunks).toString(\"utf-8\");\n```\n\n### Download to File (Node.js)\n\n```typescript\nconst fileClient = shareClient.rootDirectoryClient.getFileClient(\"my-file.txt\");\nawait fileClient.downloadToFile(\"\u002Fpath\u002Fto\u002Flocal\u002Fdestination.txt\");\n```\n\n### Download to Buffer (Node.js)\n\n```typescript\nconst fileClient = shareClient.rootDirectoryClient.getFileClient(\"my-file.txt\");\nconst buffer = await fileClient.downloadToBuffer();\nconsole.log(buffer.toString());\n```\n\n### Delete File\n\n```typescript\nconst fileClient = shareClient.rootDirectoryClient.getFileClient(\"my-file.txt\");\nawait fileClient.delete();\n\n\u002F\u002F Delete if exists\nawait fileClient.deleteIfExists();\n```\n\n### Copy File\n\n```typescript\nconst sourceUrl = \"https:\u002F\u002Faccount.file.core.windows.net\u002Fshare\u002Fsource.txt\";\nconst destFileClient = shareClient.rootDirectoryClient.getFileClient(\"destination.txt\");\n\n\u002F\u002F Start copy operation\nconst copyPoller = await destFileClient.startCopyFromURL(sourceUrl);\nawait copyPoller.pollUntilDone();\n```\n\n## File Properties & Metadata\n\n### Get File Properties\n\n```typescript\nconst fileClient = shareClient.rootDirectoryClient.getFileClient(\"my-file.txt\");\nconst properties = await fileClient.getProperties();\n\nconsole.log(\"Content-Length:\", properties.contentLength);\nconsole.log(\"Content-Type:\", properties.contentType);\nconsole.log(\"Last Modified:\", properties.lastModified);\nconsole.log(\"ETag:\", properties.etag);\n```\n\n### Set Metadata\n\n```typescript\nawait fileClient.setMetadata({\n  author: \"John Doe\",\n  category: \"documents\",\n});\n```\n\n### Set HTTP Headers\n\n```typescript\nawait fileClient.setHttpHeaders({\n  fileContentType: \"text\u002Fplain\",\n  fileCacheControl: \"max-age=3600\",\n  fileContentDisposition: \"attachment; filename=download.txt\",\n});\n```\n\n## Range Operations\n\n### Upload Range\n\n```typescript\nconst data = Buffer.from(\"partial content\");\nawait fileClient.uploadRange(data, 100, data.length); \u002F\u002F Write at offset 100\n```\n\n### Download Range\n\n```typescript\nconst downloadResponse = await fileClient.download(100, 50); \u002F\u002F offset 100, length 50\n```\n\n### Clear Range\n\n```typescript\nawait fileClient.clearRange(0, 100); \u002F\u002F Clear first 100 bytes\n```\n\n## Snapshot Operations\n\n### Create Snapshot\n\n```typescript\nconst snapshotResponse = await shareClient.createSnapshot();\nconsole.log(\"Snapshot:\", snapshotResponse.snapshot);\n```\n\n### Access Snapshot\n\n```typescript\nconst snapshotShareClient = shareClient.withSnapshot(snapshotResponse.snapshot!);\nconst snapshotFileClient = snapshotShareClient.rootDirectoryClient.getFileClient(\"file.txt\");\nconst content = await snapshotFileClient.downloadToBuffer();\n```\n\n### Delete Snapshot\n\n```typescript\nawait shareClient.delete({ deleteSnapshots: \"include\" });\n```\n\n## SAS Token Generation (Node.js only)\n\n### Generate File SAS\n\n```typescript\nimport {\n  generateFileSASQueryParameters,\n  FileSASPermissions,\n  StorageSharedKeyCredential,\n} from \"@azure\u002Fstorage-file-share\";\n\nconst sharedKeyCredential = new StorageSharedKeyCredential(accountName, accountKey);\n\nconst sasToken = generateFileSASQueryParameters(\n  {\n    shareName: \"my-share\",\n    filePath: \"my-directory\u002Fmy-file.txt\",\n    permissions: FileSASPermissions.parse(\"r\"), \u002F\u002F read only\n    expiresOn: new Date(Date.now() + 3600 * 1000), \u002F\u002F 1 hour\n  },\n  sharedKeyCredential\n).toString();\n\nconst sasUrl = `https:\u002F\u002F${accountName}.file.core.windows.net\u002Fmy-share\u002Fmy-directory\u002Fmy-file.txt?${sasToken}`;\n```\n\n### Generate Share SAS\n\n```typescript\nimport { ShareSASPermissions, generateFileSASQueryParameters } from \"@azure\u002Fstorage-file-share\";\n\nconst sasToken = generateFileSASQueryParameters(\n  {\n    shareName: \"my-share\",\n    permissions: ShareSASPermissions.parse(\"rcwdl\"), \u002F\u002F read, create, write, delete, list\n    expiresOn: new Date(Date.now() + 24 * 3600 * 1000), \u002F\u002F 24 hours\n  },\n  sharedKeyCredential\n).toString();\n```\n\n## Error Handling\n\n```typescript\nimport { RestError } from \"@azure\u002Fstorage-file-share\";\n\ntry {\n  await shareClient.create();\n} catch (error) {\n  if (error instanceof RestError) {\n    switch (error.statusCode) {\n      case 404:\n        console.log(\"Share not found\");\n        break;\n      case 409:\n        console.log(\"Share already exists\");\n        break;\n      case 403:\n        console.log(\"Access denied\");\n        break;\n      default:\n        console.error(`Storage error ${error.statusCode}: ${error.message}`);\n    }\n  }\n  throw error;\n}\n```\n\n## TypeScript Types Reference\n\n```typescript\nimport {\n  \u002F\u002F Clients\n  ShareServiceClient,\n  ShareClient,\n  ShareDirectoryClient,\n  ShareFileClient,\n\n  \u002F\u002F Authentication\n  StorageSharedKeyCredential,\n  AnonymousCredential,\n\n  \u002F\u002F SAS\n  FileSASPermissions,\n  ShareSASPermissions,\n  AccountSASPermissions,\n  AccountSASServices,\n  AccountSASResourceTypes,\n  generateFileSASQueryParameters,\n  generateAccountSASQueryParameters,\n\n  \u002F\u002F Options & Responses\n  ShareCreateResponse,\n  FileDownloadResponseModel,\n  DirectoryItem,\n  FileItem,\n  ShareProperties,\n  FileProperties,\n\n  \u002F\u002F Errors\n  RestError,\n} from \"@azure\u002Fstorage-file-share\";\n```\n\n## Best Practices\n\n1. **Use connection strings for simplicity** — Easiest setup for development\n2. **Use DefaultAzureCredential for production** — Enable managed identity in Azure\n3. **Set quotas on shares** — Prevent unexpected storage costs\n4. **Use streaming for large files** — `uploadStream`\u002F`downloadToFile` for files > 256MB\n5. **Use ranges for partial updates** — More efficient than full file replacement\n6. **Create snapshots before major changes** — Point-in-time recovery\n7. **Handle errors gracefully** — Check `RestError.statusCode` for specific handling\n8. **Use `*IfExists` methods** — For idempotent operations\n\n## Platform Differences\n\n| Feature | Node.js | Browser |\n|---------|---------|---------|\n| `StorageSharedKeyCredential` | ✅ | ❌ |\n| `uploadFile()` | ✅ | ❌ |\n| `uploadStream()` | ✅ | ❌ |\n| `downloadToFile()` | ✅ | ❌ |\n| `downloadToBuffer()` | ✅ | ❌ |\n| SAS generation | ✅ | ❌ |\n| DefaultAzureCredential | ✅ | ❌ |\n| Anonymous\u002FSAS access | ✅ | ✅ |\n\n## When to Use\nThis skill is applicable to execute the workflow or actions described in the overview.\n",{},"release\u002Fv4.2.11-panel-pro","a92ea02bcf7e2b3dbaf46d49696c29a3cb490d4f",".github\u002Fskills\u002Fazure-storage-file-share-ts","https:\u002F\u002Fgithub.com\u002Fjaviertarazon\u002Fide-agente-free-jt7-","https:\u002F\u002Fgithub.com\u002Fjaviertarazon","2026-07-12 07:10:45",{"source":7,"skillName":5,"commands":36,"prompt":46,"zipAvailable":47},[37,40,43],{"tool":38,"command":39},"npx","npx skills add javiertarazon\u002Fide-agente-free-jt7- --skill azure-storage-file-share-ts",{"tool":41,"command":42},"bunx","bunx skills add javiertarazon\u002Fide-agente-free-jt7- --skill azure-storage-file-share-ts",{"tool":44,"command":45},"pnpm","pnpm dlx skills add javiertarazon\u002Fide-agente-free-jt7- --skill azure-storage-file-share-ts","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fjaviertarazon\u002Fide-agente-free-jt7-\u002Fblob\u002Frelease\u002Fv4.2.11-panel-pro\u002F.github\u002Fskills\u002Fazure-storage-file-share-ts\u002FSKILL.md",true,[],[50,82,109,129,144,166],{"skillNo":51,"name":52,"nameZh":6,"description":53,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":6,"repositoryNo":11,"starsCount":12,"licenseSpdxId":13,"licenseFileUrl":6,"sourceHtmlUrl":54,"categories":55,"keywords":61,"publishedAt":24},"01M71TQ7Q6Z10VWF3C2H5X1KW9","zustand-store-ts","Create Zustand stores with TypeScript, subscribeWithSelector middleware, and proper state\u002Faction separation. Use when building React state management, creating global stores, or implementing reacti...","https:\u002F\u002Fgithub.com\u002Fjaviertarazon\u002Fide-agente-free-jt7-\u002Fblob\u002Frelease\u002Fv4.2.11-panel-pro\u002F.github\u002Fskills\u002Fzustand-store-ts\u002FSKILL.md",[56],{"categoryNo":57,"categoryName":58,"taxonomyType":59,"taxonomyTypeDesc":60},"01JBSEEDCAT000000000000009","前端开发","SCENARIO","使用场景",[62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81],"zustand","store","zustand store ts","community","middleware","implementing","use","react state management","when","unknown","react","with","state","create","state management","typescript","action","management","separation","global",{"skillNo":83,"name":84,"nameZh":6,"description":85,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":6,"repositoryNo":11,"starsCount":12,"licenseSpdxId":13,"licenseFileUrl":6,"sourceHtmlUrl":86,"categories":87,"keywords":91,"publishedAt":24},"01M71TQ5EAR40G6W0MV5ZDVEZT","zoom-automation","Automate Zoom meeting creation, management, recordings, webinars, and participant tracking via Rube MCP (Composio). Always search tools first for current schemas.","https:\u002F\u002Fgithub.com\u002Fjaviertarazon\u002Fide-agente-free-jt7-\u002Fblob\u002Frelease\u002Fv4.2.11-panel-pro\u002F.github\u002Fskills\u002Fzoom-automation\u002FSKILL.md",[88],{"categoryNo":89,"categoryName":90,"taxonomyType":59,"taxonomyTypeDesc":60},"01JBSEEDCAT000000000000023","Skill与智能体开发",[92,93,94,65,95,96,97,98,99,71,100,101,102,103,104,105,106,107,79,108],"zoom automation","zoom","automation","creation","for","search","schemas","MCP","first","via","meeting","search tools","tracking","webinars","composio","recordings","Tools",{"skillNo":110,"name":111,"nameZh":6,"description":112,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":6,"repositoryNo":11,"starsCount":12,"licenseSpdxId":13,"licenseFileUrl":6,"sourceHtmlUrl":113,"categories":114,"keywords":116,"publishedAt":24},"01M71TQ29B1EYBCEAP1ZBGXQ1A","zoho-crm-automation","Automate Zoho CRM tasks via Rube MCP (Composio): create\u002Fupdate records, search contacts, manage leads, and convert leads. Always search tools first for current schemas.","https:\u002F\u002Fgithub.com\u002Fjaviertarazon\u002Fide-agente-free-jt7-\u002Fblob\u002Frelease\u002Fv4.2.11-panel-pro\u002F.github\u002Fskills\u002Fzoho-crm-automation\u002FSKILL.md",[115],{"categoryNo":89,"categoryName":90,"taxonomyType":59,"taxonomyTypeDesc":60},[117,118,94,119,120,121,65,122,123,96,124,97,98,125,99,71,126,127,128,75],"crm automation","zoho crm automation","crm","zoho crm","zoho","leads","manage leads","manage","records","convert","tasks","contacts",{"skillNo":130,"name":131,"nameZh":6,"description":132,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":6,"repositoryNo":11,"starsCount":12,"licenseSpdxId":13,"licenseFileUrl":6,"sourceHtmlUrl":133,"categories":134,"keywords":136,"publishedAt":24},"01M71TPZPMN60DH0XV58KVHY23","zendesk-automation","Automate Zendesk tasks via Rube MCP (Composio): tickets, users, organizations, replies. Always search tools first for current schemas.","https:\u002F\u002Fgithub.com\u002Fjaviertarazon\u002Fide-agente-free-jt7-\u002Fblob\u002Frelease\u002Fv4.2.11-panel-pro\u002F.github\u002Fskills\u002Fzendesk-automation\u002FSKILL.md",[135],{"categoryNo":89,"categoryName":90,"taxonomyType":59,"taxonomyTypeDesc":60},[137,94,138,65,96,97,98,99,139,71,127,140,141,100,101,142,103,106,108,143],"zendesk automation","zendesk","organizations","replies","users","tickets","automate",{"skillNo":145,"name":146,"nameZh":6,"description":147,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":6,"repositoryNo":11,"starsCount":12,"licenseSpdxId":13,"licenseFileUrl":6,"sourceHtmlUrl":148,"categories":149,"keywords":150,"publishedAt":24},"01M71TPXDWKHKG4N6TVEPXWD0N","zapier-make-patterns","No-code automation democratizes workflow building. Zapier and Make (formerly Integromat) let non-developers automate business processes without writing code. But no-code doesn't mean no-complexity ...","https:\u002F\u002Fgithub.com\u002Fjaviertarazon\u002Fide-agente-free-jt7-\u002Fblob\u002Frelease\u002Fv4.2.11-panel-pro\u002F.github\u002Fskills\u002Fzapier-make-patterns\u002FSKILL.md",[],[151,152,153,154,155,156,157,158,159,94,160,71,161,162,163,164,165,143],"zapier make patterns","zapier","patterns","make","No-Code","complexity","writing","spawner","business","workflow","code","integromat","apache","processes","but",{"skillNo":167,"name":168,"nameZh":6,"description":169,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":6,"repositoryNo":11,"starsCount":12,"licenseSpdxId":13,"licenseFileUrl":6,"sourceHtmlUrl":170,"categories":171,"keywords":175,"publishedAt":24},"01M71TPT5T10WXNKW9G7ZXZ27W","youtube-summarizer","Extract transcripts from YouTube videos and generate comprehensive, detailed summaries using intelligent analysis frameworks","https:\u002F\u002Fgithub.com\u002Fjaviertarazon\u002Fide-agente-free-jt7-\u002Fblob\u002Frelease\u002Fv4.2.11-panel-pro\u002F.github\u002Fskills\u002Fyoutube-summarizer\u002FSKILL.md",[172],{"categoryNo":173,"categoryName":174,"taxonomyType":59,"taxonomyTypeDesc":60},"01JBSEEDCAT000000000000016","图像与多媒体",[176,177,178,179,65,180,181,182,183,184,185,186,161,187,188,189,190,191,192,193],"summarizer","youtube","youtube summarizer","Video","content-analysis","frameworks","copilot","2025","github-copilot","extract transcripts","analysis","codex","cli","summaries","github","generate","summarization","2026"]