Saltar al contenido principal
POST
/
api
/
v1
/
search
/
tables
/
{table_name}
/
data
Python (SDK)
from openapi import SDK


with SDK(
    bearer_auth="<YOUR_BEARER_TOKEN_HERE>",
) as sdk:

    res = sdk.search.tables.insert_data(table_name="<value>", data=[
        {
            "category": "account",
            "content": "Reset your password from the account settings page.",
            "embedding": [
                0.13,
                -0.09,
                0.41,
            ],
            "id": "doc_001",
            "rating": 4.7,
        },
        {
            "category": "security",
            "content": "Use two-factor authentication for added account security.",
            "embedding": [
                0.07,
                -0.02,
                0.36,
            ],
            "id": "doc_002",
            "rating": 4.9,
        },
    ], refresh=True)

    # Handle response
    print(res)
{
  "count": 2,
  "message": "Successfully inserted 2 records into support_kb",
  "version": 3
}

Autorizaciones

Authorization
string
header
requerido

Gateway auth: send Authorization: Bearer <mka1-api-key>. For multi-user server-side integrations, you can also send X-On-Behalf-Of: <external-user-id>.

Parámetros de ruta

table_name
string
requerido

Cuerpo

application/json
data
Data · object[]
requerido
refresh
boolean
predeterminado:true

Actualiza los índices no vectoriales. Cualquier índice vectorial debe ser recreado manualmente a través del endpoint create_indices.

Respuesta

Respuesta exitosa

version
integer
requerido
count
integer
requerido
message
string
requerido