sentisense 0.59.0 → 0.60.0

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.
package/dist/index.d.mts CHANGED
@@ -2028,11 +2028,28 @@ interface ServingMetric {
2028
2028
  }
2029
2029
  /** Distribution data returned by the v2 distribution endpoint. */
2030
2030
  interface MetricDistribution {
2031
+ /** The metric queried. */
2032
+ metricType?: string;
2033
+ /** The dimension the metric is broken down by, e.g. "source". */
2034
+ dimension?: string;
2035
+ /** Dimension value to a number whose meaning `valueType` gives. Empty when there is no data. */
2036
+ distribution?: Record<string, number>;
2037
+ /**
2038
+ * `"SHARE_PERCENT"` for a count metric (mentions, creators): each value is a percentage share
2039
+ * of the total, summing to about 100. `"MEAN"` for a value metric (sentiment): each value is
2040
+ * the mean reading on the metric's own scale, never a share.
2041
+ */
2042
+ valueType?: "SHARE_PERCENT" | "MEAN";
2031
2043
  [key: string]: unknown;
2032
2044
  }
2033
2045
  interface MarketMood {
2034
2046
  [key: string]: unknown;
2035
2047
  }
2048
+ /** Options for `MarketMoodResource.get()`. */
2049
+ interface MarketMoodOptions {
2050
+ /** Days of history to return. Omit to get the API's default of 180. */
2051
+ days?: number;
2052
+ }
2036
2053
  /** AI-generated market summary with headline and analysis. */
