Use this API to programmatically ingest data into an existing Data Source
curl https://{{ tenant }}.lightenup.ai/admin/s3_uploadlink \
\
--request POST \
--header "Authorization: Bearer {access_token}" \
--header "Content-Type: application/json" \
--data @- << EOF
{
"key": "{filename}",
"type": "datasource"
}
EOF
{
headers: {
'Content-Type': 'application/json',
'Access-Control-Allow-Headers': '*',
'Access-Control-Allow-Methods': allowMethods,
'Access-Control-Allow-Origin': GLOBALS.CORS_ORIGIN,
'Access-Control-Allow-Credentials': true
},
body: {"url: string"}
}
curl {url} \
\
--request PUT \
--header "Content-Type {type}" \
--data @- << EOF
{
"url": "https://profile-console-data-lighte...."
file
}
// no content in body
// no content in body
// no content in body
curl https://{{ tenant }}.lightenup.ai/admin/data/ingest/text_async \
\
--request POST \
--header "Authorization: Bearer {access_token}" \
--header "Content-Type: application/json" \
--data @- << EOF
{
"data_source": "catalog",
"type": "csv",
"uploadurl": "https://profile-console-data-lightenup.."
}
{
"message": "Data ingestion in progress",
"ingestion_id": "f3170179-755e-43f8-b8ea-a544256e404c"
}