Indexing
Indexing has 2 operations in gum's generated catalog. Start with search when you know the task, use describe to inspect request fields and scopes, then dispatch through the command that matches the operation risk class.
| Count | Value |
|---|---|
| Family | Search and media |
| Operations | 2 |
| Risk classes | 1 read, 1 write |
| Auth strategies | 2 byo_oauth |
Start here
gum search "indexing"
gum describe indexing.urlNotifications.getMetadata
gum read indexing.urlNotifications.getMetadata --args '{"fields":"id"}' --output jsonFor write-class operations, gum requires the write command and an explicit write gate:
gum describe indexing.urlNotifications.publish
gum write indexing.urlNotifications.publish --allow-write --args '{"fields":"id"}'Auth
Auth strategies in this service: 2 byo_oauth. Authenticate the strategy used by the operation you plan to call.
Bring-your-own OAuth
- In Google Cloud, enable Indexing API.
- Configure the OAuth consent screen. Add your Google account as a test user when the app is still in testing mode.
- Create an OAuth client ID with application type
Desktop app. - Add the scopes this service needs to the consent screen.
- Store the client in gum:
printf '%s' "$GOOGLE_OAUTH_CLIENT_SECRET" \
| gum auth use-oauth-client --client-id "$GOOGLE_OAUTH_CLIENT_ID" --secret-stdin- Authorize this service:
gum login --service indexing- Verify the grant before dispatch:
gum auth status --scopes indexing
gum describe indexing.urlNotifications.getMetadataScopes used by these operations:
https://www.googleapis.com/auth/indexing
Service setup notes: Indexing auth guide.
Operations
| Operation | Risk | Auth | Summary |
|---|---|---|---|
indexing.urlNotifications.getMetadata |
read |
byo_oauth |
Fetch the most recent notification metadata gum sent Google for a URL (url query param). |
indexing.urlNotifications.publish |
write |
byo_oauth |
Notify Google that a URL was updated or deleted (args.body: url, type=URL_UPDATED|URL_DELETED). |
Next
- Use API workflows for search, describe, invoke, and error handling.
- Use Auth guides for service-specific Google setup.
- Use Command index for CLI flags and generated help.
