{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/tapetide-com/json-schema/tapetide-com-fund-debt-security-schema.json",
  "title": "FundDebtSecurity",
  "x-generated": "2026-11-26",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/tapetide-com-openapi.json#/components/schemas/FundDebtSecurity",
  "type": "object",
  "properties": {
    "isin": {
      "type": "string",
      "description": "ISIN of the security."
    },
    "security_name": {
      "type": "string",
      "description": "The security's name as most fund houses give it in their newest portfolios."
    },
    "instrument_type": {
      "type": "string",
      "enum": [
        "gsec",
        "gsec_strips",
        "tbill",
        "sgb",
        "sdl",
        "cp",
        "cd",
        "ncd",
        "psu_bond",
        "bank_bond",
        "at1_bond",
        "perpetual_bond",
        "tier2_bond",
        "securitised",
        "municipal_bond",
        "preference_share"
      ],
      "description": "gsec: dated Government of India security; gsec_strips: a separately traded coupon or principal of one; tbill: treasury bill; sgb: sovereign gold bond; sdl: state government loan; cp: commercial paper; cd: certificate of deposit; ncd: corporate debenture or bond; psu_bond: bond of a central public-sector company or development finance institution; bank_bond: senior or infrastructure bond of a bank; at1_bond: bank additional tier 1 bond (perpetual); perpetual_bond: other perpetual bond; tier2_bond: tier 2 or subordinated bond; securitised: pass-through certificate of a securitisation trust; municipal_bond: municipal corporation bond; preference_share: redeemable preference share."
    },
    "issuer_name": {
      "type": [
        "string",
        "null"
      ],
      "description": "The issuer: the listed company's name when its shares trade, otherwise the name most fund houses print across the issuer's securities; Government of India, or the state government, for government securities."
    },
    "issuer_group": {
      "type": [
        "string",
        "null"
      ],
      "description": "Issuers whose names read alike once legal-form words and punctuation are dropped share one group, labelled with the name most of its securities carry; it joins the same issuer under several ISIN issuer codes, and a merged company's older code only when most of its paper is printed under the new name. It is not a business group: companies of one group (Tata, Adani, Bajaj...) are not combined."
    },
    "issuer_code": {
      "type": "string",
      "description": "The ISIN characters that name the issuer: 7 for a company (every security of one company shares them), 4 for a government (IN00 the central government, IN10-IN49 a state)."
    },
    "coupon_pct": {
      "type": [
        "number",
        "null"
      ],
      "description": "Coupon in percent a year (7.44 = 7.44%), the value most houses print. 0 for zero-coupon paper; null for discount paper (treasury bills, commercial paper, certificates of deposit) and where no house prints one. A floating coupon is the newest month's."
    },
    "coupon_type": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "fixed",
            "floating",
            "zero",
            "discount"
          ]
        },
        {
          "type": "null"
        }
      ],
      "description": "fixed, floating (resets; the name says so), zero (pays no coupon) or discount (issued below face value); null when unknown."
    },
    "maturity_date": {
      "type": [
        "string",
        "null"
      ],
      "description": "Maturity date (YYYY-MM-DD), the date most houses give. Null for a perpetual bond and where no house gives a full date. A house may give a put or call date instead; the date most houses agree on is used."
    },
    "perpetual": {
      "type": "boolean",
      "description": "true for perpetual bonds (at1_bond, perpetual_bond); maturity_date is then null."
    },
    "rating": {
      "type": [
        "string",
        "null"
      ],
      "description": "Latest credit rating of rating_agency, e.g. AAA, AA+, A1+ (short-term scale), D; SOV for government securities; null when no house gives one. Decided on the newest month any house gives a rating, by the houses giving that agency's rating."
    },
    "rating_agency": {
      "type": [
        "string",
        "null"
      ],
      "description": "The agency most houses give a rating from in that month: CRISIL, ICRA, CARE, India Ratings, Brickwork, Acuite or Infomerics; null when houses give grades without an agency, and for SOV."
    },
    "rating_suffix": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "SO",
            "CE"
          ]
        },
        {
          "type": "null"
        }
      ],
      "description": "SO (structured obligation) or CE (credit enhanced) when given with the rating."
    },
    "rating_as_of": {
      "type": [
        "string",
        "null"
      ],
      "description": "Date of the newest monthly statement printing the rating (YYYY-MM-DD)."
    },
    "rating_since": {
      "type": [
        "string",
        "null"
      ],
      "description": "First statement date of the run of months in which most houses printed this rating (YYYY-MM-DD): about when funds started showing it. Null for SOV."
    },
    "previous_rating": {
      "type": [
        "string",
        "null"
      ],
      "description": "The same agency's rating before rating_since, e.g. \"CRISIL AA\"; null when there is none."
    },
    "other_ratings": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "Ratings from other agencies given in the same month, e.g. [\"India Ratings AA-\"]; a bond rated by two agencies is not a disagreement."
    },
    "schemes_holding": {
      "type": "integer",
      "description": "Fund portfolios listing the security in the newest month (holdings_as_of); a fund house without a portfolio for that month counts with its previous month. 0 when no longer held."
    },
    "houses_holding": {
      "type": "integer",
      "description": "Fund houses with those portfolios."
    },
    "holding_value_cr": {
      "type": [
        "number",
        "null"
      ],
      "description": "Their total market value, INR crore; null when no fund holds it."
    },
    "holdings_as_of": {
      "type": [
        "string",
        "null"
      ],
      "description": "Newest statement month-end the holdings describe (YYYY-MM-DD); null when no fund holds it."
    },
    "first_held_on": {
      "type": "string",
      "description": "First statement date listing the security (YYYY-MM-DD)."
    },
    "last_held_on": {
      "type": "string",
      "description": "Latest statement date listing it (YYYY-MM-DD)."
    },
    "agreement": {
      "type": "object",
      "properties": {
        "coupon": {
          "type": "object",
          "properties": {
            "houses": {
              "type": "integer",
              "description": "Fund houses that give a coupon."
            },
            "agreeing": {
              "type": "integer",
              "description": "Of them, houses printing the coupon given."
            },
            "from": {
              "anyOf": [
                {
                  "type": "string",
                  "enum": [
                    "printed_column",
                    "security_name"
                  ]
                },
                {
                  "type": "null"
                }
              ],
              "description": "printed_column: at least one agreeing house gives it as a separate coupon; security_name: stated only in the security name; null when none is given."
            }
          },
          "required": [
            "houses",
            "agreeing",
            "from"
          ],
          "additionalProperties": false,
          "description": "How the coupon was decided."
        },
        "maturity": {
          "type": "object",
          "properties": {
            "houses": {
              "type": "integer",
              "description": "Fund houses that give a maturity date."
            },
            "agreeing": {
              "type": "integer",
              "description": "Of them, houses printing the maturity date given."
            },
            "from": {
              "anyOf": [
                {
                  "type": "string",
                  "enum": [
                    "printed_column",
                    "security_name"
                  ]
                },
                {
                  "type": "null"
                }
              ],
              "description": "printed_column: at least one agreeing house gives it as a separate maturity date; security_name: stated only in the security name; null when none is given."
            }
          },
          "required": [
            "houses",
            "agreeing",
            "from"
          ],
          "additionalProperties": false,
          "description": "How the maturity date was decided."
        },
        "rating": {
          "type": "object",
          "properties": {
            "houses": {
              "type": "integer",
              "description": "Fund houses that give a rating."
            },
            "agreeing": {
              "type": "integer",
              "description": "Of them, houses printing the rating given."
            },
            "from": {
              "anyOf": [
                {
                  "type": "string",
                  "enum": [
                    "printed_column",
                    "security_name"
                  ]
                },
                {
                  "type": "null"
                }
              ],
              "description": "printed_column: at least one agreeing house gives it as a separate rating; security_name: stated only in the security name; null when none is given."
            }
          },
          "required": [
            "houses",
            "agreeing",
            "from"
          ],
          "additionalProperties": false,
          "description": "How the rating was decided."
        }
      },
      "required": [
        "coupon",
        "maturity",
        "rating"
      ],
      "additionalProperties": false,
      "description": "How many houses print each field and how many agree with the value given. The rating counts the houses printing rating_agency's rating in the newest month."
    },
    "conflict_fields": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "coupon_pct",
          "maturity_date",
          "rating"
        ]
      },
      "description": "Fields fund houses print differently for the security; the values and houses are under `conflicts` on `/v1/funds/debt-securities/{isin}`."
    },
    "conflicts": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string",
            "enum": [
              "coupon_pct",
              "maturity_date",
              "rating"
            ],
            "description": "The field."
          },
          "value": {
            "type": "string",
            "description": "A value printed for it: a coupon in percent, a date YYYY-MM-DD or `perpetual`, or a rating with its agency."
          },
          "chosen": {
            "type": "boolean",
            "description": "true for the value the security's row gives. A group can have no chosen value, and the row's field is then null: houses split evenly between values with no separately reported value deciding it, or (coupon_pct) every house's percent stated in the name changed over time and was set aside."
          },
          "houses": {
            "type": "integer",
            "description": "Fund houses printing this value (their newest value; the newest month for a rating)."
          },
          "house_codes": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Those fund houses, by the `house` code of `/v1/funds/portfolios` (also accepted by `/v1/funds/houses/{fund_house}`)."
          },
          "schemes": {
            "type": "integer",
            "description": "Their portfolios printing it."
          },
          "latest_as_of": {
            "type": "string",
            "description": "Newest statement date printing it (YYYY-MM-DD)."
          }
        },
        "required": [
          "field",
          "value",
          "chosen",
          "houses",
          "house_codes",
          "schemes",
          "latest_as_of"
        ],
        "additionalProperties": false
      },
      "description": "Every value fund houses print for a field they disagree on, the chosen one first (a group may have none chosen, see `chosen`); empty when they agree."
    }
  },
  "required": [
    "isin",
    "security_name",
    "instrument_type",
    "issuer_name",
    "issuer_group",
    "issuer_code",
    "coupon_pct",
    "coupon_type",
    "maturity_date",
    "perpetual",
    "rating",
    "rating_agency",
    "rating_suffix",
    "rating_as_of",
    "rating_since",
    "previous_rating",
    "other_ratings",
    "schemes_holding",
    "houses_holding",
    "holding_value_cr",
    "holdings_as_of",
    "first_held_on",
    "last_held_on",
    "agreement",
    "conflict_fields",
    "conflicts"
  ],
  "additionalProperties": false
}