MaaS_Hy
Model Specifications
| Capability Description |
context window |
Maximum Input |
Maximum Output |
| New-generation productivity model, with comprehensive upgrades in Agent and complex task execution capabilities |
1024k |
960k |
64k |
Request Protocol
https
| Parameter Name |
Type |
Required |
Description |
| Content-Type |
string |
Yes |
application/json |
| Authorization |
string |
Yes |
Bearer ${your_AK} |
OpenAI Chat Completions
Request URL
POST https://genaiapi.cloudsway.net/v1/ai/{endpointPath}/chat/completions
Request Body Parameters
| Parameter Name |
Secondary Parameters |
Three-level parameter |
Type |
Required |
Description |
| model |
- |
- |
string |
Yes |
Fixed as MaaS_Hy_4_preview_20260828 |
| messages |
- |
- |
array[json] |
Yes |
Chat context, sequence:[system (optional) → user → assistant → user →. ..] |
|
role |
- |
string |
Yes |
system / user / assistant / tool |
|
content |
- |
string |
Yes |
Plain text; Hy4 does not support image_url/video_url/file_url |
|
reasoning_content |
- |
string |
No |
Chain of Thought; fill back as-is when multi-turn + tool calling is involved |
|
tool_calls |
- |
array |
No |
Tool Call List |
|
tool_call_id |
- |
string |
Conditions |
Required when role= tool |
| stream |
- |
- |
boolean |
No |
Streaming output (SSE), default false |
| stream_options |
- |
- |
object |
No |
Only takes effect when stream= trueis configured |
|
include_usage |
- |
boolean |
No |
Whether the last chunk in streaming contains usage, default is false |
| temperature |
- |
- |
float |
No |
[0.0,2.0], default value is 1.0 |
| top_p |
- |
- |
float |
No |
(0.0,1.0], default 1.0 |
| max_tokens |
- |
- |
integer |
No |
Maximum output tokens, ≥ 1, upper limit 64k |
| max_completion_tokens |
- |
- |
integer |
No |
Same as max_tokens, pass either of the two |
n
|
- |
- |
integer |
No |
Default value is 1; must be 1 when the thinking mode is enabled |
| stop |
- |
- |
string or array |
No |
Stop sequences, maximum 4 |
| seed |
- |
- |
integer |
No |
random seed |
| frequency_penalty |
- |
- |
float |
No |
[-2.0,2.0], default value 0 |
| presence_penalty |
- |
- |
float |
No |
[-2.0,2.0], default value 0 |
| thinking |
- |
- |
object |
No |
Deep Thinking; enabled by default for Hy4 |
|
type |
- |
string |
conditions |
"enabled" / "disabled" |
|
budget_tokens |
- |
integer |
No |
Max tokens for reasoning; defaults to 8192 if not specified |
| reasoning_effort |
- |
- |
string |
No |
Inference depth; default high, supports none, high |
| response_format |
- |
- |
object |
No |
Response format, default{"type":"text"} |
|
type |
- |
string |
Yes |
text / json_object / json_schema |
|
json_schema |
- |
object |
conditions |
type= json_schemamandatory when applicable |
|
- |
name |
string |
Yes |
Schema Name |
|
- |
schema |
object |
Yes |
JSON Schema |
|
- |
strict |
boolean |
No |
Exact match, defaults to false |
| tools |
- |
- |
array |
No |
Function Calling Tool List |
|
type |
- |
string |
Yes |
Fixed "function" |
|
function |
- |
object |
Yes |
function definition |
|
- |
name |
string |
Yes |
function name |
|
- |
description |
string |
No |
function description |
|
- |
parameters |
object |
No |
JSON Schema Input Parameters |
| tool_choice |
- |
- |
string or object |
No |
Default "auto" |
| parallel_tool_calls |
- |
- |
boolean |
No |
Parallel tool invocation, default value is true |
| user |
- |
- |
string |
No |
End User Identifier |
Request Example
curl -X POST 'https://genaiapi.cloudsway.net/v1/ai/{endpointPath}/chat/completions' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer ${your_AK}' \
-d '{
"model": "MaaS_Hy_4_preview_20260828",
"messages": [
{"role": "user", "content": "Hello, please briefly introduce yourself."}
],
"stream": false,
"temperature": 0.9,
"reasoning_effort": "high"
}'
Response Example
{
"id": "chatcmpl-xxxxxxxx",
"object": "chat.completion",
"model": "MaaS_Hy_4_preview_20260828",
"created": 1775146513,
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "I am Hunyuan, a large language model developed by Tencent...",
"reasoning_content": "The user asked me to briefly introduce myself..."
},
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 28,
"completion_tokens": 221,
"total_tokens": 249,
"completion_tokens_details": {"reasoning_tokens": 175}
}
}
Example of streaming request
curl -X POST 'https://genaiapi.cloudsway.net/v1/ai/{endpointPath}/chat/completions' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer ${your_AK}' \
-d '{
"model": "MaaS_Hy_4_preview_20260828",
"messages": [{"role": "user", "content": "Hello"}],
"stream": true,
"stream_options": {"include_usage": true}
}'
SDK Invocation Method
from openai import OpenAI
client = OpenAI(
api_key="${your_AK}",
base_url="https://genaiapi.cloudsway.net/v1/ai/{endpointPath}",
)
response = client.chat.completions.create(
model="MaaS_Hy_4_preview_20260828",
messages=[{"role": "user", "content": "Hello, please briefly introduce yourself."}],
temperature=0.9,
extra_body={"reasoning_effort": "high"},
)
print(response.choices[0].message.content)
OpenAI Responses
Request URL
POST https://genaiapi.cloudsway.net/v1/ai/{endpoint}/responses
Request Body Parameters
| Parameter Name |
Secondary Parameters |
Type |
Required |
Description |
| model |
- |
string |
Yes |
Fixed as MaaS_Hy_4_preview_20260828 |
| input |
- |
string or array |
Yes |
Plain text string, or an array of input entries |
| instructions |
- |
string |
No |
System/Developer Instructions |
| stream |
- |
boolean |
No |
SSE Streaming |
| max_output_tokens |
- |
number |
No |
Maximum output tokens (including inference tokens), ≥ 1 |
| temperature |
- |
number |
No |
[0, 2] |
| top_p |
- |
number |
No |
(0, 1] |
| truncation |
- |
string |
No |
"auto"/ "disabled"(default) |
| tools |
- |
array |
No |
Tool array; compatibility mode only supports function |
| tool_choice |
- |
string or object |
No |
"none"/ "auto"/ specified function |
| parallel_tool_calls |
- |
boolean |
No |
Whether to call tools in parallel |
| text |
- |
object |
No |
Output Format Control |
|
format |
object |
No |
text / json_schema / json_object |
| reasoning |
- |
object |
No |
Inference Model Configuration |
|
effort |
string |
No |
"none" / "low" / "medium" / "high" |
|
summary |
string |
No |
"auto" / "concise" / "detailed" |
| metadata |
- |
object |
No |
Additional metadata (up to 16 key-value pairs) |
Request Example
curl -X POST 'https://genaiapi.cloudsway.net/v1/ai/{endpoint}/responses' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer ${your_AK}' \
-d '{
"model": "MaaS_Hy_4_preview_20260828",
"input": "Hello, please briefly introduce yourself.",
"reasoning": {"effort": "high"}
}'
Response Example
{
"id": "resp_xxxxxxxx",
"object": "response",
"created_at": 1741476542,
"status": "completed",
"model": "MaaS_Hy_4_preview_20260828",
"output": [
{
"type": "reasoning",
"summary": [{"type": "summary_text", "text": "User requested self-introduction..."}]
},
{
"type": "message",
"role": "assistant",
"content": [{"type": "output_text", "text": "I am Hunyuan, a large language model developed by Tencent..."}]
}
],
"usage": {
"input_tokens": 20,
"output_tokens": 221,
"total_tokens": 241
}
}
Stream Request Example
curl -X POST 'https://genaiapi.cloudsway.net/v1/ai/{endpoint}/responses' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer ${your_AK}' \
-d '{
"model": "MaaS_Hy_4_preview_20260828",
"input": "Hello",
"stream": true
}'
SDK Calling Method
from openai import OpenAI
client = OpenAI(
api_key="${your_AK}",
base_url="https://genaiapi.cloudsway.net/v1/ai/{endpoint}",
)
response = client.responses.create(
model="MaaS_Hy_4_preview_20260828",
input="Hello, please briefly introduce yourself.",
extra_body={"reasoning": {"effort": "high"}},
)
print(response.output_text)
Anthropic Messages
Request URL
POST https://genaiapi.cloudsway.net/{endpoint}/v1/messages
| Parameter Name |
Type |
Required |
Description |
| anthropic-version |
string |
Yes |
2023-06-01 |
Request Body Parameters
| Parameter Name |
Secondary Parameters |
Three-level parameter |
Band 4 Parameters |
Type |
Required |
Description |
| model |
- |
- |
- |
string |
Yes |
Fixed as MaaS_Hy_4_preview_20260828 |
| messages |
- |
- |
- |
array[json] |
Yes |
Conversation message list with complete context |
|
role |
- |
- |
string |
Yes |
user / assistant |
|
content |
- |
- |
string or array |
Yes |
Plain text string, or content block array |
|
- |
type |
- |
string |
No |
textetc. |
|
- |
text |
- |
string |
No |
type= texttext when applicable |
| system |
- |
- |
- |
string or array |
No |
System prompt (top-level field, not included in messages) |
| max_tokens |
- |
- |
- |
integer |
Yes |
Maximum output tokens per run; the chain-of-thought tokens count towards this limit |
| stream |
- |
- |
- |
boolean |
No |
Streaming SSE, default false |
| temperature |
- |
- |
- |
float |
No |
[0,1](Anthropic range) |
| top_p |
- |
- |
- |
float |
No |
(0, 1] |
| top_k |
- |
- |
integer |
No |
Only sample from the top K tokens |
|
| stop_sequences |
- |
- |
- |
string[] |
No |
Custom Stop Sequences |
| tools |
- |
- |
- |
array |
No |
Tool Definition (Flat Structure) |
|
name |
- |
- |
string |
Yes |
Tool Name |
|
description |
- |
- |
string |
No |
Tool Description |
|
input_schema |
- |
- |
object |
Yes |
JSON Schema Input Parameters |
| tool_choice |
- |
- |
- |
object |
No |
{"type":"auto"} / none / any / specified tool |
| thinking |
- |
- |
- |
object |
No |
Extended Chain of Thought |
|
type |
- |
- |
string |
conditions |
"enabled" / "disabled" |
|
budget_tokens |
- |
- |
integer |
No |
Chain-of-Thought Token Budget |
Request Example
curl -X POST 'https://genaiapi.cloudsway.net/{endpoint}/v1/messages' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer ${your_AK}' \
-H 'anthropic-version: 2023-06-01' \
-d '{
"model": "MaaS_Hy_4_preview_20260828",
"max_tokens": 1024,
"messages": [
{"role": "user", "content": "Hello, please briefly introduce yourself."}
]
}'
Response Example
{
"id": "msg_xxxxxxxx",
"type": "message",
"role": "assistant",
"model": "MaaS_Hy_4_preview_20260828",
"content": [
{"type": "thinking", "thinking": "User requested self-introduction..."},
{"type": "text", "text": "I am Hunyuan, a large language model developed by Tencent..."}
],
"stop_reason": "end_turn",
"usage": {
"input_tokens": 28,
"output_tokens": 221
}
}
Example of streaming request
curl -X POST 'https://genaiapi.cloudsway.net/{endpoint}/v1/messages' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer ${your_AK}' \
-H 'anthropic-version: 2023-06-01' \
-d '{
"model": "MaaS_Hy_4_preview_20260828",
"max_tokens": 1024,
"stream": true,
"messages": [{"role": "user", "content": "Hello"}]
}'
SDK Invocation Method
import httpx
response = httpx.post(
"https://genaiapi.cloudsway.net/{endpoint}/v1/messages",
headers={
"Authorization": "Bearer ${your_AK}",
"Content-Type": "application/json",
"anthropic-version": "2023-06-01",
},
json={
"model": "MaaS_Hy_4_preview_20260828",
"max_tokens": 1024,
"messages": [{"role": "user", "content": "Hello, please briefly introduce yourself."}],
},
)
print(response.json())