hyf

Context-aware query service for Radroots
git clone https://radroots.dev/git/hyf.git
Log | Files | Refs | README | LICENSE

buyer_request_match.response.schema.json (9474B)


      1 {
      2   "type": "object",
      3   "properties": {
      4     "version": {
      5       "type": "integer",
      6       "const": 1
      7     },
      8     "request_id": {
      9       "type": "string",
     10       "minLength": 1
     11     },
     12     "trace_id": {
     13       "type": "string"
     14     },
     15     "ok": {
     16       "type": "boolean"
     17     },
     18     "output": {
     19       "type": "object",
     20       "properties": {
     21         "assessments": {
     22           "type": "array",
     23           "items": {
     24             "type": "object",
     25             "properties": {
     26               "candidate_id": {
     27                 "type": "string"
     28               },
     29               "eligibility": {
     30                 "type": "string",
     31                 "enum": [
     32                   "eligible",
     33                   "conditional",
     34                   "ineligible"
     35                 ]
     36               },
     37               "checks": {
     38                 "type": "array",
     39                 "items": {
     40                   "type": "object",
     41                   "properties": {
     42                     "kind": {
     43                       "type": "string"
     44                     },
     45                     "result": {
     46                       "type": "string",
     47                       "enum": [
     48                         "pass",
     49                         "fail",
     50                         "unknown"
     51                       ]
     52                     },
     53                     "reason": {
     54                       "type": "string"
     55                     },
     56                     "evidence": {
     57                       "type": "array",
     58                       "items": {
     59                         "type": "object",
     60                         "properties": {
     61                           "source_id": {
     62                             "type": "string"
     63                           },
     64                           "revision": {
     65                             "type": "string"
     66                           },
     67                           "start": {
     68                             "type": "integer",
     69                             "minimum": 0
     70                           },
     71                           "end": {
     72                             "type": "integer",
     73                             "minimum": 0
     74                           },
     75                           "method": {
     76                             "type": "string"
     77                           }
     78                         },
     79                         "required": [
     80                           "end",
     81                           "method",
     82                           "revision",
     83                           "source_id",
     84                           "start"
     85                         ],
     86                         "additionalProperties": false
     87                       }
     88                     }
     89                   },
     90                   "required": [
     91                     "kind",
     92                     "result",
     93                     "reason"
     94                   ],
     95                   "additionalProperties": false
     96                 }
     97               }
     98             },
     99             "required": [
    100               "candidate_id",
    101               "checks",
    102               "eligibility"
    103             ],
    104             "additionalProperties": false
    105           }
    106         },
    107         "plans": {
    108           "type": "array",
    109           "items": {
    110             "type": "object",
    111             "properties": {
    112               "plan_id": {
    113                 "type": "string"
    114               },
    115               "supplier_id": {
    116                 "type": "string"
    117               },
    118               "allocations": {
    119                 "type": "array",
    120                 "items": {
    121                   "type": "object",
    122                   "properties": {
    123                     "lot_id": {
    124                       "type": "string"
    125                     },
    126                     "revision": {
    127                       "type": "string"
    128                     },
    129                     "line_id": {
    130                       "type": "string"
    131                     },
    132                     "quantity": {
    133                       "type": "object",
    134                       "properties": {
    135                         "state": {
    136                           "type": "string",
    137                           "enum": [
    138                             "known",
    139                             "unknown"
    140                           ]
    141                         },
    142                         "value": {
    143                           "type": [
    144                             "string",
    145                             "null"
    146                           ]
    147                         },
    148                         "unit": {
    149                           "type": [
    150                             "string",
    151                             "null"
    152                           ]
    153                         },
    154                         "qualifier": {
    155                           "type": "string",
    156                           "enum": [
    157                             "exact",
    158                             "approximate"
    159                           ]
    160                         }
    161                       },
    162                       "required": [
    163                         "state",
    164                         "qualifier"
    165                       ],
    166                       "additionalProperties": false
    167                     }
    168                   },
    169                   "required": [
    170                     "lot_id",
    171                     "revision",
    172                     "line_id",
    173                     "quantity"
    174                   ],
    175                   "additionalProperties": false
    176                 }
    177               },
    178               "coverage": {
    179                 "type": "object",
    180                 "properties": {
    181                   "lines_covered": {
    182                     "type": "array",
    183                     "items": {
    184                       "type": "string"
    185                     }
    186                   },
    187                   "uncovered": {
    188                     "type": "array",
    189                     "items": {
    190                       "type": "string"
    191                     }
    192                   },
    193                   "partial": {
    194                     "type": "boolean"
    195                   }
    196                 },
    197                 "required": [
    198                   "lines_covered",
    199                   "partial",
    200                   "uncovered"
    201                 ],
    202                 "additionalProperties": false
    203               },
    204               "unresolved": {
    205                 "type": "array",
    206                 "items": {
    207                   "type": "object",
    208                   "properties": {
    209                     "kind": {
    210                       "type": "string"
    211                     },
    212                     "reason": {
    213                       "type": "string"
    214                     }
    215                   },
    216                   "required": [
    217                     "kind",
    218                     "reason"
    219                   ],
    220                   "additionalProperties": false
    221                 }
    222               },
    223               "preference": {
    224                 "type": "object",
    225                 "properties": {
    226                   "policy": {
    227                     "type": "string"
    228                   },
    229                   "score": {
    230                     "type": "integer"
    231                   }
    232                 },
    233                 "required": [
    234                   "policy",
    235                   "score"
    236                 ],
    237                 "additionalProperties": false
    238               }
    239             },
    240             "required": [
    241               "plan_id",
    242               "supplier_id",
    243               "allocations",
    244               "coverage"
    245             ],
    246             "additionalProperties": false
    247           }
    248         },
    249         "limitations": {
    250           "type": "object",
    251           "properties": {
    252             "scope": {
    253               "type": "string",
    254               "enum": [
    255                 "supplied_only"
    256               ]
    257             },
    258             "truncated": {
    259               "type": "boolean"
    260             },
    261             "supported_mode": {
    262               "type": "string"
    263             },
    264             "unsupported": {
    265               "type": "array",
    266               "items": {
    267                 "type": "string"
    268               }
    269             }
    270           },
    271           "required": [
    272             "scope",
    273             "supported_mode",
    274             "truncated",
    275             "unsupported"
    276           ],
    277           "additionalProperties": false
    278         },
    279         "execution": {
    280           "type": "object",
    281           "properties": {
    282             "status": {
    283               "type": "string",
    284               "enum": [
    285                 "complete",
    286                 "degraded",
    287                 "failed"
    288               ]
    289             },
    290             "provider_calls": {
    291               "type": "integer",
    292               "minimum": 0
    293             },
    294             "model": {
    295               "type": [
    296                 "string",
    297                 "null"
    298               ]
    299             },
    300             "question_bundle": {
    301               "type": [
    302                 "string",
    303                 "null"
    304               ]
    305             }
    306           },
    307           "required": [
    308             "model",
    309             "provider_calls",
    310             "question_bundle",
    311             "status"
    312           ],
    313           "additionalProperties": false
    314         }
    315       },
    316       "required": [
    317         "assessments",
    318         "plans",
    319         "limitations",
    320         "execution"
    321       ],
    322       "additionalProperties": false
    323     },
    324     "error": {
    325       "type": "object",
    326       "properties": {
    327         "code": {
    328           "type": "string"
    329         },
    330         "message": {
    331           "type": "string"
    332         }
    333       },
    334       "required": [
    335         "code",
    336         "message"
    337       ],
    338       "additionalProperties": false
    339     },
    340     "meta": {
    341       "type": "object",
    342       "additionalProperties": true
    343     }
    344   },
    345   "required": [
    346     "version",
    347     "request_id",
    348     "ok"
    349   ],
    350   "additionalProperties": false
    351 }