Bump version
This commit is contained in:
parent
04e92891e3
commit
21371e5c22
46
api_about.go
46
api_about.go
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,16 +7,16 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -26,6 +25,7 @@ var (
|
||||
)
|
||||
|
||||
type AboutApiService service
|
||||
|
||||
/*
|
||||
AboutApiService System information end point.
|
||||
Returns general system information and versions of the (supporting) software.
|
||||
@ -93,7 +93,7 @@ func (a *AboutApiService) GetAbout(ctx context.Context, localVarOptionals *About
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -106,7 +106,7 @@ func (a *AboutApiService) GetAbout(ctx context.Context, localVarOptionals *About
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -116,7 +116,7 @@ func (a *AboutApiService) GetAbout(ctx context.Context, localVarOptionals *About
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -126,7 +126,7 @@ func (a *AboutApiService) GetAbout(ctx context.Context, localVarOptionals *About
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -136,7 +136,7 @@ func (a *AboutApiService) GetAbout(ctx context.Context, localVarOptionals *About
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -146,7 +146,7 @@ func (a *AboutApiService) GetAbout(ctx context.Context, localVarOptionals *About
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v SystemInfo
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -159,6 +159,7 @@ func (a *AboutApiService) GetAbout(ctx context.Context, localVarOptionals *About
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AboutApiService Cron job endpoint
|
||||
Firefly III has one endpoint for its various cron related tasks. Send a GET to this endpoint to run the cron. The cron requires the CLI token to be present. The cron job will fire for all users.
|
||||
@ -238,7 +239,7 @@ func (a *AboutApiService) GetCron(ctx context.Context, cliToken string, localVar
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -251,7 +252,7 @@ func (a *AboutApiService) GetCron(ctx context.Context, cliToken string, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v CronResult
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -261,7 +262,7 @@ func (a *AboutApiService) GetCron(ctx context.Context, cliToken string, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -271,7 +272,7 @@ func (a *AboutApiService) GetCron(ctx context.Context, cliToken string, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -281,7 +282,7 @@ func (a *AboutApiService) GetCron(ctx context.Context, cliToken string, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -291,7 +292,7 @@ func (a *AboutApiService) GetCron(ctx context.Context, cliToken string, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -304,6 +305,7 @@ func (a *AboutApiService) GetCron(ctx context.Context, cliToken string, localVar
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AboutApiService Currently authenticated user endpoint.
|
||||
Returns the currently authenticated user.
|
||||
@ -371,7 +373,7 @@ func (a *AboutApiService) GetCurrentUser(ctx context.Context, localVarOptionals
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -384,7 +386,7 @@ func (a *AboutApiService) GetCurrentUser(ctx context.Context, localVarOptionals
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -394,7 +396,7 @@ func (a *AboutApiService) GetCurrentUser(ctx context.Context, localVarOptionals
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -404,7 +406,7 @@ func (a *AboutApiService) GetCurrentUser(ctx context.Context, localVarOptionals
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -414,7 +416,7 @@ func (a *AboutApiService) GetCurrentUser(ctx context.Context, localVarOptionals
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -424,7 +426,7 @@ func (a *AboutApiService) GetCurrentUser(ctx context.Context, localVarOptionals
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v UserSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,15 +7,15 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -25,6 +24,7 @@ var (
|
||||
)
|
||||
|
||||
type AutocompleteApiService service
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all accounts of the user returned in a basic auto-complete array.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -111,7 +111,7 @@ func (a *AutocompleteApiService) GetAccountsAC(ctx context.Context, localVarOpti
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -124,7 +124,7 @@ func (a *AutocompleteApiService) GetAccountsAC(ctx context.Context, localVarOpti
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -134,7 +134,7 @@ func (a *AutocompleteApiService) GetAccountsAC(ctx context.Context, localVarOpti
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -144,7 +144,7 @@ func (a *AutocompleteApiService) GetAccountsAC(ctx context.Context, localVarOpti
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -154,7 +154,7 @@ func (a *AutocompleteApiService) GetAccountsAC(ctx context.Context, localVarOpti
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -164,7 +164,7 @@ func (a *AutocompleteApiService) GetAccountsAC(ctx context.Context, localVarOpti
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompleteAccount
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -177,6 +177,7 @@ func (a *AutocompleteApiService) GetAccountsAC(ctx context.Context, localVarOpti
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all bills of the user returned in a basic auto-complete array.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -253,7 +254,7 @@ func (a *AutocompleteApiService) GetBillsAC(ctx context.Context, localVarOptiona
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -266,7 +267,7 @@ func (a *AutocompleteApiService) GetBillsAC(ctx context.Context, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -276,7 +277,7 @@ func (a *AutocompleteApiService) GetBillsAC(ctx context.Context, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -286,7 +287,7 @@ func (a *AutocompleteApiService) GetBillsAC(ctx context.Context, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -296,7 +297,7 @@ func (a *AutocompleteApiService) GetBillsAC(ctx context.Context, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -306,7 +307,7 @@ func (a *AutocompleteApiService) GetBillsAC(ctx context.Context, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompleteBill
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -319,6 +320,7 @@ func (a *AutocompleteApiService) GetBillsAC(ctx context.Context, localVarOptiona
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all budgets of the user returned in a basic auto-complete array.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -395,7 +397,7 @@ func (a *AutocompleteApiService) GetBudgetsAC(ctx context.Context, localVarOptio
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -408,7 +410,7 @@ func (a *AutocompleteApiService) GetBudgetsAC(ctx context.Context, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -418,7 +420,7 @@ func (a *AutocompleteApiService) GetBudgetsAC(ctx context.Context, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -428,7 +430,7 @@ func (a *AutocompleteApiService) GetBudgetsAC(ctx context.Context, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -438,7 +440,7 @@ func (a *AutocompleteApiService) GetBudgetsAC(ctx context.Context, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -448,7 +450,7 @@ func (a *AutocompleteApiService) GetBudgetsAC(ctx context.Context, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompleteBudget
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -461,6 +463,7 @@ func (a *AutocompleteApiService) GetBudgetsAC(ctx context.Context, localVarOptio
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all categories of the user returned in a basic auto-complete array.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -537,7 +540,7 @@ func (a *AutocompleteApiService) GetCategoriesAC(ctx context.Context, localVarOp
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -550,7 +553,7 @@ func (a *AutocompleteApiService) GetCategoriesAC(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -560,7 +563,7 @@ func (a *AutocompleteApiService) GetCategoriesAC(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -570,7 +573,7 @@ func (a *AutocompleteApiService) GetCategoriesAC(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -580,7 +583,7 @@ func (a *AutocompleteApiService) GetCategoriesAC(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -590,7 +593,7 @@ func (a *AutocompleteApiService) GetCategoriesAC(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompleteCategory
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -603,6 +606,7 @@ func (a *AutocompleteApiService) GetCategoriesAC(ctx context.Context, localVarOp
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all currencies of the user returned in a basic auto-complete array.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -679,7 +683,7 @@ func (a *AutocompleteApiService) GetCurrenciesAC(ctx context.Context, localVarOp
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -692,7 +696,7 @@ func (a *AutocompleteApiService) GetCurrenciesAC(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -702,7 +706,7 @@ func (a *AutocompleteApiService) GetCurrenciesAC(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -712,7 +716,7 @@ func (a *AutocompleteApiService) GetCurrenciesAC(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -722,7 +726,7 @@ func (a *AutocompleteApiService) GetCurrenciesAC(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -732,7 +736,7 @@ func (a *AutocompleteApiService) GetCurrenciesAC(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompleteCurrency
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -745,6 +749,7 @@ func (a *AutocompleteApiService) GetCurrenciesAC(ctx context.Context, localVarOp
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all currencies of the user returned in a basic auto-complete array. This endpoint is DEPRECATED and I suggest you DO NOT use it.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -821,7 +826,7 @@ func (a *AutocompleteApiService) GetCurrenciesCodeAC(ctx context.Context, localV
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -834,7 +839,7 @@ func (a *AutocompleteApiService) GetCurrenciesCodeAC(ctx context.Context, localV
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -844,7 +849,7 @@ func (a *AutocompleteApiService) GetCurrenciesCodeAC(ctx context.Context, localV
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -854,7 +859,7 @@ func (a *AutocompleteApiService) GetCurrenciesCodeAC(ctx context.Context, localV
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -864,7 +869,7 @@ func (a *AutocompleteApiService) GetCurrenciesCodeAC(ctx context.Context, localV
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -874,7 +879,7 @@ func (a *AutocompleteApiService) GetCurrenciesCodeAC(ctx context.Context, localV
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompleteCurrencyCode
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -887,6 +892,7 @@ func (a *AutocompleteApiService) GetCurrenciesCodeAC(ctx context.Context, localV
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all object groups of the user returned in a basic auto-complete array.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -963,7 +969,7 @@ func (a *AutocompleteApiService) GetObjectGroupsAC(ctx context.Context, localVar
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -976,7 +982,7 @@ func (a *AutocompleteApiService) GetObjectGroupsAC(ctx context.Context, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -986,7 +992,7 @@ func (a *AutocompleteApiService) GetObjectGroupsAC(ctx context.Context, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -996,7 +1002,7 @@ func (a *AutocompleteApiService) GetObjectGroupsAC(ctx context.Context, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1006,7 +1012,7 @@ func (a *AutocompleteApiService) GetObjectGroupsAC(ctx context.Context, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1016,7 +1022,7 @@ func (a *AutocompleteApiService) GetObjectGroupsAC(ctx context.Context, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompleteObjectGroup
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1029,6 +1035,7 @@ func (a *AutocompleteApiService) GetObjectGroupsAC(ctx context.Context, localVar
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all piggy banks of the user returned in a basic auto-complete array.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -1105,7 +1112,7 @@ func (a *AutocompleteApiService) GetPiggiesAC(ctx context.Context, localVarOptio
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1118,7 +1125,7 @@ func (a *AutocompleteApiService) GetPiggiesAC(ctx context.Context, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1128,7 +1135,7 @@ func (a *AutocompleteApiService) GetPiggiesAC(ctx context.Context, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1138,7 +1145,7 @@ func (a *AutocompleteApiService) GetPiggiesAC(ctx context.Context, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1148,7 +1155,7 @@ func (a *AutocompleteApiService) GetPiggiesAC(ctx context.Context, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1158,7 +1165,7 @@ func (a *AutocompleteApiService) GetPiggiesAC(ctx context.Context, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompletePiggy
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1171,6 +1178,7 @@ func (a *AutocompleteApiService) GetPiggiesAC(ctx context.Context, localVarOptio
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all piggy banks of the user returned in a basic auto-complete array complemented with balance information.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -1247,7 +1255,7 @@ func (a *AutocompleteApiService) GetPiggiesBalanceAC(ctx context.Context, localV
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1260,7 +1268,7 @@ func (a *AutocompleteApiService) GetPiggiesBalanceAC(ctx context.Context, localV
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1270,7 +1278,7 @@ func (a *AutocompleteApiService) GetPiggiesBalanceAC(ctx context.Context, localV
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1280,7 +1288,7 @@ func (a *AutocompleteApiService) GetPiggiesBalanceAC(ctx context.Context, localV
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1290,7 +1298,7 @@ func (a *AutocompleteApiService) GetPiggiesBalanceAC(ctx context.Context, localV
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1300,7 +1308,7 @@ func (a *AutocompleteApiService) GetPiggiesBalanceAC(ctx context.Context, localV
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompletePiggyBalance
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1313,6 +1321,7 @@ func (a *AutocompleteApiService) GetPiggiesBalanceAC(ctx context.Context, localV
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all recurring transactions of the user returned in a basic auto-complete array.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -1389,7 +1398,7 @@ func (a *AutocompleteApiService) GetRecurringAC(ctx context.Context, localVarOpt
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1402,7 +1411,7 @@ func (a *AutocompleteApiService) GetRecurringAC(ctx context.Context, localVarOpt
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1412,7 +1421,7 @@ func (a *AutocompleteApiService) GetRecurringAC(ctx context.Context, localVarOpt
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1422,7 +1431,7 @@ func (a *AutocompleteApiService) GetRecurringAC(ctx context.Context, localVarOpt
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1432,7 +1441,7 @@ func (a *AutocompleteApiService) GetRecurringAC(ctx context.Context, localVarOpt
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1442,7 +1451,7 @@ func (a *AutocompleteApiService) GetRecurringAC(ctx context.Context, localVarOpt
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompleteRecurrence
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1455,6 +1464,7 @@ func (a *AutocompleteApiService) GetRecurringAC(ctx context.Context, localVarOpt
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all rule groups of the user returned in a basic auto-complete array.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -1531,7 +1541,7 @@ func (a *AutocompleteApiService) GetRuleGroupsAC(ctx context.Context, localVarOp
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1544,7 +1554,7 @@ func (a *AutocompleteApiService) GetRuleGroupsAC(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1554,7 +1564,7 @@ func (a *AutocompleteApiService) GetRuleGroupsAC(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1564,7 +1574,7 @@ func (a *AutocompleteApiService) GetRuleGroupsAC(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1574,7 +1584,7 @@ func (a *AutocompleteApiService) GetRuleGroupsAC(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1584,7 +1594,7 @@ func (a *AutocompleteApiService) GetRuleGroupsAC(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompleteRuleGroup
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1597,6 +1607,7 @@ func (a *AutocompleteApiService) GetRuleGroupsAC(ctx context.Context, localVarOp
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all rules of the user returned in a basic auto-complete array.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -1673,7 +1684,7 @@ func (a *AutocompleteApiService) GetRulesAC(ctx context.Context, localVarOptiona
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1686,7 +1697,7 @@ func (a *AutocompleteApiService) GetRulesAC(ctx context.Context, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1696,7 +1707,7 @@ func (a *AutocompleteApiService) GetRulesAC(ctx context.Context, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1706,7 +1717,7 @@ func (a *AutocompleteApiService) GetRulesAC(ctx context.Context, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1716,7 +1727,7 @@ func (a *AutocompleteApiService) GetRulesAC(ctx context.Context, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1726,7 +1737,7 @@ func (a *AutocompleteApiService) GetRulesAC(ctx context.Context, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompleteRule
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1739,6 +1750,7 @@ func (a *AutocompleteApiService) GetRulesAC(ctx context.Context, localVarOptiona
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all tags of the user returned in a basic auto-complete array.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -1815,7 +1827,7 @@ func (a *AutocompleteApiService) GetTagAC(ctx context.Context, localVarOptionals
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1828,7 +1840,7 @@ func (a *AutocompleteApiService) GetTagAC(ctx context.Context, localVarOptionals
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1838,7 +1850,7 @@ func (a *AutocompleteApiService) GetTagAC(ctx context.Context, localVarOptionals
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1848,7 +1860,7 @@ func (a *AutocompleteApiService) GetTagAC(ctx context.Context, localVarOptionals
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1858,7 +1870,7 @@ func (a *AutocompleteApiService) GetTagAC(ctx context.Context, localVarOptionals
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1868,7 +1880,7 @@ func (a *AutocompleteApiService) GetTagAC(ctx context.Context, localVarOptionals
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompleteTag
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1881,6 +1893,7 @@ func (a *AutocompleteApiService) GetTagAC(ctx context.Context, localVarOptionals
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all transaction types returned in a basic auto-complete array. English only.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -1957,7 +1970,7 @@ func (a *AutocompleteApiService) GetTransactionTypesAC(ctx context.Context, loca
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1970,7 +1983,7 @@ func (a *AutocompleteApiService) GetTransactionTypesAC(ctx context.Context, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1980,7 +1993,7 @@ func (a *AutocompleteApiService) GetTransactionTypesAC(ctx context.Context, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1990,7 +2003,7 @@ func (a *AutocompleteApiService) GetTransactionTypesAC(ctx context.Context, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2000,7 +2013,7 @@ func (a *AutocompleteApiService) GetTransactionTypesAC(ctx context.Context, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2010,7 +2023,7 @@ func (a *AutocompleteApiService) GetTransactionTypesAC(ctx context.Context, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompleteTransactionType
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2023,6 +2036,7 @@ func (a *AutocompleteApiService) GetTransactionTypesAC(ctx context.Context, loca
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all transaction descriptions of the user returned in a basic auto-complete array.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -2099,7 +2113,7 @@ func (a *AutocompleteApiService) GetTransactionsAC(ctx context.Context, localVar
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -2112,7 +2126,7 @@ func (a *AutocompleteApiService) GetTransactionsAC(ctx context.Context, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2122,7 +2136,7 @@ func (a *AutocompleteApiService) GetTransactionsAC(ctx context.Context, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2132,7 +2146,7 @@ func (a *AutocompleteApiService) GetTransactionsAC(ctx context.Context, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2142,7 +2156,7 @@ func (a *AutocompleteApiService) GetTransactionsAC(ctx context.Context, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2152,7 +2166,7 @@ func (a *AutocompleteApiService) GetTransactionsAC(ctx context.Context, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompleteTransaction
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2165,6 +2179,7 @@ func (a *AutocompleteApiService) GetTransactionsAC(ctx context.Context, localVar
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AutocompleteApiService Returns all transactions, complemented with their ID, of the user returned in a basic auto-complete array. This endpoint is DEPRECATED and I suggest you DO NOT use it.
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
@ -2241,7 +2256,7 @@ func (a *AutocompleteApiService) GetTransactionsIDAC(ctx context.Context, localV
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -2254,7 +2269,7 @@ func (a *AutocompleteApiService) GetTransactionsIDAC(ctx context.Context, localV
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2264,7 +2279,7 @@ func (a *AutocompleteApiService) GetTransactionsIDAC(ctx context.Context, localV
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2274,7 +2289,7 @@ func (a *AutocompleteApiService) GetTransactionsIDAC(ctx context.Context, localV
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2284,7 +2299,7 @@ func (a *AutocompleteApiService) GetTransactionsIDAC(ctx context.Context, localV
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2294,7 +2309,7 @@ func (a *AutocompleteApiService) GetTransactionsIDAC(ctx context.Context, localV
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []AutocompleteTransactionId
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,16 +7,16 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -26,6 +25,7 @@ var (
|
||||
)
|
||||
|
||||
type AvailableBudgetsApiService service
|
||||
|
||||
/*
|
||||
AvailableBudgetsApiService Get a single available budget.
|
||||
Get a single available budget, by ID.
|
||||
@ -95,7 +95,7 @@ func (a *AvailableBudgetsApiService) GetAvailableBudget(ctx context.Context, id
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -108,7 +108,7 @@ func (a *AvailableBudgetsApiService) GetAvailableBudget(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -118,7 +118,7 @@ func (a *AvailableBudgetsApiService) GetAvailableBudget(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -128,7 +128,7 @@ func (a *AvailableBudgetsApiService) GetAvailableBudget(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -138,7 +138,7 @@ func (a *AvailableBudgetsApiService) GetAvailableBudget(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -148,7 +148,7 @@ func (a *AvailableBudgetsApiService) GetAvailableBudget(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v AvailableBudgetSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -161,6 +161,7 @@ func (a *AvailableBudgetsApiService) GetAvailableBudget(ctx context.Context, id
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
AvailableBudgetsApiService List all available budget amounts.
|
||||
Firefly III allows users to set the amount that is available to be budgeted in so-called \"available budgets\". For example, the user could have 1200,- available to be divided during the coming month. This amount is used on the /budgets page. This endpoint returns all of these amounts and the periods for which they are set.
|
||||
@ -248,7 +249,7 @@ func (a *AvailableBudgetsApiService) ListAvailableBudget(ctx context.Context, lo
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -261,7 +262,7 @@ func (a *AvailableBudgetsApiService) ListAvailableBudget(ctx context.Context, lo
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -271,7 +272,7 @@ func (a *AvailableBudgetsApiService) ListAvailableBudget(ctx context.Context, lo
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -281,7 +282,7 @@ func (a *AvailableBudgetsApiService) ListAvailableBudget(ctx context.Context, lo
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -291,7 +292,7 @@ func (a *AvailableBudgetsApiService) ListAvailableBudget(ctx context.Context, lo
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -301,7 +302,7 @@ func (a *AvailableBudgetsApiService) ListAvailableBudget(ctx context.Context, lo
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v AvailableBudgetArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,15 +7,15 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -25,6 +24,7 @@ var (
|
||||
)
|
||||
|
||||
type ChartsApiService service
|
||||
|
||||
/*
|
||||
ChartsApiService Dashboard chart with asset account balance information.
|
||||
This endpoint returns the data required to generate a chart with basic asset account balance information.
|
||||
@ -96,7 +96,7 @@ func (a *ChartsApiService) GetChartAccountOverview(ctx context.Context, start st
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -109,7 +109,7 @@ func (a *ChartsApiService) GetChartAccountOverview(ctx context.Context, start st
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -119,7 +119,7 @@ func (a *ChartsApiService) GetChartAccountOverview(ctx context.Context, start st
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -129,7 +129,7 @@ func (a *ChartsApiService) GetChartAccountOverview(ctx context.Context, start st
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -139,7 +139,7 @@ func (a *ChartsApiService) GetChartAccountOverview(ctx context.Context, start st
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -149,7 +149,7 @@ func (a *ChartsApiService) GetChartAccountOverview(ctx context.Context, start st
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v []ChartDataSet
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,16 +7,16 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -26,6 +25,7 @@ var (
|
||||
)
|
||||
|
||||
type CurrenciesApiService service
|
||||
|
||||
/*
|
||||
CurrenciesApiService Make currency default currency.
|
||||
Make this currency the default currency for the user. If the currency is not enabled, it will be enabled as well.
|
||||
@ -95,7 +95,7 @@ func (a *CurrenciesApiService) DefaultCurrency(ctx context.Context, code string,
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -108,7 +108,7 @@ func (a *CurrenciesApiService) DefaultCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 204 {
|
||||
var v CurrencySingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -118,7 +118,7 @@ func (a *CurrenciesApiService) DefaultCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -128,7 +128,7 @@ func (a *CurrenciesApiService) DefaultCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -138,7 +138,7 @@ func (a *CurrenciesApiService) DefaultCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -148,7 +148,7 @@ func (a *CurrenciesApiService) DefaultCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -161,6 +161,7 @@ func (a *CurrenciesApiService) DefaultCurrency(ctx context.Context, code string,
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
CurrenciesApiService Delete a currency.
|
||||
Delete a currency.
|
||||
@ -181,7 +182,6 @@ func (a *CurrenciesApiService) DeleteCurrency(ctx context.Context, code string,
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -228,7 +228,6 @@ func (a *CurrenciesApiService) DeleteCurrency(ctx context.Context, code string,
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -236,7 +235,7 @@ func (a *CurrenciesApiService) DeleteCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -246,7 +245,7 @@ func (a *CurrenciesApiService) DeleteCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -256,7 +255,7 @@ func (a *CurrenciesApiService) DeleteCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -266,7 +265,7 @@ func (a *CurrenciesApiService) DeleteCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -279,6 +278,7 @@ func (a *CurrenciesApiService) DeleteCurrency(ctx context.Context, code string,
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
CurrenciesApiService Disable a currency.
|
||||
Disable a currency.
|
||||
@ -348,7 +348,7 @@ func (a *CurrenciesApiService) DisableCurrency(ctx context.Context, code string,
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -361,7 +361,7 @@ func (a *CurrenciesApiService) DisableCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 204 {
|
||||
var v CurrencySingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -371,7 +371,7 @@ func (a *CurrenciesApiService) DisableCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -381,7 +381,7 @@ func (a *CurrenciesApiService) DisableCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -391,7 +391,7 @@ func (a *CurrenciesApiService) DisableCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -401,7 +401,7 @@ func (a *CurrenciesApiService) DisableCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -414,6 +414,7 @@ func (a *CurrenciesApiService) DisableCurrency(ctx context.Context, code string,
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
CurrenciesApiService Enable a single currency.
|
||||
Enable a single currency.
|
||||
@ -483,7 +484,7 @@ func (a *CurrenciesApiService) EnableCurrency(ctx context.Context, code string,
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -496,7 +497,7 @@ func (a *CurrenciesApiService) EnableCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 204 {
|
||||
var v CurrencySingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -506,7 +507,7 @@ func (a *CurrenciesApiService) EnableCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -516,7 +517,7 @@ func (a *CurrenciesApiService) EnableCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -526,7 +527,7 @@ func (a *CurrenciesApiService) EnableCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -536,7 +537,7 @@ func (a *CurrenciesApiService) EnableCurrency(ctx context.Context, code string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -549,6 +550,7 @@ func (a *CurrenciesApiService) EnableCurrency(ctx context.Context, code string,
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
CurrenciesApiService Get a single currency.
|
||||
Get a single currency.
|
||||
@ -618,7 +620,7 @@ func (a *CurrenciesApiService) GetCurrency(ctx context.Context, code string, loc
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -631,7 +633,7 @@ func (a *CurrenciesApiService) GetCurrency(ctx context.Context, code string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v CurrencySingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -641,7 +643,7 @@ func (a *CurrenciesApiService) GetCurrency(ctx context.Context, code string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -651,7 +653,7 @@ func (a *CurrenciesApiService) GetCurrency(ctx context.Context, code string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -661,7 +663,7 @@ func (a *CurrenciesApiService) GetCurrency(ctx context.Context, code string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -671,7 +673,7 @@ func (a *CurrenciesApiService) GetCurrency(ctx context.Context, code string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -684,6 +686,7 @@ func (a *CurrenciesApiService) GetCurrency(ctx context.Context, code string, loc
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
CurrenciesApiService Get the user's default currency.
|
||||
Get the user's default currency.
|
||||
@ -751,7 +754,7 @@ func (a *CurrenciesApiService) GetDefaultCurrency(ctx context.Context, localVarO
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -764,7 +767,7 @@ func (a *CurrenciesApiService) GetDefaultCurrency(ctx context.Context, localVarO
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v CurrencySingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -774,7 +777,7 @@ func (a *CurrenciesApiService) GetDefaultCurrency(ctx context.Context, localVarO
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -784,7 +787,7 @@ func (a *CurrenciesApiService) GetDefaultCurrency(ctx context.Context, localVarO
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -794,7 +797,7 @@ func (a *CurrenciesApiService) GetDefaultCurrency(ctx context.Context, localVarO
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -804,7 +807,7 @@ func (a *CurrenciesApiService) GetDefaultCurrency(ctx context.Context, localVarO
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -817,6 +820,7 @@ func (a *CurrenciesApiService) GetDefaultCurrency(ctx context.Context, localVarO
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
CurrenciesApiService List all accounts with this currency.
|
||||
List all accounts with this currency.
|
||||
@ -906,7 +910,7 @@ func (a *CurrenciesApiService) ListAccountByCurrency(ctx context.Context, code s
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -919,7 +923,7 @@ func (a *CurrenciesApiService) ListAccountByCurrency(ctx context.Context, code s
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v AccountArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -929,7 +933,7 @@ func (a *CurrenciesApiService) ListAccountByCurrency(ctx context.Context, code s
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -939,7 +943,7 @@ func (a *CurrenciesApiService) ListAccountByCurrency(ctx context.Context, code s
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -949,7 +953,7 @@ func (a *CurrenciesApiService) ListAccountByCurrency(ctx context.Context, code s
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -959,7 +963,7 @@ func (a *CurrenciesApiService) ListAccountByCurrency(ctx context.Context, code s
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -972,6 +976,7 @@ func (a *CurrenciesApiService) ListAccountByCurrency(ctx context.Context, code s
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
CurrenciesApiService List all available budgets with this currency.
|
||||
List all available budgets with this currency.
|
||||
@ -1051,7 +1056,7 @@ func (a *CurrenciesApiService) ListAvailableBudgetByCurrency(ctx context.Context
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1064,7 +1069,7 @@ func (a *CurrenciesApiService) ListAvailableBudgetByCurrency(ctx context.Context
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v AvailableBudgetArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1074,7 +1079,7 @@ func (a *CurrenciesApiService) ListAvailableBudgetByCurrency(ctx context.Context
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1084,7 +1089,7 @@ func (a *CurrenciesApiService) ListAvailableBudgetByCurrency(ctx context.Context
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1094,7 +1099,7 @@ func (a *CurrenciesApiService) ListAvailableBudgetByCurrency(ctx context.Context
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1104,7 +1109,7 @@ func (a *CurrenciesApiService) ListAvailableBudgetByCurrency(ctx context.Context
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1117,6 +1122,7 @@ func (a *CurrenciesApiService) ListAvailableBudgetByCurrency(ctx context.Context
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
CurrenciesApiService List all bills with this currency.
|
||||
List all bills with this currency.
|
||||
@ -1196,7 +1202,7 @@ func (a *CurrenciesApiService) ListBillByCurrency(ctx context.Context, code stri
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1209,7 +1215,7 @@ func (a *CurrenciesApiService) ListBillByCurrency(ctx context.Context, code stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v BillArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1219,7 +1225,7 @@ func (a *CurrenciesApiService) ListBillByCurrency(ctx context.Context, code stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1229,7 +1235,7 @@ func (a *CurrenciesApiService) ListBillByCurrency(ctx context.Context, code stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1239,7 +1245,7 @@ func (a *CurrenciesApiService) ListBillByCurrency(ctx context.Context, code stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1249,7 +1255,7 @@ func (a *CurrenciesApiService) ListBillByCurrency(ctx context.Context, code stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1262,6 +1268,7 @@ func (a *CurrenciesApiService) ListBillByCurrency(ctx context.Context, code stri
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
CurrenciesApiService List all budget limits with this currency
|
||||
List all budget limits with this currency
|
||||
@ -1351,7 +1358,7 @@ func (a *CurrenciesApiService) ListBudgetLimitByCurrency(ctx context.Context, co
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1364,7 +1371,7 @@ func (a *CurrenciesApiService) ListBudgetLimitByCurrency(ctx context.Context, co
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v BudgetLimitArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1374,7 +1381,7 @@ func (a *CurrenciesApiService) ListBudgetLimitByCurrency(ctx context.Context, co
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1384,7 +1391,7 @@ func (a *CurrenciesApiService) ListBudgetLimitByCurrency(ctx context.Context, co
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1394,7 +1401,7 @@ func (a *CurrenciesApiService) ListBudgetLimitByCurrency(ctx context.Context, co
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1404,7 +1411,7 @@ func (a *CurrenciesApiService) ListBudgetLimitByCurrency(ctx context.Context, co
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1417,6 +1424,7 @@ func (a *CurrenciesApiService) ListBudgetLimitByCurrency(ctx context.Context, co
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
CurrenciesApiService List all currencies.
|
||||
List all currencies.
|
||||
@ -1494,7 +1502,7 @@ func (a *CurrenciesApiService) ListCurrency(ctx context.Context, localVarOptiona
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1507,7 +1515,7 @@ func (a *CurrenciesApiService) ListCurrency(ctx context.Context, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v CurrencyArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1517,7 +1525,7 @@ func (a *CurrenciesApiService) ListCurrency(ctx context.Context, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1527,7 +1535,7 @@ func (a *CurrenciesApiService) ListCurrency(ctx context.Context, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1537,7 +1545,7 @@ func (a *CurrenciesApiService) ListCurrency(ctx context.Context, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1547,7 +1555,7 @@ func (a *CurrenciesApiService) ListCurrency(ctx context.Context, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1560,6 +1568,7 @@ func (a *CurrenciesApiService) ListCurrency(ctx context.Context, localVarOptiona
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
CurrenciesApiService List all recurring transactions with this currency.
|
||||
List all recurring transactions with this currency.
|
||||
@ -1639,7 +1648,7 @@ func (a *CurrenciesApiService) ListRecurrenceByCurrency(ctx context.Context, cod
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1652,7 +1661,7 @@ func (a *CurrenciesApiService) ListRecurrenceByCurrency(ctx context.Context, cod
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v RecurrenceArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1662,7 +1671,7 @@ func (a *CurrenciesApiService) ListRecurrenceByCurrency(ctx context.Context, cod
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1672,7 +1681,7 @@ func (a *CurrenciesApiService) ListRecurrenceByCurrency(ctx context.Context, cod
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1682,7 +1691,7 @@ func (a *CurrenciesApiService) ListRecurrenceByCurrency(ctx context.Context, cod
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1692,7 +1701,7 @@ func (a *CurrenciesApiService) ListRecurrenceByCurrency(ctx context.Context, cod
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1705,6 +1714,7 @@ func (a *CurrenciesApiService) ListRecurrenceByCurrency(ctx context.Context, cod
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
CurrenciesApiService List all rules with this currency.
|
||||
List all rules with this currency.
|
||||
@ -1784,7 +1794,7 @@ func (a *CurrenciesApiService) ListRuleByCurrency(ctx context.Context, code stri
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1797,7 +1807,7 @@ func (a *CurrenciesApiService) ListRuleByCurrency(ctx context.Context, code stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v RuleArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1807,7 +1817,7 @@ func (a *CurrenciesApiService) ListRuleByCurrency(ctx context.Context, code stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1817,7 +1827,7 @@ func (a *CurrenciesApiService) ListRuleByCurrency(ctx context.Context, code stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1827,7 +1837,7 @@ func (a *CurrenciesApiService) ListRuleByCurrency(ctx context.Context, code stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1837,7 +1847,7 @@ func (a *CurrenciesApiService) ListRuleByCurrency(ctx context.Context, code stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1850,6 +1860,7 @@ func (a *CurrenciesApiService) ListRuleByCurrency(ctx context.Context, code stri
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
CurrenciesApiService List all transactions with this currency.
|
||||
List all transactions with this currency.
|
||||
@ -1944,7 +1955,7 @@ func (a *CurrenciesApiService) ListTransactionByCurrency(ctx context.Context, co
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1957,7 +1968,7 @@ func (a *CurrenciesApiService) ListTransactionByCurrency(ctx context.Context, co
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1967,7 +1978,7 @@ func (a *CurrenciesApiService) ListTransactionByCurrency(ctx context.Context, co
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1977,7 +1988,7 @@ func (a *CurrenciesApiService) ListTransactionByCurrency(ctx context.Context, co
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1987,7 +1998,7 @@ func (a *CurrenciesApiService) ListTransactionByCurrency(ctx context.Context, co
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1997,7 +2008,7 @@ func (a *CurrenciesApiService) ListTransactionByCurrency(ctx context.Context, co
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2010,6 +2021,7 @@ func (a *CurrenciesApiService) ListTransactionByCurrency(ctx context.Context, co
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
CurrenciesApiService Store a new currency
|
||||
Creates a new currency. The data required can be submitted as a JSON body or as a list of parameters.
|
||||
@ -2080,7 +2092,7 @@ func (a *CurrenciesApiService) StoreCurrency(ctx context.Context, body CurrencyS
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -2093,7 +2105,7 @@ func (a *CurrenciesApiService) StoreCurrency(ctx context.Context, body CurrencyS
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v CurrencySingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2103,7 +2115,7 @@ func (a *CurrenciesApiService) StoreCurrency(ctx context.Context, body CurrencyS
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2113,7 +2125,7 @@ func (a *CurrenciesApiService) StoreCurrency(ctx context.Context, body CurrencyS
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2123,7 +2135,7 @@ func (a *CurrenciesApiService) StoreCurrency(ctx context.Context, body CurrencyS
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2133,7 +2145,7 @@ func (a *CurrenciesApiService) StoreCurrency(ctx context.Context, body CurrencyS
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2143,7 +2155,7 @@ func (a *CurrenciesApiService) StoreCurrency(ctx context.Context, body CurrencyS
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2156,6 +2168,7 @@ func (a *CurrenciesApiService) StoreCurrency(ctx context.Context, body CurrencyS
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
CurrenciesApiService Update existing currency.
|
||||
Update existing currency.
|
||||
@ -2228,7 +2241,7 @@ func (a *CurrenciesApiService) UpdateCurrency(ctx context.Context, body Currency
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -2241,7 +2254,7 @@ func (a *CurrenciesApiService) UpdateCurrency(ctx context.Context, body Currency
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v CurrencySingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2251,7 +2264,7 @@ func (a *CurrenciesApiService) UpdateCurrency(ctx context.Context, body Currency
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2261,7 +2274,7 @@ func (a *CurrenciesApiService) UpdateCurrency(ctx context.Context, body Currency
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2271,7 +2284,7 @@ func (a *CurrenciesApiService) UpdateCurrency(ctx context.Context, body Currency
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2281,7 +2294,7 @@ func (a *CurrenciesApiService) UpdateCurrency(ctx context.Context, body Currency
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -2291,7 +2304,7 @@ func (a *CurrenciesApiService) UpdateCurrency(ctx context.Context, body Currency
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
317
api_insight.go
317
api_insight.go
File diff suppressed because it is too large
Load Diff
154
api_links.go
154
api_links.go
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,16 +7,16 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -26,6 +25,7 @@ var (
|
||||
)
|
||||
|
||||
type LinksApiService service
|
||||
|
||||
/*
|
||||
LinksApiService Permanently delete link type.
|
||||
Will permanently delete a link type. The links between transactions will be removed. The transactions themselves remain. You cannot delete some of the system provided link types, indicated by the editable=false flag when you list it.
|
||||
@ -46,7 +46,6 @@ func (a *LinksApiService) DeleteLinkType(ctx context.Context, id string, localVa
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -93,7 +92,6 @@ func (a *LinksApiService) DeleteLinkType(ctx context.Context, id string, localVa
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -101,7 +99,7 @@ func (a *LinksApiService) DeleteLinkType(ctx context.Context, id string, localVa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -111,7 +109,7 @@ func (a *LinksApiService) DeleteLinkType(ctx context.Context, id string, localVa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -121,7 +119,7 @@ func (a *LinksApiService) DeleteLinkType(ctx context.Context, id string, localVa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -131,7 +129,7 @@ func (a *LinksApiService) DeleteLinkType(ctx context.Context, id string, localVa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -144,6 +142,7 @@ func (a *LinksApiService) DeleteLinkType(ctx context.Context, id string, localVa
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
LinksApiService Permanently delete link between transactions.
|
||||
Will permanently delete link. Transactions remain.
|
||||
@ -164,7 +163,6 @@ func (a *LinksApiService) DeleteTransactionLink(ctx context.Context, id string,
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -211,7 +209,6 @@ func (a *LinksApiService) DeleteTransactionLink(ctx context.Context, id string,
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -219,7 +216,7 @@ func (a *LinksApiService) DeleteTransactionLink(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -229,7 +226,7 @@ func (a *LinksApiService) DeleteTransactionLink(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -239,7 +236,7 @@ func (a *LinksApiService) DeleteTransactionLink(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -249,7 +246,7 @@ func (a *LinksApiService) DeleteTransactionLink(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -262,6 +259,7 @@ func (a *LinksApiService) DeleteTransactionLink(ctx context.Context, id string,
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
LinksApiService Get single a link type.
|
||||
Returns a single link type by its ID.
|
||||
@ -331,7 +329,7 @@ func (a *LinksApiService) GetLinkType(ctx context.Context, id string, localVarOp
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -344,7 +342,7 @@ func (a *LinksApiService) GetLinkType(ctx context.Context, id string, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v LinkTypeSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -354,7 +352,7 @@ func (a *LinksApiService) GetLinkType(ctx context.Context, id string, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -364,7 +362,7 @@ func (a *LinksApiService) GetLinkType(ctx context.Context, id string, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -374,7 +372,7 @@ func (a *LinksApiService) GetLinkType(ctx context.Context, id string, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -384,7 +382,7 @@ func (a *LinksApiService) GetLinkType(ctx context.Context, id string, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -397,6 +395,7 @@ func (a *LinksApiService) GetLinkType(ctx context.Context, id string, localVarOp
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
LinksApiService Get a single link.
|
||||
Returns a single link by its ID.
|
||||
@ -466,7 +465,7 @@ func (a *LinksApiService) GetTransactionLink(ctx context.Context, id string, loc
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -479,7 +478,7 @@ func (a *LinksApiService) GetTransactionLink(ctx context.Context, id string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionLinkSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -489,7 +488,7 @@ func (a *LinksApiService) GetTransactionLink(ctx context.Context, id string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -499,7 +498,7 @@ func (a *LinksApiService) GetTransactionLink(ctx context.Context, id string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -509,7 +508,7 @@ func (a *LinksApiService) GetTransactionLink(ctx context.Context, id string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -519,7 +518,7 @@ func (a *LinksApiService) GetTransactionLink(ctx context.Context, id string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -532,6 +531,7 @@ func (a *LinksApiService) GetTransactionLink(ctx context.Context, id string, loc
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
LinksApiService List all types of links.
|
||||
List all the link types the system has. These include the default ones as well as any new ones.
|
||||
@ -609,7 +609,7 @@ func (a *LinksApiService) ListLinkType(ctx context.Context, localVarOptionals *L
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -622,7 +622,7 @@ func (a *LinksApiService) ListLinkType(ctx context.Context, localVarOptionals *L
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v LinkTypeArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -632,7 +632,7 @@ func (a *LinksApiService) ListLinkType(ctx context.Context, localVarOptionals *L
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -642,7 +642,7 @@ func (a *LinksApiService) ListLinkType(ctx context.Context, localVarOptionals *L
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -652,7 +652,7 @@ func (a *LinksApiService) ListLinkType(ctx context.Context, localVarOptionals *L
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -662,7 +662,7 @@ func (a *LinksApiService) ListLinkType(ctx context.Context, localVarOptionals *L
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -675,6 +675,7 @@ func (a *LinksApiService) ListLinkType(ctx context.Context, localVarOptionals *L
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
LinksApiService List all transactions under this link type.
|
||||
List all transactions under this link type, both the inward and outward transactions.
|
||||
@ -769,7 +770,7 @@ func (a *LinksApiService) ListTransactionByLinkType(ctx context.Context, id stri
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -782,7 +783,7 @@ func (a *LinksApiService) ListTransactionByLinkType(ctx context.Context, id stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -792,7 +793,7 @@ func (a *LinksApiService) ListTransactionByLinkType(ctx context.Context, id stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -802,7 +803,7 @@ func (a *LinksApiService) ListTransactionByLinkType(ctx context.Context, id stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -812,7 +813,7 @@ func (a *LinksApiService) ListTransactionByLinkType(ctx context.Context, id stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -822,7 +823,7 @@ func (a *LinksApiService) ListTransactionByLinkType(ctx context.Context, id stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -835,6 +836,7 @@ func (a *LinksApiService) ListTransactionByLinkType(ctx context.Context, id stri
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
LinksApiService List all transaction links.
|
||||
List all the transaction links.
|
||||
@ -912,7 +914,7 @@ func (a *LinksApiService) ListTransactionLink(ctx context.Context, localVarOptio
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -925,7 +927,7 @@ func (a *LinksApiService) ListTransactionLink(ctx context.Context, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionLinkArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -935,7 +937,7 @@ func (a *LinksApiService) ListTransactionLink(ctx context.Context, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -945,7 +947,7 @@ func (a *LinksApiService) ListTransactionLink(ctx context.Context, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -955,7 +957,7 @@ func (a *LinksApiService) ListTransactionLink(ctx context.Context, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -965,7 +967,7 @@ func (a *LinksApiService) ListTransactionLink(ctx context.Context, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -978,6 +980,7 @@ func (a *LinksApiService) ListTransactionLink(ctx context.Context, localVarOptio
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
LinksApiService Create a new link type
|
||||
Creates a new link type. The data required can be submitted as a JSON body or as a list of parameters (in key=value pairs, like a webform).
|
||||
@ -1048,7 +1051,7 @@ func (a *LinksApiService) StoreLinkType(ctx context.Context, body LinkType, loca
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1061,7 +1064,7 @@ func (a *LinksApiService) StoreLinkType(ctx context.Context, body LinkType, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v LinkTypeSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1071,7 +1074,7 @@ func (a *LinksApiService) StoreLinkType(ctx context.Context, body LinkType, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1081,7 +1084,7 @@ func (a *LinksApiService) StoreLinkType(ctx context.Context, body LinkType, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1091,7 +1094,7 @@ func (a *LinksApiService) StoreLinkType(ctx context.Context, body LinkType, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1101,7 +1104,7 @@ func (a *LinksApiService) StoreLinkType(ctx context.Context, body LinkType, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1111,7 +1114,7 @@ func (a *LinksApiService) StoreLinkType(ctx context.Context, body LinkType, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1124,6 +1127,7 @@ func (a *LinksApiService) StoreLinkType(ctx context.Context, body LinkType, loca
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
LinksApiService Create a new link between transactions
|
||||
Store a new link between two transactions. For this end point you need the journal_id from a transaction.
|
||||
@ -1194,7 +1198,7 @@ func (a *LinksApiService) StoreTransactionLink(ctx context.Context, body Transac
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1207,7 +1211,7 @@ func (a *LinksApiService) StoreTransactionLink(ctx context.Context, body Transac
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionLinkSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1217,7 +1221,7 @@ func (a *LinksApiService) StoreTransactionLink(ctx context.Context, body Transac
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1227,7 +1231,7 @@ func (a *LinksApiService) StoreTransactionLink(ctx context.Context, body Transac
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1237,7 +1241,7 @@ func (a *LinksApiService) StoreTransactionLink(ctx context.Context, body Transac
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1247,7 +1251,7 @@ func (a *LinksApiService) StoreTransactionLink(ctx context.Context, body Transac
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1257,7 +1261,7 @@ func (a *LinksApiService) StoreTransactionLink(ctx context.Context, body Transac
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1270,6 +1274,7 @@ func (a *LinksApiService) StoreTransactionLink(ctx context.Context, body Transac
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
LinksApiService Update existing link type.
|
||||
Used to update a single link type. All fields that are not submitted will be cleared (set to NULL). The model will tell you which fields are mandatory. You cannot update some of the system provided link types, indicated by the editable=false flag when you list it.
|
||||
@ -1342,7 +1347,7 @@ func (a *LinksApiService) UpdateLinkType(ctx context.Context, body LinkTypeUpdat
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1355,7 +1360,7 @@ func (a *LinksApiService) UpdateLinkType(ctx context.Context, body LinkTypeUpdat
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v LinkTypeSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1365,7 +1370,7 @@ func (a *LinksApiService) UpdateLinkType(ctx context.Context, body LinkTypeUpdat
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1375,7 +1380,7 @@ func (a *LinksApiService) UpdateLinkType(ctx context.Context, body LinkTypeUpdat
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1385,7 +1390,7 @@ func (a *LinksApiService) UpdateLinkType(ctx context.Context, body LinkTypeUpdat
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1395,7 +1400,7 @@ func (a *LinksApiService) UpdateLinkType(ctx context.Context, body LinkTypeUpdat
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1405,7 +1410,7 @@ func (a *LinksApiService) UpdateLinkType(ctx context.Context, body LinkTypeUpdat
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1418,6 +1423,7 @@ func (a *LinksApiService) UpdateLinkType(ctx context.Context, body LinkTypeUpdat
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
LinksApiService Update an existing link between transactions.
|
||||
Used to update a single existing link.
|
||||
@ -1490,7 +1496,7 @@ func (a *LinksApiService) UpdateTransactionLink(ctx context.Context, body Transa
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1503,7 +1509,7 @@ func (a *LinksApiService) UpdateTransactionLink(ctx context.Context, body Transa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionLinkSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1513,7 +1519,7 @@ func (a *LinksApiService) UpdateTransactionLink(ctx context.Context, body Transa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1523,7 +1529,7 @@ func (a *LinksApiService) UpdateTransactionLink(ctx context.Context, body Transa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1533,7 +1539,7 @@ func (a *LinksApiService) UpdateTransactionLink(ctx context.Context, body Transa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1543,7 +1549,7 @@ func (a *LinksApiService) UpdateTransactionLink(ctx context.Context, body Transa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1553,7 +1559,7 @@ func (a *LinksApiService) UpdateTransactionLink(ctx context.Context, body Transa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,16 +7,16 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -26,6 +25,7 @@ var (
|
||||
)
|
||||
|
||||
type ObjectGroupsApiService service
|
||||
|
||||
/*
|
||||
ObjectGroupsApiService Delete a object group.
|
||||
Delete a object group.
|
||||
@ -46,7 +46,6 @@ func (a *ObjectGroupsApiService) DeleteObjectGroup(ctx context.Context, id strin
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -93,7 +92,6 @@ func (a *ObjectGroupsApiService) DeleteObjectGroup(ctx context.Context, id strin
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -101,7 +99,7 @@ func (a *ObjectGroupsApiService) DeleteObjectGroup(ctx context.Context, id strin
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -111,7 +109,7 @@ func (a *ObjectGroupsApiService) DeleteObjectGroup(ctx context.Context, id strin
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -121,7 +119,7 @@ func (a *ObjectGroupsApiService) DeleteObjectGroup(ctx context.Context, id strin
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -131,7 +129,7 @@ func (a *ObjectGroupsApiService) DeleteObjectGroup(ctx context.Context, id strin
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -144,6 +142,7 @@ func (a *ObjectGroupsApiService) DeleteObjectGroup(ctx context.Context, id strin
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
ObjectGroupsApiService Get a single object group.
|
||||
Get a single object group.
|
||||
@ -213,7 +212,7 @@ func (a *ObjectGroupsApiService) GetObjectGroup(ctx context.Context, id string,
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -226,7 +225,7 @@ func (a *ObjectGroupsApiService) GetObjectGroup(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v ObjectGroupSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -236,7 +235,7 @@ func (a *ObjectGroupsApiService) GetObjectGroup(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -246,7 +245,7 @@ func (a *ObjectGroupsApiService) GetObjectGroup(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -256,7 +255,7 @@ func (a *ObjectGroupsApiService) GetObjectGroup(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -266,7 +265,7 @@ func (a *ObjectGroupsApiService) GetObjectGroup(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -279,6 +278,7 @@ func (a *ObjectGroupsApiService) GetObjectGroup(ctx context.Context, id string,
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
ObjectGroupsApiService List all bills with this object group.
|
||||
List all bills with this object group.
|
||||
@ -358,7 +358,7 @@ func (a *ObjectGroupsApiService) ListBillByObjectGroup(ctx context.Context, id s
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -371,7 +371,7 @@ func (a *ObjectGroupsApiService) ListBillByObjectGroup(ctx context.Context, id s
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v BillArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -381,7 +381,7 @@ func (a *ObjectGroupsApiService) ListBillByObjectGroup(ctx context.Context, id s
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -391,7 +391,7 @@ func (a *ObjectGroupsApiService) ListBillByObjectGroup(ctx context.Context, id s
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -401,7 +401,7 @@ func (a *ObjectGroupsApiService) ListBillByObjectGroup(ctx context.Context, id s
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -411,7 +411,7 @@ func (a *ObjectGroupsApiService) ListBillByObjectGroup(ctx context.Context, id s
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -424,6 +424,7 @@ func (a *ObjectGroupsApiService) ListBillByObjectGroup(ctx context.Context, id s
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
ObjectGroupsApiService List all oject groups.
|
||||
List all oject groups.
|
||||
@ -501,7 +502,7 @@ func (a *ObjectGroupsApiService) ListObjectGroups(ctx context.Context, localVarO
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -514,7 +515,7 @@ func (a *ObjectGroupsApiService) ListObjectGroups(ctx context.Context, localVarO
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v ObjectGroupArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -524,7 +525,7 @@ func (a *ObjectGroupsApiService) ListObjectGroups(ctx context.Context, localVarO
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -534,7 +535,7 @@ func (a *ObjectGroupsApiService) ListObjectGroups(ctx context.Context, localVarO
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -544,7 +545,7 @@ func (a *ObjectGroupsApiService) ListObjectGroups(ctx context.Context, localVarO
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -554,7 +555,7 @@ func (a *ObjectGroupsApiService) ListObjectGroups(ctx context.Context, localVarO
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -567,6 +568,7 @@ func (a *ObjectGroupsApiService) ListObjectGroups(ctx context.Context, localVarO
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
ObjectGroupsApiService List all piggy banks related to the object group.
|
||||
This endpoint returns a list of all the piggy banks connected to the object group.
|
||||
@ -646,7 +648,7 @@ func (a *ObjectGroupsApiService) ListPiggyBankByObjectGroup(ctx context.Context,
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -659,7 +661,7 @@ func (a *ObjectGroupsApiService) ListPiggyBankByObjectGroup(ctx context.Context,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v PiggyBankArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -669,7 +671,7 @@ func (a *ObjectGroupsApiService) ListPiggyBankByObjectGroup(ctx context.Context,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -679,7 +681,7 @@ func (a *ObjectGroupsApiService) ListPiggyBankByObjectGroup(ctx context.Context,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -689,7 +691,7 @@ func (a *ObjectGroupsApiService) ListPiggyBankByObjectGroup(ctx context.Context,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -699,7 +701,7 @@ func (a *ObjectGroupsApiService) ListPiggyBankByObjectGroup(ctx context.Context,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -712,6 +714,7 @@ func (a *ObjectGroupsApiService) ListPiggyBankByObjectGroup(ctx context.Context,
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
ObjectGroupsApiService Update existing object group.
|
||||
Update existing object group.
|
||||
@ -784,7 +787,7 @@ func (a *ObjectGroupsApiService) UpdateObjectGroup(ctx context.Context, body Obj
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -797,7 +800,7 @@ func (a *ObjectGroupsApiService) UpdateObjectGroup(ctx context.Context, body Obj
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v ObjectGroupSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -807,7 +810,7 @@ func (a *ObjectGroupsApiService) UpdateObjectGroup(ctx context.Context, body Obj
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -817,7 +820,7 @@ func (a *ObjectGroupsApiService) UpdateObjectGroup(ctx context.Context, body Obj
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -827,7 +830,7 @@ func (a *ObjectGroupsApiService) UpdateObjectGroup(ctx context.Context, body Obj
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -837,7 +840,7 @@ func (a *ObjectGroupsApiService) UpdateObjectGroup(ctx context.Context, body Obj
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -847,7 +850,7 @@ func (a *ObjectGroupsApiService) UpdateObjectGroup(ctx context.Context, body Obj
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,16 +7,16 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -26,6 +25,7 @@ var (
|
||||
)
|
||||
|
||||
type PiggyBanksApiService service
|
||||
|
||||
/*
|
||||
PiggyBanksApiService Delete a piggy bank.
|
||||
Delete a piggy bank.
|
||||
@ -46,7 +46,6 @@ func (a *PiggyBanksApiService) DeletePiggyBank(ctx context.Context, id string, l
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -93,7 +92,6 @@ func (a *PiggyBanksApiService) DeletePiggyBank(ctx context.Context, id string, l
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -101,7 +99,7 @@ func (a *PiggyBanksApiService) DeletePiggyBank(ctx context.Context, id string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -111,7 +109,7 @@ func (a *PiggyBanksApiService) DeletePiggyBank(ctx context.Context, id string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -121,7 +119,7 @@ func (a *PiggyBanksApiService) DeletePiggyBank(ctx context.Context, id string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -131,7 +129,7 @@ func (a *PiggyBanksApiService) DeletePiggyBank(ctx context.Context, id string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -144,6 +142,7 @@ func (a *PiggyBanksApiService) DeletePiggyBank(ctx context.Context, id string, l
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
PiggyBanksApiService Get a single piggy bank.
|
||||
Get a single piggy bank.
|
||||
@ -213,7 +212,7 @@ func (a *PiggyBanksApiService) GetPiggyBank(ctx context.Context, id string, loca
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -226,7 +225,7 @@ func (a *PiggyBanksApiService) GetPiggyBank(ctx context.Context, id string, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v PiggyBankSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -236,7 +235,7 @@ func (a *PiggyBanksApiService) GetPiggyBank(ctx context.Context, id string, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -246,7 +245,7 @@ func (a *PiggyBanksApiService) GetPiggyBank(ctx context.Context, id string, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -256,7 +255,7 @@ func (a *PiggyBanksApiService) GetPiggyBank(ctx context.Context, id string, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -266,7 +265,7 @@ func (a *PiggyBanksApiService) GetPiggyBank(ctx context.Context, id string, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -279,6 +278,7 @@ func (a *PiggyBanksApiService) GetPiggyBank(ctx context.Context, id string, loca
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
PiggyBanksApiService Lists all attachments.
|
||||
Lists all attachments.
|
||||
@ -358,7 +358,7 @@ func (a *PiggyBanksApiService) ListAttachmentByPiggyBank(ctx context.Context, id
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -371,7 +371,7 @@ func (a *PiggyBanksApiService) ListAttachmentByPiggyBank(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v AttachmentArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -381,7 +381,7 @@ func (a *PiggyBanksApiService) ListAttachmentByPiggyBank(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -391,7 +391,7 @@ func (a *PiggyBanksApiService) ListAttachmentByPiggyBank(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -401,7 +401,7 @@ func (a *PiggyBanksApiService) ListAttachmentByPiggyBank(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -411,7 +411,7 @@ func (a *PiggyBanksApiService) ListAttachmentByPiggyBank(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -424,6 +424,7 @@ func (a *PiggyBanksApiService) ListAttachmentByPiggyBank(ctx context.Context, id
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
PiggyBanksApiService List all events linked to a piggy bank.
|
||||
List all events linked to a piggy bank (adding and removing money).
|
||||
@ -503,7 +504,7 @@ func (a *PiggyBanksApiService) ListEventByPiggyBank(ctx context.Context, id stri
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -516,7 +517,7 @@ func (a *PiggyBanksApiService) ListEventByPiggyBank(ctx context.Context, id stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v PiggyBankEventArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -526,7 +527,7 @@ func (a *PiggyBanksApiService) ListEventByPiggyBank(ctx context.Context, id stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -536,7 +537,7 @@ func (a *PiggyBanksApiService) ListEventByPiggyBank(ctx context.Context, id stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -546,7 +547,7 @@ func (a *PiggyBanksApiService) ListEventByPiggyBank(ctx context.Context, id stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -556,7 +557,7 @@ func (a *PiggyBanksApiService) ListEventByPiggyBank(ctx context.Context, id stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -569,6 +570,7 @@ func (a *PiggyBanksApiService) ListEventByPiggyBank(ctx context.Context, id stri
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
PiggyBanksApiService List all piggy banks.
|
||||
List all piggy banks.
|
||||
@ -646,7 +648,7 @@ func (a *PiggyBanksApiService) ListPiggyBank(ctx context.Context, localVarOption
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -659,7 +661,7 @@ func (a *PiggyBanksApiService) ListPiggyBank(ctx context.Context, localVarOption
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v PiggyBankArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -669,7 +671,7 @@ func (a *PiggyBanksApiService) ListPiggyBank(ctx context.Context, localVarOption
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -679,7 +681,7 @@ func (a *PiggyBanksApiService) ListPiggyBank(ctx context.Context, localVarOption
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -689,7 +691,7 @@ func (a *PiggyBanksApiService) ListPiggyBank(ctx context.Context, localVarOption
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -699,7 +701,7 @@ func (a *PiggyBanksApiService) ListPiggyBank(ctx context.Context, localVarOption
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -712,6 +714,7 @@ func (a *PiggyBanksApiService) ListPiggyBank(ctx context.Context, localVarOption
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
PiggyBanksApiService Store a new piggy bank
|
||||
Creates a new piggy bank. The data required can be submitted as a JSON body or as a list of parameters.
|
||||
@ -782,7 +785,7 @@ func (a *PiggyBanksApiService) StorePiggyBank(ctx context.Context, body PiggyBan
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -795,7 +798,7 @@ func (a *PiggyBanksApiService) StorePiggyBank(ctx context.Context, body PiggyBan
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v PiggyBankSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -805,7 +808,7 @@ func (a *PiggyBanksApiService) StorePiggyBank(ctx context.Context, body PiggyBan
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -815,7 +818,7 @@ func (a *PiggyBanksApiService) StorePiggyBank(ctx context.Context, body PiggyBan
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -825,7 +828,7 @@ func (a *PiggyBanksApiService) StorePiggyBank(ctx context.Context, body PiggyBan
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -835,7 +838,7 @@ func (a *PiggyBanksApiService) StorePiggyBank(ctx context.Context, body PiggyBan
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -845,7 +848,7 @@ func (a *PiggyBanksApiService) StorePiggyBank(ctx context.Context, body PiggyBan
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -858,6 +861,7 @@ func (a *PiggyBanksApiService) StorePiggyBank(ctx context.Context, body PiggyBan
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
PiggyBanksApiService Update existing piggy bank.
|
||||
Update existing piggy bank.
|
||||
@ -930,7 +934,7 @@ func (a *PiggyBanksApiService) UpdatePiggyBank(ctx context.Context, body PiggyBa
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -943,7 +947,7 @@ func (a *PiggyBanksApiService) UpdatePiggyBank(ctx context.Context, body PiggyBa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v PiggyBankSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -953,7 +957,7 @@ func (a *PiggyBanksApiService) UpdatePiggyBank(ctx context.Context, body PiggyBa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -963,7 +967,7 @@ func (a *PiggyBanksApiService) UpdatePiggyBank(ctx context.Context, body PiggyBa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -973,7 +977,7 @@ func (a *PiggyBanksApiService) UpdatePiggyBank(ctx context.Context, body PiggyBa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -983,7 +987,7 @@ func (a *PiggyBanksApiService) UpdatePiggyBank(ctx context.Context, body PiggyBa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -993,7 +997,7 @@ func (a *PiggyBanksApiService) UpdatePiggyBank(ctx context.Context, body PiggyBa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,16 +7,16 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -26,6 +25,7 @@ var (
|
||||
)
|
||||
|
||||
type RecurrencesApiService service
|
||||
|
||||
/*
|
||||
RecurrencesApiService Delete a recurring transaction.
|
||||
Delete a recurring transaction. Transactions created by the recurring transaction will not be deleted.
|
||||
@ -46,7 +46,6 @@ func (a *RecurrencesApiService) DeleteRecurrence(ctx context.Context, id string,
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -93,7 +92,6 @@ func (a *RecurrencesApiService) DeleteRecurrence(ctx context.Context, id string,
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -101,7 +99,7 @@ func (a *RecurrencesApiService) DeleteRecurrence(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -111,7 +109,7 @@ func (a *RecurrencesApiService) DeleteRecurrence(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -121,7 +119,7 @@ func (a *RecurrencesApiService) DeleteRecurrence(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -131,7 +129,7 @@ func (a *RecurrencesApiService) DeleteRecurrence(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -144,6 +142,7 @@ func (a *RecurrencesApiService) DeleteRecurrence(ctx context.Context, id string,
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RecurrencesApiService Get a single recurring transaction.
|
||||
Get a single recurring transaction.
|
||||
@ -213,7 +212,7 @@ func (a *RecurrencesApiService) GetRecurrence(ctx context.Context, id string, lo
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -226,7 +225,7 @@ func (a *RecurrencesApiService) GetRecurrence(ctx context.Context, id string, lo
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v RecurrenceSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -236,7 +235,7 @@ func (a *RecurrencesApiService) GetRecurrence(ctx context.Context, id string, lo
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -246,7 +245,7 @@ func (a *RecurrencesApiService) GetRecurrence(ctx context.Context, id string, lo
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -256,7 +255,7 @@ func (a *RecurrencesApiService) GetRecurrence(ctx context.Context, id string, lo
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -266,7 +265,7 @@ func (a *RecurrencesApiService) GetRecurrence(ctx context.Context, id string, lo
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -279,6 +278,7 @@ func (a *RecurrencesApiService) GetRecurrence(ctx context.Context, id string, lo
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RecurrencesApiService List all recurring transactions.
|
||||
List all recurring transactions.
|
||||
@ -356,7 +356,7 @@ func (a *RecurrencesApiService) ListRecurrence(ctx context.Context, localVarOpti
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -369,7 +369,7 @@ func (a *RecurrencesApiService) ListRecurrence(ctx context.Context, localVarOpti
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v RecurrenceArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -379,7 +379,7 @@ func (a *RecurrencesApiService) ListRecurrence(ctx context.Context, localVarOpti
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -389,7 +389,7 @@ func (a *RecurrencesApiService) ListRecurrence(ctx context.Context, localVarOpti
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -399,7 +399,7 @@ func (a *RecurrencesApiService) ListRecurrence(ctx context.Context, localVarOpti
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -409,7 +409,7 @@ func (a *RecurrencesApiService) ListRecurrence(ctx context.Context, localVarOpti
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -422,6 +422,7 @@ func (a *RecurrencesApiService) ListRecurrence(ctx context.Context, localVarOpti
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RecurrencesApiService List all transactions created by a recurring transaction.
|
||||
List all transactions created by a recurring transaction, optionally limited to the date ranges specified.
|
||||
@ -516,7 +517,7 @@ func (a *RecurrencesApiService) ListTransactionByRecurrence(ctx context.Context,
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -529,7 +530,7 @@ func (a *RecurrencesApiService) ListTransactionByRecurrence(ctx context.Context,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -539,7 +540,7 @@ func (a *RecurrencesApiService) ListTransactionByRecurrence(ctx context.Context,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -549,7 +550,7 @@ func (a *RecurrencesApiService) ListTransactionByRecurrence(ctx context.Context,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -559,7 +560,7 @@ func (a *RecurrencesApiService) ListTransactionByRecurrence(ctx context.Context,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -569,7 +570,7 @@ func (a *RecurrencesApiService) ListTransactionByRecurrence(ctx context.Context,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -582,6 +583,7 @@ func (a *RecurrencesApiService) ListTransactionByRecurrence(ctx context.Context,
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RecurrencesApiService Store a new recurring transaction
|
||||
Creates a new recurring transaction. The data required can be submitted as a JSON body or as a list of parameters.
|
||||
@ -652,7 +654,7 @@ func (a *RecurrencesApiService) StoreRecurrence(ctx context.Context, body Recurr
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -665,7 +667,7 @@ func (a *RecurrencesApiService) StoreRecurrence(ctx context.Context, body Recurr
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v RecurrenceSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -675,7 +677,7 @@ func (a *RecurrencesApiService) StoreRecurrence(ctx context.Context, body Recurr
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -685,7 +687,7 @@ func (a *RecurrencesApiService) StoreRecurrence(ctx context.Context, body Recurr
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -695,7 +697,7 @@ func (a *RecurrencesApiService) StoreRecurrence(ctx context.Context, body Recurr
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -705,7 +707,7 @@ func (a *RecurrencesApiService) StoreRecurrence(ctx context.Context, body Recurr
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -715,7 +717,7 @@ func (a *RecurrencesApiService) StoreRecurrence(ctx context.Context, body Recurr
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -728,6 +730,7 @@ func (a *RecurrencesApiService) StoreRecurrence(ctx context.Context, body Recurr
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RecurrencesApiService Update existing recurring transaction.
|
||||
Update existing recurring transaction.
|
||||
@ -800,7 +803,7 @@ func (a *RecurrencesApiService) UpdateRecurrence(ctx context.Context, body Recur
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -813,7 +816,7 @@ func (a *RecurrencesApiService) UpdateRecurrence(ctx context.Context, body Recur
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v RecurrenceSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -823,7 +826,7 @@ func (a *RecurrencesApiService) UpdateRecurrence(ctx context.Context, body Recur
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -833,7 +836,7 @@ func (a *RecurrencesApiService) UpdateRecurrence(ctx context.Context, body Recur
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -843,7 +846,7 @@ func (a *RecurrencesApiService) UpdateRecurrence(ctx context.Context, body Recur
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -853,7 +856,7 @@ func (a *RecurrencesApiService) UpdateRecurrence(ctx context.Context, body Recur
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -863,7 +866,7 @@ func (a *RecurrencesApiService) UpdateRecurrence(ctx context.Context, body Recur
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,16 +7,16 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -26,6 +25,7 @@ var (
|
||||
)
|
||||
|
||||
type RuleGroupsApiService service
|
||||
|
||||
/*
|
||||
RuleGroupsApiService Delete a rule group.
|
||||
Delete a rule group.
|
||||
@ -46,7 +46,6 @@ func (a *RuleGroupsApiService) DeleteRuleGroup(ctx context.Context, id string, l
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -93,7 +92,6 @@ func (a *RuleGroupsApiService) DeleteRuleGroup(ctx context.Context, id string, l
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -101,7 +99,7 @@ func (a *RuleGroupsApiService) DeleteRuleGroup(ctx context.Context, id string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -111,7 +109,7 @@ func (a *RuleGroupsApiService) DeleteRuleGroup(ctx context.Context, id string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -121,7 +119,7 @@ func (a *RuleGroupsApiService) DeleteRuleGroup(ctx context.Context, id string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -131,7 +129,7 @@ func (a *RuleGroupsApiService) DeleteRuleGroup(ctx context.Context, id string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -144,6 +142,7 @@ func (a *RuleGroupsApiService) DeleteRuleGroup(ctx context.Context, id string, l
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RuleGroupsApiService Fire the rule group on your transactions.
|
||||
Fire the rule group on your transactions. Changes will be made by the rules in the rule group! Limit the result if you want to.
|
||||
@ -170,7 +169,6 @@ func (a *RuleGroupsApiService) FireRuleGroup(ctx context.Context, id string, loc
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -226,7 +224,6 @@ func (a *RuleGroupsApiService) FireRuleGroup(ctx context.Context, id string, loc
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -234,7 +231,7 @@ func (a *RuleGroupsApiService) FireRuleGroup(ctx context.Context, id string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -244,7 +241,7 @@ func (a *RuleGroupsApiService) FireRuleGroup(ctx context.Context, id string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -254,7 +251,7 @@ func (a *RuleGroupsApiService) FireRuleGroup(ctx context.Context, id string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -264,7 +261,7 @@ func (a *RuleGroupsApiService) FireRuleGroup(ctx context.Context, id string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -277,6 +274,7 @@ func (a *RuleGroupsApiService) FireRuleGroup(ctx context.Context, id string, loc
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RuleGroupsApiService Get a single rule group.
|
||||
Get a single rule group. This does not include the rules. For that, see below.
|
||||
@ -346,7 +344,7 @@ func (a *RuleGroupsApiService) GetRuleGroup(ctx context.Context, id string, loca
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -359,7 +357,7 @@ func (a *RuleGroupsApiService) GetRuleGroup(ctx context.Context, id string, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v RuleGroupSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -369,7 +367,7 @@ func (a *RuleGroupsApiService) GetRuleGroup(ctx context.Context, id string, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -379,7 +377,7 @@ func (a *RuleGroupsApiService) GetRuleGroup(ctx context.Context, id string, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -389,7 +387,7 @@ func (a *RuleGroupsApiService) GetRuleGroup(ctx context.Context, id string, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -399,7 +397,7 @@ func (a *RuleGroupsApiService) GetRuleGroup(ctx context.Context, id string, loca
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -412,6 +410,7 @@ func (a *RuleGroupsApiService) GetRuleGroup(ctx context.Context, id string, loca
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RuleGroupsApiService List rules in this rule group.
|
||||
List rules in this rule group.
|
||||
@ -491,7 +490,7 @@ func (a *RuleGroupsApiService) ListRuleByGroup(ctx context.Context, id string, l
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -504,7 +503,7 @@ func (a *RuleGroupsApiService) ListRuleByGroup(ctx context.Context, id string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v RuleArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -514,7 +513,7 @@ func (a *RuleGroupsApiService) ListRuleByGroup(ctx context.Context, id string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -524,7 +523,7 @@ func (a *RuleGroupsApiService) ListRuleByGroup(ctx context.Context, id string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -534,7 +533,7 @@ func (a *RuleGroupsApiService) ListRuleByGroup(ctx context.Context, id string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -544,7 +543,7 @@ func (a *RuleGroupsApiService) ListRuleByGroup(ctx context.Context, id string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -557,6 +556,7 @@ func (a *RuleGroupsApiService) ListRuleByGroup(ctx context.Context, id string, l
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RuleGroupsApiService List all rule groups.
|
||||
List all rule groups.
|
||||
@ -634,7 +634,7 @@ func (a *RuleGroupsApiService) ListRuleGroup(ctx context.Context, localVarOption
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -647,7 +647,7 @@ func (a *RuleGroupsApiService) ListRuleGroup(ctx context.Context, localVarOption
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v RuleGroupArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -657,7 +657,7 @@ func (a *RuleGroupsApiService) ListRuleGroup(ctx context.Context, localVarOption
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -667,7 +667,7 @@ func (a *RuleGroupsApiService) ListRuleGroup(ctx context.Context, localVarOption
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -677,7 +677,7 @@ func (a *RuleGroupsApiService) ListRuleGroup(ctx context.Context, localVarOption
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -687,7 +687,7 @@ func (a *RuleGroupsApiService) ListRuleGroup(ctx context.Context, localVarOption
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -700,6 +700,7 @@ func (a *RuleGroupsApiService) ListRuleGroup(ctx context.Context, localVarOption
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RuleGroupsApiService Store a new rule group.
|
||||
Creates a new rule group. The data required can be submitted as a JSON body or as a list of parameters.
|
||||
@ -770,7 +771,7 @@ func (a *RuleGroupsApiService) StoreRuleGroup(ctx context.Context, body RuleGrou
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -783,7 +784,7 @@ func (a *RuleGroupsApiService) StoreRuleGroup(ctx context.Context, body RuleGrou
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v RuleGroupSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -793,7 +794,7 @@ func (a *RuleGroupsApiService) StoreRuleGroup(ctx context.Context, body RuleGrou
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -803,7 +804,7 @@ func (a *RuleGroupsApiService) StoreRuleGroup(ctx context.Context, body RuleGrou
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -813,7 +814,7 @@ func (a *RuleGroupsApiService) StoreRuleGroup(ctx context.Context, body RuleGrou
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -823,7 +824,7 @@ func (a *RuleGroupsApiService) StoreRuleGroup(ctx context.Context, body RuleGrou
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -833,7 +834,7 @@ func (a *RuleGroupsApiService) StoreRuleGroup(ctx context.Context, body RuleGrou
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -846,6 +847,7 @@ func (a *RuleGroupsApiService) StoreRuleGroup(ctx context.Context, body RuleGrou
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RuleGroupsApiService Test which transactions would be hit by the rule group. No changes will be made.
|
||||
Test which transactions would be hit by the rule group. No changes will be made. Limit the result if you want to.
|
||||
@ -950,7 +952,7 @@ func (a *RuleGroupsApiService) TestRuleGroup(ctx context.Context, id string, loc
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -963,7 +965,7 @@ func (a *RuleGroupsApiService) TestRuleGroup(ctx context.Context, id string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -973,7 +975,7 @@ func (a *RuleGroupsApiService) TestRuleGroup(ctx context.Context, id string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -983,7 +985,7 @@ func (a *RuleGroupsApiService) TestRuleGroup(ctx context.Context, id string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -993,7 +995,7 @@ func (a *RuleGroupsApiService) TestRuleGroup(ctx context.Context, id string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1003,7 +1005,7 @@ func (a *RuleGroupsApiService) TestRuleGroup(ctx context.Context, id string, loc
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1016,6 +1018,7 @@ func (a *RuleGroupsApiService) TestRuleGroup(ctx context.Context, id string, loc
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RuleGroupsApiService Update existing rule group.
|
||||
Update existing rule group.
|
||||
@ -1088,7 +1091,7 @@ func (a *RuleGroupsApiService) UpdateRuleGroup(ctx context.Context, body RuleGro
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1101,7 +1104,7 @@ func (a *RuleGroupsApiService) UpdateRuleGroup(ctx context.Context, body RuleGro
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v RuleGroupSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1111,7 +1114,7 @@ func (a *RuleGroupsApiService) UpdateRuleGroup(ctx context.Context, body RuleGro
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1121,7 +1124,7 @@ func (a *RuleGroupsApiService) UpdateRuleGroup(ctx context.Context, body RuleGro
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1131,7 +1134,7 @@ func (a *RuleGroupsApiService) UpdateRuleGroup(ctx context.Context, body RuleGro
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1141,7 +1144,7 @@ func (a *RuleGroupsApiService) UpdateRuleGroup(ctx context.Context, body RuleGro
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1151,7 +1154,7 @@ func (a *RuleGroupsApiService) UpdateRuleGroup(ctx context.Context, body RuleGro
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
98
api_rules.go
98
api_rules.go
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,16 +7,16 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -26,6 +25,7 @@ var (
|
||||
)
|
||||
|
||||
type RulesApiService service
|
||||
|
||||
/*
|
||||
RulesApiService Delete an rule.
|
||||
Delete an rule.
|
||||
@ -46,7 +46,6 @@ func (a *RulesApiService) DeleteRule(ctx context.Context, id string, localVarOpt
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -93,7 +92,6 @@ func (a *RulesApiService) DeleteRule(ctx context.Context, id string, localVarOpt
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -101,7 +99,7 @@ func (a *RulesApiService) DeleteRule(ctx context.Context, id string, localVarOpt
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -111,7 +109,7 @@ func (a *RulesApiService) DeleteRule(ctx context.Context, id string, localVarOpt
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -121,7 +119,7 @@ func (a *RulesApiService) DeleteRule(ctx context.Context, id string, localVarOpt
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -131,7 +129,7 @@ func (a *RulesApiService) DeleteRule(ctx context.Context, id string, localVarOpt
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -144,6 +142,7 @@ func (a *RulesApiService) DeleteRule(ctx context.Context, id string, localVarOpt
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RulesApiService Fire the rule on your transactions.
|
||||
Fire the rule group on your transactions. Changes will be made by the rules in the group! Limit the result if you want to.
|
||||
@ -170,7 +169,6 @@ func (a *RulesApiService) FireRule(ctx context.Context, id string, localVarOptio
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -226,7 +224,6 @@ func (a *RulesApiService) FireRule(ctx context.Context, id string, localVarOptio
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -234,7 +231,7 @@ func (a *RulesApiService) FireRule(ctx context.Context, id string, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -244,7 +241,7 @@ func (a *RulesApiService) FireRule(ctx context.Context, id string, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -254,7 +251,7 @@ func (a *RulesApiService) FireRule(ctx context.Context, id string, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -264,7 +261,7 @@ func (a *RulesApiService) FireRule(ctx context.Context, id string, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -277,6 +274,7 @@ func (a *RulesApiService) FireRule(ctx context.Context, id string, localVarOptio
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RulesApiService Get a single rule.
|
||||
Get a single rule.
|
||||
@ -346,7 +344,7 @@ func (a *RulesApiService) GetRule(ctx context.Context, id string, localVarOption
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -359,7 +357,7 @@ func (a *RulesApiService) GetRule(ctx context.Context, id string, localVarOption
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v RuleSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -369,7 +367,7 @@ func (a *RulesApiService) GetRule(ctx context.Context, id string, localVarOption
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -379,7 +377,7 @@ func (a *RulesApiService) GetRule(ctx context.Context, id string, localVarOption
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -389,7 +387,7 @@ func (a *RulesApiService) GetRule(ctx context.Context, id string, localVarOption
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -399,7 +397,7 @@ func (a *RulesApiService) GetRule(ctx context.Context, id string, localVarOption
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -412,6 +410,7 @@ func (a *RulesApiService) GetRule(ctx context.Context, id string, localVarOption
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RulesApiService List all rules.
|
||||
List all rules.
|
||||
@ -489,7 +488,7 @@ func (a *RulesApiService) ListRule(ctx context.Context, localVarOptionals *Rules
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -502,7 +501,7 @@ func (a *RulesApiService) ListRule(ctx context.Context, localVarOptionals *Rules
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v RuleArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -512,7 +511,7 @@ func (a *RulesApiService) ListRule(ctx context.Context, localVarOptionals *Rules
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -522,7 +521,7 @@ func (a *RulesApiService) ListRule(ctx context.Context, localVarOptionals *Rules
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -532,7 +531,7 @@ func (a *RulesApiService) ListRule(ctx context.Context, localVarOptionals *Rules
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -542,7 +541,7 @@ func (a *RulesApiService) ListRule(ctx context.Context, localVarOptionals *Rules
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -555,6 +554,7 @@ func (a *RulesApiService) ListRule(ctx context.Context, localVarOptionals *Rules
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RulesApiService Store a new rule
|
||||
Creates a new rule. The data required can be submitted as a JSON body or as a list of parameters.
|
||||
@ -625,7 +625,7 @@ func (a *RulesApiService) StoreRule(ctx context.Context, body RuleStore, localVa
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -638,7 +638,7 @@ func (a *RulesApiService) StoreRule(ctx context.Context, body RuleStore, localVa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v RuleSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -648,7 +648,7 @@ func (a *RulesApiService) StoreRule(ctx context.Context, body RuleStore, localVa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -658,7 +658,7 @@ func (a *RulesApiService) StoreRule(ctx context.Context, body RuleStore, localVa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -668,7 +668,7 @@ func (a *RulesApiService) StoreRule(ctx context.Context, body RuleStore, localVa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -678,7 +678,7 @@ func (a *RulesApiService) StoreRule(ctx context.Context, body RuleStore, localVa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -688,7 +688,7 @@ func (a *RulesApiService) StoreRule(ctx context.Context, body RuleStore, localVa
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -701,6 +701,7 @@ func (a *RulesApiService) StoreRule(ctx context.Context, body RuleStore, localVa
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RulesApiService Test which transactions would be hit by the rule. No changes will be made.
|
||||
Test which transactions would be hit by the rule. No changes will be made. Limit the result if you want to.
|
||||
@ -785,7 +786,7 @@ func (a *RulesApiService) TestRule(ctx context.Context, id string, localVarOptio
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -798,7 +799,7 @@ func (a *RulesApiService) TestRule(ctx context.Context, id string, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -808,7 +809,7 @@ func (a *RulesApiService) TestRule(ctx context.Context, id string, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -818,7 +819,7 @@ func (a *RulesApiService) TestRule(ctx context.Context, id string, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -828,7 +829,7 @@ func (a *RulesApiService) TestRule(ctx context.Context, id string, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -838,7 +839,7 @@ func (a *RulesApiService) TestRule(ctx context.Context, id string, localVarOptio
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -851,6 +852,7 @@ func (a *RulesApiService) TestRule(ctx context.Context, id string, localVarOptio
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
RulesApiService Update existing rule.
|
||||
Update existing rule.
|
||||
@ -923,7 +925,7 @@ func (a *RulesApiService) UpdateRule(ctx context.Context, body RuleUpdate, id st
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -936,7 +938,7 @@ func (a *RulesApiService) UpdateRule(ctx context.Context, body RuleUpdate, id st
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v RuleSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -946,7 +948,7 @@ func (a *RulesApiService) UpdateRule(ctx context.Context, body RuleUpdate, id st
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -956,7 +958,7 @@ func (a *RulesApiService) UpdateRule(ctx context.Context, body RuleUpdate, id st
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -966,7 +968,7 @@ func (a *RulesApiService) UpdateRule(ctx context.Context, body RuleUpdate, id st
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -976,7 +978,7 @@ func (a *RulesApiService) UpdateRule(ctx context.Context, body RuleUpdate, id st
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -986,7 +988,7 @@ func (a *RulesApiService) UpdateRule(ctx context.Context, body RuleUpdate, id st
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,15 +7,15 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -25,6 +24,7 @@ var (
|
||||
)
|
||||
|
||||
type SearchApiService service
|
||||
|
||||
/*
|
||||
SearchApiService Search for accounts
|
||||
Search for accounts
|
||||
@ -111,7 +111,7 @@ func (a *SearchApiService) SearchAccounts(ctx context.Context, query string, fie
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -124,7 +124,7 @@ func (a *SearchApiService) SearchAccounts(ctx context.Context, query string, fie
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v AccountArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -134,7 +134,7 @@ func (a *SearchApiService) SearchAccounts(ctx context.Context, query string, fie
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -144,7 +144,7 @@ func (a *SearchApiService) SearchAccounts(ctx context.Context, query string, fie
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -154,7 +154,7 @@ func (a *SearchApiService) SearchAccounts(ctx context.Context, query string, fie
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -164,7 +164,7 @@ func (a *SearchApiService) SearchAccounts(ctx context.Context, query string, fie
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -177,6 +177,7 @@ func (a *SearchApiService) SearchAccounts(ctx context.Context, query string, fie
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
SearchApiService Search for transactions
|
||||
Searches through the users transactions.
|
||||
@ -256,7 +257,7 @@ func (a *SearchApiService) SearchTransactions(ctx context.Context, query string,
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -269,7 +270,7 @@ func (a *SearchApiService) SearchTransactions(ctx context.Context, query string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -279,7 +280,7 @@ func (a *SearchApiService) SearchTransactions(ctx context.Context, query string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -289,7 +290,7 @@ func (a *SearchApiService) SearchTransactions(ctx context.Context, query string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -299,7 +300,7 @@ func (a *SearchApiService) SearchTransactions(ctx context.Context, query string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -309,7 +310,7 @@ func (a *SearchApiService) SearchTransactions(ctx context.Context, query string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,15 +7,15 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -25,6 +24,7 @@ var (
|
||||
)
|
||||
|
||||
type SummaryApiService service
|
||||
|
||||
/*
|
||||
SummaryApiService Returns basic sums of the users data.
|
||||
Returns basic sums of the users data, like the net worth, spent and earned amounts. It is multi-currency, and is used in Firefly III to populate the dashboard.
|
||||
@ -101,7 +101,7 @@ func (a *SummaryApiService) GetBasicSummary(ctx context.Context, start string, e
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -114,7 +114,7 @@ func (a *SummaryApiService) GetBasicSummary(ctx context.Context, start string, e
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v map[string]BasicSummaryEntry
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -124,7 +124,7 @@ func (a *SummaryApiService) GetBasicSummary(ctx context.Context, start string, e
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -134,7 +134,7 @@ func (a *SummaryApiService) GetBasicSummary(ctx context.Context, start string, e
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -144,7 +144,7 @@ func (a *SummaryApiService) GetBasicSummary(ctx context.Context, start string, e
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -154,7 +154,7 @@ func (a *SummaryApiService) GetBasicSummary(ctx context.Context, start string, e
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
100
api_tags.go
100
api_tags.go
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,16 +7,16 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -26,6 +25,7 @@ var (
|
||||
)
|
||||
|
||||
type TagsApiService service
|
||||
|
||||
/*
|
||||
TagsApiService Delete an tag.
|
||||
Delete an tag.
|
||||
@ -46,7 +46,6 @@ func (a *TagsApiService) DeleteTag(ctx context.Context, tag string, localVarOpti
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -93,7 +92,6 @@ func (a *TagsApiService) DeleteTag(ctx context.Context, tag string, localVarOpti
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -101,7 +99,7 @@ func (a *TagsApiService) DeleteTag(ctx context.Context, tag string, localVarOpti
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -111,7 +109,7 @@ func (a *TagsApiService) DeleteTag(ctx context.Context, tag string, localVarOpti
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -121,7 +119,7 @@ func (a *TagsApiService) DeleteTag(ctx context.Context, tag string, localVarOpti
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -131,7 +129,7 @@ func (a *TagsApiService) DeleteTag(ctx context.Context, tag string, localVarOpti
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -144,6 +142,7 @@ func (a *TagsApiService) DeleteTag(ctx context.Context, tag string, localVarOpti
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
TagsApiService Get a single tag.
|
||||
Get a single tag.
|
||||
@ -223,7 +222,7 @@ func (a *TagsApiService) GetTag(ctx context.Context, tag string, localVarOptiona
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -236,7 +235,7 @@ func (a *TagsApiService) GetTag(ctx context.Context, tag string, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TagSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -246,7 +245,7 @@ func (a *TagsApiService) GetTag(ctx context.Context, tag string, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -256,7 +255,7 @@ func (a *TagsApiService) GetTag(ctx context.Context, tag string, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -266,7 +265,7 @@ func (a *TagsApiService) GetTag(ctx context.Context, tag string, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -276,7 +275,7 @@ func (a *TagsApiService) GetTag(ctx context.Context, tag string, localVarOptiona
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -289,6 +288,7 @@ func (a *TagsApiService) GetTag(ctx context.Context, tag string, localVarOptiona
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
TagsApiService Lists all attachments.
|
||||
Lists all attachments.
|
||||
@ -368,7 +368,7 @@ func (a *TagsApiService) ListAttachmentByTag(ctx context.Context, tag string, lo
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -381,7 +381,7 @@ func (a *TagsApiService) ListAttachmentByTag(ctx context.Context, tag string, lo
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v AttachmentArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -391,7 +391,7 @@ func (a *TagsApiService) ListAttachmentByTag(ctx context.Context, tag string, lo
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -401,7 +401,7 @@ func (a *TagsApiService) ListAttachmentByTag(ctx context.Context, tag string, lo
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -411,7 +411,7 @@ func (a *TagsApiService) ListAttachmentByTag(ctx context.Context, tag string, lo
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -421,7 +421,7 @@ func (a *TagsApiService) ListAttachmentByTag(ctx context.Context, tag string, lo
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -434,6 +434,7 @@ func (a *TagsApiService) ListAttachmentByTag(ctx context.Context, tag string, lo
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
TagsApiService List all tags.
|
||||
List all of the user's tags.
|
||||
@ -511,7 +512,7 @@ func (a *TagsApiService) ListTag(ctx context.Context, localVarOptionals *TagsApi
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -524,7 +525,7 @@ func (a *TagsApiService) ListTag(ctx context.Context, localVarOptionals *TagsApi
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TagArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -534,7 +535,7 @@ func (a *TagsApiService) ListTag(ctx context.Context, localVarOptionals *TagsApi
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -544,7 +545,7 @@ func (a *TagsApiService) ListTag(ctx context.Context, localVarOptionals *TagsApi
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -554,7 +555,7 @@ func (a *TagsApiService) ListTag(ctx context.Context, localVarOptionals *TagsApi
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -564,7 +565,7 @@ func (a *TagsApiService) ListTag(ctx context.Context, localVarOptionals *TagsApi
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -577,6 +578,7 @@ func (a *TagsApiService) ListTag(ctx context.Context, localVarOptionals *TagsApi
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
TagsApiService List all transactions with this tag.
|
||||
List all transactions with this tag.
|
||||
@ -671,7 +673,7 @@ func (a *TagsApiService) ListTransactionByTag(ctx context.Context, tag string, l
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -684,7 +686,7 @@ func (a *TagsApiService) ListTransactionByTag(ctx context.Context, tag string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -694,7 +696,7 @@ func (a *TagsApiService) ListTransactionByTag(ctx context.Context, tag string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -704,7 +706,7 @@ func (a *TagsApiService) ListTransactionByTag(ctx context.Context, tag string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -714,7 +716,7 @@ func (a *TagsApiService) ListTransactionByTag(ctx context.Context, tag string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -724,7 +726,7 @@ func (a *TagsApiService) ListTransactionByTag(ctx context.Context, tag string, l
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -737,6 +739,7 @@ func (a *TagsApiService) ListTransactionByTag(ctx context.Context, tag string, l
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
TagsApiService Store a new tag
|
||||
Creates a new tag. The data required can be submitted as a JSON body or as a list of parameters.
|
||||
@ -807,7 +810,7 @@ func (a *TagsApiService) StoreTag(ctx context.Context, body TagModelStore, local
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -820,7 +823,7 @@ func (a *TagsApiService) StoreTag(ctx context.Context, body TagModelStore, local
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TagSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -830,7 +833,7 @@ func (a *TagsApiService) StoreTag(ctx context.Context, body TagModelStore, local
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -840,7 +843,7 @@ func (a *TagsApiService) StoreTag(ctx context.Context, body TagModelStore, local
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -850,7 +853,7 @@ func (a *TagsApiService) StoreTag(ctx context.Context, body TagModelStore, local
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -860,7 +863,7 @@ func (a *TagsApiService) StoreTag(ctx context.Context, body TagModelStore, local
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -870,7 +873,7 @@ func (a *TagsApiService) StoreTag(ctx context.Context, body TagModelStore, local
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -883,6 +886,7 @@ func (a *TagsApiService) StoreTag(ctx context.Context, body TagModelStore, local
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
TagsApiService Update existing tag.
|
||||
Update existing tag.
|
||||
@ -955,7 +959,7 @@ func (a *TagsApiService) UpdateTag(ctx context.Context, body TagModelUpdate, tag
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -968,7 +972,7 @@ func (a *TagsApiService) UpdateTag(ctx context.Context, body TagModelUpdate, tag
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TagSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -978,7 +982,7 @@ func (a *TagsApiService) UpdateTag(ctx context.Context, body TagModelUpdate, tag
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -988,7 +992,7 @@ func (a *TagsApiService) UpdateTag(ctx context.Context, body TagModelUpdate, tag
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -998,7 +1002,7 @@ func (a *TagsApiService) UpdateTag(ctx context.Context, body TagModelUpdate, tag
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1008,7 +1012,7 @@ func (a *TagsApiService) UpdateTag(ctx context.Context, body TagModelUpdate, tag
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1018,7 +1022,7 @@ func (a *TagsApiService) UpdateTag(ctx context.Context, body TagModelUpdate, tag
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,16 +7,16 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -26,6 +25,7 @@ var (
|
||||
)
|
||||
|
||||
type TransactionsApiService service
|
||||
|
||||
/*
|
||||
TransactionsApiService Delete a transaction.
|
||||
Delete a transaction.
|
||||
@ -46,7 +46,6 @@ func (a *TransactionsApiService) DeleteTransaction(ctx context.Context, id strin
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -93,7 +92,6 @@ func (a *TransactionsApiService) DeleteTransaction(ctx context.Context, id strin
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -101,7 +99,7 @@ func (a *TransactionsApiService) DeleteTransaction(ctx context.Context, id strin
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -111,7 +109,7 @@ func (a *TransactionsApiService) DeleteTransaction(ctx context.Context, id strin
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -121,7 +119,7 @@ func (a *TransactionsApiService) DeleteTransaction(ctx context.Context, id strin
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -131,7 +129,7 @@ func (a *TransactionsApiService) DeleteTransaction(ctx context.Context, id strin
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -144,6 +142,7 @@ func (a *TransactionsApiService) DeleteTransaction(ctx context.Context, id strin
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
TransactionsApiService Delete split from transaction
|
||||
Delete an individual journal (split) from a transaction.
|
||||
@ -164,7 +163,6 @@ func (a *TransactionsApiService) DeleteTransactionJournal(ctx context.Context, i
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -211,7 +209,6 @@ func (a *TransactionsApiService) DeleteTransactionJournal(ctx context.Context, i
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -219,7 +216,7 @@ func (a *TransactionsApiService) DeleteTransactionJournal(ctx context.Context, i
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -229,7 +226,7 @@ func (a *TransactionsApiService) DeleteTransactionJournal(ctx context.Context, i
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -239,7 +236,7 @@ func (a *TransactionsApiService) DeleteTransactionJournal(ctx context.Context, i
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -249,7 +246,7 @@ func (a *TransactionsApiService) DeleteTransactionJournal(ctx context.Context, i
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -262,6 +259,7 @@ func (a *TransactionsApiService) DeleteTransactionJournal(ctx context.Context, i
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
TransactionsApiService Get a single transaction.
|
||||
Get a single transaction.
|
||||
@ -331,7 +329,7 @@ func (a *TransactionsApiService) GetTransaction(ctx context.Context, id string,
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -344,7 +342,7 @@ func (a *TransactionsApiService) GetTransaction(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -354,7 +352,7 @@ func (a *TransactionsApiService) GetTransaction(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -364,7 +362,7 @@ func (a *TransactionsApiService) GetTransaction(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -374,7 +372,7 @@ func (a *TransactionsApiService) GetTransaction(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -384,7 +382,7 @@ func (a *TransactionsApiService) GetTransaction(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -397,6 +395,7 @@ func (a *TransactionsApiService) GetTransaction(ctx context.Context, id string,
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
TransactionsApiService Get a single transaction, based on one of the underlying transaction journals (transaction splits).
|
||||
Get a single transaction by underlying journal (split).
|
||||
@ -466,7 +465,7 @@ func (a *TransactionsApiService) GetTransactionByJournal(ctx context.Context, id
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -479,7 +478,7 @@ func (a *TransactionsApiService) GetTransactionByJournal(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -489,7 +488,7 @@ func (a *TransactionsApiService) GetTransactionByJournal(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -499,7 +498,7 @@ func (a *TransactionsApiService) GetTransactionByJournal(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -509,7 +508,7 @@ func (a *TransactionsApiService) GetTransactionByJournal(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -519,7 +518,7 @@ func (a *TransactionsApiService) GetTransactionByJournal(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -532,6 +531,7 @@ func (a *TransactionsApiService) GetTransactionByJournal(ctx context.Context, id
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
TransactionsApiService Lists all attachments.
|
||||
Lists all attachments.
|
||||
@ -611,7 +611,7 @@ func (a *TransactionsApiService) ListAttachmentByTransaction(ctx context.Context
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -624,7 +624,7 @@ func (a *TransactionsApiService) ListAttachmentByTransaction(ctx context.Context
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v AttachmentArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -634,7 +634,7 @@ func (a *TransactionsApiService) ListAttachmentByTransaction(ctx context.Context
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -644,7 +644,7 @@ func (a *TransactionsApiService) ListAttachmentByTransaction(ctx context.Context
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -654,7 +654,7 @@ func (a *TransactionsApiService) ListAttachmentByTransaction(ctx context.Context
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -664,7 +664,7 @@ func (a *TransactionsApiService) ListAttachmentByTransaction(ctx context.Context
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -677,6 +677,7 @@ func (a *TransactionsApiService) ListAttachmentByTransaction(ctx context.Context
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
TransactionsApiService Lists all piggy bank events.
|
||||
Lists all piggy bank events.
|
||||
@ -756,7 +757,7 @@ func (a *TransactionsApiService) ListEventByTransaction(ctx context.Context, id
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -769,7 +770,7 @@ func (a *TransactionsApiService) ListEventByTransaction(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v PiggyBankEventArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -779,7 +780,7 @@ func (a *TransactionsApiService) ListEventByTransaction(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -789,7 +790,7 @@ func (a *TransactionsApiService) ListEventByTransaction(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -799,7 +800,7 @@ func (a *TransactionsApiService) ListEventByTransaction(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -809,7 +810,7 @@ func (a *TransactionsApiService) ListEventByTransaction(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -822,6 +823,7 @@ func (a *TransactionsApiService) ListEventByTransaction(ctx context.Context, id
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
TransactionsApiService Lists all the transaction links for an individual journal (individual split).
|
||||
Lists all the transaction links for an individual journal (a split). Don't use the group ID, you need the actual underlying journal (the split).
|
||||
@ -901,7 +903,7 @@ func (a *TransactionsApiService) ListLinksByJournal(ctx context.Context, id stri
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -914,7 +916,7 @@ func (a *TransactionsApiService) ListLinksByJournal(ctx context.Context, id stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionLinkArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -924,7 +926,7 @@ func (a *TransactionsApiService) ListLinksByJournal(ctx context.Context, id stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -934,7 +936,7 @@ func (a *TransactionsApiService) ListLinksByJournal(ctx context.Context, id stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -944,7 +946,7 @@ func (a *TransactionsApiService) ListLinksByJournal(ctx context.Context, id stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -954,7 +956,7 @@ func (a *TransactionsApiService) ListLinksByJournal(ctx context.Context, id stri
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -967,6 +969,7 @@ func (a *TransactionsApiService) ListLinksByJournal(ctx context.Context, id stri
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
TransactionsApiService List all the user's transactions.
|
||||
List all the user's transactions.
|
||||
@ -1059,7 +1062,7 @@ func (a *TransactionsApiService) ListTransaction(ctx context.Context, localVarOp
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1072,7 +1075,7 @@ func (a *TransactionsApiService) ListTransaction(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1082,7 +1085,7 @@ func (a *TransactionsApiService) ListTransaction(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1092,7 +1095,7 @@ func (a *TransactionsApiService) ListTransaction(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1102,7 +1105,7 @@ func (a *TransactionsApiService) ListTransaction(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1112,7 +1115,7 @@ func (a *TransactionsApiService) ListTransaction(ctx context.Context, localVarOp
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1125,6 +1128,7 @@ func (a *TransactionsApiService) ListTransaction(ctx context.Context, localVarOp
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
TransactionsApiService Store a new transaction
|
||||
Creates a new transaction. The data required can be submitted as a JSON body or as a list of parameters.
|
||||
@ -1195,7 +1199,7 @@ func (a *TransactionsApiService) StoreTransaction(ctx context.Context, body Tran
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1208,7 +1212,7 @@ func (a *TransactionsApiService) StoreTransaction(ctx context.Context, body Tran
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1218,7 +1222,7 @@ func (a *TransactionsApiService) StoreTransaction(ctx context.Context, body Tran
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1228,7 +1232,7 @@ func (a *TransactionsApiService) StoreTransaction(ctx context.Context, body Tran
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1238,7 +1242,7 @@ func (a *TransactionsApiService) StoreTransaction(ctx context.Context, body Tran
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1248,7 +1252,7 @@ func (a *TransactionsApiService) StoreTransaction(ctx context.Context, body Tran
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1258,7 +1262,7 @@ func (a *TransactionsApiService) StoreTransaction(ctx context.Context, body Tran
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1271,6 +1275,7 @@ func (a *TransactionsApiService) StoreTransaction(ctx context.Context, body Tran
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
TransactionsApiService Update existing transaction. For more information, see https://docs.firefly-iii.org/references/firefly-iii/api/specials/
|
||||
Update an existing transaction.
|
||||
@ -1343,7 +1348,7 @@ func (a *TransactionsApiService) UpdateTransaction(ctx context.Context, body Tra
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1356,7 +1361,7 @@ func (a *TransactionsApiService) UpdateTransaction(ctx context.Context, body Tra
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v TransactionSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1366,7 +1371,7 @@ func (a *TransactionsApiService) UpdateTransaction(ctx context.Context, body Tra
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1376,7 +1381,7 @@ func (a *TransactionsApiService) UpdateTransaction(ctx context.Context, body Tra
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1386,7 +1391,7 @@ func (a *TransactionsApiService) UpdateTransaction(ctx context.Context, body Tra
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1396,7 +1401,7 @@ func (a *TransactionsApiService) UpdateTransaction(ctx context.Context, body Tra
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1406,7 +1411,7 @@ func (a *TransactionsApiService) UpdateTransaction(ctx context.Context, body Tra
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
154
api_webhooks.go
154
api_webhooks.go
@ -1,4 +1,3 @@
|
||||
|
||||
/*
|
||||
* Firefly III API v2.0.14
|
||||
*
|
||||
@ -8,16 +7,16 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"strings"
|
||||
"fmt"
|
||||
"github.com/antihax/optional"
|
||||
)
|
||||
|
||||
// Linger please
|
||||
@ -26,6 +25,7 @@ var (
|
||||
)
|
||||
|
||||
type WebhooksApiService service
|
||||
|
||||
/*
|
||||
WebhooksApiService Delete a webhook.
|
||||
Delete a webhook.
|
||||
@ -46,7 +46,6 @@ func (a *WebhooksApiService) DeleteWebhook(ctx context.Context, id string, local
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -93,7 +92,6 @@ func (a *WebhooksApiService) DeleteWebhook(ctx context.Context, id string, local
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -101,7 +99,7 @@ func (a *WebhooksApiService) DeleteWebhook(ctx context.Context, id string, local
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -111,7 +109,7 @@ func (a *WebhooksApiService) DeleteWebhook(ctx context.Context, id string, local
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -121,7 +119,7 @@ func (a *WebhooksApiService) DeleteWebhook(ctx context.Context, id string, local
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -131,7 +129,7 @@ func (a *WebhooksApiService) DeleteWebhook(ctx context.Context, id string, local
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -144,6 +142,7 @@ func (a *WebhooksApiService) DeleteWebhook(ctx context.Context, id string, local
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
WebhooksApiService Delete a webhook message.
|
||||
Delete a webhook message. Any time a webhook is triggered the message is stored before it's sent. You can delete them before or after sending.
|
||||
@ -165,7 +164,6 @@ func (a *WebhooksApiService) DeleteWebhookMessage(ctx context.Context, id string
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -213,7 +211,6 @@ func (a *WebhooksApiService) DeleteWebhookMessage(ctx context.Context, id string
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -221,7 +218,7 @@ func (a *WebhooksApiService) DeleteWebhookMessage(ctx context.Context, id string
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -231,7 +228,7 @@ func (a *WebhooksApiService) DeleteWebhookMessage(ctx context.Context, id string
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -241,7 +238,7 @@ func (a *WebhooksApiService) DeleteWebhookMessage(ctx context.Context, id string
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -251,7 +248,7 @@ func (a *WebhooksApiService) DeleteWebhookMessage(ctx context.Context, id string
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -264,6 +261,7 @@ func (a *WebhooksApiService) DeleteWebhookMessage(ctx context.Context, id string
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
WebhooksApiService Delete a webhook attempt.
|
||||
Delete a webhook message attempt. If you delete all attempts for a webhook message, Firefly III will (once again) assume all is well with the webhook message and will try to send it again.
|
||||
@ -286,7 +284,6 @@ func (a *WebhooksApiService) DeleteWebhookMessageAttempt(ctx context.Context, id
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -335,7 +332,6 @@ func (a *WebhooksApiService) DeleteWebhookMessageAttempt(ctx context.Context, id
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -343,7 +339,7 @@ func (a *WebhooksApiService) DeleteWebhookMessageAttempt(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -353,7 +349,7 @@ func (a *WebhooksApiService) DeleteWebhookMessageAttempt(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -363,7 +359,7 @@ func (a *WebhooksApiService) DeleteWebhookMessageAttempt(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -373,7 +369,7 @@ func (a *WebhooksApiService) DeleteWebhookMessageAttempt(ctx context.Context, id
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarHttpResponse, newErr
|
||||
@ -386,6 +382,7 @@ func (a *WebhooksApiService) DeleteWebhookMessageAttempt(ctx context.Context, id
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
WebhooksApiService Get a single message from a webhook.
|
||||
When a webhook is triggered it will store the actual content of the webhook in a webhook message. You can view and analyse a single one using this endpoint.
|
||||
@ -457,7 +454,7 @@ func (a *WebhooksApiService) GetSingleWebhookMessage(ctx context.Context, id str
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -470,7 +467,7 @@ func (a *WebhooksApiService) GetSingleWebhookMessage(ctx context.Context, id str
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v WebhookMessageSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -480,7 +477,7 @@ func (a *WebhooksApiService) GetSingleWebhookMessage(ctx context.Context, id str
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -490,7 +487,7 @@ func (a *WebhooksApiService) GetSingleWebhookMessage(ctx context.Context, id str
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -500,7 +497,7 @@ func (a *WebhooksApiService) GetSingleWebhookMessage(ctx context.Context, id str
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -510,7 +507,7 @@ func (a *WebhooksApiService) GetSingleWebhookMessage(ctx context.Context, id str
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -523,6 +520,7 @@ func (a *WebhooksApiService) GetSingleWebhookMessage(ctx context.Context, id str
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
WebhooksApiService Get a single failed attempt from a single webhook message.
|
||||
When a webhook message fails to send it will store the failure in an \"attempt\". You can view and analyse these. Webhooks messages that receive too many attempts (failures) will not be fired. You must first clear out old attempts and try again. This endpoint shows you the details of a single attempt. The ID of the attempt must match the corresponding webhook and webhook message.
|
||||
@ -596,7 +594,7 @@ func (a *WebhooksApiService) GetSingleWebhookMessageAttempt(ctx context.Context,
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -609,7 +607,7 @@ func (a *WebhooksApiService) GetSingleWebhookMessageAttempt(ctx context.Context,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v WebhookAttemptSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -619,7 +617,7 @@ func (a *WebhooksApiService) GetSingleWebhookMessageAttempt(ctx context.Context,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -629,7 +627,7 @@ func (a *WebhooksApiService) GetSingleWebhookMessageAttempt(ctx context.Context,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -639,7 +637,7 @@ func (a *WebhooksApiService) GetSingleWebhookMessageAttempt(ctx context.Context,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -649,7 +647,7 @@ func (a *WebhooksApiService) GetSingleWebhookMessageAttempt(ctx context.Context,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -662,6 +660,7 @@ func (a *WebhooksApiService) GetSingleWebhookMessageAttempt(ctx context.Context,
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
WebhooksApiService Get a single webhook.
|
||||
Gets all info of a single webhook.
|
||||
@ -731,7 +730,7 @@ func (a *WebhooksApiService) GetWebhook(ctx context.Context, id string, localVar
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -744,7 +743,7 @@ func (a *WebhooksApiService) GetWebhook(ctx context.Context, id string, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v WebhookSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -754,7 +753,7 @@ func (a *WebhooksApiService) GetWebhook(ctx context.Context, id string, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -764,7 +763,7 @@ func (a *WebhooksApiService) GetWebhook(ctx context.Context, id string, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -774,7 +773,7 @@ func (a *WebhooksApiService) GetWebhook(ctx context.Context, id string, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -784,7 +783,7 @@ func (a *WebhooksApiService) GetWebhook(ctx context.Context, id string, localVar
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -797,6 +796,7 @@ func (a *WebhooksApiService) GetWebhook(ctx context.Context, id string, localVar
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
WebhooksApiService Get all the failed attempts of a single webhook message.
|
||||
When a webhook message fails to send it will store the failure in an \"attempt\". You can view and analyse these. Webhook messages that receive too many attempts (failures) will not be sent again. You must first clear out old attempts before the message can go out again.
|
||||
@ -878,7 +878,7 @@ func (a *WebhooksApiService) GetWebhookMessageAttempts(ctx context.Context, id s
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -891,7 +891,7 @@ func (a *WebhooksApiService) GetWebhookMessageAttempts(ctx context.Context, id s
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v WebhookAttemptArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -901,7 +901,7 @@ func (a *WebhooksApiService) GetWebhookMessageAttempts(ctx context.Context, id s
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -911,7 +911,7 @@ func (a *WebhooksApiService) GetWebhookMessageAttempts(ctx context.Context, id s
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -921,7 +921,7 @@ func (a *WebhooksApiService) GetWebhookMessageAttempts(ctx context.Context, id s
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -931,7 +931,7 @@ func (a *WebhooksApiService) GetWebhookMessageAttempts(ctx context.Context, id s
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -944,6 +944,7 @@ func (a *WebhooksApiService) GetWebhookMessageAttempts(ctx context.Context, id s
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
WebhooksApiService Get all the messages of a single webhook.
|
||||
When a webhook is triggered the actual message that will be send is stored in a \"message\". You can view and analyse these messages.
|
||||
@ -1013,7 +1014,7 @@ func (a *WebhooksApiService) GetWebhookMessages(ctx context.Context, id string,
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1026,7 +1027,7 @@ func (a *WebhooksApiService) GetWebhookMessages(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v WebhookMessageArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1036,7 +1037,7 @@ func (a *WebhooksApiService) GetWebhookMessages(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1046,7 +1047,7 @@ func (a *WebhooksApiService) GetWebhookMessages(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1056,7 +1057,7 @@ func (a *WebhooksApiService) GetWebhookMessages(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1066,7 +1067,7 @@ func (a *WebhooksApiService) GetWebhookMessages(ctx context.Context, id string,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1079,6 +1080,7 @@ func (a *WebhooksApiService) GetWebhookMessages(ctx context.Context, id string,
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
WebhooksApiService List all webhooks.
|
||||
List all the user's webhooks.
|
||||
@ -1156,7 +1158,7 @@ func (a *WebhooksApiService) ListWebhook(ctx context.Context, localVarOptionals
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1169,7 +1171,7 @@ func (a *WebhooksApiService) ListWebhook(ctx context.Context, localVarOptionals
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v WebhookArray
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1179,7 +1181,7 @@ func (a *WebhooksApiService) ListWebhook(ctx context.Context, localVarOptionals
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1189,7 +1191,7 @@ func (a *WebhooksApiService) ListWebhook(ctx context.Context, localVarOptionals
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1199,7 +1201,7 @@ func (a *WebhooksApiService) ListWebhook(ctx context.Context, localVarOptionals
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1209,7 +1211,7 @@ func (a *WebhooksApiService) ListWebhook(ctx context.Context, localVarOptionals
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1222,6 +1224,7 @@ func (a *WebhooksApiService) ListWebhook(ctx context.Context, localVarOptionals
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
WebhooksApiService Store a new webhook
|
||||
Creates a new webhook. The data required can be submitted as a JSON body or as a list of parameters. The webhook will be given a random secret.
|
||||
@ -1292,7 +1295,7 @@ func (a *WebhooksApiService) StoreWebhook(ctx context.Context, body WebhookStore
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1305,7 +1308,7 @@ func (a *WebhooksApiService) StoreWebhook(ctx context.Context, body WebhookStore
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v WebhookSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1315,7 +1318,7 @@ func (a *WebhooksApiService) StoreWebhook(ctx context.Context, body WebhookStore
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1325,7 +1328,7 @@ func (a *WebhooksApiService) StoreWebhook(ctx context.Context, body WebhookStore
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1335,7 +1338,7 @@ func (a *WebhooksApiService) StoreWebhook(ctx context.Context, body WebhookStore
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1345,7 +1348,7 @@ func (a *WebhooksApiService) StoreWebhook(ctx context.Context, body WebhookStore
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1355,7 +1358,7 @@ func (a *WebhooksApiService) StoreWebhook(ctx context.Context, body WebhookStore
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1368,6 +1371,7 @@ func (a *WebhooksApiService) StoreWebhook(ctx context.Context, body WebhookStore
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
WebhooksApiService Submit messages for a webhook.
|
||||
This endpoint will submit any open messages for this webhook. This is an asynchronous operation, so you can't see the result. Refresh the webhook message and/or the webhook message attempts to see the results. This may take some time if the webhook receiver is slow.
|
||||
@ -1388,7 +1392,6 @@ func (a *WebhooksApiService) SubmitWebook(ctx context.Context, id string, localV
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -1435,7 +1438,6 @@ func (a *WebhooksApiService) SubmitWebook(ctx context.Context, id string, localV
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -1446,6 +1448,7 @@ func (a *WebhooksApiService) SubmitWebook(ctx context.Context, id string, localV
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
WebhooksApiService Trigger webhook for a given transaction.
|
||||
This endpoint will execute this webhook for a given transaction ID. This is an asynchronous operation, so you can't see the result. Refresh the webhook message and/or the webhook message attempts to see the results. This may take some time if the webhook receiver is slow.
|
||||
@ -1467,7 +1470,6 @@ func (a *WebhooksApiService) TriggerTransactionWebhook(ctx context.Context, id s
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
@ -1515,7 +1517,6 @@ func (a *WebhooksApiService) TriggerTransactionWebhook(ctx context.Context, id s
|
||||
return localVarHttpResponse, err
|
||||
}
|
||||
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericSwaggerError{
|
||||
body: localVarBody,
|
||||
@ -1526,6 +1527,7 @@ func (a *WebhooksApiService) TriggerTransactionWebhook(ctx context.Context, id s
|
||||
|
||||
return localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
WebhooksApiService Update existing webhook.
|
||||
Update an existing webhook's information. If you wish to reset the secret, submit any value as the \"secret\". Firefly III will take this as a hint and reset the secret of the webhook.
|
||||
@ -1598,7 +1600,7 @@ func (a *WebhooksApiService) UpdateWebhook(ctx context.Context, body WebhookUpda
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
@ -1611,7 +1613,7 @@ func (a *WebhooksApiService) UpdateWebhook(ctx context.Context, body WebhookUpda
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v WebhookSingle
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1621,7 +1623,7 @@ func (a *WebhooksApiService) UpdateWebhook(ctx context.Context, body WebhookUpda
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 422 {
|
||||
var v ValidationErrorResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1631,7 +1633,7 @@ func (a *WebhooksApiService) UpdateWebhook(ctx context.Context, body WebhookUpda
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 401 {
|
||||
var v UnauthenticatedResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1641,7 +1643,7 @@ func (a *WebhooksApiService) UpdateWebhook(ctx context.Context, body WebhookUpda
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 404 {
|
||||
var v NotFoundResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1651,7 +1653,7 @@ func (a *WebhooksApiService) UpdateWebhook(ctx context.Context, body WebhookUpda
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 400 {
|
||||
var v BadRequestResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
@ -1661,7 +1663,7 @@ func (a *WebhooksApiService) UpdateWebhook(ctx context.Context, body WebhookUpda
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 500 {
|
||||
var v InternalExceptionResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"net/http"
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AccountArray struct {
|
||||
Data []AccountRead `json:"data"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AccountRead struct {
|
||||
// Immutable value
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
// AccountRoleProperty : Is only mandatory when the type is asset.
|
||||
type AccountRoleProperty string
|
||||
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AccountSearchFieldFilter string
|
||||
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AccountSingle struct {
|
||||
Data *AccountRead `json:"data"`
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AccountTypeFilter string
|
||||
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AccountTypeProperty string
|
||||
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
// AttachableType : The object class to which the attachment must be linked.
|
||||
type AttachableType string
|
||||
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AttachmentArray struct {
|
||||
Data []AttachmentRead `json:"data"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AttachmentRead struct {
|
||||
// Immutable value
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AttachmentSingle struct {
|
||||
Data *AttachmentRead `json:"data"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AttachmentStore struct {
|
||||
Filename string `json:"filename"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AttachmentUpdate struct {
|
||||
Filename string `json:"filename,omitempty"`
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
// AutoBudgetPeriod : Period for the auto budget
|
||||
type AutoBudgetPeriod string
|
||||
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
// AutoBudgetType : The type of auto-budget that Firefly III must create.
|
||||
type AutoBudgetType string
|
||||
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompleteAccount struct {
|
||||
Id string `json:"id"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompleteBill struct {
|
||||
Id string `json:"id"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompleteBudget struct {
|
||||
Id string `json:"id"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompleteCategory struct {
|
||||
Id string `json:"id"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompleteCurrency struct {
|
||||
Id string `json:"id"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompleteCurrencyCode struct {
|
||||
Id string `json:"id"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompleteObjectGroup struct {
|
||||
Id string `json:"id"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompletePiggy struct {
|
||||
Id string `json:"id"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompletePiggyBalance struct {
|
||||
Id string `json:"id"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompleteRecurrence struct {
|
||||
Id string `json:"id"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompleteRule struct {
|
||||
Id string `json:"id"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompleteRuleGroup struct {
|
||||
Id string `json:"id"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompleteTag struct {
|
||||
Id string `json:"id"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompleteTransaction struct {
|
||||
// The ID of a transaction journal (basically a single split).
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompleteTransactionId struct {
|
||||
// The ID of a transaction journal (basically a single split).
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AutocompleteTransactionType struct {
|
||||
Id string `json:"id"`
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AvailableBudgetArray struct {
|
||||
Data []AvailableBudgetRead `json:"data"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AvailableBudgetRead struct {
|
||||
// Immutable value
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type AvailableBudgetSingle struct {
|
||||
Data *AvailableBudgetRead `json:"data"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type BadRequestResponse struct {
|
||||
Message string `json:"message,omitempty"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type BasicSummaryEntry struct {
|
||||
// This is a reference to the type of info shared, not influenced by translations or user preferences. The EUR value is a reference to the currency code. Possibilities are: balance-in-ABC, spent-in-ABC, earned-in-ABC, bills-paid-in-ABC, bills-unpaid-in-ABC, left-to-spend-in-ABC and net-worth-in-ABC.
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type BillArray struct {
|
||||
Data []BillRead `json:"data"`
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type BillRead struct {
|
||||
// Immutable value
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
// BillRepeatFrequency : How often the bill must be paid.
|
||||
type BillRepeatFrequency string
|
||||
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type BillSingle struct {
|
||||
Data *BillRead `json:"data"`
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type BudgetArray struct {
|
||||
Data []BudgetRead `json:"data"`
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type BudgetLimitArray struct {
|
||||
Data []BudgetLimitRead `json:"data"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type BudgetLimitRead struct {
|
||||
// Immutable value
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type BudgetLimitSingle struct {
|
||||
Data *BudgetLimitRead `json:"data"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type BudgetLimitStore struct {
|
||||
// Use either currency_id or currency_code. Defaults to the user's default currency.
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type BudgetRead struct {
|
||||
// Immutable value
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type BudgetSingle struct {
|
||||
Data *BudgetRead `json:"data"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type BudgetSpent struct {
|
||||
// The amount spent.
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type BudgetStore struct {
|
||||
Name string `json:"name"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type BudgetUpdate struct {
|
||||
Name string `json:"name"`
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type CategoryArray struct {
|
||||
Data []CategoryRead `json:"data"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type CategoryEarned struct {
|
||||
CurrencyId string `json:"currency_id,omitempty"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type CategoryRead struct {
|
||||
// Immutable value
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type CategorySingle struct {
|
||||
Data *CategoryRead `json:"data"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type CategorySpent struct {
|
||||
CurrencyId string `json:"currency_id,omitempty"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type CategoryUpdate struct {
|
||||
Name string `json:"name"`
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type ChartDataPoint struct {
|
||||
// The key is the label of the value, so for example: '2018-01-01' => 13 or 'Groceries' => -123.
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
@ -7,7 +7,8 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
// ConfigValueFilter : Title of the configuration value.
|
||||
type ConfigValueFilter string
|
||||
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Contact: james@firefly-iii.org
|
||||
* Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git)
|
||||
*/
|
||||
package swagger
|
||||
package firefly3
|
||||
|
||||
type ConfigValueUpdateFilter string
|
||||
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user