---
title: "The JsFiddle of APIs?"
description: "Learn the fastest way to set up an API Mock server using an API Gateway. Create mocks while you build out your services."
canonicalUrl: "https://zuplo.com/blog/2022/03/28/the-jsfiddle-of-apis"
pageType: "blog"
date: "2022-03-28"
authors: "josh"
tags: "API Mocking, Tutorial"
image: "https://zuplo.com/og?text=The%20JsFiddle%20of%20APIs?"
---
Zuplo is so fast and flexible, it is the easiest way to setup a mock API. Here
we create a simple todo API (of course 🤦🏼‍♂️). We add our 'sleep' policy to make it
slow too - so you can call this from your UI client and simulate long loading
times.

<YouTubeVideo videoId="xvByk_e-s0s" />

Length: 2 minutes

Here's the code for the request handler:

```ts
import { ZuploContext, ZuploRequest } from "@zuplo/runtime";

export default async function (request: ZuploRequest, context: ZuploContext) {
  return [
    { text: "Learn Javascript", done: false },
    { text: "Learn Typescript", done: false },
    { text: "Play around in Zuplo", done: true },
    { text: "Build something awesome", done: true },
  ];
}
```

Have fun, APIFiddling!