// @generated by protoc-gen-es v2.2.2 with parameter "target=ts,import_extension=.js"
// @generated from file gfxcafe/oku/account/v1/orders.proto (package gfxcafe.oku.account.v1, syntax proto3)
/* eslint-disable */

import type { GenFile, GenMessage, GenService } from "@bufbuild/protobuf/codegenv1";
import { fileDesc, messageDesc, serviceDesc } from "@bufbuild/protobuf/codegenv1";
import { file_buf_validate_validate } from "../../../../buf/validate/validate_pb.js";
import { file_google_protobuf_struct } from "@bufbuild/protobuf/wkt";
import type { Address } from "./common_pb.js";
import { file_gfxcafe_oku_account_v1_common } from "./common_pb.js";
import type { JsonObject, Message } from "@bufbuild/protobuf";

/**
 * Describes the file gfxcafe/oku/account/v1/orders.proto.
 */
export const file_gfxcafe_oku_account_v1_orders: GenFile = /*@__PURE__*/
  fileDesc("CiNnZnhjYWZlL29rdS9hY2NvdW50L3YxL29yZGVycy5wcm90bxIWZ2Z4Y2FmZS5va3UuYWNjb3VudC52MSJoChpDYW5vZU1hcmtldE1hcmtldElkUmVxdWVzdBIZCgltYXJrZXRfaWQYASABKAlCBrpIA8gBARIvCgZwYXJhbXMYAiABKAsyFy5nb29nbGUucHJvdG9idWYuU3RydWN0Qga6SAPIAQEiqQIKG0Nhbm9lTWFya2V0TWFya2V0SWRSZXNwb25zZRI6CglhcHByb3ZhbHMYASADKAsyJy5nZnhjYWZlLm9rdS5hY2NvdW50LnYxLkFwcHJvdmFsUGF5bG9hZBJACgx0cmFuc2FjdGlvbnMYAiADKAsyKi5nZnhjYWZlLm9rdS5hY2NvdW50LnYxLlRyYW5zYWN0aW9uUGF5bG9hZBI5CgV0cmFkZRgDIAEoCzIqLmdmeGNhZmUub2t1LmFjY291bnQudjEuVHJhbnNhY3Rpb25QYXlsb2FkEikKCGFuYWx5c2lzGAQgASgLMhcuZ29vZ2xlLnByb3RvYnVmLlN0cnVjdBImCgVleHRyYRgFIAEoCzIXLmdvb2dsZS5wcm90b2J1Zi5TdHJ1Y3QicwofQ2Fub2VRdW90ZU1hcmtldE1hcmt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LkNhbm9lTWFya2V0TWFya2V0SWRSZXF1ZXN0GjMuZ2Z4Y2FmZS5va3UuYWNjb3VudC52MS5DYW5vZU1hcmtldE1hcmtldElkUmVzcG9uc2USjQEKGENhbm9lUXVvdGVNYXJrZXRNYXJrZXRJZBI3LmdmeGNhZmUub2t1LmFjY291bnQudjEuQ2Fub2VRdW90ZU1hcmtldE1hcmtldElkUmVxdWVzdBo4LmdmeGNhZmUub2t1LmFjY291bnQudjEuQ2Fub2VRdW90ZU1hcmtldE1hcmtldElkUmVzcG9uc2VCN1o1Z2Z4LmNhZmUvb2t1L2FjY291bnQvZ2VuL2dvL2dmeGNhZmUvb2t1L2FjY291bnQvdjE7djFiBnByb3RvMw", [file_buf_validate_validate, file_google_protobuf_struct, file_gfxcafe_oku_account_v1_common]);

/**
 * CanoeMarketMarketIdRequest for generating execution information
 *
 * @generated from message gfxcafe.oku.account.v1.CanoeMarketMarketIdRequest
 */
export type CanoeMarketMarketIdRequest = Message<"gfxcafe.oku.account.v1.CanoeMarketMarketIdRequest"> & {
  /**
   * Market ID (e.g., "airswap", "enso", "kyberswap")
   *
   * @generated from field: string market_id = 1;
   */
  marketId: string;

  /**
   * Request parameters as JSON
   *
   * @generated from field: google.protobuf.Struct params = 2;
   */
  params?: JsonObject;
};

/**
 * Describes the message gfxcafe.oku.account.v1.CanoeMarketMarketIdRequest.
 * Use `create(CanoeMarketMarketIdRequestSchema)` to create a new message.
 */
export const CanoeMarketMarketIdRequestSchema: GenMessage<CanoeMarketMarketIdRequest> = /*@__PURE__*/
  messageDesc(file_gfxcafe_oku_account_v1_orders, 0);

