@mikle7/litty-api-client
Version:
TypeScript client for Litty API with clean, semantic type definitions
64 lines (63 loc) • 4.96 kB
JavaScript
;
/* tslint:disable */
/* eslint-disable */
/**
* Litty API
* Complete API documentation for the Litty platform. ## Authentication Most endpoints require authentication via Supabase JWT tokens. Include the token in the Authorization header: `Bearer <token>` ## API Structure - **Contests**: Create and manage contests, entries, and settlements - **Markets**: Manage prediction markets within contests - **Transactions**: Handle financial transactions for contest entries and rewards - **Wallet**: Manage user wallet balances (cashable, points, tickets) - **Users**: User management and profiles - **Leaderboards**: Competition rankings and scoring - **Uploads**: File upload management - **Shows**: TV show and episode management (admin only) ## Response Formats All endpoints return JSON responses with consistent error handling. Error responses include `statusCode`, `message`, and `error` fields.
*
* The version of the OpenAPI document: 1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
Object.defineProperty(exports, "__esModule", { value: true });
exports.GetContestEntries200ResponseTeamsInnerPredictionsInnerToJSONTyped = exports.GetContestEntries200ResponseTeamsInnerPredictionsInnerToJSON = exports.GetContestEntries200ResponseTeamsInnerPredictionsInnerFromJSONTyped = exports.GetContestEntries200ResponseTeamsInnerPredictionsInnerFromJSON = exports.instanceOfGetContestEntries200ResponseTeamsInnerPredictionsInner = void 0;
const GetContestById200ResponseUserPredictionsInnerMarket_1 = require("./GetContestById200ResponseUserPredictionsInnerMarket");
const GetContestById200ResponseUserPredictionsInnerMarketOption_1 = require("./GetContestById200ResponseUserPredictionsInnerMarketOption");
/**
* Check if a given object implements the GetContestEntries200ResponseTeamsInnerPredictionsInner interface.
*/
function instanceOfGetContestEntries200ResponseTeamsInnerPredictionsInner(value) {
return true;
}
exports.instanceOfGetContestEntries200ResponseTeamsInnerPredictionsInner = instanceOfGetContestEntries200ResponseTeamsInnerPredictionsInner;
function GetContestEntries200ResponseTeamsInnerPredictionsInnerFromJSON(json) {
return GetContestEntries200ResponseTeamsInnerPredictionsInnerFromJSONTyped(json, false);
}
exports.GetContestEntries200ResponseTeamsInnerPredictionsInnerFromJSON = GetContestEntries200ResponseTeamsInnerPredictionsInnerFromJSON;
function GetContestEntries200ResponseTeamsInnerPredictionsInnerFromJSONTyped(json, ignoreDiscriminator) {
if (json == null) {
return json;
}
return {
'id': json['id'] == null ? undefined : json['id'],
'marketOptionId': json['marketOptionId'] == null ? undefined : json['marketOptionId'],
'marketId': json['marketId'] == null ? undefined : json['marketId'],
'teamId': json['teamId'] == null ? undefined : json['teamId'],
'createdAt': json['createdAt'] == null ? undefined : (new Date(json['createdAt'])),
'marketOption': json['marketOption'] == null ? undefined : (0, GetContestById200ResponseUserPredictionsInnerMarketOption_1.GetContestById200ResponseUserPredictionsInnerMarketOptionFromJSON)(json['marketOption']),
'market': json['market'] == null ? undefined : (0, GetContestById200ResponseUserPredictionsInnerMarket_1.GetContestById200ResponseUserPredictionsInnerMarketFromJSON)(json['market']),
};
}
exports.GetContestEntries200ResponseTeamsInnerPredictionsInnerFromJSONTyped = GetContestEntries200ResponseTeamsInnerPredictionsInnerFromJSONTyped;
function GetContestEntries200ResponseTeamsInnerPredictionsInnerToJSON(json) {
return GetContestEntries200ResponseTeamsInnerPredictionsInnerToJSONTyped(json, false);
}
exports.GetContestEntries200ResponseTeamsInnerPredictionsInnerToJSON = GetContestEntries200ResponseTeamsInnerPredictionsInnerToJSON;
function GetContestEntries200ResponseTeamsInnerPredictionsInnerToJSONTyped(value, ignoreDiscriminator = false) {
if (value == null) {
return value;
}
return {
'id': value['id'],
'marketOptionId': value['marketOptionId'],
'marketId': value['marketId'],
'teamId': value['teamId'],
'createdAt': value['createdAt'] == null ? undefined : ((value['createdAt']).toISOString()),
'marketOption': (0, GetContestById200ResponseUserPredictionsInnerMarketOption_1.GetContestById200ResponseUserPredictionsInnerMarketOptionToJSON)(value['marketOption']),
'market': (0, GetContestById200ResponseUserPredictionsInnerMarket_1.GetContestById200ResponseUserPredictionsInnerMarketToJSON)(value['market']),
};
}
exports.GetContestEntries200ResponseTeamsInnerPredictionsInnerToJSONTyped = GetContestEntries200ResponseTeamsInnerPredictionsInnerToJSONTyped;