curl -X POST 'https://api.example.com/resource-collections/batch' \
-H 'Authorization: Bearer YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d '[
{
"scopeId": "scope_org",
"resourceTypeId": "rtype_document",
"name": "Finance Documents",
"matchDefinition": {
"tags": { "department": "finance" }
}
},
{
"scopeId": "scope_org",
"resourceTypeId": "rtype_document",
"name": "Legal Documents",
"matchDefinition": {
"tags": { "department": "legal" }
}
}
]'
[
{
"id": "collection_0190a1b2-c3d4-7e5f-8a9b-0c1d2e3f4a5b",
"scopeId": "scope_org",
"resourceTypeId": "rtype_document",
"name": "Finance Documents",
"matchDefinition": {
"tags": { "department": "finance" }
},
"createdAt": "2024-01-15T10:30:00Z"
},
{
"id": "collection_0190a1b2-c3d4-7e5f-8a9b-0c1d2e3f4a5c",
"scopeId": "scope_org",
"resourceTypeId": "rtype_document",
"name": "Legal Documents",
"matchDefinition": {
"tags": { "department": "legal" }
},
"createdAt": "2024-01-15T10:30:00Z"
}
]
Create multiple resource collections at once
curl -X POST 'https://api.example.com/resource-collections/batch' \
-H 'Authorization: Bearer YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d '[
{
"scopeId": "scope_org",
"resourceTypeId": "rtype_document",
"name": "Finance Documents",
"matchDefinition": {
"tags": { "department": "finance" }
}
},
{
"scopeId": "scope_org",
"resourceTypeId": "rtype_document",
"name": "Legal Documents",
"matchDefinition": {
"tags": { "department": "legal" }
}
}
]'
[
{
"id": "collection_0190a1b2-c3d4-7e5f-8a9b-0c1d2e3f4a5b",
"scopeId": "scope_org",
"resourceTypeId": "rtype_document",
"name": "Finance Documents",
"matchDefinition": {
"tags": { "department": "finance" }
},
"createdAt": "2024-01-15T10:30:00Z"
},
{
"id": "collection_0190a1b2-c3d4-7e5f-8a9b-0c1d2e3f4a5c",
"scopeId": "scope_org",
"resourceTypeId": "rtype_document",
"name": "Legal Documents",
"matchDefinition": {
"tags": { "department": "legal" }
},
"createdAt": "2024-01-15T10:30:00Z"
}
]
collection_{uuidv7}curl -X POST 'https://api.example.com/resource-collections/batch' \
-H 'Authorization: Bearer YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d '[
{
"scopeId": "scope_org",
"resourceTypeId": "rtype_document",
"name": "Finance Documents",
"matchDefinition": {
"tags": { "department": "finance" }
}
},
{
"scopeId": "scope_org",
"resourceTypeId": "rtype_document",
"name": "Legal Documents",
"matchDefinition": {
"tags": { "department": "legal" }
}
}
]'
[
{
"id": "collection_0190a1b2-c3d4-7e5f-8a9b-0c1d2e3f4a5b",
"scopeId": "scope_org",
"resourceTypeId": "rtype_document",
"name": "Finance Documents",
"matchDefinition": {
"tags": { "department": "finance" }
},
"createdAt": "2024-01-15T10:30:00Z"
},
{
"id": "collection_0190a1b2-c3d4-7e5f-8a9b-0c1d2e3f4a5c",
"scopeId": "scope_org",
"resourceTypeId": "rtype_document",
"name": "Legal Documents",
"matchDefinition": {
"tags": { "department": "legal" }
},
"createdAt": "2024-01-15T10:30:00Z"
}
]
Was this page helpful?