惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

TaoSecurity Blog
TaoSecurity Blog
T
Troy Hunt's Blog
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
Vercel News
Vercel News
T
Threatpost
G
Google Developers Blog
T
Threat Research - Cisco Blogs
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
T
The Exploit Database - CXSecurity.com
H
Heimdal Security Blog
Google DeepMind News
Google DeepMind News
Cyberwarzone
Cyberwarzone
T
The Blog of Author Tim Ferriss
Know Your Adversary
Know Your Adversary
Hacker News: Ask HN
Hacker News: Ask HN
www.infosecurity-magazine.com
www.infosecurity-magazine.com
S
Schneier on Security
B
Blog
V2EX - 技术
V2EX - 技术
NISL@THU
NISL@THU
C
CERT Recently Published Vulnerability Notes
W
WeLiveSecurity
C
Cybersecurity and Infrastructure Security Agency CISA
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
Y
Y Combinator Blog
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
Spread Privacy
Spread Privacy
The Last Watchdog
The Last Watchdog
V
Vulnerabilities – Threatpost
N
Netflix TechBlog - Medium
Schneier on Security
Schneier on Security
F
Fortinet All Blogs
N
News | PayPal Newsroom
Attack and Defense Labs
Attack and Defense Labs
Blog — PlanetScale
Blog — PlanetScale
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
Microsoft Security Blog
Microsoft Security Blog
S
Security @ Cisco Blogs
人人都是产品经理
人人都是产品经理
爱范儿
爱范儿
P
Privacy & Cybersecurity Law Blog
P
Proofpoint News Feed
Project Zero
Project Zero
I
Intezer
罗磊的独立博客
H
Hackread – Cybersecurity News, Data Breaches, AI and More
酷 壳 – CoolShell
酷 壳 – CoolShell
博客园 - Franky
SecWiki News
SecWiki News
Martin Fowler
Martin Fowler

DEV Community

