How We Tried To Fight Ecommerce Fraud at JunctionX Singapore Hackathonby@chip

How We Tried To Fight Ecommerce Fraud at JunctionX Singapore Hackathon

by Chip Dong LimOctober 12th, 2019
Read on Terminal Reader
Read this story w/o Javascript
tldt arrow

Too Long; Didn't Read

JunctionX Singapore hackathon tackled Shopee and Kaspersky’s track to reduce fraud in e-commerce. EY estimated that there is a US$10b-12b market for rural consumers in the next four years, which is a huge untapped opportunity. The fraud and security idea hits home, and mentors gave us the following insights: “Shopee has experienced a lot of fake user accounts coming from competitors in the past and it hurts Shopee’�s business.”
featured image - How We Tried To Fight  Ecommerce Fraud at JunctionX Singapore Hackathon
Chip Dong Lim HackerNoon profile picture

It has been a while since I’ve been to a hackathon. I always love that hackathon as an avenue to build something quickly within the 48-hour time constraint, the opportunity to sharpen my design skills, and network with fellow hackers. So when my colleague posted on Slack about JunctionX Singapore, I signed up!

2 of my colleagues and I were lucky to be selected as part of the 120 participants out of over 190 sign-ups.

But it was off to a rocky start — one of my colleagues bailed last minute. Dheeraj joined with me but he was not feeling well the next day.

We only finalized the problem we’re going to tackle on 7:15 PM the next day, with the pressure to hit the deadline in less than 17 hours…

It’s a small world. I bumped into Terry, whom I used to mentor at the Selangor Smart City and Future Commerce Hackathon in 2018. I remember both of us stayed up late to solve a bug of the valve not closing properly for his Arduino project. He was looking for a team to join, and I am so glad to have him on the team as he is a talented backend engineer working on embed software.

Brainstorming and Finalizing Ideas

On Friday evening, we started brainstorming ideas for Shopee and Kaspersky’s track, ranging from reducing churn with a subscription modal for repeat orders, loyalty program, intelligence dashboard for shopping behavior, to making education/help center more engaging and interactive for both buyers and sellers.

On Saturday, we validated project ideas from the consumer experience, payment, security and transportation that we’ve brainstormed with our Shopee mentors. The fraud and security idea hits home, and mentors gave us the following insights:

“Shopee has experienced a lot of fake user accounts coming from competitors in the past and it hurts Shopee’s business.

Competitors pretend to be real users who placed a large amount of quantity of orders, then proceed to cancel them.”

— Shopee mentors

Our mentor also mentioned that transportation is a huge issue for delivery companies. For instance, there are no postcodes available in rural areas in Indonesia. So a buyer might input something like “My house is beside this tree.”

It might be ridiculous to think that how could someone uses a tree as a landmark, but those who grew up in the same neighborhood would know what the buyer meant. There is also a lack of safe drop points like 7-Eleven for parcel collection in rural areas as well.

So, Dheeraj was exploring another idea to help rural consumers, who technically have the most to gain as they do not have access to a wide range of productsA report from EY estimated that there is a US$10b-12b e-commerce market for rural consumers in the next four years, which is a huge untapped opportunity.

As language is the barrier and trust is the key to conversion, Dheeraj was experimenting if rural consumers could “draw” what they want to buy, using Google Creative Lab’s AutoDraw API:

Framing The Problem

If you google “Shopee fraud”, fraud incidents that are reported by media are mostly consumer-facing and operational. For example, fake sellers in Taiwan and the rising eCommerce scams in Singapore. But what about the fraud that goes “unreported”? That’s exactly what we tackled over the weekend.

