Boffin Codersts-netstorageapi-akamaiby Boffin Coders

Browse

du GET

Show the number of files and bytes used under a directory.

const { du } = await ns.duAsync("/123456");
console.log(du["du-info"][0].files, du["du-info"][0].bytes);

Signatures

duAsync(ns_path: string): Promise<DuResponse>
du(ns_path: string, callback: (err: any, res?: http.IncomingMessage, body?: DuResponse) => void): void

Parameters

NameTypeDescription
ns_pathstringNetStorage directory path.

Returns

DuResponse

{ du: { attribs: { directory }, "du-info": [{ files, bytes }] } }

On the wire

HTTP methodGET
X-Akamai-ACS-Actionversion=1&action=du&format=xml
Signed withX-Akamai-ACS-Auth-Data and X-Akamai-ACS-Auth-Sign (HMAC-SHA256)
CLIakamai-netstorage du static

Build and sign this request in the playground →

← liststat →