Skip to content

Commit

Permalink
misc: Force external_subscription_id when creating an event
Browse files Browse the repository at this point in the history
  • Loading branch information
rsempe committed Jul 10, 2024
1 parent 01e1e81 commit 24d31cd
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 3 deletions.
1 change: 0 additions & 1 deletion lib/lago/api/resources/event.rb
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ def whitelist_params(params)
{
root_name => {
transaction_id: params[:transaction_id],
external_customer_id: params[:external_customer_id],
code: params[:code],
timestamp: params[:timestamp],
external_subscription_id: params[:external_subscription_id],
Expand Down
2 changes: 1 addition & 1 deletion spec/factories/event.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FactoryBot.define do
factory :event, class: OpenStruct do
transaction_id { 'UNIQUE_ID' }
external_customer_id { '5eb02857-a71e-4ea2-bcf9-57d8885990ba' }
external_subscription_id { '5eb02857-a71e-4ea2-bcf9-57d8885990ba' }
code { '123' }
timestamp { '2022-05-05T12:27:30Z' }
properties do
Expand Down
1 change: 0 additions & 1 deletion spec/fixtures/api/event.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
"lago_id": "1a901a90-1a90-1a90-1a90-1a901a901a90",
"transaction_id": "1a901a90-1a90-1a90-1a90-1a901a901a90",
"lago_customer_id": "1a901a90-1a90-1a90-1a90-1a901a901a90",
"external_customer_id": "1a901a90-1a90-1a90-1a90-1a901a901a90",
"code": "bm_code",
"timestamp": "2022-04-29T08:59:51.998Z",
"properties": {
Expand Down

0 comments on commit 24d31cd

Please sign in to comment.