Webhook Document

Data sent with the Webhook POST requests -

Scratch Card Generated

{
  "type": "action_event",
  "name": "scratch_card_generated",
  "campaign_id": 123,
  "ext_user_id": "123ASC",
  "ref_num": "lEZuU",
  "user_event_key": "event_key",
  "reward_value": 10,
  "wallet_type_id": 100,
  "created_at": 1712749810,
  "flyy_user_id": 12,
  "flyy_event_id": 1344,
  "sku": null,
  "voucher": null,
  "voucher_name": null,
  "extra_data": {
    "referrer_ext_user_id": "",
    "user_event_value": {
      "quiz_tournament_game_id": 123,
      "quiz_tournament_id": 123
    }
  }
}

User Wallet Credit

{
  "type": "action_event",
  "name": "user_wallet_credit",
  "id": 123,
  "value": 10,
  "ref_num": "NCMVN",
  "credit_reason": "Well done! Earned for ABC",
  "wallet_type_id": 100,
  "campaign_id": 12345,
  "campaign_name": "Offer Title",
  "user_event_key": "event_key",
  "ext_user_id": "123ASC",
  "created_at": 1709124752,
  "user_offer_transaction_id": 123
}

User Wallet Debit

{
  "type": "action_event",
  "name": "user_wallet_debit",
  "id": 12,
  "value": 10,
  "ref_num": "NCMVN",
  "debit_reason": "Reward expired for Cash",
  "wallet_type_id": 100,
  "user_event_key": "event_key",
  "ext_user_id": "123ASC",
  "created_at": 1709078500
}

Referral Reward Generated (Successful User Referral)

{
"type": "action_event",
"name": "successful_user_referral",
"ext_user_id": "123ASC",
"referrer_ext_user_id": "456ASC",
"created_at": 12345
} 

Referral Reward Not Generated

{
"type": "action_event",
"name": "referral_reward_not_generated",
"ext_user_id": "123ASC",
"referrer_ext_user_id": "456ASC"
}

Gift Card Redeemed

{
  "type": "action_event",
  "name": "gift_card_redeemed",
  "ext_user_id": "7828011085",
  "gift_card_value": 10,
  "amount_spent": 10,
  "wallet_type": "currency_label",
  "gift_card": {
    "name": "Gift Card Name",
    "description": "Description",
    "image_url": "URL",
    "tnc": "tnc",
    "card_number": "card_number",
    "card_pin": ""
  }
}

Campaign Budget Reached

{
"type": "action_event",
"name": "campaign_budget_reached",
"campaign_id": 123,
"budget": 1000,
"wallet_type_id": 100
}

Daily Reward Limit Reached

{
“type”: “action_event”,
"name": "daily_reward_limit_reached",
"campaign_id": 123,
"user_id": "123ASC"
}

Total Reward Limit Reached

{
"type": "action_event",
"name": "total_reward_limit_reached",
"campaign_id": 1,
"ext_user_id": "123ASC"
}

User Quiz Played

{
  type: "action_event",
  name: "user_quiz_played",
  ext_user_id: "123ASC",
  quiz_tournament_id: 123,
  campaign_id: 123,
  created_at: 1234567
}

User Quiz Score Recorded

{
  "type": "action_event",
  "name": "user_quiz_score_recorded",
  "score": 100,
  "answers": "[{\"key\":10695,\"value\":\"C\"},{\"key\":10691,\"value\":\"C\"},{\"key\":10694,\"value\":\"C\"},{\"key\":10692,\"value\":\"C\"},{\"key\":10696,\"value\":\"C\"}]",
  "quiz_data": [
    {
      "question": "Which financial statement provides information about a company\u0092s revenues and expenses over a specific period?",
      "options": [
        {
          "key": "A",
          "value": "Balance sheet"
        },
        {
          "key": "B",
          "value": "Income statement"
        },
        {
          "key": "C",
          "value": "Cash flow statement"
        },
        {
          "key": "D",
          "value": "Statement of retained earnings"
        }
      ],
      "correct_option": "B",
      "user_option": "Balance sheet",
      "option_correct": false
    }
  ],
  "ext_user_id": "123ASC",
  "quiz_tournament_id": 123,
  "campaign_id": 12345,
  "created_at": 1712749810
}

Campaign Started

{
  type: "action_event",
  name: "campaign_started", 
  campaign_id: 123, 
  campaign_title: "Campaign Title",
  starts_at: 1234567890, 
  ends_at: 1234567890
}

