Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

[Type 3] Publish directly using Datasource/Workbook objects from the Document API #1092

Copy link
Copy link
@eschranz

Description

@eschranz
Issue body actions

Description

Unless this functionality already exists, it would be helpful to directly use created Datasource/Workbook objects from the Document API as the source when publishing content via TSC. Currently, you have to pass a filepath or a file object, which I haven't found an example of. This would also reduce having to save files to the file system for quick on the fly datasource/workbook creation.

from tableaudocumentapi import Connection, Datasource
import tableauserverclient as tsc

ds = Datasource.from_connections(caption="", connections=[some_connection])

# do login magic, get information for publish
server.datasources.publish(
    datasource_item=tsc.DatasourceItem(project_id, "My Cool Datasource"),
    file=ds, # object? item?
    mode=server.PublishMode.Overwrite,
    connection_credentials=tsc.ConnectionCredentials(username, password),
)
Reactions are currently unavailable

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.