POST
/api/v1/block_storage/
curl --request POST \ --url 'https://api.e2enetworks.com/myaccount/api/v1/block_storage/?project_id=<PROJECT_ID>&location=<LOCATION>&apikey=<API_KEY>' \ --header 'Authorization: Bearer <API_TOKEN>' \ --header 'Content-Type: application/json' \ --data '{ "name": "V_250GB_452", "size": 250, "iops": 5000}'import requests
response = requests.post( "https://api.e2enetworks.com/myaccount/api/v1/block_storage/", params={"project_id": "<PROJECT_ID>", "location": "<LOCATION>", "apikey": "<API_KEY>"}, headers={"Authorization": "Bearer <API_TOKEN>"}, json={ "name": "V_250GB_452", "size": 250, "iops": 5000, },)print(response.json())const url = new URL("https://api.e2enetworks.com/myaccount/api/v1/block_storage/");url.search = new URLSearchParams({ project_id: "<PROJECT_ID>", location: "<LOCATION>", apikey: "<API_KEY>" });
const response = await fetch(url, { method: "POST", headers: { "Authorization": "Bearer <API_TOKEN>", "Content-Type": "application/json" }, body: JSON.stringify({ "name": "V_250GB_452", "size": 250, "iops": 5000 }),});console.log(await response.json());Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”project_id
required
integer
Project ID Find your project id here
location
required
string
Deployment region for the resource. Accepted values: Delhi, Chennai.
Mumbai region has been discontinued. Delhi and Chennai are the only supported regions.
Request Body
Section titled “Request Body”Media typeapplication/json
object
name
required
string
Example
V_250GB_452size
required
integer
Example
250iops
required
integer
Example
5000Responses
Section titled “Responses”A successful response containing image details
Media typeapplication/json
object
code
Response status code
integer
data
object
id
Unique identifier for the image
integer
image_name
Name of the image
string
resource_type
Type of the resource associated with the image
string
label_id
Identifier for the label associated with the image
integer
errors
Any errors that occurred during the operation (if applicable)
object
message
Response message indicating success
string
Example
{ "code": 200, "data": { "id": 25550, "image_name": "V_250GB_45211qqq11", "resource_type": null, "label_id": null }, "message": "Success"}