# Get square model detail - GetUFSquareModelDetail

## Overview

Get Square Model Details




## Usage

You can choose any of the following methods to initiate an API request:
- Multi-language OpenSDK / [Go](https://github.com/ucloud/ucloud-sdk-go) / [Java](https://github.com/ucloud/ucloud-sdk-java) / [Python](https://github.com/ucloud/ucloud-sdk-python3) / [JavaScript](https://github.com/ucloud/ucloud-sdk-js) / [PHP](https://github.com/ucloud/ucloud-sdk-php) /
- [CloudShell](https://shell.ucloud.cn/)

## Definition

### Public Parameters

| Parameter Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **Action**     | string  | Corresponding API command name, the current API is `GetUFSquareModelDetail`.                      | **Yes** |
| **PublicKey**  | string  | The user's public key can be obtained from [Console](https://console.ucloud.cn/uaccount/api_manage)                                             | **Yes** |
| **Signature**  | string  | User signature generated based on public key and API command, see [Signature Algorithm](https://docs.ucloud.cn/api/summary/signature)  | **Yes** |

### Request Parameters

| Parameter Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **Region** | string | Region. See [Region and Zone List](https://docs.ucloud.cn/api/summary/regionlist) |**Yes**|
| **ProjectId** | string | Project ID. Leave it blank for the default project. Sub-accounts must fill in. Please refer to the [GetProjectList API](https://docs.ucloud.cn/api/summary/get_project_list) |No|
| **Zone** | string | Zone. See [Region and Zone List](https://docs.ucloud.cn/api/summary/regionlist) |**Yes**|
| **Id** | string | Primary Key |**Yes**|

### Response Field

| Field Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **RetCode** | int | Return status code. If it is 0, it means successful return. If it is not 0, it means failure. |**Yes**|
| **Action** | string | Operation command name. |**Yes**|
| **Message** | string | Returns an error message, providing detailed description when `RetCode` is non-zero. |No|
| **SquareModel** | [*SquareModel*](#squaremodel) | model |**Yes**|

#### Data Model

#### SquareModel

| Field Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **BatchSquareModelId** | string | 关联的 batch 模型广场id |No|
| **ModelCategory** | string | 一级分类 |No|
| **ModelSubCategories** | string | 二级分类列表 |No|
| **IsHasBatch** | boolean | 是否关联有可用 batch 模型 |No|
| **BatchName** | string | 关联的 batch 模型名称 |No|
| **IsHasInferenceRegions** | boolean | is has inference regions |No|
| **InferenceRegions** | array[[*InferenceRegionInfo*](#inferenceregioninfo)] | inference regions model info |No|
| **Manufacturer** | string | 制造商 |No|
| **Id** | string | Primary Key |No|
| **Name** | string | Name |No|
| **SimpleDescribe** | string | Brief Description |No|
| **Describe** | string | Detailed Description |No|
| **Language** | array[string] | Language |No|
| **MaxModelLen** | int | Model Length,unit tokens |No|
| **MaxModelLenNew** | int | model length ,unit k tokens |No|
| **MaxInputTokens** | int | max input tokens |No|
| **MaxOutputTokens** | int | max output tokens |No|
| **ModelTypeMap** | [*ModelTypeMap*](#modeltypemap) | model type map |No|
| **ModelType** | string | Model Type |No|
| **CoverUrl** | string | model link image |No|
| **HfUpdateTime** | int | HuggingFace Update Time |No|
| **CreateAt** | int | Create At |No|
| **UpdateAt** | int | Update At |No|
| **SupportedCapabilities** | array[string] | Supported Capabilities |No|
| **Capabilities** | [*ModelCapabilities*](#modelcapabilities) | model Capabilities map |No|
| **ExtraModelTags** | array[string] | model extra tags |No|
| **ApiProtocols** | [*ApiProtocols*](#apiprotocols) | api portocol map |No|
| **InputModalities** | array[string] | input modal |No|
| **OutputModalities** | array[string] | output modal |No|
| **Icon** | string | Icon |No|
| **Pricing** | [*Pricing*](#pricing) | Pricing |No|
| **Tiers** | array[[*PriceTier*](#pricetier)] | 价格阶梯（有序数组） |No|

#### InferenceRegionInfo

| Field Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **RegionCode** | string | region code sg，us，hk |No|
| **RegionName** | string | region name |No|
| **RegionNameEn** | string | region name english |No|
| **ModelId** | string | model id |No|
| **SquareModelId** | string | square model id |No|
| **Status** | string | stauts published / unpublished |No|

#### ModelTypeMap

| Field Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **TextGeneration** | boolean | TextGeneration |No|
| **ImageToImage** | boolean | ImageToImage |No|
| **TextToImage** | boolean | TextToImage |No|
| **TextToVideo** | boolean | TextToVideo |No|
| **ImageToVideo** | boolean | ImageToVideo |No|
| **Sensitive** | boolean | Sensitive |No|
| **Inference** | boolean | Inference |No|

#### ModelCapabilities

| Field Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **ContextCaching** | boolean | support  cache |No|
| **BatchInference** | boolean | support batch inference |No|
| **StructuredOutput** | boolean | support  struct output |No|
| **FunctionCall** | boolean | support  function call |No|
| **WebSearch** | boolean | support  web search |No|
| **KnowledgeBase** | boolean | support  knowledge base |No|
| **Mcp** | boolean | support  mcp |No|
| **Experience** | boolean | support  experience |No|

#### ApiProtocols

| Field Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **ChatCompletions** | boolean | support chat |No|
| **Responses** | boolean | support responses |No|
| **Gemini** | boolean | support gemini |No|
| **Anthropic** | boolean | support Anthropic |No|

#### Pricing

| Field Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **Completion** | float | Completion |No|
| **Prompt** | float | Prompt |No|
| **Image** | float | Image |No|
| **Video** | string | Video |No|
| **Currency** | string | Currency |No|
| **Unit** | string |  |No|
| **UnitEn** | string |  |No|

#### PriceTier

| Field Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **Rates** | array[[*PriceRate*](#pricerate)] | List of charges under this gear (ordered array) |**Yes**|
| **DescriptionEn** | string | Gear description (e.g. "Standard context 32k") |**Yes**|
| **Condition** | string | Gear/condition (e.g. "32k", "128k") |No|
| **Description** | string | Gear description (e.g. "Standard context 32k") |No|

#### PriceRate

| Field Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **ChargeItemDescriptionEn** | string | Description of charge items |**Yes**|
| **Currency** | string | Currency Unit |**Yes**|
| **Unit** | string | Unit of pricing |**Yes**|
| **UnitEn** | string | Unit of pricing |**Yes**|
| **ChargeItem** | string | Charge item：input/output/thinking/tool... |No|
| **ChargeItemDescription** | string | Description of charge items |No|
| **Price** | int | Price |No|

## Example

### Request Example
```
https://api.ucloud.cn/?Action=GetUFSquareModelDetail
&Region=cn-zj
&Zone=cn-zj-01
&ProjectId=tPRsGRvy
&Id=lWvIsfSU
&Region=hCROXmHa
&Zone=fpfzqkGn
&ProjectId=oLOpBEXj
&Id=OKLAVqnf
```

### Response Example
```json
{
  "Action": "GetUFSquareModelDetailResponse",
  "RetCode": 0,
  "SquareModel": {}
}
```
