{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/citi/json-schema/citi-request-for-information-schema.json",
  "title": "Request-For-Information",
  "description": "Request For Information Compliance",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/citi-request-for-information-api-api-openapi.yml#/components/schemas/Request-For-Information",
  "type": "object",
  "properties": {
    "rfi_id": {
      "type": "string",
      "description": "RFI ID ",
      "minLength": 1,
      "maxLength": 100,
      "title": "rfi_id"
    },
    "alert_id": {
      "type": "string",
      "description": "Alert ID.",
      "minLength": 1,
      "maxLength": 100,
      "title": "alert_id"
    },
    "request_data": {
      "type": "object",
      "description": "Source data",
      "oneOf": [
        {
          "$ref": "#/$defs/Request-Data-Entity"
        },
        {
          "$ref": "#/$defs/Request-Data-Transaction"
        }
      ],
      "title": "request_data"
    },
    "fieldlevel_requests": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Field-Level-Requests"
      },
      "description": " Field level requests for which response is requested",
      "maxItems": 30,
      "title": "fieldlevel_requests"
    }
  },
  "required": [
    "rfi_id",
    "alert_id",
    "request_data"
  ],
  "$defs": {
    "Field-Details": {
      "type": "object",
      "description": "Field details can have one or more questions requested from client.",
      "title": "Field-Details",
      "properties": {
        "question_name": {
          "type": "string",
          "description": "Data requested from client.",
          "minLength": 1,
          "maxLength": 250,
          "title": "question_name"
        },
        "datatype": {
          "type": "string",
          "description": "Data format type which client needs to return in the response.",
          "minLength": 1,
          "maxLength": 25,
          "title": "datatype"
        },
        "description": {
          "type": "string",
          "description": "Description of the requested data.",
          "minLength": 1,
          "maxLength": 500,
          "title": "description"
        }
      },
      "required": [
        "question_name",
        "datatype",
        "description"
      ]
    },
    "Field-Level-Requests": {
      "type": "object",
      "description": "Request can have one or more match level requests.",
      "title": "Field-Level-Requests",
      "properties": {
        "field_id": {
          "type": "number",
          "description": "Unique ID for each match.",
          "title": "field_id"
        },
        "field_name": {
          "type": "string",
          "description": "Name of the field where match has occurred.",
          "minLength": 1,
          "maxLength": 250,
          "title": "field_name"
        },
        "field_value": {
          "type": "string",
          "description": "Entire content of the field having the match.",
          "minLength": 1,
          "maxLength": 500,
          "title": "field_value"
        },
        "clarification_required_for": {
          "type": "string",
          "description": "Exact match.",
          "minLength": 1,
          "maxLength": 500,
          "title": "clarification_required_for"
        },
        "input_type": {
          "type": "string",
          "description": "The input type will be one the following - individual / entity / aircraft / vessel / unknown / others.",
          "minLength": 1,
          "maxLength": 16,
          "title": "input_type"
        },
        "additional_clarification": {
          "type": "string",
          "description": "Additional clarification.",
          "minLength": 1,
          "maxLength": 150,
          "title": "additional_clarification"
        },
        "field_details": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/Field-Details"
          },
          "description": "Field details with questions requested from client.",
          "maxItems": 30,
          "title": "field_details"
        }
      },
      "required": [
        "field_id",
        "field_name",
        "field_value",
        "input_type",
        "field_details"
      ]
    },
    "Request-Data-Entity": {
      "type": "object",
      "description": "Request Data Entity.",
      "title": "Request-Data-Entity",
      "properties": {
        "type": {
          "type": "string",
          "description": "Specifies the type of request data being provided.",
          "minLength": 1,
          "maxLength": 25,
          "title": "type"
        },
        "identifier_type": {
          "type": "string",
          "description": "Specifies the type of identifier being provided. This could be a payer ID.",
          "minLength": 1,
          "maxLength": 25,
          "title": "identifier_type"
        },
        "identifier_value": {
          "type": "string",
          "description": "The actual identifier value corresponding to the `identifier_type`.",
          "minLength": 1,
          "maxLength": 100,
          "title": "identifier_value"
        },
        "country": {
          "type": "string",
          "description": "Country.",
          "minLength": 1,
          "maxLength": 5,
          "title": "country"
        },
        "last_name": {
          "type": "string",
          "description": "The last name.",
          "title": "last_name",
          "minLength": 1,
          "maxLength": 250
        },
        "first_name": {
          "type": "string",
          "description": "The first name.",
          "title": "first_name",
          "minLength": 1,
          "maxLength": 250
        }
      },
      "required": [
        "type"
      ]
    },
    "Request-Data-Transaction": {
      "type": "object",
      "description": "Request Data Transaction.",
      "title": "Request-Data-Transaction",
      "properties": {
        "type": {
          "type": "string",
          "description": "Specifies the type of request data being provided.",
          "minLength": 1,
          "maxLength": 25,
          "title": "type"
        },
        "identifier_type": {
          "type": "string",
          "description": "Specifies the type of identifier being provided. This could be an account ID, a Swift code, or an IBAN, indicating the nature of the identifier in `identifier_value`.",
          "minLength": 1,
          "maxLength": 25,
          "title": "identifier_type"
        },
        "identifier_value": {
          "type": "string",
          "description": "The actual identifier value corresponding to the `identifier_type`.",
          "minLength": 1,
          "maxLength": 100,
          "title": "identifier_value"
        },
        "direction": {
          "type": "string",
          "description": "Specifies the direction of the transaction.",
          "minLength": 1,
          "maxLength": 1,
          "title": "direction"
        },
        "origin_country": {
          "type": "string",
          "description": "Origin country.",
          "minLength": 1,
          "maxLength": 5,
          "title": "origin_country"
        },
        "destination_country": {
          "type": "string",
          "description": "Destination country.",
          "minLength": 1,
          "maxLength": 5,
          "title": "destination_country"
        },
        "debtor_account_id": {
          "type": "string",
          "description": "The account identifier of the debtor.",
          "minLength": 1,
          "maxLength": 100,
          "title": "debtor_account_id"
        },
        "debtor_name": {
          "type": "string",
          "description": "The name of the debtor.",
          "minLength": 1,
          "maxLength": 250,
          "title": "debtor_name"
        },
        "account_name": {
          "type": "string",
          "description": "The name of the creditor.",
          "minLength": 1,
          "maxLength": 250,
          "title": "account_name"
        },
        "uetr": {
          "type": "string",
          "description": "UUID v4 format unique end-to-end transaction reference",
          "minLength": 1,
          "maxLength": 100,
          "title": "uetr"
        },
        "transaction_reference": {
          "type": "string",
          "description": "A unique transaction reference number.",
          "minLength": 1,
          "maxLength": 100,
          "title": "transaction_reference"
        },
        "account_number": {
          "type": "string",
          "description": "The account identifier of the creditor.",
          "minLength": 1,
          "maxLength": 100,
          "title": "account_number"
        },
        "bic_receiver": {
          "type": "string",
          "description": "BIC receiver code.",
          "minLength": 1,
          "maxLength": 100,
          "title": "bic_receiver"
        },
        "iban": {
          "type": "string",
          "description": "The transaction IBAN.",
          "minLength": 1,
          "maxLength": 100,
          "title": "iban"
        },
        "transaction_date": {
          "type": "string",
          "description": "The date and time when the transaction was initiated or processed. Format: ISO 8601 (YYYY-MM-DDTHH:mm:ss.sssZ).",
          "minLength": 1,
          "maxLength": 50,
          "title": "transaction_date"
        },
        "value_date": {
          "type": "string",
          "description": "Format YYYY-MM-DDTHH:mm:ss.sssZ Date in local time zone (e.g., EST for a United States RTP network transaction) when Citi's transaction processing application starts processing a transaction",
          "minLength": 1,
          "maxLength": 50,
          "title": "value_date"
        },
        "amount": {
          "type": "string",
          "description": "Transaction amount.",
          "minLength": 1,
          "maxLength": 30,
          "title": "amount"
        },
        "currency": {
          "type": "string",
          "description": "Transaction currency.",
          "minLength": 1,
          "maxLength": 10,
          "title": "currency"
        }
      },
      "required": [
        "type"
      ]
    }
  }
}