bosgo: code.bankrs.com/bosgo Index | Files

package bosgo

import "code.bankrs.com/bosgo"

Package bosgo provides a Go client for accessing the Bankrs OS API.

Index

Package Files

app.go applicationkeys.go credentials.go developer.go req.go service.go stats.go types.go user.go webhooks.go

Constants

const (

    // Version is the current version of the bosgo library.
    Version = "0.1"

    // DefaultUserAgent is the default user agent header used by the bosgo library.
    DefaultUserAgent = "bosgo-bankrs-os-client/" + Version
)
const (
    SandboxAddr    = "api.sandbox.bankrs.com"
    ProductionAddr = "api.bankrs.com"
)

type Access Uses

type Access struct {
    ID                int64              `json:"id"`
    Name              string             `json:"name"`
    Enabled           bool               `json:"enabled"`
    AuthPossible      bool               `json:"auth_possible"`
    ProviderID        string             `json:"provider_id"`
    Accounts          []Account          `json:"accounts,omitempty"`
    Capabilities      AccessCapabilities `json:"capabilities"`
    Beneficiaries     []Beneficiary      `json:"beneficiaries,omitempty"`
    ConsentExpiration time.Time          `json:"consent_expiration,omitempty"`
    // Personal information of the user, just for this access
    UserInfo UserInfo `json:"user_info,omitempty"`
}

type AccessCapabilities Uses

type AccessCapabilities struct {
    RecurringTransfer RecurringTransferCapabilities `json:"recurring_transfer"`
    ScheduledTransfer ScheduledTransferCapabilities `json:"scheduled_transfer"`
    Trading           bool                          `json:"trading"`
}

type AccessPage Uses

type AccessPage struct {
    Accesses []Access `json:"accesses"`
}

type AccessesService Uses

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

AccessesService provides access to bank access related API services.

func NewAccessesService Uses

func NewAccessesService(u *UserClient) *AccessesService

func (*AccessesService) Add Uses

func (a *AccessesService) Add(providerID string) *AddAccessReq

func (*AccessesService) Delete Uses

func (a *AccessesService) Delete(id int64) *DeleteAccessReq

func (*AccessesService) Get Uses

func (a *AccessesService) Get(id int64) *GetAccessReq

Get prepares and returns a request to fetch data about a bank access associated with the user.

func (*AccessesService) List Uses

func (a *AccessesService) List() *ListAccessesReq

func (*AccessesService) Refresh Uses

func (a *AccessesService) Refresh(id int64) *RefreshAccessReq

Refresh prepares and returns a request to refresh the data for a bank access associated with the user. The request returns a job which may be used to track the progress of the refresh.

func (*AccessesService) RefreshAll Uses

func (a *AccessesService) RefreshAll() *RefreshAllAccessesReq

RefreshAll prepares and returns a request to refresh all data for all accesses associated with the user. The request returns one job per access.

func (*AccessesService) Update Uses

func (a *AccessesService) Update(id int64) *UpdateAccessReq

Update prepares and returns a request to update the stored answers for a bank access associated with the user.

type Account Uses

type Account struct {
    ID               int64               `json:"id"`
    ProviderID       string              `json:"provider_id"`
    BankAccessID     int64               `json:"bank_access_id"`
    Name             string              `json:"name"`
    Type             AccountType         `json:"type"`
    Holder           string              `json:"holder,omitempty"`
    Number           string              `json:"number"`
    Balance          string              `json:"balance"`
    BalanceDate      time.Time           `json:"balance_date"`
    AvailableBalance string              `json:"available_balance"`
    CreditLine       string              `json:"credit_line"`
    Removed          bool                `json:"removed"`
    Currency         string              `json:"currency"`
    IBAN             string              `json:"iban"`
    Alias            string              `json:"alias"`
    Capabilities     AccountCapabilities `json:"capabilities"`
    Bin              string              `json:"bin"`
    Beneficiaries    []int64             `json:"beneficiaries,omitempty"`
}

type AccountCapabilities Uses

type AccountCapabilities struct {
    AccountStatement  []string `json:"account_statement"`
    Transfer          []string `json:"transfer"`
    RecurringTransfer []string `json:"recurring_transfer"`
}

type AccountPage Uses

type AccountPage struct {
    Accounts []Account
}

type AccountRef Uses

type AccountRef struct {
    ProviderID string `json:"provider_id"`
    IBAN       string `json:"iban,omitempty"`
    Label      string `json:"label,omitempty"`
    Number     string `json:"id,omitempty"`
    Type       string `json:"type,omitempty"`
}

type AccountType Uses

type AccountType string
const (
    AccountTypeCurrent    AccountType = "current"
    AccountTypeSavings    AccountType = "savings"
    AccountTypeCreditCard AccountType = "creditcard"
    AccountTypeLoan       AccountType = "loan"
)

type AccountsService Uses

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

AccountsService provides access to account related API services.

func NewAccountsService Uses

func NewAccountsService(u *UserClient) *AccountsService

func (*AccountsService) Get Uses

func (a *AccountsService) Get(id string) *GetAccountReq

func (*AccountsService) List Uses

func (a *AccountsService) List() *ListAccountsReq

type AddAccessReq Uses

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

func (*AddAccessReq) ChallengeAnswer Uses

func (r *AddAccessReq) ChallengeAnswer(answer ChallengeAnswer) *AddAccessReq

ChallengeAnswer adds an answer to one of the authorisation challenges required to complete addition of the access.

func (*AddAccessReq) ClientID Uses

func (r *AddAccessReq) ClientID(id string) *AddAccessReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*AddAccessReq) Context Uses

func (r *AddAccessReq) Context(ctx context.Context) *AddAccessReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*AddAccessReq) Send Uses

func (r *AddAccessReq) Send() (*Job, error)

type AppClient Uses

type AppClient struct {
    Providers *ProvidersService
    Users     *AppUsersService
    IBAN      *IBANService
    // contains filtered or unexported fields
}

AppClient is a client used for interacting with services in the context of a registered application without a valid user or developer session. It is safe for concurrent use by multiple goroutines.

func NewAppClient Uses

func NewAppClient(client *http.Client, addr string, applicationKey string) *AppClient

NewAppClient creates a new client that may be used to interact with services that require a specific application context.

func (*AppClient) WithUserIDAndUserToken Uses

func (a *AppClient) WithUserIDAndUserToken(userID, token string) *UserClient

WithUserToken creates a UserClient with the supplied user token and application ID, copying options set on the receiver.

type AppUsersService Uses

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

AppUsersService provides access to application user related API services.

func NewAppUsersService Uses

func NewAppUsersService(c *AppClient) *AppUsersService

func (*AppUsersService) Create Uses

func (a *AppUsersService) Create(username, password string) *UserCreateReq

Create returns a request that may be used to create a user with the given username and password.

func (*AppUsersService) Login Uses

func (a *AppUsersService) Login(username, password string) *UserLoginReq

Login returns a request that may be used to login a user with the given username and password.

func (*AppUsersService) ResetPassword Uses

func (a *AppUsersService) ResetPassword(username, password string) *ResetUserPasswordReq

ResetPassword prepares and returns a request to reset a user's password.

type ApplicationKey Uses

type ApplicationKey struct {
    Key       string    `json:"key,omitempty"`
    CreatedAt time.Time `json:"created_at,omitempty"`
}

type ApplicationKeyPage Uses

type ApplicationKeyPage struct {
    Keys []ApplicationKey `json:"keys,omitempty"`
}

type ApplicationKeysService Uses

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

ApplicationKeysService provides access to application key related API services that also require an authenticated developer session.

func NewApplicationKeysService Uses

func NewApplicationKeysService(c *DevClient) *ApplicationKeysService

func (*ApplicationKeysService) Delete Uses

func (d *ApplicationKeysService) Delete(applicationKey string) *DeleteAppKeyReq

Delete returns a request that may be used to remove the specified key from application.

type ApplicationMetadata Uses

type ApplicationMetadata struct {
    ApplicationID string `json:"id,omitempty"`
    Label         string `json:"label,omitempty"`
}

type ApplicationPage Uses

type ApplicationPage struct {
    Applications []ApplicationMetadata `json:"applications,omitempty"`
}

type ApplicationSettings Uses

type ApplicationSettings struct {
    BackgroundRefresh bool `json:"background_refresh"`
}

type ApplicationsService Uses

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

ApplicationsService provides access to application related API services that also require an authenticated developer session.

func NewApplicationsService Uses

func NewApplicationsService(c *DevClient) *ApplicationsService

func (*ApplicationsService) Create Uses

func (d *ApplicationsService) Create(label string) *CreateApplicationsReq

func (*ApplicationsService) CreateCredential Uses

func (d *ApplicationsService) CreateCredential(applicationID, provider string, credentials map[string]string) *CreateCredentialReq

CreateCredential returns a request that may be used to create a set of developer credentials.

func (*ApplicationsService) CreateKey Uses

func (d *ApplicationsService) CreateKey(applicationID string) *CreateAppKeyReq

func (*ApplicationsService) Delete Uses

func (d *ApplicationsService) Delete(applicationID string) *DeleteApplicationsReq

func (*ApplicationsService) List Uses

func (d *ApplicationsService) List() *ListApplicationsReq

func (*ApplicationsService) ListCredentials Uses

func (d *ApplicationsService) ListCredentials(applicationID string) *ListCredentialsReq

ListCredentials returns a request that may be used to list all developer credentials associated with an application.

func (*ApplicationsService) ListKeys Uses

func (d *ApplicationsService) ListKeys(applicationID string) *ListAppKeysReq

func (*ApplicationsService) ListUsers Uses

func (d *ApplicationsService) ListUsers(applicationKey string) *ListDevUsersReq

func (*ApplicationsService) ResetUsers Uses

func (d *ApplicationsService) ResetUsers(applicationKey string, usernames []string) *ResetDevUsersReq

ResetUsers prepares and returns a request to reset user data.

func (*ApplicationsService) Settings Uses

func (d *ApplicationsService) Settings(applicationID string) *GetApplicationSettingsReq

Settings prepares and returns a request to retrieve an application's configuration settings.

func (*ApplicationsService) Update Uses

func (d *ApplicationsService) Update(applicationID string, label string) *UpdateApplicationReq

func (*ApplicationsService) UpdateSettings Uses

func (d *ApplicationsService) UpdateSettings(applicationID string) *UpdateApplicationSettingsReq

UpdateSettings prepares and returns a request to update an application's configuration settings.

func (*ApplicationsService) UserInfo Uses

func (d *ApplicationsService) UserInfo(applicationKey, id string) *DevUserInfoReq

UserInfo prepares and returns a request to lookup information about a user.

type AuthMethod Uses

type AuthMethod struct {
    ID          string `json:"id"`
    Description string `json:"description"`
}

type Beneficiary Uses

type Beneficiary struct {
    ID        int64      `json:"id"`
    RemoteAcc AccountRef `json:"remote_account"`
    Reference string     `json:"reference,omitempty"`
}

type CancelRecurringTransferReq Uses

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

func (*CancelRecurringTransferReq) ClientID Uses

func (r *CancelRecurringTransferReq) ClientID(id string) *CancelRecurringTransferReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*CancelRecurringTransferReq) Context Uses

func (r *CancelRecurringTransferReq) Context(ctx context.Context) *CancelRecurringTransferReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*CancelRecurringTransferReq) Send Uses

