1. OpenAI
TikHub-AI-Proxy
  • Overview (PLEASE READ)
  • Streaming API
  • OpenAI
    • OpenAI response
      POST
    • OpenAI embeddings
      POST
    • OpenAI audio transcription
      POST
    • OpenAI chat completion
      POST
  • Claude
    • Claude chat completion
      POST
    • Claude message
      POST
  • DeepSeek
    • DeepSeek chat completion
      POST
  • Sora
    • Sora video generation
      POST
    • Get Sora video status
      GET
    • Download Sora video content
      GET
    • Remix Sora video
      POST
    • List Sora videos
      GET
    • Delete Sora video
      DELETE
  • Gemini
    • Gemini content
      POST
  • Seedance
    • Seedance video generation
      POST
    • Retrieve Seedance task
      GET
  • Kling
    • Kling text-to-video
      POST
    • Retrieve Kling text-to-video task
      GET
    • Kling image-to-video
      POST
    • Retrieve Kling image-to-video task
      GET
  • Veo
    • Veo video generation
    • Fetch Veo video generation status
  • Schemas
    • ChatCompletionRequest
    • ChatMessage
    • Tool
    • ToolCall
    • ChatCompletionResponse
    • ChatCompletionChoice
    • ContentFilterResults
    • UsageInfo
    • EmbeddingRequest
    • EmbeddingResponse
    • TranscriptionRequest
    • TranscriptionResponse
    • ClaudeMessageRequest
    • ClaudeMessageResponse
    • VideoCreateRequest
    • VideoResponse
    • VideoRemixRequest
    • GeminiGenerateContentRequest
    • VideoListResponse
    • GeminiContent
    • VideoDeleteResponse
    • GeminiGenerationConfig
    • ResponseRequest
    • GeminiGenerateContentResponse
    • ResponseObject
    • SeedanceTaskRequest
    • SeedanceTaskCreateResponse
    • SeedanceTaskResponse
    • KlingText2VideoRequest
    • KlingImage2VideoRequest
    • KlingTaskResponse
    • KlingTaskDetailResponse
    • KlingTaskListResponse
    • VeoGenerateRequest
    • VeoOperationResponse
    • VeoFetchOperationRequest
    • VeoFetchOperationResponse
  1. OpenAI

OpenAI embeddings

POST
https://ai.tikhub.io/v1/embeddings
OpenAI
Creates an embedding vector representing the input text. Embeddings are useful for search, clustering, recommendations, and other machine learning tasks.

How To Use#

Simply specify the model name in your request payload. All other parameters remain the same across different models.

Supported Models#

text-embedding-3-large
text-embedding-3-small
text-embedding-ada-002

Request

Authorization
Bearer Token
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
or
Body Params application/jsonRequired

Examples
{
    "input": "The food was delicious and the waiter...",
    "model": "text-embedding-ada-002",
    "encoding_format": "float"
}

Request Code Samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
cURL
curl --location --request POST 'https://ai.tikhub.io/v1/embeddings' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data-raw '{
    "input": "The food was delicious and the waiter...",
    "model": "text-embedding-ada-002",
    "encoding_format": "float"
}'

Responses

🟢200OK
application/json
Successful response
Body

Example
{
    "object": "list",
    "data": [
        {
            "object": "embedding",
            "embedding": [
                0.0023064255,
                -0.009327292,
                -0.0028842222
            ],
            "index": 0
        }
    ],
    "model": "text-embedding-ada-002",
    "usage": {
        "prompt_tokens": 8,
        "total_tokens": 8
    }
}
🟠400Bad Request
🟠401Unauthorized
🟠429Too Many Requests
🔴500Internal Server Error
Modified at 2026-03-02 20:33:07
Previous
OpenAI response
Next
OpenAI audio transcription
Built with