Logo
MicroStrategy REST API API Documentation

Update a report's definition through Modelling Service

PUT {{baseUrl}}/api/model/reports/:reportId

Update a report's definition through Modeling service, based on the definition provided in request body. User can provide information, sourceType, dataSource, grid, advancedProperties and timezone in the request body, for the fields not given, they will not be updated. For the report existed in metadata, the information field can only change description part. Set Prefer to respond-async to execute this API asynchronously, then the response code would be 202 if complete report definition is not ready, in other successful cases, the definition of the newly updated report is returned in response.

 

Body PARAM

Key Datatype Required Description 
showFilterTokens
boolean Specify whether "qualification" is returned in "tokens" format, along with "text" and "tree" formats. A filter's "qualification" is presented in the following formats: * "text": A human readable, but non-parsable text, describing a filter's qualification. * "tree": A tree data structure fully defining the filter's qualification. * "tokens": A list of parsed tokens that define a filter's qualification. Be aware that generating tokens requires additional time. If omitted or `false`, only "text" and "tree" formats are returned. If `true`, all "text", "tree" and "tokens" formats are returned.
showExpressionAs
string This parameter specifies the format in which the expressions are returned in response. This parameter applies to the expressions in a fact or attribute and custom expressions used in a filter, prompt, security filter, custom group, etc. Expressions are presented in the following formats: * "text": A human readable, but non-parsable text, describing the expression. This is the default format that is always returned in the response. * "tree": A tree data structure fully defining the expression. This format can be used if you want to examine and modify the expression programmatically. * "tokens": A list of parsed tokens. This format can be used if you want to examine and modify the expression using the parser component. Note that generating tokens requires additional time. Tokens are a semi-structured representation of MicroStrategy expression text that includes object references. For example, let’s say a filter expression is "Revenue > Cost". When the filter expression is represented as tokens, the text is broken down into pieces (tokens) with information about what these pieces represent in the metadata: ("Revenue", Revenue_ID), (">", GreaterThan_ID), ("Cost", Cost_ID). If omitted, the expression is returned in "text" format. If `tree`, the expression is returned in "text" and "tree" formats. If `tokens`, the expression is returned in "text" and "tokens" formats.
showAdvancedProperties
string Specify whether to retrieve the values of the advanced properties. The advanced properties are presented in the following groups: * "vldbProperties": A list of properties as determined by the common infrastructure. * "metricJoinTypes": A list of Metric Join Types, one for each metric that appears in the template. * "attributeJoinTypes": A list of Attribute Join Types, one for each attribute that appears in the template. * "drillOptions": A list of properties related to the report drilling setting. * "useDefaultEvaluationOrder": A property decide the evaluation ordering. * "promptOrdering": A list of prompts in the same resolve sequence when executing the report. If omitted or `false`, nothing will be returned for the advanced properties. If `true`, all applicable advanced properties are returned.
executionStage
string This parameter specifies the execution stage the report is executed to. Available values: resolve_prompts, execute_data, no_action. If omitted, it is "no_action". __Available values__ : resolve_prompts, execute_data, no_action

Curl
curl -X PUT 'baseUrl/api/model/reports/:reportId?showFilterTokens=true&showExpressionAs=tree&showAdvancedProperties=tree&executionStage=resolve_prompts' -H 'X-MSTR-MS-Instance: rd_reportInstanceId' -H 'X-MSTR-AuthToken: authToken' -H 'X-MSTR-ProjectID: projectId' -H 'Prefer: respond-async'

ENDPOINTS