func (r *CancelRecurringTransferReq) Send() (*RecurringTransfer, error)

Send sends the request to update a money transfer.

type CancelTransferReq Uses

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

func (*CancelTransferReq) ClientID Uses

func (r *CancelTransferReq) ClientID(id string) *CancelTransferReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*CancelTransferReq) Context Uses

func (r *CancelTransferReq) Context(ctx context.Context) *CancelTransferReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*CancelTransferReq) Send Uses

func (r *CancelTransferReq) Send() (*Transfer, error)

Send sends the request to update a money transfer.

type Category Uses

type Category struct {
    ID    int64             `json:"id"`
    Names map[string]string `json:"names"`
    Group string            `json:"group"`
}

type CategoryList Uses

type CategoryList []Category

type Challenge Uses

type Challenge struct {
    NextChallenges []ChallengeField `json:"next_challenges"`
    LastProblems   []Problem        `json:"last_problems"`
}

type ChallengeAnswer Uses

type ChallengeAnswer struct {
    ID         string    `json:"id"`
    Value      string    `json:"value"`
    Store      bool      `json:"store"`
    ValidUntil time.Time `json:"valid_until"`
}

type ChallengeAnswerList Uses

type ChallengeAnswerList []ChallengeAnswer

type ChallengeAnswerMap Uses

type ChallengeAnswerMap map[string]ChallengeAnswer

type ChallengeField Uses

type ChallengeField struct {
    ID            string            `json:"id"`
    Description   string            `json:"description"`
    ChallengeType string            `json:"type"`
    Previous      string            `json:"previous"`
    Stored        bool              `json:"stored"`
    Reset         bool              `json:"reset"`
    Secure        bool              `json:"secure"`
    Optional      bool              `json:"optional"`
    UnStoreable   bool              `json:"unstoreable"`
    Transient     bool              `json:"transient"`
    MinLen        int               `json:"minLen"`
    Methods       []string          `json:"methods"`
    Info          map[string]string `json:"info"`
}

type ChallengeSpec Uses

type ChallengeSpec struct {
    ID          string            `json:"id"`
    Description string            `json:"description"`
    Type        ChallengeType     `json:"type"`
    Secure      bool              `json:"secure"`
    UnStoreable bool              `json:"unstoreable"`
    Optional    bool              `json:"optional"`
    Methods     []string          `json:"methods,omitempty"`
    Info        map[string]string `json:"info,omitempty"`
}

type ChallengeType Uses

type ChallengeType string
const (
    ChallengeTypeAlpha        ChallengeType = "alpha"
    ChallengeTypeNumeric      ChallengeType = "numeric"
    ChallengeTypeAlphaNumeric ChallengeType = "alphanumeric"
)

type Client Uses

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

Client is the base client used for interacting with services that do not require authentication. Use Login to initiate a developer session. It is safe for concurrent use by multiple goroutines.

func New Uses

func New(client *http.Client, addr string, opts ...ClientOption) *Client

New creates a new client that will use the supplied HTTP client and connect via the specified API host address.

func (*Client) CreateDeveloper Uses

func (c *Client) CreateDeveloper(email, password string) *DeveloperCreateReq

CreateDeveloper prepares and returns a request to create a developer account for the Bankrs API. Sending a successful request will return a new client that allows access to services requiring a valid developer session.

func (*Client) Login Uses

func (c *Client) Login(email, password string) *DeveloperLoginReq

Login prepares and returns a request to log a developer into the Bankrs API. Sending a successful request will return a new client that allows access to services requiring a valid developer session.

func (*Client) LostPassword Uses

func (c *Client) LostPassword(email string) *LostPasswordReq

LostPassword prepares and returns a request to start the lost password process.

func (*Client) ResetPassword Uses

func (c *Client) ResetPassword(password string, token string) *ResetPasswordReq

ResetPassword prepares and returns a request to reset a lost password.

func (*Client) WithApplicationKey Uses

func (c *Client) WithApplicationKey(applicationKey string) *AppClient

WithApplicationKey creates an AppClient with the supplied application ID, copying options set on the receiver.

func (*Client) WithDeveloperToken Uses

func (c *Client) WithDeveloperToken(token string) *DevClient

WithDeveloperToken creates a DevClient with the supplied developer token, copying options set on the receiver.

type ClientOption Uses

type ClientOption func(*Client)

func Environment Uses

func Environment(environment string) ClientOption

Environment is a client option that may be used to set the X-Environment header used by the client.

func UserAgent Uses

func UserAgent(ua string) ClientOption

UserAgent is a client option that may be used to add information to the user agent header used by the client.

func WithRetryPolicy Uses

func WithRetryPolicy(policy RetryPolicy) ClientOption

WithRetryPolicy is a client option that may be used to set the retry policy used by the client.

type Consent struct {
    ID               string            `json:"id"`
    ObjectType       ConsentObjectType `json:"object_type"`
    ObjectID         string            `json:"object_id"`
    Status           ConsentStatus     `json:"status"`
    StatusChangeTime time.Time         `json:"status_change_time"`
    Expiration       time.Time         `json:"expiration"`
    AuthMethod       ConsentAuthMethod `json:"auth_method"`
    AuthURL          string            `json:"auth_url"`
    AuthMessage      string            `json:"auth_message"`
}

type ConsentAuthMethod Uses

type ConsentAuthMethod string
const (
    OAuth    ConsentAuthMethod = "oauth"
    Redirect ConsentAuthMethod = "redirect"
    External ConsentAuthMethod = "external"
    Login    ConsentAuthMethod = "login"
)

type ConsentGetReq Uses

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

func (*ConsentGetReq) ClientID Uses

func (r *ConsentGetReq) ClientID(id string) *ConsentGetReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ConsentGetReq) Context Uses

func (r *ConsentGetReq) Context(ctx context.Context) *ConsentGetReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ConsentGetReq) Send Uses

func (r *ConsentGetReq) Send() (*Consent, error)

Send sends the request to get details of a consent.

type ConsentObjectType Uses

type ConsentObjectType string
const (
    ObjectTypeAccess   ConsentObjectType = "access"
    ObjectTypeTransfer ConsentObjectType = "transfer"
)

type ConsentStatus Uses

type ConsentStatus string
const (
    AwaitingAuthorisation ConsentStatus = "awaiting_authorisation"
    Authorised            ConsentStatus = "authorised"
    Rejected              ConsentStatus = "rejected"
    Revoked               ConsentStatus = "revoked"
    Consumed              ConsentStatus = "consumed"
)

type ConsentsService Uses

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

ConsentsService provides access to consent related API services.

func NewConsentsService Uses

func NewConsentsService(u *UserClient) *ConsentsService

func (*ConsentsService) Get Uses

func (j *ConsentsService) Get(id string) *ConsentGetReq

Get returns a request that may be used to get the details of a consent.

type Counterparty Uses

type Counterparty struct {
    Name     string     `json:"name"`
    Account  AccountRef `json:"account,omitempty"`
    Merchant *Merchant  `json:"merchant,omitempty"`
}

type CreateAppKeyReq Uses

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

func (*CreateAppKeyReq) ClientID Uses

func (r *CreateAppKeyReq) ClientID(id string) *CreateAppKeyReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*CreateAppKeyReq) Context Uses

func (r *CreateAppKeyReq) Context(ctx context.Context) *CreateAppKeyReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*CreateAppKeyReq) Send Uses

func (r *CreateAppKeyReq) Send() (*ApplicationKey, error)

type CreateApplicationsReq Uses

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

func (*CreateApplicationsReq) ClientID Uses

func (r *CreateApplicationsReq) ClientID(id string) *CreateApplicationsReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*CreateApplicationsReq) Context Uses

func (r *CreateApplicationsReq) Context(ctx context.Context) *CreateApplicationsReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*CreateApplicationsReq) Send Uses

func (r *CreateApplicationsReq) Send() (*ApplicationMetadata, error)

type CreateCredentialReq Uses

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

func (*CreateCredentialReq) ClientID Uses

func (r *CreateCredentialReq) ClientID(id string) *CreateCredentialReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*CreateCredentialReq) Context Uses

func (r *CreateCredentialReq) Context(ctx context.Context) *CreateCredentialReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*CreateCredentialReq) Send Uses

func (r *CreateCredentialReq) Send() (string, error)

type CreateRecurringTransferReq Uses

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

func (*CreateRecurringTransferReq) ChallengeAnswer Uses

func (r *CreateRecurringTransferReq) ChallengeAnswer(answer ChallengeAnswer) *CreateRecurringTransferReq

ChallengeAnswer adds an answer to one of the authorisation challenges required to complete the transfer.

func (*CreateRecurringTransferReq) ClientID Uses

func (r *CreateRecurringTransferReq) ClientID(id string) *CreateRecurringTransferReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*CreateRecurringTransferReq) Context Uses

func (r *CreateRecurringTransferReq) Context(ctx context.Context) *CreateRecurringTransferReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*CreateRecurringTransferReq) Description Uses

func (r *CreateRecurringTransferReq) Description(s string) *CreateRecurringTransferReq

Description sets a human readable description for the transfer.

func (*CreateRecurringTransferReq) EntryDate Uses

func (r *CreateRecurringTransferReq) EntryDate(date time.Time) *CreateRecurringTransferReq

EntryDate sets the desired date for the transfer to be placed. It cannot be a date in the past.

func (*CreateRecurringTransferReq) Send Uses

func (r *CreateRecurringTransferReq) Send() (*RecurringTransfer, error)

Send sends the request to create a money transfer.

type CreateTransferReq Uses

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

func (*CreateTransferReq) ChallengeAnswer Uses

func (r *CreateTransferReq) ChallengeAnswer(answer ChallengeAnswer) *CreateTransferReq

ChallengeAnswer adds an answer to one of the authorisation challenges required to complete the transfer.

func (*CreateTransferReq) ClientID Uses

func (r *CreateTransferReq) ClientID(id string) *CreateTransferReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*CreateTransferReq) Context Uses

func (r *CreateTransferReq) Context(ctx context.Context) *CreateTransferReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*CreateTransferReq) Description Uses

func (r *CreateTransferReq) Description(s string) *CreateTransferReq

Description sets a human readable description for the transfer.

func (*CreateTransferReq) EntryDate Uses

func (r *CreateTransferReq) EntryDate(date time.Time) *CreateTransferReq

EntryDate sets the desired date for the transfer to be placed. It cannot be a date in the past.

func (*CreateTransferReq) Send Uses

func (r *CreateTransferReq) Send() (*Transfer, error)

Send sends the request to create a money transfer.

type CreateWebhookReq Uses

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

func (*CreateWebhookReq) ClientID Uses

func (r *CreateWebhookReq) ClientID(id string) *CreateWebhookReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*CreateWebhookReq) Context Uses

func (r *CreateWebhookReq) Context(ctx context.Context) *CreateWebhookReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*CreateWebhookReq) Send Uses

func (r *CreateWebhookReq) Send() (string, error)

type Credential Uses

type Credential struct {
    ID          string            `json:"id"`
    Provider    string            `json:"provider"`
    CreatedAt   time.Time         `json:"created_at"`
    Credentials map[string]string `json:"keys"`
}

type CredentialEntry Uses

type CredentialEntry struct {
    ID        string    `json:"id"`
    Provider  string    `json:"provider"`
    CreatedAt time.Time `json:"created_at"`
}

