curl -X PATCH 'https://api.hydradb.com/connectors/{id}/resources/{resource_id}' \
-H "Authorization: Bearer $HYDRA_DB_API_KEY" \
-H "API-Version: 2" \
-H "Content-Type: application/json" \
-d '{
"custom_instructions": "These threads are incident retros. Extract root cause, impact and owner."
}'
{
"connector_id": "{connector_id}",
"resource_id": "{resource_id}",
"custom_instructions": "These threads are incident retros. Extract root cause, impact and owner.",
"custom_instructions_updated": true
}
Update Connector Resource
Change one resource’s ingestion instructions or access rule, leaving everything else as it is.
curl -X PATCH 'https://api.hydradb.com/connectors/{id}/resources/{resource_id}' \
-H "Authorization: Bearer $HYDRA_DB_API_KEY" \
-H "API-Version: 2" \
-H "Content-Type: application/json" \
-d '{
"custom_instructions": "These threads are incident retros. Extract root cause, impact and owner."
}'
{
"connector_id": "{connector_id}",
"resource_id": "{resource_id}",
"custom_instructions": "These threads are incident retros. Extract root cause, impact and owner.",
"custom_instructions_updated": true
}
custom_instructions, acl, or both. At least one is required, and any field you omit is left unchanged. This is the safe way to edit a resource that is already syncing.
resource_id in the path is the id from List Connector Resources, for example a Slack channel id or a Supabase schema.table name. URL-encode it if it contains spaces or other reserved characters.
custom_instructionssets instructions for documents from this resource only. They replace the connector-level instructions for this resource rather than adding to them. Send""to clear them so the resource uses the connector’s instructions again. Up to 4,000 characters. They apply from the next sync; documents already synced are not processed again. See Custom Ingestion Instructions.aclsets who can read this resource’s objects, and applies to already-synced objects on the next query, with no re-sync. Use["__public__"]to open the resource to everyone and[]to allow nobody. For providers whose own permissions HydraDB reads, those permissions take over again at the next sync; your rule applies whenever the provider reports the resource as public or its permissions cannot be read. See Access Control.
curl -X PATCH 'https://api.hydradb.com/connectors/{id}/resources/{resource_id}' \
-H "Authorization: Bearer $HYDRA_DB_API_KEY" \
-H "API-Version: 2" \
-H "Content-Type: application/json" \
-d '{
"custom_instructions": "These threads are incident retros. Extract root cause, impact and owner."
}'
{
"connector_id": "{connector_id}",
"resource_id": "{resource_id}",
"custom_instructions": "These threads are incident retros. Extract root cause, impact and owner.",
"custom_instructions_updated": true
}
custom_instructions and acl only when the request set them, showing the stored values.
Errors
400: neither field was sent,custom_instructionsis over 4,000 characters, or the access rule is malformed. Nothing is changed.404: no connector with this id in your workspace, or no configured resource with thisresource_idon it.
Related Resources
- Update Connector: set the connector-level instructions these override
- Custom Ingestion Instructions: how connector and resource instructions combine
- List Connector Resources: read the stored values back
Authorizations
API key sent as a Bearer token: "Bearer prefix.secret"
Path Parameters
Connector ID
"HydraDoc1234"
Resource ID
"C0123456789"
Body
Resource settings to change
Who can read this resource's objects: emails, group:<provider>:<id>, domain:<domain>, or ["__public__"]. [] allows nobody. Provider permissions, where read, take over at the next sync.
Ingestion and indexing instructions for this resource, replacing the connector's. Omit to leave unchanged; "" clears back to the connector's. Up to 4000 characters, applied from the next sync.
Response
OK
The access rule as stored. Present only when the request set acl.
Connector this resource belongs to.
"conn_abc123"
The resource's instructions as stored; "" means they were cleared. Present only when the request set them.
true when this request set or cleared the resource's custom_instructions.
true
Resource identifier from the Discover endpoint.
"C0123456789"
Was this page helpful?
