Symptom
You want to retreive the attachments in the Perferct Store Visit using Odata
Environment
SAP Cloud for Customer
Resolution
- First you need a create a custom Business Analytics Report to get the list of all the Answers from the Perfect Store Visit using the Visit ID. Example URL : https://my<tenantID>.crm.ondemand.com/sap/c4c/odata/ana_businessanalytics_analytics.svc/<ReportID>QueryResults?$format=json&$filter=CREF_VISIT_UUID eq <VisitID>&$select=CPOE_ID,CPOE_NAME,CQRE_VQV_NODE_ID&$top=10000
- Once you execute the above URL, you will get the Object IDs of all the Answers.
- Using the Object id of the Answers, Execute the below Query to get the attachments : https://my<tenantID>.crm.ondemand.com/sap/c4c/odata/v1/survey/AnswersCollection<ObjectID>$expand=ResponseItem/ResponseItemAttachment
Keywords
Odata, Perfect Store Visit, Visit, Answer, AnswerCollection , KBA , LOD-CRM-INT-API , OData API (C4C Only) , Problem
Product
SAP Cloud for Customer add-ins all versions