Processing a Json text response faster

I have quite a big json text response to a API call. AS you can see in the image am looking through the JSON for some specific values 365 times * 6 (values). This process is taking too much time using my method. Is there some tricks or tips on how to make the search faster.

Thank you!

Try the walking path blocks for the dictionary (these are bit like "pivot tables" for dictionaries)

If you provide some sample json, as a text file, (or your aia) someone might be able to work it through for you.

1 Like

Here is a snippet of the api, i have removed some part, i need to get to extract the 5 timer value and the date.

{
  "code": 200,
  "status": "OK",
  "data": {
    "1": [
      {
      "timings": {
        "timer_1": "07:30 (BST)",
        "timer_2": "07:50 (BST)",
        "timer_3": "12:00 (BST)",
        "timer_4": "15:57 (BST)",
        "timer_5": "18:37 (BST)",
      },
      "date": {
        "readable": "01 Oct 2024",
        "timestamp": "1727769661",
        "gregorian": {
          "date": "01-10-2024",
          "format": "DD-MM-YYYY",
          "day": "01",
          "weekday": {
            "en": "Tuesday"
          },
          "month": {
            "number": 10,
            "en": "October"
          },
          "year": "2024",
          "designation": {
            "abbreviated": "AD",
            "expanded": "Anno Domini"
          }
        },
..
          },
..
          },
..
          },
          "holidays": []
        }
      },
      "meta": {
..
..
          },
          "location": {
          }
        },

...
        }
      }
    },
    {
      "timings": {
        "timer_1": "07:00 (BST)",
        "timer_2": "07:02 (BST)",
         "timer_3": "12:50 (BST)",
         "timer_4": "15:57 (BST)",
         "timer_5": "18:00 (BST)",
      },
      "date": {
        "readable": "02 Oct 2024",
        "timestamp": "1727856061",
        "gregorian": {
          "date": "02-10-2024",
          "format": "DD-MM-YYYY",
          "day": "02",
          "weekday": {
            "en": "Wednesday"
          },
          "month": {
            "number": 10,
            "en": "October"
          },
          "year": "2024",
          "designation": {
            "abbreviated": "AD",
            "expanded": "Anno Domini"
          }
        },
..
          },
..
          },
..
          },
          "holidays": []
        }
      },
      "meta": {
...
          },
          "location": {
..
          }
        },
...
        }
      }
    },
..........

Please show at least the first three sets of data in their entirety, (no ...) so that a valid json can be constructed.