type CredentialProvider Uses

type CredentialProvider struct {
    Name string   `json:"name"`
    Keys []string `json:"keys"`
}

type CredentialProviderPage Uses

type CredentialProviderPage struct {
    Providers []CredentialProvider `json:"providers"`
}

type CredentialsPage Uses

type CredentialsPage struct {
    Entries []CredentialEntry `json:"entries,omitempty"`
}

type CredentialsService Uses

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

CredentialsService provides access to credential related API services that also require an authenticated developer session.

func NewCredentialsService Uses

func NewCredentialsService(c *DevClient) *CredentialsService

func (*CredentialsService) Delete Uses

func (d *CredentialsService) Delete(credentialID string) *DeleteCredentialReq

Delete returns a request that may be used to get a delete a set of stored credentials.

func (*CredentialsService) Get Uses

func (d *CredentialsService) Get(credentialID string) *GetCredentialReq

Get returns a request that may be used to get a set of stored credentials.

func (*CredentialsService) ListProviders Uses

func (d *CredentialsService) ListProviders() *ListCredentialProvidersReq

ListProviders returns a request that may be used to get a list of supported providers for credential sets.

func (*CredentialsService) Update Uses

func (d *CredentialsService) Update(credentialID string, credentials map[string]string) *UpdateCredentialReq

Update returns a request that may be used to update a set of stored credentials.

type DailyMerchantsStats Uses

type DailyMerchantsStats struct {
    Name  string `json:"name"`
    Value int64  `json:"value"`
}

type DailyProvidersStats Uses

type DailyProvidersStats struct {
    Name  string `json:"name"`
    Value int64  `json:"value"`
}

type DailyRequestsStats Uses

type DailyRequestsStats struct {
    Date          string `json:"date"`
    RequestsTotal int64  `json:"requests_total"`
}

type DailyTransfersStats Uses

type DailyTransfersStats struct {
    Date string             `json:"date"`
    Out  []StatsMoneyAmount `json:"out"`
}

type DailyUsersStats Uses

type DailyUsersStats struct {
    Date     string `json:"date"`
    NewUsers int64  `json:"new_users"`
}

type DeleteAccessReq Uses

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

func (*DeleteAccessReq) ClientID Uses

func (r *DeleteAccessReq) ClientID(id string) *DeleteAccessReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*DeleteAccessReq) Context Uses

func (r *DeleteAccessReq) Context(ctx context.Context) *DeleteAccessReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*DeleteAccessReq) Send Uses

func (r *DeleteAccessReq) Send() (int64, error)

Send sends the request to get details of a bank access.

type DeleteAppKeyReq Uses

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

func (*DeleteAppKeyReq) ClientID Uses

func (r *DeleteAppKeyReq) ClientID(id string) *DeleteAppKeyReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*DeleteAppKeyReq) Context Uses

func (r *DeleteAppKeyReq) Context(ctx context.Context) *DeleteAppKeyReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*DeleteAppKeyReq) Send Uses

func (r *DeleteAppKeyReq) Send() error

type DeleteApplicationsReq Uses

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

func (*DeleteApplicationsReq) ClientID Uses

func (r *DeleteApplicationsReq) ClientID(id string) *DeleteApplicationsReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*DeleteApplicationsReq) Context Uses

func (r *DeleteApplicationsReq) Context(ctx context.Context) *DeleteApplicationsReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*DeleteApplicationsReq) Send Uses

func (r *DeleteApplicationsReq) Send() error

type DeleteCredentialReq Uses

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

func (*DeleteCredentialReq) ClientID Uses

func (r *DeleteCredentialReq) ClientID(id string) *DeleteCredentialReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*DeleteCredentialReq) Context Uses

func (r *DeleteCredentialReq) Context(ctx context.Context) *DeleteCredentialReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*DeleteCredentialReq) Send Uses

func (r *DeleteCredentialReq) Send() error

type DeleteRepeatedTransactionReq Uses

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

func (*DeleteRepeatedTransactionReq) ChallengeAnswer Uses

func (r *DeleteRepeatedTransactionReq) ChallengeAnswer(answer ChallengeAnswer) *DeleteRepeatedTransactionReq

ChallengeAnswer adds an answer to one of the authorisation challenges required to complete the deletion.

func (*DeleteRepeatedTransactionReq) ClientID Uses

func (r *DeleteRepeatedTransactionReq) ClientID(id string) *DeleteRepeatedTransactionReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*DeleteRepeatedTransactionReq) Context Uses

func (r *DeleteRepeatedTransactionReq) Context(ctx context.Context) *DeleteRepeatedTransactionReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*DeleteRepeatedTransactionReq) Send Uses

func (r *DeleteRepeatedTransactionReq) Send() (*RecurringTransfer, error)

Send sends the request to delete a repeated transaction. It returns information about the long running recurring transfer job that may be used to track and progress the deletion. TODO: This looks wrong

type DeleteWebhookReq Uses

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

func (*DeleteWebhookReq) ClientID Uses

func (r *DeleteWebhookReq) ClientID(id string) *DeleteWebhookReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*DeleteWebhookReq) Context Uses

func (r *DeleteWebhookReq) Context(ctx context.Context) *DeleteWebhookReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*DeleteWebhookReq) Send Uses

func (r *DeleteWebhookReq) Send() error

type DeletedUser Uses

type DeletedUser struct {
    DeletedUserID string `json:"deleted_user_id"`
}

type DevClient Uses

type DevClient struct {
    Applications    *ApplicationsService
    ApplicationKeys *ApplicationKeysService
    Stats           *StatsService
    Webhooks        *WebhooksService
    Credentials     *CredentialsService
    // contains filtered or unexported fields
}

DevClient is a client used for interacting with services that require a valid developer session. It is safe for concurrent use by multiple goroutines.

func NewDevClient Uses

func NewDevClient(client *http.Client, addr string, token string) *DevClient

NewDevClient creates a new developer client, ready to use.

func (*DevClient) ChangePassword Uses

func (d *DevClient) ChangePassword(old, new string) *DeveloperChangePasswordReq

ChangePassword prepares and returns a request to change a developer's password.

func (*DevClient) Delete Uses

func (d *DevClient) Delete() *DeveloperDeleteReq

Delete prepares and returns a request to delete the developer account and all it's associated data in all environments. Once this request has been sent the client is no longer valid and should not be used.

func (*DevClient) Logout Uses

func (d *DevClient) Logout() *DeveloperLogoutReq

Logout prepares and returns a request to log a developer out of the Bankrs API. Once this request has been sent the client is no longer valid and should not be used.

func (*DevClient) Profile Uses

func (d *DevClient) Profile() *DeveloperProfileReq

Profile retrieves the developer's profile.

func (*DevClient) SessionToken Uses

func (d *DevClient) SessionToken() string

SessionToken returns the current session token.

func (*DevClient) SetProfile Uses

func (d *DevClient) SetProfile(profile *DeveloperProfile) *DeveloperSetProfileReq

SetProfile sets the developer's profile.

type DevUserInfo Uses

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

type DevUserInfoReq Uses

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

func (*DevUserInfoReq) ClientID Uses

func (r *DevUserInfoReq) ClientID(id string) *DevUserInfoReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*DevUserInfoReq) Context Uses

func (r *DevUserInfoReq) Context(ctx context.Context) *DevUserInfoReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*DevUserInfoReq) Send Uses

func (r *DevUserInfoReq) Send() (*DevUserInfo, error)

type DeveloperChangePasswordReq Uses

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

func (*DeveloperChangePasswordReq) ClientID Uses

func (r *DeveloperChangePasswordReq) ClientID(id string) *DeveloperChangePasswordReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*DeveloperChangePasswordReq) Context Uses

func (r *DeveloperChangePasswordReq) Context(ctx context.Context) *DeveloperChangePasswordReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*DeveloperChangePasswordReq) Send Uses

func (r *DeveloperChangePasswordReq) Send() error

Send sends the request to change the developer's password.

type DeveloperCreateReq Uses

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

func (*DeveloperCreateReq) ClientID Uses

func (r *DeveloperCreateReq) ClientID(id string) *DeveloperCreateReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*DeveloperCreateReq) Context Uses

func (r *DeveloperCreateReq) Context(ctx context.Context) *DeveloperCreateReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*DeveloperCreateReq) Send Uses

func (r *DeveloperCreateReq) Send() (*DevClient, error)

Send sends the create request and returns a client that can be used to access services within the developer's session.

type DeveloperCredentials Uses

type DeveloperCredentials struct {
    Email    string `json:"email"`
    Password string `json:"password"`
    OTP      string `json:"otp"`
}

type DeveloperDeleteReq Uses

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

func (*DeveloperDeleteReq) ClientID Uses

func (r *DeveloperDeleteReq) ClientID(id string) *DeveloperDeleteReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*DeveloperDeleteReq) Context Uses

func (r *DeveloperDeleteReq) Context(ctx context.Context) *DeveloperDeleteReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*DeveloperDeleteReq) Send Uses

func (r *DeveloperDeleteReq) Send() error

Send sends the request to delete developer. Once this request has been sent the developer client should not be used again.

type DeveloperLoginReq Uses

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

func (*DeveloperLoginReq) ClientID Uses

func (r *DeveloperLoginReq) ClientID(id string) *DeveloperLoginReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*DeveloperLoginReq) Context Uses

func (r *DeveloperLoginReq) Context(ctx context.Context) *DeveloperLoginReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*DeveloperLoginReq) Send Uses

func (r *DeveloperLoginReq) Send() (*DevClient, error)

Send sends the login request and returns a client that can be used to access services within the developer's session.

type DeveloperLogoutReq Uses

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

func (*DeveloperLogoutReq) ClientID Uses

func (r *DeveloperLogoutReq) ClientID(id string) *DeveloperLogoutReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*DeveloperLogoutReq) Context Uses

func (r *DeveloperLogoutReq) Context(ctx context.Context) *DeveloperLogoutReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*DeveloperLogoutReq) Send Uses

func (r *DeveloperLogoutReq) Send() error

Send sends the request to log the developer out and end the session. Once this request has been sent the developer client should not be used again.

type DeveloperProfile Uses

type DeveloperProfile struct {
    Company             string          `json:"company"`
    HasProductionAccess bool            `json:"has_production_access"`
    Confirmed           bool            `json:"confirmed"`
    ExpiresAt           string          `json:"expires_at,omitempty"`
    LinkedAccounts      []LinkedAccount `json:"linked_accounts,omitempty"`
    LinkedTeam          []LinkedTeam    `json:"linked_teams,omitempty"`
}

type DeveloperProfileReq Uses

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

func (*DeveloperProfileReq) ClientID Uses

func (r *DeveloperProfileReq) ClientID(id string) *DeveloperProfileReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*DeveloperProfileReq) Context Uses

func (r *DeveloperProfileReq) Context(ctx context.Context) *DeveloperProfileReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*DeveloperProfileReq) Send Uses

func (r *DeveloperProfileReq) Send() (*DeveloperProfile, error)

Send sends the request to retrieve the developer's profile.

type DeveloperSetProfileReq Uses

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

func (*DeveloperSetProfileReq) ClientID Uses

func (r *DeveloperSetProfileReq) ClientID(id string) *DeveloperSetProfileReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*DeveloperSetProfileReq) Context Uses

