> ## Documentation Index
> Fetch the complete documentation index at: https://docs.fusioncore.us/llms.txt
> Use this file to discover all available pages before exploring further.

# Apex Conditions

> Create Apex Conditions that use custom Apex code for complex record-based logic in fusionCore.

## Overview

Apex Conditions leverage Apex code, allowing for more complex customization and logic around different record types within your Salesforce data. These require the input of a developer familiar with Apex.

## Creating Apex Conditions

<Steps>
  <Step title="Fill out the Apex Condition information">
    Fill out the appropriate **Apex Condition information**:

    * **Name**
    * **Description**
    * **Apex Class** (`Apex_Class__c`) — the name of the Apex class that holds your logic

    <Frame>
      <img src="https://mintcdn.com/fusionspan/4u-JGPkRA8QDMGYi/images/end-user-guides/4849205273/image-20260316-135409.png?fit=max&auto=format&n=4u-JGPkRA8QDMGYi&q=85&s=f03d64157bb42b2a3c254e3b5e02b437" alt="The Apex Condition record showing the Name, Description, and Apex Class fields filled in" width="949" height="787" data-path="images/end-user-guides/4849205273/image-20260316-135409.png" />
    </Frame>
  </Step>

  <Step title="Save">
    Click **Save**.

    <Info>
      The class named in **Apex Class** must extend `FCORE_PAY.ApexConditionEvaluator` and implement its `init` and `evaluate` methods. fusionCore validates the class name when you save, so a missing or invalid class is rejected.
    </Info>
  </Step>
</Steps>

## Limitations and Common Pitfalls

* **The Apex class must extend the evaluator.** The class named in **Apex Class** must extend `FCORE_PAY.ApexConditionEvaluator`; a missing or invalid class is rejected when you save.
