@swamp/gcp/gmail
v2026.04.23.1
Google Cloud gmail infrastructure models
Repository
https://github.com/systeminit/swamp-extensions
Labels
gcpgoogle-cloudgmailcloudinfrastructure
Contents
Quality score
Verified by SwampHow well-documented and verifiable this extension is.
Grade A
- Has README or module doc2/2earned
- README has a code example1/1earned
- README is substantive1/1earned
- Most symbols documented1/1earned
- No slow types1/1earned
- Has description1/1earned
- At least one platform tag (or universal)1/1earned
- Two or more platform tags (or universal)1/1earned
- License declared1/1earned
- Verified public repository2/2earned
Install
$ swamp extension pull @swamp/gcp/gmail@swamp/gcp/gmail/users-draftsv2026.04.23.1users_drafts.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| id? | string | The immutable ID of the draft. |
| message? | object | An email message. |
| userId | string | The user's email address. The special value `me` can be used to indicate the authenticated user. |
createCreate a drafts
getGet a drafts
| Argument | Type | Description |
|---|---|---|
| identifier | string | The id of the drafts |
updateUpdate drafts attributes
deleteDelete the drafts
| Argument | Type | Description |
|---|---|---|
| identifier | string | The id of the drafts |
syncSync drafts state from GCP
sendsend
| Argument | Type | Description |
|---|---|---|
| id? | any | |
| message? | any |
Resources
state(infinite)— A draft email in the user's mailbox.
@swamp/gcp/gmail/users-historyv2026.04.23.1users_history.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| name | string | Instance name for this resource (used as the unique identifier in the factory pattern) |
getGet a history
| Argument | Type | Description |
|---|---|---|
| identifier | string | The name of the history |
syncSync history state from GCP
Resources
state(infinite)— A record of a change to the user's mailbox. Each history change may affect mu...
@swamp/gcp/gmail/users-labelsv2026.04.23.1users_labels.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| color? | object | |
| id? | string | The immutable ID of the label. |
| labelListVisibility | enum | The visibility of the label in the label list in the Gmail web interface. |
| messageListVisibility | enum | The visibility of messages with this label in the message list in the Gmail web interface. |
| messagesTotal? | number | The total number of messages with the label. |
| messagesUnread? | number | The number of unread messages with the label. |
| name | string | The display name of the label. |
| threadsTotal? | number | The total number of threads with the label. |
| threadsUnread? | number | The number of unread threads with the label. |
| type? | enum | The owner type for the label. User labels are created by the user and can be modified and deleted by the user and can be applied to any message or thread. System labels are internally created and cannot be added, modified, or deleted. System labels may be able to be applied to or removed from messages and threads under some circumstances but this is not guaranteed. For example, users can apply and remove the `INBOX` and `UNREAD` labels from messages and threads, but cannot apply or remove the `D |
| userId | string | The user's email address. The special value `me` can be used to indicate the authenticated user. |
createCreate a labels
getGet a labels
| Argument | Type | Description |
|---|---|---|
| identifier | string | The id of the labels |
updateUpdate labels attributes
deleteDelete the labels
| Argument | Type | Description |
|---|---|---|
| identifier | string | The id of the labels |
syncSync labels state from GCP
Resources
state(infinite)— Labels are used to categorize messages and threads within the user's mailbox....
@swamp/gcp/gmail/users-messagesv2026.04.23.1users_messages.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| classificationLabelValues? | array | Classification Label values on the message. Available Classification Label schemas can be queried using the Google Drive Labels API. Each classification label ID must be unique. If duplicate IDs are provided, only one will be retained, and the selection is arbitrary. Only used for Google Workspace accounts. |
| historyId? | string | The ID of the last history record that modified this message. |
| id? | string | The immutable ID of the message. |
| internalDate? | string | The internal message creation timestamp (epoch ms), which determines ordering in the inbox. For normal SMTP-received email, this represents the time the message was originally accepted by Google, which is more reliable than the `Date` header. However, for API-migrated mail, it can be configured by client to be based on the `Date` header. |
| labelIds? | array | List of IDs of labels applied to this message. |
| payload? | object | A single MIME message part. |
| raw | string | The entire email message in an RFC 2822 formatted and base64url encoded string. Returned in `messages.get` and `drafts.get` responses when the `format=RAW` parameter is supplied. |
| sizeEstimate? | number | Estimated size in bytes of the message. |
| snippet? | string | A short part of the message text. |
| threadId? | string | The ID of the thread the message belongs to. To add a message or draft to a thread, the following criteria must be met: 1. The requested `threadId` must be specified on the `Message` or `Draft.Message` you supply with your request. 2. The `References` and `In-Reply-To` headers must be set in compliance with the [RFC 2822](https://tools.ietf.org/html/rfc2822) standard. 3. The `Subject` headers must match. |
| userId | string | The user's email address. The special value `me` can be used to indicate the authenticated user. |
| deleted? | string | Mark the email as permanently deleted (not TRASH) and only visible in Google Vault to a Vault administrator. Only used for Google Workspace accounts. |
| internalDateSource? | string | Source for Gmail's internal date of the message. |
createCreate a messages
getGet a messages
| Argument | Type | Description |
|---|---|---|
| identifier | string | The id of the messages |
deleteDelete the messages
| Argument | Type | Description |
|---|---|---|
| identifier | string | The id of the messages |
syncSync messages state from GCP
batch_deletebatch delete
| Argument | Type | Description |
|---|---|---|
| ids? | any |
batch_modifybatch modify
| Argument | Type | Description |
|---|---|---|
| addLabelIds? | any | |
| ids? | any | |
| removeLabelIds? | any |
importimport
| Argument | Type | Description |
|---|---|---|
| classificationLabelValues? | any | |
| historyId? | any | |
| id? | any | |
| internalDate? | any | |
| labelIds? | any | |
| payload? | any | |
| raw? | any | |
| sizeEstimate? | any | |
| snippet? | any | |
| threadId? | any |
modifymodify
| Argument | Type | Description |
|---|---|---|
| addLabelIds? | any | |
| ids? | any | |
| removeLabelIds? | any |
sendsend
| Argument | Type | Description |
|---|---|---|
| classificationLabelValues? | any | |
| historyId? | any | |
| id? | any | |
| internalDate? | any | |
| labelIds? | any | |
| payload? | any | |
| raw? | any | |
| sizeEstimate? | any | |
| snippet? | any | |
| threadId? | any |
trashtrash
untrashuntrash
Resources
state(infinite)— An email message.
@swamp/gcp/gmail/users-messages-attachmentsv2026.04.23.1users_messages_attachments.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| name | string | Instance name for this resource (used as the unique identifier in the factory pattern) |
getGet a attachments
| Argument | Type | Description |
|---|---|---|
| identifier | string | The id of the attachments |
syncSync attachments state from GCP
Resources
state(infinite)— The body of a single MIME message part.
@swamp/gcp/gmail/users-settings-cse-identitiesv2026.04.23.1users_settings_cse_identities.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| name | string | Instance name for this resource (used as the unique identifier in the factory pattern) |
| emailAddress? | string | The email address for the sending identity. The email address must be the primary email address of the authenticated user. |
| primaryKeyPairId? | string | If a key pair is associated, the ID of the key pair, CseKeyPair. |
| signAndEncryptKeyPairs? | object | The configuration of a CSE identity that uses different key pairs for signing and encryption. |
| userId | string | The requester's primary email address. To indicate the authenticated user, you can use the special value `me`. |
createCreate a identities
getGet a identities
| Argument | Type | Description |
|---|---|---|
| identifier | string | The name of the identities |
updateUpdate identities attributes
deleteDelete the identities
| Argument | Type | Description |
|---|---|---|
| identifier | string | The name of the identities |
syncSync identities state from GCP
Resources
state(infinite)— The client-side encryption (CSE) configuration for the email address of an au...
@swamp/gcp/gmail/users-settings-cse-keypairsv2026.04.23.1users_settings_cse_keypairs.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| name | string | Instance name for this resource (used as the unique identifier in the factory pattern) |
| pkcs7? | string | Input only. The public key and its certificate chain. The chain must be in [PKCS#7](https://en.wikipedia.org/wiki/PKCS_7) format and use PEM encoding and ASCII armor. |
| privateKeyMetadata? | array | Metadata for instances of this key pair's private key. |
| userId | string | The requester's primary email address. To indicate the authenticated user, you can use the special value `me`. |
createCreate a keypairs
getGet a keypairs
| Argument | Type | Description |
|---|---|---|
| identifier | string | The name of the keypairs |
syncSync keypairs state from GCP
disabledisable
enableenable
obliterateobliterate
Resources
state(infinite)— A client-side encryption S/MIME key pair, which is comprised of a public key,...
@swamp/gcp/gmail/users-settings-delegatesv2026.04.23.1users_settings_delegates.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| name | string | Instance name for this resource (used as the unique identifier in the factory pattern) |
| delegateEmail? | string | The email address of the delegate. |
| verificationStatus? | enum | Indicates whether this address has been verified and can act as a delegate for the account. Read-only. |
| userId | string | User\ |
createCreate a delegates
getGet a delegates
| Argument | Type | Description |
|---|---|---|
| identifier | string | The name of the delegates |
deleteDelete the delegates
| Argument | Type | Description |
|---|---|---|
| identifier | string | The name of the delegates |
syncSync delegates state from GCP
Resources
state(infinite)— Settings for a delegate. Delegates can read, send, and delete messages, as we...
@swamp/gcp/gmail/users-settings-filtersv2026.04.23.1users_settings_filters.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| action? | object | A set of actions to perform on a message. |
| criteria? | object | Message matching criteria. |
| id? | string | The server assigned ID of the filter. |
| userId | string | User\ |
createCreate a filters
getGet a filters
| Argument | Type | Description |
|---|---|---|
| identifier | string | The id of the filters |
deleteDelete the filters
| Argument | Type | Description |
|---|---|---|
| identifier | string | The id of the filters |
syncSync filters state from GCP
Resources
state(infinite)— Resource definition for Gmail filters. Filters apply to specific messages ins...
@swamp/gcp/gmail/users-settings-forwardingaddressesv2026.04.23.1users_settings_forwardingaddresses.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| name | string | Instance name for this resource (used as the unique identifier in the factory pattern) |
| forwardingEmail? | string | An email address to which messages can be forwarded. |
| verificationStatus? | enum | Indicates whether this address has been verified and is usable for forwarding. Read-only. |
| userId | string | User\ |
createCreate a forwardingAddresses
getGet a forwardingAddresses
| Argument | Type | Description |
|---|---|---|
| identifier | string | The name of the forwardingAddresses |
deleteDelete the forwardingAddresses
| Argument | Type | Description |
|---|---|---|
| identifier | string | The name of the forwardingAddresses |
syncSync forwardingAddresses state from GCP
Resources
state(infinite)— Settings for a forwarding address.
@swamp/gcp/gmail/users-settings-sendasv2026.04.23.1users_settings_sendas.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| name | string | Instance name for this resource (used as the unique identifier in the factory pattern) |
| displayName? | string | A name that appears in the "From:" header for mail sent using this alias. For custom "from" addresses, when this is empty, Gmail will populate the "From:" header with the name that is used for the primary address associated with the account. If the admin has disabled the ability for users to update their name format, requests to update this field for the primary login will silently fail. |
| isDefault? | boolean | Whether this address is selected as the default "From:" address in situations such as composing a new message or sending a vacation auto-reply. Every Gmail account has exactly one default send-as address, so the only legal value that clients may write to this field is `true`. Changing this from `false` to `true` for an address will result in this field becoming `false` for the other previous default address. |
| isPrimary? | boolean | Whether this address is the primary address used to login to the account. Every Gmail account has exactly one primary address, and it cannot be deleted from the collection of send-as aliases. This field is read-only. |
| replyToAddress? | string | An optional email address that is included in a "Reply-To:" header for mail sent using this alias. If this is empty, Gmail will not generate a "Reply-To:" header. |
| sendAsEmail? | string | The email address that appears in the "From:" header for mail sent using this alias. This is read-only for all operations except create. |
| signature? | string | An optional HTML signature that is included in messages composed with this alias in the Gmail web UI. This signature is added to new emails only. |
| smtpMsa? | object | Configuration for communication with an SMTP service. |
| treatAsAlias? | boolean | Whether Gmail should treat this address as an alias for the user\ |
| verificationStatus? | enum | Indicates whether this address has been verified for use as a send-as alias. Read-only. This setting only applies to custom "from" aliases. |
| userId | string | User\ |
createCreate a sendAs
getGet a sendAs
| Argument | Type | Description |
|---|---|---|
| identifier | string | The name of the sendAs |
updateUpdate sendAs attributes
deleteDelete the sendAs
| Argument | Type | Description |
|---|---|---|
| identifier | string | The name of the sendAs |
syncSync sendAs state from GCP
verifyverify
Resources
state(infinite)— Settings associated with a send-as alias, which can be either the primary log...
@swamp/gcp/gmail/users-settings-sendas-smimeinfov2026.04.23.1users_settings_sendas_smimeinfo.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| encryptedKeyPassword? | string | Encrypted key password, when key is encrypted. |
| expiration? | string | When the certificate expires (in milliseconds since epoch). |
| id? | string | The immutable ID for the SmimeInfo. |
| isDefault? | boolean | Whether this SmimeInfo is the default one for this user's send-as address. |
| issuerCn? | string | The S/MIME certificate issuer's common name. |
| pem? | string | PEM formatted X509 concatenated certificate string (standard base64 encoding). Format used for returning key, which includes public key as well as certificate chain (not private key). |
| pkcs12? | string | PKCS#12 format containing a single private/public key pair and certificate chain. This format is only accepted from client for creating a new SmimeInfo and is never returned, because the private key is not intended to be exported. PKCS#12 may be encrypted, in which case encryptedKeyPassword should be set appropriately. |
| userId | string | The user's email address. The special value `me` can be used to indicate the authenticated user. |
| sendAsEmail | string | The email address that appears in the "From:" header for mail sent using this alias. |
createCreate a smimeInfo
getGet a smimeInfo
| Argument | Type | Description |
|---|---|---|
| identifier | string | The id of the smimeInfo |
deleteDelete the smimeInfo
| Argument | Type | Description |
|---|---|---|
| identifier | string | The id of the smimeInfo |
syncSync smimeInfo state from GCP
set_defaultset default
Resources
state(infinite)— An S/MIME email config.
@swamp/gcp/gmail/users-threadsv2026.04.23.1users_threads.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| name | string | Instance name for this resource (used as the unique identifier in the factory pattern) |
getGet a threads
| Argument | Type | Description |
|---|---|---|
| identifier | string | The id of the threads |
deleteDelete the threads
| Argument | Type | Description |
|---|---|---|
| identifier | string | The id of the threads |
syncSync threads state from GCP
modifymodify
| Argument | Type | Description |
|---|---|---|
| addLabelIds? | any | |
| removeLabelIds? | any |
trashtrash
untrashuntrash
Resources
state(infinite)— A collection of messages representing a conversation.
2026.04.16.157.1 KBApr 16, 2026
Google Cloud gmail infrastructure models
Release Notes
- Updated: users_labels
linux-x86_64linux-aarch64darwin-x86_64darwin-aarch64
gcpgoogle-cloudgmailcloudinfrastructure
2026.04.04.159.5 KBApr 4, 2026
Google Cloud gmail infrastructure models
Release Notes
- Updated: users_drafts, users_history, users_threads
linux-x86_64linux-aarch64darwin-x86_64darwin-aarch64
gcpgoogle-cloudgmailcloudinfrastructure
2026.04.03.359.3 KBApr 3, 2026
Google Cloud gmail infrastructure models
Release Notes
- Updated: users_drafts, users_history, users_labels, users_messages, users_messages_attachments, users_settings_cse_identities, users_settings_cse_keypairs, users_settings_delegates, users_settings_filters, users_settings_forwardingaddresses, users_settings_sendas, users_settings_sendas_smimeinfo, users_threads
linux-x86_64linux-aarch64darwin-x86_64darwin-aarch64
gcpgoogle-cloudgmailcloudinfrastructure
2026.04.03.158.3 KBApr 3, 2026
Google Cloud gmail infrastructure models
Release Notes
- Updated: users_drafts, users_history, users_labels, users_messages, users_messages_attachments, users_settings_cse_identities, users_settings_cse_keypairs, users_settings_delegates, users_settings_filters, users_settings_forwardingaddresses, users_settings_sendas, users_settings_sendas_smimeinfo, users_threads
linux-x86_64linux-aarch64darwin-x86_64darwin-aarch64
gcpgoogle-cloudgmailcloudinfrastructure
2026.04.02.258.2 KBApr 2, 2026
Google Cloud gmail infrastructure models
linux-x86_64linux-aarch64darwin-x86_64darwin-aarch64
gcpgoogle-cloudgmailcloudinfrastructure
2026.03.27.155.7 KBMar 27, 2026
Google Cloud gmail infrastructure models
Release Notes
- Added: users_drafts, users_history, users_labels, users_messages, users_messages_attachments, users_settings_cse_identities, users_settings_cse_keypairs, users_settings_delegates, users_settings_filters, users_settings_forwardingaddresses, users_settings_sendas, users_settings_sendas_smimeinfo, users_threads
linux-x86_64linux-aarch64darwin-x86_64darwin-aarch64
gcpgoogle-cloudgmailcloudinfrastructure