UNPKG

@volare.finance/schemas.js

Version:
137 lines 7.16 kB
"use strict"; var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) { var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d; if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc); else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; return c > 3 && r && Object.defineProperty(target, key, r), r; }; var __metadata = (this && this.__metadata) || function (k, v) { if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v); }; Object.defineProperty(exports, "__esModule", { value: true }); exports.VolareVaultSchema = exports.VolareVault = void 0; const mongoose_1 = require("@nestjs/mongoose"); const swagger_1 = require("@nestjs/swagger"); let VolareVault = class VolareVault { }; exports.VolareVault = VolareVault; __decorate([ (0, swagger_1.ApiProperty)({ description: 'The owner address.', example: '0xd894cf83f2f8d1d795b4c0ddc7f86e2baedef3b1' }), (0, mongoose_1.Prop)({ index: true }), __metadata("design:type", String) ], VolareVault.prototype, "owner", void 0); __decorate([ (0, swagger_1.ApiProperty)({ description: 'The vault ID.', example: 1 }), (0, mongoose_1.Prop)({ index: true }), __metadata("design:type", Number) ], VolareVault.prototype, "vaultId", void 0); __decorate([ (0, swagger_1.ApiProperty)({ description: 'The vault type.', example: '0x00' }), (0, mongoose_1.Prop)({ index: true }), __metadata("design:type", String) ], VolareVault.prototype, "vaultType", void 0); __decorate([ (0, swagger_1.ApiProperty)({ description: 'The strategy type.', example: 'Call Straddle' }), (0, mongoose_1.Prop)({ index: true }), __metadata("design:type", String) ], VolareVault.prototype, "strategyType", void 0); __decorate([ (0, swagger_1.ApiProperty)({ description: 'The short vTokens array.', example: ['0x495d33cf1bd948158bce0ac2393e09b213f3abe7'] }), (0, mongoose_1.Prop)(), __metadata("design:type", Array) ], VolareVault.prototype, "shortVTokens", void 0); __decorate([ (0, swagger_1.ApiProperty)({ type: [Number], description: 'The short amounts array.', example: [5] }), (0, mongoose_1.Prop)(), __metadata("design:type", Array) ], VolareVault.prototype, "shortAmounts", void 0); __decorate([ (0, swagger_1.ApiPropertyOptional)({ type: [Number], description: 'The short payouts array (denominated in collateral asset).', example: [1.875] }), (0, mongoose_1.Prop)(), __metadata("design:type", Array) ], VolareVault.prototype, "shortPayouts", void 0); __decorate([ (0, swagger_1.ApiProperty)({ description: 'The long vTokens array.', example: ['0xd10f9281a5f00db4b8d8e62f358b322226838ae3'] }), (0, mongoose_1.Prop)(), __metadata("design:type", Array) ], VolareVault.prototype, "longVTokens", void 0); __decorate([ (0, swagger_1.ApiProperty)({ type: [Number], description: 'The long amounts array.', example: [4] }), (0, mongoose_1.Prop)(), __metadata("design:type", Array) ], VolareVault.prototype, "longAmounts", void 0); __decorate([ (0, swagger_1.ApiPropertyOptional)({ type: [Number], description: 'The long payouts array (denominated in collateral asset).', example: [0] }), (0, mongoose_1.Prop)(), __metadata("design:type", Array) ], VolareVault.prototype, "longPayouts", void 0); __decorate([ (0, swagger_1.ApiPropertyOptional)({ type: [Number], description: 'The long states.', example: [0] }), (0, mongoose_1.Prop)(), __metadata("design:type", Array) ], VolareVault.prototype, "longStates", void 0); __decorate([ (0, swagger_1.ApiProperty)({ description: 'The collateral assets array.', example: ['0xe44a09787c1576b97fbe1da811090a51eddca04f'] }), (0, mongoose_1.Prop)(), __metadata("design:type", Array) ], VolareVault.prototype, "collateralAssets", void 0); __decorate([ (0, swagger_1.ApiProperty)({ type: [Number], description: 'The collateral amounts array.', example: [5] }), (0, mongoose_1.Prop)(), __metadata("design:type", Array) ], VolareVault.prototype, "collateralAmounts", void 0); __decorate([ (0, swagger_1.ApiPropertyOptional)({ type: [Number], description: 'The margin required array (denominated in collateral asset).', example: [1.875] }), (0, mongoose_1.Prop)(), __metadata("design:type", Array) ], VolareVault.prototype, "marginRequired", void 0); __decorate([ (0, swagger_1.ApiPropertyOptional)({ type: [Number], description: 'The payout array (denominated in collateral asset).', example: [3.125] }), (0, mongoose_1.Prop)(), __metadata("design:type", Array) ], VolareVault.prototype, "payoutAmounts", void 0); __decorate([ (0, swagger_1.ApiProperty)({ description: 'Return on equity (n per thousand).', example: -375 }), (0, mongoose_1.Prop)(), __metadata("design:type", Number) ], VolareVault.prototype, "roe", void 0); __decorate([ (0, swagger_1.ApiPropertyOptional)({ description: 'The fee at which the payout is withdrawn (denominated in collateral asset).', example: 0.003125 }), (0, mongoose_1.Prop)(), __metadata("design:type", Number) ], VolareVault.prototype, "fee", void 0); __decorate([ (0, swagger_1.ApiProperty)({ description: 'The vault state.', example: 1 }), (0, mongoose_1.Prop)({ index: true }), __metadata("design:type", Number) ], VolareVault.prototype, "state", void 0); __decorate([ (0, swagger_1.ApiPropertyOptional)({ description: 'The underlying symbol.', example: 'WETH' }), (0, mongoose_1.Prop)({ index: true }), __metadata("design:type", String) ], VolareVault.prototype, "underlyingSymbol", void 0); __decorate([ (0, swagger_1.ApiPropertyOptional)({ description: 'The vault is put when true, or the vault is call when false.', example: false }), (0, mongoose_1.Prop)({ index: true }), __metadata("design:type", Boolean) ], VolareVault.prototype, "isPut", void 0); __decorate([ (0, swagger_1.ApiPropertyOptional)({ description: 'The price at which the option can be liquidated (denominated in strike asset).', example: 1800 }), (0, mongoose_1.Prop)({ index: true }), __metadata("design:type", Number) ], VolareVault.prototype, "liquidatablePrice", void 0); __decorate([ (0, swagger_1.ApiProperty)({ description: 'The first timestamp at which buy longs.', example: 1655289127 }), (0, mongoose_1.Prop)({ index: true }), __metadata("design:type", Number) ], VolareVault.prototype, "ctime", void 0); __decorate([ (0, swagger_1.ApiProperty)({ description: 'The timestamp when the vault changed.', example: 1655289127 }), (0, mongoose_1.Prop)({ index: true }), __metadata("design:type", Number) ], VolareVault.prototype, "mtime", void 0); exports.VolareVault = VolareVault = __decorate([ (0, mongoose_1.Schema)({ collection: 'volare_vault' }) ], VolareVault); exports.VolareVaultSchema = mongoose_1.SchemaFactory.createForClass(VolareVault); //# sourceMappingURL=volare.vault.js.map