func (r *DeveloperSetProfileReq) Context(ctx context.Context) *DeveloperSetProfileReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*DeveloperSetProfileReq) Send Uses

func (r *DeveloperSetProfileReq) Send() error

Send sends the request to retrieve the developer's profile.

type Error Uses

type Error struct {
    Errors     []ErrorItem `json:"errors"` // error messages reported by the service
    StatusCode int         // the HTTP status code from the service response
    Status     string      // the HTTP status line from the service response
    Header     http.Header // the HTTP headers from the service response
    RequestID  string      // the ID of the request that generated the error
    URL        string      // the request URL
}

Error contains an error response from a service.

func (*Error) Error Uses

func (e *Error) Error() string

type ErrorItem Uses

type ErrorItem struct {
    Code    string              `json:"code"`    // standard error code
    Message string              `json:"message"` // additional information about the error
    Payload map[string][]string `json:"payload,omitempty"`
}

ErrorItem is a detailed error code & message.

func (*ErrorItem) Description Uses

func (ei *ErrorItem) Description() string

type Frequency Uses

type Frequency string
const (
    FrequencyOnce    Frequency = "once"
    FrequencyDaily   Frequency = "daily"
    FrequencyWeekly  Frequency = "weekly"
    FrequencyMonthly Frequency = "monthly"
    FrequencyYearly  Frequency = "yearly"
)

type GetAccessReq Uses

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

func (*GetAccessReq) ClientID Uses

func (r *GetAccessReq) ClientID(id string) *GetAccessReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*GetAccessReq) Context Uses

func (r *GetAccessReq) Context(ctx context.Context) *GetAccessReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*GetAccessReq) Send Uses

func (r *GetAccessReq) Send() (*Access, error)

Send sends the request to get details of a bank access.

type GetAccountReq Uses

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

func (*GetAccountReq) ClientID Uses

func (r *GetAccountReq) ClientID(id string) *GetAccountReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*GetAccountReq) Context Uses

func (r *GetAccountReq) Context(ctx context.Context) *GetAccountReq

func (*GetAccountReq) Send Uses

func (r *GetAccountReq) Send() (*Account, error)

type GetApplicationSettingsReq Uses

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

func (*GetApplicationSettingsReq) ClientID Uses

func (r *GetApplicationSettingsReq) ClientID(id string) *GetApplicationSettingsReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*GetApplicationSettingsReq) Context Uses

func (r *GetApplicationSettingsReq) Context(ctx context.Context) *GetApplicationSettingsReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*GetApplicationSettingsReq) Send Uses

func (r *GetApplicationSettingsReq) Send() (*ApplicationSettings, error)

Send sends the request to retrieve the developer's profile.

type GetCredentialReq Uses

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

func (*GetCredentialReq) ClientID Uses

func (r *GetCredentialReq) ClientID(id string) *GetCredentialReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*GetCredentialReq) Context Uses

func (r *GetCredentialReq) Context(ctx context.Context) *GetCredentialReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*GetCredentialReq) Send Uses

func (r *GetCredentialReq) Send() (*Credential, error)

type GetRepeatedTransactionReq Uses

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

func (*GetRepeatedTransactionReq) ClientID Uses

func (r *GetRepeatedTransactionReq) ClientID(id string) *GetRepeatedTransactionReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*GetRepeatedTransactionReq) Context Uses

func (r *GetRepeatedTransactionReq) Context(ctx context.Context) *GetRepeatedTransactionReq

func (*GetRepeatedTransactionReq) Send Uses

func (r *GetRepeatedTransactionReq) Send() (*RepeatedTransaction, error)

type GetScheduledTransactionReq Uses

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

func (*GetScheduledTransactionReq) ClientID Uses

func (r *GetScheduledTransactionReq) ClientID(id string) *GetScheduledTransactionReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*GetScheduledTransactionReq) Context Uses

func (r *GetScheduledTransactionReq) Context(ctx context.Context) *GetScheduledTransactionReq

func (*GetScheduledTransactionReq) Send Uses

func (r *GetScheduledTransactionReq) Send() (*Transaction, error)

type GetTransactionReq Uses

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

func (*GetTransactionReq) ClientID Uses

func (r *GetTransactionReq) ClientID(id string) *GetTransactionReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*GetTransactionReq) Context Uses

func (r *GetTransactionReq) Context(ctx context.Context) *GetTransactionReq

func (*GetTransactionReq) Send Uses

func (r *GetTransactionReq) Send() (*Transaction, error)

type GetWebhookReq Uses

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

func (*GetWebhookReq) ClientID Uses

func (r *GetWebhookReq) ClientID(id string) *GetWebhookReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*GetWebhookReq) Context Uses

func (r *GetWebhookReq) Context(ctx context.Context) *GetWebhookReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*GetWebhookReq) Send Uses

func (r *GetWebhookReq) Send() (*Webhook, error)

type IBANAccount Uses

type IBANAccount struct {
    IBAN     string `json:"IBAN"`     // the validated IBAN
    Provider string `json:"provider"` // the authoritative provider, IBO for IBANs
}

type IBANBank Uses

type IBANBank struct {
    ID             string `json:"id"`              // the bank identity assigned by the identity provider
    Label          string `json:"label"`           // the bank name
    Country        string `json:"country"`         // the country (e.g. DE)
    Provider       string `json:"provider"`        //  the identity provider (e.g. BIC)
    ServiceContext string `json:"service_context"` // the service context, (e.g. SEPA)
}

type IBANDetails Uses

type IBANDetails struct {
    Account IBANAccount `json:"acc_ref"`
    Banks   []IBANBank  `json:"fis"`
}

type IBANService Uses

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

IBANService provides access to IBAN related API services.

func NewIBANService Uses

func NewIBANService(c *AppClient) *IBANService

func (*IBANService) Validate Uses

func (a *IBANService) Validate(iban string) *ValidateIBANReq

Validate returns a request that may be used to validate an IBAN.

type Job Uses

type Job struct {
    URI string `json:"uri"`
}

type JobAccess Uses

type JobAccess struct {
    ID         int64        `json:"id,omitempty"`
    ProviderID string       `json:"provider_id,omitempty"`
    Name       string       `json:"name,omitempty"`
    Accounts   []JobAccount `json:"accounts,omitempty"`
}

type JobAccount Uses

type JobAccount struct {
    ID         int64     `json:"id,omitempty"`
    Name       string    `json:"name"`
    Number     string    `json:"number"`
    IBAN       string    `json:"iban"`
    ProviderID string    `json:"provider_id,omitempty"`
    Errors     []Problem `json:"errors"`
}

type JobAnswerReq Uses

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

func (*JobAnswerReq) ChallengeAnswer Uses

func (r *JobAnswerReq) ChallengeAnswer(answer ChallengeAnswer) *JobAnswerReq

ChallengeAnswer adds an answer to one of the authorisation challenges required to complete the job.

func (*JobAnswerReq) ClientID Uses

func (r *JobAnswerReq) ClientID(id string) *JobAnswerReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*JobAnswerReq) Context Uses

func (r *JobAnswerReq) Context(ctx context.Context) *JobAnswerReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*JobAnswerReq) Send Uses

func (r *JobAnswerReq) Send() error

Send sends the request to get answer a challenge needed by a job.

type JobCancelReq Uses

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

func (*JobCancelReq) ClientID Uses

func (r *JobCancelReq) ClientID(id string) *JobCancelReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*JobCancelReq) Context Uses

func (r *JobCancelReq) Context(ctx context.Context) *JobCancelReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*JobCancelReq) Send Uses

func (r *JobCancelReq) Send() error

Send sends the request to cancel a job.

type JobConsent Uses

type JobConsent struct {
    ID          string `json:"id,omitempty"`
    AuthURL     string `json:"auth_url,omitempty"`
    AuthMessage string `json:"auth_message,omitempty"`
}

type JobGetReq Uses

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

func (*JobGetReq) ClientID Uses

func (r *JobGetReq) ClientID(id string) *JobGetReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*JobGetReq) Context Uses

func (r *JobGetReq) Context(ctx context.Context) *JobGetReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*JobGetReq) Send Uses

func (r *JobGetReq) Send() (*JobStatus, error)

Send sends the request to get details of a job.

type JobStage Uses

type JobStage string
const (
    JobStageUnauthenticated JobStage = "unauthenticated"
    JobStageAuthenticated   JobStage = "authenticated"
    JobStageChallenge       JobStage = "challenge"
    JobStageImported        JobStage = "imported"
    JobStageCancelled       JobStage = "cancelled"
    JobStageProblem         JobStage = "problem"
    JobStageConsent         JobStage = "consent"
)

type JobStatus Uses

type JobStatus struct {
    Finished  bool        `json:"finished"`
    Stage     JobStage    `json:"stage"`
    Challenge *Challenge  `json:"challenge,omitempty"`
    URI       string      `json:"uri,omitempty"`
    Errors    []Problem   `json:"errors,omitempty"`
    Access    *JobAccess  `json:"access,omitempty"`
    Consent   *JobConsent `json:"consent,omitempty"`
}

type JobsService Uses

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

JobsService provides access to jobs related API services.

func NewJobsService Uses

func NewJobsService(u *UserClient) *JobsService

func (*JobsService) Answer Uses

func (j *JobsService) Answer(uri string) *JobAnswerReq

Answer returns a request that may be used to answer a challenge needed by a job

func (*JobsService) Cancel Uses

func (j *JobsService) Cancel(uri string) *JobCancelReq

Cancel returns a request that may be used to cancel a job.

func (*JobsService) Get Uses

func (j *JobsService) Get(uri string) *JobGetReq

Get returns a request that may be used to get the details of a job.

type LinkedAccount Uses

type LinkedAccount struct {
    Type     LinkedAccountType `json:"type"`
    ID       string            `json:"id"`
    Title    string            `json:"title"`
    UserName string            `json:"user_name"`
    SyncTime string            `json:"sync_time"`
}

type LinkedAccountType Uses

type LinkedAccountType int
const (
    LinkedAccountTypeRegular       LinkedAccountType = 0
    LinkedAccountTypeAuthorization LinkedAccountType = 1
)

type LinkedTeam Uses

type LinkedTeam struct {
    ID     string `json:"id"`
    Name   string `json:"name"`
    Active bool   `json:"active"`
    Owner  bool   `json:"owner"`
}

type ListAccessesReq Uses

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

func (*ListAccessesReq) ClientID Uses

func (r *ListAccessesReq) ClientID(id string) *ListAccessesReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ListAccessesReq) Context Uses

func (r *ListAccessesReq) Context(ctx context.Context) *ListAccessesReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ListAccessesReq) Send Uses

func (r *ListAccessesReq) Send() (*AccessPage, error)

type ListAccountsReq Uses

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

func (*ListAccountsReq) ClientID Uses

func (r *ListAccountsReq) ClientID(id string) *ListAccountsReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ListAccountsReq) Context Uses

func (r *ListAccountsReq) Context(ctx context.Context) *ListAccountsReq

func (*ListAccountsReq) Send Uses

func (r *ListAccountsReq) Send() (*AccountPage, error)

type ListAppKeysReq Uses

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

func (*ListAppKeysReq) ClientID Uses

func (r *ListAppKeysReq) ClientID(id string) *ListAppKeysReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ListAppKeysReq) Context Uses

