Authentification
Envoyez une clé API en tant que jeton du porteur. La clé doit posséder l'autorisation vector.manage ; une clé qui ne l'a pas est refusée avec le code 403, et non 404.
Cet endpoint ne prend aucun identifiant d'organisation. Votre clé identifie déjà l'organisation à laquelle elle appartient, et la réponse y est limitée.
Essayer
Remplacez tout ce qui se trouve entre crochets par vos propres valeurs, et le espace réservé à la clé par une clé de votre tableau de bord.
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> }'Connecté ? La console d'API de votre tableau de bord saisit votre véritable ID d'organisation ainsi que votre propre clé, et exécute la requête sur l'API de production afin que vous puissiez voir la réponse réelle. Ouvrir ce point de terminaison dans la console API
Détails
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.
Corps de la requête
| Nom | Type | Obligatoire | Qu'est-ce que c'est |
|---|---|---|---|
name | string | Oui | — |
dimension | integer | Oui | — |
metric | string<cosine, l2, inner_product> | Non | — |
Réponse
| Nom | Type | Obligatoire | Qu'est-ce que c'est |
|---|---|---|---|
id | string | Oui | — |
name | string | Oui | Lower-case, hyphenated, unique within the organisation. |
dimension | integer | Oui | The width your embedding model emits, and the width reads return. Fixed at creation. |
metric | string<cosine, l2, inner_product> | Oui | The distance function. Fixed at creation. |
status | string<ready, deleting> | Oui | — |
vectors | integer | Oui | How many vectors the index holds. |
storage_bytes | integer | Oui | 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 | Oui | — |
Erreurs que cet point de terminaison peut renvoyer
401 · 403 · 422 · 429