Authentication Security Deep Dive: From Brute Force to Salted Hashing (With Java Examples) Why AI Systems Don’t Fail — They Drift Spilling beans for how i learn for exam😁"Reinforcement Learning Cheat Sheet" I Replaced Chrome with Safari for AI Browser Automation. Here's What Broke (and What Finally Worked) How Python Borrows Other People's Work The $40 Architecture: Processing 1 Billion API Requests with 99.99% Uptime Vibe Coding: A Workflow Guide (From Zero to SaaS) Most webhook security guides protect the wrong side. The scary part is delivery. Headless CMS for TanStack Start: Build a Blog with Cosmic EU Age Verification App "Hacked in 2 Minutes" — What Actually Happened Comfy Cloud’s delete function does not actually remove files Running AI Models on GPU Cloud Servers: A Beginner Guide Event-driven media intelligence with AWS Step Functions and Bedrock I scored 500 AI prompts across 8 quality dimensions — here's what broke How to Call Google Gemini API from Next.js (Free Tier, No Backend Needed) The Portal Protocol: Reclaiming Human Connection in the Age of AI How to Fix Your Team's Scattered Knowledge Problem With a Self-Hosted Forum Intro to tc Cloud Functors: A Graph-First Mental Model for the Modern Cloud Designing Multi-Tenant Backends With Both Ownership and Team Access I Built a Neumorphic CSS Library with 77+ Components — Here's What I Learned PostgreSQL Performance Optimization: Why Connection Pooling Is Critical at Scale Cómo construí un SaaS multi-rubro para gestionar expensas en Argentina con FastAPI + Vue 3 🚀 I Built an Ethical Hacking Scanner Tool – Open Source Project I Replaced /usage and /context in Claude Code With a Single Statusline A Pythonic Way to Handle Emails (IMAP/SMTP) with Auto-Discovery and AI-Ready Design I Collected 8.9 Million Polymarket Price Points — Here's What I Found About How Markets Really Move EcoTrack AI — Carbon Footprint Tracker & Dashboard Everyone's Using AI. No One Agrees How. 5 self-hosted ebook managers worth trying in 2026 Building Your First AI Agent with LangChain: From Chatbot to Autonomous Assistant Common SOC 2 Failures (Real World) Stop Vibe-Checking Your AI App: A Practical Guide to Evals How to Use SonarQube and SonarScanner Locally to Level Up Your Code Quality Your Next To-Do App Is Dead — I Replaced Mine with an OpenClaw AI Sign a Nostr event in 60 lines of Python using coincurve — no nostr-sdk, no nbxplorer, no rust toolchain ITGC Audit Explained Like You’re in Big 4 Patch Tuesday abril 2026: Microsoft parcha 163 vulnerabilidades y un zero-day en SharePoint Stop scraping everything: a better way to track competitor price changes Listing on MCPize + the Official MCP Registry while routing payments OUTSIDE the marketplace — how I kept 100% of my x402 revenue Building an AI-Powered Risk Intelligence System Using Serverless Architecture Why We Ripped Function Overloading Out of Our AI Toolchain Testing AI-Generated Code: How to Actually Know If It Works SaaS Churn Is Killing Your Business. Here Is What to Do About It (Without a Support Team) The Speed of AI Is No Longer Linear - And Self-Improving Models Are Why How to Implement RBAC for MCP Tools: A Practical Guide for Engineering Teams From Standard Quote to Persuasive Proposal: AI Automation for Arborists I built a CLI that scaffolds complete multi-tenant SaaS apps Axios CVE-2025–62718: The Silent SSRF Bug That Could Be Hiding in Your Node.js App Right Now The dashboard that ended our friendship Data Pipelines Explained Simply (and How to Build Them with Python) The Hidden Cost of AI Systems Nobody Talks About. undefined vs undeclared, and how typeof behaves Switching from file-based jobs to NATS/Kafka in Rust without changing code io_uring Adventures: Rust Servers That Love Syscalls Why Agentic AI is Killing the Traditional Database The POUR principles of web accessibility for developers and designers Quantum Neural Network 3D — A Deep Dive into Interactive WebGL Visualization How To Install Caveman In Codex On macOS And Windows Automation Pipeline Reliability: Why Your Workflow Breaks When Nobody Is Watching I Built an 'Open World' AI Coding Agent — It Works From ANY Folder From Freelancing to Product: A Tech Service Company's SaaS Transformation China's AI Giants: Adding Tencent Hunyuan & ByteDance Doubao to AI University (74 Providers) On the Vibe Coders and Their Lies clerk: Auto-Summarize Your Claude Code Sessions AI Weekly — 2026/04/10–04/17 | The Model Lockdown Is Here, but the Toolchain Is the Real Battleground AI 週報 — 2026/04/10–2026/04/17 模型封鎖潮來了,但工具鏈才是真戰場 Maybe this is how Open-Source apps are born... 🚀 Fine-Tune LLMs with LoRA and QLoRA: 2026 Guide tRPC v11 + Next.js App Router: End-to-End Type Safety Without the Boilerplate ShadCN UI in 2026: Why I Stopped Installing Component Libraries and Started Owning My Components SaaS Billing in React Server Components: Stripe + Supabase Without a Single `useEffect` Join our DEV Weekend Challenge — $1,000 in Prizes Across TEN winners! Submissions Due April 20 at 6:59 AM UTC. Implementing FSRS Spaced Repetition in Flutter + Supabase — Adding Memory Science to an AI Learning App "I Texted My Localhost From the Train — Claude Code Fixed the Bug Before I Got Home" I Built a Sales Prep AI and It Went Deeper Than Expected Design to Code #2: One JSON, Eleven Outputs Solving the 100M-Row Problem: A Summary Table Pattern for High-Volume Push Notification Logs Flutter Web With Wasm: What Actually Changes For Developers I Built 50 Royalty-Free Soundtracks for My Side Project in a Weekend Using AI Music Generation The Vibe Coding Security Checklist: 7 Things to Check Before You Ship Stop Letting Googlebot Guess Fix Your React App's SEO Right Desconstruindo o Streaming do LinkedIn: Como Criar um Engine de Extração de Vídeo de Alta Performance com HLS e FFmpeg (EDA Part-1) EDA (Exploratory Data Analysis) Explained With Real Life — Why Looking at Your Data Is the Most Important Step in Machine Learning Brand Relationship Management at Scale: Our 4-Touch Outreach System for 200+ Brands Why String.fromEnvironment() Might Return an Empty String in Dart JGuardrails 1.0.0 — Hardening Java LLM Apps Against Jailbreaks, Toxicity, and Prompt Injection Plan and Schedule a Full Week of Threads Content From One Claude Conversation Coding Cat Oran Ep3, Five Tables Changed Everything Updated: BFF Pattern I'm done watching freelancers get buried by 200 proposals. So I'm building the alternative. This is my first post BFS Algorithm in Java Step by Step Tutorial with Examples Tracking LLM Pricing Monthly: An Open Dataset for 22 AI Models How We Measure Content ROI on a Comparison Site: Revenue Attribution Without Perfect Data Introducing Nova AI Ops: The AI-Native Operating System for SRE Teams I built a free desktop video downloader for Windows — Grabbit How Talkie OCR Helps Vision-Impaired & Dyslexic Users Read the World Around Them VRCFaceTracking安装和iPhone面捕配置教程,有bug Even CrowdStrike Can't See Your Agents The Automation Gold Rush: What n8n Workflows and Claude Are Opening Up for Developers Right Now
Chain Document Extraction, Image Processing, and Generation in a Single Claude Code Session
Iteration La · 2026-04-30 · via DEV Community