/**
 * CanoeMarketMarketIdResponse with execution information
 *
 * @generated from message gfxcafe.oku.account.v1.CanoeMarketMarketIdResponse
 */
export type CanoeMarketMarketIdResponse = Message<"gfxcafe.oku.account.v1.CanoeMarketMarketIdResponse"> & {
  /**
   * Approval payloads
   *
   * @generated from field: repeated gfxcafe.oku.account.v1.ApprovalPayload approvals = 1;
   */
  approvals: ApprovalPayload[];

  /**
   * Transaction payloads
   *
   * @generated from field: repeated gfxcafe.oku.account.v1.TransactionPayload transactions = 2;
   */
  transactions: TransactionPayload[];

  /**
   * Trade transaction
   *
   * @generated from field: gfxcafe.oku.account.v1.TransactionPayload trade = 3;
   */
  trade?: TransactionPayload;

  /**
   * Analysis results
   *
   * @generated from field: google.protobuf.Struct analysis = 4;
   */
  analysis?: JsonObject;

  /**
   * Extra data
   *
   * @generated from field: google.protobuf.Struct extra = 5;
   */
  extra?: JsonObject;
};

/**
 * Describes the message gfxcafe.oku.account.v1.CanoeMarketMarketIdResponse.
 * Use `create(CanoeMarketMarketIdResponseSchema)` to create a new message.
 */
export const CanoeMarketMarketIdResponseSchema: GenMessage<CanoeMarketMarketIdResponse> = /*@__PURE__*/
  messageDesc(file_gfxcafe_oku_account_v1_orders, 1);

/**
 * CanoeQuoteMarketMarketIdRequest for getting a price quote
 *
 * @generated from message gfxcafe.oku.account.v1.CanoeQuoteMarketMarketIdRequest
 */
export type CanoeQuoteMarketMarketIdRequest = Message<"gfxcafe.oku.account.v1.CanoeQuoteMarketMarketIdRequest"> & {
  /**
   * Market ID (e.g., "airswap", "enso", "kyberswap")
   *
   * @generated from field: string market_id = 1;
   */
  marketId: string;

  /**
   * Quote parameters as JSON
   *
   * @generated from field: google.protobuf.Struct quote_params = 2;
   */
  quoteParams?: JsonObject;
};

/**
 * Describes the message gfxcafe.oku.account.v1.CanoeQuoteMarketMarketIdRequest.
 * Use `create(CanoeQuoteMarketMarketIdRequestSchema)` to create a new message.
 */
export const CanoeQuoteMarketMarketIdRequestSchema: GenMessage<CanoeQuoteMarketMarketIdRequest> = /*@__PURE__*/
  messageDesc(file_gfxcafe_oku_account_v1_orders, 2);

/**
 * CanoeQuoteMarketMarketIdResponse with price quote data
 *
 * @generated from message gfxcafe.oku.account.v1.CanoeQuoteMarketMarketIdResponse
 */
