API Reference

Create a new pivot view


Creates a view from the provided information. Currently, persists the provided additionalMetadata field, which can store an arbitrary JSON definition of a pivot table view. This pivot table must be associated with a query, and can optionally be associated with a query result. When a query is deleted, its associated views are also deleted.

POST /api/v1/pivotview


Required OAuth Scopes:

No OAuth scopes are required to use this endpoint.


bodybodyPivotViewDtotrueThe representation of the view to create

Body parameter example

  "additionalMeta": {
    "property1": {},
    "property2": {}
  "description": "string",
  "name": "string",
  "queryId": "string",
  "queryResultId": "string"

Code Samples

curl -X POST https://h.app.wdesk.com/s/wdata/prep/api/v1/pivotview  \ 
-H 'Content-Type: application/json' \ 
-H 'Accept: application/json' \ 
-H 'Authorization: Bearer {access-token}'
http POST https://h.app.wdesk.com/s/wdata/prep/api/v1/pivotview  \ 
Content-Type:application/json \ 
Accept:application/json \ 
Authorization:"Bearer {access-token}"
wget --method=POST "https://h.app.wdesk.com/s/wdata/prep/api/v1/pivotview" \
 --output-document -  \ 
 --header 'Content-Type: application/json' \ 
 --header 'Accept: application/json' \ 
 --header 'Authorization: Bearer {access-token}'
import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'

r = requests.post('https://h.app.wdesk.com/s/wdata/prep/api/v1/pivotview', headers = headers)



201 - Created

Returns a JSON object with a body property, which contains a PivotViewDto object for the created view.

Example Responses

  "body": {
    "additionalMeta": {},
    "created": "string",
    "description": "string",
    "id": "string",
    "name": "string",
    "parentId": "string",
    "queryId": "string",
    "queryResultId": "string",
    "updated": "string",
    "userId": "string",
    "version": "integer"
  "code": "integer"