This PR implements support for Cosmos ATOM payments in addition to the existing Laconic testnet (alnt) payment system. Users can now make payments on the Cosmos mainnet and provide the transaction hash as payment proof for application deployments.
Configuration
Added ATOM payment config to webapp-deployment-status-api:
ATOM_PAYMENT_ADDRESS: The Cosmos address to receive payments
MIN_ATOM_PAYMENT: Minimum required payment (defaults to 1 ATOM)
COSMOS_RPC_ENDPOINT: URL for Cosmos RPC node
New Payment Verification Module
Created atomPayments.ts with verifyAtomPayment function to:
Query Cosmos RPC endpoint for transaction details
Verify payment recipient, amount, and success
Prevent double-spending with in-memory transaction tracking
Support marking transactions as "used" for deployments
API Enhancements
Added new endpoint /verify/atom-payment to:
Accept transaction hash and minimum amount
Verify ATOM payment validity
Track transaction usage to prevent double-spending
Glue
Updated run.sh to pass ATOM configuration to stack orchestrator
Stack Orchestrator Integration
Updated confirm_payment in util.py to:
First check for laconic payment validity
If not found, verify as ATOM payment via API call
Enable cross-system verification to maintain payment integrity
Mark transaction as used when verified for deployment
Deployer Record Updates
Extended WebappDeployer record format to include:
atomPaymentAddress: Cosmos address for payments
minimumAtomPayment: Minimum required ATOM amount
Updated CLI options in publish-webapp-deployer.py
Testing
ATOM payments can be tested by:
Setting up a deployer with an ATOM payment address
Making a payment to this address on Cosmos mainnet
Using the transaction hash in an ApplicationDeploymentRequest
Verifying the deployment proceeds successfully
Goes with: https://git.vdb.to/cerc-io/stack-orchestrator/pulls/968
This PR implements support for Cosmos ATOM payments in addition to the existing Laconic testnet (alnt) payment system. Users can now make payments on the Cosmos mainnet and provide the transaction hash as payment proof for application deployments.
## Configuration
- Added ATOM payment config to webapp-deployment-status-api:
- ATOM_PAYMENT_ADDRESS: The Cosmos address to receive payments
- MIN_ATOM_PAYMENT: Minimum required payment (defaults to 1 ATOM)
- COSMOS_RPC_ENDPOINT: URL for Cosmos RPC node
## New Payment Verification Module
- Created atomPayments.ts with verifyAtomPayment function to:
- Query Cosmos RPC endpoint for transaction details
- Verify payment recipient, amount, and success
- Prevent double-spending with in-memory transaction tracking
- Support marking transactions as "used" for deployments
## API Enhancements
- Added new endpoint /verify/atom-payment to:
- Accept transaction hash and minimum amount
- Verify ATOM payment validity
- Track transaction usage to prevent double-spending
## Glue
- Updated `run.sh` to pass ATOM configuration to stack orchestrator
## Stack Orchestrator Integration
- Updated confirm_payment in util.py to:
- First check for laconic payment validity
- If not found, verify as ATOM payment via API call
- Enable cross-system verification to maintain payment integrity
- Mark transaction as used when verified for deployment
## Deployer Record Updates
- Extended WebappDeployer record format to include:
- atomPaymentAddress: Cosmos address for payments
- minimumAtomPayment: Minimum required ATOM amount
- Updated CLI options in publish-webapp-deployer.py
## Testing
ATOM payments can be tested by:
1. Setting up a deployer with an ATOM payment address
2. Making a payment to this address on Cosmos mainnet
3. Using the transaction hash in an ApplicationDeploymentRequest
4. Verifying the deployment proceeds successfully
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Goes with: cerc-io/stack-orchestrator#968
This PR implements support for Cosmos ATOM payments in addition to the existing Laconic testnet (alnt) payment system. Users can now make payments on the Cosmos mainnet and provide the transaction hash as payment proof for application deployments.
Configuration
New Payment Verification Module
API Enhancements
Glue
run.shto pass ATOM configuration to stack orchestratorStack Orchestrator Integration
Deployer Record Updates
Testing
ATOM payments can be tested by:
revised to do this without stack-orchestrator. this is deployed and works for both LNT and ATOM
revised even further such that payment verification happens at the app level.
Pull request closed