Source: https://www.brixit.io/docs/api-transactions-create

# Create transaction

To create transaction in Brixit, send a POST request to /api/automation/v1/execute with operation set to transactions.create. Use the data fields below for supported input and filters.

[Transactions API](https://www.brixit.io/docs/api-transactions) · `transactions.create`

[URL](https://www.brixit.io/docs/api-transactions-create#url-and-authentication) · [Fields](https://www.brixit.io/docs/api-transactions-create#fields) · [Example](https://www.brixit.io/docs/api-transactions-create#example-request) · [Response](https://www.brixit.io/docs/api-transactions-create#response) · [Try it](https://www.brixit.io/docs/api-transactions-create#try-it)

## URL and authentication

`POST https://YOUR-BACKEND/api/automation/v1/execute`

Send `Authorization: Bearer <connection key>`, `Accept: application/json` and
`Content-Type: application/json`. [Create a connection](https://www.brixit.io/docs/api#get-connected).

This operation requires **write access** and CRM permission `add_transaction`.
The gateway invokes `POST /api/v1/app/transactions` internally.
Use the POST URL above with your automation key, including for read and delete operations.

## Request parameters

| Key | Type | Requirement |
| --- | --- | --- |
| `operation` | string | Required; exactly `transactions.create` |
| `data` | object | Required; see fields below |
| `idempotency_key` | string | Required; 8–100 characters. Unique per action; keep unchanged for identical retries. |

## Fields

Internal transactions require internal_listing_id and cannot include external_client. For external_listing, internal_listing_id and external_client must be empty, and external_listing must include company, listing_type and agent.name/phone/email. external_client fields are optional for external_client transactions. A transaction cannot be created as cancelled. Rental transactions with payment_method cheque require at least one cheque, unique cheque numbers and a total matching transaction_amount within 0.01. Cheques cannot be supplied for a sale.

Fields below belong inside `data`. Dot paths describe nested objects; `*` means each
array item. `nullable` permits null and `sometimes` validates a supplied field.
`in:` lists allowed values; `min:` and `max:` limit the value, length or item count.
`exists:` and `exists_in_company:` require a valid record ID. Conditional rules
such as `required_if` and `required_with` refer to other fields in the same payload.
Use YYYY-MM-DD for date-only values and timestamps with timezone offsets for follow-ups.

| Field | Type | Requirement | Format / validation |
| --- | --- | --- | --- |
| `transaction_source` | string | Required | required; in:internal,external_listing,external_client |
| `company_role` | string | Required | required; in:listing_agent,buyers_agent,tenants_agent,dual_agent,referral_only,broker |
| `transaction_type` | string | Required | required; in:sale,rental |
| `payment_method` | string | Optional | sometimes; in:cash,cheque |
| `status` | string | Optional | sometimes; in:draft,pending,in_progress,completed,closed,cancelled |
| `currency` | string | Optional | sometimes; nullable; string; size:3 |
| `transaction_amount` | number | Required | required; numeric; min:0 |
| `commission_rate` | number | Required | required; numeric; min:0; max:100 |
| `commission_amount` | number | Required | required; numeric; min:0 |
| `transaction_date` | string | Required | required; date |
| `external_listing` | object | Optional | sometimes; nullable; array |
| `external_listing.address` | string | Optional | sometimes; nullable; string; max:500 |
| `external_listing.city` | string | Optional | sometimes; nullable; string; max:100 |
| `external_listing.bedrooms` | integer | Optional | sometimes; nullable; integer; min:0 |
| `external_listing.bathrooms` | integer | Optional | sometimes; nullable; integer; min:0 |
| `external_listing.size` | number | Optional | sometimes; nullable; numeric; min:0 |
| `external_listing.listing_type` | integer | Optional | sometimes; nullable; integer; exists:listing_types,id |
| `external_listing.company` | string | Optional | sometimes; nullable; string; max:255 |
| `external_listing.agent` | object | Optional | sometimes; nullable; array |
| `external_listing.agent.name` | string | Optional | sometimes; nullable; string; max:255 |
| `external_listing.agent.phone` | string | Optional | sometimes; nullable; string; max:20 |
| `external_listing.agent.email` | string | Optional | sometimes; nullable; email; max:255 |
| `external_listing.agent.mls` | string | Optional | sometimes; nullable; string; max:100 |
| `external_client` | object | Optional | sometimes; nullable; array |
| `external_client.name` | string | Optional | sometimes; nullable; string; max:255 |
| `external_client.company` | string | Optional | sometimes; nullable; string; max:255 |
| `external_client.email` | string | Optional | sometimes; nullable; email; max:255 |
| `external_client.phone` | string | Optional | sometimes; nullable; string; max:20 |
| `external_client.client_type` | string | Optional | sometimes; nullable; string; max:100 |
| `external_client.agent` | object | Optional | sometimes; nullable; array |
| `external_client.agent.name` | string | Optional | sometimes; nullable; string; max:255 |
| `external_client.agent.phone` | string | Optional | sometimes; nullable; string; max:20 |
| `external_client.agent.email` | string | Optional | sometimes; nullable; email; max:255 |
| `rental_information` | object | Optional | sometimes; nullable; array |
| `rental_information.rental_start_date` | string | Optional | sometimes; nullable; date |
| `rental_information.rental_end_date` | string | Optional | sometimes; nullable; date; after_or_equal:rental_information.rental_start_date |
| `rental_information.lease_term_months` | integer | Optional | sometimes; nullable; integer; min:1; max:120 |
| `rental_information.monthly_rent` | number | Optional | sometimes; nullable; numeric; min:0 |
| `rental_information.security_deposit` | number | Optional | sometimes; nullable; numeric; min:0 |
| `internal_listing_id` | integer | Optional | sometimes; nullable; exists:listings,id |
| `lead_contact_id` | integer | Optional | sometimes; nullable; exists:leads,id |
| `deal_id` | integer | Optional | sometimes; nullable; exists:deals,id |
| `cheques` | array | Optional | sometimes; nullable; array; min:1 |
| `cheques.*.cheque_number` | string | Conditional | required_with:cheques; string; max:255 |
| `cheques.*.amount` | number | Conditional | required_with:cheques; numeric; min:0.01 |
| `cheques.*.due_date` | string | Conditional | required_with:cheques; date |
| `cheques.*.status` | string | Optional | sometimes; in:scheduled,deposited,paid,cleared,bounced,replaced,cancelled |
| `cheques.*.tenant_email` | string | Optional | sometimes; nullable; email; max:255 |
| `cheques.*.notes` | string | Optional | sometimes; nullable; string |
| `cheques.*.replaced_by_id` | integer | Optional | sometimes; nullable; integer; exists:transaction_cheques,id |
| `commission_splits` | array | Required | required; array; min:1 |
| `commission_splits.*.id` | integer | Optional | sometimes; nullable; integer |
| `commission_splits.*.recipient_role` | string | Required for each item | required; in:listing_agent,buyers_agent,tenants_agent,transaction_coordinator,referral_agent,broker_fee,administrative_fee,external_cooperation,custom |
| `commission_splits.*.internal_agent_id` | integer | Optional | sometimes; nullable; exists:users,id |
| `commission_splits.*.recipient_name` | string | Optional | sometimes; nullable; string; max:255 |
| `commission_splits.*.recipient_company` | string | Optional | sometimes; nullable; string; max:255 |
| `commission_splits.*.split_percentage` | number | Required for each item | required; numeric; min:0; max:100 |
| `commission_splits.*.split_amount` | number | Required for each item | required; numeric; min:0 |
| `commission_splits.*.is_external_payment` | boolean | Optional | sometimes; boolean |

## Example request

Replace the example IDs and values with records in your installation. Supply any
additional custom fields required by your company.

```json
{
  "operation": "transactions.create",
  "data": {
    "transaction_source": "internal",
    "internal_listing_id": 1,
    "company_role": "listing_agent",
    "transaction_type": "sale",
    "transaction_amount": 1000000,
    "commission_rate": 2,
    "commission_amount": 20000,
    "transaction_date": "2026-11-01",
    "commission_splits": [
      {
        "recipient_role": "listing_agent",
        "internal_agent_id": 1,
        "split_percentage": 100,
        "split_amount": 20000
      }
    ]
  },
  "idempotency_key": "example-event-12345"
}
```

## Response

Returns the created transaction in `data`. Use `data.id` for subsequent requests. Related fields depend on the resource and your permissions.

The gateway preserves the underlying HTTP status and JSON body. Successful requests return **HTTP 200**. A response may also include localized message fields.

Illustrative response excerpt (additional fields may be returned):

```json
{
  "status": "success",
  "data": {
    "id": 456
  }
}
```

## Errors

| HTTP status | Meaning |
| --- | --- |
| 400 | A CRM business rule rejected the action. |
| 401 | Missing, invalid, expired or revoked connection key. |
| 403 | Connection access or CRM permissions do not allow this action. |
| 404 | Operation or record unavailable. |
| 409 | This idempotency key was already used with a different request. |
| 413 | Request or result exceeds its size limit; reduce payload or page size. |
| 422 | Missing or invalid fields, or a CRM business rule rejected the operation. |
| 429 | Rate limit exceeded; wait before retrying. |
| 500 | The server could not complete the operation. |

Validation failures may return `message` / `errors`, or an `error` string with
an optional `fields` array. The tester shows the actual HTTP status and full body.
[Read about limits and retries](https://www.brixit.io/docs/api#errors-and-limits).

## Try it

[Open the interactive API tester](https://www.brixit.io/docs/api-transactions-create#try-it)
