client

package
v0.0.0-...-b11f4bc Latest Latest
Warning

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

Go to latest
Published: Oct 12, 2018 License: GPL-3.0 Imports: 11 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	Url *url.URL
	// contains filtered or unexported fields
}

func NewClientWithOAuth

func NewClientWithOAuth(intranetUrl, authToken, refreshToken string) (*Client, error)

func NewClientWithWebhookAuth

func NewClientWithWebhookAuth(intranetUrl string, userId int, secret string) (*Client, error)

func NewEnvClientWithOauth

func NewEnvClientWithOauth() (*Client, error)

func NewEnvClientWithWebhookAuth

func NewEnvClientWithWebhookAuth() (*Client, error)

func (*Client) Do

func (c *Client) Do(method string, reqData interface{}, respData interface{}) (interface{}, error)

func (*Client) DoRaw

func (c *Client) DoRaw(method string, reqData interface{}, respData interface{}) (*resty.Response, error)

func (*Client) LandingRepoGetappinfo

func (c *Client) LandingRepoGetappinfo(data interface{}) (*types.Response, error)

func (*Client) LandingRepoRegister

func (c *Client) LandingRepoRegister(request *landing.RepoRegisterRequest) (*types.IntResponse, error)

func (*Client) LandingRepoUnregister

func (c *Client) LandingRepoUnregister(data interface{}) (*types.Response, error)

func (*Client) Methods

func (c *Client) Methods(request *types.MethodsRequest) (*types.MethodsResponse, error)

func (*Client) SetDebug

func (c *Client) SetDebug(v bool)

func (*Client) SetInsecureSSL

func (c *Client) SetInsecureSSL(v bool)

type OAuthData

type OAuthData struct {
	AuthToken    string `valid:"alphanum,required"`
	RefreshToken string `valid:"alphanum,required"`
}

type WebhookAuthData

type WebhookAuthData struct {
	UserID int    `valid:"required"`
	Secret string `valid:"alphanum,required"`
}

Jump to

Keyboard shortcuts

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