Restore tables
POST
/api/meta/entity/bulk#restoreTables
Restore one or more soft-deleted (archived) tables.
The restoration relies on matches being found for the provided qualifiedName
s. If the this does not exactly match (case-sensitive) a soft-deleted table's qualifiedName
, the request will fail.
Note that the guid
is also required to avoid accidentally creating a new table. If the qualifiedName
does not match an existing table, and no guid
is supplied in the request, then this endpoint will create a new table with the provided details.
POST /api/meta/entity/bulk#restoreTables
curl \
-X POST https://tenant.atlan.com/api/meta/entity/bulk#restoreTables \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{"entities":[{"typeName":"Table","attributes":{"name":"customer","qualifiedName":"default/mongodb/mongodb.atlan.com/test_db/default/customer","connectorName":"mongodb","schemaName":"default","schemaQualifiedName":"default/mongodb/mongodb.atlan.com/test_db/default","databaseName":"test_db","databaseQualifiedName":"default/mongodb/mongodb.atlan.com/test_db","connectionQualifiedName":"default/mongodb/mongodb.atlan.com"},"relationshipAttributes":{"atlanSchema":{"typeName":"Schema","uniqueAttributes":{"qualifiedName":"default/mongodb/mongodb.atlan.com/test_db/default"}}},"guid":"dc14ffca-bf43-4731-b641-51408c4d892c","status":"ACTIVE"}]}'
Request example
{
"entities": [
{
"typeName": "Table",
"attributes": {
"name": "customer",
"qualifiedName": "default/mongodb/mongodb.atlan.com/test_db/default/customer",
"connectorName": "mongodb",
"schemaName": "default",
"schemaQualifiedName": "default/mongodb/mongodb.atlan.com/test_db/default",
"databaseName": "test_db",
"databaseQualifiedName": "default/mongodb/mongodb.atlan.com/test_db",
"connectionQualifiedName": "default/mongodb/mongodb.atlan.com"
},
"relationshipAttributes": {
"atlanSchema": {
"typeName": "Schema",
"uniqueAttributes": {
"qualifiedName": "default/mongodb/mongodb.atlan.com/test_db/default"
}
}
},
"guid": "dc14ffca-bf43-4731-b641-51408c4d892c",
"status": "ACTIVE"
}
]
}
Response example (200)
{
"mutatedEntities": {
"UPDATE": [
{
"typeName": "Table",
"attributes": {
"popularityScore": 1.17549435e-38,
"sourceCreatedAt": 0,
"viewerUsers": [],
"viewScore": 1.17549435e-38,
"lastSyncRunAt": 0,
"adminGroups": [],
"qualifiedName": "default/mongodb/mongodb.atlan.com/test_db/default/customer",
"__hasLineage": false,
"adminUsers": [],
"ownerGroups\"": [],
"isEditable": true,
"sourceUpdatedAt": 0,
"announcementUpdatedAt": 0,
"name": "customer",
"certificateUpdatedAt": 0,
"connectorName": "mongodb",
"schemaName": "default",
"schemaQualifiedName": "default/mongodb/mongodb.atlan.com/test_db/default",
"databaseName": "test_db",
"databaseQualifiedName": "default/mongodb/mongodb.atlan.com/test_db",
"connectionQualifiedName": "default/mongodb/mongodb.atlan.com",
"isDiscoverable": true,
"viewerGroups": [],
"ownerUsers": []
},
"guid": "dc14ffca-bf43-4731-b641-51408c4d892c",
"status": "ACTIVE",
"displayText": "default",
"classificationNames": [],
"classifications": [],
"meaningNames": [],
"meanings": [],
"isIncomplete": false,
"labels": [],
"createdBy": "service-account-apikey-bea1e1d1-e4e7-465e-8adf-7c61c227a59b",
"updatedBy": "service-account-apikey-bea1e1d1-e4e7-465e-8adf-7c61c227a59b",
"createTime": 1652795647900,
"updateTime": 1652795647900
}
]
},
"guidAssignments": {}
}
Response example (404)
{
"errorCode": "ATLAS-404-00-00A",
"errorMessage": "Referenced entity dc14ffca-bf43-4731-b641-51408c4d892c is not found",
"entityGuid": "dc14ffca-bf43-4731-b641-51408c4d892c"
}