Skip to content

Commit

Permalink
feat(fee): Expose charge_id in REST API
Browse files Browse the repository at this point in the history
  • Loading branch information
vincent-pochet committed Oct 18, 2024
1 parent 59d13ee commit 6dd2a42
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions app/serializers/v1/fee_serializer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ def serialize

payload = {
lago_id: model.id,
lago_charge_id: model.charge_id,
lago_charge_filter_id: model.charge_filter_id,
lago_invoice_id: model.invoice_id,
lago_true_up_fee_id: model.true_up_fee&.id,
Expand Down
1 change: 1 addition & 0 deletions spec/serializers/v1/fee_serializer_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
aggregate_failures do
expect(result['fee']).to include(
'lago_id' => fee.id,
'lago_charge_id' => fee.charge_id,
'lago_charge_filter_id' => fee.charge_filter_id,
'lago_invoice_id' => fee.invoice_id,
'lago_true_up_fee_id' => fee.true_up_fee&.id,
Expand Down

0 comments on commit 6dd2a42

Please sign in to comment.