edeXa Signature API
edeXa provides open, standardized APIs and smart contract specifications that enterprises can self-host and fully control. With the edeXa Signature API, each company can integrate edeXa’s blockchain signing capabilities into their own workflow while retaining complete ownership of infrastructure and data.
edeXa Signature API offers a straightforward and secure method for digitally signing documents, generating cryptographic hashes, and verifying previously signed documents on the edeXa blockchain. It ensures data integrity, avoids duplicate submissions, and guarantees blockchain transparency.
Key Features
Accepts files via
multipart/form-data
uploads.Converts uploaded documents to SHA-256 hash.
Checks if the document hash is already signed.
Signs new document hashes on the edeXa blockchain.
Returns the blockchain transaction hash.
Security Highlights
We do not store original documents on the server or blockchain.
Only the SHA-256 hash is stored on-chain.
Blockchain-backed proof of authenticity.
API key-based access control.
API Service Demonstration
For a better understanding of the edeXa Signature API in action, we have prepared short demonstration videos.
🎯 What You’ll See
Sign a Document → Upload a file, generate its SHA-256 hash, and store hash on the edeXa blockchain. Instantly receive a transaction hash as proof of signing.
Verify a Document → Check if a document is already signed by comparing its hash against the blockchain records.
Validate on Blockchain → Use the transaction hash to confirm the signature on the edeXa Blockchain Service for complete transparency.
📄 Sign Document
🔍 Verify Document
👉 Access the UI here: edeXa-Signature
Project Setup
Clone the Repository
git clone https://github.com/devEdexa/signing-service-api.git
cd signing-service-api
Configure Environment
We provide a sample
.env.example
file to help you get started.
cp .env.example .env
Then update the .env
file with values that match your project setup and environment
RPC_URL
edeXa JSON-RPC URL (https://rpc.edexa.com
& https://rpc.edexa.network
)
PRIVATE_KEY
The private key of the signer wallet is used to sign transactions.
CHAIN_ID
Chain ID of the blockchain network (e.g., 5424 for edeXa mainnet).
CONTRACT_ADDRESS
Address of the deployed smart contract for document signing
API_AUTHENTICATION
Enables or disables api_key
based access control (true
or false
).
SIGN_DOC_API_KEY
api_key
to access the sign endpoint (optional if API_AUTHENTICATION=false
)
VERIFY_DOC_API_KEY
api_key
to access the verify endpoint (optional if API_AUTHENTICATION=false
)
EXPLORER_URL
Explorer URL of the edeXa Blockchain(https://explorer.edexa.network/
)
ℹ️ All environment variables should be configured as needed to match the deployment target and security model.
▶️ Run the Project
cargo build
cargo run
service will be available at http://localhost:3000.
🚀 Deployment Options
The signing service supports deployment through Docker for local development or Kubernetes for production environments.
🐳 Option 1: Docker Compose (Local Deployment)
A pre-built Docker image is available for quick deployment without requiring a Rust environment.
📜 Docker-Compose File:
▶️ Start the Service
Run this docker-compose.yaml
file using the below command..
docker-compose up -d
The API will be available for local testing at: http://localhost:3000
☁️ Option 2: Kubernetes Deployment (Production-Ready)
The signing service can be deployed to any Kubernetes cluster such as AWS EKS, Google GKE, or Azure AKS.
📜 Kubernetes File:
📜 Deployment Script: We also provide a helper shell script to simplify deployment.
▶️ Execute the Script
chmod +x deploy.sh
./deploy.sh
API Usage
Authentication
To access the Signing API, all requests must include an api_key
, which is used to authenticate the request and authorize access to protected endpoints. This key is typically passed as a form field in API requests
Submit a document for signing. The request must include the document file and a valid API key.
The document file to sign.
API key for authentication.
Document signed successfully
Bad request (file missing or too large)
Invalid or missing API key
Document already signed
POST /api/sign HTTP/1.1
Host: https:/.signing.edexa.team
Content-Type: multipart/form-data
Accept: */*
Content-Length: 33
{
"doc": "binary",
"api_key": "text"
}
{
"message": "Document signed successfully",
"tx_hash": "0xf108555e73a50ceb18f61c7f479e7b2f1b9cd529c61dfda057bd087ec8fc508b",
"doc_hash": "0x83ae7c97f752cebd10121105d64189907b39888f2bc02291aa5a899ac5ca2c3d",
"timestamp": "2025-08-18T04:29:37.348091086+00:00",
"explorer_url": "https://explorer.testnet.edexa.network/tx/0xf108555e73a50ceb18f61c7f479e7b2f1b9cd529c61dfda057bd087ec8fc508b"
}
Verify whether a document has already been signed and recorded on the blockchain.
The document file to verify.
API key for authentication.
Document verification successful
Document not signed or file missing
Invalid or missing API key
POST /api/verify HTTP/1.1
Host: https:/.signing.edexa.team
Content-Type: multipart/form-data
Accept: */*
Content-Length: 33
{
"doc": "binary",
"api_key": "text"
}
{
"message": "Document is signed",
"verified": true
}
Last updated