---
schema_version: "1"
id: 73752df4811990a18d726b39f5a2ae776def73e34241276f51088a38c43def35
title: TxnSecurity Namespace
collection: legacydeveloper
version: current
locale: en-us
portal_url: https://docs.salesforce.com/legacydeveloper/current/en-us/apexref/apex_namespace_TxnSecurity.md
canonical_url: https://developer.salesforce.com/docs/atlas.en-us.apexref.meta/apexref/apex_namespace_TxnSecurity.htm
source_site: developer.salesforce.com
content_type: documentation
content_hash: d04eef9e259a3641822706baede4a13377eff26e7110253655cfc77a893f2b18
description: The TxnSecurity namespace provides an interface used for transaction security.
---
# TxnSecurity Namespace

The TxnSecurity namespace provides an interface used for transaction security.

The following is the interface and its supporting class in the TxnSecurity namespace.

- **[Event Class](https://developer.salesforce.com/docs/atlas.en-us.apexref.meta/apexref/apex_class_TxnSecurity_Event.htm#apex_class_TxnSecurity_Event)**  
    Contains event information that the evaluate method uses to evaluate a transaction security policy.
- **[EventCondition Interface](https://developer.salesforce.com/docs/atlas.en-us.apexref.meta/apexref/apex_interface_TxnSecurity_EventCondition.htm#apex_interface_TxnSecurity_EventCondition)**  
    Allows an implementing class to specify whether to take action when certain events occur based on a transaction security policy. This interface is only used for Apex policies created in Real-Time Event Monitoring.
- **[AsyncCondition Interface](https://developer.salesforce.com/docs/atlas.en-us.apexref.meta/apexref/apex_interface_TxnSecurity_AsyncCondition_interface.htm#apex_interface_TxnSecurity_AsyncCondition)**  
    Allows an implementing class to make asynchronous Apex calls. This interface is used only for transaction security Apex policies created in Real-Time Event Monitoring.
- **[PolicyCondition Interface](https://developer.salesforce.com/docs/atlas.en-us.apexref.meta/apexref/apex_interface_TxnSecurity_PolicyCondition.htm#apex_interface_TxnSecurity_PolicyCondition)**  
    Apex interface that allows an implementing class to specify actions to take when certain events occur based on a transaction security policy.