@stable_sea/sdk 0.2.4 → 0.2.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -596,6 +596,30 @@ export interface paths {
596
596
  patch?: never;
597
597
  trace?: never;
598
598
  };
599
+ "/v1/price_history": {
600
+ parameters: {
601
+ query?: never;
602
+ header?: never;
603
+ path?: never;
604
+ cookie?: never;
605
+ };
606
+ /**
607
+ * Read market price history
608
+ * @description Returns the BTC/USD market-price chart used by Terminal for the last thirty days, ninety days or current UTC year. Prices are decimal strings and do not depend on your holdings. The series contains about fifty samples, carrying forward the latest cached close at or before each sample. The underlying market-data cache retains ninety days, so a year-to-date request can contain a shorter available history.
609
+ *
610
+ * Inspect `source`: `historical` means normalized historical prices, `spot` means a flat two-point line at the current price because history was unavailable, and `unavailable` means no prices were available. A spot fallback does not describe past prices.
611
+ *
612
+ * The worker refreshes this observation about once a minute. `observed_ts` is the calculation start; the reads are not an atomic market snapshot. Missing, failed or older-than-two-minutes observations return HTTP 503. Requires `investments:read`.
613
+ */
614
+ get: operations["price_history.snapshot"];
615
+ put?: never;
616
+ post?: never;
617
+ delete?: never;
618
+ options?: never;
619
+ head?: never;
620
+ patch?: never;
621
+ trace?: never;
622
+ };
599
623
  "/v1/quotes": {
600
624
  parameters: {
601
625
  query?: never;
@@ -1567,6 +1591,25 @@ export interface components {
1567
1591
  holder_identifier?: string;
1568
1592
  legal_entity_name: string;
1569
1593
  };
1594
+ MarketPricePoint: {
1595
+ close_usd: string;
1596
+ /** Format: date-time */
1597
+ sampled_ts: string;
1598
+ };
1599
+ MarketPriceSeries: {
1600
+ /** @enum {string} */
1601
+ asset: "BTC";
1602
+ /** @enum {string} */
1603
+ object: "market_price_series";
1604
+ points: components["schemas"]["MarketPricePoint"][];
1605
+ /** @enum {string} */
1606
+ quote_asset: "USD";
1607
+ /**
1608
+ * @description historical is the normalized market series. spot is a flat current-price fallback, not historical observations. unavailable carries no points.
1609
+ * @enum {string}
1610
+ */
1611
+ source: "historical" | "spot" | "unavailable";
1612
+ };
1570
1613
  /** @description Customer metadata. Sensitive data is forbidden. */
1571
1614
  Metadata: {
1572
1615
  [key: string]: string;
@@ -1746,6 +1789,19 @@ export interface components {
1746
1789
  };
1747
1790
  /** @enum {string} */
1748
1791
  PolicyWindowKind: "calendar_day" | "calendar_week" | "rolling_24h" | "rolling_72h";
1792
+ PriceHistorySnapshot: {
1793
+ data: components["schemas"]["MarketPriceSeries"][];
1794
+ /** Format: date-time */
1795
+ end_ts: string;
1796
+ livemode: boolean;
1797
+ /** @enum {string} */
1798
+ object: "price_history";
1799
+ /** Format: date-time */
1800
+ observed_ts: string;
1801
+ /** Format: date-time */
1802
+ start_ts: string;
1803
+ window: components["schemas"]["BalanceHistoryWindow"];
1804
+ };
1749
1805
  Quote: {
1750
1806
  amount_usd: string;
1751
1807
  /** @enum {string} */
@@ -3448,6 +3504,45 @@ export interface operations {
3448
3504
  };
3449
3505
  };
3450
3506
  };
3507
+ "price_history.snapshot": {
3508
+ parameters: {
3509
+ query?: {
3510
+ /** @description Thirty days, ninety days, or the current UTC year to date. */
3511
+ window?: components["schemas"]["BalanceHistoryWindow"];
3512
+ };
3513
+ header?: never;
3514
+ path?: never;
3515
+ cookie?: never;
3516
+ };
3517
+ requestBody?: never;
3518
+ responses: {
3519
+ /** @description OK */
3520
+ 200: {
3521
+ headers: {
3522
+ "X-RateLimit-Limit": components["headers"]["X-RateLimit-Limit"];
3523
+ "X-RateLimit-Remaining": components["headers"]["X-RateLimit-Remaining"];
3524
+ "X-RateLimit-Reset": components["headers"]["X-RateLimit-Reset"];
3525
+ [name: string]: unknown;
3526
+ };
3527
+ content: {
3528
+ "application/json": components["schemas"]["PriceHistorySnapshot"];
3529
+ };
3530
+ };
3531
+ 400: components["responses"]["Error400"];
3532
+ 401: components["responses"]["Error401"];
3533
+ 403: components["responses"]["Error403"];
3534
+ 429: components["responses"]["Error429"];
3535
+ /** @description Error response. */
3536
+ default: {
3537
+ headers: {
3538
+ [name: string]: unknown;
3539
+ };
3540
+ content: {
3541
+ "application/json": components["schemas"]["Error"];
3542
+ };
3543
+ };
3544
+ };
3545
+ };
3451
3546
  "quotes.quote": {
3452
3547
  parameters: {
3453
3548
  query: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stable_sea/sdk",
3
- "version": "0.2.4",
3
+ "version": "0.2.5",
4
4
  "type": "module",
5
5
  "sideEffects": false,
6
6
  "files": [