{"id":"ae19908b-9684-4f43-a026-b8e76db09e3a","shortId":"whf5em","kind":"skill","title":"recipe-label-and-archive-emails","tagline":"Apply Gmail labels to matching messages and archive them to keep your inbox clean.","description":"# Label and Archive Gmail Threads\n\n> **PREREQUISITE:** Load the following skills to execute this recipe: `gws-gmail`\n\nApply Gmail labels to matching messages and archive them to keep your inbox clean.\n\n## Steps\n\n1. Search for matching emails: `gws gmail users messages list --params '{\"userId\": \"me\", \"q\": \"from:notifications@service.com\"}' --format table`\n2. Apply a label: `gws gmail users messages modify --params '{\"userId\": \"me\", \"id\": \"MESSAGE_ID\"}' --json '{\"addLabelIds\": [\"LABEL_ID\"]}'`\n3. Archive (remove from inbox): `gws gmail users messages modify --params '{\"userId\": \"me\", \"id\": \"MESSAGE_ID\"}' --json '{\"removeLabelIds\": [\"INBOX\"]}'`","tags":["recipe","label","and","archive","emails","cli","googleworkspace","agent-skills","ai-agent","automation","discovery-api","gemini-cli-extension"],"capabilities":["skill","source-googleworkspace","skill-recipe-label-and-archive-emails","topic-agent-skills","topic-ai-agent","topic-automation","topic-cli","topic-discovery-api","topic-gemini-cli-extension","topic-google-admin","topic-google-api","topic-google-calendar","topic-google-chat","topic-google-docs","topic-google-drive"],"categories":["cli"],"synonyms":[],"warnings":[],"endpointUrl":"https://skills.sh/googleworkspace/cli/recipe-label-and-archive-emails","protocol":"skill","transport":"skills-sh","auth":{"type":"none","details":{"cli":"npx skills add googleworkspace/cli","source_repo":"https://github.com/googleworkspace/cli","install_from":"skills.sh"}},"qualityScore":"0.700","qualityRationale":"deterministic score 0.70 from registry signals: · indexed on github topic:agent-skills · 26371 github stars · SKILL.md body (648 chars)","verified":false,"liveness":"unknown","lastLivenessCheck":null,"agentReviews":{"count":0,"score_avg":null,"cost_usd_avg":null,"success_rate":null,"latency_p50_ms":null,"narrative_summary":null,"summary_updated_at":null},"enrichmentModel":"deterministic:skill-github:v1","enrichmentVersion":1,"enrichedAt":"2026-05-18T18:52:34.261Z","embedding":null,"createdAt":"2026-04-18T20:25:16.048Z","updatedAt":"2026-05-18T18:52:34.261Z","lastSeenAt":"2026-05-18T18:52:34.261Z","tsv":"'1':53 '2':71 '3':90 'addlabelid':87 'appli':7,38,72 'archiv':5,14,23,45,91 'clean':20,51 'email':6,57 'execut':32 'follow':29 'format':69 'gmail':8,24,37,39,59,76,96 'gws':36,58,75,95 'gws-gmail':35 'id':83,85,89,103,105 'inbox':19,50,94,108 'json':86,106 'keep':17,48 'label':3,9,21,40,74,88 'list':62 'load':27 'match':11,42,56 'messag':12,43,61,78,84,98,104 'modifi':79,99 'notifications@service.com':68 'param':63,80,100 'prerequisit':26 'q':66 'recip':2,34 'recipe-label-and-archive-email':1 'remov':92 'removelabelid':107 'search':54 'skill':30 'skill-recipe-label-and-archive-emails' 'source-googleworkspace' 'step':52 'tabl':70 'thread':25 'topic-agent-skills' 'topic-ai-agent' 'topic-automation' 'topic-cli' 'topic-discovery-api' 'topic-gemini-cli-extension' 'topic-google-admin' 'topic-google-api' 'topic-google-calendar' 'topic-google-chat' 'topic-google-docs' 'topic-google-drive' 'user':60,77,97 'userid':64,81,101","prices":[{"id":"9d3aed87-bed4-4173-bac7-4549dcdea866","listingId":"ae19908b-9684-4f43-a026-b8e76db09e3a","amountUsd":"0","unit":"free","nativeCurrency":null,"nativeAmount":null,"chain":null,"payTo":null,"paymentMethod":"skill-free","isPrimary":true,"details":{"org":"googleworkspace","category":"cli","install_from":"skills.sh"},"createdAt":"2026-04-18T20:25:16.048Z"}],"sources":[{"listingId":"ae19908b-9684-4f43-a026-b8e76db09e3a","source":"github","sourceId":"googleworkspace/cli/recipe-label-and-archive-emails","sourceUrl":"https://github.com/googleworkspace/cli/tree/main/skills/recipe-label-and-archive-emails","isPrimary":false,"firstSeenAt":"2026-04-18T21:52:36.301Z","lastSeenAt":"2026-05-18T18:52:34.261Z"},{"listingId":"ae19908b-9684-4f43-a026-b8e76db09e3a","source":"skills_sh","sourceId":"googleworkspace/cli/recipe-label-and-archive-emails","sourceUrl":"https://skills.sh/googleworkspace/cli/recipe-label-and-archive-emails","isPrimary":true,"firstSeenAt":"2026-04-18T20:25:16.048Z","lastSeenAt":"2026-05-07T22:40:15.787Z"}],"details":{"listingId":"ae19908b-9684-4f43-a026-b8e76db09e3a","quickStartSnippet":null,"exampleRequest":null,"exampleResponse":null,"schema":null,"openapiUrl":null,"agentsTxtUrl":null,"citations":[],"useCases":[],"bestFor":[],"notFor":[],"kindDetails":{"org":"googleworkspace","slug":"recipe-label-and-archive-emails","github":{"repo":"googleworkspace/cli","stars":26371,"topics":["agent-skills","ai-agent","automation","cli","discovery-api","gemini-cli-extension","google-admin","google-api","google-calendar","google-chat","google-docs","google-drive","google-sheets","google-workspace","oauth2","rust"],"license":"apache-2.0","html_url":"https://github.com/googleworkspace/cli","pushed_at":"2026-05-12T16:46:11Z","description":"Google Workspace CLI — one command-line tool for Drive, Gmail, Calendar, Sheets, Docs, Chat, Admin, and more. Dynamically built from Google Discovery Service. Includes AI agent skills.","skill_md_sha":"c23febd90f11e112f16f7306e9472d241393da62","skill_md_path":"skills/recipe-label-and-archive-emails/SKILL.md","default_branch":"main","skill_tree_url":"https://github.com/googleworkspace/cli/tree/main/skills/recipe-label-and-archive-emails"},"layout":"multi","source":"github","category":"cli","frontmatter":{"name":"recipe-label-and-archive-emails","description":"Apply Gmail labels to matching messages and archive them to keep your inbox clean."},"skills_sh_url":"https://skills.sh/googleworkspace/cli/recipe-label-and-archive-emails"},"updatedAt":"2026-05-18T18:52:34.261Z"}}