SYSTEM NOTICE

Auto translation by AI. Be sure, accuracy, nuances and authorial intent may not be fully reflected.
見出し画像

How to Combine Receipts into a PDF | Done in 3 Minutes with Claude Code

#Receipts #PDF #Combine #Claude Code #AI Utilization #Side Hustle #Expense Reporting #Tax Return #Image Conversion #For Beginners

Have you ever had the experience of taking photos of receipts with your smartphone, only to realize they are all different orientations and sizes, forcing you to rearrange them every time before submission?

In this article, I will introduce a procedure to combine multiple receipt photos into a single PDF with unified orientation and size by giving just one instruction to Claude Code. You don't need to write any code. You can reproduce this just by following the steps.


What you need

  • An environment where Claude Code can be used (must be set up)

  • Photos of the receipts you want to combine (JPG, PNG, or HEIC are all acceptable)

  • Python installed (Claude Code can check for it and even handle the installation)

The photos can be transferred from your smartphone or scanned data. It doesn't matter if the filenames are sequential numbers like "IMG_3847.JPG".


Overall flow

  1. Gather the receipt photos into one folder

  2. Give the folder to Claude Code and provide instructions

  3. Check the generated PDF

That's it. You don't need to look at the code along the way.


Step 1: Gather the photos into one folder

Create a folder named "receipts" on your desktop and put all the photos you want to combine into it.

The order of the filenames will be the page order of the PDF. If you number them like "01_convenience_store.jpg" and "02_train.jpg", they will be output in the order you intend.


Step 2: Give instructions to Claude Code

Open Claude Code and enter the following. You can copy and use it as is.


Please combine the receipt images in the "receipts" folder on the desktop under the following conditions:

  • Unify all images to A4 size

  • Standardize orientation to portrait (rotate landscape images 90 degrees)

  • Set margins to 10mm on all sides

  • Order pages alphabetically by filename

  • Save the completed PDF in the same folder as "receipts_compiled.pdf"


That is all. Claude Code will check if the necessary Python libraries (such as Pillow) are installed and will suggest installing them if they are not. Simply reply "yes" to proceed.


Step 3: Check the generated PDF

Once the process is complete, "receipts_compiled.pdf" will be generated inside the receipts folder. Open it to verify.

Here is a summary of common issues and how to handle them.

If "the images are too small and have too much margin"

Add the instruction "Please scale the images to fill the A4 page (maintaining aspect ratio)" and run it again.

If "some pages are rotated incorrectly"

Smartphone photos sometimes record orientation via EXIF data. Adding "Please reflect EXIF rotation data before standardizing orientation" will almost always resolve this.

If "the file size is too large"

Sometimes images are not compressed when converted to PDF. Instructing it to "Please compress images at JPEG quality 80 during output" often reduces a file that was over 30MB for 10 pages down to 3-4MB.


What I learned from actually doing this

When I compiled 10 receipts using this method, it took about 3 minutes from entering the instructions to checking the result. This is a task that used to take over 20 minutes, involving rotating each image one by one in Photoshop and then combining them in Acrobat.

Fine-tuning (such as changing margin sizes or keeping specific pages in landscape) can also be handled simply by adding a verbal request. The fact that I don't need to read the code is why I am able to use this in my actual workflow.


Summary

  • Collect photos of receipts into one folder

  • Provide orientation, size, and filename conditions to Claude Code in natural language

  • Check the generated PDF and make fine-tuned adjustments with text if necessary

Once you have it running, from next time on, all you need to do is put the photos in the same folder and give the same instructions. If you do this task every time you file a tax return or process expenses, I think you will find that trying it once will change how much time it takes.


If you compile receipts for monthly expense reports, please try it first with 5 to 10 receipts for this month. Once it works well, organizing your folder structure by month will make management even easier.

いいなと思ったら応援しよう!