Skip to content

Commit

Permalink
fix: remove reconciled field in API v3 responses
Browse files Browse the repository at this point in the history
  • Loading branch information
morremeyer committed Nov 22, 2023
1 parent 06e24ce commit 7f4434d
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 14 deletions.
6 changes: 2 additions & 4 deletions api/docs.go
Original file line number Diff line number Diff line change
Expand Up @@ -5840,10 +5840,8 @@ const docTemplate = `{
"example": "Lunch"
},
"reconciled": {
"description": "DEPRECATED. Do not use, this field does not work as intended. See https://github.com/envelope-zero/backend/issues/528. Use reconciledSource and reconciledDestination instead. This field will be removed in 4.0.0",
"type": "boolean",
"default": false,
"example": true
"description": "Remove the reconciled field",
"type": "boolean"
},
"reconciledDestination": {
"description": "Is the transaction reconciled in the destination account?",
Expand Down
6 changes: 2 additions & 4 deletions api/swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -5829,10 +5829,8 @@
"example": "Lunch"
},
"reconciled": {
"description": "DEPRECATED. Do not use, this field does not work as intended. See https://github.com/envelope-zero/backend/issues/528. Use reconciledSource and reconciledDestination instead. This field will be removed in 4.0.0",
"type": "boolean",
"default": false,
"example": true
"description": "Remove the reconciled field",
"type": "boolean"
},
"reconciledDestination": {
"description": "Is the transaction reconciled in the destination account?",
Expand Down
6 changes: 1 addition & 5 deletions api/swagger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -955,11 +955,7 @@ definitions:
example: Lunch
type: string
reconciled:
default: false
description: DEPRECATED. Do not use, this field does not work as intended.
See https://github.com/envelope-zero/backend/issues/528. Use reconciledSource
and reconciledDestination instead. This field will be removed in 4.0.0
example: true
description: Remove the reconciled field
type: boolean
reconciledDestination:
default: false
Expand Down
3 changes: 2 additions & 1 deletion pkg/controllers/transaction_v3.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,8 @@ type TransactionResponseV3 struct {
// TransactionV3 is the representation of a Transaction in API v3.
type TransactionV3 struct {
models.Transaction
Links struct {
Reconciled bool `json:"reconciled,omitempty"` // Remove the reconciled field
Links struct {
Self string `json:"self" example:"https://example.com/api/v3/transactions/d430d7c3-d14c-4712-9336-ee56965a6673"` // The transaction itself
} `json:"links"` // Links for the transaction
}
Expand Down

0 comments on commit 7f4434d

Please sign in to comment.