I am trying to call one API where I need to extract the "'Invoice_URL__c" value using python script from the Json body responses as below
{
'totalSize': 1,
'done': True,
'records': [
{
'attributes': {
'type': 'Invoice__c',
'url': '/services/data/v51.0/sobjects/Invoice__c/a031Y00000eTwQSQA0'
},
'Invoice_URL__c': 'https://app.Xchange.net/stream/File/InvoiceAttachment/a78a76c0-a56d-4546-ac2a-b7b5a3933fe4',
'Payment_Record_ID__c': 'a0N1Y00003CBTTW'
}
]
}
Can someone please help me in this regard?
for i in range(len(response['records'])):
print(response['records'][i]['Invoice_URL__c'])
This can help you get the invoice urls from json data
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.