Skip to content

upsertGaugeCalibrationRecord

WRITE

Upsert gauge calibration record.

POST /api/v1/quality/upsertGaugeCalibrationRecord
curl -X POST '<your-host>/api/v1/quality/upsertGaugeCalibrationRecord' \
  -H 'Authorization: Bearer <api-key>' \
  -H 'Content-Type: application/json' \
  -d '{
    "gaugeId": "string",
    "dateCalibrated": "string",
    "calibrationAttempts": [],
    "inspectionStatus": "Pass",
    "_operation": "create"
  }'
Response
{
  "id": "string"
}

Parameters

ParameterType

Required. 'create' inserts a new record, 'update' modifies the existing record with this id.

"create""update"
min length 1
min length 1
"Pass""Fail"
min 0max 1
min -200max 500

Input schema

schema
{
  "type": "object",
  "properties": {
    "gaugeId": {
      "type": "string",
      "minLength": 1
    },
    "supplierId": {
      "type": "string"
    },
    "dateCalibrated": {
      "type": "string",
      "minLength": 1
    },
    "requiresAction": {
      "type": "boolean"
    },
    "requiresAdjustment": {
      "type": "boolean"
    },
    "requiresRepair": {
      "type": "boolean"
    },
    "temperature": {
      "type": "number",
      "minimum": -200,
      "maximum": 500
    },
    "humidity": {
      "type": "number",
      "minimum": 0,
      "maximum": 1
    },
    "approvedBy": {
      "type": "string"
    },
    "measurementStandard": {
      "type": "string"
    },
    "calibrationAttempts": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "reference": {
            "type": "number"
          },
          "actual": {
            "type": "number"
          }
        },
        "required": [
          "reference",
          "actual"
        ]
      }
    },
    "notes": {
      "type": "string"
    },
    "inspectionStatus": {
      "type": "string",
      "enum": [
        "Pass",
        "Fail"
      ]
    },
    "customFields": {},
    "id": {
      "type": "string"
    },
    "_operation": {
      "type": "string",
      "enum": [
        "create",
        "update"
      ],
      "description": "Required. 'create' inserts a new record, 'update' modifies the existing record with this id."
    }
  },
  "required": [
    "gaugeId",
    "dateCalibrated",
    "calibrationAttempts",
    "inspectionStatus",
    "_operation"
  ]
}