Skip to main content

Offline update(QuickStart)

更新时间:2025-07-03 17:32:25
Users can update model deployment (QuickStart) information offline after stopping the instance.
PUT
https://api.alayanew.com/api/serverless-infer/v1/deployment/{serviceId}
Authorizations
AuthorizationsStringHeaderRequired

用户可通过已获取Open API Key做验证,例如:plain Credential=[YOUR_AK],Signature=[YOUR_SK]。

Path Parameters
serviceIdStringRequired

Service ID.

Body
application/json
vksIdStringRequired

Vital Kubernetes Engine (VKS) ID.

namespaceStringRequired

Vital Kubernetes Engine (VKS) NameSpace.

nameStringRequired

Service Name.

servedNameList<String>Required

Internal model identifier.

modelIdStringRequired

Model ID.

backendStringRequired

Backend service, vllm/sglang.

backendVersionStringRequired

Backend service version.

backendArgsStringRequired

Backend service parameters.

resourceObjectRequired

Response
状态码:application/json
codeInt

code is a common return value form representing the execution result of the query operation.

0 is the success flag, indicating the operation completed successfully.
dataObject

msgStringRequired

Returns an error message when the code value is -1.

curl --location --request PUT 'https://api.alayanew.com/api/serverless-infer/v1/deployment/38fbfc3d-6a88-4c35-b8b6-9efc83949d47' 
     --header 'Authorization:plain Credential=YOUR_AK,Signature=YOUR_SK' 
     --header 'Content-Type: application/json' 
     --data '{
        "vksId": "vcacb50arkk4",
        "namespace": "default",
        "name": "testsglang",
        "servedName": [
                "testsglang"
            ],
        "modelId": "c486cdee-c316-4fc1-9f75-0d1741940f27",
        "backend": "sglang",
        "backendVersion": "0.4.6",
        "backendArgs": [],
        "resource": {
                "workers": 2,
                "cpu": 4,
                "gpu": {
                    "count": 1,
                    "gpuType": "nvidia.com/gpu-l40s"
                },
                "mem": 10
            }
    }'
{
    "code": 0,
    "data": {   
    },
    "msg": "string, "
}