VMs
Create VM
Authorizations
x-api-keystringRequired
Body
Instance Rent Request
vmTypeIdinteger · int32Required
machine model type id
regionstringRequired
region
regionIdinteger · int32Optional
nickNamestring · min: 1 · max: 255Required
isSpotinteger · int32 · max: 1Required
is spot instance, 0: on-demand, 1: spot
Responses
200
OK
*/*
messagestringOptional
message
codeinteger · int32Optional
code
400
Bad Request
*/*
500
Internal Server Error
*/*
post/openapi/v1/vms/create
POST /openapi/v1/vms/create HTTP/1.1
x-api-key: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 126
{
"vmTypeId": 1,
"region": "text",
"regionId": 1,
"nickName": "text",
"isSpot": 1,
"volumeMountPaths": {
"ANY_ADDITIONAL_PROPERTY": "text"
}
}{
"message": "text",
"code": 1,
"data": {
"id": 1,
"orgId": "text",
"nickname": "text",
"gpuDisplayName": "text",
"ipAddress": "text",
"domainName": "text",
"cpuCores": 1,
"memoryInGb": "text",
"gpuCount": 1,
"gpuMemoryInGb": "text",
"region": "text",
"storageInGb": "text",
"notebookUrl": "text",
"sshTemplate": "text",
"status": "text",
"createdAt": 1,
"terminatedAt": 1,
"updatedAt": 1,
"osInfo": "text",
"gpuType": "text",
"isSpot": 1
}
}Terminate VM
Authorizations
x-api-keystringRequired
Path parameters
vmIdinteger · int64RequiredExample:
0Responses
200
OK
*/*
messagestringOptionalExample:
message
successcodeinteger · int32OptionalExample:
code
10000dataanyOptional
data
400
Bad Request
*/*
500
Internal Server Error
*/*
11000
Instance not exist
*/*
11001
Instance status invalid
*/*
11002
No terminate instance permissions
*/*
12001
Resource status invalid
*/*
delete/openapi/v1/vms/{vmId}/terminate
DELETE /openapi/v1/vms/{vmId}/terminate HTTP/1.1
x-api-key: YOUR_API_KEY
Accept: */*
{
"message": "success",
"code": 10000,
"data": null
}Get available Instance ModelType
Authorizations
x-api-keystringRequired
Responses
200
OK
*/*
messagestringOptional
message
codeinteger · int32Optional
code
400
Bad Request
*/*
404
Not Found
*/*
500
Internal Server Error
*/*
get/openapi/v1/vms/type
GET /openapi/v1/vms/type HTTP/1.1
x-api-key: YOUR_API_KEY
Accept: */*
{
"message": "success",
"code": 10000,
"data": []
}Get VM details
Authorizations
x-api-keystringRequired
Path parameters
vmIdinteger · int64RequiredExample:
0Responses
200
OK
*/*
messagestringOptional
message
codeinteger · int32Optional
code
400
Bad Request
*/*
500
Internal Server Error
*/*
get/openapi/v1/vms/{vmId}
GET /openapi/v1/vms/{vmId} HTTP/1.1
x-api-key: YOUR_API_KEY
Accept: */*
{
"message": "text",
"code": 1,
"data": {
"id": 1,
"orgId": "text",
"nickname": "text",
"gpuDisplayName": "text",
"ipAddress": "text",
"domainName": "text",
"cpuCores": 1,
"memoryInGb": "text",
"gpuCount": 1,
"gpuMemoryInGb": "text",
"region": "text",
"storageInGb": "text",
"notebookUrl": "text",
"sshTemplate": "text",
"status": "text",
"createdAt": 1,
"terminatedAt": 1,
"updatedAt": 1,
"osInfo": "text",
"gpuType": "text",
"isSpot": 1
}
}Get Org VM list
Authorizations
x-api-keystringRequired
Body
Yotta Page Request
pageNumberinteger · int64 · min: 1Required
Yotta pageNumber
pageSizeinteger · int64 · min: 1Required
Yotta pageSize
pageMarkinteger · int64Optional
Yotta pageMark for cursor-based pagination
totalPageinteger · int64Optional
Yotta totalPage
totalRowinteger · int64Optional
Yotta totalRow
nextPagebooleanOptional
Next Page
Responses
200
OK
*/*
messagestringOptional
message
codeinteger · int32Optional
code
400
Bad Request
*/*
500
Internal Server Error
*/*
post/openapi/v1/vms/list
POST /openapi/v1/vms/list HTTP/1.1
x-api-key: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 112
{
"search": {
"status": "text"
},
"pageNumber": 1,
"pageSize": 1,
"pageMark": 1,
"totalPage": 1,
"totalRow": 1,
"nextPage": true
}{
"message": "text",
"code": 1,
"data": {
"records": [
{
"id": 1,
"orgId": "text",
"nickname": "text",
"gpuDisplayName": "text",
"ipAddress": "text",
"domainName": "text",
"cpuCores": 1,
"memoryInGb": "text",
"gpuCount": 1,
"gpuMemoryInGb": "text",
"region": "text",
"storageInGb": "text",
"notebookUrl": "text",
"sshTemplate": "text",
"status": "text",
"createdAt": 1,
"terminatedAt": 1,
"updatedAt": 1,
"osInfo": "text",
"gpuType": "text",
"isSpot": 1
}
],
"pageNumber": 1,
"pageSize": 1,
"totalPage": 1,
"totalRow": 1
}
}Last updated
Was this helpful?