2037
2054
  interface MarketSummary {
2038
2055
  /** Not populated by the API (always empty); retained for backward compatibility. */
@@ -3266,10 +3283,16 @@ declare class EntityMetrics {
3266
3283
  */
3267
3284
  getMetrics(symbol: string, options?: MetricsOptions): Promise<ServingMetric[]>;
3268
3285
  /**
3269
- * Get distribution data for a metric, broken down by a dimension (default: source).
3286
+ * Get a metric broken down by dimension (default dimension: source).
3287
+ *
3288
+ * `valueType` on the response says what each number in `distribution` is. For a count metric
3289
+ * such as `"mentions"` it is `"SHARE_PERCENT"`: each source's percentage share of the total,
3290
+ * summing to about 100. For `"sentiment"` it is `"MEAN"`: each source's mean polarity over the
3291
+ * window, in [-1, 1]. `"sentisense_score"` has no per-source split and answers with an empty
3292
+ * distribution.
3270
3293
  *
3271
3294
  * @param symbol Ticker symbol (e.g. "AAPL") or entity urlSlug.
3272
- * @param metricType The metric to break down (e.g. "mentions", "sentiment").
3295
+ * @param metricType The metric to break down (e.g. "mentions" or "sentiment").
3273
3296
  * @param options Optional dimension parameter.
3274
3297
  */
3275
3298
  getDistribution(symbol: string, metricType: MetricType, options?: MetricDistributionOptions): Promise<MetricDistribution>;
@@ -3728,7 +3751,13 @@ declare class KB {
3728
3751
  declare class MarketMoodResource {
3729
3752
  private client;
3730
3753
  constructor(client: APIClient);
3731
- /** Get market mood data (scores, history, sectors). */
3754
+ /**
3755
+ * Get market mood data (scores, history, sectors).
3756
+ *
3757
+ * @param options `days` sets how many days of history to return. Omit it to get the
3758
+ * API's default of 180.
3759
+ */
3760
+ get(options?: MarketMoodOptions): Promise<MarketMood>;
3732
3761
  get(): Promise<MarketMood>;
3733
3762
  }
3734
3763
 
@@ -4248,6 +4277,6 @@ declare class APIError extends SentiSenseError {
4248
4277
  constructor(message: string, status: number, code?: string);
4249
4278
  }
4250
4279
 
4251
- declare const VERSION = "0.59.0";
4280
+ declare const VERSION = "0.60.0";
4252
4281
 
4253
- export { type AISummary, APIError, type AnalystAction, type AnalystCall, type AnalystCalledItCall, type AnalystCalledItMove, type AnalystConsensus, type AnalystConsensusHistory, type AnalystConsensusHistoryPoint, type AnalystCoverage, type AnalystCoverageAnalyst, type AnalystCoverageBookEntry, type AnalystCoverageFirm, type AnalystEarningsSurprise, type AnalystEstimate, type AnalystEstimatesResponse, type AnalystFirmRating, type AnalystFirmTenure, type AnalystNote, type AnalystProfile, type AnalystRatingBuckets, type AssetMetadata, AuthenticationError, type CalendarMeta, type ChartData, type ChartDataPoint, type ClusterBuy, type CompanyKpisData, type CongressTrade, DeepHistoryUnavailableError, type Document, type DocumentSearchResponse, type DocumentSource, type EarningsCalendarResponse, type EarningsEvent, type EarningsKpiHighlight, type EarningsOutcomeStatistics, type EarningsQuarter, type EarningsReaction, type EarningsReactionsResponse, type EarningsSource, type EarningsStatistics, type EarningsStatisticsBaseline, type EarningsStatisticsDeviation, type EarningsStatisticsThresholds, type EarningsStatisticsWindow, type EntitySearchResult, type EntitySearchType, type EtfAggregateCoverage, type EtfAnalystAggregate, type EtfAnalystContributor, type EtfHolding, type EtfHoldings, type EtfInfo, type EtfInsiderAggregate, type EtfInsiderContributor, type EtfScreenerExecuteResponse, type EtfScreenerRow, type EtfSentimentAggregate, type EtfSentimentReading, type FeaturedScreen, type FloatInfo, type Fundamentals, type FundamentalsPeriod, type FundamentalsPeriodsResponse, type GetAnalystActionsOptions, type GetAnalystCalledItOptions, type GetAnalystCallsOptions, type GetAnalystConsensusHistoryOptions, type GetAnalystCoverageOptions, type GetAnalystMarketActivityOptions, type GetEarningsCalendarOptions, type GetEarningsStatisticsOptions, type GetEarningsSummariesOptions, type GetEtfInsiderAggregateOptions, type GetHoldersOptions, type GetInsiderOptions, type GetInsightsOptions, type GetLatestInsightsOptions, type GetOptionsHistoryOptions, type GetPoliticianActivityOptions, type GetPoliticianDirectoryOptions, type GetPoliticianMemberOptions, type GetPoliticiansOptions, type GetRankedEarningsOptions, type GetRecentEarningsOptions, type GetStockInsightsRangeOptions, type GetUserInsightsOptions, type Holder, type HolderNotableChanges, type IndexConstituent, type IndexHistoryPoint, type IndexHistoryResponse, type IndexListResponse, type IndexListing, type IndexSnapshot, type InsiderActivityResponse, type InsiderActivitySummary, type InsiderTrade, type Insight, type InsightPreviewResponse, type InstitutionList, type InstitutionListResponse, type InstitutionSummary, type InstitutionalFlow, type InstitutionalFlows, type InstitutionalFlowsResponse, type KBEntity, type KpiCoverageEntry, type KpiCoverageResponse, type KpiDataPoint, type KpiSeries, type KpiTypeEntry, type ListInstitutionsOptions, type LockedInsight, type MarketMood, type MarketStatus, type MarketSummary, type MetricDistribution, type MetricDistributionOptions, type MetricType, type MetricsBreakdown, type MetricsOptions, NotFoundError, type OptionsAggregate, type OptionsContext, type OptionsHighlight, type OptionsHistory, type OptionsHistoryWindow, type OptionsOiWalls, type OptionsOverview, type OptionsOverviewRow, type OptionsSummary, type OptionsUnusualContract, type OptionsWall, type PoliticianDetail, type PoliticianDirectory, type PoliticianDirectoryEntry, type PoliticianDirectoryResponse, type PoliticianSummary, type PreviewResponse, type Quarter, type RankedEarnings, type RankedEarningsSection, type RankedReportedEarnings, type RankedUpcomingEarnings, RateLimitError, type RatingBase, type RatingDimension, type RatingDimensionKey, type RatingFlag, type RatingNotRatedReason, type RatingSubLeg, type RecentEarningsEntry, type RiskAdjustment, type RiskCondition, type ScreenerExecuteOptions, type ScreenerExecuteResponse, type ScreenerFieldCatalog, type ScreenerFieldDescriptor, type ScreenerFieldOption, type ScreenerFilter, type ScreenerPlan, type ScreenerRow, type ScreenerScreensResponse, type ScreenerSort, type SearchEntitiesOptions, type SearchStoriesOptions, SentiSense, SentiSenseError, type SentiSenseOptions, type SentimentEntry, type ServingMetric, type ShortInterest, type ShortVolume, type SimilarStock, type StockDetail, type StockEntity, type StockImage, type StockNotRated, type StockPrice, type StockProfile, type StockQuote, type StockRating, type StockRatingResponse, type StockSocialDominance, type Story, type StoryCluster, type StoryTimelineEntry, TemporarilyUnavailableError, type TickerHolders, type TrackerEvent, type TrackerGeoEntry, type TrackerHeadlineMetric, type TrackerListResponse, type TrackerListing, type TrackerMetricValue, type TrackerSignal, type TrackerSnapshot, type TrackerSnapshotResponse, type TrackerSourceRef, type TrackerTableRow, type TrackerTimeSeriesPoint, type TtmFundamentals, VERSION, type WeightedConsensus, type WeightedNetFlow, SentiSense as default };
4282
+ export { type AISummary, APIError, type AnalystAction, type AnalystCall, type AnalystCalledItCall, type AnalystCalledItMove, type AnalystConsensus, type AnalystConsensusHistory, type AnalystConsensusHistoryPoint, type AnalystCoverage, type AnalystCoverageAnalyst, type AnalystCoverageBookEntry, type AnalystCoverageFirm, type AnalystEarningsSurprise, type AnalystEstimate, type AnalystEstimatesResponse, type AnalystFirmRating, type AnalystFirmTenure, type AnalystNote, type AnalystProfile, type AnalystRatingBuckets, type AssetMetadata, AuthenticationError, type CalendarMeta, type ChartData, type ChartDataPoint, type ClusterBuy, type CompanyKpisData, type CongressTrade, DeepHistoryUnavailableError, type Document, type DocumentSearchResponse, type DocumentSource, type EarningsCalendarResponse, type EarningsEvent, type EarningsKpiHighlight, type EarningsOutcomeStatistics, type EarningsQuarter, type EarningsReaction, type EarningsReactionsResponse, type EarningsSource, type EarningsStatistics, type EarningsStatisticsBaseline, type EarningsStatisticsDeviation, type EarningsStatisticsThresholds, type EarningsStatisticsWindow, type EntitySearchResult, type EntitySearchType, type EtfAggregateCoverage, type EtfAnalystAggregate, type EtfAnalystContributor, type EtfHolding, type EtfHoldings, type EtfInfo, type EtfInsiderAggregate, type EtfInsiderContributor, type EtfScreenerExecuteResponse, type EtfScreenerRow, type EtfSentimentAggregate, type EtfSentimentReading, type FeaturedScreen, type FloatInfo, type Fundamentals, type FundamentalsPeriod, type FundamentalsPeriodsResponse, type GetAnalystActionsOptions, type GetAnalystCalledItOptions, type GetAnalystCallsOptions, type GetAnalystConsensusHistoryOptions, type GetAnalystCoverageOptions, type GetAnalystMarketActivityOptions, type GetEarningsCalendarOptions, type GetEarningsStatisticsOptions, type GetEarningsSummariesOptions, type GetEtfInsiderAggregateOptions, type GetHoldersOptions, type GetInsiderOptions, type GetInsightsOptions, type GetLatestInsightsOptions, type GetOptionsHistoryOptions, type GetPoliticianActivityOptions, type GetPoliticianDirectoryOptions, type GetPoliticianMemberOptions, type GetPoliticiansOptions, type GetRankedEarningsOptions, type GetRecentEarningsOptions, type GetStockInsightsRangeOptions, type GetUserInsightsOptions, type Holder, type HolderNotableChanges, type IndexConstituent, type IndexHistoryPoint, type IndexHistoryResponse, type IndexListResponse, type IndexListing, type IndexSnapshot, type InsiderActivityResponse, type InsiderActivitySummary, type InsiderTrade, type Insight, type InsightPreviewResponse, type InstitutionList, type InstitutionListResponse, type InstitutionSummary, type InstitutionalFlow, type InstitutionalFlows, type InstitutionalFlowsResponse, type KBEntity, type KpiCoverageEntry, type KpiCoverageResponse, type KpiDataPoint, type KpiSeries, type KpiTypeEntry, type ListInstitutionsOptions, type LockedInsight, type MarketMood, type MarketMoodOptions, type MarketStatus, type MarketSummary, type MetricDistribution, type MetricDistributionOptions, type MetricType, type MetricsBreakdown, type MetricsOptions, NotFoundError, type OptionsAggregate, type OptionsContext, type OptionsHighlight, type OptionsHistory, type OptionsHistoryWindow, type OptionsOiWalls, type OptionsOverview, type OptionsOverviewRow, type OptionsSummary, type OptionsUnusualContract, type OptionsWall, type PoliticianDetail, type PoliticianDirectory, type PoliticianDirectoryEntry, type PoliticianDirectoryResponse, type PoliticianSummary, type PreviewResponse, type Quarter, type RankedEarnings, type RankedEarningsSection, type RankedReportedEarnings, type RankedUpcomingEarnings, RateLimitError, type RatingBase, type RatingDimension, type RatingDimensionKey, type RatingFlag, type RatingNotRatedReason, type RatingSubLeg, type RecentEarningsEntry, type RiskAdjustment, type RiskCondition, type ScreenerExecuteOptions, type ScreenerExecuteResponse, type ScreenerFieldCatalog, type ScreenerFieldDescriptor, type ScreenerFieldOption, type ScreenerFilter, type ScreenerPlan, type ScreenerRow, type ScreenerScreensResponse, type ScreenerSort, type SearchEntitiesOptions, type SearchStoriesOptions, SentiSense, SentiSenseError, type SentiSenseOptions, type SentimentEntry, type ServingMetric, type ShortInterest, type ShortVolume, type SimilarStock, type StockDetail, type StockEntity, type StockImage, type StockNotRated, type StockPrice, type StockProfile, type StockQuote, type StockRating, type StockRatingResponse, type StockSocialDominance, type Story, type StoryCluster, type StoryTimelineEntry, TemporarilyUnavailableError, type TickerHolders, type TrackerEvent, type TrackerGeoEntry, type TrackerHeadlineMetric, type TrackerListResponse, type TrackerListing, type TrackerMetricValue, type TrackerSignal, type TrackerSnapshot, type TrackerSnapshotResponse, type TrackerSourceRef, type TrackerTableRow, type TrackerTimeSeriesPoint, type TtmFundamentals, VERSION, type WeightedConsensus, type WeightedNetFlow, SentiSense as default };
package/dist/index.d.ts CHANGED
@@ -2028,11 +2028,28 @@ interface ServingMetric {
2028
2028
  }
2029
2029
  /** Distribution data returned by the v2 distribution endpoint. */
2030
2030
  interface MetricDistribution {
2031
+ /** The metric queried. */
2032
+ metricType?: string;
2033
+ /** The dimension the metric is broken down by, e.g. "source". */
2034
+ dimension?: string;
2035
+ /** Dimension value to a number whose meaning `valueType` gives. Empty when there is no data. */
2036
+ distribution?: Record<string, number>;
2037
+ /**
2038
+ * `"SHARE_PERCENT"` for a count metric (mentions, creators): each value is a percentage share
2039
+ * of the total, summing to about 100. `"MEAN"` for a value metric (sentiment): each value is
2040
+ * the mean reading on the metric's own scale, never a share.
2041
+ */
2042
+ valueType?: "SHARE_PERCENT" | "MEAN";
2031
2043
  [key: string]: unknown;
2032
2044
  }
2033
2045
  interface MarketMood {
2034
2046
  [key: string]: unknown;
2035
2047
  }
2048
+ /** Options for `MarketMoodResource.get()`. */
2049
+ interface MarketMoodOptions {
2050
+ /** Days of history to return. Omit to get the API's default of 180. */
2051
+ days?: number;
2052
+ }
2036
2053
  /** AI-generated market summary with headline and analysis. */
2037
2054
  interface MarketSummary {
2038
2055
  /** Not populated by the API (always empty); retained for backward compatibility. */
@@ -3266,10 +3283,16 @@ declare class EntityMetrics {
3266
3283
  */
3267
3284
  getMetrics(symbol: string, options?: MetricsOptions): Promise<ServingMetric[]>;
3268
3285
  /**
3269
- * Get distribution data for a metric, broken down by a dimension (default: source).
3286
+ * Get a metric broken down by dimension (default dimension: source).
3287
+ *
3288
+ * `valueType` on the response says what each number in `distribution` is. For a count metric
3289
+ * such as `"mentions"` it is `"SHARE_PERCENT"`: each source's percentage share of the total,
3290
+ * summing to about 100. For `"sentiment"` it is `"MEAN"`: each source's mean polarity over the
3291
+ * window, in [-1, 1]. `"sentisense_score"` has no per-source split and answers with an empty
3292
+ * distribution.
3270
3293
  *
3271
3294
  * @param symbol Ticker symbol (e.g. "AAPL") or entity urlSlug.
3272
- * @param metricType The metric to break down (e.g. "mentions", "sentiment").
3295
+ * @param metricType The metric to break down (e.g. "mentions" or "sentiment").
3273
3296
  * @param options Optional dimension parameter.
3274
3297
  */
3275
3298
  getDistribution(symbol: string, metricType: MetricType, options?: MetricDistributionOptions): Promise<MetricDistribution>;
@@ -3728,7 +3751,13 @@ declare class KB {
3728
3751
  declare class MarketMoodResource {
3729
3752
  private client;
3730
3753
  constructor(client: APIClient);
3731
- /** Get market mood data (scores, history, sectors). */
3754
+ /**
3755
+ * Get market mood data (scores, history, sectors).
3756
+ *
3757
+ * @param options `days` sets how many days of history to return. Omit it to get the
3758
+ * API's default of 180.
3759
+ */
3760
+ get(options?: MarketMoodOptions): Promise<MarketMood>;
3732
3761
  get(): Promise<MarketMood>;
3733
3762
  }
3734
3763
 
@@ -4248,6 +4277,6 @@ declare class APIError extends SentiSenseError {
4248
4277
  constructor(message: string, status: number, code?: string);
4249
4278
  }
4250
4279
 
4251
- declare const VERSION = "0.59.0";
4280
+ declare const VERSION = "0.60.0";
4252
4281
 
4253
- export { type AISummary, APIError, type AnalystAction, type AnalystCall, type AnalystCalledItCall, type AnalystCalledItMove, type AnalystConsensus, type AnalystConsensusHistory, type AnalystConsensusHistoryPoint, type AnalystCoverage, type AnalystCoverageAnalyst, type AnalystCoverageBookEntry, type AnalystCoverageFirm, type AnalystEarningsSurprise, type AnalystEstimate, type AnalystEstimatesResponse, type AnalystFirmRating, type AnalystFirmTenure, type AnalystNote, type AnalystProfile, type AnalystRatingBuckets, type AssetMetadata, AuthenticationError, type CalendarMeta, type ChartData, type ChartDataPoint, type ClusterBuy, type CompanyKpisData, type CongressTrade, DeepHistoryUnavailableError, type Document, type DocumentSearchResponse, type DocumentSource, type EarningsCalendarResponse, type EarningsEvent, type EarningsKpiHighlight, type EarningsOutcomeStatistics, type EarningsQuarter, type EarningsReaction, type EarningsReactionsResponse, type EarningsSource, type EarningsStatistics, type EarningsStatisticsBaseline, type EarningsStatisticsDeviation, type EarningsStatisticsThresholds, type EarningsStatisticsWindow, type EntitySearchResult, type EntitySearchType, type EtfAggregateCoverage, type EtfAnalystAggregate, type EtfAnalystContributor, type EtfHolding, type EtfHoldings, type EtfInfo, type EtfInsiderAggregate, type EtfInsiderContributor, type EtfScreenerExecuteResponse, type EtfScreenerRow, type EtfSentimentAggregate, type EtfSentimentReading, type FeaturedScreen, type FloatInfo, type Fundamentals, type FundamentalsPeriod, type FundamentalsPeriodsResponse, type GetAnalystActionsOptions, type GetAnalystCalledItOptions, type GetAnalystCallsOptions, type GetAnalystConsensusHistoryOptions, type GetAnalystCoverageOptions, type GetAnalystMarketActivityOptions, type GetEarningsCalendarOptions, type GetEarningsStatisticsOptions, type GetEarningsSummariesOptions, type GetEtfInsiderAggregateOptions, type GetHoldersOptions, type GetInsiderOptions, type GetInsightsOptions, type GetLatestInsightsOptions, type GetOptionsHistoryOptions, type GetPoliticianActivityOptions, type GetPoliticianDirectoryOptions, type GetPoliticianMemberOptions, type GetPoliticiansOptions, type GetRankedEarningsOptions, type GetRecentEarningsOptions, type GetStockInsightsRangeOptions, type GetUserInsightsOptions, type Holder, type HolderNotableChanges, type IndexConstituent, type IndexHistoryPoint, type IndexHistoryResponse, type IndexListResponse, type IndexListing, type IndexSnapshot, type InsiderActivityResponse, type InsiderActivitySummary, type InsiderTrade, type Insight, type InsightPreviewResponse, type InstitutionList, type InstitutionListResponse, type InstitutionSummary, type InstitutionalFlow, type InstitutionalFlows, type InstitutionalFlowsResponse, type KBEntity, type KpiCoverageEntry, type KpiCoverageResponse, type KpiDataPoint, type KpiSeries, type KpiTypeEntry, type ListInstitutionsOptions, type LockedInsight, type MarketMood, type MarketStatus, type MarketSummary, type MetricDistribution, type MetricDistributionOptions, type MetricType, type MetricsBreakdown, type MetricsOptions, NotFoundError, type OptionsAggregate, type OptionsContext, type OptionsHighlight, type OptionsHistory, type OptionsHistoryWindow, type OptionsOiWalls, type OptionsOverview, type OptionsOverviewRow, type OptionsSummary, type OptionsUnusualContract, type OptionsWall, type PoliticianDetail, type PoliticianDirectory, type PoliticianDirectoryEntry, type PoliticianDirectoryResponse, type PoliticianSummary, type PreviewResponse, type Quarter, type RankedEarnings, type RankedEarningsSection, type RankedReportedEarnings, type RankedUpcomingEarnings, RateLimitError, type RatingBase, type RatingDimension, type RatingDimensionKey, type RatingFlag, type RatingNotRatedReason, type RatingSubLeg, type RecentEarningsEntry, type RiskAdjustment, type RiskCondition, type ScreenerExecuteOptions, type ScreenerExecuteResponse, type ScreenerFieldCatalog, type ScreenerFieldDescriptor, type ScreenerFieldOption, type ScreenerFilter, type ScreenerPlan, type ScreenerRow, type ScreenerScreensResponse, type ScreenerSort, type SearchEntitiesOptions, type SearchStoriesOptions, SentiSense, SentiSenseError, type SentiSenseOptions, type SentimentEntry, type ServingMetric, type ShortInterest, type ShortVolume, type SimilarStock, type StockDetail, type StockEntity, type StockImage, type StockNotRated, type StockPrice, type StockProfile, type StockQuote, type StockRating, type StockRatingResponse, type StockSocialDominance, type Story, type StoryCluster, type StoryTimelineEntry, TemporarilyUnavailableError, type TickerHolders, type TrackerEvent, type TrackerGeoEntry, type TrackerHeadlineMetric, type TrackerListResponse, type TrackerListing, type TrackerMetricValue, type TrackerSignal, type TrackerSnapshot, type TrackerSnapshotResponse, type TrackerSourceRef, type TrackerTableRow, type TrackerTimeSeriesPoint, type TtmFundamentals, VERSION, type WeightedConsensus, type WeightedNetFlow, SentiSense as default };
4282
+ export { type AISummary, APIError, type AnalystAction, type AnalystCall, type AnalystCalledItCall, type AnalystCalledItMove, type AnalystConsensus, type AnalystConsensusHistory, type AnalystConsensusHistoryPoint, type AnalystCoverage, type AnalystCoverageAnalyst, type AnalystCoverageBookEntry, type AnalystCoverageFirm, type AnalystEarningsSurprise, type AnalystEstimate, type AnalystEstimatesResponse, type AnalystFirmRating, type AnalystFirmTenure, type AnalystNote, type AnalystProfile, type AnalystRatingBuckets, type AssetMetadata, AuthenticationError, type CalendarMeta, type ChartData, type ChartDataPoint, type ClusterBuy, type CompanyKpisData, type CongressTrade, DeepHistoryUnavailableError, type Document, type DocumentSearchResponse, type DocumentSource, type EarningsCalendarResponse, type EarningsEvent, type EarningsKpiHighlight, type EarningsOutcomeStatistics, type EarningsQuarter, type EarningsReaction, type EarningsReactionsResponse, type EarningsSource, type EarningsStatistics, type EarningsStatisticsBaseline, type EarningsStatisticsDeviation, type EarningsStatisticsThresholds, type EarningsStatisticsWindow, type EntitySearchResult, type EntitySearchType, type EtfAggregateCoverage, type EtfAnalystAggregate, type EtfAnalystContributor, type EtfHolding, type EtfHoldings, type EtfInfo, type EtfInsiderAggregate, type EtfInsiderContributor, type EtfScreenerExecuteResponse, type EtfScreenerRow, type EtfSentimentAggregate, type EtfSentimentReading, type FeaturedScreen, type FloatInfo, type Fundamentals, type FundamentalsPeriod, type FundamentalsPeriodsResponse, type GetAnalystActionsOptions, type GetAnalystCalledItOptions, type GetAnalystCallsOptions, type GetAnalystConsensusHistoryOptions, type GetAnalystCoverageOptions, type GetAnalystMarketActivityOptions, type GetEarningsCalendarOptions, type GetEarningsStatisticsOptions, type GetEarningsSummariesOptions, type GetEtfInsiderAggregateOptions, type GetHoldersOptions, type GetInsiderOptions, type GetInsightsOptions, type GetLatestInsightsOptions, type GetOptionsHistoryOptions, type GetPoliticianActivityOptions, type GetPoliticianDirectoryOptions, type GetPoliticianMemberOptions, type GetPoliticiansOptions, type GetRankedEarningsOptions, type GetRecentEarningsOptions, type GetStockInsightsRangeOptions, type GetUserInsightsOptions, type Holder, type HolderNotableChanges, type IndexConstituent, type IndexHistoryPoint, type IndexHistoryResponse, type IndexListResponse, type IndexListing, type IndexSnapshot, type InsiderActivityResponse, type InsiderActivitySummary, type InsiderTrade, type Insight, type InsightPreviewResponse, type InstitutionList, type InstitutionListResponse, type InstitutionSummary, type InstitutionalFlow, type InstitutionalFlows, type InstitutionalFlowsResponse, type KBEntity, type KpiCoverageEntry, type KpiCoverageResponse, type KpiDataPoint, type KpiSeries, type KpiTypeEntry, type ListInstitutionsOptions, type LockedInsight, type MarketMood, type MarketMoodOptions, type MarketStatus, type MarketSummary, type MetricDistribution, type MetricDistributionOptions, type MetricType, type MetricsBreakdown, type MetricsOptions, NotFoundError, type OptionsAggregate, type OptionsContext, type OptionsHighlight, type OptionsHistory, type OptionsHistoryWindow, type OptionsOiWalls, type OptionsOverview, type OptionsOverviewRow, type OptionsSummary, type OptionsUnusualContract, type OptionsWall, type PoliticianDetail, type PoliticianDirectory, type PoliticianDirectoryEntry, type PoliticianDirectoryResponse, type PoliticianSummary, type PreviewResponse, type Quarter, type RankedEarnings, type RankedEarningsSection, type RankedReportedEarnings, type RankedUpcomingEarnings, RateLimitError, type RatingBase, type RatingDimension, type RatingDimensionKey, type RatingFlag, type RatingNotRatedReason, type RatingSubLeg, type RecentEarningsEntry, type RiskAdjustment, type RiskCondition, type ScreenerExecuteOptions, type ScreenerExecuteResponse, type ScreenerFieldCatalog, type ScreenerFieldDescriptor, type ScreenerFieldOption, type ScreenerFilter, type ScreenerPlan, type ScreenerRow, type ScreenerScreensResponse, type ScreenerSort, type SearchEntitiesOptions, type SearchStoriesOptions, SentiSense, SentiSenseError, type SentiSenseOptions, type SentimentEntry, type ServingMetric, type ShortInterest, type ShortVolume, type SimilarStock, type StockDetail, type StockEntity, type StockImage, type StockNotRated, type StockPrice, type StockProfile, type StockQuote, type StockRating, type StockRatingResponse, type StockSocialDominance, type Story, type StoryCluster, type StoryTimelineEntry, TemporarilyUnavailableError, type TickerHolders, type TrackerEvent, type TrackerGeoEntry, type TrackerHeadlineMetric, type TrackerListResponse, type TrackerListing, type TrackerMetricValue, type TrackerSignal, type TrackerSnapshot, type TrackerSnapshotResponse, type TrackerSourceRef, type TrackerTableRow, type TrackerTimeSeriesPoint, type TtmFundamentals, VERSION, type WeightedConsensus, type WeightedNetFlow, SentiSense as default };
package/dist/index.mjs CHANGED
@@ -408,10 +408,16 @@ var EntityMetrics = class {
408
408
  );
409
409
  }
410
410
  /**
411
- * Get distribution data for a metric, broken down by a dimension (default: source).
411
+ * Get a metric broken down by dimension (default dimension: source).
412
+ *
413
+ * `valueType` on the response says what each number in `distribution` is. For a count metric
414
+ * such as `"mentions"` it is `"SHARE_PERCENT"`: each source's percentage share of the total,
415
+ * summing to about 100. For `"sentiment"` it is `"MEAN"`: each source's mean polarity over the
416
+ * window, in [-1, 1]. `"sentisense_score"` has no per-source split and answers with an empty
417
+ * distribution.
412
418
  *
413
419
  * @param symbol Ticker symbol (e.g. "AAPL") or entity urlSlug.
414
- * @param metricType The metric to break down (e.g. "mentions", "sentiment").
420
+ * @param metricType The metric to break down (e.g. "mentions" or "sentiment").
415
421
  * @param options Optional dimension parameter.
416
422
  */
417
423
  async getDistribution(symbol, metricType, options = {}) {
@@ -802,12 +808,13 @@ var MarketMoodResource = class {
802
808
  constructor(client) {
803
809
  this.client = client;
804
810
  }
805
- /** Get market mood data (scores, history, sectors). */
806
- async get() {
807
- return this.client.get("/api/v2/market-mood");
811
+ async get(options) {
812
+ const days = options?.days;
813
+ return this.client.get(
814
+ "/api/v2/market-mood",
815
+ days === void 0 ? void 0 : { days }
816
+ );
808
817
  }
809
- // TODO: accept a `days` param to control history length (the endpoint supports ?days=N).
810
- //
811
818
  // Market Mood is also reachable through `client.indexes`, which serves it in the shared
812
819
  // index envelope alongside fed-sentiment and ai-sentiment. Use this resource when you want
813
820
  // the phase band, weekly change, per-signal breakdown and per-sector map; use `indexes`
@@ -1311,7 +1318,7 @@ var Trackers = class {
1311
1318
  };
1312
1319
 
1313
1320
  // src/version.ts
1314
- var VERSION = "0.59.0";
1321
+ var VERSION = "0.60.0";
1315
1322
 
1316
1323
  // src/client.ts
1317
1324
  var DEFAULT_BASE_URL = "https://app.sentisense.ai";