func (r *ListAppKeysReq) Context(ctx context.Context) *ListAppKeysReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ListAppKeysReq) Send Uses

func (r *ListAppKeysReq) Send() (*ApplicationKeyPage, error)

type ListApplicationsReq Uses

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

func (*ListApplicationsReq) ClientID Uses

func (r *ListApplicationsReq) ClientID(id string) *ListApplicationsReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ListApplicationsReq) Context Uses

func (r *ListApplicationsReq) Context(ctx context.Context) *ListApplicationsReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ListApplicationsReq) Send Uses

func (r *ListApplicationsReq) Send() (*ApplicationPage, error)

type ListCredentialProvidersReq Uses

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

func (*ListCredentialProvidersReq) ClientID Uses

func (r *ListCredentialProvidersReq) ClientID(id string) *ListCredentialProvidersReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ListCredentialProvidersReq) Context Uses

func (r *ListCredentialProvidersReq) Context(ctx context.Context) *ListCredentialProvidersReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ListCredentialProvidersReq) Send Uses

func (r *ListCredentialProvidersReq) Send() (*CredentialProviderPage, error)

type ListCredentialsReq Uses

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

func (*ListCredentialsReq) ClientID Uses

func (r *ListCredentialsReq) ClientID(id string) *ListCredentialsReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ListCredentialsReq) Context Uses

func (r *ListCredentialsReq) Context(ctx context.Context) *ListCredentialsReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ListCredentialsReq) Send Uses

func (r *ListCredentialsReq) Send() (*CredentialsPage, error)

type ListDevUsersReq Uses

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

func (*ListDevUsersReq) ClientID Uses

func (r *ListDevUsersReq) ClientID(id string) *ListDevUsersReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ListDevUsersReq) Context Uses

func (r *ListDevUsersReq) Context(ctx context.Context) *ListDevUsersReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ListDevUsersReq) Cursor Uses

func (r *ListDevUsersReq) Cursor(cursor string) *ListDevUsersReq

func (*ListDevUsersReq) Limit Uses

func (r *ListDevUsersReq) Limit(v int) *ListDevUsersReq

func (*ListDevUsersReq) Send Uses

func (r *ListDevUsersReq) Send() (*UserListPage, error)

type ListRepeatedTransactionsReq Uses

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

func (*ListRepeatedTransactionsReq) AccessID Uses

func (r *ListRepeatedTransactionsReq) AccessID(id int64) *ListRepeatedTransactionsReq

func (*ListRepeatedTransactionsReq) AccountID Uses

func (r *ListRepeatedTransactionsReq) AccountID(id int64) *ListRepeatedTransactionsReq

func (*ListRepeatedTransactionsReq) ClientID Uses

func (r *ListRepeatedTransactionsReq) ClientID(id string) *ListRepeatedTransactionsReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ListRepeatedTransactionsReq) Context Uses

func (r *ListRepeatedTransactionsReq) Context(ctx context.Context) *ListRepeatedTransactionsReq

func (*ListRepeatedTransactionsReq) Limit Uses

func (r *ListRepeatedTransactionsReq) Limit(limit int) *ListRepeatedTransactionsReq

func (*ListRepeatedTransactionsReq) Offset Uses

func (r *ListRepeatedTransactionsReq) Offset(offset int) *ListRepeatedTransactionsReq

func (*ListRepeatedTransactionsReq) Send Uses

func (r *ListRepeatedTransactionsReq) Send() (*RepeatedTransactionPage, error)

type ListScheduledTransactionsReq Uses

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

func (*ListScheduledTransactionsReq) AccessID Uses

func (r *ListScheduledTransactionsReq) AccessID(id int64) *ListScheduledTransactionsReq

func (*ListScheduledTransactionsReq) AccountID Uses

func (r *ListScheduledTransactionsReq) AccountID(id int64) *ListScheduledTransactionsReq

func (*ListScheduledTransactionsReq) ClientID Uses

func (r *ListScheduledTransactionsReq) ClientID(id string) *ListScheduledTransactionsReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ListScheduledTransactionsReq) Context Uses

func (r *ListScheduledTransactionsReq) Context(ctx context.Context) *ListScheduledTransactionsReq

func (*ListScheduledTransactionsReq) Send Uses

func (r *ListScheduledTransactionsReq) Send() ([]Transaction, error)

type ListTransactionsReq Uses

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

func (*ListTransactionsReq) AccessID Uses

func (r *ListTransactionsReq) AccessID(id int64) *ListTransactionsReq

func (*ListTransactionsReq) AccountID Uses

func (r *ListTransactionsReq) AccountID(id int64) *ListTransactionsReq

func (*ListTransactionsReq) ClientID Uses

func (r *ListTransactionsReq) ClientID(id string) *ListTransactionsReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ListTransactionsReq) Context Uses

func (r *ListTransactionsReq) Context(ctx context.Context) *ListTransactionsReq

func (*ListTransactionsReq) Limit Uses

func (r *ListTransactionsReq) Limit(limit int) *ListTransactionsReq

func (*ListTransactionsReq) Offset Uses

func (r *ListTransactionsReq) Offset(offset int) *ListTransactionsReq

func (*ListTransactionsReq) Send Uses

func (r *ListTransactionsReq) Send() (*TransactionPage, error)

func (*ListTransactionsReq) Since Uses

func (r *ListTransactionsReq) Since(t time.Time) *ListTransactionsReq

type ListWebhookReq Uses

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

func (*ListWebhookReq) ClientID Uses

func (r *ListWebhookReq) ClientID(id string) *ListWebhookReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ListWebhookReq) Context Uses

func (r *ListWebhookReq) Context(ctx context.Context) *ListWebhookReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ListWebhookReq) Send Uses

func (r *ListWebhookReq) Send() (*WebhookPage, error)

type LostPasswordReq Uses

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

func (*LostPasswordReq) ClientID Uses

func (r *LostPasswordReq) ClientID(id string) *LostPasswordReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*LostPasswordReq) Context Uses

func (r *LostPasswordReq) Context(ctx context.Context) *LostPasswordReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*LostPasswordReq) Send Uses

func (r *LostPasswordReq) Send() error

Send sends the lost password request.

type Merchant Uses

type Merchant struct {
    Name string `json:"name"`
}

type MerchantsStats Uses

type MerchantsStats struct {
    From   string                `json:"from_date"`
    To     string                `json:"to_date"`
    Domain string                `json:"domain"`
    Stats  []DailyMerchantsStats `json:"stats"`
}

type MoneyAmount Uses

type MoneyAmount struct {
    Currency string `json:"currency"`
    Value    string `json:"value"`
}

type NameValue Uses

type NameValue struct {
    Name  string `json:"name"`
    Value int64  `json:"value"`
}

type OriginalAmount Uses

type OriginalAmount struct {
    Value        *MoneyAmount `json:"value"`
    ExchangeRate string       `json:"exchange_rate"`
}

type PageParams Uses

type PageParams struct {
    Cursor string `json:"cursor"`
    Limit  int    `json:"limit"`
}

type PaymentTransferCancelParams Uses

type PaymentTransferCancelParams struct {
    ID      string `json:"id"`
    Version int    `json:"version"`
}

type Period Uses

type Period struct {
    Type   string `json:"type"`
    Repeat int    `json:"repeat"`
}

type Problem Uses

type Problem struct {
    Domain                     string                 `json:"domain"`
    Code                       string                 `json:"code"`
    Info                       map[string]interface{} `json:"info"`
    ContainsPrivateInformation bool                   `json:"contains_private_information"`
}

type ProcessRecurringTransferReq Uses

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

func (*ProcessRecurringTransferReq) ChallengeAnswer Uses

func (r *ProcessRecurringTransferReq) ChallengeAnswer(answer ChallengeAnswer) *ProcessRecurringTransferReq

ChallengeAnswer adds an answer to one of the authorisation challenges required to complete the transfer.

func (*ProcessRecurringTransferReq) ClientID Uses

func (r *ProcessRecurringTransferReq) ClientID(id string) *ProcessRecurringTransferReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ProcessRecurringTransferReq) Confirm Uses

func (r *ProcessRecurringTransferReq) Confirm(confirm bool) *ProcessRecurringTransferReq

Confirm sets whether the user has confirmed a transfer that appears to be similar to another that was recently sent.

func (*ProcessRecurringTransferReq) Context Uses

func (r *ProcessRecurringTransferReq) Context(ctx context.Context) *ProcessRecurringTransferReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ProcessRecurringTransferReq) Send Uses

func (r *ProcessRecurringTransferReq) Send() (*RecurringTransfer, error)

Send sends the request to update information and answer challenges for a transfer.

type ProcessTransferReq Uses

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

func (*ProcessTransferReq) ChallengeAnswer Uses

func (r *ProcessTransferReq) ChallengeAnswer(answer ChallengeAnswer) *ProcessTransferReq

ChallengeAnswer adds an answer to one of the authorisation challenges required to complete the transfer.

func (*ProcessTransferReq) ClientID Uses

func (r *ProcessTransferReq) ClientID(id string) *ProcessTransferReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ProcessTransferReq) Confirm Uses

func (r *ProcessTransferReq) Confirm(confirm bool) *ProcessTransferReq

Confirm sets whether the user has confirmed a transfer that appears to be similar to another that was recently sent.

func (*ProcessTransferReq) Context Uses

func (r *ProcessTransferReq) Context(ctx context.Context) *ProcessTransferReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ProcessTransferReq) Send Uses

func (r *ProcessTransferReq) Send() (*Transfer, error)

Send sends the request to update information and answer challenges for a transfer.

type Provider Uses

type Provider struct {
    ID          string             `json:"id"`
    Name        string             `json:"name"`
    Description string             `json:"description"`
    Country     string             `json:"country"`
    URL         string             `json:"url"`
    Address     string             `json:"address"`
    PostalCode  string             `json:"postal_code"`
    Operations  ProviderOperations `json:"operations"`
    Challenges  []ChallengeSpec    `json:"challenges"`
}

type ProviderAllowedOperations Uses

type ProviderAllowedOperations struct {
    PaymentTransfer     bool `json:"transfer"`
    AccountStatement    bool `json:"statement"`
    AccountBalance      bool `json:"balance"`
    CreditCardStatement bool `json:"-"`
    CreditCardBalance   bool `json:"-"`
    CreateRecTrf        bool `json:"create_recurring_transfer"`
    ReadRecTrf          bool `json:"read_recurring_transfer"`
    UpdateRecTrf        bool `json:"update_recurring_transfer"`
    DeleteRecTrf        bool `json:"delete_recurring_transfer"`
    ReadBeneficiaries   bool `json:"beneficiaries"`
}

type ProviderOperations Uses

type ProviderOperations struct {
    Adapter           string                    `json:"adapter"`
    AllowedOperations ProviderAllowedOperations `json:"allowed_operations,omitempty" `
}

type ProviderSearchResult Uses

type ProviderSearchResult struct {
    Score    float64  `json:"score"`
    Provider Provider `json:"provider"`
}

type ProviderSearchResults Uses

type ProviderSearchResults []ProviderSearchResult

type ProvidersGetReq Uses

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

func (*ProvidersGetReq) ClientID Uses

func (r *ProvidersGetReq) ClientID(id string) *ProvidersGetReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ProvidersGetReq) Context Uses

