Documentation ¶
Index ¶
- type API
- type APIImplementation
- func (c *APIImplementation) Call(method, path, accessToken string, additionalHeader map[string]string, ...) error
- func (c *APIImplementation) CallRaw(method, path, contentType string, headers http.Header, body io.Reader, ...) error
- func (c *APIImplementation) Do(req *http.Request, v interface{}) error
- func (c *APIImplementation) NewRequest(method, path, contentType string, headers http.Header, body io.Reader) (*http.Request, error)
- type AccountStatement
- type AccountStatementOfflineRequest
- type AccountStatementOfflineResponse
- type AccountStatementRequest
- type AccountStatementResponse
- type AmendmentTeleTransferAmendCashTransfer
- type Auth
- type AuthToken
- type BalanceFailedBalanceInformationResponse
- type BalanceInformationRequest
- type BalanceInformationResponse
- type BalanceSuccessBalanceInformationResponse
- type BeneficiaryAccountRequest
- type BeneficiaryAccountResponse
- type BeneficiaryInquiryAccountRequest
- type BeneficiaryInquiryAccountResponse
- type BeneficiaryInquiryTransactionResponse
- type BeneficiaryTeleTransferAmendCashTransfer
- type BeneficiaryTeleTransferCashTransferRequest
- type BeneficiaryTeleTransferCashTransferResponse
- type Config
- type Currency
- type DetailsBill
- type DomesticFundTransferRequest
- type DomesticFundTransferResponse
- type Error
- type ErrorLang
- type FIInquiryAccountBalanceRequest
- type FIInquiryAccountBalanceResponse
- type ForeignExchangeRateRequest
- type ForeignExchangeRateResponse
- type FundTransferRequest
- type FundTransferResponse
- type InquiryAccountBalanceRequest
- type InquiryAccountBalanceResponse
- type InquiryAccountRequest
- type InquiryAccountResponse
- type InquiryDomesticAccountRequest
- type InquiryDomesticAccountResponse
- type InquiryStatusPaymentRequest
- type InquiryStatusPaymentResponse
- type InquiryTransactionRequest
- type InquiryTransactionResponse
- type InquiryTransferStatusRequest
- type InquiryTransferStatusResponse
- type RateDetails
- type ReasonInquiryTransferStatusResponse
- type SenderAccountRequest
- type SenderInquiryTransactionResponse
- type SenderTeleTransferAmendCashTransfer
- type SenderTeleTransferCashTransferRequest
- type TeleTransferAccountRequest
- type TeleTransferAccountResponse
- type TeleTransferAmendCashTransferRequest
- type TeleTransferAmendCashTransferResponse
- type TeleTransferCancelCashTransferRequest
- type TeleTransferCancelCashTransferResponse
- type TeleTransferCashTransferRequest
- type TeleTransferCashTransferResponse
- type Transaction1TeleTransferAmendCashTransfer
- type Transaction2TTAmendCashTransfer
- type TransactionAccountRequest
- type TransactionAccountResponse
- type TransactionInquiryTransactionRequest
- type TransactionTTAmendCashTransferResponse
- type TransactionTTInquiryTransactionResponse
- type TransactionTeleTransferCancelCashTransferRequest
- type TransactionTeleTransferCancelCashTransferResponse
- type TransactionTeleTransferCashTransferRequest
- type TransactionTeleTransferCashTransferResponse
- type VAInquiryStatusPaymentResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type API ¶
type API interface { //Call(method, path string, body io.Reader, v interface{}) error Call(method, path string, body []byte, v interface{}) error CallRaw(method, path string, headers http.Header, body io.Reader, v interface{}) error }
API is an interface for making call to BCA API
type APIImplementation ¶
type APIImplementation struct { APIKey string APISecret string OriginHost string URL string HTTPClient *http.Client LogLevel int Logger *log.Logger }
APIImplementation represents config that used for HTTP client needs
func NewAPI ¶
func NewAPI(cfg Config) APIImplementation
NewAPI is used to initialize new APIImplementation
func (*APIImplementation) Call ¶
func (c *APIImplementation) Call(method, path, accessToken string, additionalHeader map[string]string, body []byte, v interface{}) error
Call is the implementation for invoking BCA API with its authentication func (c *APIImplementation) Call(method, path, accessToken string, body io.Reader, v interface{}) error {
func (*APIImplementation) CallRaw ¶
func (c *APIImplementation) CallRaw(method, path, contentType string, headers http.Header, body io.Reader, v interface{}) error
CallRaw is the implementation for invoking API without any wrapper
type AccountStatement ¶
type AccountStatement struct { TransactionDate string BranchCode string TransactionType string TransactionAmount float64 `json:",string"` TransactionName string Trailer string }
AccountStatement represents account statement information
type AccountStatementOfflineRequest ¶
type AccountStatementOfflineRequest struct { AccountNumber string StartDate time.Time EndDate time.Time }
AccountStatementOfflineRequest is to get your bulk statement in form of file for a period up to 7 days
type AccountStatementOfflineResponse ¶
AccountStatementOfflineResponse is to get your bulk statement in form of file for a period up to 7 days
type AccountStatementRequest ¶
type AccountStatementRequest struct { CorporateID string AccountNumber string StartDate time.Time EndDate time.Time }
AccountStatementRequest is to get your KlikBCA Bisnis account statement for a period up to 31 days
type AccountStatementResponse ¶
type AccountStatementResponse struct { Error Currency string StartBalance float64 `json:",string"` StartDate string EndDate string Data []AccountStatement }
AccountStatementResponse is to get your KlikBCA Bisnis account statement for a period up to 31 days
type AmendmentTeleTransferAmendCashTransfer ¶
type AmendmentTeleTransferAmendCashTransfer struct { SenderDetails SenderTeleTransferAmendCashTransfer BeneficiaryDetails BeneficiaryTeleTransferAmendCashTransfer TransactionDetails Transaction1TeleTransferAmendCashTransfer }
AmendmentTeleTransferAmendCashTransfer represents amendment details to amend cash-transfer
type Auth ¶
type Auth struct { CorporateID string AccessCode string BranchCode string UserID string LocalID string }
Auth represents authentication info used in FIRe transaction
type AuthToken ¶
type AuthToken struct { Error AccessToken string `json:"access_token"` TokenType string `json:"token_type"` ExpiresIn int `json:"expires_in"` Scope string `json:"scope"` }
AuthToken represents response of BCA OAuth 2.0 response message
type BalanceFailedBalanceInformationResponse ¶
type BalanceFailedBalanceInformationResponse struct { Indonesian string English string AccountNumber string }
BalanceFailedBBBalanceInformationResponse represents account balance details when it cannot be retrieved
type BalanceInformationRequest ¶
BalanceInformationRequest is to get your KlikBCA Bisnis account balance information with maximum of 20 accounts in a request
type BalanceInformationResponse ¶
type BalanceInformationResponse struct { Error AccountDetailDataSuccess []BalanceSuccessBalanceInformationResponse `json:",omitempty"` AccountDetailDataFailed []BalanceFailedBalanceInformationResponse `json:",omitempty"` }
BalanceInformationResponse is to get your KlikBCA Bisnis account balance information with maximum of 20 accounts in a request
type BalanceSuccessBalanceInformationResponse ¶
type BalanceSuccessBalanceInformationResponse struct { AccountNumber string Currency string Balance float64 `json:",string"` AvailableBalance float64 `json:",string"` FloatAmount float64 `json:",string"` HoldAmount float64 `json:",string"` Plafon float64 `json:",string"` Indonesian string English string }
BalanceSuccessBBBalanceInformationResponse represents account balance details when it is successfully retrieved
type BeneficiaryAccountRequest ¶
type BeneficiaryAccountRequest struct { Name string DateOfBirth string Address1 string Address2 string City string StateID string PostalCode string CountryID string Mobile string IdentificationType string IdentificationNumber string NationalityID string Occupation string BankCodeType string BankCodeValue string BankCountryID string BankAddress string BankCity string AccountNumber string }
BeneficiaryAccountRequest represents beneficiary details used in TTAccountRequest
type BeneficiaryAccountResponse ¶
type BeneficiaryAccountResponse struct { Name string AccountNumber string ServerBeneAccountName string }
BeneficiaryTTAccountResponse represents beneficiary details for response message
type BeneficiaryInquiryAccountRequest ¶
type BeneficiaryInquiryAccountRequest struct { BankCodeType string BankCodeValue string AccountNumber string }
BeneficiaryInquiryAccountRequest represents beneficiary details to inquire account(s)
type BeneficiaryInquiryAccountResponse ¶
type BeneficiaryInquiryAccountResponse struct {
ServerBeneAccountName string
}
BeneficiaryInquiryAccountResponse represents response payload to inquire accounts
type BeneficiaryInquiryTransactionResponse ¶
type BeneficiaryInquiryTransactionResponse struct { Name string BankCodeType string BankCodeValue string AccountNumber string }
BeneficiaryInquiryTransactionResponse represents beneficiary details for response message
type BeneficiaryTeleTransferAmendCashTransfer ¶
type BeneficiaryTeleTransferAmendCashTransfer struct { Name string DateOfBirth string Address1 string Address2 string City string StateID string PostalCode string CountryID string Mobile string IdentificationType string IdentificationNumber string NationalityID string Occupation string }
BeneficiaryTTAmendCashTransfer represents beneficiary details to amend cash-transfer
type BeneficiaryTeleTransferCashTransferRequest ¶
type BeneficiaryTeleTransferCashTransferRequest struct { Name string DateOfBirth string Address1 string Address2 string City string StateID string PostalCode string CountryID string Mobile string IdentificationType string IdentificationNumber string NationalityID string Occupation string }
BeneficiaryTeleTransferCashTransferRequest represents beneficiary details used in TTCashTransferRequest
type BeneficiaryTeleTransferCashTransferResponse ¶
type BeneficiaryTeleTransferCashTransferResponse struct {
Name string
}
BeneficiaryTeleTransferCashTransferResponse represents beneficiary details in response message
type Config ¶
type Config struct { ClientID string ClientSecret string APIKey string APISecret string URL string CorporateID string OriginHost string ChannelID string CredentialID string CompanyCode string FIReCorporateID string AccessCode string BranchCode string UserID string LocalID string LogLevel int LogPath string }
Config represents configuration that needed by BCA API
type Currency ¶
type Currency struct { CurrencyCode string /// The currency code e.g. IDR, USD, JPY RateDetail []RateDetails }
type DetailsBill ¶
DetailsBill represents bills details to retrieve Virtual Account payment status
type DomesticFundTransferRequest ¶
type DomesticFundTransferRequest struct { TransactionID string TransactionDate string ReferenceID string SourceAccountNumber string BeneficiaryAccountNumber string BeneficiaryBankCode string BeneficiaryName string Amount float64 `json:",string"` TransferType string BeneficiaryCustType string BeneficiaryCustResidence string CurrencyCode string Remark1 string Remark2 string BeneficiaryEmail string }
DomesticFundTransferRequest is to send fund transfer instructions to BCA using this service. The source of fund transfer must be from your corporate's own deposit account. The recipient may be any deposit account within domestic bank except BCA.
type DomesticFundTransferResponse ¶
type DomesticFundTransferResponse struct { Error TransactionID string TransactionDate string ReferenceID string PPUNumber string }
DomesticFundTransferResponse is to send fund transfer instructions to BCA using this service. The source of fund transfer must be from your corporate's own deposit account. The recipient may be any deposit account within domestic bank except BCA.
type FIInquiryAccountBalanceRequest ¶
type FIInquiryAccountBalanceRequest struct {
AccountNumber string
}
InquiryAccountBalanceRequest represents FID details to inquire account balance
type FIInquiryAccountBalanceResponse ¶
type FIInquiryAccountBalanceResponse struct { CurrencyID string AccountBalance float64 `json:",string"` }
FIInquiryAccountBalanceResponse represents FID details in response message
type FundTransferRequest ¶
type FundTransferRequest struct { CorporateID string SourceAccountNumber string TransactionID string TransactionDate string ReferenceID string CurrencyCode string Amount float64 `json:",string"` BeneficiaryAccountNumber string Remark1 string Remark2 string }
FundTransferRequest is to send fund transfer instructions to BCA using this service. The source of fund transfer must be from your corporate’s own deposit account. The recipient may be any deposit account within BCA
type FundTransferResponse ¶
type FundTransferResponse struct { Error TransactionID string TransactionDate string ReferenceID string Status string }
FundTransferResponse is to send fund transfer instructions to BCA using this service. The source of fund transfer must be from your corporate’s own deposit account. The recipient may be any deposit account within BCA
type InquiryAccountBalanceRequest ¶
type InquiryAccountBalanceRequest struct { Authentication Auth FIDetails FIInquiryAccountBalanceRequest }
InquiryAccountBalanceRequest is to provide service to Inquiry balance for Vostro’s Account.
type InquiryAccountBalanceResponse ¶
type InquiryAccountBalanceResponse struct { Error FIDetails FIInquiryAccountBalanceResponse StatusTransaction string StatusMessage string }
TTInquiryAccountBalanceResponse is to provide service to Inquiry balance for Vostro’s Account.
type InquiryAccountRequest ¶
type InquiryAccountRequest struct { Authentication Auth BeneficiaryDetails BeneficiaryInquiryAccountRequest }
InquiryAccountRequest is to provide service to Inquiry BCA’s Account name or Other Bank Switching’s Account name.
type InquiryAccountResponse ¶
type InquiryAccountResponse struct { Error BeneficiaryDetails BeneficiaryInquiryAccountResponse StatusTransaction string StatusMessage string }
InquiryAccountResponse is to provide service to Inquiry BCA’s Account name or Other Bank Switching’s Account name.
type InquiryDomesticAccountRequest ¶
type InquiryDomesticAccountRequest struct { BeneficiaryAccountNumber string BeneficiaryBankCode string }
InquiryDomesticAccountRequest is to get beneficiary account information including beneficiary account name
type InquiryDomesticAccountResponse ¶
type InquiryDomesticAccountResponse struct { BeneficiaryBankCode string BeneficiaryAccountNumber string BeneficiaryAccountName string }
InquiryDomesticAccountResponse is to get beneficiary account information including beneficiary account name
type InquiryStatusPaymentRequest ¶
type InquiryStatusPaymentRequest struct { CompanyCode string CustomerNumber string RequestID string }
InquiryStatusPaymentRequest represents Virtual Account payment status request message
type InquiryStatusPaymentResponse ¶
type InquiryStatusPaymentResponse struct { Error TransactionData []InquiryStatusPaymentResponse }
VAInquiryStatusPaymentResponse represents Virtual Account payment status response message
type InquiryTransactionRequest ¶
type InquiryTransactionRequest struct { Authentication Auth TransactionDetails TransactionInquiryTransactionRequest }
InquiryTransactionRequest is to provide service to Inquiry Transaction that has been submitted before
type InquiryTransactionResponse ¶
type InquiryTransactionResponse struct { Error SenderDetails SenderInquiryTransactionResponse BeneficiaryDetails BeneficiaryInquiryTransactionResponse TransactionDetails TransactionTTInquiryTransactionResponse StatusTransaction string StatusMessage string }
InquiryTransactionResponse is to provide service to Inquiry Transaction that has been submitted before
type InquiryTransferStatusRequest ¶
type InquiryTransferStatusRequest struct { TransactionID string TransactionDate time.Time TransferType string }
InquiryTransferStatusRequest is to get fund transfer status
type InquiryTransferStatusResponse ¶
type InquiryTransferStatusResponse struct { Error TransactionID string TransactionDate time.Time TransferType string SourceAccountNumber string BeneficiaryAccountNumber string CurrencyCode string Amount float64 `json:",string"` StatusCode string Reason ReasonInquiryTransferStatusResponse }
InquiryTransferStatusResponse is to get fund transfer status
type RateDetails ¶
type ReasonInquiryTransferStatusResponse ¶
ReasonInquiryTransferStatusResponse represents
type SenderAccountRequest ¶
type SenderAccountRequest struct { FirstName string LastName string DateOfBirth string Address1 string Address2 string City string StateID string PostalCode string CountryID string Mobile string IdentificationType string IdentificationNumber string AccountNumber string }
SenderAccountRequest represents sender details used in TTAccountRequest
type SenderInquiryTransactionResponse ¶
SenderInquiryTransactionResponse represents sender details for response message
type SenderTeleTransferAmendCashTransfer ¶
type SenderTeleTransferAmendCashTransfer struct { FirstName string LastName string DateOfBirth string Address1 string Address2 string City string StateID string PostalCode string CountryID string Mobile string IdentificationType string IdentificationNumber string }
SenderTeleTransferAmendCashTransfer represents sender details to amend cash-transfer
type SenderTeleTransferCashTransferRequest ¶
type SenderTeleTransferCashTransferRequest struct { FirstName string LastName string DateOfBirth string Address1 string Address2 string City string StateID string PostalCode string CountryID string Mobile string IdentificationType string IdentificationNumber string }
SenderTeleTransferCashTransferRequest represents sender details used in TTCashTransferRequest
type TeleTransferAccountRequest ¶
type TeleTransferAccountRequest struct { Authentication Auth SenderDetails SenderAccountRequest BeneficiaryDetails BeneficiaryAccountRequest TransactionDetails TransactionAccountRequest }
TeleTransferAccountRequest is to provides service transaction “Transaction to BCA’s Account” and also “Transfer to Other Bank”
type TeleTransferAccountResponse ¶
type TeleTransferAccountResponse struct { Error BeneficiaryDetails BeneficiaryAccountResponse TransactionDetails TransactionAccountResponse StatusTransaction string StatusMessage string }
TTAccountResponse is to provide service transaction “Transaction to BCA’s Account” and also “Transfer to Other Bank”
type TeleTransferAmendCashTransferRequest ¶
type TeleTransferAmendCashTransferRequest struct { Authentication Auth AmendmentDetails AmendmentTeleTransferAmendCashTransfer TransactionDetails Transaction2TTAmendCashTransfer }
TeleTransferAmendCashTransferRequest is to provide service for Amendment “Cash Transfer” to Non account holder
type TeleTransferAmendCashTransferResponse ¶
type TeleTransferAmendCashTransferResponse struct { Error AmendmentDetails AmendmentTeleTransferAmendCashTransfer TransactionDetails Transaction2TTAmendCashTransfer StatusTransaction string StatusMessage string }
TeleTransferAmendCashTransferResponse is to provide service for Amendment “Cash Transfer” to Non account holder
type TeleTransferCancelCashTransferRequest ¶
type TeleTransferCancelCashTransferRequest struct { Authentication Auth TransactionDetails TransactionTeleTransferCancelCashTransferRequest }
TTCancelCashTransferRequest is to provide service for Cancellation “Cash Transfer” to Non account holder
type TeleTransferCancelCashTransferResponse ¶
type TeleTransferCancelCashTransferResponse struct { Error TransactionDetails TransactionTeleTransferCancelCashTransferResponse StatusTransaction string StatusMessage string }
TTCancelCashTransferResponse is to provide service for Cancellation “Cash Transfer” to Non account holder
type TeleTransferCashTransferRequest ¶
type TeleTransferCashTransferRequest struct { Authentication Auth SenderDetails SenderTeleTransferCashTransferRequest BeneficiaryDetails BeneficiaryTeleTransferCashTransferRequest TransactionDetails TransactionTeleTransferCashTransferRequest }
TeleTransferCashTransferRequest is to provide service for transaction “Cash Transfer” to Non account holder.
type TeleTransferCashTransferResponse ¶
type TeleTransferCashTransferResponse struct { Error BeneficiaryDetails BeneficiaryTeleTransferCashTransferResponse TransactionDetails TransactionTeleTransferCashTransferResponse StatusTransaction string StatusMessage string }
TTCashTransferResponse is to provide service for transaction “Cash Transfer” to Non account holder.
type Transaction1TeleTransferAmendCashTransfer ¶
type Transaction1TeleTransferAmendCashTransfer struct { Description1 string Description2 string SecretQuestion string SecretAnswer string }
Transaction1TeleTransferAmendCashTransfer represents transaction details to amend cash-transfer
type Transaction2TTAmendCashTransfer ¶
type Transaction2TTAmendCashTransfer struct {
FormNumber string
}
Transaction2TeleTransferAmendCashTransfer represents transaction details to amend cash-transfer
type TransactionAccountRequest ¶
type TransactionAccountRequest struct { CurrencyID string Amount float64 `json:",string"` PurposeCode string Description1 string Description2 string DetailOfCharges string SourceOfFund string FormNumber string }
TransactionTTAccountRequest represents transaction details used in TTAccountRequest
type TransactionAccountResponse ¶
type TransactionAccountResponse struct { CurrencyID string Amount float64 `json:",string"` Description1 string Description2 string FormNumber string ReferenceNumber string ReleaseDateTime string StatusTransaction string `json:",omitempty"` StatusMessage string `json:",omitempty"` }
TransactionTTAccountResponse represents transaction details for response message
type TransactionInquiryTransactionRequest ¶
TransactionTTInquiryTransactionRequest represents transaction details to inquire transaction
type TransactionTTAmendCashTransferResponse ¶
type TransactionTTAmendCashTransferResponse struct { Description1 string Description2 string SecretQuestion string SecretAnswer string FormNumber string }
TransactionTTAmendCashTransferResponse represents transaction details to amend cash-transfer
type TransactionTTInquiryTransactionResponse ¶
type TransactionTTInquiryTransactionResponse struct { AmountPaid float64 `json:",string"` CurrencyID string ReleaseDateTime string LocalID string FormNumber string ReferenceNumber string PIN string Description1 string Description2 string }
TransactionInquiryTransactionResponse represents transaction details for response message
type TransactionTeleTransferCancelCashTransferRequest ¶
type TransactionTeleTransferCancelCashTransferRequest struct { FormNumber string Amount float64 `json:",string"` CurrencyID string }
TransactionTTCancelCashTransferRequest represents transaction details to cancel cash-transfer
type TransactionTeleTransferCancelCashTransferResponse ¶
type TransactionTeleTransferCancelCashTransferResponse struct { FormNumber string ReleaseDateTime string }
TransactionTTCancelCashTransferResponse represents transaction details to cancel cash-transfer
type TransactionTeleTransferCashTransferRequest ¶
type TransactionTeleTransferCashTransferRequest struct { PIN string SecretQuestion string SecretAnswer string CurrencyID string Amount float64 `json:",string"` PurposeCode string Description1 string Description2 string DetailOfCharges string SourceOfFund string FormNumber string }
TransactionTeleTransferCashTransferRequest represents transaction details used in TTCashTransferRequest
type TransactionTeleTransferCashTransferResponse ¶
type TransactionTeleTransferCashTransferResponse struct { PIN string CurrencyID string Amount float64 `json:",string"` Description1 string Description2 string FormNumber string ReferenceNumber string ReleaseDateTime string }
TransactionTeleTransferCashTransferResponse represents transaction details in response message
type VAInquiryStatusPaymentResponse ¶
type VAInquiryStatusPaymentResponse struct { DetailBills []DetailsBill RequestID string TransactionDate string PaymentFlagStatus string Reference string TotalAmount float64 `json:",string"` PaidAmount float64 `json:",string"` }
VAInquiryStatusPaymentResponse represents Virtual Account transaction info