Skip to main content

Base Types

Foundational classes that API entities inherit from.

Value Wrapper Types

Wrapper types used to encapsulate primitive values in API requests and responses. This wrapper pattern allows the API to distinguish between "no value provided" and "explicitly set to null".

How Value Wrappers Work

All property values in the Acumatica API are wrapped in type-specific objects. For example, a string property is returned as:

{
  "CustomerID": {
    "value": "CUST001"
  }
}

This pattern provides several benefits:

  • Distinguishes between "field not included" and "field set to null"
  • Enables consistent handling of optional fields
  • Supports partial updates without ambiguity

Error Property

All value wrapper types include an inherited error property that contains a description when there is a validation or processing issue with the field. This is critical for understanding field-level errors in API responses.

{
  "CustomerID": {
    "value": "INVALID",
    "error": "Customer 'INVALID' not found"
  }
}

Always check the error property when processing API responses to handle field-level issues appropriately.