PlaceBetRequest
Request model for placing bets
Properties
| Property | Type | Required | Description |
|---|---|---|---|
opportunityId | string | β Yes | - |
outcome | string | β Yes | - |
amount | number | β Yes | - |
userId | string | β Yes | - |
Example
{
"opportunityId": "example",
"outcome": "example",
"amount": 0,
"userId": "example"
}Used In
Code Examples
TypeScript
interface PlaceBetRequest {
opportunityId: string;
outcome: string;
amount: number;
userId: string;
}
// Usage example
const data: PlaceBetRequest = {
"opportunityId": "example",
"outcome": "example",
"amount": 0,
"userId": "example"
};Python
from data_layer.schemas import PlaceBetRequest
# Create instance
data = PlaceBetRequest(
# Add your field values here
)cURL
curl -X POST "https://altsportsleagues-backend-2qcdjegnaa-uc.a.run.app/api/endpoint" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{ "opportunityId": "example", "outcome": "example", "amount": 0, "userId": "example" }'Validation Rules
Required Fields: opportunityId, outcome, amount, userId
Additional Information
- Type: object
- Source: Generated from Pydantic models in
data_layer/schemas/ - Auto-validated: All fields are validated by FastAPI
This documentation is auto-generated from the OpenAPI specification.