All Products
Search
Document Center

DataWorks:ListLineages

更新時間:Dec 04, 2025

Queries a list of ancestor and descendant entities of an entity in Data Map. You can specify whether to return the lineage between the entities.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • For mandatory resource types, indicate with a prefix of * .
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
dataworks:ListLineageslist
*All Resources
*
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
SrcEntityIdstringNo

The source entity ID. You can refer to the table or column ID returned by the ListTables or ListColumns operation, or use a custom entity ID.

maxcompute-table:123456XXX::test_project::test_tbl dlf-table:123456XXX:test_catalog:test_db::test_tbl hms-table:c-abc123xxx::test_db::test_tbl holo-table:h-abc123xxx::test_db:test_schema:test_tbl custom-api:api123 custom-table:table456
DstEntityIdstringNo

The destination entity ID. You can refer to the table or column ID returned by the ListTables or ListColumns operation, or use a custom entity ID.

maxcompute-table:123456XXX::test_project::test_tbl dlf-table:123456XXX:test_catalog:test_db::test_tbl hms-table:c-abc123xxx::test_db::test_tbl holo-table:h-abc123xxx::test_db:test_schema:test_tbl custom-api:api123 custom-table:table456
SrcEntityNamestringNo

The source entity name. Supports fuzzy matching.

srcName1
DstEntityNamestringNo

The destination entity name. Supports fuzzy matching.

dstName1
NeedAttachRelationshipbooleanNo

Specifies whether to return lineage information.

false
SortBystringNo

The sort field. Default value: Name.

Name
OrderstringNo

The sort order. Default value: Asc. Valid values:

  • Asc
  • Desc
Asc
PageNumberintegerNo

The page number. Default value: 1.

1
PageSizeintegerNo

The number of records per page. Default value: 10. Maximum value: 100.

10

Response parameters

ParameterTypeDescriptionExample
object

The response.

RequestIdstring

The request ID.

0000-ABCD-EFG****
Successboolean

Indicates whether the request was successful.

true
PagingInfoobject

The pagination result.

TotalCountlong

Total record count.

12
PageNumberinteger

The requested page number for pagination.

1
PageSizeinteger

The page size. Default value: 10.

10
Lineagesarray<object>

The lineage information list.

Lineagesobject

The lineage information.

SrcEntityLineageEntity

The source entity.

DstEntityLineageEntity

The destination entity.

Relationshipsarray

The lineage details.

RelationshipsLineageRelationship

The lineage detail.

Examples

Sample success responses

JSONformat

{
  "RequestId": "0000-ABCD-EFG****",
  "Success": true,
  "PagingInfo": {
    "TotalCount": 12,
    "PageNumber": 1,
    "PageSize": 10,
    "Lineages": [
      {
        "SrcEntity": {
          "Id": "maxcompute-table:123456XXX::test_project::test_tbl\ndlf-table:123456XXX:test_catalog:test_db::test_tbl\nhms-table:c-abc123xxx::test_db::test_tbl\nholo-table:h-abc123xxx::test_db:test_schema:test_tbl\ncustom-api:api123\ncustom-table:table456",
          "Name": "test_tbl",
          "Attributes": {
            "key": "key1:value1"
          }
        },
        "DstEntity": {
          "Id": "maxcompute-table:123456XXX::test_project::test_tbl\ndlf-table:123456XXX:test_catalog:test_db::test_tbl\nhms-table:c-abc123xxx::test_db::test_tbl\nholo-table:h-abc123xxx::test_db:test_schema:test_tbl\ncustom-api:api123\ncustom-table:table456",
          "Name": "test_tbl",
          "Attributes": {
            "key": "key1:value1"
          }
        },
        "Relationships": [
          {
            "SrcEntity": {
              "Id": "maxcompute-table:123456XXX::test_project::test_tbl\ndlf-table:123456XXX:test_catalog:test_db::test_tbl\nhms-table:c-abc123xxx::test_db::test_tbl\nholo-table:h-abc123xxx::test_db:test_schema:test_tbl\ncustom-api:api123\ncustom-table:table456",
              "Name": "test_tbl",
              "Attributes": {
                "key": "key1:value1"
              }
            },
            "Task": {
              "Id": 12345,
              "Type": "custom-sql",
              "Attributes": {
                "key": "key1:value21"
              }
            },
            "Id": "maxcompute-table.p.table:custom-table.xxx:custom-sql.123",
            "CreateTime": 1743040581000
          }
        ]
      }
    ]
  }
}

Error codes

For a list of error codes, visit the Service error codes.