PhilRadar

Find medication before you travel. See which pharmacies actually have it before leaving home.

Inspiration

The idea came from a really frustrating experience.

A friend had just been discharged from the hospital with a prescription. We assumed we'd stop at the nearest pharmacy, buy the medication, and head home. Instead, they were out of stock.

So we walked to another pharmacy. Same story.

Then another.

Then another.

By the time we found the medication, we'd already spent a long time walking around with no clue whether the next pharmacy would have it either. It felt strange because pharmacies already know what's on their shelves. The information exists, but only the people behind the counter can see it.

That was the moment PhilRadar clicked for me. Why should someone have to visit five pharmacies just to find one medication?

What it does

PhilRadar helps people find medications before they leave home.

A user searches for a medicine, for example Paracetamol, and immediately sees nearby pharmacies that currently stock it. Results are sorted by distance and each pharmacy shows:

  • Stock status (In Stock, Low Stock, or Out of Stock)
  • When the information was last updated
  • How far the pharmacy is from the user

Since stock changes all the time, users can also Confirm that a report is still accurate or Flag it if it's wrong. That way the information stays useful instead of becoming another outdated directory.

Pharmacies have their own portal where they can register, manage their inventory, and update stock with just a few clicks. They can choose medications from a shared catalog or add new ones if needed.

How I built it

I built the frontend with Next.js and used Leaflet.js with OpenStreetMap/CARTO tiles for the map experience. User location comes from the browser's Geolocation API, and pharmacy distances are calculated using the Haversine formula.

The backend uses Supabase for authentication and the database.

I had a very short Buildweek timeline, so I leaned heavily on AI coding agents. They helped scaffold pages, generate parts of the database schema, build dashboard components, and speed up repetitive work.

That said, I wasn't just accepting whatever the agents produced. I spent most of my time designing the architecture, writing prompts, reviewing the generated code, fixing integration issues, and making sure everything worked together as one application.

Without AI, I honestly don't think I would have finished a two-sided platform within the time limit.

Challenges

The hardest part wasn't writing code.

It was getting AI-generated code to fit together.

A component might work perfectly on its own, but then it wouldn't match the database schema or another component's expectations. I'd go back, rewrite the prompt with more constraints, regenerate it, and repeat the process.

There were lots of moments where writing a small piece myself was actually faster than trying to convince the AI to generate exactly what I wanted.

Most of my debugging wasn't fixing broken features. It was fixing the connections between features like authentication, geolocation, inventory updates, and map rendering so they all behaved as one system.

What I'm proud of

I'm proud that I managed to ship a complete working product during Buildweek.

PhilRadar isn't just a landing page or a demo. The full flow works:

  • Search for a medication
  • Find nearby pharmacies
  • View live stock status
  • Confirm or flag reports
  • Manage inventory through the pharmacy dashboard

Getting all those moving pieces working together in a short amount of time feels like a big win.

What I learned

This project taught me that prompt engineering is a real development skill.

The quality of AI-generated code depends heavily on how well you describe the problem, the expected data, and how that piece fits into the rest of the application.

I also realized that building a real-time product isn't only about syncing data. It's about making sure people have a reason to keep the data accurate. That's why I added the Confirm and Flag system instead of relying only on pharmacy updates.

More than anything, I was reminded that good ideas usually come from real problems. PhilRadar started because one frustrating afternoon made me think, "There has to be a better way to do this."

What's next

There are still a lot of ideas I'd like to add:

  • Built-in navigation instead of opening Google Maps
  • Verified pharmacy accounts so trusted updates stand out
  • Notifications when a medication comes back in stock
  • Expanding beyond Accra into more cities and regions across Ghana

Built With

Share this project:

Updates