func (r *ProvidersGetReq) Context(ctx context.Context) *ProvidersGetReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ProvidersGetReq) Send Uses

func (r *ProvidersGetReq) Send() (*Provider, error)

Send sends the request to get a single financial provider.

type ProvidersSearchReq Uses

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

func (*ProvidersSearchReq) ClientID Uses

func (r *ProvidersSearchReq) ClientID(id string) *ProvidersSearchReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ProvidersSearchReq) Context Uses

func (r *ProvidersSearchReq) Context(ctx context.Context) *ProvidersSearchReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ProvidersSearchReq) Send Uses

func (r *ProvidersSearchReq) Send() (*ProviderSearchResults, error)

Send sends the request to search providers.

type ProvidersService Uses

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

ProvidersService provides access to financial provider related API services.

func NewProvidersService Uses

func NewProvidersService(a *AppClient) *ProvidersService

func (*ProvidersService) Get Uses

func (c *ProvidersService) Get(id string) *ProvidersGetReq

Get returns a request that may be used to get the details of a single financial provider.

func (*ProvidersService) Search Uses

func (c *ProvidersService) Search(query string) *ProvidersSearchReq

Search returns a request that may be used to search the list of financial providers.

type ProvidersStats Uses

type ProvidersStats struct {
    From   string                `json:"from_date"`
    To     string                `json:"to_date"`
    Domain string                `json:"domain"`
    Stats  []DailyProvidersStats `json:"stats"`
}

type RecurrenceRule Uses

type RecurrenceRule struct {
    Start     time.Time `json:"start"`
    Until     time.Time `json:"until"`
    Frequency Frequency `json:"frequency"`
    Interval  int       `json:"interval"`
    ByDay     int       `json:"by_day"`
}

type RecurringTransfer Uses

type RecurringTransfer struct {
    ID       string           `json:"id"`
    From     TransferAddress  `json:"from"`
    To       TransferAddress  `json:"to"`
    Amount   MoneyAmount      `json:"amount"`
    Usage    string           `json:"usage"`
    Version  int              `json:"version"`
    Step     TransferStep     `json:"step"`
    State    TransferState    `json:"state"`
    Schedule *RecurrenceRule  `json:"schedule,omitempty"`
    Created  time.Time        `json:"created,omitempty"`
    Updated  time.Time        `json:"updated,omitempty"`
    RemoteID string           `json:"remote_id"`
    Errors   []Problem        `json:"errors,omitempty"`
    Consent  *TransferConsent `json:"consent,omitempty"`
}

type RecurringTransferCapabilities Uses

type RecurringTransferCapabilities struct {
    Periods                      []Period `json:"periods"`
    MinimumLeadTimeCreate        int      `json:"minimum_lead_time_create"`
    MaximumLeadTimeCreate        int      `json:"maximum_lead_time_create"`
    MinimumLeadTimeEdit          int      `json:"minimum_lead_time_edit"`
    MaximumLeadTimeEdit          int      `json:"maximum_lead_time_edit"`
    MinimumLeadTimeDelete        int      `json:"minimum_lead_time_delete"`
    MaximumLeadTimeDelete        int      `json:"maximum_lead_time_delete"`
    LastDayOfMonthEnabled        bool     `json:"last_day_of_month_enabled"`
    FirstScheduledDateModifiable bool     `json:"first_scheduled_date_modifiable"`
    TimeUnitModifiable           bool     `json:"time_unit_modifiable"`
    PeriodLengthModifiable       bool     `json:"period_length_modifiable"`
    ScheduledDateModifiable      bool     `json:"scheduled_date_modifiable"`
    LastScheduleDateModifiable   bool     `json:"last_schedule_date_modifiable"`
}

type RecurringTransfersService Uses

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

RecurringTransfersService provides access to recurring money transfer related API services.

func NewRecurringTransfersService Uses

func NewRecurringTransfersService(u *UserClient) *RecurringTransfersService

func (*RecurringTransfersService) Cancel Uses

func (t *RecurringTransfersService) Cancel(id string, version int) *CancelRecurringTransferReq

Cancel returns a request that may be used to cancel an ongoing money transfer.

func (*RecurringTransfersService) Create Uses

func (t *RecurringTransfersService) Create(from int64, to TransferAddress, amount MoneyAmount, rule RecurrenceRule, usage string) *CreateRecurringTransferReq

Create returns a request that may be used to create a money transfer. from is an account id belonging to the user.

func (*RecurringTransfersService) Process Uses

func (t *RecurringTransfersService) Process(id string, intent TransferIntent, version int) *ProcessRecurringTransferReq

Process returns a request that may be used to update information and answer challenges for a transfer.

type RefreshAccessReq Uses

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

func (*RefreshAccessReq) ClientID Uses

func (r *RefreshAccessReq) ClientID(id string) *RefreshAccessReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*RefreshAccessReq) Context Uses

func (r *RefreshAccessReq) Context(ctx context.Context) *RefreshAccessReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*RefreshAccessReq) Send Uses

func (r *RefreshAccessReq) Send() (*Job, error)

type RefreshAllAccessesReq Uses

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

func (*RefreshAllAccessesReq) ClientID Uses

func (r *RefreshAllAccessesReq) ClientID(id string) *RefreshAllAccessesReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*RefreshAllAccessesReq) Context Uses

func (r *RefreshAllAccessesReq) Context(ctx context.Context) *RefreshAllAccessesReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*RefreshAllAccessesReq) Send Uses

func (r *RefreshAllAccessesReq) Send() ([]Job, error)

type RepeatedTransaction Uses

type RepeatedTransaction struct {
    ID            int64          `json:"id"`
    AccessID      int64          `json:"user_bank_access_id,omitempty"`
    UserAccountID int64          `json:"user_bank_account_id,omitempty"`
    UserAccount   AccountRef     `json:"user_account"`
    RemoteAccount AccountRef     `json:"remote_account"`
    RemoteID      string         `json:"remote_id"`
    Schedule      RecurrenceRule `json:"schedule"`
    Amount        *MoneyAmount   `json:"amount"`
    Usage         string         `json:"usage"`
}

type RepeatedTransactionPage Uses

type RepeatedTransactionPage struct {
    Transactions []RepeatedTransaction `json:"data"`
    Total        int                   `json:"total"`
    Limit        int                   `json:"limit"`
    Offset       int                   `json:"offset"`
}

type RepeatedTransactionsService Uses

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

RepeatedTransactionsService provides access to repeated transaction related API services.

func NewRepeatedTransactionsService Uses

func NewRepeatedTransactionsService(u *UserClient) *RepeatedTransactionsService

func (*RepeatedTransactionsService) Delete Uses

func (r *RepeatedTransactionsService) Delete(id string) *DeleteRepeatedTransactionReq

Delete returns a request that may be used to delete a repeated transaction.

func (*RepeatedTransactionsService) Get Uses

func (r *RepeatedTransactionsService) Get(id string) *GetRepeatedTransactionReq

func (*RepeatedTransactionsService) List Uses

func (r *RepeatedTransactionsService) List() *ListRepeatedTransactionsReq

func (*RepeatedTransactionsService) Update Uses

func (r *RepeatedTransactionsService) Update(id string, to TransferAddress, amount MoneyAmount, usage string) *UpdateRepeatedTransactionReq

Update returns a request that may be used to update a repeated transaction.

type RequestsStats Uses

type RequestsStats struct {
    From          string               `json:"from_date"`
    To            string               `json:"to_date"`
    Domain        string               `json:"domain"`
    RequestsTotal StatsValueChange     `json:"requests_total"`
    RequestsToday StatsValueChange     `json:"requests_today"`
    Stats         []DailyRequestsStats `json:"stats"`
}

type ResetDevUsersReq Uses

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

func (*ResetDevUsersReq) ClientID Uses

func (r *ResetDevUsersReq) ClientID(id string) *ResetDevUsersReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ResetDevUsersReq) Context Uses

func (r *ResetDevUsersReq) Context(ctx context.Context) *ResetDevUsersReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ResetDevUsersReq) Send Uses

func (r *ResetDevUsersReq) Send() (*ResetUsersResponse, error)

Send sends the request to reset user data.

type ResetPasswordReq Uses

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

func (*ResetPasswordReq) ClientID Uses

func (r *ResetPasswordReq) ClientID(id string) *ResetPasswordReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ResetPasswordReq) Context Uses

func (r *ResetPasswordReq) Context(ctx context.Context) *ResetPasswordReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ResetPasswordReq) Send Uses

func (r *ResetPasswordReq) Send() error

Send sends the reset password request.

type ResetUserOutcome Uses

type ResetUserOutcome struct {
    Username string    `json:"username"`
    Problems []Problem `json:"problems"`
}

type ResetUserPasswordReq Uses

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

func (*ResetUserPasswordReq) ClientID Uses

func (r *ResetUserPasswordReq) ClientID(id string) *ResetUserPasswordReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ResetUserPasswordReq) Context Uses

func (r *ResetUserPasswordReq) Context(ctx context.Context) *ResetUserPasswordReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ResetUserPasswordReq) Send Uses

func (r *ResetUserPasswordReq) Send() error

Send sends the request to reset a user's password.

type ResetUsersResponse Uses

type ResetUsersResponse struct {
    Users []ResetUserOutcome `json:"users"`
}

type RetryPolicy Uses

type RetryPolicy struct {
    // MaxRetries is the maximum number of requests that will be made after the original request.
    MaxRetries int

    // Wait is the base time to wait between attempts.
    Wait time.Duration

    // MaxWait is the maximum length of time to wait between retries.
    MaxWait time.Duration

    // Multiplier is the multiplier applied to Wait on each retry after the first. Set to zero
    // to implement a linear backoff.
    Multiplier float64

    // Jitter controls the amount of randomness applied to each wait period. A
    // random amount of time up to +/- Jitter is added to the period.
    Jitter time.Duration
}

func (RetryPolicy) NextWait Uses

func (r RetryPolicy) NextWait(requestsAttempted int) time.Duration

type ScheduledTransactionsService Uses

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

ScheduledTransactionsService provides access to scheduled transaction related API services.

func NewScheduledTransactionsService Uses

func NewScheduledTransactionsService(u *UserClient) *ScheduledTransactionsService

func (*ScheduledTransactionsService) Get Uses

func (a *ScheduledTransactionsService) Get(id string) *GetScheduledTransactionReq

func (*ScheduledTransactionsService) List Uses

func (a *ScheduledTransactionsService) List() *ListScheduledTransactionsReq

type ScheduledTransferCapabilities Uses

type ScheduledTransferCapabilities struct {
    Supported bool `json:"supported"`
}

type StatsMerchantsReq Uses

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

func (*StatsMerchantsReq) ClientID Uses

func (r *StatsMerchantsReq) ClientID(id string) *StatsMerchantsReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*StatsMerchantsReq) Context Uses

func (r *StatsMerchantsReq) Context(ctx context.Context) *StatsMerchantsReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*StatsMerchantsReq) FromDate Uses

func (r *StatsMerchantsReq) FromDate(date time.Time) *StatsMerchantsReq

func (*StatsMerchantsReq) Send Uses

func (r *StatsMerchantsReq) Send() (*MerchantsStats, error)

func (*StatsMerchantsReq) ToDate Uses

func (r *StatsMerchantsReq) ToDate(date time.Time) *StatsMerchantsReq

type StatsMoneyAmount Uses