One Conversation, Four APIs

You get a PDF invoice from a supplier. You need to extract the line items, resize the supplier's logo, and generate a branded summary card for your internal dashboard. Three separate tasks that normally mean three separate scripts, three sets of API credentials, and an afternoon of glue code.

With MCP, all four Iteration Layer APIs are available as tools inside your AI assistant. Claude Code and Cursor can call them in sequence within a single conversation — passing the output of one API directly into the next. No intermediary scripts. No file juggling. Just describe the workflow, and the assistant chains the calls together.

Setting Up All Four Tools

The Iteration Layer MCP server exposes all APIs through a single endpoint. One setup gives you access to Document Extraction, Image Transformation, Image Generation, and Document Generation.

In Claude Code:

claude mcp add iterationlayer --transport http https://api.iterationlayer.com/mcp

Enter fullscreen mode Exit fullscreen mode

In Cursor, add to .cursor/mcp.json:

{
  "mcpServers": {
    "iterationlayer": {
      "type": "http",
      "url": "https://api.iterationlayer.com/mcp"
    }
  }
}

Enter fullscreen mode Exit fullscreen mode

That's it. One server, four tools: extract_document, transform_image, generate_image, generate_document. Authentication happens via OAuth in the browser on first use.

A Real Workflow: Invoice to Summary Card

Here's what a multi-API chain looks like in practice. You have a supplier invoice PDF and need to produce a branded summary card for your internal system.

Step 1 — Extract the data.

"Extract the supplier name, invoice number, date, line items with descriptions and amounts, and the total from this invoice PDF."

The assistant calls extract_document with a schema matching your request. Back comes structured JSON with every field and its confidence score:

{
  "supplierName": {
    "value": "Nordic Components AB",
    "confidence": 0.96,
    "citations": ["Nordic Components AB"]
  },
  "invoiceNumber": {
    "value": "NC-2026-1847",
    "confidence": 0.98,
    "citations": ["Invoice #NC-2026-1847"]
  },
  "invoiceDate": {
    "value": "2026-02-28",
    "confidence": 0.97,
    "citations": ["Date: 28 February 2026"]
  },
  "lineItems": {
    "value": [
      {
        "description": {
          "value": "Circuit boards (x200)",
          "confidence": 0.95,
          "citations": ["Circuit boards (x200)"]
        },
        "amount": {
          "value": 4800.00,
          "confidence": 0.97,
          "citations": ["4,800.00"]
        }
      },
      {
        "description": {
          "value": "Connector assemblies (x50)",
          "confidence": 0.94,
          "citations": ["Connector assemblies (x50)"]
        },
        "amount": {
          "value": 1250.00,
          "confidence": 0.96,
          "citations": ["1,250.00"]
        }
      }
    ],
    "confidence": 0.95
  },
  "total": {
    "value": 6050.00,
    "confidence": 0.98,
    "citations": ["Total: 6,050.00"]
  }
}

Enter fullscreen mode Exit fullscreen mode

Step 2 — Process the supplier logo.

"Now take the supplier's logo from https://example.com/nordic-logo.png, resize it to 120x40, and convert it to PNG with a transparent background."

The assistant calls transform_image with resize and convert operations. The logo comes back optimized for placement in the summary card.

Step 3 — Generate the summary card.

"Generate a 800x400 image for the dashboard. White background. Put the resized supplier logo at the top left. 'NC-2026-1847' as the title in dark text. Below that, a gray subtitle line with 'Nordic Components AB — Feb 28, 2026'. At the bottom right, the total '$6,050.00' in large bold text. Add a thin blue accent line across the top."

The assistant calls generate_image with the extracted data and processed logo composed into a layer stack. The dashboard card is generated in one call — no manual data entry, no Figma, no template.

