Method: debug.datasources.items.searchByViewUrl
Tetap teratur dengan koleksi
Simpan dan kategorikan konten berdasarkan preferensi Anda.
Mengambil item yang viewUrl-nya sama persis dengan URL yang diberikan dalam permintaan.
Catatan: API ini memerlukan akun admin untuk dieksekusi.
Permintaan HTTP
POST https://cloudsearch.googleapis.com/v1/debug/{name=datasources/*}/items:searchByViewUrl
URL menggunakan sintaksis gRPC Transcoding.
Parameter jalur
Parameter |
name |
string
Nama sumber, format: datasources/{sourceId}
|
Isi permintaan
Isi permintaan memuat data dengan struktur berikut:
Representasi JSON |
{
"viewUrl": string,
"pageToken": string,
"debugOptions": {
object (DebugOptions )
}
} |
Kolom |
viewUrl |
string
Tentukan URL tampilan lengkap untuk menemukan item yang sesuai. Panjang maksimumnya adalah 2048 karakter.
|
pageToken |
string
Nilai nextPageToken yang ditampilkan dari permintaan sebelumnya, jika ada.
|
debugOptions |
object (DebugOptions )
Opsi debug umum.
|
Isi respons
Jika berhasil, isi respons memuat data dengan struktur berikut:
Representasi JSON |
{
"items": [
{
object (Item )
}
],
"nextPageToken": string
} |
Kolom |
items[] |
object (Item )
|
nextPageToken |
string
Token untuk mengambil halaman hasil berikutnya, atau kosong jika tidak ada lagi hasil dalam daftar.
|
Cakupan otorisasi
Memerlukan salah satu cakupan OAuth berikut:
https://www.googleapis.com/auth/cloud_search.debug
https://www.googleapis.com/auth/cloud_search
Untuk mengetahui informasi selengkapnya, lihat Panduan otorisasi.
Kecuali dinyatakan lain, konten di halaman ini dilisensikan berdasarkan Lisensi Creative Commons Attribution 4.0, sedangkan contoh kode dilisensikan berdasarkan Lisensi Apache 2.0. Untuk mengetahui informasi selengkapnya, lihat Kebijakan Situs Google Developers. Java adalah merek dagang terdaftar dari Oracle dan/atau afiliasinya.
Terakhir diperbarui pada 2025-07-25 UTC.
[null,null,["Terakhir diperbarui pada 2025-07-25 UTC."],[],[],null,["# Method: debug.datasources.items.searchByViewUrl\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Path parameters](#body.PATH_PARAMETERS)\n- [Request body](#body.request_body)\n - [JSON representation](#body.request_body.SCHEMA_REPRESENTATION)\n- [Response body](#body.response_body)\n - [JSON representation](#body.SearchItemsByViewUrlResponse.SCHEMA_REPRESENTATION)\n- [Authorization scopes](#body.aspect)\n- [Try it!](#try-it)\n\nFetches the item whose viewUrl exactly matches that of the URL provided in the request.\n\n**Note:** This API requires an admin account to execute.\n\n### HTTP request\n\n`POST https://cloudsearch.googleapis.com/v1/debug/{name=datasources/*}/items:searchByViewUrl`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n| Parameters ||\n|--------|------------------------------------------------------|\n| `name` | `string` Source name, format: datasources/{sourceId} |\n\n### Request body\n\nThe request body contains data with the following structure:\n\n| JSON representation |\n|----------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"viewUrl\": string, \"pageToken\": string, \"debugOptions\": { object (/workspace/cloud-search/docs/reference/rest/v1/DebugOptions) } } ``` |\n\n| Fields ||\n|----------------|----------------------------------------------------------------------------------------------------------------|\n| `viewUrl` | `string` Specify the full view URL to find the corresponding item. The maximum length is 2048 characters. |\n| `pageToken` | `string` The nextPageToken value returned from a previous request, if any. |\n| `debugOptions` | `object (`[DebugOptions](/workspace/cloud-search/docs/reference/rest/v1/DebugOptions)`)` Common debug options. |\n\n### Response body\n\nIf successful, the response body contains data with the following structure:\n\n| JSON representation |\n|-----------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"items\": [ { object (/workspace/cloud-search/docs/reference/rest/v1/indexing.datasources.items#Item) } ], \"nextPageToken\": string } ``` |\n\n| Fields ||\n|-----------------|---------------------------------------------------------------------------------------------------------|\n| `items[]` | `object (`[Item](/workspace/cloud-search/docs/reference/rest/v1/indexing.datasources.items#Item)`)` |\n| `nextPageToken` | `string` Token to retrieve the next page of results, or empty if there are no more results in the list. |\n\n### Authorization scopes\n\nRequires one of the following OAuth scopes:\n\n- `https://www.googleapis.com/auth/cloud_search.debug`\n- `https://www.googleapis.com/auth/cloud_search`\n\nFor more information, see the [Authorization guide](/workspace/guides/configure-oauth-consent)."]]