API/Account commands

From DreamHost
Jump to: navigation, search

Contents

Account API commands

The account API module contains commands for checking status or usage of your account.

Commands

account-domain_usage

Lists bandwidth usage for all visible domain services. Bandwidth usage is in bytes since the beginning of the current billing cycle (which can be determined using account-status).

Values:

(none)

Result:

success
domain	type	bw
example.com	http	1048576

Possible Errors:

(none)

account-list_keys

Lists all SSH public keys on this account. SSH keys may be used to provide root access to any of your VPS or Dedicated Servers (see API/Dreamhost_ps_commands).

Values:

(none)

Result:

success
key_name	key_val
Test	ssh-rsa ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz/+..........== Dreamhost Managed Key

Possible Errors:

(none)

account-status

Returns the status of the current account. All results of this function should be treated as advisory only.

Values:

(none)

Result:

success
key	value
balance	-10.00	
delinquent	0	
delinquent_date	2009-10-02	
due	0	
lastrebill_date	2009-12-02	
nextrebill_date	2010-01-02	
past_due	0	
pastdue_date	2009-11-02	
today	2009-12-23

Possible Errors:

(none)

account-user_usage

Lists disk and bandwidth usage for all visible users. Disk usage is in kilobytes; bandwidth usage is in bytes since the start of the billing cycle (see account-status to determine when that is). In most cases, bandwidth usage will appear as zero here -- see account-domain_usage for domain bandwidth.

Values:

(none)

Result:

success
user	disk	disk_as_of	bw
username	4700.56	2009-12-22	9.412

Possible Errors:

(none)
Personal tools