REST Resource: urlNotifications
资源:UrlNotification
UrlNotification
是在所有 Indexing API 调用中使用的资源。它描述了网络文档的生命周期中的一个事件。
字段 |
url |
string
此通知的对象。该网址的所有者必须是此通知的发布者;如果是 URL_UPDATED 通知,该网址必须能被 Google 抓取。
|
type |
enum(UrlNotificationType )
正在通知 Google 的相关网址生命周期事件。
|
notifyTime |
string (Timestamp format)
此通知的创建时间戳。用户不应指定该字段,该字段在请求时被忽略。 采用 RFC3339 世界协调时 (UTC)(即“祖鲁时”)格式且精确到纳秒的时间戳。示例:"2014-10-02T15:01:23.045123456Z" 。
|
UrlNotificationType
枚举 |
URL_NOTIFICATION_TYPE_UNSPECIFIED |
未指定。 |
URL_UPDATED |
给定网址(网络文档)已更新。 |
URL_DELETED |
给定网址(网络文档)已删除。 |
方法 |
|
获取网络文档的相关元数据。 |
|
通知已更新或删除某个网址。 |
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2025-02-17。
[null,null,["最后更新时间 (UTC):2025-02-17。"],[[["`UrlNotification` is the resource used for communicating URL updates and deletions to Google's Indexing API."],["The `UrlNotification` object utilizes `url`, `type`, and `notifyTime` fields to provide details about web document events."],["`UrlNotificationType` defines the specific event being communicated, such as URL updates (`URL_UPDATED`) or deletions (`URL_DELETED`)."],["The Indexing API provides methods for publishing URL notifications and retrieving web document metadata."]]],["The `UrlNotification` resource represents an event in a web document's lifecycle, used within the Indexing API. It includes the document's `url` (which must be owned by the publisher and crawlable if `URL_UPDATED`), the `type` of event (`URL_UPDATED` or `URL_DELETED`), and `notifyTime`. The API provides `publish` to send updates or deletions. A `getMetadata` method provides web document's information. `UrlNotificationType` defines the event type.\n"]]