Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Browse API to Purview.Catalog #14602

Merged
merged 2 commits into from
Jun 17, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"parameters": {
"Endpoint": "{Endpoint}",
"browseRequest": {
"entityType": "azure_data_explorer_cluster",
"limit": 10
},
"api-version": "2021-05-01-preview"
},
"responses": {
"200": {
"body": {
"@search.count": 1,
"value": [
{
"id": "7afe6da2-4275-4096-90af-e40479cf70e2",
"name": "examplecluster.westus",
"qualifiedName": "https://examplecluster.westus.kusto.windows.net",
"entityType": "azure_data_explorer_cluster",
"path": "/azure_data_explorer_cluster#examplecluster.westus.kusto.windows.net",
"owner": [
{
"id": "12345678-1234-5678-1234-86b7251e0353",
"displayName": "Example DisplayName",
"mail": "example.displayname@microsoft.com",
"contactType": "Owner"
}
],
"isLeaf": false
}
]
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
{
"parameters": {
"Endpoint": "{Endpoint}",
"browseRequest": {
"path": "/azure_data_explorer_cluster#examplecluster.westus.kusto.windows.net",
"limit": 10
},
"api-version": "2021-05-01-preview"
},
"responses": {
"200": {
"body": {
"@search.count": 3,
"value": [
{
"id": "55656c92-7e29-4831-a243-f95bdcdd397b",
"name": "exampledata",
"qualifiedName": "https://examplecluster.westus.kusto.windows.net/exampledata",
"entityType": "azure_data_explorer_database",
"path": "/azure_data_explorer_cluster#examplecluster.westus.kusto.windows.net/azure_data_explorer_database#exampledata",
"owner": [
{
"id": "12345678-1234-5678-1234-86b7251e0353",
"displayName": "Example DisplayName",
"mail": "example.displayname@microsoft.com",
"contactType": "Owner"
}
],
"isLeaf": false
},
{
"id": "940aa60f-36f6-4dcf-8989-2faa49c74462",
"name": "exampledata2",
"qualifiedName": "https://examplecluster.westus.kusto.windows.net/exampledata2",
"entityType": "azure_data_explorer_database",
"path": "/azure_data_explorer_cluster#examplecluster.westus.kusto.windows.net/azure_data_explorer_database#exampledata2",
"owner": [
{
"id": "12345678-1234-5678-1234-86b7251e0353",
"displayName": "Example DisplayName",
"mail": "example.displayname@microsoft.com",
"contactType": "Owner"
}
],
"isLeaf": false
},
{
"id": "19c4a337-840b-442d-ac9c-3df65bb33d69",
"name": "exampledata3",
"qualifiedName": "https://examplecluster.westus.kusto.windows.net/exampledata3",
"entityType": "azure_data_explorer_database",
"path": "/azure_data_explorer_cluster#examplecluster.westus.kusto.windows.net/azure_data_explorer_database#exampledata3",
"owner": [
{
"id": "12345678-1234-5678-1234-86b7251e0353",
"displayName": "Example DisplayName",
"mail": "example.displayname@microsoft.com",
"contactType": "Owner"
}
],
"isLeaf": false
}
]
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2193,6 +2193,45 @@
}
}
},
"/browse": {
"post": {
"tags": [
"Discovery"
],
"description": "Browse entities by path or entity type.",
"operationId": "Discovery_Browse",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needs review by archboard

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The API has been reviewed by SDK team.

"x-ms-examples": {
"Discovery_Browse_Path": {
"$ref": "./examples/Discovery_Browse_Path.json"
},
"Discovery_Browse_EntityType": {
"$ref": "./examples/Discovery_Browse_EntityType.json"
}
},
"parameters": [
{
"in": "body",
"name": "browseRequest",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needs review by archboard

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The API has been reviewed by SDK team.

"description": "An object specifying the browse criteria.",
"required": true,
"schema": {
"$ref": "#/definitions/BrowseRequest"
}
},
{
"$ref": "#/parameters/purviewAPIVersion"
}
],
"responses": {
"200": {
"description": "OK. On successful get the entities to browse.",
"schema": {
"$ref": "#/definitions/BrowseResult"
}
}
}
}
},
"/search/autocomplete": {
"post": {
"tags": [
Expand Down Expand Up @@ -5367,6 +5406,24 @@
"title": "SuggestResult",
"description": "The result item of the search suggest."
},
"BrowseResult": {
"type": "object",
"properties": {
"@search.count": {
"type": "integer",
"format": "int32",
"description": "The total number of browse results."
},
"value": {
"type": "array",
"items": {
"$ref": "#/definitions/BrowseResultValue"
}
}
},
"title": "BrowseResult",
"description": "The result item of the browse request."
},
"SuggestResultValue": {
"type": "object",
"properties": {
Expand Down Expand Up @@ -5442,6 +5499,67 @@
"title": "SuggestResultValue",
"description": "The value item of the search suggest."
},
"BrowseResultValue": {
"type": "object",
"properties": {
"entityType": {
"type": "string",
"description": "The type name of the record."
},
"id": {
"type": "string",
"description": "The GUID of the record."
},
"isLeaf": {
"type": "boolean",
"description": "If the record is a leaf entity."
},
"name": {
"type": "string",
"description": "The name of the record."
},
"owner": {
"type": "array",
"description": "The owners of the record.",
"items": {
"$ref": "#/definitions/BrowseResultOwner"
}
},
"path": {
"type": "string",
"description": "The path of the record."
},
"qualifiedName": {
"type": "string",
"description": "The qualified name of the record."
}
},
"title": "BrowseResultValue",
"description": "The value item of the browse result."
},
"BrowseResultOwner": {
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "The GUID of the owner."
},
"displayName": {
"type": "string",
"description": "The display name of the owner."
},
"mail": {
"type": "string",
"description": "The mail of the owner."
},
"contactType": {
"type": "string",
"description": "The contact type of the owner. The value will be Owner."
}
},
"title": "BrowseResultOwner",
"description": "The value item of the browse owner."
},
"SearchResult": {
"type": "object",
"properties": {
Expand Down Expand Up @@ -5830,6 +5948,31 @@
"title": "SearchRequest",
"description": "The search query of advanced search request."
},
"BrowseRequest": {
"type": "object",
"properties": {
"entityType": {
"type": "string",
"description": "The entity type to browse as the root level entry point."
},
"path": {
"type": "string",
"description": "The path to browse the next level child entities."
},
"limit": {
"type": "integer",
"format": "int32",
"description": "The number of browse items we hope to return."
},
"offset": {
"type": "integer",
"format": "int32",
"description": "The offset. The default value is 0."
}
},
"title": "BrowseRequest",
"description": "The criteria of browse request."
},
"SuggestRequest": {
"type": "object",
"properties": {
Expand Down