Vaccine Card Scanner

I’m an AI enthusiast. When I read about the NYC Covid Safe cat-gate scandal (here and here), I wanted to know if I could make something a little bit better. Below is my 2-weekend attempt using a few low-cost AWS tools.

Discerning CDC Cards From 😺
AWS Textract AWS Rekognition S3 + Lambda Python Node.js

If you upload a non-Photoshopped image that fools the scanner, I'll buy you a beer (or coffee or tea). Background story here.

1. Upload an image

.png or .jpg images only
Errors here.
2. View image
Things to note:
  • File size: < 5mb ish (jpg or png)
  • Not bullet proof! Just better than this.
  • No photoshopping please! Just pics from your camera
  • Only πŸ‡ΊπŸ‡Έ US vaccine cards are recognized 😒
  • All uploaded images go to a non-public s3 bucket, and are purged every 24 hours
  • URL's are pre-signed with expirations – so they self-destruct. I'm not keeping tabs on you πŸ‘€ – I promise!
3. Card scan details
vax-card-scanner-part2.png

How it Works

  • Attach an image 5MB or less (png or jpg)

  • The app does some validation, then dispatches a GET request that sends back a pre-signed S3 URL that allows you to (temporarily) upload a specific file to a specific bucket. Pre-signed URLs are super handy. They come with expiration dates, and are generally a safe way to expose S3 bucket functionality to anonymous users.

  • When you’re ready, click the upload button. The app dispatches a PUT request, and the file is uploaded to the bucket. When the upload completes, two things happen:

    • A second pre-signed GET url is generated – this one allows you to view your uploaded image in the context of the web page (temporarily) – this too will expire

    • A lambda function is triggered which sends a Slack notification to yours truly

  • Finally, the app dispatches a POST request – this is the one that actually scans the uploaded image in the bucket. When the scan completes, the json response is displayed to the user.

This is a follow-up effort to this.