---
title: "Create Transaction"
method: POST
path: "/transactions"
tags: ["transactions"]
---

# Create Transaction

`POST /transactions`

Create a new transaction

## Query parameters

- `mock` boolean

## Request body

- Transaction — Request body for a permission
  - `data` TransactionData — Date object expected to create a transaction
    - `type` string — Type of resource
    - `attributes` object — Attributes of a transaction resource
      - `organizationId` string, uuid, required — UUID of the organization to which this transaction belongs
      - `customerId` string, uuid, required — UUID of the customer that made the transaction
      - `appointmentId` string, uuid — UUID of the appointment during which this transaction was made
      - `organizationTransactionId` string — Organization's internally identifiable ID of the transaction
      - `amount` integer, required — The transaction amount in the smallest denomination of the currency system (e.g cent)

## Response `201`

Return a single data response

- object
  - `data` TransactionDataResponse, required — Expected data response object for a Transaction
    - `type` string — Type of resource
    - `id` string, uuid — UUID of resource; additional resource attributes will also be returned
    - `attributes` object — Attributes of resource
      - `organizationTransactionId` string — Organization's internally identifiable ID of the transaction
      - `amount` integer — Transaction amount in the smallest denomination of the currency system (e.g cent)
      - `currency` string — The currency of the transaction
      - `createdAt` string, date-time — Date the resource was logged
      - `updatedAt` string, date-time — Date the resource was last modified
      - `createdBy` string, uuid — User who created the transaction resource
      - `updatedBy` union — User who updated the transaction resource
        - string, uuid
        - unknown
    - `relationships` TransactionRelationships — Relationships of a customer
      - `organization` OrganizationRelationship, required — Organization that the resource belongs to
        - `data` object
          - `type` string — Type of the organization
          - `id` string, uuid — UUID of the organization
      - `customer` object, required
        - `data` CustomerRelationship — Customer that the resource belongs to
          - `data` object
            - `type` string — Type of resource
            - `id` string, uuid — UUID of the resource
      - `appointment` object, required
        - `data` AppointmentRelationship — Appointment that the customer belongs to
          - `data` object
            - `type` string — Type of resource
            - `id` string, uuid — UUID of the resource
    - `links` Link — Link object for resource meta data
      - `self` string
  - `links` Link — Link object for resource meta data
    - `self` string

## Other responses

- `401` — Unauthorized
- `403` — Forbidden
- `404` — Not Found
- `500` — Internal Server Error

---

[API](https://skmtc.dev/brickworksoftware/apis/brickwork-software-api.md) · [All operations](https://skmtc.dev/brickworksoftware/apis/brickwork-software-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/brickworksoftware/brickwork-software-api/revisions/b06aa4f3b83c/schema)