export type CanoeQuoteMarketMarketIdResponse = Message<"gfxcafe.oku.account.v1.CanoeQuoteMarketMarketIdResponse"> & {
  /**
   * Input amount
   *
   * @generated from field: string in_amount = 1;
   */
  inAmount: string;

  /**
   * Output amount
   *
   * @generated from field: string out_amount = 2;
   */
  outAmount: string;

  /**
   * Slippage
   *
   * @generated from field: double slippage = 3;
   */
  slippage: number;

  /**
   * Estimated gas
   *
   * @generated from field: string estimated_gas = 4;
   */
  estimatedGas: string;

  /**
   * Chain ID
   *
   * @generated from field: int32 chain_id = 5;
   */
  chainId: number;

  /**
   * Market ID
   *
   * @generated from field: string market = 6;
   */
  market: string;

  /**
   * Is exact input
   *
   * @generated from field: bool is_exact_in = 7;
   */
  isExactIn: boolean;

  /**
   * Input token metadata
   *
   * @generated from field: gfxcafe.oku.account.v1.TokenMetadata in_token = 8;
   */
  inToken?: TokenMetadata;

  /**
   * Output token metadata
   *
   * @generated from field: gfxcafe.oku.account.v1.TokenMetadata out_token = 9;
   */
  outToken?: TokenMetadata;

  /**
   * Amount ratio
   *
   * @generated from field: double amount_ratio = 10;
   */
  amountRatio: number;

  /**
   * Gas value in USD
   *
   * @generated from field: double gas_usd_value = 11;
   */
  gasUsdValue: number;

  /**
   * Token input USD value
   *
   * @generated from field: double token_in_usd_value = 12;
   */
  tokenInUsdValue: number;

  /**
   * Total input USD value
   *
   * @generated from field: double in_usd_value = 13;
   */
  inUsdValue: number;

  /**
   * Token output USD value
   *
   * @generated from field: double token_out_usd_value = 14;
   */
  tokenOutUsdValue: number;

  /**
   * Total output USD value
   *
   * @generated from field: double out_usd_value = 15;
   */
  outUsdValue: number;

  /**
   * Fees information
   *
   * @generated from field: gfxcafe.oku.account.v1.Fees fees = 16;
   */
  fees?: Fees;

  /**
   * Trade path
   *
   * @generated from field: repeated gfxcafe.oku.account.v1.TradePath path = 17;
   */
  path: TradePath[];

  /**
   * Candidate trade transaction
   *
   * @generated from field: gfxcafe.oku.account.v1.TransactionPayload candidate_trade = 18;
   */
  candidateTrade?: TransactionPayload;

  /**
   * Coupon data
   *
   * @generated from field: google.protobuf.Struct coupon = 19;
   */
  coupon?: JsonObject;

  /**
   * Signing request
   *
   * @generated from field: google.protobuf.Struct signing_request = 20;
   */
  signingRequest?: JsonObject;

  /**
   * Extra data
   *
   * @generated from field: google.protobuf.Struct extra = 21;
   */
  extra?: JsonObject;

  /**
   * Analysis results
   *
   * @generated from field: google.protobuf.Struct analysis = 22;
   */
  analysis?: JsonObject;

  /**
   * Simulation result
   *
   * @generated from field: string simulation = 23;
   */
  simulation: string;

  /**
   * Simulation error
   *
   * @generated from field: string simulation_error = 24;
   */
  simulationError: string;

  /**
   * Simulated amount out
   *
   * @generated from field: string simulated_amount_out = 25;
   */
  simulatedAmountOut: string;

  /**
   * Timestamp
   *
   * @generated from field: int32 timestamp = 26;
   */
  timestamp: number;
};

/**
 * Describes the message gfxcafe.oku.account.v1.CanoeQuoteMarketMarketIdResponse.
 * Use `create(CanoeQuoteMarketMarketIdResponseSchema)` to create a new message.
 */
export const CanoeQuoteMarketMarketIdResponseSchema: GenMessage<CanoeQuoteMarketMarketIdResponse> = /*@__PURE__*/
  messageDesc(file_gfxcafe_oku_account_v1_orders, 3);

/**
 * TokenMetadata describes a token
 *
 * @generated from message gfxcafe.oku.account.v1.TokenMetadata
 */
export type TokenMetadata = Message<"gfxcafe.oku.account.v1.TokenMetadata"> & {
  /**
   * Chain ID
   *
   * @generated from field: int32 chain_id = 1;
   */
  chainId: number;

  /**
   * Token address
   *
   * @generated from field: gfxcafe.oku.account.v1.Address address = 2;
   */
  address?: Address;

  /**
   * Token decimals
   *
   * @generated from field: int32 decimals = 3;
   */
  decimals: number;

  /**
   * Token name
   *
   * @generated from field: string name = 4;
   */
  name: string;

  /**
   * Token symbol
   *
   * @generated from field: string symbol = 5;
   */
  symbol: string;
};

/**
 * Describes the message gfxcafe.oku.account.v1.TokenMetadata.
 * Use `create(TokenMetadataSchema)` to create a new message.
 */
export const TokenMetadataSchema: GenMessage<TokenMetadata> = /*@__PURE__*/
  messageDesc(file_gfxcafe_oku_account_v1_orders, 4);

/**
 * TransactionPayload for trade execution
 *
 * @generated from message gfxcafe.oku.account.v1.TransactionPayload
 */
export type TransactionPayload = Message<"gfxcafe.oku.account.v1.TransactionPayload"> & {
  /**
   * Chain ID
   *
   * @generated from field: int32 chain_id = 1;
   */
  chainId: number;

  /**
   * Access list
   *
   * @generated from field: google.protobuf.Struct access_list = 2;
   */
  accessList?: JsonObject;

  /**
   * Value in wei
   *
   * @generated from field: string value = 3;
   */
  value: string;

  /**
   * To address
   *
   * @generated from field: string to = 4;
   */
  to: string;

  /**
   * Transaction data
   *
   * @generated from field: string data = 5;
   */
  data: string;
};

