curl --request POST \
--url https://api.tikway.ai/v1beta/models/google/{model}:embedContent \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"content": {
"parts": [
{
"text": "Hello, world!"
}
]
}
}
'{
"candidates": [
{
"index": 0,
"content": {
"role": "model",
"parts": [
{
"text": "Once upon a time, a magic backpack..."
}
]
},
"finishReason": "STOP"
}
],
"usageMetadata": {
"promptTokenCount": 10,
"candidatesTokenCount": 12,
"totalTokenCount": 22
},
"modelVersion": "gemini-2.0-flash"
}Gemini - vector
curl --request POST \
--url https://api.tikway.ai/v1beta/models/google/{model}:embedContent \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"content": {
"parts": [
{
"text": "Hello, world!"
}
]
}
}
'{
"candidates": [
{
"index": 0,
"content": {
"role": "model",
"parts": [
{
"text": "Once upon a time, a magic backpack..."
}
]
},
"finishReason": "STOP"
}
],
"usageMetadata": {
"promptTokenCount": 10,
"candidatesTokenCount": 12,
"totalTokenCount": 22
},
"modelVersion": "gemini-2.0-flash"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
Current conversation content. A single-round request usually has only one Content; multi-round conversations include historical and latest requests in order.
1Hide child attributes
Hide child attributes
List of content sections.
1Hide child attributes
Hide child attributes
Text input.
Does this part belong to model thinking content?
Think content signatures; keep them as is on postback.
Content roles. When omitted, it is usually treated as user.
user, model A list of tools that the model can use, such as function calls or code execution.
Hide child attributes
Hide child attributes
List of function declarations.
Hide child attributes
Hide child attributes
Enable code execution tools.
Enable Google search tools.
Enable the URL context tool.
Tool call configuration.
Hide child attributes
Hide child attributes
Security filtering rules; the same category can be configured at most once, overriding the default threshold for that category.
Hide child attributes
Hide child attributes
Security Category.
HARM_CATEGORY_HATE_SPEECH, HARM_CATEGORY_SEXUALLY_EXPLICIT, HARM_CATEGORY_DANGEROUS_CONTENT, HARM_CATEGORY_HARASSMENT, HARM_CATEGORY_CIVIC_INTEGRITY, HARM_CATEGORY_JAILBREAK Blocking threshold.
Safety rating method.
Generate and output configurations.
Hide child attributes
Hide child attributes
Sampling temperature.
Kernel sampling threshold.
The number of highest probability candidates retained at each step.
Returns the number of candidate replies.
x >= 1The maximum number of output tokens.
Stop the sequence.
Output MIME type.
text/plain, application/json The JSON Schema that application/json output should follow.
The raw JSON Schema of the JSON output.
The requested output modal.
TEXT, IMAGE, AUDIO Media input resolution settings.
The cached content name to use as context, in the format cachedContents/{cachedContent}.
Request service level.
Whether to log this request; if set, it will override the project-level log configuration.
Response
Gemini API: models.generateContent normal response. Fully inline and suitable for importing into Apifox.
A list of candidate responses generated by the model.
Hide child attributes
Hide child attributes
Candidate reply index.
Candidate reply content.
Hide child attributes
Hide child attributes
Role, fixed as model.
model Reply content part.
Hide child attributes
Hide child attributes
Generated text.
Whether it is the content of thinking.
Think about signing.
The ending reason for the candidate reply.
A description of the reason for ending.
Reference metadata.
Number of candidate reply tokens.
Average log probability of candidate responses.
Term log probability results.
URL context metadata.
Word usage statistics.
Hide child attributes
Hide child attributes
Prompt word number.
Number of candidate reply tokens.
The total number of tokens.
The number of cached content tokens.
Think about word count.
Tool usage hint word token number.
The actual model version used.
Response unique ID.

