API_Endpoints
API Documentation
This documentation provides a ioprehensive guide to PeoPay’s APIs, enabling developers to integrate with the PeoPay ecosystem. The APIs allow seamless access to core features such as user management, P2P payments, staking, governance, and Dynamic Contribution Scoring (DCS).
1. Overview
PeoPay APIs enable developers to: - Authenticate users and manage accounts. - Initiate and track transactions, including crypto-to-mobile money conversions. - Access staking, rewards, and referral systems. - Participate in governance through voting and proposal submission. - Monitor user contributions and penalties via DCS.
Base URL
Production Environment:
https://api.peopay.io/v1
Sandbox Environment:
https://sandbox.api.peopay.io/v1
2. Authentication
Endpoint: Login
Authenticate users and retrieve a session token for subsequent API requests.
Method:
POST
URL:
/auth/login
Request
Response
Endpoint: Register
Create a new user account.
Method:
POST
URL:
/auth/register
Request
Response
3. User Management
Endpoint: Get User Profile
Retrieve user details, including DCS score and staking status.
Method:
GET
URL:
/user/profile
Headers:
Authorization: Bearer <token>
Response
4. Transactions
Endpoint: Send P2P Payment
Send a peer-to-peer payment using PeoCoin.
Method:
POST
URL:
/transactions/p2p
Request
Response
Endpoint: Crypto-to-Mobile Conversion
Convert crypto to mobile money.
Method:
POST
URL:
/transactions/convert
Request
Response
5. Staking
Endpoint: Stake PeoCoin
Stake PeoCoin to earn rewards.
Method:
POST
URL:
/staking/stake
Request
Response
Endpoint: Get Staking Rewards
Retrieve current staking rewards.
Method:
GET
URL:
/staking/rewards
Headers:
Authorization: Bearer <token>
Response
6. Governance
Endpoint: Submit Proposal
Submit a governance proposal.
Method:
POST
URL:
/governance/proposals
Request
Response
Endpoint: Vote on Proposal
Cast a vote on an active proposal.
Method:
POST
URL:
/governance/vote
Request
Response
7. Dynamic Contribution Scoring (DCS)
Endpoint: Get DCS Score
Retrieve the user’s DCS score.
Method:
GET
URL:
/dcs/score
Headers:
Authorization: Bearer <token>
Response
8. Error Codes
iomon Errors
Error Code
Message
Description
400
Bad Request
Invalid or malformed request data.
401
Unauthorized
Missing or invalid authentication token.
403
Forbidden
Insufficient permissions.
404
Not Found
Requested resource does not exist.
500
Internal Server Error
An unexpected error occurred.
9. Rate Limits
Free Tier: 100 requests per minute.
Pro Tier: 500 requests per minute.
Rate limit status is returned in the headers:
10. Examples
Send a Payment (cURL)
Next Steps
Test API endpoints in the sandbox environment.
Follow our Developer Guide for integration tutorials.
Join our iomunity forum for support.
Last updated
Was this helpful?