Shopee is already winning in 2 markets that it receives the largest amount of orders — Indonesia and Taiwan. StatCounter reported that in Indonesia, more than 70% of internet traffic comes from mobile devices, and Shopee wins in mobile apps with Tokopedia (#2) and Lazada (#3) following behind.


In an extremely saturated, aggressive and competitive market like this, dirty business techniques are not uncommon, with Uber’s unscrupulous “Hell” program spying on Lyft drivers, which resulted in the loss of revenue for Lyft.

A small percentage would cost a huge loss

Considering that Shopee’s Gross Merchandise Value (GMV) is over $10 billion in 2018, even a small percentage of fraud coming from competitors is $20 million:

US$10,000,000,000 ¹ x 0.9% ² x 10% ³ = US$20,000,000

¹ Shopee’s GMV in 2018
² Fraud to eCommerce Sales %/year by CyberSource
³ Estimation based on the total fraud

The Opportunities: How to Curb Competitors’ Fraud?

Verifying User Profile
Shopee already has an existing email and mobile OTP verification embed during the sign-up process. We think that the 1st layer of defense is to reduce fake accounts is to strengthen the current verification process by adding more layers on top of it: Valid credit card, shipping address and social media account.

Positive Reinforcement for Shopping Behaviour
One of the traits to identify highly suspicious account is to buy a large quantity of the same product and multiple transactions in a short amount of time to “hijack” merchants’ listing so that the stock is sold out during sales, which refrains the real customers out there from buying.

We think that placing a maximum quota on the stock quantity and total amount for the 1st-time user would reduce fraud. For example, if users promise not to cancel within the 24-hour period and request a refund, it’s very likely that these are real customers and not fake accounts, and we can provide them 10% OFF for the entire order.
Moreover, we can reinforce positive buying behavior: the more users shop, the higher the quota is lifted for placing an order.

The Solution

By factoring in the number of order, item price and maximum quantity of the item ordered, we can analyze if an account is a valid and loyal customer. Thanks to Terry for coming up with the formula and user flow:

JS code written for scammer detector:

If you shop at Shopee before, you might have noticed that under the Quantity field, if it says “100 pieces available” and you tried to update to 120, the quantity will be automatically reverted to 100 because that is the maximum allowed. We want to build on top of that existing function to encourage positive shopping behavior — by offering discounts for the entire order if users promise not to cancel within the 24-hour period:

For Shopee’s internal fraud team, we want to empower them by providing them the necessary tools to make an informed decision and do what they do best at, and this starts by providing real-time fraud threat score for Shopee site globally:

Shopee’s internal fraud team can also track the number, monitor the trends over time and audit/review these flagged accounts in real-time.

An organization might employ a network of fraudsters or even outsource them to third-world countries. Physically they are probably in the same location but could be routed through anonymously using VPNs. But by tracking logged-in data such as device IPs, OS, and browsers, it will be easier to observe the purchase patterns, spot frauds faster and bust hidden networks of these fraudsters.

Combining these three powerful tools together, we built a global dashboard to protect Shopee from competitors’ fraud:

In the previous example, 100 is the default maximum stock quantity that Shopee can allow the 1st-time users to purchase. What if we could allow some flexibility to the maximum quantity, the total amount allowed, and discounts applicable for the 1st-time buyer? 

Fraud Thresholds Tool comes in handy here by providing that customization. It could start out as an internal tool at first, but Shopee can roll this out to merchants at Seller Central as well.

Potential Future Developments

More scenarios and use cases
Over the 48 hours, we tackled the fraud scenarios coming from competitors, but more use cases can be included for enhancement.

Machine learning to facilitate Accurate Fraud Predictions
By utilizing tools such as TensorFlow, machine learning can help build a better fraud prediction model to help the fraud team to make better decisions.

Expand comprehensive user profile for other SEA businesses
Since data has been collected to build comprehensive user profiles to fight fraud, we thought to expand this to other SEA group’s businesses such as Garena and Digital Financial Services.

Final Thoughts

When the deadline hits at 12 noon on Sunday, I was still working on the slides. When Dheeraj submitted our entry, I feel so relieved with a sense of accomplishment of what we’ve built. There were moments we almost give up, but what I learned is although our resources and time are strained, we need to work with what we have.

During the brainstorming phase, Terry suggested that we can use board games to educate Shopee users. His two favorite board games are Catan and CASHFLOW by Robert Kiyosaki. It doesn’t make sense at first, but when we validate with our mentors, it is actually a great idea to use interactive games to educate buyers and sellers.

I learned that brainstorming is the best phase to go wild and crazy instead of killing creativity, and embracing these ideas with an open mind is key. Don’t aspire to be the smartest person in the room, and leave your ego at the door.

And yes, I need to learn Principle or Flinto to animate my prototype!


Dheeraj Joshi — Front-end | Twitter
Terry Pang — Backend | LinkedIn
Chip Dong Lim — Design | Portfolio / LinkedIn / Twitter

Thanks for making it to the end of this story! Are you enjoying reading it?

What are other awesome ideas that you might have thought of to solve for an eCommerce platform?

Let me know by commenting below ⇣
You can view the 6 final pitches I’ve compiled as well.