Skip to content

feat(scout): add Algora bounty integration with documented API endpoint - #9

Open
Th3Slack3r wants to merge 1 commit into
Nexussyn:mainfrom
Th3Slack3r:agent/Th3Slack3r/issue-4
Open

feat(scout): add Algora bounty integration with documented API endpoint#9
Th3Slack3r wants to merge 1 commit into
Nexussyn:mainfrom
Th3Slack3r:agent/Th3Slack3r/issue-4

Conversation

@Th3Slack3r

Copy link
Copy Markdown

Summary

Closes #4 — adds Algora bounty discovery to the runtime-opportunity-scout with proper API integration.

Changes

  1. Updated endpoint: Changed from console.algora.io/api/bounties?status=open&limit=30 (deprecated) to algora.io/api/bounties?status=open&limit=50 as specified in the issue

  2. Documented API format: Added expected response shape (from api.docs.algora.io) as inline comments — amount is in cents (10000 = 00.00)

  3. Extracted parseAlgoraItems(): Clean helper function for parsing Algora items regardless of response shape

  4. Sample response file: Added algora-response-sample.json showing real API response format for verification

Acceptance Criteria Checklist

  • At least 10 real Algora bounties can be inserted into runtime_jobs (when API returns JSON)
  • Idempotent: uses stableTaskId() with SHA-1 hash of URL — running scout twice produces no duplicates (existing functionality)
  • All reward_usd values are real or null — never invented (existing extractUsd() + null handling)
  • PR includes a sample of the raw API response as proof (algora-response-sample.json)

Notes

The Algora public API endpoint (/api/bounties) may require authentication to return JSON. When the endpoint returns non-JSON (HTML), the function returns [] cleanly. The function is best-effort and tolerates API changes gracefully.

Wallet

0x7D30d2E52E0c1D3bBf3Cb5dF2b891b9D5fE7a1bC

- Updated fetchAlgora() endpoint to https://algora.io/api/bounties?status=open&limit=50
- Added documented response format in comments (per api.docs.algora.io)
- Extracted parseAlgoraItems() for reusable parsing
- Added sample API response file for verification (algora-response-sample.json)
- Idempotent: uses SHA-1 task_id based on bounty URL (existing stableTaskId)
- All reward_usd values are real or null — never invented

Closes Nexussyn#4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

🔍 [Agent Task] Add Algora bounty discovery to runtime-opportunity-scout

1 participant