Infinitely scalable, super fast, and built for developers. Say goodbye to the limitations of Bitcoin and Ethereum. Epic is the future of payments.
Get started in minutes with our straightforward API. Here's how to create, sign, and submit a transaction in three simple steps.
Start by creating a JSON object for your transaction. Specify the sender, recipient, amount, token name and optional data to support ecommerce.
{
"from": "@gustave",
"to": "@maelle",
"amount": "100.0",
"namespace": "USDC",
"data": { "orderId": "abc123" },
}
Secure your transaction by signing the JSON object with your private key. This proves ownership and prevents tampering.
import { sign } from 'epic-crypto';
const jsonTx = '{"from": "...", "to": "...", "amount": "100.0", "namespace": "USDC"}';
const privateKey = 'your_private_key_here';
const signature = sign(jsonTx, privateKey);
Send the original transaction and the generated signature to the network through our API endpoint.
const signedTx = {
transaction: jsonTx,
signature: signature,
};
await fetch('/v1/submit', {
method: 'POST',
headers: {
'Content-Type': 'application/json'
},
body: JSON.stringify(signedTx)
});
And that's it. Your transaction is now live and secured on the blockchain!