StorageGRID Webscale supports several Swift API endpoint types.
These Swift API endpoints are:
The capabilities and limitations of the StorageGRID Webscale Swift implementation can be queried through the Swift info URL. You obtain this information by issuing a GET request to the StorageGRID Webscale Swift base URL with the /info path.
https://FQDN | IP:Swift_Port/info/
The StorageGRID Webscale implementation of Swift allows unauthenticated access to the info URL.
A GET request to the info URL yields the capabilities of the Swift implementation as a JSON dictionary. A client tool can parse the returned JSON response to determine the capabilities of the implementation and employ them as constraints for subsequent storage operations.
A client can authenticate a tenant user and procure a Swift token from the Swift auth URL. A successful authentication request yields a token and a storage URL, which are required for access on a StorageGRID Webscale CLB service on the Gateway Node or LDR service on a Storage Node.
https://FQDN | IP:Swift_Port/auth/v1.0/
The credentials include the user name and password as parameters and must be provided using request headers as follows:
X-Auth-User : Tenant_Account_ID:Username
X-Auth-Key : Password
The Swift tenant account information is used in the authentication process and consists of one of the following:
A valid user name and password combination yields a valid token and storage URL through response headers as shown in the following:
X-Storage-Url : https://FQDN | IP:Swift_Port/v1/Tenant_Account_ID X-Auth-Token : token X-Storage-Token : token
By default, the token is valid for 24 hours from generation time.
Tokens are generated for a specific tenant account. A valid token for one account does not authorize a user to access another account.
A client application can issue Swift REST API calls to perform supported account, container, and object operations against a CLB service on the Gateway Node or LDR service on a Storage Node. Storage requests can be addressed to the URL that is returned by the auth request in the X-Storage-Url response header. The request must include the X-Auth-Token header and value returned from the auth request.
https://FQDN | IP:Swift_Port/v1/ Tenant_Account_ID[/container][/object]
Because StorageGRID Webscale uses an eventually-consistent data model, some storage response headers that contain usage statistics might not reflect accurate numbers for recently modified objects. It might take a few minutes for accurate numbers to appear in these headers.
The following response headers are examples of those that contain usage statistics:
For details about responses, see information about account, container, and object operations.