curl --request POST \
--url https://api.cloudglue.dev/v1/collections/{collection_id}/imports \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"connector_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"filters": [],
"default_mode": "append",
"delete_missing": false,
"rate_limit": 25,
"start": true,
"max_files": 500000,
"include_thumbnails": false,
"enrich_metadata": false
}
'import requests
url = "https://api.cloudglue.dev/v1/collections/{collection_id}/imports"
payload = {
"name": "<string>",
"connector_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"filters": [],
"default_mode": "append",
"delete_missing": False,
"rate_limit": 25,
"start": True,
"max_files": 500000,
"include_thumbnails": False,
"enrich_metadata": False
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
connector_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
filters: [],
default_mode: 'append',
delete_missing: false,
rate_limit: 25,
start: true,
max_files: 500000,
include_thumbnails: false,
enrich_metadata: false
})
};
fetch('https://api.cloudglue.dev/v1/collections/{collection_id}/imports', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.cloudglue.dev/v1/collections/{collection_id}/imports",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'connector_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'filters' => [
],
'default_mode' => 'append',
'delete_missing' => false,
'rate_limit' => 25,
'start' => true,
'max_files' => 500000,
'include_thumbnails' => false,
'enrich_metadata' => false
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.cloudglue.dev/v1/collections/{collection_id}/imports"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"connector_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"filters\": [],\n \"default_mode\": \"append\",\n \"delete_missing\": false,\n \"rate_limit\": 25,\n \"start\": true,\n \"max_files\": 500000,\n \"include_thumbnails\": false,\n \"enrich_metadata\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.cloudglue.dev/v1/collections/{collection_id}/imports")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"connector_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"filters\": [],\n \"default_mode\": \"append\",\n \"delete_missing\": false,\n \"rate_limit\": 25,\n \"start\": true,\n \"max_files\": 500000,\n \"include_thumbnails\": false,\n \"enrich_metadata\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.cloudglue.dev/v1/collections/{collection_id}/imports")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"connector_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"filters\": [],\n \"default_mode\": \"append\",\n \"delete_missing\": false,\n \"rate_limit\": 25,\n \"start\": true,\n \"max_files\": 500000,\n \"include_thumbnails\": false,\n \"enrich_metadata\": false\n}"
response = http.request(request)
puts response.read_body{
"object": "metadata_import",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"collection_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"connector_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"import_type": "metadata",
"name": "<string>",
"filters": [
{
"from": "2023-12-25",
"to": "2023-12-25",
"folder_id": "<string>",
"path": "<string>",
"title_search": "<string>",
"team": "<string>",
"meeting_type": "<string>",
"recursive": "true"
}
],
"default_mode": "append",
"delete_missing": true,
"rate_limit": 123,
"created_at": 123,
"latest_run": {
"object": "metadata_import_run",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"import_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"import_type": "metadata",
"mode": "append",
"delete_missing": true,
"status": "pending",
"progress": {
"pages_listed": 123,
"files_listed": 123,
"files_created": 123,
"files_updated": 123,
"files_skipped": 123,
"files_failed": 123,
"files_queued": 123,
"files_indexed": 123,
"files_imported": 123,
"files_removed": 123,
"files_enriched": 123
},
"error": "<string>",
"started_at": 123,
"completed_at": 123,
"created_at": 123,
"max_files": 123,
"include_thumbnails": true,
"enrich_metadata": true
},
"max_files": 123,
"include_thumbnails": true,
"enrich_metadata": true
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}Create Bulk Import
Create a bulk import: a saved definition that lists a data connector’s source files and brings each match into the collection. What a run ingests follows the collection’s type (see import_type on the response). For a metadata collection it imports each file’s source metadata as a collection file, with no media download or processing, and runs consume no credits. For any other collection type it imports the media itself: each matching file is ingested and processed exactly like a manual add, so it is billed per file and counts against the account’s file usage limits. A media run that exhausts credits or a usage limit stops with a user-facing error and keeps everything it already imported — rerun in append mode to resume. By default the first run starts immediately (start: false saves the definition only). The response’s latest_run is the triggered run; it is null when start is false or when another run is already active in the collection (the definition is saved, and can be run once that one finishes), and it is returned with status failed when the run could not be started (trigger a new run to retry). Runs page the connector — and, for media imports, add each file — with the account’s default active API key, and fail with a clear error when the account has none.
curl --request POST \
--url https://api.cloudglue.dev/v1/collections/{collection_id}/imports \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"connector_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"filters": [],
"default_mode": "append",
"delete_missing": false,
"rate_limit": 25,
"start": true,
"max_files": 500000,
"include_thumbnails": false,
"enrich_metadata": false
}
'import requests
url = "https://api.cloudglue.dev/v1/collections/{collection_id}/imports"
payload = {
"name": "<string>",
"connector_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"filters": [],
"default_mode": "append",
"delete_missing": False,
"rate_limit": 25,
"start": True,
"max_files": 500000,
"include_thumbnails": False,
"enrich_metadata": False
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
connector_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
filters: [],
default_mode: 'append',
delete_missing: false,
rate_limit: 25,
start: true,
max_files: 500000,
include_thumbnails: false,
enrich_metadata: false
})
};
fetch('https://api.cloudglue.dev/v1/collections/{collection_id}/imports', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.cloudglue.dev/v1/collections/{collection_id}/imports",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'connector_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'filters' => [
],
'default_mode' => 'append',
'delete_missing' => false,
'rate_limit' => 25,
'start' => true,
'max_files' => 500000,
'include_thumbnails' => false,
'enrich_metadata' => false
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.cloudglue.dev/v1/collections/{collection_id}/imports"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"connector_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"filters\": [],\n \"default_mode\": \"append\",\n \"delete_missing\": false,\n \"rate_limit\": 25,\n \"start\": true,\n \"max_files\": 500000,\n \"include_thumbnails\": false,\n \"enrich_metadata\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.cloudglue.dev/v1/collections/{collection_id}/imports")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"connector_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"filters\": [],\n \"default_mode\": \"append\",\n \"delete_missing\": false,\n \"rate_limit\": 25,\n \"start\": true,\n \"max_files\": 500000,\n \"include_thumbnails\": false,\n \"enrich_metadata\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.cloudglue.dev/v1/collections/{collection_id}/imports")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"connector_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"filters\": [],\n \"default_mode\": \"append\",\n \"delete_missing\": false,\n \"rate_limit\": 25,\n \"start\": true,\n \"max_files\": 500000,\n \"include_thumbnails\": false,\n \"enrich_metadata\": false\n}"
response = http.request(request)
puts response.read_body{
"object": "metadata_import",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"collection_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"connector_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"import_type": "metadata",
"name": "<string>",
"filters": [
{
"from": "2023-12-25",
"to": "2023-12-25",
"folder_id": "<string>",
"path": "<string>",
"title_search": "<string>",
"team": "<string>",
"meeting_type": "<string>",
"recursive": "true"
}
],
"default_mode": "append",
"delete_missing": true,
"rate_limit": 123,
"created_at": 123,
"latest_run": {
"object": "metadata_import_run",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"import_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"import_type": "metadata",
"mode": "append",
"delete_missing": true,
"status": "pending",
"progress": {
"pages_listed": 123,
"files_listed": 123,
"files_created": 123,
"files_updated": 123,
"files_skipped": 123,
"files_failed": 123,
"files_queued": 123,
"files_indexed": 123,
"files_imported": 123,
"files_removed": 123,
"files_enriched": 123
},
"error": "<string>",
"started_at": 123,
"completed_at": 123,
"created_at": 123,
"max_files": 123,
"include_thumbnails": true,
"enrich_metadata": true
},
"max_files": 123,
"include_thumbnails": true,
"enrich_metadata": true
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}Authorizations
Body
Upstream list requests per second. Defaults to a per-connector safe rate (e.g. gong 2, zoom 6, google-drive/dropbox 8) and is clamped to a per-connector ceiling (gong 3, iconik 12, zoom/grain/recall 10, google-drive/dropbox 20) sized to keep the whole account inside each provider's published rate budget.
1 <= x <= 50Stop each run after processing this many files from the listing. A capped run stops listing at the limit and never runs the delete-missing sweep — a truncated listing is incomplete by definition, so nothing is removed based on it. Media imports additionally cap every run at 10,000 files, whatever this is set to.
1 <= x <= 1000000Copy connector poster images as default thumbnails for imported files, for sources that provide one (Grain, iconik, Google Drive, and Dropbox today). Off by default. Posters are copied in the background, so they do not slow the import itself and may appear shortly after a file is indexed. Metadata imports only — setting it on a media import is a 400, since imported media gets real thumbnails from the processing pipeline.
Backfill source-metadata fields the connector's list endpoint omits, after each index batch settles: Gong parties + Call Spotlight content (batched - enriched docs are re-embedded so the content is searchable) and Dropbox media_info duration/dimensions (per-file). No-op for other connectors. Off by default: it spends upstream API budget and, for Gong, embedding work. Metadata imports only — setting it on a media import is a 400, since a media run ingests each file in full and has no metadata-only record to enrich.
Response
The created import, with latest_run reflecting the immediately-triggered first run when applicable
A saved bulk import: which connector to list, how to filter it, and how runs behave. What a run ingests depends on the collection — see import_type. Definitions are immutable — delete and recreate to change one.
Inferred from the collection's type at creation and fixed for the import's lifetime. metadata (metadata collections): source metadata is indexed, no media is downloaded, runs are free. media (every other collection type): each matching file is ingested and processed exactly like a manual add, billed per file.
metadata, media Backfill source-metadata fields the connector's list endpoint omits, after each index batch settles: Gong parties + Call Spotlight content (batched - enriched docs are re-embedded so the content is searchable) and Dropbox media_info duration/dimensions (per-file). No-op for other connectors. Off by default: it spends upstream API budget and, for Gong, embedding work. Metadata imports only — setting it on a media import is a 400, since a media run ingests each file in full and has no metadata-only record to enrich.