Setting Attribute Values to Null with setnull¶
Some Arena API PUT endpoints let you clear an attribute by setting it to null. A null in the payload alone is not enough. You must also append the setnull=true query parameter to the endpoint URL.
Note
setnull is set in the endpoint URL, not in the request body. Without ?setnull=true, a null value in the payload is ignored and the existing value is kept. Other attributes in the same payload are still updated.
How It Works¶
- Append
?setnull=trueto the PUT endpoint URL. - Include the attribute in the payload with a value of
null. - The response returns the attribute as
null.
PUT {endpoint}?setnull=true
Example: Clear Item Sourcing Values¶
This example clears amlRank, amlSplit, and notes on an item sourcing record.
Endpoint
PUT /items/{itemGuid}/sourcing/{sourcingGuid}?setnull=true
Request body
{
"amlRank": null,
"amlSplit": null,
"notes": null
}
Response
{
"activeProduction": false,
"activePrototype": false,
"amlRank": null,
"amlSplit": null,
"approved": true,
"guid": "M4O7C21JMVDUDWGGVMEP",
"makeItem": false,
"mfrItem": {},
"notes": null,
"vendorItem": {
"guid": "EWGZ4UTBEN6BUDC9ZF6C",
"number": "RCE5C1H390J0K1H03B",
"supplier": {
"guid": "I0K38YXFIRAGZINCFA64",
"name": "MURATA MANUFACTURING CO LTD"
}
},
"vendorItemConversionFactor": 1
}
Supported Endpoints and Attributes¶
setnull=true applies to the following PUT endpoints. Only the listed attributes can be set to null.
| World (View) PUT Endpoint | Null Supported |
|---|---|
| Items (Spec) | description, revisionNumber, standardCost, targetCost, targetPrice |
| Items (BOM) | refDes, notes |
| Items (Sourcing) | notes, amlRank, amlSplit |
| Items (Items) | note |
| Suppliers (Profile) | supplierID, accountNumber, description, website |
| Suppliers (Phone Numbers) | comment, extension, label, number |
| Supplier Items (Spec) | name, description, type |
| Supplier Items (Compliance) | mark, rationale |
| Files (Summary) | description, format |
| Files (Markup) | markup.format |
| Changes (Summary) | implementationStatus, approvalDeadlineDateTime, title, description |
| Changes (Items) | materialEffectivityDateTime |
| Requests (Summary) | problem, requestedAction |
| Quality (Summary) | description, targetCompletionDateTime, type |
| Quality (Steps) | dueDateTime |
| Training (Summary) | description |