collecta

package module
v0.0.0-...-444ad2e Latest Latest
Warning

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

Go to latest
Published: Aug 17, 2020 License: MIT Imports: 5 Imported by: 0

README

collecta

Collecta is a project related to feedback data and survey collection.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Auth

type Auth interface {
	Identify(i *Instance) (string, error)
}

type Collecta

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

Collecta wraps all the thing related to data manipulation on collecta, that is for create a robust API based on Golang

type Input

type Input interface {
	Type() InputType
	Value() ([]string, error)
}

Input is a input interface util to define how an input interact with other types

type InputType

type InputType string

InputType defines a type of input, that is useful to define the primitives

const Options InputType = "options"

Options is an input type

const Satisfaction InputType = "satisfaction"

Satisfaction is an input type

const Text InputType = "text"

Text is an input type

const YesNo InputType = "yesno"

YesNo is an input type

type Instance

type Instance struct {
	Endpoint string
	// contains filtered or unexported fields
}

func NewClient

func NewClient(endpoint string, auth ...Auth) *Instance

type Question

type Question struct {
	Order     int
	ID        string
	Title     string
	Anonymous bool
	Input     Input
}

func (*Question) CalculateID

func (q *Question) CalculateID()

type Span

type Span struct {
	After  *string
	Before *string
	Text   string
}

type Survey

type Survey struct {
	Title     string
	Metadata  map[string]interface{}
	Questions []Question
	Spans     []Span
}

type UserPasswordToken

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

func (*UserPasswordToken) Identify

func (upt *UserPasswordToken) Identify(i *Instance) (string, error)

Jump to

Keyboard shortcuts

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