EmailClient¶
-
class
oci.email.
EmailClient
(config, **kwargs)¶ Use the Email Delivery API to do the necessary set up to send high-volume and application-generated emails through the OCI Email Delivery service. For more information, see [Overview of the Email Delivery Service](/iaas/Content/Email/Concepts/overview.htm).
Note: Write actions (POST, UPDATE, DELETE) may take several minutes to propagate and be reflected by the API. If a subsequent read request fails to reflect your changes, wait a few minutes and try again.Methods
__init__
(config, **kwargs)Creates a new service client change_email_domain_compartment
(…)Moves an email domain into a different compartment. change_sender_compartment
(sender_id, …)Moves a sender into a different compartment. create_dkim
(create_dkim_details, **kwargs)Creates a new DKIM for an email domain. create_email_domain
(…)Creates a new email domain. create_email_return_path
(…)Creates a new email return path. create_sender
(create_sender_details, **kwargs)Creates a sender for a tenancy in a given compartment. create_suppression
(…)Adds recipient email addresses to the suppression list for a tenancy. delete_dkim
(dkim_id, **kwargs)Deletes a DKIM. delete_email_domain
(email_domain_id, **kwargs)Deletes an email domain. delete_email_return_path
(…)Deletes an email return path. delete_sender
(sender_id, **kwargs)Deletes an approved sender for a tenancy in a given compartment for a provided senderId. delete_suppression
(suppression_id, **kwargs)Removes a suppressed recipient email address from the suppression list for a tenancy in a given compartment for a provided suppressionId. get_dkim
(dkim_id, **kwargs)Retrieves the specified DKIM. get_email_configuration
(compartment_id, **kwargs)Returns email configuration associated with the specified compartment. get_email_domain
(email_domain_id, **kwargs)Retrieves the specified email domain. get_email_return_path
(email_return_path_id, …)Retrieves the specified email return path. get_sender
(sender_id, **kwargs)Gets an approved sender for a given senderId. get_suppression
(suppression_id, **kwargs)Gets the details of a suppressed recipient email address for a given suppressionId. get_work_request
(work_request_id, **kwargs)Gets the status of the work request with the given ID. list_dkims
(email_domain_id, **kwargs)Lists DKIMs for an email domain. list_email_domains
(compartment_id, **kwargs)Lists email domains in the specified compartment. list_email_return_paths
(**kwargs)Lists email return paths in the specified compartment or emaildomain. list_senders
(compartment_id, **kwargs)Gets a collection of approved sender email addresses and sender IDs. list_suppressions
(compartment_id, **kwargs)Gets a list of suppressed recipient email addresses for a user. list_work_request_errors
(work_request_id, …)Return a (paginated) list of errors for a given work request. list_work_request_logs
(work_request_id, **kwargs)Return a (paginated) list of logs for a given work request. list_work_requests
(compartment_id, **kwargs)Lists the work requests in a compartment. update_dkim
(dkim_id, update_dkim_details, …)Modifies a DKIM. update_email_domain
(email_domain_id, …)Modifies an email domain. update_email_return_path
(…)Modifies an email return path. update_sender
(sender_id, …)Replaces the set of tags for a sender with the tags provided. -
__init__
(config, **kwargs)¶ Creates a new service client
Parameters: - config (dict) – Configuration keys and values as per SDK and Tool Configuration.
The
from_file()
method can be used to load configuration from a file. Alternatively, adict
can be passed. You can validate_config the dict usingvalidate_config()
- service_endpoint (str) – (optional)
The endpoint of the service to call using this client. For example
https://iaas.us-ashburn-1.oraclecloud.com
. If this keyword argument is not provided then it will be derived using the region in the config parameter. You should only provide this keyword argument if you have an explicit need to specify a service endpoint. - timeout (float or tuple(float, float)) – (optional) The connection and read timeouts for the client. The default values are connection timeout 10 seconds and read timeout 60 seconds. This keyword argument can be provided as a single float, in which case the value provided is used for both the read and connection timeouts, or as a tuple of two floats. If a tuple is provided then the first value is used as the connection timeout and the second value as the read timeout.
- signer (
AbstractBaseSigner
) –(optional) The signer to use when signing requests made by the service client. The default is to use a
Signer
based on the values provided in the config parameter.One use case for this parameter is for Instance Principals authentication by passing an instance of
InstancePrincipalsSecurityTokenSigner
as the value for this keyword argument - retry_strategy (obj) –
(optional) A retry strategy to apply to all calls made by this service client (i.e. at the client level). There is no retry strategy applied by default. Retry strategies can also be applied at the operation level by passing a
retry_strategy
keyword argument as part of calling the operation. Any value provided at the operation level will override whatever is specified at the client level.This should be one of the strategies available in the
retry
module. A convenienceDEFAULT_RETRY_STRATEGY
is also available. The specifics of the default retry strategy are described here. - circuit_breaker_strategy (obj) – (optional)
A circuit breaker strategy to apply to all calls made by this service client (i.e. at the client level).
This client uses
DEFAULT_CIRCUIT_BREAKER_STRATEGY
as default if no circuit breaker strategy is provided. The specifics of circuit breaker strategy are described here. - circuit_breaker_callback (function) – (optional) Callback function to receive any exceptions triggerred by the circuit breaker.
- client_level_realm_specific_endpoint_template_enabled (bool) – (optional) A boolean flag to indicate whether or not this client should be created with realm specific endpoint template enabled or disable. By default, this will be set as None.
- allow_control_chars – (optional) allow_control_chars is a boolean to indicate whether or not this client should allow control characters in the response object. By default, the client will not allow control characters to be in the response object.
- config (dict) – Configuration keys and values as per SDK and Tool Configuration.
The
-
change_email_domain_compartment
(email_domain_id, change_email_domain_compartment_details, **kwargs)¶ Moves an email domain into a different compartment. When provided, If-Match is checked against ETag value of the resource. For information about moving resources between compartments, see Moving Resources to a Different Compartment.
Note: All DKIM objects associated with this email domain will also be moved into the provided compartment.
Parameters: - email_domain_id (str) –
(required) The OCID of this email domain.
- change_email_domain_compartment_details (oci.email.models.ChangeEmailDomainCompartmentDetails) – (required) The configuration details for the move operation.
- if_match (str) – (optional) Used for optimistic concurrency control. In the update or delete call for a resource, set the if-match parameter to the value of the etag from a previous get, create, or update response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource’s current etag value.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- opc_retry_token (str) – (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected.
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of type NoneReturn type: Example: Click here to see an example of how to use change_email_domain_compartment API.
- email_domain_id (str) –
-
change_sender_compartment
(sender_id, change_sender_compartment_details, **kwargs)¶ Moves a sender into a different compartment. When provided, If-Match is checked against ETag values of the resource.
Parameters: - sender_id (str) – (required) The unique OCID of the sender.
- change_sender_compartment_details (oci.email.models.ChangeSenderCompartmentDetails) – (required) Details for moving a sender into a different compartment.
- if_match (str) – (optional) Used for optimistic concurrency control. In the update or delete call for a resource, set the if-match parameter to the value of the etag from a previous get, create, or update response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource’s current etag value.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of type NoneReturn type: Example: Click here to see an example of how to use change_sender_compartment API.
-
create_dkim
(create_dkim_details, **kwargs)¶ Creates a new DKIM for an email domain. This DKIM signs all approved senders in the tenancy that are in this email domain. Best security practices indicate to periodically rotate the DKIM that is doing the signing. When a second DKIM is applied, all senders seamlessly pick up the new key without interruption in signing.
Parameters: - create_dkim_details (oci.email.models.CreateDkimDetails) – (required) The DKIM details.
- opc_retry_token (str) – (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: Return type: Example: Click here to see an example of how to use create_dkim API.
-
create_email_domain
(create_email_domain_details, **kwargs)¶ Creates a new email domain. Avoid entering confidential information.
Parameters: - create_email_domain_details (oci.email.models.CreateEmailDomainDetails) – (required) The email domain to create.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- opc_retry_token (str) – (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected.
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of typeEmailDomain
Return type: Example: Click here to see an example of how to use create_email_domain API.
-
create_email_return_path
(create_email_return_path_details, **kwargs)¶ Creates a new email return path. Avoid entering confidential information.
Parameters: - create_email_return_path_details (oci.email.models.CreateEmailReturnPathDetails) – (required) The email return path to create.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- opc_retry_token (str) – (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected.
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of typeEmailReturnPath
Return type: Example: Click here to see an example of how to use create_email_return_path API.
-
create_sender
(create_sender_details, **kwargs)¶ Creates a sender for a tenancy in a given compartment.
Parameters: - create_sender_details (oci.email.models.CreateSenderDetails) – (required) Create a sender.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: Return type: Example: Click here to see an example of how to use create_sender API.
-
create_suppression
(create_suppression_details, **kwargs)¶ Adds recipient email addresses to the suppression list for a tenancy. Addresses added to the suppression list via the API are denoted as “MANUAL” in the reason field. Note: All email addresses added to the suppression list are normalized to include only lowercase letters.
Parameters: - create_suppression_details (oci.email.models.CreateSuppressionDetails) – (required) Adds a single email address to the suppression list for a compartment’s tenancy.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of typeSuppression
Return type: Example: Click here to see an example of how to use create_suppression API.
-
delete_dkim
(dkim_id, **kwargs)¶ Deletes a DKIM. If this key is currently the active key for the email domain, deleting the key will stop signing the domain’s outgoing mail. DKIM keys are left in DELETING state for about a day to allow DKIM signatures on in-transit mail to be validated. Consider creating a new DKIM for this domain so the signing can be rotated to it instead of deletion.
Parameters: - dkim_id (str) –
(required) The OCID of this DKIM.
- if_match (str) – (optional) Used for optimistic concurrency control. In the update or delete call for a resource, set the if-match parameter to the value of the etag from a previous get, create, or update response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource’s current etag value.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of type NoneReturn type: Example: Click here to see an example of how to use delete_dkim API.
- dkim_id (str) –
-
delete_email_domain
(email_domain_id, **kwargs)¶ Deletes an email domain.
Parameters: - email_domain_id (str) –
(required) The OCID of this email domain.
- if_match (str) – (optional) Used for optimistic concurrency control. In the update or delete call for a resource, set the if-match parameter to the value of the etag from a previous get, create, or update response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource’s current etag value.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of type NoneReturn type: Example: Click here to see an example of how to use delete_email_domain API.
- email_domain_id (str) –
-
delete_email_return_path
(email_return_path_id, **kwargs)¶ Deletes an email return path.
Parameters: - email_return_path_id (str) –
(required) The OCID of this email return path.
- if_match (str) – (optional) Used for optimistic concurrency control. In the update or delete call for a resource, set the if-match parameter to the value of the etag from a previous get, create, or update response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource’s current etag value.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of type NoneReturn type: Example: Click here to see an example of how to use delete_email_return_path API.
- email_return_path_id (str) –
-
delete_sender
(sender_id, **kwargs)¶ Deletes an approved sender for a tenancy in a given compartment for a provided senderId.
Parameters: - sender_id (str) – (required) The unique OCID of the sender.
- if_match (str) – (optional) Used for optimistic concurrency control. In the update or delete call for a resource, set the if-match parameter to the value of the etag from a previous get, create, or update response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource’s current etag value.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of type NoneReturn type: Example: Click here to see an example of how to use delete_sender API.
-
delete_suppression
(suppression_id, **kwargs)¶ Removes a suppressed recipient email address from the suppression list for a tenancy in a given compartment for a provided suppressionId.
Parameters: - suppression_id (str) – (required) The unique OCID of the suppression.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of type NoneReturn type: Example: Click here to see an example of how to use delete_suppression API.
-
get_dkim
(dkim_id, **kwargs)¶ Retrieves the specified DKIM.
Parameters: - dkim_id (str) –
(required) The OCID of this DKIM.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: Return type: Example: Click here to see an example of how to use get_dkim API.
- dkim_id (str) –
-
get_email_configuration
(compartment_id, **kwargs)¶ Returns email configuration associated with the specified compartment.
Parameters: - compartment_id (str) – (required) The OCID for the compartment.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of typeConfiguration
Return type: Example: Click here to see an example of how to use get_email_configuration API.
-
get_email_domain
(email_domain_id, **kwargs)¶ Retrieves the specified email domain.
Parameters: - email_domain_id (str) –
(required) The OCID of this email domain.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of typeEmailDomain
Return type: Example: Click here to see an example of how to use get_email_domain API.
- email_domain_id (str) –
-
get_email_return_path
(email_return_path_id, **kwargs)¶ Retrieves the specified email return path.
Parameters: - email_return_path_id (str) –
(required) The OCID of this email return path.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of typeEmailReturnPath
Return type: Example: Click here to see an example of how to use get_email_return_path API.
- email_return_path_id (str) –
-
get_sender
(sender_id, **kwargs)¶ Gets an approved sender for a given senderId.
Parameters: - sender_id (str) – (required) The unique OCID of the sender.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: Return type: Example: Click here to see an example of how to use get_sender API.
-
get_suppression
(suppression_id, **kwargs)¶ Gets the details of a suppressed recipient email address for a given suppressionId. Each suppression is given a unique OCID.
Parameters: - suppression_id (str) – (required) The unique OCID of the suppression.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of typeSuppression
Return type: Example: Click here to see an example of how to use get_suppression API.
-
get_work_request
(work_request_id, **kwargs)¶ Gets the status of the work request with the given ID.
Parameters: - work_request_id (str) – (required) The ID of the asynchronous request.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of typeWorkRequest
Return type: Example: Click here to see an example of how to use get_work_request API.
-
list_dkims
(email_domain_id, **kwargs)¶ Lists DKIMs for an email domain.
Parameters: - email_domain_id (str) –
(required) The OCID of the email domain to which this DKIM belongs.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- id (str) – (optional) A filter to only return resources that match the given id exactly.
- name (str) – (optional) A filter to only return resources that match the given name exactly.
- limit (int) –
(optional) For list pagination. The maximum number of results per page, or items to return in a paginated “List” call. 1 is the minimum, 1000 is the maximum. For important details about how pagination works, see List Pagination.
- page (str) –
(optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.
- sort_order (str) –
(optional) The sort order to use, either ascending or descending order.
Allowed values are: “ASC”, “DESC”
- lifecycle_state (str) –
(optional) Filter returned list by specified lifecycle state. This parameter is case-insensitive.
Allowed values are: “ACTIVE”, “CREATING”, “DELETING”, “DELETED”, “FAILED”, “INACTIVE”, “NEEDS_ATTENTION”, “UPDATING”
- sort_by (str) –
(optional) Specifies the attribute with which to sort the DKIMs.
Default: TIMECREATED
- TIMECREATED: Sorts by timeCreated.
- NAME: Sorts by name.
- ID: Sorts by id.
Allowed values are: “TIMECREATED”, “ID”, “NAME”
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of typeDkimCollection
Return type: Example: Click here to see an example of how to use list_dkims API.
- email_domain_id (str) –
-
list_email_domains
(compartment_id, **kwargs)¶ Lists email domains in the specified compartment.
Parameters: - compartment_id (str) – (required) The OCID for the compartment.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- id (str) – (optional) A filter to only return resources that match the given id exactly.
- name (str) – (optional) A filter to only return resources that match the given name exactly.
- limit (int) –
(optional) For list pagination. The maximum number of results per page, or items to return in a paginated “List” call. 1 is the minimum, 1000 is the maximum. For important details about how pagination works, see List Pagination.
- page (str) –
(optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.
- sort_order (str) –
(optional) The sort order to use, either ascending or descending order.
Allowed values are: “ASC”, “DESC”
- lifecycle_state (str) –
(optional) Filter returned list by specified lifecycle state. This parameter is case-insensitive.
Allowed values are: “ACTIVE”, “CREATING”, “DELETING”, “DELETED”, “FAILED”, “UPDATING”
- sort_by (str) –
(optional) Specifies the attribute with which to sort the email domains.
Default: TIMECREATED
- TIMECREATED: Sorts by timeCreated.
- NAME: Sorts by name.
- ID: Sorts by id.
Allowed values are: “TIMECREATED”, “ID”, “NAME”
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of typeEmailDomainCollection
Return type: Example: Click here to see an example of how to use list_email_domains API.
-
list_email_return_paths
(**kwargs)¶ Lists email return paths in the specified compartment or emaildomain.
Parameters: - opc_request_id (str) – (optional) The request ID for tracing from the system
- compartment_id (str) – (optional) The OCID for the compartment.
- parent_resource_id (str) –
(optional) The OCID of the Email Domain to which this Email Return Path belongs.
- id (str) – (optional) A filter to only return resources that match the given id exactly.
- name (str) – (optional) A filter to only return resources that match the given name exactly.
- limit (int) –
(optional) For list pagination. The maximum number of results per page, or items to return in a paginated “List” call. 1 is the minimum, 1000 is the maximum. For important details about how pagination works, see List Pagination.
- page (str) –
(optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.
- sort_order (str) –
(optional) The sort order to use, either ascending or descending order.
Allowed values are: “ASC”, “DESC”
- lifecycle_state (str) –
(optional) Filter returned list by specified lifecycle state. This parameter is case-insensitive.
Allowed values are: “ACTIVE”, “CREATING”, “DELETING”, “DELETED”, “FAILED”, “NEEDS_ATTENTION”, “UPDATING”
- sort_by (str) –
(optional) Specifies the attribute with which to sort the return paths.
Default: TIMECREATED
- TIMECREATED: Sorts by timeCreated.
- NAME: Sorts by name.
- ID: Sorts by id.
Allowed values are: “TIMECREATED”, “ID”, “NAME”
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of typeEmailReturnPathCollection
Return type: Example: Click here to see an example of how to use list_email_return_paths API.
-
list_senders
(compartment_id, **kwargs)¶ Gets a collection of approved sender email addresses and sender IDs.
Parameters: - compartment_id (str) – (required) The OCID for the compartment.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- lifecycle_state (str) –
(optional) The current state of a sender.
Allowed values are: “CREATING”, “ACTIVE”, “NEEDS_ATTENTION”, “INACTIVE”, “FAILED”, “DELETING”, “DELETED”
- domain (str) – (optional) A filter to only return resources that match the given domain exactly.
- email_address (str) – (optional) The email address of the approved sender.
- page (str) –
(optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.
- limit (int) –
(optional) For list pagination. The maximum number of results per page, or items to return in a paginated “List” call. 1 is the minimum, 1000 is the maximum. For important details about how pagination works, see List Pagination.
- sort_by (str) –
(optional) The field to sort by. The TIMECREATED value returns the list in in descending order by default. The EMAILADDRESS value returns the list in ascending order by default. Use the SortOrderQueryParam to change the direction of the returned list of items.
Allowed values are: “TIMECREATED”, “EMAILADDRESS”
- sort_order (str) –
(optional) The sort order to use, either ascending or descending order.
Allowed values are: “ASC”, “DESC”
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of type list ofSenderSummary
Return type: Example: Click here to see an example of how to use list_senders API.
-
list_suppressions
(compartment_id, **kwargs)¶ Gets a list of suppressed recipient email addresses for a user. The compartmentId for suppressions must be a tenancy OCID. The returned list is sorted by creation time in descending order.
Parameters: - compartment_id (str) – (required) The OCID for the compartment.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- email_address (str) – (optional) The email address of the suppression.
- time_created_greater_than_or_equal_to (datetime) –
(optional) Search for suppressions that were created within a specific date range, using this parameter to specify the earliest creation date for the returned list (inclusive). Specifying this parameter without the corresponding timeCreatedLessThan parameter will retrieve suppressions created from the given timeCreatedGreaterThanOrEqualTo to the current time, in “YYYY-MM-ddThh:mmZ” format with a Z offset, as defined by RFC 3339.
Example: 2016-12-19T16:39:57.600Z
- time_created_less_than (datetime) –
(optional) Search for suppressions that were created within a specific date range, using this parameter to specify the latest creation date for the returned list (exclusive). Specifying this parameter without the corresponding timeCreatedGreaterThanOrEqualTo parameter will retrieve all suppressions created before the specified end date, in “YYYY-MM-ddThh:mmZ” format with a Z offset, as defined by RFC 3339.
Example: 2016-12-19T16:39:57.600Z
- page (str) –
(optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.
- limit (int) –
(optional) For list pagination. The maximum number of results per page, or items to return in a paginated “List” call. 1 is the minimum, 1000 is the maximum. For important details about how pagination works, see List Pagination.
- sort_by (str) –
(optional) The field to sort by. The TIMECREATED value returns the list in in descending order by default. The EMAILADDRESS value returns the list in ascending order by default. Use the SortOrderQueryParam to change the direction of the returned list of items.
Allowed values are: “TIMECREATED”, “EMAILADDRESS”
- sort_order (str) –
(optional) The sort order to use, either ascending or descending order.
Allowed values are: “ASC”, “DESC”
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of type list ofSuppressionSummary
Return type: Example: Click here to see an example of how to use list_suppressions API.
-
list_work_request_errors
(work_request_id, **kwargs)¶ Return a (paginated) list of errors for a given work request.
Parameters: - work_request_id (str) – (required) The ID of the asynchronous request.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- page (str) –
(optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.
- limit (int) –
(optional) For list pagination. The maximum number of results per page, or items to return in a paginated “List” call. 1 is the minimum, 1000 is the maximum. For important details about how pagination works, see List Pagination.
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of typeWorkRequestErrorCollection
Return type: Example: Click here to see an example of how to use list_work_request_errors API.
-
list_work_request_logs
(work_request_id, **kwargs)¶ Return a (paginated) list of logs for a given work request.
Parameters: - work_request_id (str) – (required) The ID of the asynchronous request.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- page (str) –
(optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.
- limit (int) –
(optional) For list pagination. The maximum number of results per page, or items to return in a paginated “List” call. 1 is the minimum, 1000 is the maximum. For important details about how pagination works, see List Pagination.
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of typeWorkRequestLogEntryCollection
Return type: Example: Click here to see an example of how to use list_work_request_logs API.
-
list_work_requests
(compartment_id, **kwargs)¶ Lists the work requests in a compartment.
Parameters: - compartment_id (str) – (required) The OCID for the compartment.
- work_request_id (str) – (optional) The ID of the asynchronous work request.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- page (str) –
(optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.
- limit (int) –
(optional) For list pagination. The maximum number of results per page, or items to return in a paginated “List” call. 1 is the minimum, 1000 is the maximum. For important details about how pagination works, see List Pagination.
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of typeWorkRequestSummaryCollection
Return type: Example: Click here to see an example of how to use list_work_requests API.
-
update_dkim
(dkim_id, update_dkim_details, **kwargs)¶ Modifies a DKIM.
Parameters: - dkim_id (str) –
(required) The OCID of this DKIM.
- update_dkim_details (oci.email.models.UpdateDkimDetails) – (required) The new DKIM attributes to apply.
- if_match (str) – (optional) Used for optimistic concurrency control. In the update or delete call for a resource, set the if-match parameter to the value of the etag from a previous get, create, or update response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource’s current etag value.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of type NoneReturn type: Example: Click here to see an example of how to use update_dkim API.
- dkim_id (str) –
-
update_email_domain
(email_domain_id, update_email_domain_details, **kwargs)¶ Modifies an email domain.
Parameters: - email_domain_id (str) –
(required) The OCID of this email domain.
- update_email_domain_details (oci.email.models.UpdateEmailDomainDetails) – (required) The new email domain attributes to apply.
- if_match (str) – (optional) Used for optimistic concurrency control. In the update or delete call for a resource, set the if-match parameter to the value of the etag from a previous get, create, or update response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource’s current etag value.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of type NoneReturn type: Example: Click here to see an example of how to use update_email_domain API.
- email_domain_id (str) –
-
update_email_return_path
(email_return_path_id, update_email_return_path_details, **kwargs)¶ Modifies an email return path.
Parameters: - email_return_path_id (str) –
(required) The OCID of this email return path.
- update_email_return_path_details (oci.email.models.UpdateEmailReturnPathDetails) – (required) The new email return path attributes to apply.
- if_match (str) – (optional) Used for optimistic concurrency control. In the update or delete call for a resource, set the if-match parameter to the value of the etag from a previous get, create, or update response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource’s current etag value.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: A
Response
object with data of type NoneReturn type: Example: Click here to see an example of how to use update_email_return_path API.
- email_return_path_id (str) –
-
update_sender
(sender_id, update_sender_details, **kwargs)¶ Replaces the set of tags for a sender with the tags provided. If either freeform or defined tags are omitted, the tags for that set remain the same. Each set must include the full set of tags for the sender, partial updates are not permitted. For more information about tagging, see Resource Tags.
Parameters: - sender_id (str) – (required) The unique OCID of the sender.
- update_sender_details (oci.email.models.UpdateSenderDetails) – (required) update details for sender.
- if_match (str) – (optional) Used for optimistic concurrency control. In the update or delete call for a resource, set the if-match parameter to the value of the etag from a previous get, create, or update response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource’s current etag value.
- opc_request_id (str) – (optional) The request ID for tracing from the system
- retry_strategy (obj) –
(optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
This should be one of the strategies available in the
retry
module. This operation will not retry by default, users can also use the convenientDEFAULT_RETRY_STRATEGY
provided by the SDK to enable retries for it. The specifics of the default retry strategy are described here.To have this operation explicitly not perform any retries, pass an instance of
NoneRetryStrategy
. - allow_control_chars (bool) – (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings
Returns: Return type: Example: Click here to see an example of how to use update_sender API.
-