/* tslint:disable */ /* eslint-disable */ /** * * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import { mapValues } from '../runtime'; /** * * @export * @interface Asset */ export interface Asset { /** * * @type {number} * @memberof Asset */ asset_id: number; /** * * @type {string} * @memberof Asset */ symbol: string; /** * * @type {number} * @memberof Asset */ l1_decimals: number; /** * * @type {number} * @memberof Asset */ decimals: number; /** * * @type {string} * @memberof Asset */ min_transfer_amount: string; /** * * @type {string} * @memberof Asset */ min_withdrawal_amount: string; /** * * @type {string} * @memberof Asset */ margin_mode: AssetMarginModeEnum; /** * * @type {string} * @memberof Asset */ index_price: string; /** * * @type {string} * @memberof Asset */ l1_address: string; } /** * @export */ export const AssetMarginModeEnum = { Enabled: 'enabled', Disabled: 'disabled' } as const; export type AssetMarginModeEnum = typeof AssetMarginModeEnum[keyof typeof AssetMarginModeEnum]; /** * Check if a given object implements the Asset interface. */ export function instanceOfAsset(value: object): value is Asset { if (!('asset_id' in value) || value['asset_id'] === undefined) return false; if (!('symbol' in value) || value['symbol'] === undefined) return false; if (!('l1_decimals' in value) || value['l1_decimals'] === undefined) return false; if (!('decimals' in value) || value['decimals'] === undefined) return false; if (!('min_transfer_amount' in value) || value['min_transfer_amount'] === undefined) return false; if (!('min_withdrawal_amount' in value) || value['min_withdrawal_amount'] === undefined) return false; if (!('margin_mode' in value) || value['margin_mode'] === undefined) return false; if (!('index_price' in value) || value['index_price'] === undefined) return false; if (!('l1_address' in value) || value['l1_address'] === undefined) return false; return true; } export function AssetFromJSON(json: any): Asset { return AssetFromJSONTyped(json, false); } export function AssetFromJSONTyped(json: any, ignoreDiscriminator: boolean): Asset { if (json == null) { return json; } return { 'asset_id': json['asset_id'], 'symbol': json['symbol'], 'l1_decimals': json['l1_decimals'], 'decimals': json['decimals'], 'min_transfer_amount': json['min_transfer_amount'], 'min_withdrawal_amount': json['min_withdrawal_amount'], 'margin_mode': json['margin_mode'], 'index_price': json['index_price'], 'l1_address': json['l1_address'], }; } export function AssetToJSON(value?: Asset | null): any { if (value == null) { return value; } return { 'asset_id': value['asset_id'], 'symbol': value['symbol'], 'l1_decimals': value['l1_decimals'], 'decimals': value['decimals'], 'min_transfer_amount': value['min_transfer_amount'], 'min_withdrawal_amount': value['min_withdrawal_amount'], 'margin_mode': value['margin_mode'], 'index_price': value['index_price'], 'l1_address': value['l1_address'], }; }