/* tslint:disable */
/* eslint-disable */
/**
 * Stacks 2.0 Blockchain API
 * This is the documentation for the Stacks 2.0 Blockchain API.  It is comprised of two parts; the Stacks Blockchain API and the Stacks Core API.  [![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/614feab5c108d292bffa#?env%5BStacks%20Blockchain%20API%5D=W3sia2V5Ijoic3R4X2FkZHJlc3MiLCJ2YWx1ZSI6IlNUMlRKUkhESE1ZQlE0MTdIRkIwQkRYNDMwVFFBNVBYUlg2NDk1RzFWIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJibG9ja19pZCIsInZhbHVlIjoiMHgiLCJlbmFibGVkIjp0cnVlfSx7ImtleSI6Im9mZnNldCIsInZhbHVlIjoiMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfdHgiLCJ2YWx1ZSI6IjIwMCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoibGltaXRfYmxvY2siLCJ2YWx1ZSI6IjMwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJ0eF9pZCIsInZhbHVlIjoiMHg1NDA5MGMxNmE3MDJiNzUzYjQzMTE0ZTg4NGJjMTlhODBhNzk2MzhmZDQ0OWE0MGY4MDY4Y2RmMDAzY2RlNmUwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9pZCIsInZhbHVlIjoiU1RKVFhFSlBKUFBWRE5BOUIwNTJOU1JSQkdRQ0ZOS1ZTMTc4VkdIMS5oZWxsb193b3JsZFxuIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJidGNfYWRkcmVzcyIsInZhbHVlIjoiYWJjIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9hZGRyZXNzIiwidmFsdWUiOiJTVEpUWEVKUEpQUFZETkE5QjA1Mk5TUlJCR1FDRk5LVlMxNzhWR0gxIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJjb250cmFjdF9uYW1lIiwidmFsdWUiOiJoZWxsb193b3JsZCIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWFwIiwidmFsdWUiOiJzdG9yZSIsImVuYWJsZWQiOnRydWV9LHsia2V5IjoiY29udHJhY3RfbWV0aG9kIiwidmFsdWUiOiJnZXQtdmFsdWUiLCJlbmFibGVkIjp0cnVlfV0=) 
 *
 * The version of the OpenAPI document: 1.0.0
 * 
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */

import { exists, mapValues } from '../runtime';
/**
 * The options that will be sent directly to /construction/metadata by the caller.
 * @export
 * @interface RosettaOptions
 */
export interface RosettaOptions {
    /**
     * sender's address 
     * @type {string}
     * @memberof RosettaOptions
     */
    sender_address?: string;
    /**
     * Type of operation e.g transfer
     * @type {string}
     * @memberof RosettaOptions
     */
    type?: string;
    /**
     * This value indicates the state of the operations
     * @type {string}
     * @memberof RosettaOptions
     */
    status?: string;
    /**
     * Recipient's address
     * @type {string}
     * @memberof RosettaOptions
     */
    token_transfer_recipient_address?: string;
    /**
     * Amount to be transfeered.
     * @type {string}
     * @memberof RosettaOptions
     */
    amount?: string;
    /**
     * Currency symbol e.g STX
     * @type {string}
     * @memberof RosettaOptions
     */
    symbol?: string;
    /**
     * Number of decimal places
     * @type {number}
     * @memberof RosettaOptions
     */
    decimals?: number;
    /**
     * Maximum price a user is willing to pay.
     * @type {number}
     * @memberof RosettaOptions
     */
    gas_limit?: number;
    /**
     * Cost necessary to perform a transaction on the network
     * @type {number}
     * @memberof RosettaOptions
     */
    gas_price?: number;
    /**
     *  A suggested fee multiplier to indicate that the suggested fee should be scaled. This may be used to set higher fees for urgent transactions or to pay lower fees when there is less urgency.
     * @type {number}
     * @memberof RosettaOptions
     */
    suggested_fee_multiplier?: number;
    /**
     * Maximum fee user is willing to pay
     * @type {string}
     * @memberof RosettaOptions
     */
    max_fee?: string;
    /**
     * Fee for this transaction
     * @type {string}
     * @memberof RosettaOptions
     */
    fee?: string;
}

export function RosettaOptionsFromJSON(json: any): RosettaOptions {
    return RosettaOptionsFromJSONTyped(json, false);
}

export function RosettaOptionsFromJSONTyped(json: any, ignoreDiscriminator: boolean): RosettaOptions {
    if ((json === undefined) || (json === null)) {
        return json;
    }
    return {
        
        'sender_address': !exists(json, 'sender_address') ? undefined : json['sender_address'],
        'type': !exists(json, 'type') ? undefined : json['type'],
        'status': !exists(json, 'status') ? undefined : json['status'],
        'token_transfer_recipient_address': !exists(json, 'token_transfer_recipient_address') ? undefined : json['token_transfer_recipient_address'],
        'amount': !exists(json, 'amount') ? undefined : json['amount'],
        'symbol': !exists(json, 'symbol') ? undefined : json['symbol'],
        'decimals': !exists(json, 'decimals') ? undefined : json['decimals'],
        'gas_limit': !exists(json, 'gas_limit') ? undefined : json['gas_limit'],
        'gas_price': !exists(json, 'gas_price') ? undefined : json['gas_price'],
        'suggested_fee_multiplier': !exists(json, 'suggested_fee_multiplier') ? undefined : json['suggested_fee_multiplier'],
        'max_fee': !exists(json, 'max_fee') ? undefined : json['max_fee'],
        'fee': !exists(json, 'fee') ? undefined : json['fee'],
    };
}

export function RosettaOptionsToJSON(value?: RosettaOptions | null): any {
    if (value === undefined) {
        return undefined;
    }
    if (value === null) {
        return null;
    }
    return {
        
        'sender_address': value.sender_address,
        'type': value.type,
        'status': value.status,
        'token_transfer_recipient_address': value.token_transfer_recipient_address,
        'amount': value.amount,
        'symbol': value.symbol,
        'decimals': value.decimals,
        'gas_limit': value.gas_limit,
        'gas_price': value.gas_price,
        'suggested_fee_multiplier': value.suggested_fee_multiplier,
        'max_fee': value.max_fee,
        'fee': value.fee,
    };
}


