callback::acs_mail_lite::email_inbound::impl::acs-mail-lite (private)
callback::acs_mail_lite::email_inbound::impl::acs-mail-lite \ -headers_array_name headers_array_name \ -parts_array_name parts_array_name [ -package_id package_id ] \ [ -object_id object_id ] [ -party_id party_id ] [ -other other ] \ [ -datetime_cs datetime_cs ]
Defined in packages/acs-mail-lite/tcl/acs-mail-lite-callback-procs.tcl
Example Implementation of acs_mail_lite::email_inbound. This is where documentation for callback goes.
- Switches:
- -headers_array_name (required)
- An array with all email headers.
- -parts_array_name (required)
- An array with info on files and bodies.
- -package_id (optional)
- The package_id of package that sent the original email.
- -object_id (optional)
- -party_id (optional)
- -other (optional)
- -datetime_cs (optional)
- Not all inbound email are expected to be replies.
- Created:
- 2017-10-17
- See Also:
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- No testcase defined.
Source code: ::callback::acs_mail_lite::email_inbound::contract__arg_parser {*}$args upvar $headers_array_name headers_arr upvar $parts_array_name parts_arr set no_errors_p 1 # ------------------- Do Not change code above this line in your copy --- # Use this callback implementation as a template for other packages. # Be sure to change 'impl acs-mail-lite' to a reference relevant to # package implementation is used in. # For example: -impl super-package-now-with-email # # This proc is called whenever an inbound email is pulled from the queue. # # System-wide bounces, vacation notices and other noise have already been # filtered out. # # A package developer should just need to confirm input for their specific # package. # # When supplied, package_id, object_id and party_id, other and datetime_cs # are passed in headers via a signed unique_id. # Values default to empty string. # headers_arr is an array of header values indexed by header name. # header names are in original uppercase and lowercase, which may # have some significance in filtering cases. Although case should # should not be relied on for obtaining a value. # Some header indexes are created by ACS Mail Lite procs during # processing. For example these indexes may be populated via # a unique id header created using acs_mail_lite::unique_id_create : # # aml_package_id contains package_id # # aml_object_id contains object_id # # aml_party_id contains party_id (usually same as user_id) # # aml_other contains other data useful as input # # aml_datetime_cs contains approx time in seconds since epoch when sent. # # # Other header names, and a description of their values, includes: # # aml_received_cs approx time in seconds since epoch when email received. # aml_subject contains subject value. # aml_to contents of 'to' header # aml_to_addrs email address of 'to' header # aml_from contents of 'from' header # aml_from_addrs email address of 'from' header # For other created headers, see: acs_mail_lite::inbound_queue_pull_one # Header indexes may not exist for all cases. # # parts_arr is an array that contains all the information about attached # or inline files and body contents. # For details, see acs_mail_lite::inbound_queue_pull_one # ns_log Debug "acs_mail_lite::email_inbound -impl acs-mail-lite called. Sender $headers_arr(aml_from_addrs)" # Important: If your implementation has an error, # set no_errors_p to 0, so that the email remains # in the queue for later examination, even though it is also # marked as 'processed' so it will not be re-processed later. # # ------------------- Do Not change code below this line in your copy --- return $no_errors_pXQL Not present: PostgreSQL, Oracle Generic XQL file: packages/acs-mail-lite/tcl/acs-mail-lite-callback-procs.xql