To list the containers in an account, send a GET request to the account.
To send REST API calls to Object Storage Classic, you need a valid authentication token. If you obtained a token less than 30 minutes ago, then you can use that token. Otherwise, get a new token as described in Get an Authentication Token.
Send a GET call to the account. Specify the authentication token in the X-Auth-Token header.
Syntax
curl -X GET \
{accountRestEndpointURL} \
-H 'x-auth-token: {authToken}'
Sample Command
curl -X GET \
https://myaccount.ocm.rack01.example.com/v1/Storage-myaccount \
-H 'x-auth-token: AUTH_tk10d7cf10041726fa2e64652d975bbab0'
The output is a list of the containers in the account.