The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.
TypeScript clickhousemysqlnextjsopen-sourceplanetscaleprismatailwindcsstinybirdtypescriptupstashvercel
fix example data
Steven Teye15a12d30805
diff --git a/apps/web/ui/analytics/events/example-data.ts b/apps/web/ui/analytics/events/example-data.tsindex 8034d63ec1..fb16f60aeb 100644--- a/apps/web/ui/analytics/events/example-data.ts+++ b/apps/web/ui/analytics/events/example-data.ts@@ -8,186 +8,183 @@ const common = {};const dubLink = {- link_id: "1",+ id: "1",domain: "dub.sh", // TODO: update to dub.linkkey: "uxUrVCz",url: "https://dub.co/",- link: {- id: "1",- domain: "dub.sh", // TODO: update to dub.link- key: "uxUrVCz",- url: "https://dub.co/",- },};const githubLink = {- link_id: "3",+ id: "3",domain: "git.new",key: "9XyzIho",url: "https://github.com/dubinc/dub",- link: {- id: "3",- domain: "git.new",- key: "9XyzIho",- url: "https://github.com/dubinc/dub",- },};const steven = {- customer_name: "Steven",- customer_email: "",- customer_avatar: "https://avatar.vercel.sh/s.png?text=S",- customer: {- name: "Steven",- email: "",- avatar: "https://avatar.vercel.sh/s.png?text=S",- },+ name: "Steven",+ email: "",+ avatar: "https://avatar.vercel.sh/s.png?text=S",};const tim = {- customer_name: "Tim",- customer_email: "",- customer_avatar: "https://avatar.vercel.sh/t.png?text=T",- customer: {- name: "Tim",- email: "",- avatar: "https://avatar.vercel.sh/t.png?text=T",- },+ name: "Tim",+ email: "",+ avatar: "https://avatar.vercel.sh/t.png?text=T",};const kiran = {- customer_name: "Kiran",- customer_email: "",- customer_avatar: "https://avatar.vercel.sh/k.png?text=K",- customer: {- name: "Kiran",- email: "",- avatar: "https://avatar.vercel.sh/k.png?text=K",- },+ name: "Kiran",+ email: "",+ avatar: "https://avatar.vercel.sh/k.png?text=K",};export const exampleData = {clicks: [{- ...common,event: "click",- timestamp: "2024-06-09T16:12:02.556Z",- click_id: "1",- continent: "NA",- country: "US",- city: "San Francisco",- ...dubLink,+ timestamp: new Date().toISOString(),+ click: {+ id: "1",+ continent: "NA",+ country: "US",+ city: "San Francisco",+ ...common,+ },+ link: dubLink,},{- ...common,event: "click",- timestamp: "2024-06-09T15:52:02.556Z",- click_id: "2",- continent: "NA",- country: "US",- city: "San Francisco",- ...dubLink,+ timestamp: new Date(Date.now() - 3 * 60 * 1000).toISOString(),+ click: {+ id: "2",+ continent: "NA",+ country: "US",+ city: "San Francisco",+ ...common,+ },+ link: dubLink,},{- ...common,event: "click",- timestamp: "2024-06-08T13:32:02.556Z",- click_id: "3",- continent: "NA",- country: "US",- city: "New York",- ...githubLink,+ timestamp: new Date(Date.now() - 7 * 60 * 1000).toISOString(),+ click: {+ id: "3",+ continent: "NA",+ country: "US",+ city: "New York",+ ...common,+ },+ link: githubLink,},],leads: [{- ...common,event: "lead",- click_id: "1",- timestamp: "2024-06-11T17:03:56.000Z",- event_id: "YbL8RwLTRRCxQz5H",- event_name: "Sign up",- continent: "NA",- country: "US",- city: "San Francisco",- ...dubLink,- ...steven,+ timestamp: new Date().toISOString(),+ eventId: "YbL8RwLTRRCxQz5H",+ eventName: "Sign up",+ click: {+ id: "1",+ continent: "NA",+ country: "US",+ city: "San Francisco",+ ...common,+ },+ link: dubLink,+ customer: steven,},{- ...common,event: "lead",- click_id: "2",- timestamp: "2024-06-10T16:07:56.000Z",- event_id: "YbL8RwLTRRCxQz5H",- event_name: "Sign up",- continent: "AS",- country: "IN",- city: "Kerala",- ...dubLink,- ...kiran,+ timestamp: new Date(Date.now() - 3 * 60 * 1000).toISOString(),+ eventId: "YbL8RwLTRRCxQz5H",+ eventName: "Sign up",+ click: {+ id: "1",+ continent: "NA",+ country: "US",+ city: "San Francisco",+ ...common,+ },+ link: dubLink,+ customer: kiran,},{- ...common,event: "lead",- click_id: "3",- timestamp: "2024-06-10T16:07:56.000Z",- event_id: "YbL8RwLTRRCxQz5H",- event_name: "Sign up",- continent: "NA",- country: "US",- city: "Pittsburgh",- ...dubLink,- ...tim,+ timestamp: new Date(Date.now() - 7 * 60 * 1000).toISOString(),+ eventId: "YbL8RwLTRRCxQz5H",+ eventName: "Sign up",+ click: {+ id: "3",+ continent: "NA",+ country: "US",+ city: "Pittsburgh",+ ...common,+ },+ link: githubLink,+ customer: tim,},],sales: [{- ...common,event: "sale",- click_id: "1",- timestamp: "2024-06-14T18:36:01.000Z",- event_id: "Nffk2cwShKu5lQ7E",- event_name: "Purchase",- payment_processor: "stripe",- invoice_id: "123456",- saleAmount: 900,- continent: "NA",- country: "US",- city: "San Francisco",- ...dubLink,- ...steven,+ timestamp: new Date().toISOString(),+ eventId: "Nffk2cwShKu5lQ7E",+ eventName: "Purchase",+ sale: {+ amount: 900,+ paymentProcessor: "stripe",+ invoiceId: "123456",+ },+ click: {+ id: "1",+ continent: "NA",+ country: "US",+ city: "San Francisco",+ ...common,+ },+ link: dubLink,+ customer: steven,},{- ...common,event: "sale",- click_id: "2",- timestamp: "2024-06-13T20:36:06.000Z",- event_id: "Nffk2cwShKu5lQ7E",- event_name: "Purchase",- payment_processor: "stripe",- invoice_id: "123456",- saleAmount: 700,- continent: "NA",- country: "US",- city: "Pittsburgh",- ...dubLink,- ...tim,+ timestamp: new Date(Date.now() - 3 * 60 * 1000).toISOString(),+ eventId: "Nffk2cwShKu5lQ7E",+ eventName: "Purchase",+ sale: {+ amount: 700,+ paymentProcessor: "stripe",+ invoiceId: "123456",+ },+ click: {+ id: "2",+ continent: "NA",+ country: "US",+ city: "Pittsburgh",+ ...common,+ },+ link: dubLink,+ customer: tim,},{- ...common,event: "sale",- click_id: "2",- timestamp: "2024-06-13T22:02:06.000Z",- event_id: "Nffk2cwShKu5lQ7E",- event_name: "Purchase",- payment_processor: "stripe",- invoice_id: "123456",- saleAmount: 1000,- continent: "AS",- country: "IN",- city: "Kerala",- ...dubLink,- ...kiran,+ timestamp: new Date(Date.now() - 7 * 60 * 1000).toISOString(),+ eventId: "Nffk2cwShKu5lQ7E",+ eventName: "Purchase",+ sale: {+ amount: 1000,+ paymentProcessor: "stripe",+ invoiceId: "123456",+ },+ click: {+ id: "3",+ continent: "AS",+ country: "IN",+ city: "Kerala",+ ...common,+ },+ link: dubLink,+ customer: kiran,},],};