tableau

package
v0.1.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 18, 2026 License: Apache-2.0 Imports: 10 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

func NewClient

func NewClient(accessToken string, siteId string, baseUrl string, userId string, httpClient *uhttp.BaseHttpClient) *Client

func (*Client) AddUserToGroup added in v0.0.2

func (c *Client) AddUserToGroup(ctx context.Context, groupId, userId string) error

AddUserToGroup adds user to a group.

func (*Client) AddUserToSite added in v0.0.5

func (c *Client) AddUserToSite(ctx context.Context, user CreateUserRequest) (*User, error)

func (*Client) GetGroupUsers

func (c *Client) GetGroupUsers(ctx context.Context, groupId string, pageSize int, pageNumber int) ([]User, Pagination, error)

GetGroupUsers returns all users in a group.

func (*Client) GetGroups

func (c *Client) GetGroups(ctx context.Context, pageSize int, pageNumber int) ([]Group, Pagination, error)

GetGroups returns all groups on site.

func (*Client) GetPaginatedGroupUsers

func (c *Client) GetPaginatedGroupUsers(ctx context.Context, groupId string) ([]User, error)

GetPaginatedGroupUsers returns all users in a group - paginated.

func (*Client) GetPaginatedGroups

func (c *Client) GetPaginatedGroups(ctx context.Context) ([]Group, error)

GetPaginatedGroups returns all groups - paginated.

func (*Client) GetPaginatedUsers

func (c *Client) GetPaginatedUsers(ctx context.Context) ([]User, error)

GetPaginatedUsers returns all users - paginated.

func (*Client) GetSite

func (c *Client) GetSite(ctx context.Context) (Site, error)

GetSite returns site details of the site user is logged in to.

func (*Client) GetUsers

func (c *Client) GetUsers(ctx context.Context, pageSize int, pageNumber int) ([]User, Pagination, error)

GetUsers returns all users on site.

func (*Client) GetUsersPage added in v0.0.4

func (c *Client) GetUsersPage(ctx context.Context, token string) ([]User, string, error)

func (*Client) ListIdpConfigurations added in v0.1.4

func (c *Client) ListIdpConfigurations(ctx context.Context) ([]IdpConfiguration, error)

func (*Client) RemoveUserFromGroup added in v0.0.2

func (c *Client) RemoveUserFromGroup(ctx context.Context, groupId, userId string) error

RemoveUserFromGroup removes user from a group.

func (*Client) RemoveUserFromSite added in v0.0.5

func (c *Client) RemoveUserFromSite(ctx context.Context, userId string) error

func (*Client) UpdateUserSiteRole added in v0.1.1

func (c *Client) UpdateUserSiteRole(ctx context.Context, userId string, siteRole string) error

func (*Client) VerifyUser

func (c *Client) VerifyUser(ctx context.Context) error

VerifyUser returns current logged in user.

type CreateUserRequest added in v0.0.5

type CreateUserRequest struct {
	// has to be name in the payload
	Email              string `json:"name"`
	SiteRole           string `json:"siteRole"`
	AuthSetting        string `json:"authSetting,omitempty"`
	IdpConfigurationId string `json:"idpConfigurationId,omitempty"`
}

type Credentials

type Credentials struct {
	Site                      Site   `json:"site"`
	User                      User   `json:"user"`
	Token                     string `json:"token"`
	EstimatedTimeToExpiration string `json:"estimatedTimeToExpiration"`
}

func Login

func Login(ctx context.Context, baseUrl string, contentUrl string, token string, tokenName string) (Credentials, error)

Login returns credentials needed to use the API.

type Group

type Group struct {
	ID   string `json:"id"`
	Name string `json:"name"`
}

type IdpConfiguration added in v0.1.4

type IdpConfiguration struct {
	IdpConfigurationId   string `json:"idpConfigurationId"`
	IdpConfigurationName string `json:"idpConfigurationName"`
	AuthSetting          string `json:"authSetting"`
	Enabled              bool   `json:"enabled"`
}

type Pagination

type Pagination struct {
	PageNumber     string `json:"pageNumber"`
	PageSize       string `json:"pageSize"`
	TotalAvailable string `json:"totalAvailable"`
}

type Site

type Site struct {
	ID         string `json:"id"`
	ContentURL string `json:"contentUrl"`
	Name       string `json:"name"`
}

type User

type User struct {
	Email       string    `json:"email"`
	ID          string    `json:"id"`
	FullName    string    `json:"fullName"`
	Name        string    `json:"name"`
	SiteRole    string    `json:"siteRole"`
	AuthSetting string    `json:"authSetting"`
	LastLogin   time.Time `json:"lastLogin"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL