# README
Go API client for openapi
Moov Accounts is an HTTP service which represents both a general ledger and chart of accounts for customers. The service is designed to abstract over various core systems and provide a uniform API for developers.
Overview
This API client was generated by the OpenAPI Generator project. By using the OpenAPI-spec from a remote server, you can easily generate an API client.
- API version: 1.0.0
- Package version: 1.0.0
- Build package: org.openapitools.codegen.languages.GoClientCodegen For more information, please visit https://groups.google.com/forum/#!forum/moov-users
Installation
Install the following dependencies:
go get github.com/stretchr/testify/assert
go get golang.org/x/oauth2
go get golang.org/x/net/context
go get github.com/antihax/optional
Put the package under your project folder and add the following in import:
import "./openapi"
Documentation for API Endpoints
All URIs are relative to http://localhost:8085
Class | Method | HTTP request | Description |
---|---|---|---|
AccountsApi | CreateAccount | Post /accounts | Create a new account for a Customer |
AccountsApi | CreateTransaction | Post /accounts/transactions | Post a transaction against multiple accounts. All transaction lines must sum to zero. No money is created or destroyed in a transaction - only moved from account to account. Accounts can be referred to in a Transaction without creating them first. |
AccountsApi | GetAccountTransactions | Get /accounts/{accountID}/transactions | Get transactions for an account. Ordered descending from their posted date. |
AccountsApi | Ping | Get /ping | Ping the Accounts service to check if running |
AccountsApi | ReverseTransaction | Post /accounts/transactions/{transaction_id}/reversal | Reverse a transaction by debiting the credited and crediting the debited amounts among all accounts involved. |
AccountsApi | SearchAccounts | Get /accounts/search | Search for account which matches all query parameters |
Documentation For Models
- Account
- AccountAddress
- CreateAccount
- CreateAccountAddress
- CreatePhone
- CreateTransaction
- Error
- Phone
- Transaction
- TransactionLine
Documentation For Authorization
Endpoints do not require authorization.
Author
# Functions
CacheExpires helper function to determine remaining time before repeating a request.
NewAPIClient creates a new API client.
NewAPIResponse returns a new APIResonse object.
NewAPIResponseWithError returns a new APIResponse object with the provided error message.
NewConfiguration returns a new Configuration object.
# Variables
ContextAccessToken takes a string oauth2 access token as authentication for the request.
ContextAPIKey takes an APIKey as authentication for the request.
ContextBasicAuth takes BasicAuth as authentication for the request.
ContextOAuth2 takes an oauth2.TokenSource as authentication for the request.
# Structs
Account struct for Account.
AccountAddress struct for AccountAddress.
APIClient manages communication with the Simple Core System API API v1.0.0 In most cases there should be only one, shared, APIClient.
APIKey provides API key based authentication to a request passed via context using ContextAPIKey.
APIResponse stores the API response returned by the server.
BasicAuth provides basic http authentication to a request passed via context using ContextBasicAuth.
Configuration stores the configuration of the API client.
CreateAccount struct for CreateAccount.
CreateAccountAddress struct for CreateAccountAddress.
CreateAccountOpts Optional parameters for the method 'CreateAccount'.
CreatePhone struct for CreatePhone.
CreateTransaction struct for CreateTransaction.
CreateTransactionOpts Optional parameters for the method 'CreateTransaction'.
Error struct for Error.
GenericOpenAPIError Provides access to the body, error and model on returned errors.
GetAccountTransactionsOpts Optional parameters for the method 'GetAccountTransactions'.
Phone struct for Phone.
ReverseTransactionOpts Optional parameters for the method 'ReverseTransaction'.
SearchAccountsOpts Optional parameters for the method 'SearchAccounts'.
Transaction struct for Transaction.
TransactionLine struct for TransactionLine.
# Type aliases
AccountsApiService AccountsApi service.