skip to Main Content

How to find all elements by value in list in JSonPath

I can find a person who has a hobby of "Dance" by doing the following: Xpath = Persons/Person/Hobbies/Hobby[text()="Dance"]/../.. <Persons> <Person> <Name>David</Name> <Age>20</Age> <Hobbies> <Hobby>Sing</Hobby> <Hobby>Dance</Hobby> </Hobbies> </Person> <Person> <Name>Frank</Name> <Age>30</Age> <Hobbies> <Hobby>Sing</Hobby> <Hobby>Read</Hobby> </Hobbies> </Person> </Persons> How would I do…

VIEW QUESTION

How to get json?

In browser I got this. I'm trying to get json but got error: raise JSONDecodeError("Expecting value", s, err.value) from None json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0) Code: import requests url = 'https://api-mainnet.magiceden.io/idxv2/getBidsByMintAddresses?hideExpired=true&mintAddresses=GXXBt4tzJ6aGoNvz87Xzh1PqXwB4qVRdQdHcX65iXtRZ&direction=1&field=2&limit=500&offset=0' response = requests.get(url) data =…

VIEW QUESTION

Transform JSON Data

I've Json data as below mentioned [ { "id": 3, "name": "ghi", "gender": null, "city": "" }, { "id": 5, "name": "", "gender": "", "city": "es" } ] and I want to transform to data format shown below. [ {…

VIEW QUESTION
Back To Top
Search