/**
 * Describes the message gfxcafe.oku.account.v1.TransactionPayload.
 * Use `create(TransactionPayloadSchema)` to create a new message.
 */
export const TransactionPayloadSchema: GenMessage<TransactionPayload> = /*@__PURE__*/
  messageDesc(file_gfxcafe_oku_account_v1_orders, 5);

/**
 * ApprovalPayload for token approvals
 *
 * @generated from message gfxcafe.oku.account.v1.ApprovalPayload
 */
export type ApprovalPayload = Message<"gfxcafe.oku.account.v1.ApprovalPayload"> & {
  /**
   * Chain ID
   *
   * @generated from field: int32 chain_id = 1;
   */
  chainId: number;

  /**
   * Approvee address
   *
   * @generated from field: gfxcafe.oku.account.v1.Address approvee = 2;
   */
  approvee?: Address;

  /**
   * Token address
   *
   * @generated from field: gfxcafe.oku.account.v1.Address address = 3;
   */
  address?: Address;

  /**
   * Approval amount
   *
   * @generated from field: string amount = 4;
   */
  amount: string;
};

/**
 * Describes the message gfxcafe.oku.account.v1.ApprovalPayload.
 * Use `create(ApprovalPayloadSchema)` to create a new message.
 */
export const ApprovalPayloadSchema: GenMessage<ApprovalPayload> = /*@__PURE__*/
  messageDesc(file_gfxcafe_oku_account_v1_orders, 6);

/**
 * Fees information
 *
 * @generated from message gfxcafe.oku.account.v1.Fees
 */
export type Fees = Message<"gfxcafe.oku.account.v1.Fees"> & {
  /**
   * Fees in input amount
   *
   * @generated from field: string fees_in_amount = 1;
   */
  feesInAmount: string;

  /**
   * Fees in output amount
   *
   * @generated from field: string fees_out_amount = 2;
   */
  feesOutAmount: string;

  /**
   * Gas fees
   *
   * @generated from field: string gas = 3;
   */
  gas: string;
};

/**
 * Describes the message gfxcafe.oku.account.v1.Fees.
 * Use `create(FeesSchema)` to create a new message.
 */
export const FeesSchema: GenMessage<Fees> = /*@__PURE__*/
  messageDesc(file_gfxcafe_oku_account_v1_orders, 7);

/**
 * TradePath describes a swap path
 *
 * @generated from message gfxcafe.oku.account.v1.TradePath
 */
export type TradePath = Message<"gfxcafe.oku.account.v1.TradePath"> & {
  /**
   * DEX code
   *
   * @generated from field: string dex_code = 1;
   */
  dexCode: string;

  /**
   * Swap token
   *
   * @generated from field: string swap_token = 2;
   */
  swapToken: string;

  /**
   * Input amount
   *
   * @generated from field: string in_amount = 3;
   */
  inAmount: string;

  /**
   * Output amount
   *
   * @generated from field: string out_amount = 4;
   */
  outAmount: string;
};

/**
 * Describes the message gfxcafe.oku.account.v1.TradePath.
 * Use `create(TradePathSchema)` to create a new message.
 */
export const TradePathSchema: GenMessage<TradePath> = /*@__PURE__*/
  messageDesc(file_gfxcafe_oku_account_v1_orders, 8);

/**
 * OrdersService provides trading and quote functionality
 *
 * Note: /orders/simple_swap/* endpoints are handled by SimpleSwapService
 * Note: /orders/history/* endpoints are handled by OrderHistoryService
 *
 * @generated from service gfxcafe.oku.account.v1.OrdersService
 */
export const OrdersService: GenService<{
  /**
   * Generate execution information for a market order (/canoe_market/{marketId})
   *
   * @generated from rpc gfxcafe.oku.account.v1.OrdersService.CanoeMarketMarketId
   */
  canoeMarketMarketId: {
    methodKind: "unary";
    input: typeof CanoeMarketMarketIdRequestSchema;
    output: typeof CanoeMarketMarketIdResponseSchema;
  },
  /**
   * Get a price quote for a market order (/canoe_quote/market/{marketId})
   *
   * @generated from rpc gfxcafe.oku.account.v1.OrdersService.CanoeQuoteMarketMarketId
   */
  canoeQuoteMarketMarketId: {
    methodKind: "unary";
    input: typeof CanoeQuoteMarketMarketIdRequestSchema;
    output: typeof CanoeQuoteMarketMarketIdResponseSchema;
  },
}> = /*@__PURE__*/
  serviceDesc(file_gfxcafe_oku_account_v1_orders, 0);

