Freepik API + x402: pay only for what you use, build exactly what you want

A personal note to start

Hello there! 

I’ve been at Freepik for more than nine years (I was one of the earlier developers working in the infrastructure for this very blog…). And 9 years is long enough to have seen the industry change a few times over — from classic stock imagery to fully programmatic access (API), from bare metal to cloud computing, and, now, to generative AI touching everything we build. Through all of that, one thing has never really changed for us: the mission to make creativity accessible for all.

Our API team just shipped an important step for developers and builders: Freepik API is using the x402 protocol. Mystic model, as the first generative AI model using web3 and x402 in our suite.  The API team jumped into a brand‑new ecosystem, created the tools, wired the protocols, and made it real. I want to say this clearly: the Engineering team deserves the merit. This kind of work takes real effort — across engineering, product, and operations. 

 

Why x402 made sense (and why now)

Everyone can agree, AI is everywhere. Everyone is talking about inference, credits, GPUs, providers, and the latest models. That’s exciting, but it also brings new challenges. In the past, downloading an image or asset was simple — you knew exactly what you were getting and how it was billed. With inference, it’s harder to see what’s happening behind the curtain: What resources are used? What does a single generation really cost? How do you plan a budget when complexity keeps shifting?

At the same time, we live in the era of subscriptions. They’re great for predictability, but they’re not always the perfect match — especially when you’re prototyping, spiking, or building something that scales in bursts. Sometimes you just want to pay exactly for what you use and nothing more.

That’s the core reason x402 clicked for us. x402 is a Web3‑based protocol that lets you connect a wallet, natively call an API, and pay on demand for the exact usage you consume. No guesswork, no end‑of‑month surprises. It’s “metered creativity” that fits how modern builders actually work. Payment and inference in one request.

If you want a simple analogy, think about public transport. Some people buy a monthly pass (great if you ride every day). Others top up a card and pay per ride. x402 is that top‑up card for API usage and inference. You tap, you ride, you build — and you always know what’s being deducted.

What this unlocks for developers

Clarity and control. Before you call the API, you know you have the funds for that call. You’re not waiting for a bill next month. You’re not guessing whether a complex generation just spiked your spend.

Pay‑as‑you‑go by default. If you don’t need a subscription, you don’t have to carry one. Keep your workflow light — especially useful in R&D, hackathons, pilots, or seasonal workloads.

Native Web3 flow. If you’re already comfortable with wallets and decentralized services, this feels natural. You connect, you call, you settle.

Composability with an ecosystem. Being part of a protocol matters. Standards and shared rails tend to make everything faster — from discovery to integration to monetization. We like where this is going.

To be clear: this doesn’t replace our existing payment models. If a subscription fits your product, keep it. What x402 adds is choice.

How I explain x402 in one breath

x402 lets you know — before you generate — that the funds are there for that exact inference or API call, so you pay precisely for what you use, right when you use it.

Not next month. Not “we’ll figure it out later.” Now. Like tapping a transit card. 

If you’ve ever had to explain “why this month’s bill was different,” you can see why the per‑call clarity matters.

A simple mental model for the flow

  1. Connect your wallet (Web3‑native).
  2. Call Freepik API mystic endpoint via the protocol (your app does the same thing it always does: requests assets, search, generate…).
  3. The protocol confirms you’re funded, executes the call, and settles the exact cost.
  4. You get the response, your users get the result, and your ledger reflects one precise, itemized action.

That’s it. No big mystery. The innovation is in the rails and the timing — pay exactly, right now, for exactly what you used.

A word about the team

I want to pause and thank the people who made this happen. Implementing a new protocol is not just flipping a switch. Its design choices, security reviews, edge cases, documentation, tooling, testing, checking laws, double checking finances, and…have I already said testing? Failing and trying again, is to make sure that is useful for the users, while collaborating with people you have never worked before. This is, in my opinion, what defines Freepik.

Our API team jumped on this, learned fast, built the pieces, and shipped. I got to watch them move — quickly — again, Thank you all.

We also want to acknowledge the collaboration with Coinbase and the broader x402 initiative for making sure everything is working and helping us through this process. Decentralized payment rails for APIs are not a theory anymore; they’re real, and they’re getting better because teams are actually shipping.

What this does not change

  • Your choices. Subscriptions remain for the teams who prefer them.
  • Your rights and obligations. Licensing, documentation, and compliance processes remain intact.
  • Your path to support. You still get Freepik’s support channels, documentation, and guidance.

This is one more way to work — not a forced migration.

Frequently asked (early) questions

Do I need to be a Web3 expert?
No. If you’re comfortable connecting a wallet and following the docs, you’ll be fine. If you prefer not to, you can continue using familiar models.

Is this only for AI inference?
It’s for API usage, first we are shipping x402 for mystic model— more to come.

What about gas fees or network costs?
The protocol handles settlement. Exact mechanics and fees depend on network conditions and your configuration. We’ll keep the docs clear and practical so you can plan.

Will I still get the docs and invoices my business needs?
Yes. We care about developer experience and business operations. You’ll have what you need for accounting and tax purposes.

For specifics and examples, head to the docs (linked below).

(Optional) quick-start flavor

Heads‑up: endpoints and headers below are illustrative. Use the official docs for exact routes, parameters, and auth.

The shape is simple on purpose: connect wallet → sign intent → call → settle → receive results. Swap in the real gateway URL, headers, and params from the docs.

Why do I need an API KEY? 

We are implementing x402 as a choice, your choice, you can decide to use it, and we want to bring you the best of our products and the best of our platform. If you are a professional, you know how important it is to be able to present reports, taxes, etc. That’s what the API key will give you. We’ll make sure to connect your request back to you. 

Why I’m excited about where this goes

We’ve all felt the friction of “heavy” integrations: new billing systems, new contracts, new everything. Protocols like x402 shrink the mental overhead of trying new capabilities. You fund, you build, you see value, and you decide how far to go — without carrying a plan you might not fully use, and making budgeting easier.

More broadly, I think this is part of a bigger shift. Creative tech is moving toward clearer costs, clearer rights, and clearer choices. Builders need it. Teams need it. Users need it. We’re happy to push in that direction.

And again: this is the beginning of a long road. We’ll adapt. We’ll stay flexible. We’ll keep improving how you discover, select, generate, and use content — with transparency about what’s happening behind the curtain.

We need to remember more than ever that progress isn’t just about new features, new models that “do the magic” for me. Progress must come with direction. Aiming our efforts towards a trustworthy technology has to be one of our main goals as “techies”.

To the API team: thank you. To our partners and the ecosystem: we’re glad to be building with you. And to everyone about to ship something new on top of this: we can’t wait to see what you make.

Let’s keep moving forward.