File methods, browser sessions serve 0, phone sessions 0 and computer sessions 6. A method marked not served answers StrategyUnavailable on that kind of session; check the handshake’s capabilities before relying on one.
File.read
Browser: not served
Phone: not served
Computer: served
A file’s content, base64, at most x-dcp-computer-limits.fileMaxBytes. Computer sessions only.
| Param | Type | Required | Description |
|---|---|---|---|
path | string | Yes | Absolute, may use environment variables (%USERPROFILE%); a relative path is taken from the user’s home folder. |
idempotencyKey | string | No | Makes a re-send after a reconnect safe: a repeated key returns the recorded response without acting again. See Idempotency keys. |
| Field | Type | Description |
|---|---|---|
path | string | |
contentBase64 | string | |
size | integer |
File.write
Browser: not served
Phone: not served
Computer: served
Write a file from base64 content, creating its folders, replacing it unless append. C:\ax is read-only apart from C:\ax\downloads. Computer sessions only.
| Param | Type | Required | Description |
|---|---|---|---|
path | string | Yes | |
contentBase64 | string | Yes | |
append | boolean | No | |
idempotencyKey | string | No | Makes a re-send after a reconnect safe: a repeated key returns the recorded response without acting again. See Idempotency keys. |
| Field | Type | Description |
|---|---|---|
name | string | |
path | string | |
isDir | boolean | |
size | integer | |
modifiedMs | integer |
File.list
Browser: not served
Phone: not served
Computer: served
A folder’s entries, at most 10000. Computer sessions only.
| Param | Type | Required | Description |
|---|---|---|---|
path | string | Yes | Absolute, may use environment variables (%USERPROFILE%); a relative path is taken from the user’s home folder. |
idempotencyKey | string | No | Makes a re-send after a reconnect safe: a repeated key returns the recorded response without acting again. See Idempotency keys. |
| Field | Type | Description |
|---|---|---|
path | string | |
entries | FileInfo[] | |
truncated | boolean |
File.stat
Browser: not served
Phone: not served
Computer: served
One file’s or folder’s details. Computer sessions only.
| Param | Type | Required | Description |
|---|---|---|---|
path | string | Yes | Absolute, may use environment variables (%USERPROFILE%); a relative path is taken from the user’s home folder. |
idempotencyKey | string | No | Makes a re-send after a reconnect safe: a repeated key returns the recorded response without acting again. See Idempotency keys. |
| Field | Type | Description |
|---|---|---|
name | string | |
path | string | |
isDir | boolean | |
size | integer | |
modifiedMs | integer |
File.mkdir
Browser: not served
Phone: not served
Computer: served
Create a folder and its parents. Computer sessions only.
| Param | Type | Required | Description |
|---|---|---|---|
path | string | Yes | Absolute, may use environment variables (%USERPROFILE%); a relative path is taken from the user’s home folder. |
idempotencyKey | string | No | Makes a re-send after a reconnect safe: a repeated key returns the recorded response without acting again. See Idempotency keys. |
| Field | Type | Description |
|---|---|---|
name | string | |
path | string | |
isDir | boolean | |
size | integer | |
modifiedMs | integer |
File.delete
Browser: not served
Phone: not served
Computer: served
Delete a file, or a folder (recursive for one that isn’t empty). Computer sessions only.
| Param | Type | Required | Description |
|---|---|---|---|
path | string | Yes | |
recursive | boolean | No | |
idempotencyKey | string | No | Makes a re-send after a reconnect safe: a repeated key returns the recorded response without acting again. See Idempotency keys. |
{}.