{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/monite/json-schema/monite-sync-record-resource-schema.json",
  "title": "SyncRecordResource",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/monite-accounting-synchronized-records-api-openapi.yml#/components/schemas/SyncRecordResource",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    },
    "errors": {
      "type": "object"
    },
    "last_pulled_at": {
      "type": "string",
      "format": "date-time"
    },
    "object_id": {
      "type": "string",
      "format": "uuid"
    },
    "object_type": {
      "$ref": "#/$defs/ObjectMatchTypes"
    },
    "object_updated_at": {
      "type": "string",
      "format": "date-time"
    },
    "platform": {
      "$ref": "#/$defs/Platform"
    },
    "platform_object_id": {
      "type": "string"
    },
    "platform_updated_at": {
      "type": "string",
      "format": "date-time"
    },
    "provider": {
      "$ref": "#/$defs/ServiceProvidersEnum"
    },
    "provider_object_id": {
      "type": "string"
    },
    "provider_updated_at": {
      "type": "string",
      "format": "date-time"
    },
    "sync_status": {
      "$ref": "#/$defs/SyncStatus"
    }
  },
  "type": "object",
  "required": [
    "id",
    "created_at",
    "updated_at",
    "last_pulled_at",
    "sync_status",
    "object_type"
  ],
  "$defs": {
    "ObjectMatchTypes": {
      "type": "string",
      "enum": [
        "product",
        "customer",
        "vendor",
        "receivable",
        "bill",
        "payment_record"
      ]
    },
    "Platform": {
      "type": "string",
      "enum": [
        "xero",
        "quickbooks",
        "quickbooks_online",
        "quickbooks_online_sandbox"
      ]
    },
    "ServiceProvidersEnum": {
      "type": "string",
      "enum": [
        "codat",
        "railz"
      ]
    },
    "SyncStatus": {
      "type": "string",
      "enum": [
        "pending",
        "error",
        "done"
      ]
    }
  }
}