2 Likes
{ 
  "code": 200,
  "status": "OK",
  "data": {
    "1": [
      {
        "timings": {
          "timer_1": "07:30 (BST)",
          "timer_2": "07:50 (BST)",
          "timer_3": "12:00 (BST)",
          "timer_4": "15:57 (BST)",
          "timer_5": "18:37 (BST)"
        },
        "date": {
          "readable": "01 Jan 2025",
          "timestamp": "1735722061",
          "gregorian": {
            "date": "01-01-2025",
            "format": "DD-MM-YYYY",
            "day": "01",
            "weekday": {
              "en": "Wednesday"
            },
            "month": {
              "number": 1,
              "en": "January"
            },
            "year": "2025",
            "designation": {
              "abbreviated": "AD",
              "expanded": "Anno Domini"
            }
          },
          "hijri": {
            "date": "01-07-1446",
            "format": "DD-MM-YYYY",
            "day": "01",
            "weekday": {
              "en": "Al Arba'a"
            },
            "month": {
              "number": 7,
              "en": "Rajab"
            },
            "year": "1446",
            "designation": {
              "abbreviated": "AH",
              "expanded": "Anno Hegirae"
            },
            "holidays": []
          }
        },
        "meta": {
          "latitude": 1.234567,
          "longitude": 2.34567,
          "timezone": "Europe/London",
          "method": {
            "id": 2,
            "params": {
              "Sunrise": 15,
              "Sunset": 15
            },
            "location": {
              "latitude": 39.7042123,
              "longitude": -86.3994387
            }
          },
          "latitudeAdjustmentMethod": "ANGLE_BASED",
          "midnightMode": "STANDARD",
          "school": "STANDARD",
          "offset": {
            "Sunrise": 0,
            "Sunset": 0,
            "Midnight": 0
          }
        }
      },
      {
        "timings": {
          "timer_1": "08:00 (BST)",
          "timer_2": "08:20 (BST)",
          "timer_3": "12:30 (BST)",
          "timer_4": "16:00 (BST)",
          "timer_5": "19:00 (BST)"
        },
        "date": {
          "readable": "02 Jan 2025",
          "timestamp": "1735808461",
          "gregorian": {
            "date": "02-01-2025",
            "format": "DD-MM-YYYY",
            "day": "02",
            "weekday": {
              "en": "Thursday"
            },
            "month": {
              "number": 1,
              "en": "January"
            },
            "year": "2025",
            "designation": {
              "abbreviated": "AD",
              "expanded": "Anno Domini"
            }
          },
          "hijri": {
            "date": "02-07-1446",
            "format": "DD-MM-YYYY",
            "day": "02",
            "weekday": {
              "en": "Al Khamees"
            },
            "month": {
              "number": 7,
              "en": "Rajab"
            },
            "year": "1446",
            "designation": {
              "abbreviated": "AH",
              "expanded": "Anno Hegirae"
            },
            "holidays": []
          }
        },
        "meta": {
          "latitude": 1.234567,
          "longitude": 2.34567,
          "timezone": "Europe/London",
          "method": {
            "id": 2,
            "params": {
              "Sunrise": 15,
              "Sunset": 15
            },
            "location": {
              "latitude": 39.7042123,
              "longitude": -86.3994387
            }
          },
          "latitudeAdjustmentMethod": "ANGLE_BASED",
          "midnightMode": "STANDARD",
          "school": "STANDARD",
          "offset": {
            "Sunrise": 0,
            "Sunset": 0,
            "Midnight": 0
          }
        }
      },
      {
        "timings": {
          "timer_1": "08:15 (BST)",
          "timer_2": "08:35 (BST)",
          "timer_3": "13:00 (BST)",
          "timer_4": "16:30 (BST)",
          "timer_5": "19:15 (BST)"
        },
        "date": {
          "readable": "03 Jan 2025",
          "timestamp": "1735894861",
          "gregorian": {
            "date": "03-01-2025",
            "format": "DD-MM-YYYY",
            "day": "03",
            "weekday": {
              "en": "Friday"
            },
            "month": {
              "number": 1,
              "en": "January"
            },
            "year": "2025",
            "designation": {
              "abbreviated": "AD",
              "expanded": "Anno Domini"
            }
          },
          "hijri": {
            "date": "03-07-1446",
            "format": "DD-MM-YYYY",
            "day": "03",
            "weekday": {
              "en": "Al Jum'a"
            },
            "month": {
              "number": 7,
              "en": "Rajab"
            },
            "year": "1446",
            "designation": {
              "abbreviated": "AH",
              "expanded": "Anno Hegirae"
            },
            "holidays": []
          }
        },
        "meta": {
          "latitude": 1.234567,
          "longitude": 2.34567,
          "timezone": "Europe/London",
          "method": {
            "id": 2,
            "params": {
              "Sunrise": 15,
              "Sunset": 15
            },
            "location": {
              "latitude": 39.7042123,
              "longitude": -86.3994387
            }
          },
          "latitudeAdjustmentMethod": "ANGLE_BASED",
          "midnightMode": "STANDARD",
          "school": "STANDARD",
          "offset": {
            "Sunrise": 0,
            "Sunset": 0,
            "Midnight": 0
          }
        }
      }
    ]
  }
}

heres for 3 days thank you

1 Like

to get data from first date of first month

2 Likes

Thank you,

How can can i change the second entry in the list. I want to use the global month count but i cant find it when i use the variable month_count.

are you sure your responseContent contains data for 12 month x 30 days?

yes am sure in the full APi it does. how can i use the variable month count instead of "1"

you already know how to connect with 1, then why you don't know how to connect with 2, 3,...

because i got 12 month to do and 6 value to extract. i cannot have 72, that why i have a while count for the month

give the full responseContent as a text file and upload here.
and tell us what data you want to get, and in what format.