5
我正在使用Python,并且我向URL发送了一个请求并使用httplib2接收了一个回复。我得到的答复是在JSon,我如何访问一个特定的参数。我目前所面对的是:python,Json和字符串索引必须是整数,而不是str
resp, content = parser.request(access_token_uri, method = 'POST', body = params, headers = headers)
raise Exception(content['access_token'])
,我得到的错误
string indices must be integers, not str
我该怎么办呢?
谢谢