Authenticatie
Stuur een API-sleutel mee als bearer token. De sleutel moet over de permissie vector.manage beschikken; een sleutel zonder deze permissie wordt geweigerd met een 403 in plaats van een 404.
Dit eindpunt vereist geen organisatie-id. Uw sleutel identificeert al de organisatie waartoe deze behoort, en het antwoord is hierop afgestemd.
Probeer het
Vervang alles tussen punthaakjes door uw eigen waarden en de sleutelplaatsvervanger door een sleutel uit uw dashboard.
curl -X POST https://api.zinndigital.com/v1/vector/indexes \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ "name": <string>, "dimension": <integer> }'Ingelogd? De API-console in je dashboard vult je echte organisatie-id en je eigen sleutel in, en voert het verzoek uit tegen de live API zodat je de daadwerkelijke respons kunt zien. Open dit eindpunt in de API-console
Details
Creates an index of a fixed width and distance function. `dimension` is whatever your embedding model emits, from 1 to 3072 — it does not have to be a round number, and a width we do not store natively is held exactly rather than approximately. Above 2000 dimensions the index is stored at half precision, because pgvector's HNSW index does not accept a full-precision column wider than that. Requires `vector.manage`, and is refused if the plan's `vector_indexes` allowance is full.
Aanvraaglichaam
| Naam | Type | Verplicht | Wat dit is |
|---|---|---|---|
name | string | Ja | — |
dimension | integer | Ja | — |
metric | string<cosine, l2, inner_product> | Nee | — |
Reactie
| Naam | Type | Verplicht | Wat dit is |
|---|---|---|---|
id | string | Ja | — |
name | string | Ja | Lower-case, hyphenated, unique within the organisation. |
dimension | integer | Ja | The width your embedding model emits, and the width reads return. Fixed at creation. |
metric | string<cosine, l2, inner_product> | Ja | The distance function. Fixed at creation. |
status | string<ready, deleting> | Ja | — |
vectors | integer | Ja | How many vectors the index holds. |
storage_bytes | integer | Ja | What the index counts for against `vector_index_gb`. A published formula rather than a physical table size, so it is reproducible: 96 bytes of row overhead, plus the stored widt… |
created_at | string | Ja | — |
Fouten die dit eindpunt kan retourneren
401 · 403 · 422 · 429