Skip to Content

get api model list - GetUMInferAPIModel

Overview

Get the list of models that can be called by this API key

Definition

Public Parameters

Parameter NameTypeDescription InformationRequired
ActionstringCorresponding API command name, the current API is GetUMInferAPIModel.Yes
PublicKeystringThe user’s public key can be obtained from Console Yes
SignaturestringUser signature generated based on public key and API command, see Signature AlgorithmYes

Request Parameters

Parameter NameTypeDescription InformationRequired
ProjectIdstringProject ID. Leave it blank for the default project. Sub-accounts must fill in. Please refer to the GetProjectList APIYes
KeyIdstringapikey idNo
ModelTypeintmodel type, 1 text generation, 2 image generation.No
SquareIdstringThe ID of the model square, used to jump to the experience centerNo

Response Field

Field NameTypeDescription InformationRequired
RetCodeintReturn status code. If it is 0, it means successful return. If it is not 0, it means failure.Yes
ActionstringOperation command name.Yes
MessagestringReturns an error message, providing detailed description when RetCode is non-zero.No
Dataarray[UMinferAPIModel]List of Model NamesYes

Data Model

UMinferAPIModel

Field NameTypeDescription InformationRequired
ServedModelNamestringWhen calling the OpenAI interface, fill in the model valueNo
IdstringidNo
NamestringnameNo
SimpleDescribestringdescriptionNo
Languagearray[string]languageNo
Iconstringicon linkNo
PricingPricingmodel priceNo
CreateAtintcreate timeNo
UpdateAtintupdate timeNo

Pricing

Field NameTypeDescription InformationRequired
CompletionfloatCompletionNo
PromptfloatPromptNo
ImagefloatImageNo
CurrencystringCurrencyNo

Example

Request Example

https://api.surfercloud.com/?Action=GetUMInferAPIModel &KeyId=BNPXRmCb &ModelType=2 &SquareId=fschGecL &ProjectId=cauxjXmc

Response Example

{ "Action": "GetUMInferAPIModelResponse", "Data": [ "daArfQcO" ], "RetCode": 0 }