开始使用
实例
Endpoint
查询 Endpoint 列表
GET
/
gpu-instance
/
openapi
/
v1
/
endpoint
curl --request GET \
--url https://api.ppinfra.com/gpu-instance/openapi/v1/endpoint \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>'
{
"endpoints": [
{
"id": "<string>",
"name": "<string>",
"appName": "<string>",
"state": {
"state": "<string>",
"error": "<string>",
"message": "<string>"
},
"url": "<string>",
"workerConfig": {
"minNum": 123,
"maxNum": 123,
"freeTimeout": "<string>",
"maxConcurrent": "<string>",
"gpuNum": 123,
"cudaVersion": "<string>"
},
"policy": {
"type": "<string>",
"value": "<string>"
},
"image": {
"image": "<string>",
"authId": "<string>",
"command": "<string>"
},
"rootfsSize": 123,
"volumeMounts": [
{
"type": "<string>",
"id": "<string>",
"size": 123,
"mountPath": "<string>"
}
],
"envs": [
{
"key": "<string>",
"value": "<string>"
}
],
"ports": [
{
"port": "<string>"
}
],
"workers": [
{
"id": "<string>",
"state": {
"state": "<string>",
"error": "<string>",
"message": "<string>"
},
"log": "<string>",
"metrics": "<string>",
"healthy": true
}
],
"products": [
{
"id": "<string>"
}
],
"healthy": {
"path": "<string>",
"initialDelay": 123,
"period": 123,
"timeout": 123,
"successThreshold": 123,
"failureThreshold": 123
},
"clusterID": "<string>",
"log": "<string>"
}
],
"total": 123
}
请求头
枚举值:application/json。
Bearer 身份验证格式,例如:Bearer {{API 密钥}}。
查询参数
每页返回的最大条数。
当前页码。
响应参数
Endpoint 信息。
Endpoint ID。
Endpoint 名称。
应用名称。
Endpoint URL。通过该 URL 可以访问 您的 HTTP 服务。
系统盘大小。
Endpoint 的 Worker 信息。
云存储所在的集群 ID。使用云存储时返回。
Endpoint 的日志路径。
查询结果的条数。
curl --request GET \
--url https://api.ppinfra.com/gpu-instance/openapi/v1/endpoint \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>'
{
"endpoints": [
{
"id": "<string>",
"name": "<string>",
"appName": "<string>",
"state": {
"state": "<string>",
"error": "<string>",
"message": "<string>"
},
"url": "<string>",
"workerConfig": {
"minNum": 123,
"maxNum": 123,
"freeTimeout": "<string>",
"maxConcurrent": "<string>",
"gpuNum": 123,
"cudaVersion": "<string>"
},
"policy": {
"type": "<string>",
"value": "<string>"
},
"image": {
"image": "<string>",
"authId": "<string>",
"command": "<string>"
},
"rootfsSize": 123,
"volumeMounts": [
{
"type": "<string>",
"id": "<string>",
"size": 123,
"mountPath": "<string>"
}
],
"envs": [
{
"key": "<string>",
"value": "<string>"
}
],
"ports": [
{
"port": "<string>"
}
],
"workers": [
{
"id": "<string>",
"state": {
"state": "<string>",
"error": "<string>",
"message": "<string>"
},
"log": "<string>",
"metrics": "<string>",
"healthy": true
}
],
"products": [
{
"id": "<string>"
}
],
"healthy": {
"path": "<string>",
"initialDelay": 123,
"period": 123,
"timeout": 123,
"successThreshold": 123,
"failureThreshold": 123
},
"clusterID": "<string>",
"log": "<string>"
}
],
"total": 123
}