Skip to content

fix: add normalizeFee, analyzeFeeHistory, and expose multi-op builders on client - #1

Open
TheHalalHunter wants to merge 1 commit into
mainfrom
fix/sdk-issues-18-26-62
Open

fix: add normalizeFee, analyzeFeeHistory, and expose multi-op builders on client#1
TheHalalHunter wants to merge 1 commit into
mainfrom
fix/sdk-issues-18-26-62

Conversation

@TheHalalHunter

Copy link
Copy Markdown
Owner

Summary

Resolves issues Sorokit#18, Sorokit#26, and Sorokit#62.

Changes

Issue Sorokit#26 - normalizeFee()

  • Added normalizeFee(fee: string | number): string to src/shared/utils.ts
  • Ensures fees are floored integer stroops before submission
  • Exported from public API

Issue Sorokit#62 - analyzeFeeHistory()

  • Created src/transaction/feeAnalytics.ts
  • Computes min, max, avg, median, stddev, p25/p50/p75/p90/p95/p99
  • Returns FeeHistoryAnalytics | null
  • Exported from src/transaction/index.ts and src/index.ts

Issue Sorokit#18 - Multi-op builders on client

  • Wired buildPaymentWithTrustline, buildSwapTransaction, buildReverseTransaction into SorokitClient.transaction
  • Full error handling and logging consistent with existing methods
  • PaymentWithTrustlineParams, SwapTransactionParams, ReverseTransactionParams exported from public API

Files Changed

  • src/shared/utils.ts
  • src/transaction/feeAnalytics.ts (new)
  • src/transaction/index.ts
  • src/client/createSorokitClient.ts
  • src/index.ts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant