@mikle7/litty-api-client
Version:
TypeScript client for Litty API with clean, semantic type definitions
68 lines (67 loc) • 3.93 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.CompleteSession200ResponseToJSONTyped = exports.CompleteSession200ResponseToJSON = exports.CompleteSession200ResponseFromJSONTyped = exports.CompleteSession200ResponseFromJSON = exports.instanceOfCompleteSession200Response = exports.CompleteSession200ResponseContestTypeEnum = void 0;
const CompleteSession200ResponsePerformance_1 = require("./CompleteSession200ResponsePerformance");
/**
* @export
*/
exports.CompleteSession200ResponseContestTypeEnum = {
PickPack: 'PickPack',
Traditional: 'Traditional'
};
/**
* Check if a given object implements the CompleteSession200Response interface.
*/
function instanceOfCompleteSession200Response(value) {
return true;
}
exports.instanceOfCompleteSession200Response = instanceOfCompleteSession200Response;
function CompleteSession200ResponseFromJSON(json) {
return CompleteSession200ResponseFromJSONTyped(json, false);
}
exports.CompleteSession200ResponseFromJSON = CompleteSession200ResponseFromJSON;
function CompleteSession200ResponseFromJSONTyped(json, ignoreDiscriminator) {
if (json == null) {
return json;
}
return {
'message': json['message'] == null ? undefined : json['message'],
'contestType': json['contestType'] == null ? undefined : json['contestType'],
'sessionId': json['sessionId'] == null ? undefined : json['sessionId'],
'performance': json['performance'] == null ? undefined : (0, CompleteSession200ResponsePerformance_1.CompleteSession200ResponsePerformanceFromJSON)(json['performance']),
'completedAt': json['completedAt'] == null ? undefined : (new Date(json['completedAt'])),
'note': json['note'] == null ? undefined : json['note'],
};
}
exports.CompleteSession200ResponseFromJSONTyped = CompleteSession200ResponseFromJSONTyped;
function CompleteSession200ResponseToJSON(json) {
return CompleteSession200ResponseToJSONTyped(json, false);
}
exports.CompleteSession200ResponseToJSON = CompleteSession200ResponseToJSON;
function CompleteSession200ResponseToJSONTyped(value, ignoreDiscriminator = false) {
if (value == null) {
return value;
}
return {
'message': value['message'],
'contestType': value['contestType'],
'sessionId': value['sessionId'],
'performance': (0, CompleteSession200ResponsePerformance_1.CompleteSession200ResponsePerformanceToJSON)(value['performance']),
'completedAt': value['completedAt'] == null ? undefined : ((value['completedAt']).toISOString()),
'note': value['note'],
};
}
exports.CompleteSession200ResponseToJSONTyped = CompleteSession200ResponseToJSONTyped;