我在从python脚本进行api调用时生成了输出。我只需要那个出口的特殊物品

2024-09-30 14:24:21 发布

您现在位置:Python中文网/ 问答频道 /正文

我只需要这些输出块中的灯的总数,总灯亮和总灯关。我如何实现它。有多个建筑物id,它有所有这些信息。但我需要灯开,灯关和灯的总数累计

{
"lampSummaryStatus": [
   {
        "buildingId": "93CB2950-46D0-4231-B21C-C4691ACFCC1D",
        "totalNumberOfLamps": 9,
        "totalLampOn": 0,
        "totalLampOff": 0,
        "totalLampUnknown": 9,
        "totalLampConnected": 0,
        "totalLampDisconnected": 9,
        "totalLampWithALS": 0,
        "totalLampWithoutALS": 9,
        "totalPolicyNull": 0,

Tags: 信息id总数建筑物buildingid灯关c4691acfcc1dlampsummarystatus