78trust / 100
Images Image2image
by base.mapleai.shop in Other
x402 APIPassing, checked 2 h ago
Edit an image, priced per image and size
POST https://base.mapleai.shop/api/v1/images/image2image
Last 30 days
All checks passedSome failedAll failedNot checked
- Uptime
- 100%
- Response time
- 186 ms typical, 273 ms slowest 5%
- Last check
- 2 h ago
- Next check
- any minute now
How to call it
# See the payment challenge (nothing is charged)
curl -i -X POST "https://base.mapleai.shop/api/v1/images/image2image" \
-H "content-type: application/json" \
-d '{"image":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAIAAACQd1PeAAAADElEQVR4nGP4z8AAAAMBAQDJ/pLvAAAAAElFTkSuQmCC","model":"gpt-image-2","n":1,"prompt":"Make the leaf green","size":"1024x1024"}'import { wrapFetchWithPayment } from "@x402/fetch";
import { x402Client } from "@x402/core/client";
import { ExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
const client = new x402Client().register(
"eip155:8453",
new ExactEvmScheme(privateKeyToAccount(process.env.AGENT_KEY)),
);
const pay = wrapFetchWithPayment(fetch, client);
// Not sure it's safe to pay? Preflight it first for $0.005:
// GET https://toolvet.app/api/v1/check?url=https%3A%2F%2Fbase.mapleai.shop%2Fapi%2Fv1%2Fimages%2Fimage2image
const res = await pay("https://base.mapleai.shop/api/v1/images/image2image", {
method: "POST",
headers: { "content-type": "application/json" },
body: JSON.stringify({"image":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAIAAACQd1PeAAAADElEQVR4nGP4z8AAAAMBAQDJ/pLvAAAAAElFTkSuQmCC","model":"gpt-image-2","n":1,"prompt":"Make the leaf green","size":"1024x1024"}),
});
console.log(await res.json());Example input
{
"image": "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAIAAACQd1PeAAAADElEQVR4nGP4z8AAAAMBAQDJ/pLvAAAAAElFTkSuQmCC",
"model": "gpt-image-2",
"n": 1,
"prompt": "Make the leaf green",
"size": "1024x1024"
}Example output
{
"created": 1700000000,
"data": [
{
"url": "https://example.com/image.png"
}
]
}Security scan
- No findings. We scan names, descriptions and tool definitions for hidden instructions and other prompt-injection patterns.
Recent checks
| When | Result | HTTP | Time | Price |
|---|---|---|---|---|
| 2 h ago | Passed | 402 | 251 ms | $0.021 |
| 6 h ago | Passed | 402 | 273 ms | $0.021 |
| 10 h ago | Passed | 402 | 177 ms | $0.021 |
| 13 h ago | Passed | 402 | 187 ms | $0.021 |
| 17 h ago | Passed | 402 | 186 ms | $0.021 |
| 20 h ago | Passed | 402 | 191 ms | $0.021 |
| 23 h ago | Passed | 402 | 244 ms | $0.021 |
| 27 h ago | Passed | 402 | 277 ms | $0.021 |
| 31 h ago | Passed | 402 | 229 ms | $0.021 |
| 35 h ago | Passed | 402 | 184 ms | $0.021 |
| 38 h ago | Passed | 402 | 186 ms | $0.021 |
| 42 h ago | Passed | 402 | 171 ms | $0.021 |
| 45 h ago | Passed | 402 | 170 ms | $0.021 |
| 2 days ago | Passed | 402 | 120 ms | $0.021 |