Campaign Ended

{
  type: "action_event",
  name: "campaign_ended", 
  campaign_id: 123,
  campaign_title: "Campaign Title",
  starts_at: 1234567890,
  ends_at: 1234567890
}

Custom Gift Card Purchased

{
  type: "action_event",
  name: "custom_gift_card_purchased", 
  virtual_currency_used: 123, 
  virtual_currency_label: "Points", 
  ref_num: "ASC123", 
  ext_user_id: "1234DSDS43",
  user_name: "John Doe",
  user_email: "[email protected]",
  product_id: "12SD34", 
  product_name: "Company Coupon", 
  created_at: 1234567890
}

Share Link Clicked

{
  type: "action_event",
  name: "share_link_clicked",
  ext_user_id: "123ASC",
  offer_id: 1,
  created_at: 1234567890
}

User Tournament Played

{
  type: "action_event",
  name: "user_tournament_played",
  ext_user_id: "123ASC", 
  tournament_id: 1, 
  game_id: 1,
  game_name: "Floor Escape", 
  created_at: 1234567890
}

Checkin

{
  type: "action_event", 
  name: "checkin", 
  campaign_id: 1,
  user_event_key: "transact",
  reward_won: true,
  ref_num: "123POI",
  value: 10, 
  wallet_type_id: 1,
  ext_user_id: "123ASC", 
  created_at: 1234567890
}

Payout Updated

{
  type: "action_event", 
  name: "payout_updated",
  ext_user_id: "123ASC",
  payout: {
            utr: "UTR",
            status: "STATUS", 
            amount: 100, 
            payout_mode: "IMPS/NEFT/etc",
            failure_reason: "MESSAGE"
           },
  account: {
            type: "bank/upi", 
            account_number: "ACCOUNT NUMBER",
            name: "NAME",
            ifsc: "IFSC",
            upi_id:"a@upi"
           } 
}

            
                                                                                                      
                                                                                                                               """@upoP             

New User Registered

{
  type: "action_event", 
  name: "new_user_registered", 
  ext_user_id: "123ASC",
  referrer_ext_user_id: "456ASC",
  user_referral_code: "ABC245",
  user_referral_link: "https://stage.flyy.in/ABC245",
  created_at: 1234567890
}

Milestone Reached

{
  "type": "action_event",
  "name": "milestone_reached",
  "ext_user_id": "123ASC",
  "current_score": 1,
  "leaderboard_id": 123,
  "milestone_data": {
    "index": 1,
    "title": "Milestone",
    "sub_title": "subtitle",
    "identifier": "AbcERYaz"
  },
  "created_at": 1717657399
}

Stamp Generated

{
  type: "action_event", 
  name: "stamp_generated",
  campaign_id: 12345,
  ext_user_id: "123ASC",
  ref_num: "Akqj1",
  stamp: "Stamp Name",
  created_at: 1234567890
}

User Properties Updated

{
  "type": "action_event",
  "name": "user_propeties_updated",
  "ext_uid": "123ASC",
  "properties": {
    "age": 20,
    "color": "color",
    "region": {
      "city": "City",
      "state": "State"
    },
    "nickname": "NickName"
  },
  "user_data": {
    "id": 12,
    "contact_number": null,
    "user_name": "User",
    "device_id": "device_id",
    "show_popup": false,
    "referral_code": null,
    "created_at": "2022-11-03T14:55:59.361+05:30",
    "updated_at": "2024-06-04T14:28:05.833+05:30",
    "ext_uid": "123ASC",
    "offer_id": 123,
    "sdk_version": 1,
    "app_version": 1,
    "rzp_contact_id": "rzp_cont_id",
    "display_name": null,
    "token": "token",
    "properties": {
      "age": 20,
      "color": "color",
      "region": {
        "city": "City",
        "state": "State"
      },
      "nickname": "NickName"
    }
  }
}

Transfer Request Created

{
  type: "action_event", 
  name: "transfer_request_created",
  transfer_request_id: 12345,
  amount: 100,
  ext_user_id: "123ASC",
  debit_ref_num: "FLYY01221",
  status: "status"
}

_Multireward Campaign Budget Reached

{
  type: "action_event", 
  name: "multireward_campaign_budget_reached",
  campaign_id: 12345,
  multireward_campaign_id: 11223,
  budget: 100000,
  budget_used: 10000,
  reward_type: "Type",
  currency_label: "Currency Label"
}