Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for getFeeStats endpoint #1006

Merged
merged 5 commits into from
Jul 17, 2024
Merged

Add support for getFeeStats endpoint #1006

merged 5 commits into from
Jul 17, 2024

Conversation

Shaptic
Copy link
Contributor

@Shaptic Shaptic commented Jul 11, 2024

Closes #998 (see issue or changelog for schema).

Copy link

Size Change: +4.85 kB (+0.04%)

Total Size: 12.1 MB

Filename Size Change
dist/stellar-sdk.js 6.78 MB +2.87 kB (+0.04%)
dist/stellar-sdk.min.js 5.34 MB +1.98 kB (+0.04%)

compressed-size-action

@Shaptic Shaptic self-assigned this Jul 11, 2024
@Shaptic Shaptic force-pushed the add-getFeeStats branch 2 times, most recently from f29becc to 8aa54b5 Compare July 11, 2024 17:45
Signed-off-by: George <george@stellar.org>
Signed-off-by: George <george@stellar.org>
Signed-off-by: George <george@stellar.org>
Comment on lines +9 to +37
### Added
- `rpc.Server` now has a `getFeeStats` method which retrieves fee statistics for a previous chunk of ledgers to provide users with a way to provide informed decisions about getting their transactions included in the following ledgers ([#998](https://github.com/stellar/js-stellar-sdk/issues/998)):

```typescript
export interface GetFeeStatsResponse {
sorobanInclusionFee: FeeDistribution;
inclusionFee: FeeDistribution;
latestLedger: number; // uint32
}

interface FeeDistribution {
max: string; // uint64
min: string; // uint64
mode: string; // uint64
p10: string; // uint64
p20: string; // uint64
p30: string; // uint64
p40: string; // uint64
p50: string; // uint64
p60: string; // uint64
p70: string; // uint64
p80: string; // uint64
p90: string; // uint64
p95: string; // uint64
p99: string; // uint64
transactionCount: string; // uint32
ledgerCount: number; // uint32
}
```
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So good.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Support getFeeStats in the RPC client (rpc.Server)
3 participants