type StatsMoneyAmount struct {
    Value    float64 `json:"value"`
    Currency string  `json:"currency"`
}

type StatsProvidersReq Uses

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

func (*StatsProvidersReq) ClientID Uses

func (r *StatsProvidersReq) ClientID(id string) *StatsProvidersReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*StatsProvidersReq) Context Uses

func (r *StatsProvidersReq) Context(ctx context.Context) *StatsProvidersReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*StatsProvidersReq) FromDate Uses

func (r *StatsProvidersReq) FromDate(date time.Time) *StatsProvidersReq

func (*StatsProvidersReq) Send Uses

func (r *StatsProvidersReq) Send() (*ProvidersStats, error)

func (*StatsProvidersReq) ToDate Uses

func (r *StatsProvidersReq) ToDate(date time.Time) *StatsProvidersReq

type StatsRequestsReq Uses

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

func (*StatsRequestsReq) ClientID Uses

func (r *StatsRequestsReq) ClientID(id string) *StatsRequestsReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*StatsRequestsReq) Context Uses

func (r *StatsRequestsReq) Context(ctx context.Context) *StatsRequestsReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*StatsRequestsReq) FromDate Uses

func (r *StatsRequestsReq) FromDate(date time.Time) *StatsRequestsReq

func (*StatsRequestsReq) Send Uses

func (r *StatsRequestsReq) Send() (*RequestsStats, error)

func (*StatsRequestsReq) ToDate Uses

func (r *StatsRequestsReq) ToDate(date time.Time) *StatsRequestsReq

type StatsService Uses

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

StatsService provides access to statistic related API services.

func NewStatsService Uses

func NewStatsService(c *DevClient) *StatsService

func (*StatsService) Merchants Uses

func (d *StatsService) Merchants() *StatsMerchantsReq

func (*StatsService) Providers Uses

func (d *StatsService) Providers() *StatsProvidersReq

func (*StatsService) Requests Uses

func (d *StatsService) Requests() *StatsRequestsReq

func (*StatsService) Transfers Uses

func (d *StatsService) Transfers() *StatsTransfersReq

func (*StatsService) Users Uses

func (d *StatsService) Users() *StatsUsersReq

type StatsTransfersReq Uses

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

func (*StatsTransfersReq) ClientID Uses

func (r *StatsTransfersReq) ClientID(id string) *StatsTransfersReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*StatsTransfersReq) Context Uses

func (r *StatsTransfersReq) Context(ctx context.Context) *StatsTransfersReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*StatsTransfersReq) FromDate Uses

func (r *StatsTransfersReq) FromDate(date time.Time) *StatsTransfersReq

func (*StatsTransfersReq) Send Uses

func (r *StatsTransfersReq) Send() (interface{}, error)

func (*StatsTransfersReq) ToDate Uses

func (r *StatsTransfersReq) ToDate(date time.Time) *StatsTransfersReq

type StatsUsersReq Uses

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

func (*StatsUsersReq) ClientID Uses

func (r *StatsUsersReq) ClientID(id string) *StatsUsersReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*StatsUsersReq) Context Uses

func (r *StatsUsersReq) Context(ctx context.Context) *StatsUsersReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*StatsUsersReq) FromDate Uses

func (r *StatsUsersReq) FromDate(date time.Time) *StatsUsersReq

func (*StatsUsersReq) Send Uses

func (r *StatsUsersReq) Send() (*UsersStats, error)

func (*StatsUsersReq) ToDate Uses

func (r *StatsUsersReq) ToDate(date time.Time) *StatsUsersReq

type StatsValueChange Uses

type StatsValueChange struct {
    Value  int64   `json:"value"`
    Change float64 `json:"change"`
}

type TANType Uses

type TANType string
const (
    // TANTypePaymentPin4 is an abstract 4-chars string used to authorise payment
    TANTypePaymentPin4 TANType = "paymentPIN4"
    // TANTypeOptical indicates an optical TAN such as flickering barcodes
    TANTypeOptical TANType = "optical"
    // TANTypeITAN indicates an iTAN (aka indexed TAN) such as a list of TAN numbers with a sequence
    TANTypeITAN TANType = "itan"
    // TANTypeMobile indicates a mobileTAN such as an SMS with a passcode
    TANTypeMobile TANType = "mobile"
    // TANTypeChip indicates a chipTAN provided from a calculator device
    TANTypeChip TANType = "chip"
    // TANTypePush indicates a push push notification to a mobile app
    TANTypePush TANType = "push"
    // TANTypeOTP indicates a one-time password
    TANTypeOTP TANType = "otp"
    // TANTypeUSB indicate a usb based TAN
    TANTypeUSB TANType = "usb"
    // TANTypePhoto indicates a colorised matrix barcode
    TANTypePhoto TANType = "photo"

    TANTypeUnknown TANType = "unknown"
)

type TestWebhookReq Uses

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

func (*TestWebhookReq) ClientID Uses

func (r *TestWebhookReq) ClientID(id string) *TestWebhookReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*TestWebhookReq) Context Uses

func (r *TestWebhookReq) Context(ctx context.Context) *TestWebhookReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*TestWebhookReq) Send Uses

func (r *TestWebhookReq) Send() (*WebhookTestResult, error)

type Transaction Uses

type Transaction struct {
    ID                    int64           `json:"id"`
    AccessID              int64           `json:"user_bank_access_id,omitempty"`
    UserAccountID         int64           `json:"user_bank_account_id,omitempty"`
    UserAccount           AccountRef      `json:"user_account,omitempty"`
    CategoryID            int64           `json:"category_id,omitempty"`
    RepeatedTransactionID int64           `json:"repeated_transaction_id,omitempty"`
    Counterparty          Counterparty    `json:"counterparty,omitempty"`
    RemoteID              string          `json:"remote_id"`
    EntryDate             time.Time       `json:"entry_date,omitempty"`
    SettlementDate        time.Time       `json:"settlement_date,omitempty"`
    Amount                *MoneyAmount    `json:"amount,omitempty"`
    OriginalAmount        *OriginalAmount `json:"original_amount,omitempty"`
    Usage                 string          `json:"usage,omitempty"`
    TransactionType       string          `json:"transaction_type,omitempty"`
    Gvcode                string          `json:"gvcode,omitempty"`
}

type TransactionPage Uses

type TransactionPage struct {
    Transactions []Transaction `json:"data"`
    Total        int           `json:"total"`
    Limit        int           `json:"limit"`
    Offset       int           `json:"offset"`
}

type TransactionsService Uses

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

TransactionsService provides access to transaction related API services.

func NewTransactionsService Uses

func NewTransactionsService(u *UserClient) *TransactionsService

func (*TransactionsService) Get Uses

func (a *TransactionsService) Get(id string) *GetTransactionReq

func (*TransactionsService) List Uses

func (a *TransactionsService) List() *ListTransactionsReq

type Transfer Uses

type Transfer struct {
    ID             string           `json:"id"`
    From           TransferAddress  `json:"from"`
    To             TransferAddress  `json:"to"`
    Amount         *MoneyAmount     `json:"amount"`
    Usage          string           `json:"usage"`
    Version        int              `json:"version"`
    Step           TransferStep     `json:"step"`
    State          TransferState    `json:"state"`
    EntryDate      time.Time        `json:"booking_date,omitempty"`
    SettlementDate time.Time        `json:"effective_date,omitempty"`
    Created        time.Time        `json:"created,omitempty"`
    Updated        time.Time        `json:"updated,omitempty"`
    RemoteID       string           `json:"remote_id"`
    Errors         []Problem        `json:"errors"`
    Consent        *TransferConsent `json:"consent,omitempty"`
}

type TransferAddress Uses

type TransferAddress struct {
    Name      string `json:"name"`
    IBAN      string `json:"iban"`
    AccessID  int64  `json:"bank_access_id,omitempty"`
    AccountID int64  `json:"bank_account_id,omitempty"`
}

type TransferConsent Uses

type TransferConsent struct {
    ID          string `json:"id,omitempty"`
    AuthURL     string `json:"auth_url,omitempty"`
    AuthMessage string `json:"auth_message,omitempty"`
}

type TransferIntent Uses

type TransferIntent string
const (
    TransferIntentProvidePIN             TransferIntent = "provide_pin"
    TransferIntentProvideCredentials     TransferIntent = "provide_credentials"
    TransferIntentSelectAuthMethod       TransferIntent = "select_auth_method"
    TransferIntentProvideChallengeAnswer TransferIntent = "provide_challenge_answer"
    TransferIntentConfirmSimilarTransfer TransferIntent = "confirm_similar_transfer"
    TransferIntentConsent                TransferIntent = "consent"
)

type TransferState Uses

type TransferState string
const (
    TransferStateOngoing   TransferState = "ongoing"
    TransferStateSucceeded TransferState = "succeeded"
    TransferStateFailed    TransferState = "failed"
    TransferStateCancelled TransferState = "cancelled"
)

type TransferStep Uses

type TransferStep struct {
    Intent    TransferIntent    `json:"intent,omitempty"`
    Data      *TransferStepData `json:"data,omitempty"`
    Challenge *Challenge        `json:"challenge,omitempty"`
}

type TransferStepData Uses

type TransferStepData struct {
    AuthMethods      []AuthMethod `json:"auth_methods,omitempty"`      // TAN Options
    Challenge        string       `json:"challenge,omitempty"`         // TAN Challenge
    ChallengeMessage string       `json:"challenge_message,omitempty"` // TAN Challenge Message
    TANType          TANType      `json:"tan_type,omitempty"`          // Type of the TAN (optical, itan, unknown)
    Transfers        []Transfer   `json:"transfers,omitempty"`         // Transfer list (similar transfers)
}

type TransferType Uses

type TransferType string
const (
    TransferTypeRecurring TransferType = "recurring"
    TransferTypeRegular   TransferType = "regular"
)

type TransfersService Uses

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

TransfersService provides access to money transfer related API services.

func NewTransfersService Uses

func NewTransfersService(u *UserClient) *TransfersService

func (*TransfersService) Cancel Uses

func (t *TransfersService) Cancel(id string, version int) *CancelTransferReq

Cancel returns a request that may be used to cancel an ongoing money transfer.

func (*TransfersService) Create Uses

func (t *TransfersService) Create(from int64, to TransferAddress, amount MoneyAmount) *CreateTransferReq

Create returns a request that may be used to create a money transfer.

func (*TransfersService) Process Uses

func (t *TransfersService) Process(id string, intent TransferIntent, version int) *ProcessTransferReq

Process returns a request that may be used to update information and answer challenges for a transfer.

type TransfersStats Uses

type TransfersStats struct {
    From     string                `json:"from_date"`
    To       string                `json:"to_date"`
    Domain   string                `json:"domain"`
    TotalOut []StatsMoneyAmount    `json:"total_out"`
    TodayOut []StatsMoneyAmount    `json:"today_out"`
    Stats    []DailyTransfersStats `json:"stats"`
}

type UpdateAccessReq Uses

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

func (*UpdateAccessReq) ChallengeAnswer Uses

func (r *UpdateAccessReq) ChallengeAnswer(answer ChallengeAnswer) *UpdateAccessReq

ChallengeAnswer adds an answer to one of the authorisation challenges required to complete update of the access.

func (*UpdateAccessReq) ClientID Uses

