Autentikasi
Kirim kunci API sebagai token bearer. Kunci tersebut harus memiliki izin vector.manage; kunci tanpa izin tersebut akan ditolak dengan status 403, bukan 404.
Endpoint ini tidak memerlukan id organisasi. Kunci Anda telah mengidentifikasi organisasi tempatnya berafiliasi, dan respons akan dibatasi untuk organisasi tersebut.
Coba
Ganti apa pun di dalam tanda kurung sudut dengan nilai Anda sendiri, dan placeholder kunci dengan kunci dari dasbor Anda.
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> }'Sudah masuk? Konsol API di dasbor Anda akan mengisi ID organisasi asli dan kunci Anda sendiri, serta menjalankan permintaan terhadap API langsung sehingga Anda dapat melihat respons aktualnya. Buka titik akhir ini di konsol API
Detail
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.
Isi permintaan
| Nama | Jenis | Wajib | Tentang apa ini |
|---|---|---|---|
name | string | Ya | — |
dimension | integer | Ya | — |
metric | string<cosine, l2, inner_product> | Tidak | — |
Tanggapan
| Nama | Jenis | Wajib | Tentang apa ini |
|---|---|---|---|
id | string | Ya | — |
name | string | Ya | Lower-case, hyphenated, unique within the organisation. |
dimension | integer | Ya | The width your embedding model emits, and the width reads return. Fixed at creation. |
metric | string<cosine, l2, inner_product> | Ya | The distance function. Fixed at creation. |
status | string<ready, deleting> | Ya | — |
vectors | integer | Ya | How many vectors the index holds. |
storage_bytes | integer | Ya | 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 | Ya | — |
Kesalahan yang dapat dikembalikan oleh titik akhir ini
401 · 403 · 422 · 429