2

I know about Salesforce Reports and Dashboards REST API. But Report REST API allows only to change (update) an existing report by sending PATCH request with appropriate json body and clone a report based on existing one by sending POST request. But I need to create a new Report, not cloned report.

Also I tested dashboard creation by sending POST request with appropriate json body on the url https://ap2.salesforce.com/services/data/v37.0/analytics/dashboards and it works. But the same doesn't work for the Report. After sending POST request on the url ap2.salesforce.com/services/data/v37.0/analytics/reports I got a response:

[
  {
    "errorCode": "BAD_REQUEST",
    "message": "The clone request must contain a valid cloneId parameter."
  }
]

It means that I cannot create new Report by sending POST request to the REST resource.

Also I tried to create report by upsert and insert methods of SOAP Partner API, but in the response result I got the next message:

<message>entity type cannot be updated: Report</message>
<statusCode>CANNOT_INSERT_UPDATE_ACTIVATE_ENTITY</statusCode>

My goal is to deploy personal report to the instance. I already successfully deployed reports which are located in the custom folder or Unfiled Public Reports folder. I have done this with by deploy() method of the Salesforce SOAP API. But in the instance there is a standard folder My Personal Reports. And it impossible to deploy personal report via deploy() method of the SOAP API, because of unknown api name of the My Personal Reports folder. I retrieved metadata of the personal report in json format using Salesforce Reports and Dashboards REST API, but I don't know how to create a personal report based on the retrieved json metadata of this report.

If anyone know how to solve this problem (may be there is any workaround to create a personal report), please, share your ideas.

1 Answer 1

1

Perhaps the Salesforce Reports and Dashboards API has been expanded since you last checked. It is definitely possible to create a report into your personal folder as of 30SEP19. I suggest that you review current documentation.

  • You can create a new report with the Salesforce Reports and Dashboards API via POST request to /services/data/v39.0/analytics/reports.
  • Specify a desired folder ID for the new report inside reportMetadata object, e.g. "folderId" : "005R0000000Kg8cIAC"

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .