{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/webex/json-schema/webex-update-contact-status-response-schema.json",
  "title": "UpdateContactStatusResponse",
  "description": "Result of the \"close contact record\" request. Each item in `records` describes the outcome in the target campaign where the contact was found.",
  "x-generated": "2026-11-04",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/webex-contact-list-management-api-openapi.yml#/components/schemas/UpdateContactStatusResponse",
  "type": "object",
  "required": [
    "outcome",
    "statusCode",
    "records"
  ],
  "properties": {
    "outcome": {
      "type": "string",
      "description": "Overall result: `Success` if closed everywhere a match was found; `PartialSuccess` if some matching contact records were closed but others were non-closeable; `NoChange` if none of the matching contact records could be closed; `Matching contact record not found.` if no match (HTTP 404).",
      "enum": [
        "Success",
        "PartialSuccess",
        "NoChange",
        "Matching contact record not found."
      ]
    },
    "statusCode": {
      "type": "integer",
      "description": "0 for a completed API response."
    },
    "records": {
      "type": "array",
      "description": "Per-campaign close outcome.",
      "items": {
        "$ref": "#/$defs/ContactCampaignUpdateResult"
      }
    }
  },
  "$defs": {
    "ContactCampaignUpdateResult": {
      "type": "object",
      "description": "Close outcome for one campaign.",
      "properties": {
        "updated": {
          "type": "boolean",
          "description": "True when the contact was closed in this campaign."
        },
        "campaignId": {
          "type": "string",
          "description": "Campaign ID for this record."
        },
        "campaignName": {
          "type": "string",
          "description": "Campaign Name."
        },
        "contactListId": {
          "type": "string",
          "description": "Contact list ID within the campaign where the contact was matched."
        },
        "matchedBy": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          },
          "description": "Field header and value used to match the contact in this campaign."
        },
        "fields": {
          "type": "object",
          "additionalProperties": true,
          "description": "Optional map of requested field names to values, present when the `fields` query parameter was supplied. Omitted when no fields were requested."
        },
        "comment": {
          "type": "string",
          "description": "Per-record result message. `Closed.` when the contact was successfully closed (`updated: true`). When matched but in sent-to-dialer status, `Cannot close; already sent to dialer.` (`updated: false`)."
        }
      }
    }
  }
}