trainingpeaks-sdk
Version:
TypeScript SDK for TrainingPeaks API integration
118 lines (117 loc) • 5.19 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.WorkoutType = exports.SimpleWorkoutElementType = exports.LoginMethod = exports.SortOption = exports.WorkoutTypeInternal = exports.OperationType = exports.ErrorType = exports.AuthMethod = exports.ActivityType = exports.Difficulty = exports.IntensityClass = exports.IntensityTargetType = exports.IntensityMetric = exports.LengthMetric = exports.LengthUnit = exports.ElementType = void 0;
var ElementType;
(function (ElementType) {
ElementType["STEP"] = "step";
ElementType["REPETITION"] = "repetition";
})(ElementType || (exports.ElementType = ElementType = {}));
var LengthUnit;
(function (LengthUnit) {
LengthUnit["SECOND"] = "second";
LengthUnit["MINUTE"] = "minute";
LengthUnit["HOUR"] = "hour";
LengthUnit["REPETITION"] = "repetition";
LengthUnit["METER"] = "meter";
LengthUnit["KILOMETER"] = "kilometer";
LengthUnit["MILE"] = "mile";
})(LengthUnit || (exports.LengthUnit = LengthUnit = {}));
var LengthMetric;
(function (LengthMetric) {
LengthMetric["DURATION"] = "duration";
LengthMetric["DISTANCE"] = "distance";
})(LengthMetric || (exports.LengthMetric = LengthMetric = {}));
var IntensityMetric;
(function (IntensityMetric) {
IntensityMetric["PERCENT_OF_THRESHOLD_PACE"] = "percentOfThresholdPace";
IntensityMetric["PERCENT_OF_THRESHOLD_POWER"] = "percentOfThresholdPower";
IntensityMetric["HEART_RATE"] = "heartRate";
IntensityMetric["POWER"] = "power";
IntensityMetric["PACE"] = "pace";
IntensityMetric["SPEED"] = "speed";
})(IntensityMetric || (exports.IntensityMetric = IntensityMetric = {}));
var IntensityTargetType;
(function (IntensityTargetType) {
IntensityTargetType["TARGET"] = "target";
IntensityTargetType["RANGE"] = "range";
})(IntensityTargetType || (exports.IntensityTargetType = IntensityTargetType = {}));
var IntensityClass;
(function (IntensityClass) {
IntensityClass["ACTIVE"] = "active";
IntensityClass["REST"] = "rest";
IntensityClass["WARM_UP"] = "warmUp";
IntensityClass["COOL_DOWN"] = "coolDown";
})(IntensityClass || (exports.IntensityClass = IntensityClass = {}));
var Difficulty;
(function (Difficulty) {
Difficulty["EASY"] = "easy";
Difficulty["MODERATE"] = "moderate";
Difficulty["HARD"] = "hard";
Difficulty["EXTREME"] = "extreme";
})(Difficulty || (exports.Difficulty = Difficulty = {}));
var ActivityType;
(function (ActivityType) {
ActivityType["RUN"] = "run";
ActivityType["BIKE"] = "bike";
ActivityType["SWIM"] = "swim";
ActivityType["STRENGTH"] = "strength";
ActivityType["OTHER"] = "other";
})(ActivityType || (exports.ActivityType = ActivityType = {}));
var AuthMethod;
(function (AuthMethod) {
AuthMethod["WEB"] = "web";
AuthMethod["API"] = "api";
})(AuthMethod || (exports.AuthMethod = AuthMethod = {}));
var ErrorType;
(function (ErrorType) {
ErrorType["VALIDATION_ERROR"] = "VALIDATION_ERROR";
ErrorType["AUTHENTICATION_ERROR"] = "AUTHENTICATION_ERROR";
ErrorType["AUTHORIZATION_ERROR"] = "AUTHORIZATION_ERROR";
ErrorType["NETWORK_ERROR"] = "NETWORK_ERROR";
ErrorType["UPLOAD_ERROR"] = "UPLOAD_ERROR";
ErrorType["RATE_LIMIT_ERROR"] = "RATE_LIMIT_ERROR";
ErrorType["ERROR"] = "ERROR";
})(ErrorType || (exports.ErrorType = ErrorType = {}));
var OperationType;
(function (OperationType) {
OperationType["LOGIN"] = "login";
OperationType["LOGOUT"] = "logout";
OperationType["GET_CURRENT_USER"] = "getCurrentUser";
OperationType["GET_CURRENT_TOKEN"] = "getCurrentToken";
OperationType["GET_USER_ID"] = "getUserId";
})(OperationType || (exports.OperationType = OperationType = {}));
var WorkoutTypeInternal;
(function (WorkoutTypeInternal) {
WorkoutTypeInternal["STRUCTURED"] = "structured";
WorkoutTypeInternal["FILE"] = "file";
WorkoutTypeInternal["MANUAL"] = "manual";
WorkoutTypeInternal["FILE_BASED"] = "file-based";
WorkoutTypeInternal["SIMPLE"] = "simple";
})(WorkoutTypeInternal || (exports.WorkoutTypeInternal = WorkoutTypeInternal = {}));
var SortOption;
(function (SortOption) {
SortOption["DATE"] = "date";
SortOption["NAME"] = "name";
SortOption["DURATION"] = "duration";
SortOption["DISTANCE"] = "distance";
})(SortOption || (exports.SortOption = SortOption = {}));
var LoginMethod;
(function (LoginMethod) {
LoginMethod["WEB"] = "web";
LoginMethod["CREDENTIALS"] = "credentials";
})(LoginMethod || (exports.LoginMethod = LoginMethod = {}));
var SimpleWorkoutElementType;
(function (SimpleWorkoutElementType) {
SimpleWorkoutElementType["WARMUP"] = "warmup";
SimpleWorkoutElementType["INTERVAL"] = "interval";
SimpleWorkoutElementType["RECOVERY"] = "recovery";
SimpleWorkoutElementType["COOLDOWN"] = "cooldown";
SimpleWorkoutElementType["STEADY"] = "steady";
})(SimpleWorkoutElementType || (exports.SimpleWorkoutElementType = SimpleWorkoutElementType = {}));
var WorkoutType;
(function (WorkoutType) {
WorkoutType["BIKE"] = "BIKE";
WorkoutType["RUN"] = "RUN";
WorkoutType["SWIM"] = "SWIM";
WorkoutType["OTHER"] = "OTHER";
})(WorkoutType || (exports.WorkoutType = WorkoutType = {}));