2 Replies Latest reply on Jun 9, 2017 6:42 AM by Andrew Harmon

    REST API schema question

    Andrew Harmon

      I'm getting familiar with the rest api. (using 2.4 at the moment). I'm using the xsd schemas provided on the Tableau site to properly format my Request and Responses. I ran into an issue while trying to get a paginated list of views. I used a GET and this url {server}/sites/{siteId}/views. The raw result comes back just fine, but when i try to unmarshall the results into a Response object I get an error. Looking closely at the xsd file, I see that the views element is not in the <xs:group name="paginatedResponseGroup"> section. So I modified the xsd and moved the element from <xs:element name="tsResponse"> to <xs:group name="paginatedResponseGroup"> and everything worked fine. So I'm a bit confused on why I'd need to make that change. Is my code doing something wrong? I doubt it's a error in the xsd bc i see the same thing in 2.5 and 2.6. There are multiple other elements that seem like they could have the same issue such as connections, favorites  and tags. I appreciate the help.




        • 1. Re: REST API schema question
          Peter Drage

          Hi Andrew,


          I just came across this very same problem today using version 2.5. I'm pretty sure its a bug in the XSD as it conceptually invalidates the response from the 'Query Views For Site' API. Instead of moving the element I would suggest that you copy it instead.




          • 2. Re: REST API schema question
            Andrew Harmon

            Thanks Peter,


            This week we upgraded to 10.3 and now i"m using 2.6 API... still same issue. I'll do a copy instead of a move. I'm having quite a bit of trouble using a new API feature "Refresh Extract Task". Have you used that yet? I'm able to issue the call appropriately, and get a successful response back. I can see the refresh starts on the web dashboard, but then it fails. The only 2 parameters the api call takes are siteId and taskId. I assume I have those correct since I can see the refresh begin in the dashboard. It fails with an error saying a workbook doesn't exist. But that's not a parameter i provide. If I manually refresh the task through the web interface, it works fine. Thinking of contacting Tableau support on this one.