/* tslint:disable */ /* eslint-disable */ /** * barkd REST API * A simple REST API for barkd, a wallet daemon for integrating bitcoin payments into your app over HTTP. Supports self-custodial Lightning, Ark, and on-chain out of the box. barkd is a long-running daemon best suited for always-on or high-connectivity environments like nodes, servers, desktops, and point-of-sale terminals. All endpoints return JSON. Amounts are denominated in satoshis. * * The version of the OpenAPI document: 0.6.1 * Contact: hello@second.tech * * 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'; /** * Contains the data required to bump the fee for a given transaction (including ancestors). * @export * @interface FeeInfo */ export interface FeeInfo { /** * The effective fee rate of the transaction (including unconfirmed CPFP ancestors), in * sats per kvB. `kvb` matches the unit used elsewhere in `bark-json` * (e.g. `offboard_feerate_sat_per_kvb`). * @type {number} * @memberof FeeInfo */ feeRateSatPerKvb: number; /** * Sum of the transaction's own fee plus the fee of each of its unconfirmed ancestors. * @type {number} * @memberof FeeInfo */ totalFeeSat: number; } /** * Check if a given object implements the FeeInfo interface. */ export function instanceOfFeeInfo(value: object): value is FeeInfo { if (!('feeRateSatPerKvb' in value) || value['feeRateSatPerKvb'] === undefined) return false; if (!('totalFeeSat' in value) || value['totalFeeSat'] === undefined) return false; return true; } export function FeeInfoFromJSON(json: any): FeeInfo { return FeeInfoFromJSONTyped(json, false); } export function FeeInfoFromJSONTyped(json: any, ignoreDiscriminator: boolean): FeeInfo { if (json == null) { return json; } return { 'feeRateSatPerKvb': json['fee_rate_sat_per_kvb'], 'totalFeeSat': json['total_fee_sat'], }; } export function FeeInfoToJSON(json: any): FeeInfo { return FeeInfoToJSONTyped(json, false); } export function FeeInfoToJSONTyped(value?: FeeInfo | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'fee_rate_sat_per_kvb': value['feeRateSatPerKvb'], 'total_fee_sat': value['totalFeeSat'], }; }