Add HTTP status codes to swarm join and coordinate endpoints
Some checks failed
API Endpoint Tests / test-api-endpoints (push) Successful in 16s
Cross-Node Transaction Testing / transaction-test (push) Successful in 2s
Deploy to Testnet / deploy-testnet (push) Successful in 1m7s
Integration Tests / test-service-integration (push) Successful in 2m38s
Multi-Node Stress Testing / stress-test (push) Successful in 2s
Node Failover Simulation / failover-test (push) Successful in 2s
Production Tests / Production Integration Tests (push) Successful in 17s
Python Tests / test-python (push) Failing after 1m6s
Security Scanning / security-scan (push) Successful in 16s

- Add status_code=201 to /join endpoint in both coordinator APIs
- Add status_code=202 to /coordinate endpoint in both coordinator APIs
This commit is contained in:
aitbc
2026-05-08 12:39:45 +02:00
parent 094fa268fc
commit f8d8d41807
2 changed files with 4 additions and 4 deletions

View File

@@ -57,7 +57,7 @@ async def list_swarms(
return []
@router.post("/join", response_model=dict)
@router.post("/join", response_model=dict, status_code=201)
async def join_swarm(request: JoinRequest):
"""Join agent swarm for collective optimization."""
import uuid
@@ -71,7 +71,7 @@ async def join_swarm(request: JoinRequest):
}
@router.post("/coordinate", response_model=dict)
@router.post("/coordinate", response_model=dict, status_code=202)
async def coordinate_swarm(request: CoordinateRequest):
"""Coordinate swarm task execution."""
import uuid

View File

@@ -57,7 +57,7 @@ async def list_swarms(
return []
@router.post("/join", response_model=dict)
@router.post("/join", response_model=dict, status_code=201)
async def join_swarm(request: JoinRequest):
"""Join agent swarm for collective optimization."""
import uuid
@@ -71,7 +71,7 @@ async def join_swarm(request: JoinRequest):
}
@router.post("/coordinate", response_model=dict)
@router.post("/coordinate", response_model=dict, status_code=202)
async def coordinate_swarm(request: CoordinateRequest):
"""Coordinate swarm task execution."""
import uuid