models

package
v0.0.0-...-f60b94f Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2020 License: GPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Account

type Account struct {
	AccountId        int     `json:"account_id"`
	Bank             string  `json:"bank"`
	Type             string  `json:"type"`
	AccountName      string  `json:"account_name"`
	AccountNumber    int     `json:"account_number"`
	CurrentBalance   float64 `json:"current_balance"`
	AvailableBalance float64 `json:"available_balance"`
}

type ApnsLog

type ApnsLog struct {
	Event          string `json:"event"`
	SentTs         string `json:"sent_ts"`
	ReceivedTs     string `json:"received_ts"`
	NotificationId string `json:"notification_id"`
}

type ApnsRegisterRequest

type ApnsRegisterRequest struct {
	DeviceToken string `json:"device_token"`
}

type ApnsRequest

type ApnsRequest struct {
	DeviceToken      string `json:"device_token"`
	User             string `json:"user"`
	Topic            string `json:"topic"`
	Title            string `json:"title"`
	Body             string `json:"body"`
	ContentAvailable bool   `json:"content_available"`
}

type ApnsResponse

type ApnsResponse struct {
	StatusCode   int    `json:"status_code"`
	ApnsID       string `json:"apns_id"`
	Reason       string `json:"reason"`
	DeviceToken  string `json:"device_token"`
	User         string `json:"user"`
	SendResponse string `json:"send_response"`
}

type BankResponse

type BankResponse struct {
	Transactions []Transaction     `json:"transactions"`
	Accounts     []Account         `json:"accounts"`
	Holdings     []ForeignCurrency `json:"holdings"`
	Totals       []Total           `json:"totals"`
}

type Category

type Category struct {
	Category string `json:"category"`
	Regex    string `json:"regex"`
}

type CategoryRequest

type CategoryRequest struct {
	Categories []Category `json:"categories"`
}

type Credential

type Credential struct {
	Institution string `json:"institution"`
	Username    string `json:"username"`
	Password    string `json:"password"`
}

type CredentialsResponse

type CredentialsResponse struct {
	Credentials []Credential `json:"credentials"`
}

type ExclusionResponse

type ExclusionResponse struct {
	Exclusions []Transaction `json:"exclusions"`
}

type ExpectedTransaction

type ExpectedTransaction struct {
	Name             string    `json:"name"`
	Credit           float64   `json:"credit"`
	Debit            float64   `json:"debit"`
	FromDate         time.Time `json:"from_date"`
	PeriodLengthDays int       `json:"period_length_days"`
}

type ForeignCurrency

type ForeignCurrency struct {
	Instrument string  `json:"instrument"`
	Balance    float64 `json:"balance"`
	Value      float64 `json:"value"`
	Market     string  `json:"market"`
	UnitValue  float64 `json:"unit_value"`
}

type Invocation

type Invocation struct {
	InvocationId int       `json:"invocation_id"`
	Date         time.Time `json:"date"`
	Success      bool      `json:"success"`
	CountAdded   int       `json:"count_added"`
	CountDeleted int       `json:"count_deleted"`
}

type InvocationsResponse

type InvocationsResponse struct {
	Invocations []Invocation `json:"invocations"`
}

type ProjectionsRequest

type ProjectionsRequest struct {
	ExpectedTransactions []ExpectedTransaction `json:"expected_transactions"`
}

type ProjectionsResponse

type ProjectionsResponse struct {
	Projections []TimeseriesBalance `json:"projections"`
}

type RegisterRequest

type RegisterRequest struct {
	Username string `json:"username"`
}

type RegisterResponse

type RegisterResponse struct {
	Username string `json:"username"`
	Password string `json:"password"`
}

type Sprint

type Sprint struct {
	StartDate             time.Time           `json:"start_date"`
	EndDate               time.Time           `json:"end_date"`
	TransactionCount      int                 `json:"transaction_count"`
	MeanTransactionAmount float64             `json:"mean_transaction_amount"`
	Outgoings             float64             `json:"outgoings"`
	Ingoings              float64             `json:"ingoings"`
	Net                   float64             `json:"net"`
	NetBeforeExclusions   float64             `json:"net_before_exclusions"`
	InProgress            bool                `json:"in_progress"`
	Categories            []SprintCategory    `json:"categories"`
	Transactions          []Transaction       `json:"transactions"`
	Timeseries            []TimeseriesBalance `json:"timeseries_balance"`
}

type SprintCategory

type SprintCategory struct {
	Category         string  `json:"category"`
	TransactionCount int     `json:"transaction_count"`
	CategoryTotal    float64 `json:"category_total"`
}

type SprintsResponse

type SprintsResponse struct {
	Sprints []Sprint `json:"sprints"`
}

type TimeseriesAccount

type TimeseriesAccount struct {
	Account    Account             `json:"account"`
	Timeseries []TimeseriesBalance `json:"timeseries_balance"`
}

type TimeseriesBalance

type TimeseriesBalance struct {
	Date    time.Time `json:"date"`
	Balance float64   `json:"balance"`
}

type TimeseriesCategory

type TimeseriesCategory struct {
	Category   string              `json:"category"`
	Timeseries []TimeseriesBalance `json:"timeseries_balance"`
}

type TimeseriesResponse

type TimeseriesResponse struct {
	Accounts   []TimeseriesAccount  `json:"accounts"`
	Categories []TimeseriesCategory `json:"categories"`
	Total      []TimeseriesBalance  `json:"total"`
}

type Total

type Total struct {
	Type   string  `json:"type"`
	Amount float64 `json:"amount"`
}

type Transaction

type Transaction struct {
	TransactionId    int       `json:"transaction_id"`
	Date             time.Time `json:"date"`
	Account          int       `json:"account"`
	Description      string    `json:"description"`
	Bank             string    `json:"bank"`
	Credit           float64   `json:"credit"`
	Debit            float64   `json:"debit"`
	Categories       []string  `json:"categories"`
	Status           string    `json:"status"`
	InternalTransfer bool      `json:"internal_transfer"`
	Exclude          bool      `json:"exclude"`
}

type TransactionPatch

type TransactionPatch struct {
	Exclude bool `json:"exclude"`
}

Jump to

Keyboard shortcuts

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