curl --location --request POST 'https://app.zappway.ai/api/datastores/upsert/<datastoreId>' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer <API_KEY>' \
--data-raw '{
"documents": [
"text": "Lorem Ipsum...",
"name": "My Document",
"metadata": {
"source" : "https://en.wikipedia.org/wiki/Lorem_ipsum",
"author": "John Doe",
"date": "2021-01-01",
}
]
}'
{
"ids": ["60f9b9f0-0b1a-11ec-9a03-0242ac130003"]
}
Datastores
Fuente de datos: Upsert (⚠️ en desuso)
Este punto final le permite agregar una nueva fuente de datos en un almacén de datos
POST
/
api
/
datastores
/
upsert
/
{datastoreId}
curl --location --request POST 'https://app.zappway.ai/api/datastores/upsert/<datastoreId>' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer <API_KEY>' \
--data-raw '{
"documents": [
"text": "Lorem Ipsum...",
"name": "My Document",
"metadata": {
"source" : "https://en.wikipedia.org/wiki/Lorem_ipsum",
"author": "John Doe",
"date": "2021-01-01",
}
]
}'
{
"ids": ["60f9b9f0-0b1a-11ec-9a03-0242ac130003"]
}
Camino
string
requerido
La identificación del almacén de datos al que desea acceder.
Cuerpo
array
requerido
Respuesta
array of string
Los ID de los documentos que se crearon.
curl --location --request POST 'https://app.zappway.ai/api/datastores/upsert/<datastoreId>' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer <API_KEY>' \
--data-raw '{
"documents": [
"text": "Lorem Ipsum...",
"name": "My Document",
"metadata": {
"source" : "https://en.wikipedia.org/wiki/Lorem_ipsum",
"author": "John Doe",
"date": "2021-01-01",
}
]
}'
{
"ids": ["60f9b9f0-0b1a-11ec-9a03-0242ac130003"]
}

