Zum Inhalt springen

Update source

PUT
/api/sources/{sourceId}
curl --request PUT \
--url https://firma.company-gpt.com/companygpt/rag/api/api/sources/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0 \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "name": "example", "config": {}, "enabled": true, "syncSchedule": "example", "collectionId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0" }'
sourceId
required
string format: uuid
Media typeapplication/json

Type is immutable and not part of this request

object
name
string
config
object
key
additional properties
any
enabled
boolean
syncSchedule

Null/omitted: leave unchanged; “”: clear; “hourly”/“daily”/“weekly”: set

string
nullable
collectionId
string format: uuid
nullable
Examplegenerated
{
"name": "example",
"config": {},
"enabled": true,
"syncSchedule": "example",
"collectionId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0"
}

Source updated

Media typeapplication/json

Data source configuration (database.SourceConfig)

object
id
required
string format: uuid
name
required
string
sourceType
required
string
Allowed values: webcrawl sharepoint nextcloud git
config
required

Source-specific configuration

object
key
additional properties
any
enabled
required
boolean
syncSchedule
string
nullable
Allowed values: hourly daily weekly
collectionId
string format: uuid
nullable
createdBy
string format: uuid
nullable
createdAt
required
string format: date-time
updatedAt
required
string format: date-time
lastSyncAt
string format: date-time
nullable
Example
{
"sourceType": "webcrawl",
"syncSchedule": "hourly"
}

Invalid request

Unauthorized

Source not found