Skip to content

Agentpay-Org/Agentpay-contracts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

58 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AgentPay Contracts

Soroban smart contracts for the AgentPay protocol: escrow, usage recording, and payment settlement on Stellar.

Overview

  • escrow — Records usage and supports settlement logic for machine-to-machine payments.

Prerequisites

Setup for contributors

  1. Clone the repo (or add remote and pull):

    git clone <repo-url> && cd agentpay-contracts
  2. Install Rust (if needed):

    curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
    rustup component add rustfmt
  3. Verify setup:

    cargo fmt --all -- --check
    cargo build
    cargo test

Project structure

agentpay-contracts/
├── Cargo.toml              # Workspace root
├── contracts/
│   └── escrow/
│       ├── Cargo.toml
│       └── src/
│           ├── lib.rs      # Contract logic
│           └── test.rs     # Unit tests
└── .github/workflows/
    └── ci.yml              # CI: fmt, build, test

Commands

Command Description
cargo fmt --all Format code
cargo fmt --all -- --check Check formatting (CI)
cargo build Build
cargo test Run tests

CI/CD

On push/PR to main, GitHub Actions runs:

  • Format check (cargo fmt --all -- --check)
  • Build (cargo build)
  • Tests (cargo test)

Contributing

  1. Fork the repo and create a branch.
  2. Make changes; ensure cargo fmt, cargo build, and cargo test pass locally.
  3. Open a pull request. CI must pass before merge.

License

MIT

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages