gmail v0.1.5 Gmail.Message

An email message.

Summary

Functions

Converts a Gmail API message resource into a local struct

Immediately and permanently deletes the specified message. This operation cannot be undone. Prefer trash instead

Gets the specified message

Lists the messages in the user’s mailbox

Searches for messages in the user’s mailbox

Moves the specified message to the trash

Types

t :: %Gmail.Message{history_id: term, id: term, label_ids: term, payload: term, raw: term, size_estimate: term, snippet: term, thread_id: term}

Functions

convert(message)

Specs

convert(map) :: Gmail.Message.t

Converts a Gmail API message resource into a local struct.

delete(user_id, message_id)

Specs

delete(String.t, String.t) :: {atom, String.t, String.t}

Immediately and permanently deletes the specified message. This operation cannot be undone. Prefer trash instead.

Gmail API documentation: https://developers.google.com/gmail/api/v1/reference/users/messages/delete

get(user_id, message_id, params)

Specs

get(String.t, String.t, map) :: {atom, String.t, String.t}

Gets the specified message.

Gmail API documentation: https://developers.google.com/gmail/api/v1/reference/users/messages/get

list(user_id, params)

Specs

list(String.t, map) :: {atom, String.t, String.t}

Lists the messages in the user’s mailbox.

Gmail API documentation: https://developers.google.com/gmail/api/v1/reference/users/messages/list

search(user_id, query, params)

Specs

search(String.t, String.t, map) :: {atom, String.t, String.t}

Searches for messages in the user’s mailbox.

Gmail API documentation: https://developers.google.com/gmail/api/v1/reference/users/messages/list

trash(user_id, message_id)

Specs

trash(String.t, String.t) :: {atom, String.t, String.t}

Moves the specified message to the trash.

Gmail API documentation: https://developers.google.com/gmail/api/v1/reference/users/messages/trash