-
Notifications
You must be signed in to change notification settings - Fork 1
📚 Add Comprehensive API Documentation #39
Copy link
Copy link
Open
Labels
documentationImprovements or additions to documentationImprovements or additions to documentation
Description
Description
The project lacks documentation for contract functions, frontend hooks, and integration guides for developers.
Current Documentation
README.md- Basic overviewDEVELOPMENT.md- Brief development guidedocs/folder exists but contents not reviewed
Required Documentation
1. Smart Contract Documentation
market-core.clar
| Function | Parameters | Returns | Description |
|---|---|---|---|
create-market |
question, duration | market-id | Creates new prediction market |
predict |
market-id, outcome, amount | bool | Places a prediction |
claim-winnings |
market-id | payout | Claims winning stake |
oxcast.clar (MVP Contract)
- Token functions (SIP-010)
- Staking functions
- Market functions
2. Frontend Hooks Documentation
/**
* useMarkets - Fetches all markets from the contract
* @returns {Object} { markets, isLoading, error, refetch }
* @example
* const { markets, isLoading } = useMarkets();
*/3. Integration Guide
- How to connect wallet
- How to place predictions
- How to create markets
- How to claim winnings
4. API Reference
- Hiro API endpoints used
- Rate limits
- Response formats
Files to Create
docs/contracts/market-core.mddocs/contracts/oxcast.mddocs/contracts/governance.mddocs/frontend/hooks.mddocs/frontend/components.mddocs/integration-guide.mddocs/api-reference.md
Priority
🟢 Low - Important for open source contribution
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
documentationImprovements or additions to documentationImprovements or additions to documentation