AI Platform
Information about configuring Generative AI API.
Last updated
Information about configuring Generative AI API.
Last updated
Š2024 Little Pig Team. All Rights Reserved
Navigate to AI configuration management page. Click on "Open Service" button to enter configuration page.
To obtain the API key click on "View". You have to enter your account password for verification.
API Domain: https://ai.littlepig.tech
Protocol: HTTPS
Request Method: POST
Request Body: Serialized JSON format
Invoke AI chat capabilities.
API Endpoint: https://ai.littlepig.tech/ai/chat
Request Data Definition:
Response Data Definition:
Example:
Invoke AI chat capabilities (Streaming, SSE mode)
API Endpoint: https://ai.littlepig.tech/ai/chat_stream
Request Data Definition:
Response: Streaming large model chat information
Example:
The model pricing is subject to change. Please visit the configuration management page to view the latest pricing.
To disable API access, click on "Close Service" button in configuration management page.
Parameter Name | Description | Required | Notes |
---|---|---|---|
Parameter Name | Description | Required | Notes |
---|---|---|---|
Parameter Name | Description | Required | Notes |
---|---|---|---|
Model | Price | Unit |
---|---|---|
user
prompt (user)
Yes
system
prompt (system)
No
secretKey
Secret key assigned to the API
Yes
name
Deployed model name
No
If not provided, the default is gpt_4o_mini
code
API response code
Yes
0000 indicates success
message
API response message
No
data
Chat information
Yes
Parse the 'chat' field in the data
user
prompt (user)
Yes
system
prompt (system)
No
secretKey
Secret key assigned to the API
Yes
name
Deployed model name
No
If not provided, the default is gpt_4o_mini
gpt_4o
input: $0.005
output: $0.015
1000time
gpt_4o_mini
input: $0.00015
output: $0.0006
1000time
gemini_15_flash
input: $0.00001875
output: $0.000075
1000time
gemini_15_pro
input: $0.00125
output: $0.00375
1000time
claude_3_sonnet
input: $0.003
output: $0.015
1000time