Supported Http Methods; General Uri Format; System Access; Creating Credentials - HP 3PAR StoreServ 7200 2-node Manual

Hp 3par web service api 1.2 developer's guide (qr482-96192, june 2013)
Hide thumbs Also See for 3PAR StoreServ 7200 2-node:
Table of Contents

Advertisement

Supported HTTP Methods

This section summarizes the HTTP methods currently supported by the HP 3PAR WSAPI. These
include:
GET
The HTTP GET method retrieves information identified by the request-URI.
POST
The HTTP POST method requests that an object described by the body of the request
be created in the collection identified by the URI.
PUT
The HTTP PUT method requests that an entity identified by the Request-URI be modified.
DELETE
The HTTP DELETE method requests that the server delete the resource identified by the
request URI.

General URI Format

All operations of the API are performed using an HTTP method (GET, POST, PUT, or DELETE) and
a Uniform Resource Identifier (URI). In this example, the URI corresponds to the volume named
projectXvol residing on the HP 3PAR storage system with the hostname
storsys1.example.com:
https://storsys1.example.com:8080/api/v1/volumes/projectXvol

System Access

This section discusses the use of session keys with the WSAPI. Session keys enable access to the
HTTP methods for a single session.

Creating Credentials

In order to use the Web Services, you must create a session key by providing a username and
password. The username and password are the same that you would use to access the HP 3PAR
storage server through the HP 3PAR Command Line Interface (CLI) or the HP 3PAR Management
Console (MC). The authorization carries the same user permissions for the WSAPI as for the CLI
or MC, in that you have permission to perform the same operations through the API (where available)
as you would with the CLI or MC.
1.
Create a session key using the HTTP POST method with a URI of the following format:
https://<storage system>:8080/api/v1/credentials
2.
The message body of the request is a JSON object, with members as shown in
14).
Table 3 Session Key Message Body Member JSON Objects
Member
user
password
NOTE:
For error output for this and other conditions, see

About Multiple Session Keys

A multi-threaded client application can use one session key in multiple threads concurrently.
However, the requested operations will be serialized by the server. When true concurrency is
needed, a client can create a session key for each concurrent thread.
NOTE:
This increases server resource usage and should be kept to a small number to avoid
affecting server performance.
14
Accessing the WSAPI
JSON Type
string
string
Value
Username
User's password
"HTTP Status and Error Codes" (page
Table 3 (page
Description
User's name.
User's password.
16).

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents