public. Delete file attachment
| Name | Type | Description |
| filename | string | "=" followed by a double uri-encoded file name |
| pageid | string | either an integer page ID, "home", or "=" followed by a double uri-encoded page title |
| Name | Type | Description |
| authenticate | bool? | Force authentication for request (default: false) |
| redirects | int? | If zero, do not follow page redirects (only applies when {pageid} is present). |
| Name | Value | Description |
| BadRequest | 400 | Invalid input parameter or request body |
| Forbidden | 403 | Update access to the page is required |
| NotFound | 404 | The requested file could not be found |
| Ok | 200 | The request completed successfully |
None
When a file is deleted, it is moved into the archive. It will remain in the archive until it is either permanently deleted (DELETE:archive/files/{fileid}) or restored (POST:archive/files/restore/{fileid}).
Use GET:files to retrieve a list of files across the site or GET:pages/{pageid}/files to retrieve the files on a specified page.
The following code example deletes myfile.jpg from the home page:
Plug p = Plug.New("http://deki-hayes/@api/deki");
p.At("users", "authenticate").WithCredentials("admin", "password").Get();
p.At("pages", "home", "files", "=myfile%252ejpg").Delete();