Documentation ¶
Index ¶
- type Account
- type Accounts
- type Address
- type Asset
- type Assets
- type Balance
- type CreateAccountInput
- type CreateAssetInput
- type CreateLedgerInput
- type CreateOrganizationInput
- type CreatePortfolioInput
- type CreateProductInput
- type Ledger
- type Ledgers
- type Organization
- type Organizations
- type Portfolio
- type Portfolios
- type Product
- type Products
- type Status
- type UpdateAccountInput
- type UpdateAssetInput
- type UpdateLedgerInput
- type UpdateOrganizationInput
- type UpdatePortfolioInput
- type UpdateProductInput
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Account ¶
type Account struct { ID string `json:"id" example:"00000000-0000-0000-0000-000000000000"` Name string `json:"name" example:"My Account"` ParentAccountID *string `json:"parentAccountId" example:"00000000-0000-0000-0000-000000000000"` EntityID *string `json:"entityId" example:"00000000-0000-0000-0000-000000000000"` AssetCode string `json:"assetCode" example:"BRL"` OrganizationID string `json:"organizationId" example:"00000000-0000-0000-0000-000000000000"` LedgerID string `json:"ledgerId" example:"00000000-0000-0000-0000-000000000000"` PortfolioID *string `json:"portfolioId" example:"00000000-0000-0000-0000-000000000000"` ProductID *string `json:"productId" example:"00000000-0000-0000-0000-000000000000"` Balance Balance `json:"balance"` Status Status `json:"status"` AllowSending *bool `json:"allowSending" example:"true"` AllowReceiving *bool `json:"allowReceiving" example:"true"` Alias *string `json:"alias" example:"@person1"` Type string `json:"type" example:"creditCard"` CreatedAt time.Time `json:"createdAt" example:"2021-01-01T00:00:00Z"` UpdatedAt time.Time `json:"updatedAt" example:"2021-01-01T00:00:00Z"` DeletedAt *time.Time `json:"deletedAt" example:"2021-01-01T00:00:00Z"` Metadata map[string]any `json:"metadata,omitempty"` } // @name Account
Account is a struct designed to encapsulate response payload data.
swagger:model Account @Description Account is a struct designed to store account data.
type Accounts ¶
type Accounts struct { Items []Account `json:"items"` Page int `json:"page" example:"1"` Limit int `json:"limit" example:"10"` } // @name Accounts
Accounts struct to return get all.
swagger:model Accounts @Description Accounts is the struct designed to return a list of accounts with pagination.
type Address ¶
type Address struct { Line1 string `json:"line1" example:"Street 1"` Line2 *string `json:"line2" example:"Street 2"` ZipCode string `json:"zipCode" example:"00000-000"` City string `json:"city" example:"New York"` State string `json:"state" example:"NY"` Country string `json:"country" example:"US"` // According to ISO 3166-1 alpha-2 } // @name Address
Address structure for marshaling/unmarshalling JSON.
swagger:model Address @Description Address is a struct designed to store the address data of an organization.
type Asset ¶
type Asset struct { ID string `json:"id" example:"00000000-0000-0000-0000-000000000000"` Name string `json:"name" example:"Brazilian Real"` Type string `json:"type" example:"currency"` Code string `json:"code" example:"BRL"` Status Status `json:"status"` LedgerID string `json:"ledgerId" example:"00000000-0000-0000-0000-000000000000"` OrganizationID string `json:"organizationId" example:"00000000-0000-0000-0000-000000000000"` CreatedAt time.Time `json:"createdAt" example:"2021-01-01T00:00:00Z"` UpdatedAt time.Time `json:"updatedAt" example:"2021-01-01T00:00:00Z"` DeletedAt *time.Time `json:"deletedAt" example:"2021-01-01T00:00:00Z"` Metadata map[string]any `json:"metadata,omitempty"` } // @name Asset
Asset is a struct designed to encapsulate payload data.
swagger:model Asset
@Description Asset is a struct designed to store asset data.
type Assets ¶
type Assets struct { Items []Asset `json:"items"` Page int `json:"page" example:"1"` Limit int `json:"limit" example:"10"` } // @name Assets
Assets struct to return get all.
swagger:model Assets
@Description Assets is the struct designed to return a list of assets with pagination.
type Balance ¶
type Balance struct { Available *float64 `json:"available" example:"1500"` OnHold *float64 `json:"onHold" example:"500"` Scale *float64 `json:"scale" example:"2"` } // @name Balance
Balance structure for marshaling/unmarshalling JSON.
swagger:model Balance @Description Balance is the struct designed to represent the account balance.
type CreateAccountInput ¶
type CreateAccountInput struct { AssetCode string `json:"assetCode" validate:"required,max=100" example:"BRL"` Name string `json:"name" validate:"max=256" example:"My Account"` Alias *string `json:"alias" validate:"max=100,prohibitedexternalaccountprefix" example:"@person1"` Type string `json:"type" validate:"required" example:"creditCard"` ParentAccountID *string `json:"parentAccountId" validate:"omitempty,uuid" example:"00000000-0000-0000-0000-000000000000"` ProductID *string `json:"productId" validate:"omitempty,uuid" example:"00000000-0000-0000-0000-000000000000"` PortfolioID *string `json:"portfolioId" validate:"omitempty,uuid" example:"00000000-0000-0000-0000-000000000000"` EntityID *string `json:"entityId" validate:"omitempty,max=256" example:"00000000-0000-0000-0000-000000000000"` Status Status `json:"status"` AllowSending *bool `json:"allowSending" example:"true"` AllowReceiving *bool `json:"allowReceiving" example:"true"` Metadata map[string]any `json:"metadata" validate:"dive,keys,keymax=100,endkeys,nonested,valuemax=2000"` } // @name CreateAccountInput
CreateAccountInput is a struct design to encapsulate request create payload data.
swagger:model CreateAccountInput @Description CreateAccountInput is the input payload to create an account.
type CreateAssetInput ¶
type CreateAssetInput struct { Name string `json:"name" validate:"max=256" example:"Brazilian Real"` Type string `json:"type" example:"currency"` Code string `json:"code" validate:"required,max=100" example:"BRL"` Status Status `json:"status"` Metadata map[string]any `json:"metadata" validate:"dive,keys,keymax=100,endkeys,nonested,valuemax=2000"` } // @name CreateAssetInput
CreateAssetInput is a struct design to encapsulate request create payload data.
swagger:model CreateAssetInput
@Description CreateAssetInput is the input payload to create an asset.
type CreateLedgerInput ¶
type CreateLedgerInput struct { Name string `json:"name" validate:"required,max=256" example:"Lerian Studio"` Status Status `json:"status"` Metadata map[string]any `json:"metadata" validate:"dive,keys,keymax=100,endkeys,nonested,valuemax=2000"` } // @name CreateLedgerInput
CreateLedgerInput is a struct design to encapsulate request create payload data.
swagger:model CreateLedgerInput @Description CreateLedgerInput is the input payload to create a ledger.
type CreateOrganizationInput ¶
type CreateOrganizationInput struct { LegalName string `json:"legalName" validate:"required,max=256" example:"Lerian Studio"` ParentOrganizationID *string `json:"parentOrganizationId" validate:"omitempty,uuid" example:"00000000-0000-0000-0000-000000000000"` DoingBusinessAs *string `json:"doingBusinessAs" validate:"max=256" example:"Lerian Studio"` LegalDocument string `json:"legalDocument" validate:"required,max=256" example:"00000000000000"` Address Address `json:"address"` Status Status `json:"status"` Metadata map[string]any `json:"metadata" validate:"dive,keys,keymax=100,endkeys,nonested,valuemax=2000"` } // @name CreateOrganizationInput
CreateOrganizationInput is a struct design to encapsulate request create payload data.
// swagger:model CreateOrganizationInput @Description CreateOrganizationInput is the input payload to create an organization.
type CreatePortfolioInput ¶
type CreatePortfolioInput struct { EntityID string `json:"entityId" validate:"required,max=256" example:"00000000-0000-0000-0000-000000000000"` Name string `json:"name" validate:"required,max=256" example:"My Portfolio"` Status Status `json:"status"` Metadata map[string]any `json:"metadata" validate:"dive,keys,keymax=100,endkeys,nonested,valuemax=2000"` } // @name CreatePortfolioInput
CreatePortfolioInput is a struct design to encapsulate request create payload data.
swagger:model CreatePortfolioInput @Description CreatePortfolioInput is the input payload to create a portfolio.
type CreateProductInput ¶
type CreateProductInput struct { Name string `json:"name" validate:"required,max=256" example:"My Product"` Status Status `json:"status"` Metadata map[string]any `json:"metadata" validate:"dive,keys,keymax=100,endkeys,nonested,valuemax=2000"` } // @name CreateProductInput
CreateProductInput is a struct design to encapsulate request create payload data.
swagger:model CreateProductInput @Description CreateProductInput is the input payload to create a product.
type Ledger ¶
type Ledger struct { ID string `json:"id" example:"00000000-0000-0000-0000-000000000000"` Name string `json:"name" example:"Lerian Studio"` OrganizationID string `json:"organizationId" example:"00000000-0000-0000-0000-000000000000"` Status Status `json:"status"` CreatedAt time.Time `json:"createdAt" example:"2021-01-01T00:00:00Z"` UpdatedAt time.Time `json:"updatedAt" example:"2021-01-01T00:00:00Z"` DeletedAt *time.Time `json:"deletedAt" sql:"index" example:"2021-01-01T00:00:00Z"` Metadata map[string]any `json:"metadata,omitempty"` } // @name Ledger
Ledger is a struct designed to encapsulate payload data.
swagger:model Ledger @Description Ledger is a struct designed to store ledger data.
type Ledgers ¶
type Ledgers struct { Items []Ledger `json:"items"` Page int `json:"page" example:"1"` Limit int `json:"limit" example:"10"` } // @name Ledgers
Ledgers struct to return get all.
swagger:model Ledgers @Description Ledgers is the struct designed to return a list of ledgers with pagination.
type Organization ¶
type Organization struct { ID string `json:"id" example:"00000000-0000-0000-0000-000000000000"` ParentOrganizationID *string `json:"parentOrganizationId" example:"00000000-0000-0000-0000-000000000000"` LegalName string `json:"legalName" example:"Lerian Studio"` DoingBusinessAs *string `json:"doingBusinessAs" example:"Lerian Studio"` LegalDocument string `json:"legalDocument" example:"00000000000000"` Address Address `json:"address"` Status Status `json:"status"` CreatedAt time.Time `json:"createdAt" example:"2021-01-01T00:00:00Z"` UpdatedAt time.Time `json:"updatedAt" example:"2021-01-01T00:00:00Z"` DeletedAt *time.Time `json:"deletedAt" example:"2021-01-01T00:00:00Z"` Metadata map[string]any `json:"metadata,omitempty"` } // @name Organization
Organization is a struct designed to encapsulate response payload data.
swagger:model Organization @Description Organization is a struct designed to store organization data.
type Organizations ¶
type Organizations struct { Items []Organization `json:"items"` Page int `json:"page" example:"1"` Limit int `json:"limit" example:"10"` } // @name Organizations
Organizations struct to return get all.
swagger:model Organizations @Description Organizations is the struct designed to return a list of organizations with pagination.
type Portfolio ¶
type Portfolio struct { ID string `json:"id" example:"00000000-0000-0000-0000-000000000000"` Name string `json:"name" example:"My Portfolio"` EntityID string `json:"entityId" example:"00000000-0000-0000-0000-000000000000"` LedgerID string `json:"ledgerId" example:"00000000-0000-0000-0000-000000000000"` OrganizationID string `json:"organizationId" example:"00000000-0000-0000-0000-000000000000"` Status Status `json:"status"` CreatedAt time.Time `json:"createdAt" example:"2021-01-01T00:00:00Z"` UpdatedAt time.Time `json:"updatedAt" example:"2021-01-01T00:00:00Z"` DeletedAt *time.Time `json:"deletedAt" example:"2021-01-01T00:00:00Z"` Metadata map[string]any `json:"metadata,omitempty"` } // @name Portfolio
Portfolio is a struct designed to encapsulate request update payload data.
swagger:model Portfolio @Description Portfolio is a struct designed to store portfolio data.
type Portfolios ¶
type Portfolios struct { Items []Portfolio `json:"items"` Page int `json:"page" example:"1"` Limit int `json:"limit" example:"10"` } // @name Portfolios
Portfolios struct to return get all.
swagger:model Portfolios @Description Portfolios is the struct designed to return a list of portfolios with pagination.
type Product ¶
type Product struct { ID string `json:"id" example:"00000000-0000-0000-0000-000000000000"` Name string `json:"name" example:"My Product"` LedgerID string `json:"ledgerId" example:"00000000-0000-0000-0000-000000000000"` OrganizationID string `json:"organizationId" example:"00000000-0000-0000-0000-000000000000"` Status Status `json:"status"` CreatedAt time.Time `json:"createdAt" example:"2021-01-01T00:00:00Z"` UpdatedAt time.Time `json:"updatedAt" example:"2021-01-01T00:00:00Z"` DeletedAt *time.Time `json:"deletedAt" example:"2021-01-01T00:00:00Z"` Metadata map[string]any `json:"metadata,omitempty"` } // @name Product
Product is a struct designed to encapsulate payload data.
swagger:model Product @Description Product is a struct designed to store product data.
type Products ¶
type Products struct { Items []Product `json:"items"` Page int `json:"page" example:"1"` Limit int `json:"limit" example:"10"` } // @name Products
Products struct to return get all.
swagger:model Products @Description Products is the struct designed to return a list of products with pagination.
type Status ¶
type Status struct { Code string `json:"code" validate:"max=100" example:"ACTIVE"` Description *string `json:"description" validate:"omitempty,max=256" example:"Active status"` } // @name Status
Status structure for marshaling/unmarshalling JSON.
swagger:model Status @Description Status is the struct designed to store the status data of an entity.
type UpdateAccountInput ¶
type UpdateAccountInput struct { Name string `json:"name" validate:"max=256" example:"My Account Updated"` Status Status `json:"status"` AllowSending *bool `json:"allowSending" example:"true"` AllowReceiving *bool `json:"allowReceiving" example:"true"` Alias *string `json:"alias" validate:"omitempty,max=100,prohibitedexternalaccountprefix" example:"@person1"` ProductID *string `json:"productId" validate:"omitempty,uuid" example:"00000000-0000-0000-0000-000000000000"` Metadata map[string]any `json:"metadata" validate:"dive,keys,keymax=100,endkeys,nonested,valuemax=2000"` } // @name UpdateAccountInput
UpdateAccountInput is a struct design to encapsulate request update payload data.
swagger:model UpdateAccountInput @Description UpdateAccountInput is the input payload to update an account.
type UpdateAssetInput ¶
type UpdateAssetInput struct { Name string `json:"name" validate:"max=256" example:"Bitcoin"` Status Status `json:"status"` Metadata map[string]any `json:"metadata" validate:"dive,keys,keymax=100,endkeys,nonested,valuemax=2000"` } // @name UpdateAssetInput
UpdateAssetInput is a struct design to encapsulate request update payload data.
swagger:model UpdateAssetInput
@Description UpdateAssetInput is the input payload to update an asset.
type UpdateLedgerInput ¶
type UpdateLedgerInput struct { Name string `json:"name" validate:"max=256" example:"Lerian Studio Updated"` Status Status `json:"status"` Metadata map[string]any `json:"metadata" validate:"dive,keys,keymax=100,endkeys,nonested,valuemax=2000"` } // @name UpdateLedgerInput
UpdateLedgerInput is a struct design to encapsulate request update payload data.
swagger:model UpdateLedgerInput @Description UpdateLedgerInput is the input payload to update a ledger.
type UpdateOrganizationInput ¶
type UpdateOrganizationInput struct { LegalName string `json:"legalName" validate:"required,max=256" example:"Lerian Studio Updated"` ParentOrganizationID *string `json:"parentOrganizationId" validate:"omitempty,uuid" example:"00000000-0000-0000-0000-000000000000"` DoingBusinessAs *string `json:"doingBusinessAs" validate:"max=256" example:"The ledger.io"` Address Address `json:"address"` Status Status `json:"status"` Metadata map[string]any `json:"metadata" validate:"dive,keys,keymax=100,endkeys,nonested,valuemax=2000"` } // @name UpdateOrganizationInput
UpdateOrganizationInput is a struct design to encapsulate request update payload data.
// swagger:model UpdateOrganizationInput @Description UpdateOrganizationInput is the input payload to update an organization.
type UpdatePortfolioInput ¶
type UpdatePortfolioInput struct { Name string `json:"name" validate:"max=256" example:"My Portfolio Updated"` Status Status `json:"status"` Metadata map[string]any `json:"metadata" validate:"dive,keys,keymax=100,endkeys,nonested,valuemax=2000"` } // @name UpdatePortfolioInput
UpdatePortfolioInput is a struct design to encapsulate payload data.
swagger:model UpdatePortfolioInput @Description UpdatePortfolioInput is the input payload to update a portfolio.
type UpdateProductInput ¶
type UpdateProductInput struct { Name string `json:"name" validate:"max=256" example:"My Product Updated"` Status Status `json:"status"` Metadata map[string]any `json:"metadata" validate:"dive,keys,keymax=100,endkeys,nonested,valuemax=2000"` } // @name UpdateProductInput
UpdateProductInput is a struct design to encapsulate request update payload data.
swagger:model UpdateProductInput @Description UpdateProductInput is the input payload to update a product.