Get multiple value from json dictionary

Viewed 17

I am fetching data using api in json format everything is fine just that i want to get two or multiple out from the below json

    {'s': 'ok',
 'd': [{'n': 'NSE:NIFTYBANK-INDEX',
   's': 'ok',
   'v': {'ch': -837.7,
    'chp': -1.39,
    'lp': 40630.6,
    'spread': 0.0,
    'ask': 40630.6,
    'bid': 40630.6,
    'open_price': 40889.05,
    'high_price': 41159.2,
    'low_price': 40360.2,
    'prev_close_price': 41468.3,
    'volume': 0,
    'short_name': 'NIFTYBANK-INDEX',
    'exchange': 'NSE',
    'description': 'NSE:NIFTYBANK-INDEX',
    'original_name': 'NSE:NIFTYBANK-INDEX',
    'symbol': 'NSE:NIFTYBANK-INDEX',
    'fyToken': '101000000026009',
    'tt': 1663804800,
    'cmd': {'t': 1663850640,
     'o': 40630.6,
     'h': 40630.6,
     'l': 40630.6,
     'c': 40630.6,
     'v': 0,
     'tf': '18:14'}}}]}

I am using below method to get on varible out

data['d'][0]['v']['high_price']

is there easy way to get multiple outputs

0 Answers
Related