Easy-Acumatica Docs

Cases Service

The `CasesService` is your primary tool for interacting with Case records in Acumatica. It allows you to programmatically create support cases, link related cases together, and manage their properties.

Importing Helpers

To create cases, you'll need the `CaseBuilder` from the `easy_acumatica.models` module. You may also need `QueryOptions` if you wish to customize the API response.

python

from easy_acumatica.models.case_builder import CaseBuilder
from easy_acumatica.models.query_builder import QueryOptions

Service Methods

create_case(api_version, builder, options=None)

This is the main method for creating a new case record. You must provide a `CaseBuilder` object containing the new case's details. You can optionally provide `QueryOptions` to customize the response, for example, to expand related entities.

python

# Build the case payload
case_payload = (
    CaseBuilder()
    .class_id("HIGH")  # Set the Case Class
    .subject("Urgent: Main website is down")
    .set("BusinessAccount", "ABCCORP") # Set the customer for the case
)

# Create the case
new_case = client.cases.create_case("24.200.001", case_payload)
print(f"Successfully created case with ID: {new_case['CaseCD']['value']}")
Easy-Acumatica v0.3.9 — Created and Developed by Matthew Hirstius (Nioron07).
Significant Contributions made by Chris Xu
Want to see the NPM version? See it here