code: function BranchCommerce() {
    // revenue required
    var event = {
      revenue: 50.29,
      currency: 148, // USD
      transactionID: "transaction id",
      coupon: "coupon",
      shipping: 2.22,
      tax: 5.11,
      affiliation: "affiliation",
      products: [
        {
          sku: "u123",
          name: "cactus",
          price: 4.99,
          quantity: 2,
          brand: "brand",
          category: 17, // Software
          variant: "variant"
        },
        {
          sku: "u456",
          name: "grass",
          price: 0.0,
          quantity: 1
        }
      ]
    };
  
    // optional
    var metadata = {
      custom_dictionary: 123,
      anything: "everything"
    };
  
    Branch.sendCommerceEvent(event, metadata)
      .then(function success(res) {
        console.log("CommerceEvent", res);
        logger(res);
      })
      .catch(function error(err) {
        logger(err, true);
      });
  }
docs: DEPRECATED