Blame view

sources/3rdparty/rackspace/php-opencloud/docs/userguide/ObjectStore/Account.md 623 Bytes
6d9380f96   Cédric Dupont   Update sources OC...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
  ## Setup
  
  ```php
  use OpenCloud\Rackspace;
  
  $client = new Rackspace(RACKSPACE_US, array(
  
  ));
  
  $service = $client->objectStoreService('cloudFiles');
  ```
  
  ## View Account Details
  
  To see how many containers you have in your account (X-Account-Container-Count), how many objects are in your account
  (X-Account-Object-Count), and how many total bytes your account uses (X-Account-Bytes-Used):
  
  ```php
  $account = $service->getAccount();
  
  // Either return the full Metadata object
  $details = $account->getDetails();
  
  // or individual values
  $account->getContainerCount();
  $account->getObjectCount();
  $account->getBytesUsed();
  ```