Properties
NAME | TYPE | DESCRIPTION |
$id | string | Collection ID. |
$createdAt | integer | Collection creation date in Unix timestamp. |
$updatedAt | integer | Collection update date in Unix timestamp. |
$read | array | Collection read permissions. |
$write | array | Collection write permissions. |
databaseId | string | Database ID. |
name | string | Collection name. |
enabled | boolean | Collection enabled. |
permission | string | Collection permission model. Possible values: `document` or `collection` |
attributes | array | Collection attributes. Can be one of: AttributeBoolean model, AttributeInteger model, AttributeFloat model, AttributeEmail model, AttributeEnum model, AttributeURL model, AttributeIP model, AttributeString model |
indexes | array | Collection indexes. Can be one of: |
Example
JSON
{
"$id": "5e5ea5c16897e",
"$createdAt": 1592981250,
"$updatedAt": 1592981250,
"$read": "role:all",
"$write": "user:608f9da25e7e1",
"databaseId": "5e5ea5c16897e",
"name": "My Collection",
"enabled": false,
"permission": "document",
"attributes": [
{
"key": "isEnabled",
"type": "boolean",
"status": "available",
"required": true,
"array": false,
"default": false
}
],
"indexes": [
{
"key": "index1",
"type": "primary",
"status": "available",
"attributes": [],
"orders": []
}
]
}
JSON
{
"_id": "5e5ea5c16897e",
"_createdAt": 1592981250,
"_updatedAt": 1592981250,
"_read": "role:all",
"_write": "user:608f9da25e7e1",
"databaseId": "5e5ea5c16897e",
"name": "My Collection",
"enabled": false,
"permission": "document",
"attributes": [
{
"key": "isEnabled",
"type": "boolean",
"status": "available",
"required": true,
"array": false,
"default": false
}
],
"indexes": [
{
"key": "index1",
"type": "primary",
"status": "available",
"attributes": [],
"orders": []
}
]
}