Three API calls, one conversation, zero glue code. The assistant passed data between each step because it has the full conversation context.

More Chaining Patterns

The invoice-to-card workflow is just one pattern. Here are a few more that combine multiple APIs in a single session.

Receipt to expense report PDF:

"Here are three receipt photos from my business trip. Extract the vendor name, date, amount, and category from each one. Then generate a PDF expense report with a table of all items, a total at the bottom, and my name 'Jane Chen' in the header."

The assistant calls extract_document for each receipt, collects the structured data, then calls generate_document to produce a formatted PDF expense report. Two API types, one conversation. The receipts go in as photos and a finished PDF comes out.

Product photo to catalog page:

"Take this product photo and resize it to 600x400 with smart cropping. Then generate an A4 PDF product sheet with the cropped photo at the top, the product name 'ErgoDesk Pro' as a headline, a paragraph of description text, a table of specifications, and a QR code linking to the product page."

The assistant calls transform_image for the crop, then generate_document to build the product sheet with the processed image, text blocks, a specs table, and a QR code — all in one document.

Contract to summary image:

"Extract the parties, effective date, term length, and total contract value from this PDF. Then generate a 1200x630 card with a dark background showing the key terms — party names at the top, dates and value below, styled like an OG image."

extract_document pulls the key terms, generate_image composes them into a shareable summary card. Useful for Slack updates, internal dashboards, or stakeholder emails.

Screenshot to optimized banner:

"Take this screenshot, crop it to 16:9 aspect ratio with smart cropping, upscale it to 2x, then generate a marketing banner with the screenshot in the center, a gradient overlay, and 'Now Available' text on top."

transform_image handles the crop and upscale, generate_image composes the final banner with the processed screenshot as a layer. The assistant knows to apply the transformations first and use the result in the composition.

Why This Works

The reason multi-API chaining works smoothly in conversation is that the assistant holds the full context. After extracting data from a document, it doesn't forget the results — it uses them directly in the next tool call.

This is fundamentally different from writing pipeline code. In code, you parse the extraction response, map it to the generation request, handle error cases, and wire the data flow explicitly. In conversation, the assistant does that mapping implicitly. You say "use the supplier name from the invoice" and it knows which value you mean.

The tradeoff is clear. Conversation-based chaining is ideal for:

  • One-off workflows — processing a single document or batch without building a script
  • Prototyping pipelines — figuring out the right sequence of API calls before writing production code
  • Ad-hoc data processing — extracting, transforming, and generating when the input varies every time

For production pipelines that run on a schedule or process hundreds of documents, you'd move to direct API calls. But the chain you prototyped in conversation maps directly to the API requests you'll write — same endpoints, same parameters, same data structures.

Combining All Four APIs

The Iteration Layer MCP server gives you four tools that cover the full content processing lifecycle:

  • Document Extraction — structured data out of PDFs, images, Word files
  • Image Transformation — resize, crop, convert, upscale, sharpen, and 18 more operations
  • Image Generation — layer-based composition for cards, banners, graphics
  • Document Generation — PDFs, DOCX, EPUB, PPTX from structured content blocks

These tools compose in any order. Extract data from a document, use it to generate an image, transform that image, embed it in a new document. Or go the other direction — take a screenshot, transform it, and extract text from it. The assistant figures out the sequence from your description.

Tips for Effective Chaining

Be explicit about data flow. When you want the assistant to use output from a previous step, reference it directly: "Use the total from the invoice extraction" rather than "add the total." The assistant handles the mapping, but clarity helps.

Break complex chains into steps. Instead of describing a five-step workflow in one message, walk through it step by step. This lets you verify intermediate results — check that the extraction looks right before using it to generate a report.

Check confidence scores. Document Extraction returns confidence scores for every field. If a score is low, ask the assistant to show you the raw value so you can verify it before it flows into a generated document or image.

Iterate on individual steps. If the generated image looks right but the PDF layout needs work, you don't need to re-run the whole chain. Just ask the assistant to regenerate the document with adjusted styling. The extracted data and processed images are still in the conversation context.

Get Started

Sign up for a free account at iterationlayer.com — no credit card required. Add the MCP server to Claude Code or Cursor with the configuration above, and start chaining APIs from your next conversation.

The docs cover every tool — Document Extraction schemas, Image Transformation operations, Image Generation layers, and Document Generation blocks. Start with a two-step chain — extract data from a document and generate an image from it. Once that clicks, the four-step workflows follow naturally.