I find the SO question perfectly on-topic and properly scoped (that is, not "too broad").
The question asks about a tool for parsing JSON which is able to provide specific information (location of the value in the JSON file). In on-topic list this falls into the category "software tools commonly used by programmers".
As for scoping, a simple request for a command line tool would be sufficient to make the question not broader than "how to extract <something> from a shared library" sort of questions, e.g. that one.
Original scoping
I would like to know if there an option in jq (or a phython library, or some other linux/command line utility)
could be viewed as "too broad" reason, because command line tools and Python libraries are definitely different areas which should be searched separately. But since other parts of the question don't note Python at all, I find it reasonable to assume that Python is not the main concern for the asker. At least, it could be clarified with a comment like
Command line tools and Python libraries represent separate areas for search, but it seems that Python is not your main concern, so it could be removed from your question.
The current scoping
I would like to know if there is an option in jq
seems to be too strict, but on a potential asker's side I would treat this as "any command line tool is applicable".
Some time ago I searched for a Python library which parsed YAML and stored locations of the values. Finally I decided to wrap pyyaml with my classes.
So I would expect that command line tools lack support for this too. But the comment from @pmf suggests that some ways exist on that road.