Before.Rd
Criteria helper functions to be combined inside a operator helper - function as a custom request in customSearch.
- -Before(date_char, negate = FALSE)- -
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
---|---|
negate | -If |
-
A search string to be used as a custom_request
parameter in
- customSearch function.
Other customsearch helper functions: AND
,
- Flag
, OR
,
- Since
, String
,
- olderThan
, sentBefore
,
- sentOn
, sentSince
,
- smallerThan
, youngerThan
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -result <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - customSearch(custom_request = AND(Before(date_char = "17-Apr-2019"), - smallerThan(size = 512000), - negate = TRUE)) -# searches for messages NOT Before "17-Apr-2019" AND NOT SmallerThan 512KB. - -# }-
Flag.Rd
Criteria helper functions to be combined inside a operator helper - function as a custom request in customSearch.
- -Flag(flag, negate = FALSE)- -
flag | -A string specifying the flag to be used for filtering messages. -Use flag_options to list the flags available in your IMAP server. |
-
---|---|
negate | -If |
-
A search string to be used as a custom_request
parameter in
- customSearch function.
Other customsearch helper functions: AND
,
- Before
, OR
,
- Since
, String
,
- olderThan
, sentBefore
,
- sentOn
, sentSince
,
- smallerThan
, youngerThan
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -result <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - customSearch(custom_request = AND(Flag(flag="UNSEEN"), - smallerThan(size = 512000), - negate = TRUE)) -# searches for messages with Flag ""UNSEEN" AND NOT SmallerThan 512KB. - -# }-
On.Rd
Criteria helper functions to be combined inside a operator helper - function as a custom request in customSearch.
- -On(date_char, negate = FALSE)- -
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
---|---|
negate | -If |
-
A search string to be used as a custom_request
parameter in
- customSearch function.
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -result <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - customSearch(custom_request = OR(On(date_char = "17-Apr-2019"), - On(date_char = "17-Jul-2018"))) -# searches for messages On "17-Apr-2019" OR On "17-Jul-2018". - -# }-
Since.Rd
Criteria helper functions to be combined inside a operator helper - function as a custom request in customSearch.
- -Since(date_char, negate = FALSE)- -
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
---|---|
negate | -If |
-
A search string to be used as a custom_request
parameter in
- customSearch function.
Other customsearch helper functions: AND
,
- Before
, Flag
,
- OR
, String
,
- olderThan
, sentBefore
,
- sentOn
, sentSince
,
- smallerThan
, youngerThan
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -result <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - customSearch(custom_request = AND(Since(date_char = "17-Apr-2019"), - smallerThan(size = 512000))) -# searches for messages Since "17-Apr-2019" AND SmallerThan 512KB. - -# }-
String.Rd
Criteria helper functions to be combined inside a operator helper - function as a custom request in customSearch.
- -String(section_or_field, string, negate = FALSE)- -
section_or_field | -A mandatory character string specifying in which -messages's Section or Header Field to search for the provided string. -For some available options, see section_or_field_options. |
-
---|---|
string | -A character string specifying the word or expression to -search for in messages. |
-
negate | -If |
-
A search string to be used as a custom_request
parameter in
- customSearch function.
Other customsearch helper functions: AND
,
- Before
, Flag
,
- OR
, Since
,
- olderThan
, sentBefore
,
- sentOn
, sentSince
,
- smallerThan
, youngerThan
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -result <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - customSearch(custom_request = - OR(String( - section_or_field = "from", string = "allanvcq@gmail.com"), - String( - section_or_field = "from", string = "allanvcq@yahoo.com") - ) - ) -# searches for messages containing the string "allanvcq@gmail.com" OR - "allanvcq@yahoo.com" in the "FROM" field. - -# } --
addFlags.Rd
Add one or more flags to one or more messages.
- -addFlags(imapconf, msg_id, by = "MSN", flags_to_set, - logical_output = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
flags_to_set | -A character vector containing one ore more flag names to -add to or replace in the specified message ids. |
-
logical_output | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the logical_output
parameter, returns a list
- of length 2
containing the imapconf
object and previously
- informed message ids (parameter msg_id
), or a logical vector of
- length 1
indicating the success (TRUE
) of the mentioned
- operation.
addFlags, removeFlags and replaceFlags, accepts
- not only flags but also keywords (such as $Phishing
on Gmail's
- IMAP server) to add, remove or replace.
IMAP servers do not allow setting the negative version of a flag when a
- message already has the positive version of it. If a message with
- MSN 1
already has the "SEEN" flag, it is not allowed to add "UNSEEN"
- to that. Instead, you have to first remove the "SEEN" flag
- removeFlags(imapconf, msg_id = 1, "SEEN")
and only then do
- addFlags(imapconf, msg_id = 1, "SEEN")
. Another option is to
- complete override all the flags of a message or a set of messages using
- replaceFlags(imapconf, msg_id = 1, "SEEN")
.
Other miscellaneous: copyMsg
,
- countMsgs
, deleteMsg
,
- expunge
, getMaxId
,
- getMinId
, moveMsg
,
- removeFlags
, replaceFlags
# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -results <- imapconf %>% - selectMailbox(mbox = "TAM") %>% - searchBefore(date_char = "10-may-2012", by = "UID") %$% #exposition pipe - two argg - addFlags(imapconf = imapconf, msg_id = msg_id, flags_to_set = "RECENT") - -# }--
add_flags.Rd
Add one or more flags to one or more messages.
- -add_flags(imapconf, msg_id, by = "MSN", flags_to_set, retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
flags_to_set | -A character vector containing one ore more flag names to -add to or replace in the specified message ids. |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
An (invisible) list
of length 2
containing the
- imapconf
object and the previously inputed message ids
- (parameter msg_id
).
add_flags, remove_flags and replace_flags, accepts
- not only flags but also keywords (such as $Phishing
on Gmail's
- IMAP server) to add, remove or replace.
IMAP servers do not allow setting the negative version of a flag when a
- message already has the positive version of it. If a message with
- MSN 1
already has the "SEEN" flag, it is not allowed to add "UNSEEN"
- to that. Instead, you have to first remove the "SEEN" flag
- remove_flags(imapconf, msg_id = 1, "SEEN")
and only then do
- add_flags(imapconf, msg_id = 1, "SEEN")
. Another option is to
- complete override all the flags of a message or of a set of messages using
- replace_flags(imapconf, msg_id = 1, "SEEN")
.
Other miscellaneous: copy_msg
,
- count_msgs
, delete_msg
,
- expunge
, get_max_id
,
- get_min_id
, move_msg
,
- remove_flags
, replace_flags
# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -results <- imapconf %>% - select_mailbox(mbox = "TAM") %>% - search_before(date_char = "10-may-2012", by = "UID") %$% #exposition pipe - two argg - add_flags(imapconf = imapconf, msg_id = msg_id, flags_to_set = "RECENT") - -# }--
check_args_addReplaceFlags.Rd
Internal helper function for checking the arguments - used in addFlags, and replaceFlags functions.
- -check_args_addReplaceFlags(imapconf, msg_id, by, flags_to_set, - logical_output, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
flags_to_set | -A character vector containing one ore more flag names to -add to or replace in the specified message ids. |
-
logical_output | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other miscellaneous helper: check_args_copyMsg
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_getMaxMinId
Other check args: check_args_copyMsg
,
- check_args_customSearch
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- check_args_getMaxMinId
,
- check_args_moveMsg
,
- check_args_removeFlags
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
check_args_add_replace_flags.Rd
Internal helper function for checking the arguments - used in add_flags, and replace_flags functions.
- -check_args_add_replace_flags(imapconf, msg_id, by, flags_to_set, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
flags_to_set | -A character vector containing one ore more flag names to -add to or replace in the specified message ids. |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other miscellaneous helper: check_args_copy_msg
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_get_max_min_id
Other check args: check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_copyMsg.Rd
Internal helper function for checking the arguments - used in copyMsg function.
- -check_args_copyMsg(imapconf, msg_id, by, to_mbox, reselect_mbox, - logical_output, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
to_mbox | -A character string specifying the mailbox to which messages -will be copied to. |
-
reselect_mbox | -If |
-
logical_output | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other miscellaneous helper: check_args_addReplaceFlags
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_getMaxMinId
Other check args: check_args_addReplaceFlags
,
- check_args_customSearch
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- check_args_getMaxMinId
,
- check_args_moveMsg
,
- check_args_removeFlags
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
check_args_copy_msg.Rd
Internal helper function for checking the arguments - used in copy_msg function.
- -check_args_copy_msg(imapconf, msg_id, by, to_mbox, reselect_mbox, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
to_mbox | -A character string specifying the mailbox to which messages -will be copied to. |
-
reselect_mbox | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other miscellaneous helper: check_args_add_replace_flags
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_get_max_min_id
Other check args: check_args_add_replace_flags
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_customSearch.Rd
Internal helper function for checking arguments used in search - functions.
- -check_args_customSearch(imapconf, custom_search, negate, by, esearch, - return_imapconf, retries)- -
imapconf | -An object of class |
-
---|---|
negate | -If |
-
by | -Which id ( |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
custom_request | -A string directly specifying what to search or -constructed by a combination of operators helper functions OR and -AND, and criteria helper functions such as Before, Since, -On, sentBefore, sentSince, sentOn, -Flag, or String. |
-
NULL
if arguments are correct.
Other search helper: check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_searchStripping
Other check args: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- check_args_getMaxMinId
,
- check_args_moveMsg
,
- check_args_removeFlags
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
check_args_custom_search.Rd
Internal helper function for checking arguments used in search - functions.
- -check_args_custom_search(imapconf, custom_search, negate, by, esearch, - return_imapconf, retries)- -
imapconf | -An object of class |
-
---|---|
negate | -If |
-
by | -Which id ( |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
custom_request | -A string directly specifying what to search or -constructed by a combination of operators helper functions OR and -AND, and criteria helper functions such as before, since, -on, sent_before, sent_since, sent_on, -flag, string, smaller_than, larger_than, -younger_than, or younger_than. |
-
NULL
if arguments are correct.
Other search helper: check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_search_stripping
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_date.Rd
Internal helper function for checking specific arguments - used in custom_search.
- -check_args_date(date_char, negate)- -
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
---|---|
negate | -If |
-
NULL
if arguments are correct.
Other customsearch checkargs functions: check_args_flag
,
- check_args_size
,
- check_args_string
,
- check_args_within
check_args_deleteMsg.Rd
Internal helper function for checking the arguments - used in deleteMsg function.
- -check_args_deleteMsg(imapconf, msg_id, by, logical_output, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
logical_output | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other miscellaneous helper: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_expunge
,
- check_args_getMaxMinId
Other check args: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_customSearch
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- check_args_getMaxMinId
,
- check_args_moveMsg
,
- check_args_removeFlags
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
check_args_delete_msg.Rd
Internal helper function for checking the arguments - used in delete_msg function.
- -check_args_delete_msg(imapconf, msg_id, by, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other miscellaneous helper: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_expunge
,
- check_args_get_max_min_id
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_expunge.Rd
Internal helper function for checking the arguments - used in expunge function.
- -check_args_expunge(imapconf, specific_UID, retries)- -
imapconf | -An object of class |
-
---|---|
specific_UID | -A numeric vector containing one or more messages UIDs, if -specific messages should be expunged and not the whole mailbox. |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other miscellaneous helper: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_delete_msg
,
- check_args_get_max_min_id
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_fetchFullMsg.Rd
Internal helper function for checking arguments used in - fetch functions.
- -check_args_fetchFullMsg(imapconf, msg_id, by, peek, partial, write_to_file, - keep_in_mem, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
peek | -If |
-
partial | -
|
-
write_to_file | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other fetch helper: check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- clean_fetch_results
,
- decode_base64_text_if_TRUE
Other check args: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_customSearch
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- check_args_getMaxMinId
,
- check_args_moveMsg
,
- check_args_removeFlags
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
check_args_fetchMsgHeader.Rd
Internal helper function for checking arguments used in - fetch functions.
- -check_args_fetchMsgHeader(imapconf, msg_id, by, fields, negate_fields, - peek, partial, write_to_file, keep_in_mem, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
fields | -A character vector specifying which field(s) to fetch from -messages. See section_or_field_options |
-
negate_fields | -If |
-
peek | -If |
-
partial | -
|
-
write_to_file | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other fetch helper: check_args_fetchFullMsg
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- clean_fetch_results
,
- decode_base64_text_if_TRUE
Other check args: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_customSearch
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- check_args_getMaxMinId
,
- check_args_moveMsg
,
- check_args_removeFlags
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
check_args_fetchMsgMetadata.Rd
Internal helper function for checking arguments used in - fetch functions.
- -check_args_fetchMsgMetadata(imapconf, msg_id, by, metadata, write_to_file, - keep_in_mem, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
metadata | -A character vector or string specifying one or more items of -the metadata of a message to fetch. See metadata_options. |
-
write_to_file | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other fetch helper: check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgText
,
- clean_fetch_results
,
- decode_base64_text_if_TRUE
Other check args: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_customSearch
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgText
,
- check_args_getMaxMinId
,
- check_args_moveMsg
,
- check_args_removeFlags
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
check_args_fetchMsgText.Rd
Internal helper function for checking arguments used in - fetch functions.
- -check_args_fetchMsgText(imapconf, msg_id, by, peek, partial, write_to_file, - keep_in_mem, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
peek | -If |
-
partial | -
|
-
write_to_file | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other fetch helper: check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- clean_fetch_results
,
- decode_base64_text_if_TRUE
Other check args: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_customSearch
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_getMaxMinId
,
- check_args_moveMsg
,
- check_args_removeFlags
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
check_args_fetch_full_msg.Rd
Internal helper function for checking arguments used in - fetch functions.
- -check_args_fetch_full_msg(imapconf, msg_id, by, peek, partial, - write_to_disk, keep_in_mem, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
peek | -If |
-
partial | -
|
-
write_to_disk | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other fetch helper: check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- clean_fetch_results
,
- decode_base64_text_if_needed
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_fetch_msg_header.Rd
Internal helper function for checking arguments used in - fetch functions.
- -check_args_fetch_msg_header(imapconf, msg_id, by, fields, negate_fields, - peek, partial, write_to_disk, keep_in_mem, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
fields | -A character vector specifying which field(s) to fetch from -messages. See section_or_field_options |
-
negate_fields | -If |
-
peek | -If |
-
partial | -
|
-
write_to_disk | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other fetch helper: check_args_fetch_full_msg
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- clean_fetch_results
,
- decode_base64_text_if_needed
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_fetch_msg_metadata.Rd
Internal helper function for checking arguments used in - fetch functions.
- -check_args_fetch_msg_metadata(imapconf, msg_id, by, metadata, - write_to_disk, keep_in_mem, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
metadata | -A character vector or string specifying one or more items of -the metadata of a message to fetch. See metadata_options. |
-
write_to_disk | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other fetch helper: check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_text
,
- clean_fetch_results
,
- decode_base64_text_if_needed
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_fetch_msg_text.Rd
Internal helper function for checking arguments used in - fetch functions.
- -check_args_fetch_msg_text(imapconf, msg_id, by, peek, partial, - write_to_disk, keep_in_mem, try_b64decode, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
peek | -If |
-
partial | -
|
-
write_to_disk | -If |
-
keep_in_mem | -If |
-
try_b64decode | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other fetch helper: check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- clean_fetch_results
,
- decode_base64_text_if_needed
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_flag.Rd
Internal helper function for checking specific arguments - used in custom_search.
- -check_args_flag(flag, negate)- -
flag | -A string specifying the flag to be used for filtering messages. -Use flag_options to list the flags available in your IMAP server. |
-
---|---|
negate | -If |
-
NULL
if arguments are correct.
Other customsearch checkargs functions: check_args_date
,
- check_args_size
,
- check_args_string
,
- check_args_within
check_args_getMaxMinId.Rd
Internal helper function for checking the arguments - used in getMaxId and getMinId functions.
- -check_args_getMaxMinId(imapconf, by, flag, retries)- -
imapconf | -An object of class |
-
---|---|
by | -Which id ( |
-
flag | -A string specifying the flag to be used for filtering messages.
-Use flag_options to list the common flags used by IMAP
-servers. Default is |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other miscellaneous helper: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_deleteMsg
,
- check_args_expunge
Other check args: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_customSearch
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- check_args_moveMsg
,
- check_args_removeFlags
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
check_args_get_attachment.Rd
Internal helper function for getting attachments
- -check_args_get_attachment(msg_list)- -
msg_list | -A |
-
---|
NULL
if arguments are correct.
Other attachments helper: has_attachment
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_max_min_id
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_get_attachments.Rd
Internal helper function for getting attachments
- -check_args_get_attachments(msg_list, content_disposition)- -
msg_list | -A |
-
---|---|
content_disposition | -A |
-
NULL
if arguments are correct.
Other attachments helper: check_args_list_attachments
,
- has_attachment
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_get_max_min_id.Rd
Internal helper function for checking the arguments - used in get_max_id and get_min_id functions.
- -check_args_get_max_min_id(imapconf, by, flag, retries)- -
imapconf | -An object of class |
-
---|---|
by | -Which id ( |
-
flag | -A string specifying the flag to be used for filtering messages.
-Use flag_options to list the common flags used by IMAP
-servers. Default is |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other miscellaneous helper: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_delete_msg
,
- check_args_expunge
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_list_attachments.Rd
Internal helper function for listing attachments
- -check_args_list_attachments(msg_list)- -
msg_list | -A |
-
---|
NULL
if arguments are correct.
Other attachments helper: check_args_get_attachments
,
- has_attachment
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_moveMsg.Rd
Internal helper function for checking the arguments - used in moveMsg function.
- -check_args_moveMsg(imapconf, msg_id, by, to_mbox, logical_output, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
to_mbox | -A character string specifying the mailbox to which messages -will be moved to. |
-
logical_output | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
reselect_mbox | -If |
-
NULL
if arguments are correct.
Other miscellaneous helpers: check_args_removeFlags
Other check args: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_customSearch
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- check_args_getMaxMinId
,
- check_args_removeFlags
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
check_args_move_msg.Rd
Internal helper function for checking the arguments - used in move_msg function.
- -check_args_move_msg(imapconf, msg_id, by, to_mbox, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
to_mbox | -A character string specifying the mailbox to which messages -will be moved to. |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
reselect_mbox | -If |
-
NULL
if arguments are correct.
Other miscellaneous helpers: check_args_remove_flags
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_removeFlags.Rd
Internal helper function for checking the arguments - used in removeFlags function.
- -check_args_removeFlags(imapconf, msg_id, by, flags_to_unset, - logical_output, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
flags_to_unset | -A character vector containing one ore more flag names to -remove from the specified message ids. |
-
logical_output | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other miscellaneous helpers: check_args_moveMsg
Other check args: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_customSearch
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- check_args_getMaxMinId
,
- check_args_moveMsg
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
check_args_remove_flags.Rd
Internal helper function for checking the arguments - used in remove_flags function.
- -check_args_remove_flags(imapconf, msg_id, by, flags_to_unset, retries)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
flags_to_unset | -A character vector containing one ore more flag names to -remove from the specified message ids. |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other miscellaneous helpers: check_args_move_msg
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_searchDate.Rd
Internal helper function for checking arguments used in search - functions.
- -check_args_searchDate(imapconf, date_char, negate, by, flag, esearch, - return_imapconf, retries)- -
imapconf | -An object of class |
-
---|---|
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other search helper: check_args_customSearch
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_searchStripping
Other check args: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_customSearch
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- check_args_getMaxMinId
,
- check_args_moveMsg
,
- check_args_removeFlags
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
check_args_searchFlag.Rd
Internal helper function for checking arguments used in search - functions.
- -check_args_searchFlag(imapconf, flag, negate, by, esearch, return_imapconf, - retries)- -
imapconf | -An object of class |
-
---|---|
flag | -A string specifying the flag to be used for filtering messages. -Use flag_options to list the common flags used by IMAP -servers. |
-
negate | -If |
-
by | -Which id ( |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other search helper: check_args_customSearch
,
- check_args_searchDate
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_searchStripping
Other check args: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_customSearch
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- check_args_getMaxMinId
,
- check_args_moveMsg
,
- check_args_removeFlags
,
- check_args_searchDate
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
check_args_searchPeriod.Rd
Internal helper function for checking arguments used in search - functions.
- -check_args_searchPeriod(imapconf, since_date_char, before_date_char, - negate, by, flag, esearch, return_imapconf, retries)- -
imapconf | -An object of class |
-
---|---|
since_date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019" indicating the start date (inclusive). We opted not to -use objects of type "date", since IMAP servers like this not so common date -format. |
-
before_date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019" indicating the stop date (exclusive). We opted not to -use objects of type "date", since IMAP server likes this not so common date -format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other search helper: check_args_customSearch
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_searchStripping
Other check args: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_customSearch
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- check_args_getMaxMinId
,
- check_args_moveMsg
,
- check_args_removeFlags
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
check_args_searchSize.Rd
Internal helper function for checking arguments used in search - functions.
- -check_args_searchSize(imapconf, size, negate, by, flag, esearch, - return_imapconf, retries)- -
imapconf | -An object of class |
-
---|---|
size | -An integer specifying the size (in number of characters) of -message to be used as search criterion. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other search helper: check_args_customSearch
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchString
,
- check_args_searchWithin
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_searchStripping
Other check args: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_customSearch
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- check_args_getMaxMinId
,
- check_args_moveMsg
,
- check_args_removeFlags
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchString
,
- check_args_searchWithin
check_args_searchString.Rd
Internal helper function for checking arguments used in search - functions.
- -check_args_searchString(imapconf, section_or_field, string, negate, by, - esearch, return_imapconf, retries)- -
imapconf | -An object of class |
-
---|---|
section_or_field | -A mandatory character string specifying in which -message's Section or Header Field to search for the provided string. -For some available options, see section_or_field_options. |
-
string | -A character string specifying the word or expression to -search for in messages. |
-
negate | -If |
-
by | -Which id ( |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other search helper: check_args_customSearch
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchWithin
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_searchStripping
Other check args: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_customSearch
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- check_args_getMaxMinId
,
- check_args_moveMsg
,
- check_args_removeFlags
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchWithin
check_args_searchWithin.Rd
Internal helper function for checking arguments used in search - functions.
- -check_args_searchWithin(imapconf, seconds, negate, by, flag, esearch, - return_imapconf, retries)- -
imapconf | -An object of class |
-
---|---|
seconds | -An integer specifying the number of seconds to be used as -search criterion. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other search helper: check_args_customSearch
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_searchStripping
Other check args: check_args_addReplaceFlags
,
- check_args_copyMsg
,
- check_args_customSearch
,
- check_args_deleteMsg
,
- check_args_expunge
,
- check_args_fetchFullMsg
,
- check_args_fetchMsgHeader
,
- check_args_fetchMsgMetadata
,
- check_args_fetchMsgText
,
- check_args_getMaxMinId
,
- check_args_moveMsg
,
- check_args_removeFlags
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
check_args_search_date.Rd
Internal helper function for checking arguments used in search - functions.
- -check_args_search_date(imapconf, date_char, negate, by, flag, esearch, - return_imapconf, retries)- -
imapconf | -An object of class |
-
---|---|
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other search helper: check_args_custom_search
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_search_stripping
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_search_flag.Rd
Internal helper function for checking arguments used in search - functions.
- -check_args_search_flag(imapconf, flag, negate, by, esearch, - return_imapconf, retries)- -
imapconf | -An object of class |
-
---|---|
flag | -A string specifying the flag to be used for filtering messages. -Use flag_options to list the common flags used by IMAP -servers. |
-
negate | -If |
-
by | -Which id ( |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other search helper: check_args_custom_search
,
- check_args_search_date
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_search_stripping
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_search_period.Rd
Internal helper function for checking arguments used in search - functions.
- -check_args_search_period(imapconf, since_date_char, before_date_char, - negate, by, flag, esearch, return_imapconf, retries)- -
imapconf | -An object of class |
-
---|---|
since_date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019" indicating the start date (inclusive). We opted not to -use objects of type "date", since IMAP servers like this not so common date -format. |
-
before_date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019" indicating the stop date (exclusive). We opted not to -use objects of type "date", since IMAP server likes this not so common date -format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other search helper: check_args_custom_search
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_search_stripping
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
check_args_search_size.Rd
Internal helper function for checking arguments used in search - functions.
- -check_args_search_size(imapconf, size, negate, by, flag, esearch, - return_imapconf, retries)- -
imapconf | -An object of class |
-
---|---|
size | -An integer specifying the size (in number of characters) of -message to be used as search criterion. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other search helper: check_args_custom_search
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_string
,
- check_args_search_within
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_search_stripping
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_string
,
- check_args_search_within
check_args_search_string.Rd
Internal helper function for checking arguments used in search - functions.
- -check_args_search_string(imapconf, section_or_field, string, negate, by, - esearch, return_imapconf, retries)- -
imapconf | -An object of class |
-
---|---|
section_or_field | -A mandatory character string specifying in which -message's Section or Header Field to search for the provided string. -For some available options, see section_or_field_options. |
-
string | -A character string specifying the word or expression to -search for in messages. |
-
negate | -If |
-
by | -Which id ( |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other search helper: check_args_custom_search
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_within
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_search_stripping
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_within
check_args_search_within.Rd
Internal helper function for checking arguments used in search - functions.
- -check_args_search_within(imapconf, seconds, negate, by, flag, esearch, - return_imapconf, retries)- -
imapconf | -An object of class |
-
---|---|
seconds | -An integer specifying the number of seconds to be used as -search criterion. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
NULL
if arguments are correct.
Other search helper: check_args_custom_search
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_search_stripping
Other check args: check_args_add_replace_flags
,
- check_args_copy_msg
,
- check_args_custom_search
,
- check_args_delete_msg
,
- check_args_expunge
,
- check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- check_args_get_attachments
,
- check_args_get_max_min_id
,
- check_args_list_attachments
,
- check_args_move_msg
,
- check_args_remove_flags
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
check_args_size.Rd
Internal helper function for checking specific arguments - used in custom_search.
- -check_args_size(size, negate)- -
size | -An integer specifying the size (in number of characters) of -message to be used as search criterion. |
-
---|---|
negate | -If |
-
NULL
if arguments are correct.
Other customsearch checkargs functions: check_args_date
,
- check_args_flag
,
- check_args_string
,
- check_args_within
check_args_string.Rd
Internal helper function for checking specific arguments - used in custom_search.
- -check_args_string(string, section_or_field, negate)- -
string | -A character string specifying the word or expression to -search for in messages. |
-
---|---|
section_or_field | -A mandatory character string specifying in which -messages's Section or Header Field to search for the provided string. -For some available options, see section_or_field_options. |
-
negate | -If |
-
NULL
if arguments are correct.
Other customsearch checkargs functions: check_args_date
,
- check_args_flag
,
- check_args_size
,
- check_args_within
check_args_within.Rd
Internal helper function for checking specific arguments - used in custom_search.
- -check_args_within(seconds, negate)- -
seconds | -An integer specifying the number of seconds to be used as -search criterion. |
-
---|---|
negate | -If |
-
NULL
if arguments are correct.
Other customsearch checkargs functions: check_args_date
,
- check_args_flag
,
- check_args_size
,
- check_args_string
clean_fetch_results.Rd
Internal helper function for cleaning a message content in a - string. It is used with fetch loop functions.
- -clean_fetch_results(msg)- -
msg | -A character string with a message content. |
-
---|
A string with a cleaned message.
- -Other fetch helper: check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- decode_base64_text_if_needed
Other cleaning: decode_base64_text_if_needed
config_handle.Rd
Internal helper function for configuring curl handles used in - almost all mRpostman functions.
- -config_handle(imapconf)- -
imapconf | -An object of class |
-
---|
A curl handle object.
- - -configureIMAP.Rd
Configure IMAP server settings.
- -configureIMAP(url, username, password, show_pass = FALSE, - use_ssl = TRUE, verbose = FALSE, buffersize = 16000, - fresh_connect = FALSE, timeout_ms = 5000, ...)- -
url | -String containing the IMAP server address |
-
---|---|
username | -String containing user's name. |
-
password | -String containing user's password. |
-
show_pass | -How to store user's password in imapconf object. Default is
- |
-
use_ssl | -A Logical indicating the use or not of Secure Sockets Layer
-encryption when connecting to IMAP server. Default is |
-
verbose | -If |
-
buffersize | -The size in bytes for curl's receive buffer. Default is -16000 bytes or 16kb, which means it will use the default value of libcurl. -Maximum buffersize in libcurl documentation is 512kb (or 512000 bytes), -but curl package accepts 2147483647 bytes without returning errors. |
-
fresh_connect | -If |
-
timeout_ms | -Time in miliseconds (ms) to wait until a connection or a
-command to be executed. Default is 5000ms (or 5 seconds). If a first
-execution is frustated, an error handler in each function (depending on
- |
-
... | -Further IMAP parameters listed in
- |
-
An object of class imapconf
containing the settings
- needed to connect to the IMAP server.
https://curl.haxx.se/libcurl/c/CURLOPT_BUFFERSIZE.html
- -Other config: config_handle
# NOT RUN { -# Gmail config example: -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) -# }-
copyMsg.Rd
Copies messages form a mailbox to another.
- -copyMsg(imapconf, msg_id, by = "MSN", to_mbox, reselect_mbox = FALSE, - logical_output = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
to_mbox | -A character string specifying the mailbox to which messages -will be copied to. |
-
reselect_mbox | -If |
-
logical_output | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the logical_output
parameter, returns a list
- of length 2
containing the imapconf
object and previously
- informed message ids (parameter msg_id
), or a logical vector of
- length 1
indicating the success (TRUE
) of the mentioned
- operation.
Other miscellaneous: addFlags
,
- countMsgs
, deleteMsg
,
- expunge
, getMaxId
,
- getMinId
, moveMsg
,
- removeFlags
, replaceFlags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# copy search results from "Sent" to "INBOX" -results <- imapconf %>% - selectMailbox(mbox = "Sent") %>% - searchBefore(date_char = "10-may-2012") %$% #exposition pipe operator - pass two argg - copyMsg(imapconf = imapconf, msg_id = msg_id, to_mbox = "INBOX") - -# }-
copy_msg.Rd
Copies messages form a mailbox to another.
- -copy_msg(imapconf, msg_id, by = "MSN", to_mbox, reselect_mbox = FALSE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
to_mbox | -A character string specifying the mailbox to which messages -will be copied to. |
-
reselect_mbox | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
An (invisible) list
of length 2
containing the
- imapconf
object and the previously inputed message ids
- (parameter msg_id
).
Other miscellaneous: add_flags
,
- count_msgs
, delete_msg
,
- expunge
, get_max_id
,
- get_min_id
, move_msg
,
- remove_flags
, replace_flags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# copy search results from "Sent" to "INBOX" -results <- imapconf %>% - select_mailbox(mbox = "Sent") %>% - search_before(date_char = "10-may-2012") %$% #exposition pipe operator - pass two argg - copy_msg(imapconf = imapconf, msg_id = msg_id, to_mbox = "INBOX") - -# }-
countMsgs.Rd
Counts the number of messages with a respective flag in a mailbox.
- -countMsgs(imapconf, by = "MSN", flag, retries = 2)- -
imapconf | -An object of class |
-
---|---|
by | -Which id ( |
-
flag | -A string specifying the flag to be used for filtering messages. -Use flag_options to list the common flags used by IMAP -servers. |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A numeric vector
of length 1
containing the number of
- messages that meet the specified criteria.
copyMsg
uses ESEARCH
extension. Check if your server
- supports ESEARCH capability with listServerCapabilities.
Other miscellaneous: addFlags
,
- copyMsg
, deleteMsg
,
- expunge
, getMaxId
,
- getMinId
, moveMsg
,
- removeFlags
, replaceFlags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -results <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - countMsgs(by = "UID", flag = "SEEN") - -# }-
count_msgs.Rd
Counts the number of messages with a respective flag in a mailbox.
- -count_msgs(imapconf, by = "MSN", flag, retries = 2)- -
imapconf | -An object of class |
-
---|---|
by | -Which id ( |
-
flag | -A string specifying the flag to be used for filtering messages. -Use flag_options to list the common flags used by IMAP -servers. |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A numeric vector
of length 1
containing the number of
- messages that meet the specified criteria.
Other miscellaneous: add_flags
,
- copy_msg
, delete_msg
,
- expunge
, get_max_id
,
- get_min_id
, move_msg
,
- remove_flags
, replace_flags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -results <- imapconf %>% - select_mailbox(mbox = "INBOX") %>% - count_msgs(by = "UID", flag = "SEEN") - -# }-
customSearch.Rd
Allows a combination of several arguments using helper functions - that serve as relational operators, such as OR and AND; and - criteria helper functions such as Before, Since, On, - sentBefore, sentSince, sentOn, Flag, or - String, in order to execute a custom search (with multiple - arguments).
- -customSearch(imapconf, custom_request, negate = FALSE, by = "MSN", - esearch = FALSE, return_imapconf = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
custom_request | -A string directly specifying what to search or -constructed by a combination of operators helper functions OR and -AND, and criteria helper functions such as Before, Since, -On, sentBefore, sentSince, sentOn, -Flag, or String. |
-
negate | -If |
-
by | -Which id ( |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
IMAP queries follows Polish notation, i.e. operators such as OR
- come before arguments, e.g. "OR argument1 argument2". Therefore, the
- relational operators functions in this package should be used like the
- following examples: OR(Before("17-Apr-2015"), String("FROM", "Jim"))
.
- Even though there is no "AND" operator in IMAP, this package adds a helper
- funcion AND to indicate multiples arguments that must be searched
- together, e.g. AND(Since("01-Jul-2018"), Size(16000))
.
Other Date-search operations: searchBefore
,
- searchOn
, searchPeriod
,
- searchSentBefore
,
- searchSentOn
,
- searchSentPeriod
,
- searchSentSince
, searchSince
Other Size-search operations: searchLargerThan
,
- searchSmallerThan
Other Flag-search operations: searchFlag
Other Within-search operations: searchOlderThan
,
- searchYoungerThan
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) -# search1 -result1 <- imapconf %>% - selectMailbox(mbox = "TAM") %>% - customSearch(custom_request = AND(String(section_or_field = "TO", - string = "allan"), - Before(date_char = "12-Apr-2009"))) -# searches for messages containing the string "allan" in the "TO" field - and that were received before "12-Apr-2009". - -# search2 -result2 <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - customSearch(custom_request = OR(String(section_or_field = "TEXT", - string = "Contract 2872827"), - String(section_or_field = "Subject", - string = "Buying operation"))) -# searches for messages containing the string "Contract 2872827" in the - "TEXT" section or the string "Buying operation" in the "Subject" field - of the HEADER. - -# } --
custom_search.Rd
Allows a combination of several arguments using helper functions - that serve as relational operators, such as OR and AND; and - criteria helper functions such as before, since, - on, sent_before, sent_since, sent_on, - flag, string, smaller_than, larger_than, - younger_than, or younger_than, in order to execute a - custom search (with multiple arguments).
- -custom_search(imapconf, custom_request, negate = FALSE, by = "MSN", - esearch = FALSE, return_imapconf = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
custom_request | -A string directly specifying what to search or -constructed by a combination of operators helper functions OR and -AND, and criteria helper functions such as before, since, -on, sent_before, sent_since, sent_on, -flag, string, smaller_than, larger_than, -younger_than, or younger_than. |
-
negate | -If |
-
by | -Which id ( |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
IMAP queries follows Polish notation, i.e. operators such as OR
- come before arguments, e.g. "OR argument1 argument2". Therefore, the
- relational operators functions in this package should be used like the
- following examples: OR(before("17-Apr-2015"), string("FROM", "Jim"))
.
- Even though there is no "AND" operator in IMAP, this package adds a helper
- funcion AND to indicate multiples arguments that must be searched
- together, e.g. AND(since("01-Jul-2018"), smaller_than(16000))
.
Other Date-search operations: search_before
,
- search_on
, search_period
,
- search_sent_before
,
- search_sent_on
,
- search_sent_period
,
- search_sent_since
,
- search_since
Other Size-search operations: search_larger_than
,
- search_smaller_than
Other Flag-search operations: search_flag
Other Within-search operations: search_older_than
,
- search_younger_than
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) -# search1 -result1 <- imapconf %>% - select_mailbox(mbox = "TAM") %>% - custom_search(custom_request = AND(string(section_or_field = "TO", - string = "allan"), - before(date_char = "12-Apr-2009") - )) -# searches for messages containing the string "allan" in the "TO" field -# and that were received before "12-Apr-2009". - -# search2 -result2 <- imapconf %>% - select_mailbox(mbox = "INBOX") %>% - custom_search(custom_request = OR(string(section_or_field = "TEXT", - string = "Contract 2872827"), - string(section_or_field = "Subject", - string = "Buying operation") - )) -# searches for messages containing the string "Contract 2872827" in the -# "TEXT" section or the string "Buying operation" in the "Subject" field -# of the HEADER. - -# }-
decode_base64_text_if_TRUE.Rd
Internal helper function for decoding base64 message results.
- -decode_base64_text_if_TRUE(msg)- -
msg | -A character string with a message content. |
-
---|
A string with a decoded message, if it was base64 coded.
- -Other fetch helper: check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- clean_fetch_results
Other cleaning: clean_fetch_results
decode_base64_text_if_needed.Rd
Internal helper function for decoding base64 message results.
- -decode_base64_text_if_needed(msg)- -
msg | -A character string with a message content. |
-
---|
A string with a decoded message, if it was base64 coded.
- -Other fetch helper: check_args_fetch_full_msg
,
- check_args_fetch_msg_header
,
- check_args_fetch_msg_metadata
,
- check_args_fetch_msg_text
,
- clean_fetch_results
Other cleaning: clean_fetch_results
define_searchrequest_custom.Rd
Internal helper function for defining curl custom request to be - used with each search function
- -define_searchrequest_custom(custom_request, negate, by, esearch, handle)- -
custom_request | -A string directly specifying what to search or -constructed by a combination of operators helper functions OR and -AND, and criteria helper functions such as before, since, -on, sent_before, sent_since, sent_on, -flag, string, smaller_than, larger_than, -younger_than, or younger_than. |
-
---|---|
negate | -If |
-
by | -Which id ( |
-
esearch | -A logical. Default is |
-
handle | -A curl handle object. |
-
A curl handle object containing the custom request.
- -Other search helper: check_args_custom_search
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_search_stripping
Other define searchrequest: define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
define_searchrequest_date.Rd
Internal helper function for defining curl custom request to be - used with each search function
- -define_searchrequest_date(operation, date_char, negate, by, flag, esearch, - handle)- -
operation | -A character indicating which custom operation to execute. |
-
---|---|
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
handle | -A curl handle object. |
-
A curl handle object containing the custom request.
- -Other search helper: check_args_custom_search
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
,
- define_searchrequest_custom
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_search_stripping
Other define searchrequest: define_searchrequest_custom
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
define_searchrequest_flag.Rd
Internal helper function for defining curl custom request to be - used with each search function
- -define_searchrequest_flag(flag, negate, by, esearch, handle)- -
flag | -A string specifying the flag to be used for filtering messages. -Use flag_options to list the common flags used by IMAP -servers. |
-
---|---|
negate | -If |
-
by | -Which id ( |
-
esearch | -A logical. Default is |
-
handle | -A curl handle object. |
-
A curl handle object containing the custom request.
- -Other search helper: check_args_custom_search
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_search_stripping
Other define searchrequest: define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
define_searchrequest_period.Rd
Internal helper function for defining curl custom request to be - used with each search function
- -define_searchrequest_period(operation1, since_date_char, operation2, - before_date_char, negate, by, flag, esearch, handle)- -
operation1 | -A character indicating the first argument -(SINCE and variations) to the custom request. |
-
---|---|
since_date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019" indicating the start date (inclusive). We opted not to -use objects of type "date", since IMAP servers like this not so common date -format. |
-
operation2 | -A character indicating the first argument -(BEFORE and variations) to the custom request. |
-
before_date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019" indicating the stop date (exclusive). We opted not to -use objects of type "date", since IMAP server likes this not so common date -format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
handle | -A curl handle object. |
-
A curl handle object containing the custom request.
- -Other search helper: check_args_custom_search
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_search_stripping
Other define searchrequest: define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
define_searchrequest_size.Rd
Internal helper function for defining curl custom request to be - used with each search function
- -define_searchrequest_size(operation, size, negate, by, flag, esearch, - handle)- -
operation | -A character indicating which custom operation to execute. |
-
---|---|
size | -An integer specifying the size (in number of characters) of -message to be used as search criterion. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
handle | -A curl handle object. |
-
A curl handle object containing the custom request.
- -Other search helper: check_args_custom_search
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_string
,
- define_searchrequest_within
,
- fix_search_stripping
Other define searchrequest: define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_string
,
- define_searchrequest_within
define_searchrequest_string.Rd
Internal helper function for defining curl custom request to be - used with each search function
- -define_searchrequest_string(section_or_field, string, negate, by, esearch, - handle)- -
section_or_field | -A mandatory character string specifying in which -message's Section or Header Field to search for the provided string. -For some available options, see section_or_field_options. |
-
---|---|
string | -A character string specifying the word or expression to -search for in messages. |
-
negate | -If |
-
by | -Which id ( |
-
esearch | -A logical. Default is |
-
handle | -A curl handle object. |
-
A curl handle object containing the custom request.
- -Other search helper: check_args_custom_search
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_within
,
- fix_search_stripping
Other define searchrequest: define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_within
define_searchrequest_within.Rd
Internal helper function for defining curl custom request to be - used with each search function
- -define_searchrequest_within(operation, seconds, negate, by, flag, esearch, - handle)- -
operation | -A character indicating which custom operation to execute. |
-
---|---|
seconds | -An integer specifying the number of seconds to be used as -search criterion. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
handle | -A curl handle object. |
-
A curl handle object containing the custom request.
- -Other search helper: check_args_custom_search
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- fix_search_stripping
Other define searchrequest: define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
deleteMsg.Rd
Deletes messages from a mailbox.
- -deleteMsg(imapconf, msg_id, by = "MSN", logical_output = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
logical_output | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the logical_output
parameter, returns a list
- of length 2
containing the imapconf
object and previously
- informed message ids (parameter msg_id
), or a logical vector of
- length 1
indicating the success (TRUE
) of the mentioned
- operation.
Other miscellaneous: addFlags
,
- copyMsg
, countMsgs
,
- expunge
, getMaxId
,
- getMinId
, moveMsg
,
- removeFlags
, replaceFlags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# deleting based on search results -result1 <- imapconf %>% - selectMailbox(mbox = "TAM") %>% - searchBefore(date_char = "10-may-2012", by = "UID") %$% #modified pipe operator - pass two argg - deleteMsg(imapconf = imapconf, msg_id = msg_id) - - -# deleting a specific msg_id without a previous search -result2 <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - deleteMsg(msg_id = 66128) - -# }-
delete_msg.Rd
Deletes messages from a mailbox.
- -delete_msg(imapconf, msg_id, by = "MSN", retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
An (invisible) list
of length 2
containing the
- imapconf
object and the previously inputed message ids
- (parameter msg_id
).
Other miscellaneous: add_flags
,
- copy_msg
, count_msgs
,
- expunge
, get_max_id
,
- get_min_id
, move_msg
,
- remove_flags
, replace_flags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# deleting based on search results -result1 <- imapconf %>% - select_mailbox(mbox = "TAM") %>% - search_before(date_char = "10-may-2012", by = "UID") %$% #modified pipe operator - pass two argg - delete_msg(imapconf = imapconf, msg_id = msg_id) - - -# deleting a specific msg_id without a previous search -result2 <- imapconf %>% - select_mailbox(mbox = "INBOX") %>% - delete_msg(msg_id = 66128) - -# }-
examineMailbox.Rd
Retrieve the number of recent messages and the total number of - messages in a mailbox.
- -examineMailbox(imapconf, retries = 2)- -
imapconf | -An object of class |
-
---|---|
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A vector
containing the ("EXISTS"
) and the
- ("RECENT"
) number of messages in the selected mailbox.
Other mailbox commands: listMailboxes
,
- listServerCapabilities
,
- renameMailbox
, selectMailbox
# NOT RUN { -# configure IMAP -#' library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# list mailboxes -results <- imapconf %>% - listMailboxes() %>% - selectMailbox(mbox = "Sent") %>% - examineMailbox() - -# }-
examine_mailbox.Rd
Retrieve the number of recent messages and the total number of - messages in a mailbox.
- -examine_mailbox(imapconf, retries = 2)- -
imapconf | -An object of class |
-
---|---|
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A vector
containing the ("EXISTS"
) and the
- ("RECENT"
) number of messages in the selected mailbox.
Other mailbox commands: list_mailboxes
,
- list_server_capabilities
,
- rename_mailbox
,
- select_mailbox
# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# list mailboxes -results <- imapconf %>% - list_mailboxes() %>% - select_mailbox(mbox = "Sent") %>% - examine_mailbox() - -# }-
R/execute-attachment-fetch.R
- execute_attachment_fetch.Rd
Execution engine loop for all the fetch commands
-execute_attachment_fetch( - self, - id, - id_folder, - df_meta_to_fetch, - fetch_request, - folder_clean, - url_folder, - content_disposition, - override, - retries -)- -
self | -The R6 connection object. |
-
---|---|
id | -A message id obtained inside the main loop in |
-
id_folder | -The name of the folder containing the message id. |
-
df_meta_to_fetch | -A |
-
fetch_request | -A string containing the fetch request to the server that -will be added to the curl handle. |
-
folder_clean | -A |
-
url_folder | -The name of the folder containing the message url of the IMAP server. |
-
content_disposition | -A |
-
override | -A |
-
retries | -Number of attempts to connect and execute the command. Default
- is @noRd |
-
R/execute-complementary-operations.R
- execute_complementary_operations.Rd
Execution engine for all the complementary commands
-execute_complementary_operations(self, url, handle, customrequest, retries)- -
self | -The R6 connection object. |
-
---|---|
url | -A string containing the url from the |
-
handle | -A curl handle object with the custom request already defined. |
-
customrequest | -A string containing the custom request to the server that will -be added to the curl handle. |
-
retries | -Number of attempts to connect and execute the command. Default
- is |
-
R/execute-fetch-loop.R
- execute_fetch_loop.Rd
Execution engine loop for all the fetch commands
-execute_fetch_loop( - self, - msg_id, - fetch_request, - use_uid, - write_to_disk, - keep_in_mem, - retries, - fetch_type, - base64_decode = FALSE, - metadata_attribute = NULL -)- -
self | -The R6 connection object. |
-
---|---|
msg_id | -A |
-
fetch_request | -A string containing the fetch request to the server that -will be added to the curl handle. |
-
use_uid | -Default is |
-
write_to_disk | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
fetch_type | -A string indicating if it will be executed a body, header, -text, or metadata fetch. |
-
base64_decode | -If |
-
metadata_attribute | -String containing the meta attributes if applicable. Default
- is @noRd |
-
exposition.Rd
Exposition Pipe operator
- -expunge.Rd
Expunge a specific message (using specific UID) or all messages - marked as "DELETED" in a mailbox.
- -expunge(imapconf, specific_UID = NULL, retries = 2)- -
imapconf | -An object of class |
-
---|---|
specific_UID | -A numeric vector containing one or more messages UIDs, if -specific messages should be expunged and not the whole mailbox. |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
The (invisible) imapconf object that was previously inputed.
- -Other miscellaneous: add_flags
,
- copy_msg
, count_msgs
,
- delete_msg
, get_max_id
,
- get_min_id
, move_msg
,
- remove_flags
, replace_flags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# deleting a message using specific UID -result1 <- imapconf %>% - select_mailbox(mbox = "TAM") %>% - delete_msg(msg_id = 71171, by = "UID") %$% - expunge(imapconf = imapconf, specific_UID = msg_id) - - -# expunge all message smarked as "DELETED" in INBOX -result2 <- imapconf %>% - select_mailbox(mbox = "INBOX") %>% - expunge() - -# }-
fetchFullMsg.Rd
Fetch all the sections and fields of one or more messages.
- -fetchFullMsg(imapconf, msg_id, by = "MSN", peek = TRUE, - partial = NULL, write_to_file = FALSE, keep_in_mem = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
peek | -If |
-
partial | -
|
-
write_to_file | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A list
or/and text files containing the fetch results.
Other fetch: fetchMsgHeader
,
- fetchMsgMetadata
,
- fetchMsgText
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# fetching -results <- imapconf %>% - selectMailbox(mbox = "TAM") %>% - searchBefore(date_char = "10-may-2012", by = "UID") %$% #exposition pipe - two argg - fetchFullMsg(imapconf = imapconf, msg_id = msg_id, - by="UID", write_to_file = TRUE, keep_in_mem = FALSE, - partial = "0.789") - -# }-
fetchMsgHeader.Rd
Fetch header fields of one or more messages.
- -fetchMsgHeader(imapconf, msg_id, by = "MSN", fields = NULL, - negate_fields = FALSE, peek = TRUE, partial = NULL, - write_to_file = FALSE, keep_in_mem = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
fields | -A character vector specifying which field(s) to fetch from -messages. See section_or_field_options |
-
negate_fields | -If |
-
peek | -If |
-
partial | -
|
-
write_to_file | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A list
or/and text files containing the fetch results.
Other fetch: fetchFullMsg
,
- fetchMsgMetadata
,
- fetchMsgText
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) -# fetching -results <- imapconf %>% - selectMailbox(mbox = "TAM") %>% - searchBefore(date_char = "10-may-2012", by = "UID") %$% #exposition pipe - two argg - fetchMsgHeader(imapconf = imapconf, msg_id = msg_id, fields = c("From", "To")) - -# }-
fetchMsgMetadata.Rd
Fetch Metadata of one or more messages.
- -fetchMsgMetadata(imapconf, msg_id, by = "MSN", metadata, - write_to_file = FALSE, keep_in_mem = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
metadata | -A character vector or string specifying one or more items of -the metadata of a message to fetch. See metadata_options. |
-
write_to_file | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A list
or/and text files containing the fetch results.
Other fetch: fetchFullMsg
,
- fetchMsgHeader
, fetchMsgText
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# fetching -results <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - searchSentSince(date_char = "26-Aug-2008") %$% #exposition pipe - two argg - fetchMsgMetadata(imapconf, msg_id = msg_id, by = "UID", - metadata = c("INTERNALDATE", "UID", "ENVELOPE", "FLAGS", - "RFC822.SIZE", "BODYSTRUCTURE")) - -# }-
fetchMsgText.Rd
Fetch Text section of one or more messages.
- -fetchMsgText(imapconf, msg_id, by = "MSN", peek = TRUE, - partial = NULL, write_to_file = FALSE, keep_in_mem = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
peek | -If |
-
partial | -
|
-
write_to_file | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A list
or/and text files containing the fetch results.
Other fetch: fetchFullMsg
,
- fetchMsgHeader
,
- fetchMsgMetadata
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# fetching and saving results to disk -results <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - searchSentSince(date_char = "26-Aug-2008") %$% #exposition pipe - two argg - fetchMsgText(imapconf = imapconf, msg_id = msg_id, write_to_file = TRUE) - -# }-
fetch_full_msg.Rd
Fetch all the sections and fields of one or more messages.
- -fetch_full_msg(imapconf, msg_id, by = "MSN", peek = TRUE, - partial = NULL, write_to_disk = FALSE, keep_in_mem = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
peek | -If |
-
partial | -
|
-
write_to_disk | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A list
or/and text files containing the fetch results.
Other fetch: fetch_msg_header
,
- fetch_msg_metadata
,
- fetch_msg_text
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# fetching -results <- imapconf %>% - select_mailbox(mbox = "TAM") %>% - search_before(date_char = "10-may-2012", by = "UID") %$% #exposition pipe - two argg - fetch_full_msg(imapconf = imapconf, - msg_id = msg_id, - by="UID", write_to_disk = TRUE, - keep_in_mem = FALSE, - partial = "0.789") - -# }-
fetch_msg_header.Rd
Fetch header fields of one or more messages.
- -fetch_msg_header(imapconf, msg_id, by = "MSN", fields = NULL, - negate_fields = FALSE, peek = TRUE, partial = NULL, - write_to_disk = FALSE, keep_in_mem = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
fields | -A character vector specifying which field(s) to fetch from -messages. See section_or_field_options |
-
negate_fields | -If |
-
peek | -If |
-
partial | -
|
-
write_to_disk | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A list
or/and text files containing the fetch results.
Other fetch: fetch_full_msg
,
- fetch_msg_metadata
,
- fetch_msg_text
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) -# fetching -results <- imapconf %>% - select_mailbox(mbox = "TAM") %>% - search_before(date_char = "10-may-2012", by = "UID") %$% #exposition pipe - two argg - fetch_msg_header(imapconf = imapconf, msg_id = msg_id, fields = c("From", "To")) - -# }-
fetch_msg_metadata.Rd
Fetch Metadata of one or more messages.
- -fetch_msg_metadata(imapconf, msg_id, by = "MSN", metadata, - write_to_disk = FALSE, keep_in_mem = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
metadata | -A character vector or string specifying one or more items of -the metadata of a message to fetch. See metadata_options. |
-
write_to_disk | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A list
or/and text files containing the fetch results.
Other fetch: fetch_full_msg
,
- fetch_msg_header
,
- fetch_msg_text
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# fetching -results <- imapconf %>% - select_mailbox(mbox = "INBOX") %>% - search_sent_since(date_char = "26-Aug-2008") %$% #exposition pipe - two argg - fetch_msg_metadata(imapconf, msg_id = msg_id, by = "UID", - metadata = c("INTERNALDATE", "UID", "ENVELOPE", "FLAGS", - "RFC822.SIZE", "BODYSTRUCTURE")) - -# }-
fetch_msg_text.Rd
Fetch Text section of one or more messages.
- -fetch_msg_text(imapconf, msg_id, by = "MSN", peek = TRUE, - partial = NULL, write_to_disk = FALSE, keep_in_mem = TRUE, - try_b64decode = FALSE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
peek | -If |
-
partial | -
|
-
write_to_disk | -If |
-
keep_in_mem | -If |
-
try_b64decode | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A list
or/and text files containing the fetch results.
Other fetch: fetch_full_msg
,
- fetch_msg_header
,
- fetch_msg_metadata
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# fetching and saving results to disk -results <- imapconf %>% - select_mailbox(mbox = "INBOX") %>% - search_sent_since(date_char = "26-Aug-2008") %$% #exposition pipe - two argg - fetch_msg_text(imapconf = imapconf, msg_id = msg_id, write_to_disk = TRUE) - -# }-
fix_searchStripping.Rd
Fixes stripped results from search operations when server may - have stripped some lines.
- -fix_searchStripping(response)- -
response | -An integer |
-
---|
An integer vector
.
Other search helper: check_args_customSearch
,
- check_args_searchDate
,
- check_args_searchFlag
,
- check_args_searchPeriod
,
- check_args_searchSize
,
- check_args_searchString
,
- check_args_searchWithin
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
fix_search_stripping.Rd
Fixes stripped results from search operations when server may - have stripped some lines.
- -fix_search_stripping(response)- -
response | -An integer |
-
---|
An integer vector
.
Other search helper: check_args_custom_search
,
- check_args_search_date
,
- check_args_search_flag
,
- check_args_search_period
,
- check_args_search_size
,
- check_args_search_string
,
- check_args_search_within
,
- define_searchrequest_custom
,
- define_searchrequest_date
,
- define_searchrequest_flag
,
- define_searchrequest_period
,
- define_searchrequest_size
,
- define_searchrequest_string
,
- define_searchrequest_within
flag_options.Rd
Lists flags used by most of IMAP servers.
- -flag_options()
-
- A data.frame
containing flag names, its descriptions, and its
- antonym versions.
RFC 2060 lists a set of systems flags, which are presentend and extended
- by this function. We also present a list of negative flags. When using
- verbose = TRUE
in configure_imap function, flags appear
- with "\", e.g. "\Seen". It is important to note that some (but not all)
- functions that deal with flags also accepts, keywords - words usually
- listed (when verbose = TRUE) together with flags by the server but with
- no leading "\"). This is the case of add_flags,
- remove_flags, and replace_flags.
Crispin, M., "Internet Message Access Protocol - Version 4rev1", - RFC 2060, doi: 10.17487/RFC2060 -, December 1996, - https://www.rfc-editor.org/info/rfc2060.
- -Other options: metadata_options
,
- section_or_field_options
# NOT RUN { -library(mRpostman) -flag_options() - -# }-
getMaxId.Rd
Get the greater (maximum) message id in a Mailbox, considering - messages with a specific flag
- -getMaxId(imapconf, by = "MSN", flag, retries = 2)- -
imapconf | -An object of class |
-
---|---|
by | -Which id ( |
-
flag | -A string specifying the flag to be used for filtering messages.
-Use flag_options to list the common flags used by IMAP
-servers. Default is |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A numeric vector
of length 1
indicating the minimum id.
getMaxId
uses ESEARCH
extension. Check if your server
- supports ESEARCH
capability with listServerCapabilities.
Other miscellaneous: addFlags
,
- copyMsg
, countMsgs
,
- deleteMsg
, expunge
,
- getMinId
, moveMsg
,
- removeFlags
, replaceFlags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -results <- imapconf %>% - selectMailbox(mbox = "[Gmail]/Trash") %>% - getMaxId(by = "UID", flag = "SEEN") - -# }-
getMinId.Rd
Get the smaller (minimum) message id in a Mailbox, considering - messages with a specific flag
- -getMinId(imapconf, by = "MSN", flag, retries = 2)- -
imapconf | -An object of class |
-
---|---|
by | -Which id ( |
-
flag | -A string specifying the flag to be used for filtering messages.
-Use flag_options to list the common flags used by IMAP
-servers. Default is |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A numeric vector
of length 1
indicating the minimum id.
getMaxId
uses ESEARCH
extension. Check if your server
- supports ESEARCH
capability with listServerCapabilities.
Other miscellaneous: addFlags
,
- copyMsg
, countMsgs
,
- deleteMsg
, expunge
,
- getMaxId
, moveMsg
,
- removeFlags
, replaceFlags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -results <- imapconf %>% - selectMailbox(mbox = "[Gmail]/Trash") %>% - getMinId(flag = "UNSEEN") - -# }-
get_attachment.Rd
Get attachments after fetching full messages.
- -get_attachment(msg_list)- -
msg_list | -A |
-
---|
A logical TRUE
if the attachments extraction was successful.
All attachments will be stored in a folder labelled with the message id
- inside the working directory. This function currently handles only attachments
- encoded as base64
text. It tries to guess all file extensions while decoding
- the text, but it may not be possible in some circumstances. In those cases,
- you can try to change the file extension by directly renaming the file.
Other attachments: list_attachments
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# extracting attachments -imapconf %>% - select_mailbox(mbox = "TAM") %>% - search_before(date_char = "10-may-2012", by = "UID") %$% #exposition pipe - two argg - fetch_full_msgs(imapconf = imapconf, msg_id = msg_id) %>% - get_attachments() - -# }-
get_attachments.Rd
Get attachments after fetching full messages.
- -get_attachments(msg_list, content_disposition = "both")- -
msg_list | -A |
-
---|---|
content_disposition | -A |
-
A logical TRUE
if the attachments extraction was successful.
All attachments will be stored in a folder labelled with the message id
- inside the working directory. This function currently handles only attachments
- encoded as base64
text. It tries to guess all file extensions while
- decoding the text, but it may not be possible to do it in some circumstances.
- If it happens, you can try to change the file extension directly by renaming
- the file.
The "Content-Disposition" header specifies if the multipart electronic
- messages will be presented as a main document with a list of separate
- attachments ("Content-Disposition: attachment") or as a single document
- with the various parts displayed inline. The first requires positive action
- on the part of recipient, i.e. downloading the file, whereas inline
- components are displayed automatically when the message is viewed
- (Troost, R., Dorner, S., and K. Moore, Ed. (1997)). You can choose
- to download both
, or only one of the types of attachments, using the
- argument content_disposition
.
Troost, R., Dorner, S., and K. Moore, Ed., - Communicating Presentation Information in Internet Messages: - The Content-Disposition Header Field, RFC 2183, DOI 10.17487/RFC2183, - August 1997, https://www.rfc-editor.org/info/rfc2183.
- -Other attachments: list_attachments
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# extracting attachments -imapconf %>% - select_mailbox(mbox = "TAM") %>% - search_before(date_char = "10-may-2012", by = "UID") %$% #exposition pipe - two argg - fetch_full_msgs(imapconf = imapconf, msg_id = msg_id) %>% - get_attachments() - -# }-
get_max_id.Rd
Get the greater (maximum) message id in a Mailbox, considering - messages with a specific flag.
- -get_max_id(imapconf, by = "MSN", flag, retries = 2)- -
imapconf | -An object of class |
-
---|---|
by | -Which id ( |
-
flag | -A string specifying the flag to be used for filtering messages.
-Use flag_options to list the common flags used by IMAP
-servers. Default is |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A numeric vector
of length 1
indicating the minimum id.
get_max_id
uses ESEARCH
extension. Check if your server
- supports ESEARCH
capability with list_server_capabilities.
Other miscellaneous: add_flags
,
- copy_msg
, count_msgs
,
- delete_msg
, expunge
,
- get_min_id
, move_msg
,
- remove_flags
, replace_flags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -results <- imapconf %>% - select_mailbox(mbox = "[Gmail]/Trash") %>% - get_max_id(by = "UID", flag = "SEEN") - -# }-
get_min_id.Rd
Get the smaller (minimum) message id in a Mailbox, considering - messages with a specific flag.
- -get_min_id(imapconf, by = "MSN", flag, retries = 2)- -
imapconf | -An object of class |
-
---|---|
by | -Which id ( |
-
flag | -A string specifying the flag to be used for filtering messages.
-Use flag_options to list the common flags used by IMAP
-servers. Default is |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A numeric vector
of length 1
indicating the minimum id.
get_max_id
uses ESEARCH
extension. Check if your server
- supports ESEARCH
capability with list_server_capabilities.
Other miscellaneous: add_flags
,
- copy_msg
, count_msgs
,
- delete_msg
, expunge
,
- get_max_id
, move_msg
,
- remove_flags
, replace_flags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -results <- imapconf %>% - select_mailbox(mbox = "[Gmail]/Trash") %>% - get_min_id(flag = "UNSEEN") - -# }-
has_attachment.Rd
Internal helper function for attachment checking in messages.
- -has_attachment(msg)- -
msg | -An object of class |
-
---|
A logical
containing TRUE
if there is one or more
- attachments and FALSE
if there is none.
Other attachments helper: check_args_get_attachments
,
- check_args_list_attachments
largerThan.Rd
Criteria helper functions to be combined inside a operator helper - function as a custom request in customSearch.
- -largerThan(size, negate = FALSE)- -
size | -An integer specifying the size (in number characters) of message to be used as search -criterion. |
-
---|---|
negate | -If |
-
A search string to be used as a custom_request
parameter in
- customSearch function.
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -result <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - customSearch(custom_request = - OR(String( - section_or_field = "from", string = "allanvcq@gmail.com"), - largerThan( - size = 512000) - ) - ) -# searches for messages containing the string "allanvcq@gmail.com" in the field "FROM" - OR those largerThan 512KB. - -# } --
listMailboxes.Rd
List Mailboxes from IMAP server.
- -listMailboxes(imapconf, retries = 2)- -
imapconf | -An object of class |
-
---|---|
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A list
containing the Mailboxes (root and children).
Other mailbox commands: examineMailbox
,
- listServerCapabilities
,
- renameMailbox
, selectMailbox
# NOT RUN { -# configure IMAP -#' library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# list mailboxes -results <- imapconf %>% - listMailboxes() - -# }-
listServerCapabilities.Rd
Lists IMAP server's capabilities.
- -listServerCapabilities(imapconf, retries = 2)- -
imapconf | -An object of class |
-
---|---|
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A character vector
containing server's IMAP capacbilities.
Other mailbox commands: examineMailbox
,
- listMailboxes
, renameMailbox
,
- selectMailbox
# NOT RUN { -# configure IMAP -#' library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# list server's capabilities -results <- imapconf %>% - listServerCapabilities() - -# }--
list_mailboxes.Rd
List Mailboxes from IMAP server.
- -list_mailboxes(imapconf, retries = 2)- -
imapconf | -An object of class |
-
---|---|
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A list
containing the Mailboxes (root and children).
Other mailbox commands: examine_mailbox
,
- list_server_capabilities
,
- rename_mailbox
,
- select_mailbox
# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# list mailboxes -results <- imapconf %>% - list_mailboxes() - -# }-
list_server_capabilities.Rd
Lists IMAP server's capabilities.
- -list_server_capabilities(imapconf, retries = 2)- -
imapconf | -An object of class |
-
---|---|
retries | -Number of attempts to connect and execute the command. Default
-is |
-
A character vector
containing server's IMAP capacbilities.
Other mailbox commands: examine_mailbox
,
- list_mailboxes
,
- rename_mailbox
,
- select_mailbox
# NOT RUN { -# configure IMAP -#' library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# list server's capabilities -results <- imapconf %>% - list_server_capabilities() - -# }--
loop_fetchFullMsg.Rd
Internal helper function for loop execution used in fetch - functions.
- -loop_fetchFullMsg(new_imapconf, msg_id, by, peek, partial, write_to_disk, - keep_in_mem, retries, handle)- -
new_imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
peek | -If |
-
partial | -
|
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
handle | -A curl handle object. |
-
A list
or/and text files containing the fetch results.
Other fetch helpers: loop_fetchMsgHeader
,
- loop_fetchMsgMetadata
,
- loop_fetchMsgText
Other loop: loop_fetchMsgHeader
,
- loop_fetchMsgMetadata
,
- loop_fetchMsgText
loop_fetchMsgHeader.Rd
Internal helper function for loop execution used in fetch - functions.
- -loop_fetchMsgHeader(new_imapconf, msg_id, by, fields, negate_fields, peek, - partial, write_to_disk, keep_in_mem, retries, handle)- -
new_imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
fields | -A character vector specifying which field(s) to fetch from -messages. See section_or_field_options |
-
negate_fields | -If |
-
peek | -If |
-
partial | -
|
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
handle | -A curl handle object. |
-
A list
or/and text files containing the fetch results.
Other fetch helpers: loop_fetchFullMsg
,
- loop_fetchMsgMetadata
,
- loop_fetchMsgText
Other loop: loop_fetchFullMsg
,
- loop_fetchMsgMetadata
,
- loop_fetchMsgText
loop_fetchMsgMetadata.Rd
Internal helper function for loop execution used in fetch - functions.
- -loop_fetchMsgMetadata(new_imapconf, msg_id, by, metadata, write_to_disk, - keep_in_mem, retries, handle)- -
new_imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
metadata | -A character vector or string specifying one or more items of -the metadata of a message to fetch. See metadata_options. |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
handle | -A curl handle object. |
-
A list
or/and text files containing the fetch results.
Other fetch helpers: loop_fetchFullMsg
,
- loop_fetchMsgHeader
,
- loop_fetchMsgText
Other loop: loop_fetchFullMsg
,
- loop_fetchMsgHeader
,
- loop_fetchMsgText
loop_fetchMsgText.Rd
Internal helper function for loop execution used in fetch - functions.
- -loop_fetchMsgText(new_imapconf, msg_id, by, peek, partial, write_to_disk, - keep_in_mem, retries, handle)- -
new_imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
peek | -If |
-
partial | -
|
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
handle | -A curl handle object. |
-
A list
or/and text files containing the fetch results.
Other fetch helpers: loop_fetchFullMsg
,
- loop_fetchMsgHeader
,
- loop_fetchMsgMetadata
Other loop: loop_fetchFullMsg
,
- loop_fetchMsgHeader
,
- loop_fetchMsgMetadata
loop_fetch_full_msg.Rd
Internal helper function for loop execution used in fetch - functions.
- -loop_fetch_full_msg(new_imapconf, msg_id, by, peek, partial, write_to_disk, - keep_in_mem, retries, handle)- -
msg_id | -A numeric vetor containing one or more messages ids. |
-
---|---|
by | -Which id ( |
-
peek | -If |
-
partial | -
|
-
write_to_disk | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
handle | -A curl handle object. |
-
imapconf | -An object of class |
-
A list
or/and text files containing the fetch results.
Other fetch helpers: loop_fetch_msg_header
,
- loop_fetch_msg_metadata
,
- loop_fetch_msg_text
Other loop: loop_fetch_msg_header
,
- loop_fetch_msg_metadata
,
- loop_fetch_msg_text
loop_fetch_msg_header.Rd
Internal helper function for loop execution used in fetch - functions.
- -loop_fetch_msg_header(new_imapconf, msg_id, by, fields, negate_fields, - peek, partial, write_to_disk, keep_in_mem, retries, handle)- -
msg_id | -A numeric vetor containing one or more messages ids. |
-
---|---|
by | -Which id ( |
-
fields | -A character vector specifying which field(s) to fetch from -messages. See section_or_field_options |
-
negate_fields | -If |
-
peek | -If |
-
partial | -
|
-
write_to_disk | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
handle | -A curl handle object. |
-
imapconf | -An object of class |
-
A list
or/and text files containing the fetch results.
Other fetch helpers: loop_fetch_full_msg
,
- loop_fetch_msg_metadata
,
- loop_fetch_msg_text
Other loop: loop_fetch_full_msg
,
- loop_fetch_msg_metadata
,
- loop_fetch_msg_text
loop_fetch_msg_metadata.Rd
Internal helper function for loop execution used in fetch - functions.
- -loop_fetch_msg_metadata(new_imapconf, msg_id, by, metadata, write_to_disk, - keep_in_mem, retries, handle)- -
msg_id | -A numeric vetor containing one or more messages ids. |
-
---|---|
by | -Which id ( |
-
metadata | -A character vector or string specifying one or more items of -the metadata of a message to fetch. See metadata_options. |
-
write_to_disk | -If |
-
keep_in_mem | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
handle | -A curl handle object. |
-
imapconf | -An object of class |
-
A list
or/and text files containing the fetch results.
Other fetch helpers: loop_fetch_full_msg
,
- loop_fetch_msg_header
,
- loop_fetch_msg_text
Other loop: loop_fetch_full_msg
,
- loop_fetch_msg_header
,
- loop_fetch_msg_text
loop_fetch_msg_text.Rd
Internal helper function for loop execution used in fetch - functions.
- -loop_fetch_msg_text(new_imapconf, msg_id, by, peek, partial, write_to_disk, - keep_in_mem, try_b64decode, retries, handle)- -
msg_id | -A numeric vetor containing one or more messages ids. |
-
---|---|
by | -Which id ( |
-
peek | -If |
-
partial | -
|
-
write_to_disk | -If |
-
keep_in_mem | -If |
-
try_b64decode | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
handle | -A curl handle object. |
-
imapconf | -An object of class |
-
A list
or/and text files containing the fetch results.
Other fetch helpers: loop_fetch_full_msg
,
- loop_fetch_msg_header
,
- loop_fetch_msg_metadata
Other loop: loop_fetch_full_msg
,
- loop_fetch_msg_header
,
- loop_fetch_msg_metadata
moveMsg.Rd
Moves messages between mailboxes.
- -moveMsg(imapconf, msg_id, by = "MSN", to_mbox, reselect_mbox = FALSE, - logical_output = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
to_mbox | -A character string specifying the mailbox to which messages -will be moved to. |
-
reselect_mbox | -If |
-
logical_output | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the logical_output
parameter, returns a list
- of length 2
containing the imapconf
object and previously
- informed message ids (parameter msg_id
), or a logical vector of
- length 1
indicating the success (TRUE
) of the mentioned
- operation.
moveMsg
uses MOVE
extension. Check if your server
- supports MOVE
capability with listServerCapabilities.
Other miscellaneous: addFlags
,
- copyMsg
, countMsgs
,
- deleteMsg
, expunge
,
- getMaxId
, getMinId
,
- removeFlags
, replaceFlags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# copy search results from "Sent" to "INBOX" -results <- imapconf %>% - selectMailbox(mbox = "Sent") %>% - searchBefore(date_char = "10-may-2012") %$% #exposition pipe operator - pass two argg - moveMsg(imapconf = imapconf, msg_id = msg_id, to_mbox = "Other Mailbox") - -# the same result can be achieved with a combination of: -results <- imapconf %>% - selectMailbox(mbox = "Sent") %>% - searchBefore(date_char = "10-may-2012") %$% #exposition pipe operator - pass two argg - copyMsg(imapconf = imapconf, msg_id = msg_id, to_mbox = "Other Mailbox") %$% - addFlags(imapconf = imapconf, msg_id = msg_id, flags_to_set = "Deleted") %$% - expunge() - -# }-
move_msg.Rd
Moves messages between mailboxes.
- -move_msg(imapconf, msg_id, by = "MSN", to_mbox, reselect_mbox = FALSE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
to_mbox | -A character string specifying the mailbox to which messages -will be moved to. |
-
reselect_mbox | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
An (invisible) list
of length 2
containing the
- imapconf
object and the previously inputed message ids
- (parameter msg_id
).
move_msg
uses MOVE
extension. Check if your server
- supports MOVE
capability with list_server_capabilities.
Other miscellaneous: add_flags
,
- copy_msg
, count_msgs
,
- delete_msg
, expunge
,
- get_max_id
, get_min_id
,
- remove_flags
, replace_flags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# copy search results from "Sent" to "INBOX" -results <- imapconf %>% - select_mailbox(mbox = "Sent") %>% - search_before(date_char = "10-may-2012") %$% #exposition pipe operator - pass two argg - move_msg(imapconf = imapconf, msg_id = msg_id, to_mbox = "Other Mailbox") - -# the same result can be achieved with a combination of: -results <- imapconf %>% - select_mailbox(mbox = "Sent") %>% - search_before(date_char = "10-may-2012") %$% #exposition pipe operator - pass two argg - copy_msg(imapconf = imapconf, msg_id = msg_id, to_mbox = "Other Mailbox") %$% - add_flags(imapconf = imapconf, msg_id = msg_id, flags_to_set = "Deleted") %$% - expunge() - -# }-
olderThan.Rd
Criteria helper functions to be combined inside a operator helper - function as a custom request in customSearch.
- -olderThan(seconds, negate = FALSE)- -
seconds | -An integer specifying the number of seconds to be used as -search criterion. |
-
---|---|
negate | -If |
-
A search string to be used as a custom_request
parameter in
- customSearch function.
Other customsearch helper functions: AND
,
- Before
, Flag
,
- OR
, Since
,
- String
, sentBefore
,
- sentOn
, sentSince
,
- smallerThan
, youngerThan
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -result <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - customSearch(custom_request = - OR(String( - section_or_field = "from", string = "allanvcq@gmail.com"), - olderThan( - seconds = 3600) - ) - ) -# searches for messages containing the string "allanvcq@gmail.com" in the field "FROM" - OR messgaes that are "older" than one hour (messages arrived 3more than - 600 seconds ago). - -# } --
removeFlags.Rd
Remove one or more flags from one or more messages.
- -removeFlags(imapconf, msg_id, by = "MSN", flags_to_unset, - logical_output = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
flags_to_unset | -A character vector containing one ore more flag names to -remove from the specified message ids. |
-
logical_output | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the logical_output
parameter, returns a list
- of length 2
containing the imapconf
object and previously
- informed message ids (parameter msg_id
), or a logical vector of
- length 1
indicating the success (TRUE
) of the mentioned
- operation.
addFlags, removeFlags and replaceFlags, accepts
- not only flags but also keywords (such as $Phishing
on Gmail's
- IMAP server) to add, remove or replace.
IMAP servers do not allow setting the negative version of a flag when a
- message already has the positive version of it. If a message with
- MSN 1
already has the "SEEN" flag, it is not allowed to add "UNSEEN"
- to that. Instead, you have to first remove the "SEEN" flag
- removeFlags(imapconf, msg_id = 1, "SEEN")
and only then do
- addFlags(imapconf, msg_id = 1, "SEEN")
. Another option is to
- complete override all the flags of a message or a set of messages using
- replaceFlags(imapconf, msg_id = 1, "SEEN")
.
Other miscellaneous: addFlags
,
- copyMsg
, countMsgs
,
- deleteMsg
, expunge
,
- getMaxId
, getMinId
,
- moveMsg
, replaceFlags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -result1 <- imapconf %>% - selectMailbox(mbox = "TAM") %>% - searchBefore(date_char = "10-may-2012", by = "UID") %$% #exposition pipe - two argg - removeFlags(imapconf = imapconf, msg_id = msg_id, flags_to_unset = c("RECENT", "$NotPhishing")) - -# }-
remove_flags.Rd
Remove one or more flags from one or more messages.
- -remove_flags(imapconf, msg_id, by = "MSN", flags_to_unset, retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
flags_to_unset | -A character vector containing one ore more flag names to -remove from the specified message ids. |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
An (invisible) list
of length 2
containing the
- imapconf
object and the previously inputed message ids
- (parameter msg_id
).
add_flags, remove_flags and replace_flags, accepts
- not only flags but also keywords (such as $Phishing
on Gmail's
- IMAP server) to add, remove or replace.
IMAP servers do not allow setting the negative version of a flag when a
- message already has the positive version of it. If a message with
- MSN 1
already has the "SEEN" flag, it is not allowed to add "UNSEEN"
- to that. Instead, you have to first remove the "SEEN" flag
- remove_flags(imapconf, msg_id = 1, "SEEN")
and only then do
- add_flags(imapconf, msg_id = 1, "SEEN")
. Another option is to
- complete override all the flags of a message or a set of messages using
- replace_flags(imapconf, msg_id = 1, "SEEN")
.
Other miscellaneous: add_flags
,
- copy_msg
, count_msgs
,
- delete_msg
, expunge
,
- get_max_id
, get_min_id
,
- move_msg
, replace_flags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -result1 <- imapconf %>% - select_mailbox(mbox = "TAM") %>% - search_before(date_char = "10-may-2012", by = "UID") %$% #exposition pipe - two argg - remove_flags(imapconf = imapconf, msg_id = msg_id, flags_to_unset = c("RECENT", "$NotPhishing")) - -# }-
renameMailbox.Rd
Rename a mailbox.
- -renameMailbox(imapconf, new_name, reselect_mbox = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
new_name | -A string containing the new name to be set. |
-
reselect_mbox | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
An imaconf
object with the newer selected mailbox added
- to it. If reselect_mbox
is FALSE
, it returns the
- imaconf
object with the former mailbox name.
Other mailbox commands: examineMailbox
,
- listMailboxes
,
- listServerCapabilities
,
- selectMailbox
# NOT RUN { -# configure IMAP -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# rename mailbox "Sent" -imapconf %>% - selectMailbox(mbox = "Sent") %>% - renameMailbox(new_name = "Sent Mail") - -# }-
rename_mailbox.Rd
Rename a mailbox.
- -rename_mailbox(imapconf, new_name, reselect_mbox = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
new_name | -A string containing the new name to be set. |
-
reselect_mbox | -If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
An (invisible) imaconf
object with the newer selected mailbox added
- to it. If reselect_mbox
is FALSE
, it returns the
- imaconf
object with the former mailbox name.
Other mailbox commands: examine_mailbox
,
- list_mailboxes
,
- list_server_capabilities
,
- select_mailbox
# NOT RUN { -# configure IMAP -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# rename mailbox "Sent" -imapconf %>% - select_mailbox(mbox = "Sent") %>% - rename_mailbox(new_name = "Sent Mail") - -# }-
replaceFlags.Rd
Replaces all flags in messages by one or more flags.
- -replaceFlags(imapconf, msg_id, by = "MSN", flags_to_set, - logical_output = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
flags_to_set | -A character vector containing one ore more flag names to -add to or replace in the specified message ids. |
-
logical_output | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the logical_output
parameter, returns a list
- of length 2
containing the imapconf
object and previously
- informed message ids (parameter msg_id
), or a logical vector of
- length 1
indicating the success (TRUE
) of the mentioned
- operation.
addFlags, removeFlags and replaceFlags, accepts
- not only flags but also keywords (such as $Phishing
on Gmail's
- IMAP server) to add, remove or replace.
IMAP servers do not allow setting the negative version of a flag when a
- message already has the positive version of it. If a message with
- MSN 1
already has the "SEEN" flag, it is not allowed to add "UNSEEN"
- to that. Instead, you have to first remove the "SEEN" flag
- removeFlags(imapconf, msg_id = 1, "SEEN")
and only then do
- addFlags(imapconf, msg_id = 1, "SEEN")
. Another option is to
- complete override all the flags of a message or a set of messages using
- replaceFlags(imapconf, msg_id = 1, "SEEN")
.
Other miscellaneous: addFlags
,
- copyMsg
, countMsgs
,
- deleteMsg
, expunge
,
- getMaxId
, getMinId
,
- moveMsg
, removeFlags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -result1 <- imapconf %>% - selectMailbox(mbox = "TAM") %>% - searchBefore(date_char = "10-may-2012", by = "UID") %$% #exposition pipe - two argg - removeFlags(imapconf = imapconf, msg_id = msg_id, flags_to_set = c("SEEN", "DRAFT")) - -# }-
replace_flags.Rd
Replaces all flags in messages by one or more flags.
- -replace_flags(imapconf, msg_id, by = "MSN", flags_to_set, retries = 2)- -
imapconf | -An object of class |
-
---|---|
msg_id | -A numeric vetor containing one or more messages ids. |
-
by | -Which id ( |
-
flags_to_set | -A character vector containing one ore more flag names to -add to or replace in the specified message ids. |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
An (invisible) list
of length 2
containing the
- imapconf
object and the previously inputed message ids
- (parameter msg_id
).
add_flags, remove_flags and replace_flags, accepts
- not only flags but also keywords (such as $Phishing
on Gmail's
- IMAP server) to add, remove or replace.
IMAP servers do not allow setting the negative version of a flag when a
- message already has the positive version of it. If a message with
- MSN 1
already has the "SEEN" flag, it is not allowed to add "UNSEEN"
- to that. Instead, you have to first remove the "SEEN" flag
- remove_flags(imapconf, msg_id = 1, "SEEN")
and only then do
- add_flags(imapconf, msg_id = 1, "SEEN")
. Another option is to
- complete override all the flags of a message or a set of messages using
- replace_flags(imapconf, msg_id = 1, "SEEN")
.
Other miscellaneous: add_flags
,
- copy_msg
, count_msgs
,
- delete_msg
, expunge
,
- get_max_id
, get_min_id
,
- move_msg
, remove_flags
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -result1 <- imapconf %>% - select_mailbox(mbox = "TAM") %>% - search_before(date_char = "10-may-2012", by = "UID") %$% #exposition pipe - two argg - replace_flags(imapconf = imapconf, msg_id = msg_id, flags_to_set = c("SEEN", "DRAFT")) - -# }-
rfc2047_header_decode.Rd
Decode RFC 2047 quoted-printable and base64 headers or strings
- -rfc2047_header_decode(header)- -
header | -A |
-
---|
A decoded character
vector if applicable.
-# Simple quoted-printable string - Portuguese example -qp_encoded <- "Minist=E9rio_da_Educa=E7=E3o" -decoded_string <- rfc2047_header_decode(header = qp_encoded) - -# Simple quoted-printable string - French example -qp_encoded <- "Minist=E9rio_da_Educa=E7=E3o" -decoded_string <- rfc2047_header_decode(header = qp_encoded) - -# RFC 2047 quoted-printable header - Portuguese example -qp_encoded <- "=?iso-8859-1?Q?DIDEC_Capacita=E7=E3o?=" -decoded_string <- rfc2047_header_decode(header = qp_encoded) - -# RFC 2047 quoted-printable - German example -qp_encoded <- "=?UTF-8?Q?stern=2Ede_-_t=C3=A4glich?=" -decoded_string <- rfc2047_header_decode(header = qp_encoded) - -# RFC 2047 base64 - Portuguese example -b64_encoded <- "=?utf-8?B?Sk9BTkEgRlVTQ08gTE9CTyBubyBUZWFtcw==?=" -decoded_string <- rfc2047_header_decode(header = b64_encoded)
searchBefore.Rd
Functions that allows searching for messages using the (internal) - date criteria, such as before, since, on, and period.
- -searchBefore(imapconf, date_char, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
searchBefore, searchSince, searchOn, and - searchPeriod use internal date, - which reflects the moment when the message was received. - searchSentBefore, searchSentSince, searchSentOn, and - searchSentPeriod use RFC-2822 date header (origination date), which - "specifies the date and time at which the creator of the message - indicated that the message was complete and ready to enter the mail - delivery system" (Resnick, 2008). Dates in both methods must be the same - most of time. Nonetheless, using internal date for search is faster - (Babcock, 2016).
- -Resnick, P., Ed., "Internet Message Format", RFC 5322, - doi: 10.17487/RFC5322 -, October 2008, https://www.rfc-editor.org/info/rfc5322.
-Babcock, N., "Introduction to IMAP", Blog, May 2016, - https://nbsoftsolutions.com/blog/introduction-to-imap.
- -Other Date-search operations: customSearch
,
- searchOn
, searchPeriod
,
- searchSentBefore
,
- searchSentOn
,
- searchSentPeriod
,
- searchSentSince
, searchSince
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search 1 -result1 <- imapconf %>% - selectMailbox(mbox = "[Gmail]/Sent") %>% - searchBefore(date_char = "17-Apr-2012") - -# search 2 (brazilian portuguese example -- mailboxes with compound names) -result2 <- imapconf %>% - selectMailbox(mbox = "[Gmail]/Com estrela") %>% - searchBefore(date_char = "17-Dec-2018", flag = "ANSWERED") -# depending on results, it might be necessary increase buffersize in configureIMAP() - -# }-
searchFlag.Rd
Searches for messages marked with a specific flag.
- -searchFlag(imapconf, flag, negate = FALSE, by = "MSN", - esearch = FALSE, return_imapconf = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
flag | -A string specifying the flag to be used for filtering messages. -Use flag_options to list the common flags used by IMAP -servers. |
-
negate | -If |
-
by | -Which id ( |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Other Flag-search operations: customSearch
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - searchFlag(flag = "RECENT", by = "UID") - -# }-
searchLargerThan.Rd
Searches for messages by bytes size.
- -searchLargerThan(imapconf, size, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
size | -An integer specifying the size (in number of characters) of -message to be used as search criterion. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Other Size-search operations: customSearch
,
- searchSmallerThan
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - searchLargerThan(size = 512000, flag = "UNSEEN") # larger than 512KB - -# }-
searchOlderThan.Rd
Searches for messages within a number of seconds from the - server’s current time to fetch messages.
- -searchOlderThan(imapconf, seconds, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
seconds | -An integer specifying the number of seconds to be used as -search criterion. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Other Within-search operations: customSearch
,
- searchYoungerThan
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url=""imaps://export.imap.aol.com"", - username="your_AOL_user", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - selectMailbox(mbox = "Smiles GOL") %>% - searchOlderThan(seconds = 3600) - -# } --
searchOn.Rd
Functions that allows searching for messages using the (internal) - date criteria, such as before, since, on, and period.
- -searchOn(imapconf, date_char, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Resnick, P., Ed., "Internet Message Format", RFC 5322, - doi: 10.17487/RFC5322 -, October 2008, https://www.rfc-editor.org/info/rfc5322.
-Babcock, N., "Introduction to IMAP", Blog, May 2016, - https://nbsoftsolutions.com/blog/introduction-to-imap.
- -Other Date-search operations: customSearch
,
- searchBefore
, searchPeriod
,
- searchSentBefore
,
- searchSentOn
,
- searchSentPeriod
,
- searchSentSince
, searchSince
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# list mailboxes -results <- imapconf %>% - listMailboxes() - -# search 1 -result1 <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - searchOn(date_char = "17-Dec-2003") - -# search 2 (mailboxes with compound names) -result2 <- imapconf %>% - selectMailbox(mbox = "Special Mailbox") %>% - searchOn(date_char = "17-Sep-2018", flag = "UNDELETED") -# depending on results, it might be necessary increase buffersize in configureIMAP() - -# }-
searchPeriod.Rd
Functions that allows searching for messages using the (internal) - date criteria, such as before, since, on, and period.
- -searchPeriod(imapconf, since_date_char, before_date_char, negate = FALSE, - by = "MSN", flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
since_date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019" indicating the start date (inclusive). We opted not to -use objects of type "date", since IMAP servers like this not so common date -format. |
-
before_date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019" indicating the stop date (exclusive). We opted not to -use objects of type "date", since IMAP server likes this not so common date -format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
searchBefore, searchSince, linksearchOn, and - searchPeriod use internal date, - which reflects the moment when the message was received. - searchSentBefore, searchSentSince, linksearchSentOn, and - searchSentPeriod use RFC-2822 date header (origination date), which - "specifies the date and time at which the creator of the message - indicated that the message was complete and ready to enter the mail - delivery system" (Resnick, 2008). Dates in both methods must be the same - most of time. Nonetheless, using internal date for search is faster - (Babcock, 2016).
- -Resnick, P., "Internet Message Format", RFC 5322, October 2008.
-Babcock, N., "Introduction to IMAP", Blog, May 2016.
- -Other Date-search operations: customSearch
,
- searchBefore
, searchOn
,
- searchSentBefore
,
- searchSentOn
,
- searchSentPeriod
,
- searchSentSince
, searchSince
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - - -# search -results <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - searchPeriod(since_date_char = "17-Apr-2012", - before_date_char = "30-Jun-2015", - flag = "DRAFT") - - -# }-
searchSentBefore.Rd
Functions that allows searching for messages using the - (RC-2822 Header) date criteria, such as before, since, on, and period.
- -searchSentBefore(imapconf, date_char, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
searchBefore, searchSince, linksearchOn, and - searchPeriod use internal date, - which reflects the moment when the message was received. - searchSentBefore, searchSentSince, linksearchSentOn, and - searchSentPeriod use RFC-2822 date header (origination date), which - "specifies the date and time at which the creator of the message - indicated that the message was complete and ready to enter the mail - delivery system" (Resnick, 2008). Dates in both methods must be the same - most of time. Nonetheless, using internal date for search is faster - (Babcock, 2016).
- -Resnick, P., "Internet Message Format", RFC 5322, October 2008.
-Babcock, N., "Introduction to IMAP", Blog, May 2016.
- -Other Date-search operations: customSearch
,
- searchBefore
, searchOn
,
- searchPeriod
, searchSentOn
,
- searchSentPeriod
,
- searchSentSince
, searchSince
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - searchSentBefore(date_char = "17-Apr-2012", - negate = TRUE, - flag = "UNANSWERED") - -# }-
searchSentOn.Rd
Functions that allows searching for messages using the - (RC-2822 Header) date criteria, such as before, since, on, and period.
- -searchSentOn(imapconf, date_char, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Resnick, P., "Internet Message Format", RFC 5322, October 2008.
-Babcock, N., "Introduction to IMAP", Blog, May 2016.
- -Other Date-search operations: customSearch
,
- searchBefore
, searchOn
,
- searchPeriod
,
- searchSentBefore
,
- searchSentPeriod
,
- searchSentSince
, searchSince
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search 1 -result1 <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - searchSentOn(date_char = "17-Dec-2003") - -# search 2 (mailboxes with compound names) -result2 <- imapconf %>% - selectMailbox(mbox = "Special Mailbox") %>% - searchSentOn(date_char = "17-Sep-2018", flag = "UNDELETED") - -# }-
searchSentPeriod.Rd
Functions that allows searching for messages using the - (RC-2822 Header) date criteria, such as before, since, on, and period.
- -searchSentPeriod(imapconf, since_date_char, before_date_char, - negate = FALSE, by = "MSN", flag = NULL, esearch = FALSE, - return_imapconf = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
since_date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019" indicating the start date (inclusive). We opted not to -use objects of type "date", since IMAP servers like this not so common date -format. |
-
before_date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019" indicating the stop date (exclusive). We opted not to -use objects of type "date", since IMAP server likes this not so common date -format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
searchBefore, searchSince, linksearchOn, and - searchPeriod use internal date, - which reflects the moment when the message was received. - searchSentBefore, searchSentSince, linksearchSentOn, and - searchSentPeriod use RFC-2822 date header (origination date), which - "specifies the date and time at which the creator of the message - indicated that the message was complete and ready to enter the mail - delivery system" (Resnick, 2008). Dates in both methods must be the same - most of time. Nonetheless, using internal date for search is faster - (Babcock, 2016).
- -Resnick, P., "Internet Message Format", RFC 5322, October 2008.
-Babcock, N., "Introduction to IMAP", Blog, May 2016.
- -Other Date-search operations: customSearch
,
- searchBefore
, searchOn
,
- searchPeriod
,
- searchSentBefore
,
- searchSentOn
,
- searchSentSince
, searchSince
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - searchPeriod(since_date_char = "17-Apr-2012", - before_date_char = "30-Jun-2015", - flag = "UNFLAGGED") - -# }-
searchSentSince.Rd
Functions that allows searching for messages using the - (RC-2822 Header) date criteria, such as before, since, on, and period.
- -searchSentSince(imapconf, date_char, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Resnick, P., "Internet Message Format", RFC 5322, October 2008.
-Babcock, N., "Introduction to IMAP", Blog, May 2016.
- -Other Date-search operations: customSearch
,
- searchBefore
, searchOn
,
- searchPeriod
,
- searchSentBefore
,
- searchSentOn
,
- searchSentPeriod
, searchSince
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="url="imaps://export.imap.aol.com"", - username="your_AOL_user", - password=rstudioapi::askForPassword() - ) - -# search 1 -result1 <- imapconf %>% - selectMailbox(mbox = "Sent") %>% - searchSentSince(date_char = "17-Apr-2012") - -# search 2 -result2 <- imapconf %>% - selectMailbox(mbox = "Inbox") %>% - searchSentSince(date_char = "17-Jun-2019", flag = "FLAGGED") - -# } --
searchSince.Rd
Functions that allows searching for messages using the (internal) - date criteria, such as before, since, on, and period.
- -searchSince(imapconf, date_char, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Resnick, P., Ed., "Internet Message Format", RFC 5322, - doi: 10.17487/RFC5322 -, October 2008, https://www.rfc-editor.org/info/rfc5322.
-Babcock, N., "Introduction to IMAP", Blog, May 2016, - https://nbsoftsolutions.com/blog/introduction-to-imap.
- -Other Date-search operations: customSearch
,
- searchBefore
, searchOn
,
- searchPeriod
,
- searchSentBefore
,
- searchSentOn
,
- searchSentPeriod
,
- searchSentSince
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="url="imaps://export.imap.aol.com"", - username="your_AOL_user", - password=rstudioapi::askForPassword() - ) - -# search 1 -result1 <- imapconf %>% - selectMailbox(mbox = "Sent") %>% - searchSince(date_char = "17-Apr-2012") - -# search 2 -result2 <- imapconf %>% - selectMailbox(mbox = "Inbox") %>% - searchSince(date_char = "17-Jun-2019", flag = "FLAGGED") -# depending on results, it might be necessary increase buffersize in configureIMAP() - -# } --
searchSmallerThan.Rd
Searches for messages by bytes size.
- -searchSmallerThan(imapconf, size, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
size | -An integer specifying the size (in number of characters) of -message to be used as search criterion. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Other Size-search operations: customSearch
,
- searchLargerThan
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - searchSmallerThan(size = 512000) # smaller than 512KB - -# }-
searchString.Rd
Searches for messages containing a string in an specific - section or field.
- -searchString(imapconf, section_or_field, string, negate = FALSE, - by = "MSN", esearch = FALSE, return_imapconf = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
section_or_field | -A mandatory character string specifying in which -message's Section or Header Field to search for the provided string. -For some available options, see section_or_field_options. |
-
string | -A character string specifying the word or expression to -search for in messages. |
-
negate | -If |
-
by | -Which id ( |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - selectMailbox(mbox = "TAM") %>% - searchString(section_or_field = "FROM", string = "michelle@hotmail.com", - negate = TRUE) # not FROM "michele" - -# }-
searchYoungerThan.Rd
Searches for messages within a number of seconds from the - server’s current time to fetch messages.
- -searchYoungerThan(imapconf, seconds, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
seconds | -An integer specifying the number of seconds to be used as -search criterion. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Some SMTP servers, such as Gmail and AOL, may not support WITHIN SEARCH - EXTENSION.
- -Other Within-search operations: customSearch
,
- searchOlderThan
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url=""imaps://export.imap.aol.com"", - username="your_AOL_user", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - selectMailbox(mbox = "Smiles GOL") %>% - searchYoungerThan(seconds = 3600) - -# } --
search_before.Rd
Functions that allows searching for messages using the (internal) - date criteria, such as before, since, on, and period.
- -search_before(imapconf, date_char, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
search_before, search_since, search_on, and - search_period use internal date, - which reflects the moment when the message was received. - search_sent_before, search_sent_since, search_sent_on, and - search_sent_period use RFC-2822 date header (origination date), which - "specifies the date and time at which the creator of the message - indicated that the message was complete and ready to enter the mail - delivery system" (Resnick, 2008). Dates in both methods must be the same - most of time. Nonetheless, using internal date for search is faster - (Babcock, 2016).
- -Resnick, P., Ed., "Internet Message Format", RFC 5322, - doi: 10.17487/RFC5322 -, October 2008, https://www.rfc-editor.org/info/rfc5322.
-Babcock, N., "Introduction to IMAP", Blog, May 2016, - https://nbsoftsolutions.com/blog/introduction-to-imap.
- -Other Date-search operations: custom_search
,
- search_on
, search_period
,
- search_sent_before
,
- search_sent_on
,
- search_sent_period
,
- search_sent_since
,
- search_since
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# search 1 -result1 <- imapconf %>% - select_mailbox(mbox = "[Gmail]/Sent") %>% - search_before(date_char = "17-Apr-2012") - -# search 2 (brazilian portuguese example -- mailboxes with compound names) -result2 <- imapconf %>% - select_mailbox(mbox = "[Gmail]/Com estrela") %>% - search_before(date_char = "17-Dec-2018", flag = "ANSWERED") -# depending on results, it might be necessary to increase buffersize in -# configure_imap() - -# }-
search_flag.Rd
Searches for messages marked with a specific flag.
- -search_flag(imapconf, flag, negate = FALSE, by = "MSN", - esearch = FALSE, return_imapconf = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
flag | -A string specifying the flag to be used for filtering messages. -Use flag_options to list the common flags used by IMAP -servers. |
-
negate | -If |
-
by | -Which id ( |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Other Flag-search operations: custom_search
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - select_mailbox(mbox = "INBOX") %>% - search_flag(flag = "RECENT", by = "UID") - -# }-
search_larger_than.Rd
Searches for messages by bytes size.
- -search_larger_than(imapconf, size, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
size | -An integer specifying the size (in number of characters) of -message to be used as search criterion. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Other Size-search operations: custom_search
,
- search_smaller_than
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - select_mailbox(mbox = "INBOX") %>% - search_larger_than(size = 512000, flag = "UNSEEN") # larger than 512KB - -# }-
search_older_than.Rd
Searches for messages within a number of seconds from the - server’s current time to fetch messages.
- -search_older_than(imapconf, seconds, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
seconds | -An integer specifying the number of seconds to be used as -search criterion. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Other Within-search operations: custom_search
,
- search_younger_than
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - select_mailbox(mbox = "Smiles GOL") %>% - search_older_than(seconds = 3600) - -# }-
search_on.Rd
Functions that allows searching for messages using the (internal) - date criteria, such as before, since, on, and period.
- -search_on(imapconf, date_char, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Resnick, P., Ed., "Internet Message Format", RFC 5322, - doi: 10.17487/RFC5322 -, October 2008, https://www.rfc-editor.org/info/rfc5322.
-Babcock, N., "Introduction to IMAP", Blog, May 2016, - https://nbsoftsolutions.com/blog/introduction-to-imap.
- -Other Date-search operations: custom_search
,
- search_before
, search_period
,
- search_sent_before
,
- search_sent_on
,
- search_sent_period
,
- search_sent_since
,
- search_since
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# list mailboxes -results <- imapconf %>% - list_mailboxes() - -# search 1 -result1 <- imapconf %>% - select_mailbox(mbox = "INBOX") %>% - search_on(date_char = "17-Dec-2003") - -# search 2 (mailboxes with compound names) -result2 <- imapconf %>% - select_mailbox(mbox = "Special Mailbox") %>% - search_on(date_char = "17-Sep-2018", flag = "UNDELETED") -# depending on results, it might be necessary to increase buffersize in -# configure_imap() - -# }-
search_period.Rd
Functions that allows searching for messages using the (internal) - date criteria, such as before, since, on, and period.
- -search_period(imapconf, since_date_char, before_date_char, - negate = FALSE, by = "MSN", flag = NULL, esearch = FALSE, - return_imapconf = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
since_date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019" indicating the start date (inclusive). We opted not to -use objects of type "date", since IMAP servers like this not so common date -format. |
-
before_date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019" indicating the stop date (exclusive). We opted not to -use objects of type "date", since IMAP server likes this not so common date -format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
search_before, search_since, search_on, and - search_period use internal date, - which reflects the moment when the message was received. - search_sent_before, search_sent_since, search_sent_on, and - search_sent_period use RFC-2822 date header (origination date), which - "specifies the date and time at which the creator of the message - indicated that the message was complete and ready to enter the mail - delivery system" (Resnick, 2008). Dates in both methods must be the same - most of time. Nonetheless, using internal date for search is faster - (Babcock, 2016).
- -Resnick, P., "Internet Message Format", RFC 5322, October 2008.
-Babcock, N., "Introduction to IMAP", Blog, May 2016.
- -Other Date-search operations: custom_search
,
- search_before
, search_on
,
- search_sent_before
,
- search_sent_on
,
- search_sent_period
,
- search_sent_since
,
- search_since
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - - -# search -results <- imapconf %>% - select_mailbox(mbox = "INBOX") %>% - search_period(since_date_char = "17-Apr-2012", - before_date_char = "30-Jun-2015", - flag = "DRAFT") - - -# }-
search_sent_before.Rd
Functions that allows searching for messages using the - (RC-2822 Header) date criteria, such as before, since, on, and period.
- -search_sent_before(imapconf, date_char, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
search_before, search_since, search_on, and - search_period use internal date, - which reflects the moment when the message was received. - search_sent_before, search_sent_since, search_sent_on, and - search_sent_period use RFC-2822 date header (origination date), which - "specifies the date and time at which the creator of the message - indicated that the message was complete and ready to enter the mail - delivery system" (Resnick, 2008). Dates in both methods must be the same - most of time. Nonetheless, using internal date for search is faster - (Babcock, 2016).
- -Resnick, P., "Internet Message Format", RFC 5322, October 2008.
-Babcock, N., "Introduction to IMAP", Blog, May 2016.
- -Other Date-search operations: custom_search
,
- search_before
, search_on
,
- search_period
,
- search_sent_on
,
- search_sent_period
,
- search_sent_since
,
- search_since
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - select_mailbox(mbox = "INBOX") %>% - search_sent_before(date_char = "17-Apr-2012", - negate = TRUE, - flag = "UNANSWERED") - -# }-
search_sent_on.Rd
Functions that allows searching for messages using the - (RC-2822 Header) date criteria, such as before, since, on, and period.
- -search_sent_on(imapconf, date_char, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Resnick, P., "Internet Message Format", RFC 5322, October 2008.
-Babcock, N., "Introduction to IMAP", Blog, May 2016.
- -Other Date-search operations: custom_search
,
- search_before
, search_on
,
- search_period
,
- search_sent_before
,
- search_sent_period
,
- search_sent_since
,
- search_since
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# search 1 -result1 <- imapconf %>% - select_mailbox(mbox = "INBOX") %>% - search_sent_on(date_char = "17-Dec-2003") - -# search 2 (mailboxes with compound names) -result2 <- imapconf %>% - select_mailbox(mbox = "Special Mailbox") %>% - search_sent_on(date_char = "17-Sep-2018", flag = "UNDELETED") - -# }-
search_sent_period.Rd
Functions that allows searching for messages using the - (RC-2822 Header) date criteria, such as before, since, on, and period.
- -search_sent_period(imapconf, since_date_char, before_date_char, - negate = FALSE, by = "MSN", flag = NULL, esearch = FALSE, - return_imapconf = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
since_date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019" indicating the start date (inclusive). We opted not to -use objects of type "date", since IMAP servers like this not so common date -format. |
-
before_date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019" indicating the stop date (exclusive). We opted not to -use objects of type "date", since IMAP server likes this not so common date -format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
search_before, search_since, search_on, and - search_period use internal date, - which reflects the moment when the message was received. - search_sent_before, search_sent_since, search_sent_on, and - search_sent_period use RFC-2822 date header (origination date), which - "specifies the date and time at which the creator of the message - indicated that the message was complete and ready to enter the mail - delivery system" (Resnick, 2008). Dates in both methods must be the same - most of time. Nonetheless, using internal date for search is faster - (Babcock, 2016).
- -Resnick, P., "Internet Message Format", RFC 5322, October 2008.
-Babcock, N., "Introduction to IMAP", Blog, May 2016.
- -Other Date-search operations: custom_search
,
- search_before
, search_on
,
- search_period
,
- search_sent_before
,
- search_sent_on
,
- search_sent_since
,
- search_since
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - select_mailbox(mbox = "INBOX") %>% - search_sent_period(since_date_char = "17-Apr-2012", - before_date_char = "30-Jun-2015", - flag = "UNFLAGGED") - -# }-
search_sent_since.Rd
Functions that allows searching for messages using the - (RC-2822 Header) date criteria, such as before, since, on, and period.
- -search_sent_since(imapconf, date_char, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Resnick, P., "Internet Message Format", RFC 5322, October 2008.
-Babcock, N., "Introduction to IMAP", Blog, May 2016.
- -Other Date-search operations: custom_search
,
- search_before
, search_on
,
- search_period
,
- search_sent_before
,
- search_sent_on
,
- search_sent_period
,
- search_since
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# search 1 -result1 <- imapconf %>% - select_mailbox(mbox = "Sent") %>% - search_sent_since(date_char = "17-Apr-2012") - -# search 2 -result2 <- imapconf %>% - select_mailbox(mbox = "Inbox") %>% - search_sent_since(date_char = "17-Jun-2019", flag = "FLAGGED") - -# }-
search_since.Rd
Functions that allows searching for messages using the (internal) - date criteria, such as before, since, on, and period.
- -search_since(imapconf, date_char, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Resnick, P., Ed., "Internet Message Format", RFC 5322, - doi: 10.17487/RFC5322 -, October 2008, https://www.rfc-editor.org/info/rfc5322.
-Babcock, N., "Introduction to IMAP", Blog, May 2016, - https://nbsoftsolutions.com/blog/introduction-to-imap.
- -Other Date-search operations: custom_search
,
- search_before
, search_on
,
- search_period
,
- search_sent_before
,
- search_sent_on
,
- search_sent_period
,
- search_sent_since
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# search 1 -result1 <- imapconf %>% - select_mailbox(mbox = "Sent") %>% - search_since(date_char = "17-Apr-2012") - -# search 2 -result2 <- imapconf %>% - select_mailbox(mbox = "Inbox") %>% - search_since(date_char = "17-Jun-2019", flag = "FLAGGED") -# depending on results, it might be necessary to increase buffersize in -# configure_imap() - -# }-
search_smaller_than.Rd
Searches for messages by bytes size.
- -search_smaller_than(imapconf, size, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
size | -An integer specifying the size (in number of characters) of -message to be used as search criterion. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Other Size-search operations: custom_search
,
- search_larger_than
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - select_mailbox(mbox = "INBOX") %>% - search_smaller_than(size = 512000) # smaller than 512KB - -# }-
search_string.Rd
Searches for messages containing a string in an specific - section or field.
- -search_string(imapconf, section_or_field, string, negate = FALSE, - by = "MSN", esearch = FALSE, return_imapconf = TRUE, retries = 2)- -
imapconf | -An object of class |
-
---|---|
section_or_field | -A mandatory character string specifying in which -message's Section or Header Field to search for the provided string. -For some available options, see section_or_field_options. |
-
string | -A character string specifying the word or expression to -search for in messages. |
-
negate | -If |
-
by | -Which id ( |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - select_mailbox(mbox = "TAM") %>% - search_string(section_or_field = "FROM", - string = "michelle@hotmail.com", - negate = TRUE - ) # not FROM "michele" - -# }-
search_younger_than.Rd
Searches for messages within a number of seconds from the - server’s current time to fetch messages.
- -search_younger_than(imapconf, seconds, negate = FALSE, by = "MSN", - flag = NULL, esearch = FALSE, return_imapconf = TRUE, - retries = 2)- -
imapconf | -An object of class |
-
---|---|
seconds | -An integer specifying the number of seconds to be used as -search criterion. |
-
negate | -If |
-
by | -Which id ( |
-
flag | -Optional parameter that adds a flag filter to the search. Use
-flag_options to list the common flags used by IMAP servers.
-Default is |
-
esearch | -A logical. Default is |
-
return_imapconf | -A logical. If |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
Depending on the return_imapconf
parameter, it can be a
- list
of length 2
containing the imapconf
object
- and message ids resulted from search, or a numeric vector containing
- only message ids.
Some SMTP servers, such as Gmail and AOL, may not support WITHIN SEARCH - EXTENSION.
- -Other Within-search operations: custom_search
,
- search_older_than
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configure_imap(url="imaps://your.imap.server.com", - username="your_username", - password=rstudioapi::askForPassword() - ) - -# search -results <- imapconf %>% - select_mailbox(mbox = "Smiles GOL") %>% - search_younger_than(seconds = 3600) - -# }-
section_or_field_options.Rd
This function presents message sections and header fields - that can be used for searching and fetching message contents. The header - fields, particularly, are only a suggestion and indicate the most common - terms. Some messages may not contain one or more of the listed fields. - It is also possible that one or more fields not listed here may be used - in some messages.
- -section_or_field_options()
-
- A list
containing common header fields.
A message body is the (full) content of a message. It is simply lines
- of US-ASCII characters (Freed & Borenstein, 1996; Resnick, 2001). Therefore,
- if you want to do a search of a string in the whole message, including
- HEADER
and TEXT
, you can specify
- section_or_field = "BODY"
.
While header is a part of the message body, indicating sender, date and - other information, header fields are specific - parts of the header of a message. "Header fields are lines - composed of a field name, followed by a colon (":"), which is followed by - a field body, and terminated by CRLF" (Resnick, 2001).
-A message TEXT
is the message itself, indicating the content
- written or produced by the sender.
Freed, N. and N. Borenstein, "Multipurpose Internet Mail - Extensions (MIME) Part Two: Media Types", RFC 2046, - doi: 10.17487/RFC2046 -, November 1996, - https://www.rfc-editor.org/info/rfc2046.
-Resnick, P., Ed., "Internet Message Format", RFC 2822, - doi: 10.17487/RFC2822 -, April 2001, - https://www.rfc-editor.org/info/rfc2822.
-Crocker, D., "STANDARD FOR THE FORMAT OF ARPA INTERNET TEXT - MESSAGES", STD 11, RFC 822, doi: 10.17487/RFC0822 -, - August 1982, https://www.rfc-editor.org/info/rfc822.
- -Other options:
-metadata_options()
# NOT RUN { -library(mRpostman) -section_or_field_options() - -# }-
selectMailbox.Rd
Select a mailbox on the server for issuing further commands.
- -selectMailbox(imapconf, mbox, retries = 2)- -
imapconf | -A object of class |
-
---|---|
mbox | -A string containing the name of an existing mailbox on the server. |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
The imaconf, list
object with the selected mailbox added to it.
Other mailbox commands: examineMailbox
,
- listMailboxes
,
- listServerCapabilities
,
- renameMailbox
# NOT RUN { -# configure IMAP -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# Select INBOX -imapconf %>% - selectMailbox(mbox = "INBOX") - -# }-
select_mailbox.Rd
Select a mailbox on the server for issuing further commands.
- -select_mailbox(imapconf, mbox, retries = 2)- -
imapconf | -A object of class |
-
---|---|
mbox | -A string containing the name of an existing mailbox on the server. |
-
retries | -Number of attempts to connect and execute the command. Default
-is |
-
The (invisible) imaconf
object with the selected mailbox added to it.
Other mailbox commands: examine_mailbox
,
- list_mailboxes
,
- list_server_capabilities
,
- rename_mailbox
# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# Select INBOX -imapconf %>% - select_mailbox(mbox = "INBOX") - -# }-
sentBefore.Rd
Criteria helper functions to be combined inside a operator helper - function as a custom request in customSearch.
- -sentBefore(date_char, negate = FALSE)- -
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
---|---|
negate | -If |
-
A search string to be used as a custom_request
parameter in
- customSearch function.
Other customsearch helper functions: AND
,
- Before
, Flag
,
- OR
, Since
,
- String
, olderThan
,
- sentOn
, sentSince
,
- smallerThan
, youngerThan
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -result <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - customSearch(custom_request = OR(sentBefore(date_char = "17-Apr-2019"), - smallerThan(size = 512000))) -# searches for messages sentBefore "17-Apr-2019" OR smallerThan 512KB. - -# }-
sentOn.Rd
Criteria helper functions to be combined inside a operator helper - function as a custom request in customSearch.
- -sentOn(date_char, negate = FALSE)- -
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
---|---|
negate | -If |
-
A search string to be used as a custom_request
parameter in
- customSearch function.
Other customsearch helper functions: AND
,
- Before
, Flag
,
- OR
, Since
,
- String
, olderThan
,
- sentBefore
, sentSince
,
- smallerThan
, youngerThan
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -result <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - customSearch(custom_request = OR(sentOn(date_char = "17-Apr-2019"), - sentOn(date_char = "17-Jul-2018"))) -# searches for messages sentOn "17-Apr-2019" OR sentOn "17-Jul-2018". - -# }-
sentSince.Rd
Criteria helper functions to be combined inside a operator helper - function as a custom request in customSearch.
- -sentSince(date_char, negate = FALSE)- -
date_char | -A character vector with format "DD-Mon-YYYY", -e.g. "01-Apr-2019". We opted not to use objects of type "date", since IMAP -servers like this not so common date format. |
-
---|---|
negate | -If |
-
A search string to be used as a custom_request
parameter in
- customSearch function.
Other customsearch helper functions: AND
,
- Before
, Flag
,
- OR
, Since
,
- String
, olderThan
,
- sentBefore
, sentOn
,
- smallerThan
, youngerThan
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -result <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - customSearch(custom_request = OR(sentSince(date_char = "17-Apr-2019"), - smallerThan(size = 512000))) -# searches for messages sentSince "17-Apr-2019" OR smallerThan 512KB. - -# }-
smallerThan.Rd
Criteria helper functions to be combined inside a operator helper - function as a custom request in customSearch.
- -smallerThan(size, negate = FALSE)- -
size | -An integer specifying the size (in number characters) of message to be used as search -criterion. |
-
---|---|
negate | -If |
-
A search string to be used as a custom_request
parameter in
- customSearch function.
Other customsearch helper functions: AND
,
- Before
, Flag
,
- OR
, Since
,
- String
, olderThan
,
- sentBefore
, sentOn
,
- sentSince
, youngerThan
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -result <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - customSearch(custom_request = - OR(String( - section_or_field = "from", string = "allanvcq@gmail.com"), - smallerThan( - size = 512000) - ) - ) -# searches for messages containing the string "allanvcq@gmail.com" in the field "FROM" - OR those smallerThan 512KB. - -# } --
youngerThan.Rd
Criteria helper functions to be combined inside a operator helper - function as a custom request in customSearch.
- -youngerThan(seconds, negate = FALSE)- -
seconds | -An integer specifying the number of seconds to be used as -search criterion. |
-
---|---|
negate | -If |
-
A search string to be used as a custom_request
parameter in
- customSearch function.
Other customsearch helper functions: AND
,
- Before
, Flag
,
- OR
, Since
,
- String
, olderThan
,
- sentBefore
, sentOn
,
- sentSince
, smallerThan
--# NOT RUN { -# configure IMAP -library(mRpostman) -imapconf <- configureIMAP(url="imaps://imap.gmail.com", - username="your_gmail_user", - password=rstudioapi::askForPassword() - ) - -# search -result <- imapconf %>% - selectMailbox(mbox = "INBOX") %>% - customSearch(custom_request = - OR(smallerThan( - size = 512000), - youngerThan( - seconds = 3600) - ) - ) -# searches for messages that are youngerThan 3600 seconds (or one hour) OR - that contains the string "allanvcq@gmail.com" in the field "FROM" - -# } --