A Client ID for your org.
Body
Identifier for your embedding. Must be between 3 - 256 chars and consist of
numbers, letters, or -
. If not provided, a random ID will be generated.
Text to be embedded. Must be between 3 - 10,000 chars.
Additional metadata for the document.
curl --location --request POST 'https://api.getmetal.io/v1/index' \
--header 'Content-Type: application/json' \
--header 'x-metal-api-key: <api-key>' \
--header 'x-metal-client-id: <client-id>' \
--data-raw '{
"index": "index-id",
"text": "text that will be embedded",
"id": "my-unique-id",
"metadata": {
"fieldA": "my custom value",
"fieldB": "my other custom value"
}
}'
{
"data": {
"id": "my-unique-id",
"text": "text that will be embedded",
"createdAt": "2023-03-17T17:21:13.163Z",
"metadata": {
"fieldA": "my custom value",
"fieldB": "my other custom value"
}
}
}