func (r *UpdateAccessReq) ClientID(id string) *UpdateAccessReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*UpdateAccessReq) Context Uses

func (r *UpdateAccessReq) Context(ctx context.Context) *UpdateAccessReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*UpdateAccessReq) Send Uses

func (r *UpdateAccessReq) Send() (*Access, error)

type UpdateApplicationReq Uses

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

func (*UpdateApplicationReq) ClientID Uses

func (r *UpdateApplicationReq) ClientID(id string) *UpdateApplicationReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*UpdateApplicationReq) Context Uses

func (r *UpdateApplicationReq) Context(ctx context.Context) *UpdateApplicationReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*UpdateApplicationReq) Send Uses

func (r *UpdateApplicationReq) Send() error

type UpdateApplicationSettingsReq Uses

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

func (*UpdateApplicationSettingsReq) BackgroundRefresh Uses

func (r *UpdateApplicationSettingsReq) BackgroundRefresh(value bool) *UpdateApplicationSettingsReq

BackgroundRefresh sets the value of the background_refresh configuration setting.

func (*UpdateApplicationSettingsReq) ClientID Uses

func (r *UpdateApplicationSettingsReq) ClientID(id string) *UpdateApplicationSettingsReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*UpdateApplicationSettingsReq) Context Uses

func (r *UpdateApplicationSettingsReq) Context(ctx context.Context) *UpdateApplicationSettingsReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*UpdateApplicationSettingsReq) Send Uses

func (r *UpdateApplicationSettingsReq) Send() (*ApplicationSettings, error)

Send sends the request to retrieve the developer's profile.

type UpdateCredentialReq Uses

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

func (*UpdateCredentialReq) ClientID Uses

func (r *UpdateCredentialReq) ClientID(id string) *UpdateCredentialReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*UpdateCredentialReq) Context Uses

func (r *UpdateCredentialReq) Context(ctx context.Context) *UpdateCredentialReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*UpdateCredentialReq) Send Uses

func (r *UpdateCredentialReq) Send() error

type UpdateRepeatedTransactionReq Uses

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

func (*UpdateRepeatedTransactionReq) ChallengeAnswer Uses

func (r *UpdateRepeatedTransactionReq) ChallengeAnswer(answer ChallengeAnswer) *UpdateRepeatedTransactionReq

ChallengeAnswer adds an answer to one of the authorisation challenges required to complete the update.

func (*UpdateRepeatedTransactionReq) ClientID Uses

func (r *UpdateRepeatedTransactionReq) ClientID(id string) *UpdateRepeatedTransactionReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*UpdateRepeatedTransactionReq) Context Uses

func (r *UpdateRepeatedTransactionReq) Context(ctx context.Context) *UpdateRepeatedTransactionReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*UpdateRepeatedTransactionReq) Description Uses

func (r *UpdateRepeatedTransactionReq) Description(s string) *UpdateRepeatedTransactionReq

Description sets a human readable description for the transaction.

func (*UpdateRepeatedTransactionReq) Schedule Uses

func (r *UpdateRepeatedTransactionReq) Schedule(rule RecurrenceRule) *UpdateRepeatedTransactionReq

Schedule sets a recurrence schedule for the transaction.

func (*UpdateRepeatedTransactionReq) Send Uses

func (r *UpdateRepeatedTransactionReq) Send() (*RecurringTransfer, error)

Send sends the request to update a repeated transaction. It returns information about the long running recurring transfer job that may be used to track and progress the update.

type UpdateWebhookParams Uses

type UpdateWebhookParams struct {
    URL        string   `json:"url"`
    Events     []string `json:"events"`
    APIVersion int      `json:"api_version"`
}

type UpdateWebhookReq Uses

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

func (*UpdateWebhookReq) ClientID Uses

func (r *UpdateWebhookReq) ClientID(id string) *UpdateWebhookReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*UpdateWebhookReq) Context Uses

func (r *UpdateWebhookReq) Context(ctx context.Context) *UpdateWebhookReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*UpdateWebhookReq) Send Uses

func (r *UpdateWebhookReq) Send() error

type UserClient Uses

type UserClient struct {
    UserID                string
    Accesses              *AccessesService
    Jobs                  *JobsService
    Accounts              *AccountsService
    Transactions          *TransactionsService
    ScheduledTransactions *ScheduledTransactionsService
    RepeatedTransactions  *RepeatedTransactionsService
    Transfers             *TransfersService
    RecurringTransfers    *RecurringTransfersService
    Consents              *ConsentsService
    // contains filtered or unexported fields
}

UserClient is a client used for interacting with services in the context of a registered application and a valid user session. It is safe for concurrent use by multiple goroutines.

func NewUserClient Uses

func NewUserClient(client *http.Client, addr string, userID string, token string, applicationKey string) *UserClient

NewUserClient creates a new user client, ready to use.

func (*UserClient) Delete Uses

func (u *UserClient) Delete(password string) *UserDeleteReq

Delete returns a request that may be used to delete a user account and its associated data. Once this request has been sent the user client is no longer valid and should not be used.

func (*UserClient) Logout Uses

func (u *UserClient) Logout() *UserLogoutReq

Logout returns a request that may be used to log a user out of the Bankrs API. Once this request has been sent the user client is no longer valid and should not be used.

func (*UserClient) SessionToken Uses

func (u *UserClient) SessionToken() string

SessionToken returns the current session token.

type UserCreateReq Uses

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

UserCreateReq is a request that may be used to create a user.

func (*UserCreateReq) ClientID Uses

func (r *UserCreateReq) ClientID(id string) *UserCreateReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*UserCreateReq) Context Uses

func (r *UserCreateReq) Context(ctx context.Context) *UserCreateReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*UserCreateReq) Send Uses

func (r *UserCreateReq) Send() (*UserClient, error)

Send sends the request to create the user and returns a client that can be used to access services within the new users's session.

type UserCredentials Uses

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

type UserDeleteReq Uses

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

func (*UserDeleteReq) Context Uses

func (r *UserDeleteReq) Context(ctx context.Context) *UserDeleteReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*UserDeleteReq) Send Uses

func (r *UserDeleteReq) Send() (*DeletedUser, error)

Send sends the request to delete a user.

type UserInfo Uses

type UserInfo struct {
    PhoneNumber   string     `json:"phone_number,omitempty"`
    LastUpdated   *time.Time `json:"last_updated,omitempty"`
    KYCUpdated    *time.Time `json:"kyc_completed,omitempty"`
    CardActivated *time.Time `json:"card_activated,omitempty"`
    Country       string     `json:"country,omitempty"`
}

UserInfo represents personal information about the user of this access

type UserListPage Uses

type UserListPage struct {
    Users      []string `json:"users,omitempty"`
    NextCursor string   `json:"next,omitempty"`
}

type UserLoginReq Uses

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

func (*UserLoginReq) ClientID Uses

func (r *UserLoginReq) ClientID(id string) *UserLoginReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*UserLoginReq) Context Uses

func (r *UserLoginReq) Context(ctx context.Context) *UserLoginReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*UserLoginReq) Send Uses

func (r *UserLoginReq) Send() (*UserClient, error)

Send sends the request to login the user and returns a client that can be used to access services within the new users's session.

type UserLogoutReq Uses

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

func (*UserLogoutReq) ClientID Uses

func (r *UserLogoutReq) ClientID(id string) *UserLogoutReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*UserLogoutReq) Context Uses

func (r *UserLogoutReq) Context(ctx context.Context) *UserLogoutReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*UserLogoutReq) Send Uses

func (r *UserLogoutReq) Send() error

type UserToken Uses

type UserToken struct {
    ID    string `json:"id"`    // globally unique identifier for a user
    Token string `json:"token"` // session token
}

type UsersStats Uses

type UsersStats struct {
    From       string            `json:"from_date"`
    To         string            `json:"to_date"`
    Domain     string            `json:"domain"`
    UsersTotal StatsValueChange  `json:"users_total"` // with weekly relative change
    UsersToday StatsValueChange  `json:"users_today"` // with daily relative change
    Stats      []DailyUsersStats `json:"stats"`
}

type ValidateIBANReq Uses

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

ValidateIBANReq is a request that may be used to validate an IBAN.

func (*ValidateIBANReq) ClientID Uses

func (r *ValidateIBANReq) ClientID(id string) *ValidateIBANReq

ClientID sets a client identifier that will be passed to the Bankrs API in the X-Client-Id header.

func (*ValidateIBANReq) Context Uses

func (r *ValidateIBANReq) Context(ctx context.Context) *ValidateIBANReq

Context sets the context to be used during this request. If no context is supplied then the request will use context.Background.

func (*ValidateIBANReq) Send Uses

func (r *ValidateIBANReq) Send() (*IBANDetails, error)

Send sends the request to validate the IBAN and returns details about the IBAN.

type Webhook Uses

type Webhook struct {
    ID          string    `json:"id"`
    URL         string    `json:"url"`
    Events      []string  `json:"events"`
    APIVersion  int       `json:"api_version"`
    Enabled     bool      `json:"enabled"`
    Environment string    `json:"environment"`
    CreatedAt   time.Time `json:"created_at"`
}

type WebhookEventDetail Uses

type WebhookEventDetail struct {
    ID          string    `json:"id"`
    Type        string    `json:"type"`
    URL         string    `json:"url"`
    APIVersion  int       `json:"api_version"`
    Environment string    `json:"environment"`
    CreatedAt   time.Time `json:"created_at"`
}

type WebhookPage Uses

type WebhookPage struct {
    Webhooks []Webhook `json:"webhooks,omitempty"`
}

type WebhookPayload Uses

type WebhookPayload struct {
    Event WebhookEventDetail     `json:"event"`
    Data  map[string]interface{} `json:"data"`
}

type WebhookTestResponse Uses

type WebhookTestResponse struct {
    ID     string `json:"id"`
    Code   int    `json:"code"`
    Status string `json:"status"`
}

type WebhookTestResult Uses

type WebhookTestResult struct {
    Payload  WebhookPayload      `json:"payload"`
    Response WebhookTestResponse `json:"response"`
}

type WebhooksService Uses

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

WebhooksService provides access to webhook related API services.

func NewWebhooksService Uses

func NewWebhooksService(c *DevClient) *WebhooksService

func (*WebhooksService) Create Uses

func (d *WebhooksService) Create(apiVersion int, url string, events []string) *CreateWebhookReq

Create prepares and returns a request to create a new webhook.

func (*WebhooksService) Delete Uses

func (d *WebhooksService) Delete(id string) *DeleteWebhookReq

Delete prepares and returns a request to delete an existing webhook.

func (*WebhooksService) Get Uses

func (d *WebhooksService) Get(id string) *GetWebhookReq

Get prepares and returns a request to get details of an existing webhook.

func (*WebhooksService) List Uses

func (d *WebhooksService) List() *ListWebhookReq

List prepares and returns a request to list details of all webhooks.

func (*WebhooksService) Test Uses

func (d *WebhooksService) Test(id string, event string) *TestWebhookReq

Test prepares and returns a request to test a webhook.

func (*WebhooksService) Update Uses

func (d *WebhooksService) Update(id string, apiVersion int, u string, events []string) *UpdateWebhookReq

Update prepares and returns a request to update an existing webhook.

Package bosgo imports 12 packages (graph) and is imported by 4 packages. Updated 2020-03-21. Refresh now. Tools for package owners.