from metadata.sdk import configure
from metadata.sdk.entities import DatabaseSchemas
configure(
host="https://your-company.getcollate.io/api",
jwt_token="your-jwt-token"
)
# List with pagination
page = DatabaseSchemas.list(limit=50, fields=["owners", "tags"])
for s in page.entities:
print(f"{s.fullyQualifiedName}")
if s.owners:
print(f" Owners: {[o.name for o in s.owners]}")
# List all with auto-pagination
all_schemas = DatabaseSchemas.list_all(batch_size=100)
for schema in all_schemas:
print(f"{schema.fullyQualifiedName}")
{
"data": [
{
"id": "f681432b-e66c-4096-a1cd-7771358c5323",
"name": "information_schema",
"fullyQualifiedName": "Glue.default.information_schema",
"description": "This **mock** database contains tables related to the Glue service",
"version": 0.1,
"updatedAt": 1769982658171,
"updatedBy": "admin",
"href": "http://localhost:8585/api/v1/databaseSchemas/f681432b-e66c-4096-a1cd-7771358c5323",
"owners": [],
"service": {
"id": "0fab117a-4c58-4ebb-9d42-beab0768fa8e",
"type": "databaseService",
"name": "Glue",
"fullyQualifiedName": "Glue",
"displayName": "Glue",
"deleted": false,
"href": "http://localhost:8585/api/v1/services/databaseServices/0fab117a-4c58-4ebb-9d42-beab0768fa8e"
},
"serviceType": "Glue",
"database": {
"id": "9655ba5b-b8d7-419c-98f4-16b976692ad8",
"type": "database",
"name": "default",
"fullyQualifiedName": "Glue.default",
"description": "This **mock** database contains tables related to the Glue service",
"displayName": "default",
"deleted": false,
"href": "http://localhost:8585/api/v1/databases/9655ba5b-b8d7-419c-98f4-16b976692ad8"
},
"tables": [
{
"id": "49cae725-62e6-48b4-b604-7ea915659d9a",
"type": "table",
"name": "sales",
"fullyQualifiedName": "Glue.default.information_schema.sales",
"description": "Sales data",
"displayName": "sales",
"deleted": false,
"href": "http://localhost:8585/api/v1/tables/49cae725-62e6-48b4-b604-7ea915659d9a"
},
{
"id": "b9988329-cb3e-469b-8d10-d6a21de8b0b9",
"type": "table",
"name": "marketing",
"fullyQualifiedName": "Glue.default.information_schema.marketing",
"description": "Marketing data",
"displayName": "marketing",
"deleted": false,
"href": "http://localhost:8585/api/v1/tables/b9988329-cb3e-469b-8d10-d6a21de8b0b9"
}
],
"tags": [],
"deleted": false,
"sourceUrl": "https://www.glue.com/information_schema",
"domains": [],
"entityStatus": "Unprocessed"
}
],
"paging": {
"after": "...",
"total": 28
}
}
List all database schema entities with optional filtering by database, owner, tag, domain, and pagination support via the Collate REST API.
from metadata.sdk import configure
from metadata.sdk.entities import DatabaseSchemas
configure(
host="https://your-company.getcollate.io/api",
jwt_token="your-jwt-token"
)
# List with pagination
page = DatabaseSchemas.list(limit=50, fields=["owners", "tags"])
for s in page.entities:
print(f"{s.fullyQualifiedName}")
if s.owners:
print(f" Owners: {[o.name for o in s.owners]}")
# List all with auto-pagination
all_schemas = DatabaseSchemas.list_all(batch_size=100)
for schema in all_schemas:
print(f"{schema.fullyQualifiedName}")
{
"data": [
{
"id": "f681432b-e66c-4096-a1cd-7771358c5323",
"name": "information_schema",
"fullyQualifiedName": "Glue.default.information_schema",
"description": "This **mock** database contains tables related to the Glue service",
"version": 0.1,
"updatedAt": 1769982658171,
"updatedBy": "admin",
"href": "http://localhost:8585/api/v1/databaseSchemas/f681432b-e66c-4096-a1cd-7771358c5323",
"owners": [],
"service": {
"id": "0fab117a-4c58-4ebb-9d42-beab0768fa8e",
"type": "databaseService",
"name": "Glue",
"fullyQualifiedName": "Glue",
"displayName": "Glue",
"deleted": false,
"href": "http://localhost:8585/api/v1/services/databaseServices/0fab117a-4c58-4ebb-9d42-beab0768fa8e"
},
"serviceType": "Glue",
"database": {
"id": "9655ba5b-b8d7-419c-98f4-16b976692ad8",
"type": "database",
"name": "default",
"fullyQualifiedName": "Glue.default",
"description": "This **mock** database contains tables related to the Glue service",
"displayName": "default",
"deleted": false,
"href": "http://localhost:8585/api/v1/databases/9655ba5b-b8d7-419c-98f4-16b976692ad8"
},
"tables": [
{
"id": "49cae725-62e6-48b4-b604-7ea915659d9a",
"type": "table",
"name": "sales",
"fullyQualifiedName": "Glue.default.information_schema.sales",
"description": "Sales data",
"displayName": "sales",
"deleted": false,
"href": "http://localhost:8585/api/v1/tables/49cae725-62e6-48b4-b604-7ea915659d9a"
},
{
"id": "b9988329-cb3e-469b-8d10-d6a21de8b0b9",
"type": "table",
"name": "marketing",
"fullyQualifiedName": "Glue.default.information_schema.marketing",
"description": "Marketing data",
"displayName": "marketing",
"deleted": false,
"href": "http://localhost:8585/api/v1/tables/b9988329-cb3e-469b-8d10-d6a21de8b0b9"
}
],
"tags": [],
"deleted": false,
"sourceUrl": "https://www.glue.com/information_schema",
"domains": [],
"entityStatus": "Unprocessed"
}
],
"paging": {
"after": "...",
"total": 28
}
}
owners, tables, usageSummary, tags, certification, extension, domains, sourceHash, followers.all, deleted, or non-deleted entities.from metadata.sdk import configure
from metadata.sdk.entities import DatabaseSchemas
configure(
host="https://your-company.getcollate.io/api",
jwt_token="your-jwt-token"
)
# List with pagination
page = DatabaseSchemas.list(limit=50, fields=["owners", "tags"])
for s in page.entities:
print(f"{s.fullyQualifiedName}")
if s.owners:
print(f" Owners: {[o.name for o in s.owners]}")
# List all with auto-pagination
all_schemas = DatabaseSchemas.list_all(batch_size=100)
for schema in all_schemas:
print(f"{schema.fullyQualifiedName}")
{
"data": [
{
"id": "f681432b-e66c-4096-a1cd-7771358c5323",
"name": "information_schema",
"fullyQualifiedName": "Glue.default.information_schema",
"description": "This **mock** database contains tables related to the Glue service",
"version": 0.1,
"updatedAt": 1769982658171,
"updatedBy": "admin",
"href": "http://localhost:8585/api/v1/databaseSchemas/f681432b-e66c-4096-a1cd-7771358c5323",
"owners": [],
"service": {
"id": "0fab117a-4c58-4ebb-9d42-beab0768fa8e",
"type": "databaseService",
"name": "Glue",
"fullyQualifiedName": "Glue",
"displayName": "Glue",
"deleted": false,
"href": "http://localhost:8585/api/v1/services/databaseServices/0fab117a-4c58-4ebb-9d42-beab0768fa8e"
},
"serviceType": "Glue",
"database": {
"id": "9655ba5b-b8d7-419c-98f4-16b976692ad8",
"type": "database",
"name": "default",
"fullyQualifiedName": "Glue.default",
"description": "This **mock** database contains tables related to the Glue service",
"displayName": "default",
"deleted": false,
"href": "http://localhost:8585/api/v1/databases/9655ba5b-b8d7-419c-98f4-16b976692ad8"
},
"tables": [
{
"id": "49cae725-62e6-48b4-b604-7ea915659d9a",
"type": "table",
"name": "sales",
"fullyQualifiedName": "Glue.default.information_schema.sales",
"description": "Sales data",
"displayName": "sales",
"deleted": false,
"href": "http://localhost:8585/api/v1/tables/49cae725-62e6-48b4-b604-7ea915659d9a"
},
{
"id": "b9988329-cb3e-469b-8d10-d6a21de8b0b9",
"type": "table",
"name": "marketing",
"fullyQualifiedName": "Glue.default.information_schema.marketing",
"description": "Marketing data",
"displayName": "marketing",
"deleted": false,
"href": "http://localhost:8585/api/v1/tables/b9988329-cb3e-469b-8d10-d6a21de8b0b9"
}
],
"tags": [],
"deleted": false,
"sourceUrl": "https://www.glue.com/information_schema",
"domains": [],
"entityStatus": "Unprocessed"
}
],
"paging": {
"after": "...",
"total": 28
}
}
fields parameter to request additional data.
Show properties
service.database.schema.fields contains owners.fields contains tags.fields contains domains.fields contains tables.fields contains usageSummary.fields contains certification.fields contains extension.fields contains sourceHash.fields contains followers.Was this page helpful?