Thành phần: quảng cáo tìm kiếm
Sử dụng bộ sưu tập để sắp xếp ngăn nắp các trang
Lưu và phân loại nội dung dựa trên lựa chọn ưu tiên của bạn.
Tìm kiếm các thành phần của người dùng trên Looker Studio.
Yêu cầu
Yêu cầu HTTP
GET https://datastudio.googleapis.com/v1/assets:search
Thông số
Tên thông số |
Loại |
Mô tả |
assetTypes |
Array<AssetType> |
Bắt buộc. Loại tài sản cần tìm kiếm. Bạn phải chỉ định đúng một loại tài sản. |
tiêu đề |
chuỗi |
Chuỗi tìm kiếm. Theo mặc định, chuỗi này được kiểm tra dựa trên tiêu đề và nội dung mô tả của thành phần. Hãy xem phần Ví dụ để biết các chuỗi tìm kiếm nâng cao. |
includeTrashed |
boolean |
Giá trị mặc định là false .
- Khi bạn đặt tham số này thành
true , chỉ những tài sản trong thùng rác mới được đưa vào. - Khi tham số này được đặt thành
false , chỉ những thành phần không nằm trong thùng rác mới được đưa vào.
|
chủ sở hữu |
chuỗi |
Email của chủ sở hữu tài sản. |
orderBy |
chuỗi |
Thứ tự của kết quả. Bạn có thể sắp xếp theo các trường sau:
title
last_viewed_by_me
create_time
last_accessed_time
id
|
pageSize |
số |
Số lượng kết quả cần đưa vào mỗi trang. Giá trị mặc định là 1000. |
pageToken |
chuỗi |
Mã thông báo xác định một trang kết quả cần trả về. Để phân trang kết quả, hãy sử dụng giá trị nextPageToken hoặc giá trị previousPageToken từ một yêu cầu khác. |
Ủy quyền
Yêu cầu này cần có uỷ quyền với ít nhất một trong các phạm vi sau:
Phạm vi |
https://www.googleapis.com/auth/datastudio.readonly |
https://www.googleapis.com/auth/datastudio |
Nội dung yêu cầu
Không cung cấp nội dung yêu cầu bằng phương thức này.
Phản hồi
Nếu thành công, phương thức này sẽ trả về một phần nội dung phản hồi có cấu trúc sau:
{
"assets": [Asset],
"nextPageToken": string
}
Tên tài sản |
Loại |
Mô tả |
tài sản |
Array<Asset> |
Danh sách tài sản. |
nextPageToken |
chuỗi |
Mã thông báo để truy xuất trang kết quả tiếp theo. Thuộc tính này chỉ xuất hiện khi số lượng kết quả lớn hơn yêu cầu pageSize . nextPageToken trống cho biết không còn kết quả nào để trả về. |
previousPageToken |
chuỗi |
Mã thông báo để truy xuất trang kết quả trước đó. previousPageToken trống cho biết điểm bắt đầu của tập kết quả. |
Ví dụ
Bạn có thể truyền các chuỗi tìm kiếm nâng cao trong trường title
.
Bạn có thể sử dụng nhiều loại tìm kiếm trong một chuỗi tìm kiếm duy nhất.
Hãy xem bảng sau để biết cú pháp chuỗi tìm kiếm được hỗ trợ. Bạn có thể kết hợp nhiều chuỗi tìm kiếm.
Lọc |
Định nghĩa |
Ví dụ |
Nhà sáng tạo |
Tìm kiếm những tài sản do một người dùng cụ thể tạo. |
creator:me creator:user@example.com
|
Chủ sở hữu |
Tìm tài sản do một người dùng cụ thể sở hữu. |
owner:me owner:user@example.com
|
Dự án |
Tìm kiếm thành phần trong một dự án. |
|
Không gian làm việc |
Tìm kiếm thành phần trong một không gian làm việc hoặc thư mục. |
parentWorkspace:2a080c66-50cb-4399-92a8-74c534da2de9
|
Từ |
Tìm kiếm những thành phần mà người dùng đã chia sẻ với bạn. |
|
Đến |
Tìm kiếm những thành phần mà bạn đã chia sẻ với một người dùng hoặc nhóm. |
to:user@example.com to:example-group@googlegroups.com
|
Trừ phi có lưu ý khác, nội dung của trang này được cấp phép theo Giấy phép ghi nhận tác giả 4.0 của Creative Commons và các mẫu mã lập trình được cấp phép theo Giấy phép Apache 2.0. Để biết thông tin chi tiết, vui lòng tham khảo Chính sách trang web của Google Developers. Java là nhãn hiệu đã đăng ký của Oracle và/hoặc các đơn vị liên kết với Oracle.
Cập nhật lần gần đây nhất: 2025-07-25 UTC.
[null,null,["Cập nhật lần gần đây nhất: 2025-07-25 UTC."],[[["\u003cp\u003eSearch for specific Looker Studio assets using parameters like asset type, title, owner, and more.\u003c/p\u003e\n"],["\u003cp\u003eFilter search results to include or exclude trashed assets.\u003c/p\u003e\n"],["\u003cp\u003eOrder results by title and control the number of results per page using pagination.\u003c/p\u003e\n"],["\u003cp\u003eRequires authorization with specific scopes for data access.\u003c/p\u003e\n"],["\u003cp\u003eThe API response includes a list of matching assets and a token for retrieving subsequent pages.\u003c/p\u003e\n"]]],[],null,["# Assets: search\n\nSearch a user's Looker Studio assets.\n\nRequest\n-------\n\n### HTTP request\n\n GET https://datastudio.googleapis.com/v1/assets:search\n\n### Parameters\n\n| Parameter name | Type | Description |\n|----------------|------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| assetTypes | Array\\\u003c[AssetType](/looker-studio/integrate/api/reference/types#AssetType)\\\u003e | **Required**. The asset type to search. Exactly one asset type must be specified. |\n| title | string | The search string. By default, the string is checked against the title and description of the asset. See the [Examples](#examples) section for advanced search strings. |\n| includeTrashed | boolean | Defaults to `false`. - When this parameter is set to `true`, only assets from the trash are included. - When this parameter is set to `false`, only assets not in the trash are included. |\n| owner | string | The asset owner's email. |\n| orderBy | string | The order of the results. You can sort by the following fields: - `title` - `last_viewed_by_me` - `create_time` - `last_accessed_time` - `id` |\n| pageSize | number | The number of results to include per page. Defaults to 1000. |\n| pageToken | string | A token identifying a page of results to return. To paginate results, use a `nextPageToken` value or `previousPageToken` value from another request. |\n\n### Authorization\n\nThis request requires authorization with at least one of the following scopes:\n\n| Scope |\n|-------------------------------------------------------|\n| `https://www.googleapis.com/auth/datastudio.readonly` |\n| `https://www.googleapis.com/auth/datastudio` |\n\n### Request body\n\nDon't supply a request body with this method.\n\nResponse\n--------\n\nIf successful, this method returns a response body with the following structure: \n\n {\n \"assets\": [Asset],\n \"nextPageToken\": string\n }\n\n| Property name | Type | Description |\n|-------------------|----------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| assets | Array\\\u003c[Asset](/looker-studio/integrate/api/reference/types#Asset)\\\u003e | The list of assets. |\n| nextPageToken | string | A token to retrieve the next page of results. This property is only present when the number of results is greater than the request `pageSize`. An empty `nextPageToken` indicates that there are no more results to return. |\n| previousPageToken | string | A token to retrieve the previous page of results. An empty `previousPageToken` indicates the beginning of the result set. |\n\nExamples\n--------\n\nYou can pass advanced search strings in the `title` field.\nYou can use multiple search types in a single search string.\nSee the following table for supported search string syntax. You can combine\nmultiple search strings.\n\n| Filter | Definition | Examples |\n|-----------|--------------------------------------------------------------|---------------------------------------------------------------|\n| Creator | Search for assets created by a specific user. | - `creator:me` - `creator:user@example.com` |\n| Owner | Search for assets owned by a specific user. | - `owner:me` - `owner:user@example.com` |\n| Project | Search for assets in a project. | - `projectNumber:123456789` |\n| Workspace | Search for assets in a workspace or folder. | - `parentWorkspace:2a080c66-50cb-4399-92a8-74c534da2de9` |\n| From | Search for assets that a user has shared with you. | - `from:user@example.com` |\n| To | Search for assets that you have shared with a user or group. | - `to:user@example.com` - `to:example-group@googlegroups.com` |"]]