@scalemule/sdk 0.0.75 → 0.0.76
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/README.md +26 -0
- package/dist/index.d.mts +238 -1
- package/dist/index.d.ts +238 -1
- package/dist/index.js +96 -0
- package/dist/index.mjs +94 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -567,3 +567,29 @@ Mutations require optimistic revisions. Collection/feature edits never auto-publ
|
|
|
567
567
|
Submission/report retries reuse the same UUID `idempotency_key` for unchanged input.
|
|
568
568
|
Residential `EXACT_PUBLIC` locations are rejected. Photo approval and publication
|
|
569
569
|
are separate actions; `mediaPath()` returns a path to proxy, never a signed file URL.
|
|
570
|
+
|
|
571
|
+
|
|
572
|
+
### Local intelligence (BaseNews foundation)
|
|
573
|
+
|
|
574
|
+
`sdk.localIntelligence` provides typed access to the existing News service's opt-in
|
|
575
|
+
`basenews/1` contract: approved record projections, supporting evidence, scoped
|
|
576
|
+
changes, concise briefings, explicit preferences/follows, and voluntary utility
|
|
577
|
+
feedback. Publication publish permission and a human review are required for
|
|
578
|
+
`release`; being allowed to read intelligence never grants editorial authority.
|
|
579
|
+
|
|
580
|
+
Use `briefing(publicationId, { geography, personalized: false })` for a useful
|
|
581
|
+
nonpersonalized community view. `briefingForPreferences` accepts ephemeral
|
|
582
|
+
explicit preferences for agents without reading another person's saved profile.
|
|
583
|
+
Existing SDK authentication and request context apply; publication API keys remain
|
|
584
|
+
server-side and no internal platform token belongs in an application.
|
|
585
|
+
|
|
586
|
+
Cache records per application/publication, honor `refresh_after`, and remove
|
|
587
|
+
tombstones. `applyIntelligenceChanges` preserves sequence precision, rejects gaps
|
|
588
|
+
and cross-scope pages, and ignores replayed changes. When bootstrapping with
|
|
589
|
+
`records`, retain the first page's `changes_cursor` and `changes_sequence`; use
|
|
590
|
+
that sequence to initialize the cache, then consume changes serially. Leases must
|
|
591
|
+
be refreshed even when the change feed is quiet. Responses represent current
|
|
592
|
+
authorized state, not access to historical source documents.
|
|
593
|
+
|
|
594
|
+
This feature requires the new News migration and explicit operator enablement.
|
|
595
|
+
It does not change existing publishing, maps, jobs, classifieds or reader flows.
|
package/dist/index.d.mts
CHANGED
|
@@ -5626,6 +5626,242 @@ declare class CommunityMapsGeographyService extends ServiceModule {
|
|
|
5626
5626
|
}>>;
|
|
5627
5627
|
}
|
|
5628
5628
|
|
|
5629
|
+
/** BaseNews delivery through the existing News service and ScaleMule identity.
|
|
5630
|
+
* Records are evidence-backed projections; a release is not an article.
|
|
5631
|
+
* Honor refresh_after and removals. Never use this API as a source-text archive.
|
|
5632
|
+
*/
|
|
5633
|
+
|
|
5634
|
+
type IntelligenceKind = 'event' | 'development' | 'community_story' | 'opportunity' | 'public_notice';
|
|
5635
|
+
type IntelligenceStatus = 'proposed' | 'approved' | 'scheduled' | 'ongoing' | 'completed' | 'canceled' | 'postponed' | 'disputed';
|
|
5636
|
+
type IntelligenceVerification = 'unverified' | 'community_submitted' | 'supported' | 'officially_confirmed' | 'independently_verified' | 'disputed';
|
|
5637
|
+
type IntelligenceSection = 'important' | 'around_you' | 'people' | 'discover' | 'participate';
|
|
5638
|
+
type CommunityValueOutcome = 'understand' | 'discover' | 'decide' | 'participate' | 'not_relevant';
|
|
5639
|
+
interface IntelligenceEvent {
|
|
5640
|
+
starts_at: string;
|
|
5641
|
+
ends_at: string;
|
|
5642
|
+
time_zone: string;
|
|
5643
|
+
place_entity_id: string | null;
|
|
5644
|
+
organizer_entity_id: string | null;
|
|
5645
|
+
series_entity_id: string | null;
|
|
5646
|
+
cost: string | null;
|
|
5647
|
+
accessibility: string | null;
|
|
5648
|
+
}
|
|
5649
|
+
interface IntelligenceAction {
|
|
5650
|
+
label: string;
|
|
5651
|
+
url: string;
|
|
5652
|
+
deadline: string | null;
|
|
5653
|
+
}
|
|
5654
|
+
interface IntelligenceSource {
|
|
5655
|
+
id: string;
|
|
5656
|
+
title: string;
|
|
5657
|
+
publisher: string;
|
|
5658
|
+
url: string;
|
|
5659
|
+
published_at: string | null;
|
|
5660
|
+
retrieved_at: string | null;
|
|
5661
|
+
kind: string;
|
|
5662
|
+
distance: string;
|
|
5663
|
+
interested_party: boolean | null;
|
|
5664
|
+
}
|
|
5665
|
+
interface IntelligenceClaim {
|
|
5666
|
+
id: string;
|
|
5667
|
+
text: string;
|
|
5668
|
+
verification: 'UNVERIFIED' | 'SUPPORTED' | 'VERIFIED' | 'DISPUTED';
|
|
5669
|
+
attribution: string | null;
|
|
5670
|
+
evidence: {
|
|
5671
|
+
source_id: string;
|
|
5672
|
+
role: 'DIRECT' | 'CORROBORATING' | 'CONTEXT' | 'CONTRADICTING' | 'ATTRIBUTED_CLAIM';
|
|
5673
|
+
}[];
|
|
5674
|
+
}
|
|
5675
|
+
interface LocalIntelligenceRecord {
|
|
5676
|
+
contract_version: 'basenews/1';
|
|
5677
|
+
id: string;
|
|
5678
|
+
revision: number;
|
|
5679
|
+
title: string;
|
|
5680
|
+
why_it_matters: string;
|
|
5681
|
+
kind: IntelligenceKind;
|
|
5682
|
+
status: IntelligenceStatus;
|
|
5683
|
+
section: IntelligenceSection;
|
|
5684
|
+
civic_importance: boolean;
|
|
5685
|
+
geography_ids: string[];
|
|
5686
|
+
related_entity_ids: string[];
|
|
5687
|
+
issue_entity_ids: string[];
|
|
5688
|
+
topics: string[];
|
|
5689
|
+
event: IntelligenceEvent | null;
|
|
5690
|
+
actions: IntelligenceAction[];
|
|
5691
|
+
claims: IntelligenceClaim[];
|
|
5692
|
+
sources: IntelligenceSource[];
|
|
5693
|
+
verification: IntelligenceVerification;
|
|
5694
|
+
last_verified_at: string | null;
|
|
5695
|
+
observed_at: string;
|
|
5696
|
+
effective_at: string | null;
|
|
5697
|
+
review_due_at: string;
|
|
5698
|
+
published_at: string;
|
|
5699
|
+
original_reporting_url: string | null;
|
|
5700
|
+
original_byline: string;
|
|
5701
|
+
originating_publication_id: string;
|
|
5702
|
+
license: string;
|
|
5703
|
+
supersedes_revision: number | null;
|
|
5704
|
+
canonical_references: {
|
|
5705
|
+
reporting_package_id: string;
|
|
5706
|
+
reporting_revision: number;
|
|
5707
|
+
event_id: string | null;
|
|
5708
|
+
event_version: number | null;
|
|
5709
|
+
};
|
|
5710
|
+
/** Refresh or remove the record after this time. Access may have been revoked. */
|
|
5711
|
+
refresh_after: string;
|
|
5712
|
+
relevance_reasons?: string[];
|
|
5713
|
+
}
|
|
5714
|
+
interface LocalIntelligencePreferences {
|
|
5715
|
+
personalized: boolean;
|
|
5716
|
+
geography_ids: string[];
|
|
5717
|
+
topic_codes: string[];
|
|
5718
|
+
entity_ids: string[];
|
|
5719
|
+
issue_ids: string[];
|
|
5720
|
+
record_ids: string[];
|
|
5721
|
+
}
|
|
5722
|
+
interface IntelligenceRecordPage {
|
|
5723
|
+
contract_version: 'basenews/1';
|
|
5724
|
+
items: LocalIntelligenceRecord[];
|
|
5725
|
+
next_cursor: string | null;
|
|
5726
|
+
/** Keep the FIRST page's checkpoint while bootstrapping the inventory. */
|
|
5727
|
+
changes_cursor: string;
|
|
5728
|
+
/** Initialize IntelligenceCache.sequence from the FIRST page's value. */
|
|
5729
|
+
changes_sequence: string;
|
|
5730
|
+
}
|
|
5731
|
+
interface IntelligenceChangePage {
|
|
5732
|
+
contract_version: 'basenews/1';
|
|
5733
|
+
scope: {
|
|
5734
|
+
application_id: string;
|
|
5735
|
+
publication_id: string;
|
|
5736
|
+
};
|
|
5737
|
+
items: {
|
|
5738
|
+
sequence: string;
|
|
5739
|
+
id: string;
|
|
5740
|
+
changed_at: string;
|
|
5741
|
+
removed: boolean;
|
|
5742
|
+
record: LocalIntelligenceRecord | null;
|
|
5743
|
+
}[];
|
|
5744
|
+
next_cursor: string;
|
|
5745
|
+
has_more: boolean;
|
|
5746
|
+
lease_seconds: number;
|
|
5747
|
+
}
|
|
5748
|
+
interface LocalBriefing {
|
|
5749
|
+
contract_version: 'basenews/1';
|
|
5750
|
+
policy_version: string;
|
|
5751
|
+
as_of: string;
|
|
5752
|
+
geography_id: string;
|
|
5753
|
+
personalized: boolean;
|
|
5754
|
+
items: LocalIntelligenceRecord[];
|
|
5755
|
+
more_available: boolean;
|
|
5756
|
+
lease_seconds: number;
|
|
5757
|
+
}
|
|
5758
|
+
interface IntelligenceRelease {
|
|
5759
|
+
package_id: string;
|
|
5760
|
+
package_revision: number;
|
|
5761
|
+
expected_revision: number;
|
|
5762
|
+
title: string;
|
|
5763
|
+
why_it_matters: string;
|
|
5764
|
+
kind: IntelligenceKind;
|
|
5765
|
+
status: IntelligenceStatus;
|
|
5766
|
+
section: IntelligenceSection;
|
|
5767
|
+
civic_importance: boolean;
|
|
5768
|
+
claim_ids: string[];
|
|
5769
|
+
geography_ids: string[];
|
|
5770
|
+
related_entity_ids: string[];
|
|
5771
|
+
issue_entity_ids: string[];
|
|
5772
|
+
topics: string[];
|
|
5773
|
+
event: IntelligenceEvent | null;
|
|
5774
|
+
actions: IntelligenceAction[];
|
|
5775
|
+
verification: IntelligenceVerification;
|
|
5776
|
+
last_verified_at: string | null;
|
|
5777
|
+
observed_at: string;
|
|
5778
|
+
effective_at: string | null;
|
|
5779
|
+
review_due_at: string;
|
|
5780
|
+
original_reporting_url: string | null;
|
|
5781
|
+
redistribution_permitted: boolean;
|
|
5782
|
+
privacy_and_consent_reviewed: boolean;
|
|
5783
|
+
license: string;
|
|
5784
|
+
reason: string;
|
|
5785
|
+
destinations: {
|
|
5786
|
+
application_id: string;
|
|
5787
|
+
publication_id: string;
|
|
5788
|
+
expires_at: string;
|
|
5789
|
+
}[];
|
|
5790
|
+
sensitivity_review: {
|
|
5791
|
+
policy_version: string;
|
|
5792
|
+
rule_ids: string[];
|
|
5793
|
+
reason: string;
|
|
5794
|
+
} | null;
|
|
5795
|
+
}
|
|
5796
|
+
interface IntelligenceReleaseReceipt {
|
|
5797
|
+
id: string;
|
|
5798
|
+
revision: number;
|
|
5799
|
+
contract_version: 'basenews/1';
|
|
5800
|
+
}
|
|
5801
|
+
/** API keys remain server-side in publication apps. Personal preference writes
|
|
5802
|
+
* use the reader's authenticated session; agents cannot impersonate a reader.
|
|
5803
|
+
* Methods retain the SDK's {data,error} contract and RequestOptions propagation.
|
|
5804
|
+
*/
|
|
5805
|
+
declare class LocalIntelligenceService extends ServiceModule {
|
|
5806
|
+
protected basePath: string;
|
|
5807
|
+
private scope;
|
|
5808
|
+
records(publication: string, params?: {
|
|
5809
|
+
cursor?: string;
|
|
5810
|
+
limit?: number;
|
|
5811
|
+
geography?: string;
|
|
5812
|
+
kind?: IntelligenceKind;
|
|
5813
|
+
}, options?: RequestOptions): Promise<ApiResponse<IntelligenceRecordPage>>;
|
|
5814
|
+
get(publication: string, record: string, options?: RequestOptions): Promise<ApiResponse<LocalIntelligenceRecord>>;
|
|
5815
|
+
changes(publication: string, params?: {
|
|
5816
|
+
cursor?: string;
|
|
5817
|
+
limit?: number;
|
|
5818
|
+
}, options?: RequestOptions): Promise<ApiResponse<IntelligenceChangePage>>;
|
|
5819
|
+
briefing(publication: string, params: {
|
|
5820
|
+
geography: string;
|
|
5821
|
+
limit?: number;
|
|
5822
|
+
personalized?: boolean;
|
|
5823
|
+
}, options?: RequestOptions): Promise<ApiResponse<LocalBriefing>>;
|
|
5824
|
+
/** Agent-safe explicit preferences: evaluated for this request and never saved. */
|
|
5825
|
+
briefingForPreferences(publication: string, input: {
|
|
5826
|
+
geography: string;
|
|
5827
|
+
preferences: LocalIntelligencePreferences;
|
|
5828
|
+
limit?: number;
|
|
5829
|
+
}, options?: RequestOptions): Promise<ApiResponse<LocalBriefing>>;
|
|
5830
|
+
preferences(publication: string, options?: RequestOptions): Promise<ApiResponse<{
|
|
5831
|
+
revision: number;
|
|
5832
|
+
preferences: LocalIntelligencePreferences;
|
|
5833
|
+
}>>;
|
|
5834
|
+
savePreferences(publication: string, expectedRevision: number, preferences: LocalIntelligencePreferences, options?: RequestOptions): Promise<ApiResponse<{
|
|
5835
|
+
revision: number;
|
|
5836
|
+
preferences: LocalIntelligencePreferences;
|
|
5837
|
+
}>>;
|
|
5838
|
+
deletePreferences(publication: string, options?: RequestOptions): Promise<ApiResponse<void>>;
|
|
5839
|
+
feedback(publication: string, record: string, recordRevision: number, outcome: CommunityValueOutcome, options?: RequestOptions): Promise<ApiResponse<{
|
|
5840
|
+
recorded: boolean;
|
|
5841
|
+
}>>;
|
|
5842
|
+
deleteFeedback(publication: string, record: string, options?: RequestOptions): Promise<ApiResponse<void>>;
|
|
5843
|
+
/** Requires a human editor with publication publish authority. */
|
|
5844
|
+
release(publication: string, input: IntelligenceRelease, idempotencyKey: string, options?: RequestOptions): Promise<ApiResponse<IntelligenceReleaseReceipt>>;
|
|
5845
|
+
withdraw(publication: string, record: string, expectedRevision: number, reason: string, options?: RequestOptions): Promise<ApiResponse<{
|
|
5846
|
+
id: string;
|
|
5847
|
+
revision: number;
|
|
5848
|
+
removed: true;
|
|
5849
|
+
}>>;
|
|
5850
|
+
}
|
|
5851
|
+
/** Apply a change batch only to a cache already scoped by application AND
|
|
5852
|
+
* publication. Lease expiry is mandatory even when no change notification arrives.
|
|
5853
|
+
* No persistence, tracking or cross-publication identity joins are performed.
|
|
5854
|
+
*/
|
|
5855
|
+
interface IntelligenceCache {
|
|
5856
|
+
scope: {
|
|
5857
|
+
application_id: string;
|
|
5858
|
+
publication_id: string;
|
|
5859
|
+
};
|
|
5860
|
+
sequence: string;
|
|
5861
|
+
records: ReadonlyMap<string, LocalIntelligenceRecord>;
|
|
5862
|
+
}
|
|
5863
|
+
declare function applyIntelligenceChanges(current: IntelligenceCache, changes: IntelligenceChangePage, now?: number): IntelligenceCache;
|
|
5864
|
+
|
|
5629
5865
|
/**
|
|
5630
5866
|
* Polls Service Module
|
|
5631
5867
|
*
|
|
@@ -8239,6 +8475,7 @@ declare class ScaleMule {
|
|
|
8239
8475
|
readonly leaderboard: LeaderboardService;
|
|
8240
8476
|
readonly listings: ListingsService;
|
|
8241
8477
|
readonly communityMaps: CommunityMapsService;
|
|
8478
|
+
readonly localIntelligence: LocalIntelligenceService;
|
|
8242
8479
|
readonly polls: PollsService;
|
|
8243
8480
|
readonly events: EventsService;
|
|
8244
8481
|
readonly graph: GraphService;
|
|
@@ -8321,4 +8558,4 @@ declare class ScaleMule {
|
|
|
8321
8558
|
getClient(): ScaleMuleClient;
|
|
8322
8559
|
}
|
|
8323
8560
|
|
|
8324
|
-
export { type AcceptQuoteInput, type AccountBalance, type AccountSwitcherPrivacy, AccountsService, type ActiveUsers, type ActivityItem, AgentAuthService, AgentModelsService, type AgentProfile, AgentProjectsService, type AgentResponse, type AgentSecurityPolicy, AgentSessionsService, type AgentSigningKey, type AgentToken, type AgentToolEntitlement, AgentToolsService, type Workspace as AgentWorkspace, AgentsService, type AggregateOptions, type AggregateResult, type AnalyticsEvent, AnalyticsService, type ApiError, type ApiKey, type ApiResponse, type Appeal, type Application, type AppointmentDepositValue, type Attachment, type Attendee, type AudioRegisterResult, AudioService, type AudioUploadViaStorageResult, type AuditLog, type AuthRegisterAgentRequest, type AuthRegisterAgentResponse, AuthService, type AuthSession, type AuthUser, type BackupCodes, BillingService, type BookingCompletionResult, BookingsService, type CacheEntry, CacheService, type CalendarEvent, type CallParticipant, type CallSession, type CatalogEntry, CatalogService, type ChatMessage, type ChatReaction, ChatService, type ClaimResult, type Client, type ClientContext, type Collection, type Comment, CommunicationService, type CommunityMapArea, type CommunityMapCanonicalArea, type CommunityMapCollection, type CommunityMapCollectionConfig, type CommunityMapComment, type CommunityMapCommentInput, type CommunityMapCommentPage, type CommunityMapConsent, type CommunityMapEditorialCollection, type CommunityMapEditorialComment, type CommunityMapEditorialFeature, type CommunityMapEditorialMedia, type CommunityMapFeature, type CommunityMapFeatureDraft, type CommunityMapFeatureQuery, type CommunityMapFeatureStatus, type CommunityMapGeometry, type CommunityMapMedia, type CommunityMapOwnSubmission, type CommunityMapOwnSubmissionPage, type CommunityMapPage, type CommunityMapPosition, type CommunityMapPrecision, type CommunityMapPrivateReport, type CommunityMapPrivateSubmission, type CommunityMapProposal, type CommunityMapPublicContent, type CommunityMapQueueQuery, type CommunityMapReactionDefinition, type CommunityMapReceipt, type CommunityMapReportInput, type CommunityMapReportReason, type CommunityMapRevision, type CommunityMapSource, type CommunityMapSubmissionInput, type CommunityMapSubmissionPolicy, type CommunityMapSubmissionStatus, type CommunityMapSubmissionUpdate, type CommunityMapView, type CommunityMapVote, CommunityMapsEditorialService, CommunityMapsGeographyService, CommunityMapsService, type CompletedPart, ComplianceService, type CompressionConfig, ConferenceService, type ConferenceSettings, type ConnectedAccount, type ConnectedAccountSubscription, type ConnectedSetupIntentResponse, type ConnectedSubscriptionListParams, type ConnectionStatus, type ContentFlag, type ContentPolicy, type Conversation, type CostReportDay, type CreateProjectInput as CreateCreatorProjectInput, type CreateFlagRequest, type CreateLeadInput, type CreatePollInput, type CreateQuoteInput, type CreateRuleRequest, type CreateSegmentRequest, type CreateSessionResponse, type CreateVariantRequest, type GenerationJob as CreatorJob, CreatorMakerService, type GenerationOutput as CreatorOutput, type CreatorProject, type CreatorUsage, type Credential, type CredentialScope, type Customer, type CustomerStats, type DataAccessPolicy, type DataExport, DataService, type DataSource, type DeadLetterJob, type DecisionBatchItem, type DecisionBatchResult, type DecisionEvaluateOptions, type DecisionOutcome, type DecisionProposedAction, type DecisionReceipt, type DecisionResult, type DecisionTraceLevel, type DecisionVersions, DecisionsService, type DeviceInfo, type DirectoryUser, type DirectoryUserDetail, type DirectoryUsersListResponse, type Document, type ErrorCode, ErrorCodes, type EventAggregation, EventsService, type FileInfo, type FileStatus, type FlagAuditEntry, type FlagCheck, type FlagCondition, FlagContentService, type FlagDefinition, type FlagDetail, type FlagEnvironment, type FlagEvaluation, type FlagSegment, type FlagVariant, FlagsService, type FollowStatus, type FunctionExecution, type FunctionMetrics, FunctionsService, type Funnel, type FunnelConversion, type GdprRequest, type GenerateInput, type GrantInfo, type GraphEdge, type GraphNode, GraphService, IdentityService, type IdentityType, type IncomingRequestLike, type Invoice, type JobExecution, type JobStats, type JoinCallResponse, type KnownAccount, type KnownAccountDisplay, LEGACY_ANONYMOUS_ID_KEYS, type Lead, type Leaderboard, type LeaderboardEntry, LeaderboardService, LeadsService, type Like, type ListNotificationsParams, type Listing, ListingsService, type LogEntry, type LogInput, type LogQueryParams, type LogQueryResponse, type LogRecord, LoggerService, type LoginActivitySummary, type LoginDeviceInfo, type LoginHistoryEntry, type LoginRiskInfo, MEDIA_PRESETS, type MediaAsset, type MediaCaptureSession, type MediaKind, type MediaManifest, type MediaManifestOptions, type MediaPolicy, type MediaPreset, type MediaPresetSpec, MediaService, type MediaUploadEvent, type MediaUploadOptions, type MediaUploadPhase, type MediaUploadResult, type MessageCallback, type MessagePin, type MessageStatus, type MetricDataPoint, type MfaStatus, type Model, type ModelEntitlement, type ModelPricing, type ModelProvider, type UsageSummary as ModelUsageSummary, type MultipartCompleteResponse, type MultipartConfig, type MultipartPartUrl, type MultipartPartUrlsResponse, type MultipartStartResponse, type NetworkClass, type Notification, type NotificationListResponse, NotificationsService, type OAuthProvider, type OAuthUrl, OrchestratorService, PHOTO_BREAKPOINTS, type PaginatedResponse, type PaginationMetadata, type PaginationParams, type PartResult, type PartUrl, type Participant, type Payment, type PaymentListParams, type PaymentMethod, type PaymentStatusResponse, type Payout, type PayoutSchedule, type PermissionCheck, type PermissionMatrix, PermissionsService, type PhotoInfo, PhotoService, type PinnedMessagesResponse, type Pipeline, type PipelineVersion, type Policy, type Poll, type PollBallot, type PollChoice, type PollChoiceInput, type PollListOptions, type PollMedia, type PollMediaKind, type PollStatus, PollsService, type PresenceCallback, type PresenceEvent, type PresignedUploadResponse, type Price, type Product, type Project, type ProjectDocument, type ProjectGrant, type ProjectMember, type PushApiFetcher, type PushPreferences, type PushSettings, type PushSubscriptionInfo, type PushToken, type PushTokenAssociationResult, type PushTopic, type QueryFilter, type QueryOptions, type QuerySort, type QueueJob, QueueService, type Quote, type QuoteDeposit, type QuoteState, type ReadStatus, RealtimeService, type ReceiptVerification, type RedeemResult, type ReferralAnalytics, type ReferralCampaign, type ReferralProfile, type ReferralStats, ReferralsService, type Refund, type RegisterAgentRequest, type RegisterAgentResponse, type RegisterPushTokenData, type RequestOptions, type ResolvedReferral, type ResumeSession, type Role, type RuntimeTemplate, type RuntimeTemplateVersion, type S3MultipartOptions, type S3MultipartResult, type S3SingleUploadOptions, type S3SingleUploadResult, type S3UploadProgress, STORAGE_KEYS, ScaleMule, ScaleMuleClient, type ScaleMuleConfig, type SchedulerJob, SchedulerService, type SearchResult, SearchService, type SearchUsersParams, type SecurityLayers, type ServerlessFunction, type ServiceHealth, ServiceModule, type Session, type SessionArtifact, type SessionInfo, type SessionLog, type SessionPoolEntry, type Severity, type ShareLink, type ShortestPathResult, type SignedUrlResponse, type SocialContentProjection, type SocialContentProjectionInput, type SocialDiscoveryCreatorInput, type SocialPolicyAction, type SocialPolicyBatchDecisionItem, type SocialPolicyBatchDecisionRequest, type SocialPolicyBatchDecisionResponse, type SocialPolicyBatchDecisionTarget, type SocialPolicyBlockRequest, type SocialPolicyContactRequest, type SocialPolicyContactRequestListItem, type SocialPolicyContactRequestQuery, type SocialPolicyContactRequestRequest, type SocialPolicyContext, type SocialPolicyDecision, type SocialPolicyDecisionLimits, type SocialPolicyDecisionRequest, type SocialPolicyDecisionResponse, type SocialPolicyIdentity, type SocialPolicyIdentityType, type SocialPolicyMuteRequest, type SocialPolicyPolicyPack, type SocialPolicyRelationship, type SocialPolicyRelationshipQuery, type SocialPolicyRelationshipRequest, type SocialPolicyReportRequest, SocialPolicyService, type SocialPolicySettings, type SocialPolicyUnblockRequest, type SocialPolicyUpdateSettingsRequest, type SocialPost, SocialService, type SocialUser, type SsoConfig, type StatusCallback, type StorageAdapter, StorageService, type StorageSettings, type StrategyResult, type StylePreset, type SubmitResult, type Subscription, type TargetingRule, type Task, type TaskAttempt, type TaskTransition, type Team, type TeamInvitation, type TeamMember, TeamsService, type TelemetryPayload, type Tool, type ToolCapability, type ToolIntegration, type TopEvent, type TotpSetup, type Transaction, type TransactionListParams, type TransactionSummary, type TransactionSummaryParams, type Transfer, type TransformOptions, type TransformResult, type TraversalResult, type TtsAccessMode, type TtsAudioInfo, type TtsJobStatus, type TtsListVoicesParams, TtsService, type TtsSpeechMetadata, type TtsSpeechProfile, type TtsSynthesizeParams, type TtsSynthesizeQueuedResult, type TtsSynthesizeReadyResult, type TtsSynthesizeResult, type TtsVoice, type TtsVoicesResponse, type UnreadCountResponse, type UpdateFlagRequest, type UpdatePollInput, type UpdateRuleRequest, type UpdateSegmentRequest, type UpdateVariantRequest, type UploadCompleteResponse, type UploadEngineConfig, type UploadFailureReport, type UploadFailureReportResponse, type UploadOptions, type UploadPlan, UploadResumeStore, type UploadStrategy, UploadTelemetry, type UploadTelemetryConfig, type UploadTelemetryEvent, type UpsertEnvironmentRequest, type UsageRecord, type UsageSummary$1 as UsageSummary, type UserRank, type VideoInfo, VideoService, type VideoUploadOptions, type VoteState, WEB_PUSH_SERVICE_WORKER, WebPushManager, type WebPushManagerOptions, type WebPushSubscriptionData, type Webhook, WebhooksService, type WebrtcStats, type Workflow, type WorkflowExecution, type Workspace$1 as Workspace, type WorkspaceInvitation, type WorkspaceMember, WorkspacesService, buildClientContextHeaders, calculateTotalParts, canPerform, createUploadPlan, ScaleMule as default, detectNetworkClass, ensureAnonymousId, extractClientContext, generateAnonymousId, generateUploadSessionId, getMeasuredBandwidthMbps, getPartRange, hasMinRoleLevel, pollSharePercent, pollVoterKey, prepareCommunityMapAttachment, readAnonymousId, resolveStrategy, startMediaCapture, uploadMultipartToS3, uploadSingleToS3, validateIP };
|
|
8561
|
+
export { type AcceptQuoteInput, type AccountBalance, type AccountSwitcherPrivacy, AccountsService, type ActiveUsers, type ActivityItem, AgentAuthService, AgentModelsService, type AgentProfile, AgentProjectsService, type AgentResponse, type AgentSecurityPolicy, AgentSessionsService, type AgentSigningKey, type AgentToken, type AgentToolEntitlement, AgentToolsService, type Workspace as AgentWorkspace, AgentsService, type AggregateOptions, type AggregateResult, type AnalyticsEvent, AnalyticsService, type ApiError, type ApiKey, type ApiResponse, type Appeal, type Application, type AppointmentDepositValue, type Attachment, type Attendee, type AudioRegisterResult, AudioService, type AudioUploadViaStorageResult, type AuditLog, type AuthRegisterAgentRequest, type AuthRegisterAgentResponse, AuthService, type AuthSession, type AuthUser, type BackupCodes, BillingService, type BookingCompletionResult, BookingsService, type CacheEntry, CacheService, type CalendarEvent, type CallParticipant, type CallSession, type CatalogEntry, CatalogService, type ChatMessage, type ChatReaction, ChatService, type ClaimResult, type Client, type ClientContext, type Collection, type Comment, CommunicationService, type CommunityMapArea, type CommunityMapCanonicalArea, type CommunityMapCollection, type CommunityMapCollectionConfig, type CommunityMapComment, type CommunityMapCommentInput, type CommunityMapCommentPage, type CommunityMapConsent, type CommunityMapEditorialCollection, type CommunityMapEditorialComment, type CommunityMapEditorialFeature, type CommunityMapEditorialMedia, type CommunityMapFeature, type CommunityMapFeatureDraft, type CommunityMapFeatureQuery, type CommunityMapFeatureStatus, type CommunityMapGeometry, type CommunityMapMedia, type CommunityMapOwnSubmission, type CommunityMapOwnSubmissionPage, type CommunityMapPage, type CommunityMapPosition, type CommunityMapPrecision, type CommunityMapPrivateReport, type CommunityMapPrivateSubmission, type CommunityMapProposal, type CommunityMapPublicContent, type CommunityMapQueueQuery, type CommunityMapReactionDefinition, type CommunityMapReceipt, type CommunityMapReportInput, type CommunityMapReportReason, type CommunityMapRevision, type CommunityMapSource, type CommunityMapSubmissionInput, type CommunityMapSubmissionPolicy, type CommunityMapSubmissionStatus, type CommunityMapSubmissionUpdate, type CommunityMapView, type CommunityMapVote, CommunityMapsEditorialService, CommunityMapsGeographyService, CommunityMapsService, type CommunityValueOutcome, type CompletedPart, ComplianceService, type CompressionConfig, ConferenceService, type ConferenceSettings, type ConnectedAccount, type ConnectedAccountSubscription, type ConnectedSetupIntentResponse, type ConnectedSubscriptionListParams, type ConnectionStatus, type ContentFlag, type ContentPolicy, type Conversation, type CostReportDay, type CreateProjectInput as CreateCreatorProjectInput, type CreateFlagRequest, type CreateLeadInput, type CreatePollInput, type CreateQuoteInput, type CreateRuleRequest, type CreateSegmentRequest, type CreateSessionResponse, type CreateVariantRequest, type GenerationJob as CreatorJob, CreatorMakerService, type GenerationOutput as CreatorOutput, type CreatorProject, type CreatorUsage, type Credential, type CredentialScope, type Customer, type CustomerStats, type DataAccessPolicy, type DataExport, DataService, type DataSource, type DeadLetterJob, type DecisionBatchItem, type DecisionBatchResult, type DecisionEvaluateOptions, type DecisionOutcome, type DecisionProposedAction, type DecisionReceipt, type DecisionResult, type DecisionTraceLevel, type DecisionVersions, DecisionsService, type DeviceInfo, type DirectoryUser, type DirectoryUserDetail, type DirectoryUsersListResponse, type Document, type ErrorCode, ErrorCodes, type EventAggregation, EventsService, type FileInfo, type FileStatus, type FlagAuditEntry, type FlagCheck, type FlagCondition, FlagContentService, type FlagDefinition, type FlagDetail, type FlagEnvironment, type FlagEvaluation, type FlagSegment, type FlagVariant, FlagsService, type FollowStatus, type FunctionExecution, type FunctionMetrics, FunctionsService, type Funnel, type FunnelConversion, type GdprRequest, type GenerateInput, type GrantInfo, type GraphEdge, type GraphNode, GraphService, IdentityService, type IdentityType, type IncomingRequestLike, type IntelligenceAction, type IntelligenceCache, type IntelligenceChangePage, type IntelligenceClaim, type IntelligenceEvent, type IntelligenceKind, type IntelligenceRecordPage, type IntelligenceRelease, type IntelligenceReleaseReceipt, type IntelligenceSection, type IntelligenceSource, type IntelligenceStatus, type IntelligenceVerification, type Invoice, type JobExecution, type JobStats, type JoinCallResponse, type KnownAccount, type KnownAccountDisplay, LEGACY_ANONYMOUS_ID_KEYS, type Lead, type Leaderboard, type LeaderboardEntry, LeaderboardService, LeadsService, type Like, type ListNotificationsParams, type Listing, ListingsService, type LocalBriefing, type LocalIntelligencePreferences, type LocalIntelligenceRecord, LocalIntelligenceService, type LogEntry, type LogInput, type LogQueryParams, type LogQueryResponse, type LogRecord, LoggerService, type LoginActivitySummary, type LoginDeviceInfo, type LoginHistoryEntry, type LoginRiskInfo, MEDIA_PRESETS, type MediaAsset, type MediaCaptureSession, type MediaKind, type MediaManifest, type MediaManifestOptions, type MediaPolicy, type MediaPreset, type MediaPresetSpec, MediaService, type MediaUploadEvent, type MediaUploadOptions, type MediaUploadPhase, type MediaUploadResult, type MessageCallback, type MessagePin, type MessageStatus, type MetricDataPoint, type MfaStatus, type Model, type ModelEntitlement, type ModelPricing, type ModelProvider, type UsageSummary as ModelUsageSummary, type MultipartCompleteResponse, type MultipartConfig, type MultipartPartUrl, type MultipartPartUrlsResponse, type MultipartStartResponse, type NetworkClass, type Notification, type NotificationListResponse, NotificationsService, type OAuthProvider, type OAuthUrl, OrchestratorService, PHOTO_BREAKPOINTS, type PaginatedResponse, type PaginationMetadata, type PaginationParams, type PartResult, type PartUrl, type Participant, type Payment, type PaymentListParams, type PaymentMethod, type PaymentStatusResponse, type Payout, type PayoutSchedule, type PermissionCheck, type PermissionMatrix, PermissionsService, type PhotoInfo, PhotoService, type PinnedMessagesResponse, type Pipeline, type PipelineVersion, type Policy, type Poll, type PollBallot, type PollChoice, type PollChoiceInput, type PollListOptions, type PollMedia, type PollMediaKind, type PollStatus, PollsService, type PresenceCallback, type PresenceEvent, type PresignedUploadResponse, type Price, type Product, type Project, type ProjectDocument, type ProjectGrant, type ProjectMember, type PushApiFetcher, type PushPreferences, type PushSettings, type PushSubscriptionInfo, type PushToken, type PushTokenAssociationResult, type PushTopic, type QueryFilter, type QueryOptions, type QuerySort, type QueueJob, QueueService, type Quote, type QuoteDeposit, type QuoteState, type ReadStatus, RealtimeService, type ReceiptVerification, type RedeemResult, type ReferralAnalytics, type ReferralCampaign, type ReferralProfile, type ReferralStats, ReferralsService, type Refund, type RegisterAgentRequest, type RegisterAgentResponse, type RegisterPushTokenData, type RequestOptions, type ResolvedReferral, type ResumeSession, type Role, type RuntimeTemplate, type RuntimeTemplateVersion, type S3MultipartOptions, type S3MultipartResult, type S3SingleUploadOptions, type S3SingleUploadResult, type S3UploadProgress, STORAGE_KEYS, ScaleMule, ScaleMuleClient, type ScaleMuleConfig, type SchedulerJob, SchedulerService, type SearchResult, SearchService, type SearchUsersParams, type SecurityLayers, type ServerlessFunction, type ServiceHealth, ServiceModule, type Session, type SessionArtifact, type SessionInfo, type SessionLog, type SessionPoolEntry, type Severity, type ShareLink, type ShortestPathResult, type SignedUrlResponse, type SocialContentProjection, type SocialContentProjectionInput, type SocialDiscoveryCreatorInput, type SocialPolicyAction, type SocialPolicyBatchDecisionItem, type SocialPolicyBatchDecisionRequest, type SocialPolicyBatchDecisionResponse, type SocialPolicyBatchDecisionTarget, type SocialPolicyBlockRequest, type SocialPolicyContactRequest, type SocialPolicyContactRequestListItem, type SocialPolicyContactRequestQuery, type SocialPolicyContactRequestRequest, type SocialPolicyContext, type SocialPolicyDecision, type SocialPolicyDecisionLimits, type SocialPolicyDecisionRequest, type SocialPolicyDecisionResponse, type SocialPolicyIdentity, type SocialPolicyIdentityType, type SocialPolicyMuteRequest, type SocialPolicyPolicyPack, type SocialPolicyRelationship, type SocialPolicyRelationshipQuery, type SocialPolicyRelationshipRequest, type SocialPolicyReportRequest, SocialPolicyService, type SocialPolicySettings, type SocialPolicyUnblockRequest, type SocialPolicyUpdateSettingsRequest, type SocialPost, SocialService, type SocialUser, type SsoConfig, type StatusCallback, type StorageAdapter, StorageService, type StorageSettings, type StrategyResult, type StylePreset, type SubmitResult, type Subscription, type TargetingRule, type Task, type TaskAttempt, type TaskTransition, type Team, type TeamInvitation, type TeamMember, TeamsService, type TelemetryPayload, type Tool, type ToolCapability, type ToolIntegration, type TopEvent, type TotpSetup, type Transaction, type TransactionListParams, type TransactionSummary, type TransactionSummaryParams, type Transfer, type TransformOptions, type TransformResult, type TraversalResult, type TtsAccessMode, type TtsAudioInfo, type TtsJobStatus, type TtsListVoicesParams, TtsService, type TtsSpeechMetadata, type TtsSpeechProfile, type TtsSynthesizeParams, type TtsSynthesizeQueuedResult, type TtsSynthesizeReadyResult, type TtsSynthesizeResult, type TtsVoice, type TtsVoicesResponse, type UnreadCountResponse, type UpdateFlagRequest, type UpdatePollInput, type UpdateRuleRequest, type UpdateSegmentRequest, type UpdateVariantRequest, type UploadCompleteResponse, type UploadEngineConfig, type UploadFailureReport, type UploadFailureReportResponse, type UploadOptions, type UploadPlan, UploadResumeStore, type UploadStrategy, UploadTelemetry, type UploadTelemetryConfig, type UploadTelemetryEvent, type UpsertEnvironmentRequest, type UsageRecord, type UsageSummary$1 as UsageSummary, type UserRank, type VideoInfo, VideoService, type VideoUploadOptions, type VoteState, WEB_PUSH_SERVICE_WORKER, WebPushManager, type WebPushManagerOptions, type WebPushSubscriptionData, type Webhook, WebhooksService, type WebrtcStats, type Workflow, type WorkflowExecution, type Workspace$1 as Workspace, type WorkspaceInvitation, type WorkspaceMember, WorkspacesService, applyIntelligenceChanges, buildClientContextHeaders, calculateTotalParts, canPerform, createUploadPlan, ScaleMule as default, detectNetworkClass, ensureAnonymousId, extractClientContext, generateAnonymousId, generateUploadSessionId, getMeasuredBandwidthMbps, getPartRange, hasMinRoleLevel, pollSharePercent, pollVoterKey, prepareCommunityMapAttachment, readAnonymousId, resolveStrategy, startMediaCapture, uploadMultipartToS3, uploadSingleToS3, validateIP };
|
package/dist/index.d.ts
CHANGED
|
@@ -5626,6 +5626,242 @@ declare class CommunityMapsGeographyService extends ServiceModule {
|
|
|
5626
5626
|
}>>;
|
|
5627
5627
|
}
|
|
5628
5628
|
|
|
5629
|
+
/** BaseNews delivery through the existing News service and ScaleMule identity.
|
|
5630
|
+
* Records are evidence-backed projections; a release is not an article.
|
|
5631
|
+
* Honor refresh_after and removals. Never use this API as a source-text archive.
|
|
5632
|
+
*/
|
|
5633
|
+
|
|
5634
|
+
type IntelligenceKind = 'event' | 'development' | 'community_story' | 'opportunity' | 'public_notice';
|
|
5635
|
+
type IntelligenceStatus = 'proposed' | 'approved' | 'scheduled' | 'ongoing' | 'completed' | 'canceled' | 'postponed' | 'disputed';
|
|
5636
|
+
type IntelligenceVerification = 'unverified' | 'community_submitted' | 'supported' | 'officially_confirmed' | 'independently_verified' | 'disputed';
|
|
5637
|
+
type IntelligenceSection = 'important' | 'around_you' | 'people' | 'discover' | 'participate';
|
|
5638
|
+
type CommunityValueOutcome = 'understand' | 'discover' | 'decide' | 'participate' | 'not_relevant';
|
|
5639
|
+
interface IntelligenceEvent {
|
|
5640
|
+
starts_at: string;
|
|
5641
|
+
ends_at: string;
|
|
5642
|
+
time_zone: string;
|
|
5643
|
+
place_entity_id: string | null;
|
|
5644
|
+
organizer_entity_id: string | null;
|
|
5645
|
+
series_entity_id: string | null;
|
|
5646
|
+
cost: string | null;
|
|
5647
|
+
accessibility: string | null;
|
|
5648
|
+
}
|
|
5649
|
+
interface IntelligenceAction {
|
|
5650
|
+
label: string;
|
|
5651
|
+
url: string;
|
|
5652
|
+
deadline: string | null;
|
|
5653
|
+
}
|
|
5654
|
+
interface IntelligenceSource {
|
|
5655
|
+
id: string;
|
|
5656
|
+
title: string;
|
|
5657
|
+
publisher: string;
|
|
5658
|
+
url: string;
|
|
5659
|
+
published_at: string | null;
|
|
5660
|
+
retrieved_at: string | null;
|
|
5661
|
+
kind: string;
|
|
5662
|
+
distance: string;
|
|
5663
|
+
interested_party: boolean | null;
|
|
5664
|
+
}
|
|
5665
|
+
interface IntelligenceClaim {
|
|
5666
|
+
id: string;
|
|
5667
|
+
text: string;
|
|
5668
|
+
verification: 'UNVERIFIED' | 'SUPPORTED' | 'VERIFIED' | 'DISPUTED';
|
|
5669
|
+
attribution: string | null;
|
|
5670
|
+
evidence: {
|
|
5671
|
+
source_id: string;
|
|
5672
|
+
role: 'DIRECT' | 'CORROBORATING' | 'CONTEXT' | 'CONTRADICTING' | 'ATTRIBUTED_CLAIM';
|
|
5673
|
+
}[];
|
|
5674
|
+
}
|
|
5675
|
+
interface LocalIntelligenceRecord {
|
|
5676
|
+
contract_version: 'basenews/1';
|
|
5677
|
+
id: string;
|
|
5678
|
+
revision: number;
|
|
5679
|
+
title: string;
|
|
5680
|
+
why_it_matters: string;
|
|
5681
|
+
kind: IntelligenceKind;
|
|
5682
|
+
status: IntelligenceStatus;
|
|
5683
|
+
section: IntelligenceSection;
|
|
5684
|
+
civic_importance: boolean;
|
|
5685
|
+
geography_ids: string[];
|
|
5686
|
+
related_entity_ids: string[];
|
|
5687
|
+
issue_entity_ids: string[];
|
|
5688
|
+
topics: string[];
|
|
5689
|
+
event: IntelligenceEvent | null;
|
|
5690
|
+
actions: IntelligenceAction[];
|
|
5691
|
+
claims: IntelligenceClaim[];
|
|
5692
|
+
sources: IntelligenceSource[];
|
|
5693
|
+
verification: IntelligenceVerification;
|
|
5694
|
+
last_verified_at: string | null;
|
|
5695
|
+
observed_at: string;
|
|
5696
|
+
effective_at: string | null;
|
|
5697
|
+
review_due_at: string;
|
|
5698
|
+
published_at: string;
|
|
5699
|
+
original_reporting_url: string | null;
|
|
5700
|
+
original_byline: string;
|
|
5701
|
+
originating_publication_id: string;
|
|
5702
|
+
license: string;
|
|
5703
|
+
supersedes_revision: number | null;
|
|
5704
|
+
canonical_references: {
|
|
5705
|
+
reporting_package_id: string;
|
|
5706
|
+
reporting_revision: number;
|
|
5707
|
+
event_id: string | null;
|
|
5708
|
+
event_version: number | null;
|
|
5709
|
+
};
|
|
5710
|
+
/** Refresh or remove the record after this time. Access may have been revoked. */
|
|
5711
|
+
refresh_after: string;
|
|
5712
|
+
relevance_reasons?: string[];
|
|
5713
|
+
}
|
|
5714
|
+
interface LocalIntelligencePreferences {
|
|
5715
|
+
personalized: boolean;
|
|
5716
|
+
geography_ids: string[];
|
|
5717
|
+
topic_codes: string[];
|
|
5718
|
+
entity_ids: string[];
|
|
5719
|
+
issue_ids: string[];
|
|
5720
|
+
record_ids: string[];
|
|
5721
|
+
}
|
|
5722
|
+
interface IntelligenceRecordPage {
|
|
5723
|
+
contract_version: 'basenews/1';
|
|
5724
|
+
items: LocalIntelligenceRecord[];
|
|
5725
|
+
next_cursor: string | null;
|
|
5726
|
+
/** Keep the FIRST page's checkpoint while bootstrapping the inventory. */
|
|
5727
|
+
changes_cursor: string;
|
|
5728
|
+
/** Initialize IntelligenceCache.sequence from the FIRST page's value. */
|
|
5729
|
+
changes_sequence: string;
|
|
5730
|
+
}
|
|
5731
|
+
interface IntelligenceChangePage {
|
|
5732
|
+
contract_version: 'basenews/1';
|
|
5733
|
+
scope: {
|
|
5734
|
+
application_id: string;
|
|
5735
|
+
publication_id: string;
|
|
5736
|
+
};
|
|
5737
|
+
items: {
|
|
5738
|
+
sequence: string;
|
|
5739
|
+
id: string;
|
|
5740
|
+
changed_at: string;
|
|
5741
|
+
removed: boolean;
|
|
5742
|
+
record: LocalIntelligenceRecord | null;
|
|
5743
|
+
}[];
|
|
5744
|
+
next_cursor: string;
|
|
5745
|
+
has_more: boolean;
|
|
5746
|
+
lease_seconds: number;
|
|
5747
|
+
}
|
|
5748
|
+
interface LocalBriefing {
|
|
5749
|
+
contract_version: 'basenews/1';
|
|
5750
|
+
policy_version: string;
|
|
5751
|
+
as_of: string;
|
|
5752
|
+
geography_id: string;
|
|
5753
|
+
personalized: boolean;
|
|
5754
|
+
items: LocalIntelligenceRecord[];
|
|
5755
|
+
more_available: boolean;
|
|
5756
|
+
lease_seconds: number;
|
|
5757
|
+
}
|
|
5758
|
+
interface IntelligenceRelease {
|
|
5759
|
+
package_id: string;
|
|
5760
|
+
package_revision: number;
|
|
5761
|
+
expected_revision: number;
|
|
5762
|
+
title: string;
|
|
5763
|
+
why_it_matters: string;
|
|
5764
|
+
kind: IntelligenceKind;
|
|
5765
|
+
status: IntelligenceStatus;
|
|
5766
|
+
section: IntelligenceSection;
|
|
5767
|
+
civic_importance: boolean;
|
|
5768
|
+
claim_ids: string[];
|
|
5769
|
+
geography_ids: string[];
|
|
5770
|
+
related_entity_ids: string[];
|
|
5771
|
+
issue_entity_ids: string[];
|
|
5772
|
+
topics: string[];
|
|
5773
|
+
event: IntelligenceEvent | null;
|
|
5774
|
+
actions: IntelligenceAction[];
|
|
5775
|
+
verification: IntelligenceVerification;
|
|
5776
|
+
last_verified_at: string | null;
|
|
5777
|
+
observed_at: string;
|
|
5778
|
+
effective_at: string | null;
|
|
5779
|
+
review_due_at: string;
|
|
5780
|
+
original_reporting_url: string | null;
|
|
5781
|
+
redistribution_permitted: boolean;
|
|
5782
|
+
privacy_and_consent_reviewed: boolean;
|
|
5783
|
+
license: string;
|
|
5784
|
+
reason: string;
|
|
5785
|
+
destinations: {
|
|
5786
|
+
application_id: string;
|
|
5787
|
+
publication_id: string;
|
|
5788
|
+
expires_at: string;
|
|
5789
|
+
}[];
|
|
5790
|
+
sensitivity_review: {
|
|
5791
|
+
policy_version: string;
|
|
5792
|
+
rule_ids: string[];
|
|
5793
|
+
reason: string;
|
|
5794
|
+
} | null;
|
|
5795
|
+
}
|
|
5796
|
+
interface IntelligenceReleaseReceipt {
|
|
5797
|
+
id: string;
|
|
5798
|
+
revision: number;
|
|
5799
|
+
contract_version: 'basenews/1';
|
|
5800
|
+
}
|
|
5801
|
+
/** API keys remain server-side in publication apps. Personal preference writes
|
|
5802
|
+
* use the reader's authenticated session; agents cannot impersonate a reader.
|
|
5803
|
+
* Methods retain the SDK's {data,error} contract and RequestOptions propagation.
|
|
5804
|
+
*/
|
|
5805
|
+
declare class LocalIntelligenceService extends ServiceModule {
|
|
5806
|
+
protected basePath: string;
|
|
5807
|
+
private scope;
|
|
5808
|
+
records(publication: string, params?: {
|
|
5809
|
+
cursor?: string;
|
|
5810
|
+
limit?: number;
|
|
5811
|
+
geography?: string;
|
|
5812
|
+
kind?: IntelligenceKind;
|
|
5813
|
+
}, options?: RequestOptions): Promise<ApiResponse<IntelligenceRecordPage>>;
|
|
5814
|
+
get(publication: string, record: string, options?: RequestOptions): Promise<ApiResponse<LocalIntelligenceRecord>>;
|
|
5815
|
+
changes(publication: string, params?: {
|
|
5816
|
+
cursor?: string;
|
|
5817
|
+
limit?: number;
|
|
5818
|
+
}, options?: RequestOptions): Promise<ApiResponse<IntelligenceChangePage>>;
|
|
5819
|
+
briefing(publication: string, params: {
|
|
5820
|
+
geography: string;
|
|
5821
|
+
limit?: number;
|
|
5822
|
+
personalized?: boolean;
|
|
5823
|
+
}, options?: RequestOptions): Promise<ApiResponse<LocalBriefing>>;
|
|
5824
|
+
/** Agent-safe explicit preferences: evaluated for this request and never saved. */
|
|
5825
|
+
briefingForPreferences(publication: string, input: {
|
|
5826
|
+
geography: string;
|
|
5827
|
+
preferences: LocalIntelligencePreferences;
|
|
5828
|
+
limit?: number;
|
|
5829
|
+
}, options?: RequestOptions): Promise<ApiResponse<LocalBriefing>>;
|
|
5830
|
+
preferences(publication: string, options?: RequestOptions): Promise<ApiResponse<{
|
|
5831
|
+
revision: number;
|
|
5832
|
+
preferences: LocalIntelligencePreferences;
|
|
5833
|
+
}>>;
|
|
5834
|
+
savePreferences(publication: string, expectedRevision: number, preferences: LocalIntelligencePreferences, options?: RequestOptions): Promise<ApiResponse<{
|
|
5835
|
+
revision: number;
|
|
5836
|
+
preferences: LocalIntelligencePreferences;
|
|
5837
|
+
}>>;
|
|
5838
|
+
deletePreferences(publication: string, options?: RequestOptions): Promise<ApiResponse<void>>;
|
|
5839
|
+
feedback(publication: string, record: string, recordRevision: number, outcome: CommunityValueOutcome, options?: RequestOptions): Promise<ApiResponse<{
|
|
5840
|
+
recorded: boolean;
|
|
5841
|
+
}>>;
|
|
5842
|
+
deleteFeedback(publication: string, record: string, options?: RequestOptions): Promise<ApiResponse<void>>;
|
|
5843
|
+
/** Requires a human editor with publication publish authority. */
|
|
5844
|
+
release(publication: string, input: IntelligenceRelease, idempotencyKey: string, options?: RequestOptions): Promise<ApiResponse<IntelligenceReleaseReceipt>>;
|
|
5845
|
+
withdraw(publication: string, record: string, expectedRevision: number, reason: string, options?: RequestOptions): Promise<ApiResponse<{
|
|
5846
|
+
id: string;
|
|
5847
|
+
revision: number;
|
|
5848
|
+
removed: true;
|
|
5849
|
+
}>>;
|
|
5850
|
+
}
|
|
5851
|
+
/** Apply a change batch only to a cache already scoped by application AND
|
|
5852
|
+
* publication. Lease expiry is mandatory even when no change notification arrives.
|
|
5853
|
+
* No persistence, tracking or cross-publication identity joins are performed.
|
|
5854
|
+
*/
|
|
5855
|
+
interface IntelligenceCache {
|
|
5856
|
+
scope: {
|
|
5857
|
+
application_id: string;
|
|
5858
|
+
publication_id: string;
|
|
5859
|
+
};
|
|
5860
|
+
sequence: string;
|
|
5861
|
+
records: ReadonlyMap<string, LocalIntelligenceRecord>;
|
|
5862
|
+
}
|
|
5863
|
+
declare function applyIntelligenceChanges(current: IntelligenceCache, changes: IntelligenceChangePage, now?: number): IntelligenceCache;
|
|
5864
|
+
|
|
5629
5865
|
/**
|
|
5630
5866
|
* Polls Service Module
|
|
5631
5867
|
*
|
|
@@ -8239,6 +8475,7 @@ declare class ScaleMule {
|
|
|
8239
8475
|
readonly leaderboard: LeaderboardService;
|
|
8240
8476
|
readonly listings: ListingsService;
|
|
8241
8477
|
readonly communityMaps: CommunityMapsService;
|
|
8478
|
+
readonly localIntelligence: LocalIntelligenceService;
|
|
8242
8479
|
readonly polls: PollsService;
|
|
8243
8480
|
readonly events: EventsService;
|
|
8244
8481
|
readonly graph: GraphService;
|
|
@@ -8321,4 +8558,4 @@ declare class ScaleMule {
|
|
|
8321
8558
|
getClient(): ScaleMuleClient;
|
|
8322
8559
|
}
|
|
8323
8560
|
|
|
8324
|
-
export { type AcceptQuoteInput, type AccountBalance, type AccountSwitcherPrivacy, AccountsService, type ActiveUsers, type ActivityItem, AgentAuthService, AgentModelsService, type AgentProfile, AgentProjectsService, type AgentResponse, type AgentSecurityPolicy, AgentSessionsService, type AgentSigningKey, type AgentToken, type AgentToolEntitlement, AgentToolsService, type Workspace as AgentWorkspace, AgentsService, type AggregateOptions, type AggregateResult, type AnalyticsEvent, AnalyticsService, type ApiError, type ApiKey, type ApiResponse, type Appeal, type Application, type AppointmentDepositValue, type Attachment, type Attendee, type AudioRegisterResult, AudioService, type AudioUploadViaStorageResult, type AuditLog, type AuthRegisterAgentRequest, type AuthRegisterAgentResponse, AuthService, type AuthSession, type AuthUser, type BackupCodes, BillingService, type BookingCompletionResult, BookingsService, type CacheEntry, CacheService, type CalendarEvent, type CallParticipant, type CallSession, type CatalogEntry, CatalogService, type ChatMessage, type ChatReaction, ChatService, type ClaimResult, type Client, type ClientContext, type Collection, type Comment, CommunicationService, type CommunityMapArea, type CommunityMapCanonicalArea, type CommunityMapCollection, type CommunityMapCollectionConfig, type CommunityMapComment, type CommunityMapCommentInput, type CommunityMapCommentPage, type CommunityMapConsent, type CommunityMapEditorialCollection, type CommunityMapEditorialComment, type CommunityMapEditorialFeature, type CommunityMapEditorialMedia, type CommunityMapFeature, type CommunityMapFeatureDraft, type CommunityMapFeatureQuery, type CommunityMapFeatureStatus, type CommunityMapGeometry, type CommunityMapMedia, type CommunityMapOwnSubmission, type CommunityMapOwnSubmissionPage, type CommunityMapPage, type CommunityMapPosition, type CommunityMapPrecision, type CommunityMapPrivateReport, type CommunityMapPrivateSubmission, type CommunityMapProposal, type CommunityMapPublicContent, type CommunityMapQueueQuery, type CommunityMapReactionDefinition, type CommunityMapReceipt, type CommunityMapReportInput, type CommunityMapReportReason, type CommunityMapRevision, type CommunityMapSource, type CommunityMapSubmissionInput, type CommunityMapSubmissionPolicy, type CommunityMapSubmissionStatus, type CommunityMapSubmissionUpdate, type CommunityMapView, type CommunityMapVote, CommunityMapsEditorialService, CommunityMapsGeographyService, CommunityMapsService, type CompletedPart, ComplianceService, type CompressionConfig, ConferenceService, type ConferenceSettings, type ConnectedAccount, type ConnectedAccountSubscription, type ConnectedSetupIntentResponse, type ConnectedSubscriptionListParams, type ConnectionStatus, type ContentFlag, type ContentPolicy, type Conversation, type CostReportDay, type CreateProjectInput as CreateCreatorProjectInput, type CreateFlagRequest, type CreateLeadInput, type CreatePollInput, type CreateQuoteInput, type CreateRuleRequest, type CreateSegmentRequest, type CreateSessionResponse, type CreateVariantRequest, type GenerationJob as CreatorJob, CreatorMakerService, type GenerationOutput as CreatorOutput, type CreatorProject, type CreatorUsage, type Credential, type CredentialScope, type Customer, type CustomerStats, type DataAccessPolicy, type DataExport, DataService, type DataSource, type DeadLetterJob, type DecisionBatchItem, type DecisionBatchResult, type DecisionEvaluateOptions, type DecisionOutcome, type DecisionProposedAction, type DecisionReceipt, type DecisionResult, type DecisionTraceLevel, type DecisionVersions, DecisionsService, type DeviceInfo, type DirectoryUser, type DirectoryUserDetail, type DirectoryUsersListResponse, type Document, type ErrorCode, ErrorCodes, type EventAggregation, EventsService, type FileInfo, type FileStatus, type FlagAuditEntry, type FlagCheck, type FlagCondition, FlagContentService, type FlagDefinition, type FlagDetail, type FlagEnvironment, type FlagEvaluation, type FlagSegment, type FlagVariant, FlagsService, type FollowStatus, type FunctionExecution, type FunctionMetrics, FunctionsService, type Funnel, type FunnelConversion, type GdprRequest, type GenerateInput, type GrantInfo, type GraphEdge, type GraphNode, GraphService, IdentityService, type IdentityType, type IncomingRequestLike, type Invoice, type JobExecution, type JobStats, type JoinCallResponse, type KnownAccount, type KnownAccountDisplay, LEGACY_ANONYMOUS_ID_KEYS, type Lead, type Leaderboard, type LeaderboardEntry, LeaderboardService, LeadsService, type Like, type ListNotificationsParams, type Listing, ListingsService, type LogEntry, type LogInput, type LogQueryParams, type LogQueryResponse, type LogRecord, LoggerService, type LoginActivitySummary, type LoginDeviceInfo, type LoginHistoryEntry, type LoginRiskInfo, MEDIA_PRESETS, type MediaAsset, type MediaCaptureSession, type MediaKind, type MediaManifest, type MediaManifestOptions, type MediaPolicy, type MediaPreset, type MediaPresetSpec, MediaService, type MediaUploadEvent, type MediaUploadOptions, type MediaUploadPhase, type MediaUploadResult, type MessageCallback, type MessagePin, type MessageStatus, type MetricDataPoint, type MfaStatus, type Model, type ModelEntitlement, type ModelPricing, type ModelProvider, type UsageSummary as ModelUsageSummary, type MultipartCompleteResponse, type MultipartConfig, type MultipartPartUrl, type MultipartPartUrlsResponse, type MultipartStartResponse, type NetworkClass, type Notification, type NotificationListResponse, NotificationsService, type OAuthProvider, type OAuthUrl, OrchestratorService, PHOTO_BREAKPOINTS, type PaginatedResponse, type PaginationMetadata, type PaginationParams, type PartResult, type PartUrl, type Participant, type Payment, type PaymentListParams, type PaymentMethod, type PaymentStatusResponse, type Payout, type PayoutSchedule, type PermissionCheck, type PermissionMatrix, PermissionsService, type PhotoInfo, PhotoService, type PinnedMessagesResponse, type Pipeline, type PipelineVersion, type Policy, type Poll, type PollBallot, type PollChoice, type PollChoiceInput, type PollListOptions, type PollMedia, type PollMediaKind, type PollStatus, PollsService, type PresenceCallback, type PresenceEvent, type PresignedUploadResponse, type Price, type Product, type Project, type ProjectDocument, type ProjectGrant, type ProjectMember, type PushApiFetcher, type PushPreferences, type PushSettings, type PushSubscriptionInfo, type PushToken, type PushTokenAssociationResult, type PushTopic, type QueryFilter, type QueryOptions, type QuerySort, type QueueJob, QueueService, type Quote, type QuoteDeposit, type QuoteState, type ReadStatus, RealtimeService, type ReceiptVerification, type RedeemResult, type ReferralAnalytics, type ReferralCampaign, type ReferralProfile, type ReferralStats, ReferralsService, type Refund, type RegisterAgentRequest, type RegisterAgentResponse, type RegisterPushTokenData, type RequestOptions, type ResolvedReferral, type ResumeSession, type Role, type RuntimeTemplate, type RuntimeTemplateVersion, type S3MultipartOptions, type S3MultipartResult, type S3SingleUploadOptions, type S3SingleUploadResult, type S3UploadProgress, STORAGE_KEYS, ScaleMule, ScaleMuleClient, type ScaleMuleConfig, type SchedulerJob, SchedulerService, type SearchResult, SearchService, type SearchUsersParams, type SecurityLayers, type ServerlessFunction, type ServiceHealth, ServiceModule, type Session, type SessionArtifact, type SessionInfo, type SessionLog, type SessionPoolEntry, type Severity, type ShareLink, type ShortestPathResult, type SignedUrlResponse, type SocialContentProjection, type SocialContentProjectionInput, type SocialDiscoveryCreatorInput, type SocialPolicyAction, type SocialPolicyBatchDecisionItem, type SocialPolicyBatchDecisionRequest, type SocialPolicyBatchDecisionResponse, type SocialPolicyBatchDecisionTarget, type SocialPolicyBlockRequest, type SocialPolicyContactRequest, type SocialPolicyContactRequestListItem, type SocialPolicyContactRequestQuery, type SocialPolicyContactRequestRequest, type SocialPolicyContext, type SocialPolicyDecision, type SocialPolicyDecisionLimits, type SocialPolicyDecisionRequest, type SocialPolicyDecisionResponse, type SocialPolicyIdentity, type SocialPolicyIdentityType, type SocialPolicyMuteRequest, type SocialPolicyPolicyPack, type SocialPolicyRelationship, type SocialPolicyRelationshipQuery, type SocialPolicyRelationshipRequest, type SocialPolicyReportRequest, SocialPolicyService, type SocialPolicySettings, type SocialPolicyUnblockRequest, type SocialPolicyUpdateSettingsRequest, type SocialPost, SocialService, type SocialUser, type SsoConfig, type StatusCallback, type StorageAdapter, StorageService, type StorageSettings, type StrategyResult, type StylePreset, type SubmitResult, type Subscription, type TargetingRule, type Task, type TaskAttempt, type TaskTransition, type Team, type TeamInvitation, type TeamMember, TeamsService, type TelemetryPayload, type Tool, type ToolCapability, type ToolIntegration, type TopEvent, type TotpSetup, type Transaction, type TransactionListParams, type TransactionSummary, type TransactionSummaryParams, type Transfer, type TransformOptions, type TransformResult, type TraversalResult, type TtsAccessMode, type TtsAudioInfo, type TtsJobStatus, type TtsListVoicesParams, TtsService, type TtsSpeechMetadata, type TtsSpeechProfile, type TtsSynthesizeParams, type TtsSynthesizeQueuedResult, type TtsSynthesizeReadyResult, type TtsSynthesizeResult, type TtsVoice, type TtsVoicesResponse, type UnreadCountResponse, type UpdateFlagRequest, type UpdatePollInput, type UpdateRuleRequest, type UpdateSegmentRequest, type UpdateVariantRequest, type UploadCompleteResponse, type UploadEngineConfig, type UploadFailureReport, type UploadFailureReportResponse, type UploadOptions, type UploadPlan, UploadResumeStore, type UploadStrategy, UploadTelemetry, type UploadTelemetryConfig, type UploadTelemetryEvent, type UpsertEnvironmentRequest, type UsageRecord, type UsageSummary$1 as UsageSummary, type UserRank, type VideoInfo, VideoService, type VideoUploadOptions, type VoteState, WEB_PUSH_SERVICE_WORKER, WebPushManager, type WebPushManagerOptions, type WebPushSubscriptionData, type Webhook, WebhooksService, type WebrtcStats, type Workflow, type WorkflowExecution, type Workspace$1 as Workspace, type WorkspaceInvitation, type WorkspaceMember, WorkspacesService, buildClientContextHeaders, calculateTotalParts, canPerform, createUploadPlan, ScaleMule as default, detectNetworkClass, ensureAnonymousId, extractClientContext, generateAnonymousId, generateUploadSessionId, getMeasuredBandwidthMbps, getPartRange, hasMinRoleLevel, pollSharePercent, pollVoterKey, prepareCommunityMapAttachment, readAnonymousId, resolveStrategy, startMediaCapture, uploadMultipartToS3, uploadSingleToS3, validateIP };
|
|
8561
|
+
export { type AcceptQuoteInput, type AccountBalance, type AccountSwitcherPrivacy, AccountsService, type ActiveUsers, type ActivityItem, AgentAuthService, AgentModelsService, type AgentProfile, AgentProjectsService, type AgentResponse, type AgentSecurityPolicy, AgentSessionsService, type AgentSigningKey, type AgentToken, type AgentToolEntitlement, AgentToolsService, type Workspace as AgentWorkspace, AgentsService, type AggregateOptions, type AggregateResult, type AnalyticsEvent, AnalyticsService, type ApiError, type ApiKey, type ApiResponse, type Appeal, type Application, type AppointmentDepositValue, type Attachment, type Attendee, type AudioRegisterResult, AudioService, type AudioUploadViaStorageResult, type AuditLog, type AuthRegisterAgentRequest, type AuthRegisterAgentResponse, AuthService, type AuthSession, type AuthUser, type BackupCodes, BillingService, type BookingCompletionResult, BookingsService, type CacheEntry, CacheService, type CalendarEvent, type CallParticipant, type CallSession, type CatalogEntry, CatalogService, type ChatMessage, type ChatReaction, ChatService, type ClaimResult, type Client, type ClientContext, type Collection, type Comment, CommunicationService, type CommunityMapArea, type CommunityMapCanonicalArea, type CommunityMapCollection, type CommunityMapCollectionConfig, type CommunityMapComment, type CommunityMapCommentInput, type CommunityMapCommentPage, type CommunityMapConsent, type CommunityMapEditorialCollection, type CommunityMapEditorialComment, type CommunityMapEditorialFeature, type CommunityMapEditorialMedia, type CommunityMapFeature, type CommunityMapFeatureDraft, type CommunityMapFeatureQuery, type CommunityMapFeatureStatus, type CommunityMapGeometry, type CommunityMapMedia, type CommunityMapOwnSubmission, type CommunityMapOwnSubmissionPage, type CommunityMapPage, type CommunityMapPosition, type CommunityMapPrecision, type CommunityMapPrivateReport, type CommunityMapPrivateSubmission, type CommunityMapProposal, type CommunityMapPublicContent, type CommunityMapQueueQuery, type CommunityMapReactionDefinition, type CommunityMapReceipt, type CommunityMapReportInput, type CommunityMapReportReason, type CommunityMapRevision, type CommunityMapSource, type CommunityMapSubmissionInput, type CommunityMapSubmissionPolicy, type CommunityMapSubmissionStatus, type CommunityMapSubmissionUpdate, type CommunityMapView, type CommunityMapVote, CommunityMapsEditorialService, CommunityMapsGeographyService, CommunityMapsService, type CommunityValueOutcome, type CompletedPart, ComplianceService, type CompressionConfig, ConferenceService, type ConferenceSettings, type ConnectedAccount, type ConnectedAccountSubscription, type ConnectedSetupIntentResponse, type ConnectedSubscriptionListParams, type ConnectionStatus, type ContentFlag, type ContentPolicy, type Conversation, type CostReportDay, type CreateProjectInput as CreateCreatorProjectInput, type CreateFlagRequest, type CreateLeadInput, type CreatePollInput, type CreateQuoteInput, type CreateRuleRequest, type CreateSegmentRequest, type CreateSessionResponse, type CreateVariantRequest, type GenerationJob as CreatorJob, CreatorMakerService, type GenerationOutput as CreatorOutput, type CreatorProject, type CreatorUsage, type Credential, type CredentialScope, type Customer, type CustomerStats, type DataAccessPolicy, type DataExport, DataService, type DataSource, type DeadLetterJob, type DecisionBatchItem, type DecisionBatchResult, type DecisionEvaluateOptions, type DecisionOutcome, type DecisionProposedAction, type DecisionReceipt, type DecisionResult, type DecisionTraceLevel, type DecisionVersions, DecisionsService, type DeviceInfo, type DirectoryUser, type DirectoryUserDetail, type DirectoryUsersListResponse, type Document, type ErrorCode, ErrorCodes, type EventAggregation, EventsService, type FileInfo, type FileStatus, type FlagAuditEntry, type FlagCheck, type FlagCondition, FlagContentService, type FlagDefinition, type FlagDetail, type FlagEnvironment, type FlagEvaluation, type FlagSegment, type FlagVariant, FlagsService, type FollowStatus, type FunctionExecution, type FunctionMetrics, FunctionsService, type Funnel, type FunnelConversion, type GdprRequest, type GenerateInput, type GrantInfo, type GraphEdge, type GraphNode, GraphService, IdentityService, type IdentityType, type IncomingRequestLike, type IntelligenceAction, type IntelligenceCache, type IntelligenceChangePage, type IntelligenceClaim, type IntelligenceEvent, type IntelligenceKind, type IntelligenceRecordPage, type IntelligenceRelease, type IntelligenceReleaseReceipt, type IntelligenceSection, type IntelligenceSource, type IntelligenceStatus, type IntelligenceVerification, type Invoice, type JobExecution, type JobStats, type JoinCallResponse, type KnownAccount, type KnownAccountDisplay, LEGACY_ANONYMOUS_ID_KEYS, type Lead, type Leaderboard, type LeaderboardEntry, LeaderboardService, LeadsService, type Like, type ListNotificationsParams, type Listing, ListingsService, type LocalBriefing, type LocalIntelligencePreferences, type LocalIntelligenceRecord, LocalIntelligenceService, type LogEntry, type LogInput, type LogQueryParams, type LogQueryResponse, type LogRecord, LoggerService, type LoginActivitySummary, type LoginDeviceInfo, type LoginHistoryEntry, type LoginRiskInfo, MEDIA_PRESETS, type MediaAsset, type MediaCaptureSession, type MediaKind, type MediaManifest, type MediaManifestOptions, type MediaPolicy, type MediaPreset, type MediaPresetSpec, MediaService, type MediaUploadEvent, type MediaUploadOptions, type MediaUploadPhase, type MediaUploadResult, type MessageCallback, type MessagePin, type MessageStatus, type MetricDataPoint, type MfaStatus, type Model, type ModelEntitlement, type ModelPricing, type ModelProvider, type UsageSummary as ModelUsageSummary, type MultipartCompleteResponse, type MultipartConfig, type MultipartPartUrl, type MultipartPartUrlsResponse, type MultipartStartResponse, type NetworkClass, type Notification, type NotificationListResponse, NotificationsService, type OAuthProvider, type OAuthUrl, OrchestratorService, PHOTO_BREAKPOINTS, type PaginatedResponse, type PaginationMetadata, type PaginationParams, type PartResult, type PartUrl, type Participant, type Payment, type PaymentListParams, type PaymentMethod, type PaymentStatusResponse, type Payout, type PayoutSchedule, type PermissionCheck, type PermissionMatrix, PermissionsService, type PhotoInfo, PhotoService, type PinnedMessagesResponse, type Pipeline, type PipelineVersion, type Policy, type Poll, type PollBallot, type PollChoice, type PollChoiceInput, type PollListOptions, type PollMedia, type PollMediaKind, type PollStatus, PollsService, type PresenceCallback, type PresenceEvent, type PresignedUploadResponse, type Price, type Product, type Project, type ProjectDocument, type ProjectGrant, type ProjectMember, type PushApiFetcher, type PushPreferences, type PushSettings, type PushSubscriptionInfo, type PushToken, type PushTokenAssociationResult, type PushTopic, type QueryFilter, type QueryOptions, type QuerySort, type QueueJob, QueueService, type Quote, type QuoteDeposit, type QuoteState, type ReadStatus, RealtimeService, type ReceiptVerification, type RedeemResult, type ReferralAnalytics, type ReferralCampaign, type ReferralProfile, type ReferralStats, ReferralsService, type Refund, type RegisterAgentRequest, type RegisterAgentResponse, type RegisterPushTokenData, type RequestOptions, type ResolvedReferral, type ResumeSession, type Role, type RuntimeTemplate, type RuntimeTemplateVersion, type S3MultipartOptions, type S3MultipartResult, type S3SingleUploadOptions, type S3SingleUploadResult, type S3UploadProgress, STORAGE_KEYS, ScaleMule, ScaleMuleClient, type ScaleMuleConfig, type SchedulerJob, SchedulerService, type SearchResult, SearchService, type SearchUsersParams, type SecurityLayers, type ServerlessFunction, type ServiceHealth, ServiceModule, type Session, type SessionArtifact, type SessionInfo, type SessionLog, type SessionPoolEntry, type Severity, type ShareLink, type ShortestPathResult, type SignedUrlResponse, type SocialContentProjection, type SocialContentProjectionInput, type SocialDiscoveryCreatorInput, type SocialPolicyAction, type SocialPolicyBatchDecisionItem, type SocialPolicyBatchDecisionRequest, type SocialPolicyBatchDecisionResponse, type SocialPolicyBatchDecisionTarget, type SocialPolicyBlockRequest, type SocialPolicyContactRequest, type SocialPolicyContactRequestListItem, type SocialPolicyContactRequestQuery, type SocialPolicyContactRequestRequest, type SocialPolicyContext, type SocialPolicyDecision, type SocialPolicyDecisionLimits, type SocialPolicyDecisionRequest, type SocialPolicyDecisionResponse, type SocialPolicyIdentity, type SocialPolicyIdentityType, type SocialPolicyMuteRequest, type SocialPolicyPolicyPack, type SocialPolicyRelationship, type SocialPolicyRelationshipQuery, type SocialPolicyRelationshipRequest, type SocialPolicyReportRequest, SocialPolicyService, type SocialPolicySettings, type SocialPolicyUnblockRequest, type SocialPolicyUpdateSettingsRequest, type SocialPost, SocialService, type SocialUser, type SsoConfig, type StatusCallback, type StorageAdapter, StorageService, type StorageSettings, type StrategyResult, type StylePreset, type SubmitResult, type Subscription, type TargetingRule, type Task, type TaskAttempt, type TaskTransition, type Team, type TeamInvitation, type TeamMember, TeamsService, type TelemetryPayload, type Tool, type ToolCapability, type ToolIntegration, type TopEvent, type TotpSetup, type Transaction, type TransactionListParams, type TransactionSummary, type TransactionSummaryParams, type Transfer, type TransformOptions, type TransformResult, type TraversalResult, type TtsAccessMode, type TtsAudioInfo, type TtsJobStatus, type TtsListVoicesParams, TtsService, type TtsSpeechMetadata, type TtsSpeechProfile, type TtsSynthesizeParams, type TtsSynthesizeQueuedResult, type TtsSynthesizeReadyResult, type TtsSynthesizeResult, type TtsVoice, type TtsVoicesResponse, type UnreadCountResponse, type UpdateFlagRequest, type UpdatePollInput, type UpdateRuleRequest, type UpdateSegmentRequest, type UpdateVariantRequest, type UploadCompleteResponse, type UploadEngineConfig, type UploadFailureReport, type UploadFailureReportResponse, type UploadOptions, type UploadPlan, UploadResumeStore, type UploadStrategy, UploadTelemetry, type UploadTelemetryConfig, type UploadTelemetryEvent, type UpsertEnvironmentRequest, type UsageRecord, type UsageSummary$1 as UsageSummary, type UserRank, type VideoInfo, VideoService, type VideoUploadOptions, type VoteState, WEB_PUSH_SERVICE_WORKER, WebPushManager, type WebPushManagerOptions, type WebPushSubscriptionData, type Webhook, WebhooksService, type WebrtcStats, type Workflow, type WorkflowExecution, type Workspace$1 as Workspace, type WorkspaceInvitation, type WorkspaceMember, WorkspacesService, applyIntelligenceChanges, buildClientContextHeaders, calculateTotalParts, canPerform, createUploadPlan, ScaleMule as default, detectNetworkClass, ensureAnonymousId, extractClientContext, generateAnonymousId, generateUploadSessionId, getMeasuredBandwidthMbps, getPartRange, hasMinRoleLevel, pollSharePercent, pollVoterKey, prepareCommunityMapAttachment, readAnonymousId, resolveStrategy, startMediaCapture, uploadMultipartToS3, uploadSingleToS3, validateIP };
|
package/dist/index.js
CHANGED
|
@@ -338,6 +338,7 @@ __export(index_exports, {
|
|
|
338
338
|
LeaderboardService: () => LeaderboardService,
|
|
339
339
|
LeadsService: () => LeadsService,
|
|
340
340
|
ListingsService: () => ListingsService,
|
|
341
|
+
LocalIntelligenceService: () => LocalIntelligenceService,
|
|
341
342
|
LoggerService: () => LoggerService,
|
|
342
343
|
MEDIA_PRESETS: () => MEDIA_PRESETS,
|
|
343
344
|
MediaService: () => MediaService,
|
|
@@ -369,6 +370,7 @@ __export(index_exports, {
|
|
|
369
370
|
WebPushManager: () => WebPushManager,
|
|
370
371
|
WebhooksService: () => WebhooksService,
|
|
371
372
|
WorkspacesService: () => WorkspacesService,
|
|
373
|
+
applyIntelligenceChanges: () => applyIntelligenceChanges,
|
|
372
374
|
buildClientContextHeaders: () => buildClientContextHeaders,
|
|
373
375
|
calculateTotalParts: () => calculateTotalParts,
|
|
374
376
|
canPerform: () => canPerform,
|
|
@@ -7150,6 +7152,97 @@ var CommunityMapsGeographyService = class extends ServiceModule {
|
|
|
7150
7152
|
}
|
|
7151
7153
|
};
|
|
7152
7154
|
|
|
7155
|
+
// src/services/local-intelligence.ts
|
|
7156
|
+
var LocalIntelligenceService = class extends ServiceModule {
|
|
7157
|
+
constructor() {
|
|
7158
|
+
super(...arguments);
|
|
7159
|
+
this.basePath = "/v1/news";
|
|
7160
|
+
}
|
|
7161
|
+
scope(publication) {
|
|
7162
|
+
return `/intelligence/publications/${encodeURIComponent(publication)}`;
|
|
7163
|
+
}
|
|
7164
|
+
records(publication, params = {}, options) {
|
|
7165
|
+
return this._get(this.withQuery(`${this.scope(publication)}/records`, params), options);
|
|
7166
|
+
}
|
|
7167
|
+
get(publication, record, options) {
|
|
7168
|
+
return this._get(`${this.scope(publication)}/records/${encodeURIComponent(record)}`, options);
|
|
7169
|
+
}
|
|
7170
|
+
changes(publication, params = {}, options) {
|
|
7171
|
+
return this._get(this.withQuery(`${this.scope(publication)}/changes`, params), options);
|
|
7172
|
+
}
|
|
7173
|
+
briefing(publication, params, options) {
|
|
7174
|
+
return this._get(this.withQuery(`${this.scope(publication)}/briefing`, params), options);
|
|
7175
|
+
}
|
|
7176
|
+
/** Agent-safe explicit preferences: evaluated for this request and never saved. */
|
|
7177
|
+
briefingForPreferences(publication, input, options) {
|
|
7178
|
+
return this.post(`${this.scope(publication)}/briefing`, input, options);
|
|
7179
|
+
}
|
|
7180
|
+
preferences(publication, options) {
|
|
7181
|
+
return this._get(`${this.scope(publication)}/preferences`, options);
|
|
7182
|
+
}
|
|
7183
|
+
savePreferences(publication, expectedRevision, preferences, options) {
|
|
7184
|
+
return this.put(
|
|
7185
|
+
`${this.scope(publication)}/preferences`,
|
|
7186
|
+
{ expected_revision: expectedRevision, preferences },
|
|
7187
|
+
options
|
|
7188
|
+
);
|
|
7189
|
+
}
|
|
7190
|
+
deletePreferences(publication, options) {
|
|
7191
|
+
return this.del(`${this.scope(publication)}/preferences`, options);
|
|
7192
|
+
}
|
|
7193
|
+
feedback(publication, record, recordRevision, outcome, options) {
|
|
7194
|
+
return this.post(
|
|
7195
|
+
`${this.scope(publication)}/records/${encodeURIComponent(record)}/feedback`,
|
|
7196
|
+
{ record_revision: recordRevision, outcome },
|
|
7197
|
+
options
|
|
7198
|
+
);
|
|
7199
|
+
}
|
|
7200
|
+
deleteFeedback(publication, record, options) {
|
|
7201
|
+
return this.del(`${this.scope(publication)}/records/${encodeURIComponent(record)}/feedback`, options);
|
|
7202
|
+
}
|
|
7203
|
+
/** Requires a human editor with publication publish authority. */
|
|
7204
|
+
release(publication, input, idempotencyKey, options) {
|
|
7205
|
+
return this.post(`/publications/${encodeURIComponent(publication)}/intelligence`, input, {
|
|
7206
|
+
...options,
|
|
7207
|
+
headers: { ...options?.headers, "idempotency-key": idempotencyKey }
|
|
7208
|
+
});
|
|
7209
|
+
}
|
|
7210
|
+
withdraw(publication, record, expectedRevision, reason, options) {
|
|
7211
|
+
return this.post(
|
|
7212
|
+
`/publications/${encodeURIComponent(publication)}/intelligence/${encodeURIComponent(record)}/withdraw`,
|
|
7213
|
+
{ expected_revision: expectedRevision, reason },
|
|
7214
|
+
options
|
|
7215
|
+
);
|
|
7216
|
+
}
|
|
7217
|
+
};
|
|
7218
|
+
function applyIntelligenceChanges(current, changes, now = Date.now()) {
|
|
7219
|
+
if (changes.contract_version !== "basenews/1" || changes.scope.application_id !== current.scope.application_id || changes.scope.publication_id !== current.scope.publication_id)
|
|
7220
|
+
throw new Error("Intelligence change scope mismatch");
|
|
7221
|
+
const sequenceValue = (value) => {
|
|
7222
|
+
if (!/^(0|[1-9][0-9]{0,19})$/.test(value)) throw new Error("Invalid intelligence sequence");
|
|
7223
|
+
return BigInt(value);
|
|
7224
|
+
};
|
|
7225
|
+
let sequence = sequenceValue(current.sequence);
|
|
7226
|
+
let previous = -1n;
|
|
7227
|
+
const next = new Map(current.records);
|
|
7228
|
+
for (const item of changes.items) {
|
|
7229
|
+
const received = sequenceValue(item.sequence);
|
|
7230
|
+
if (received <= previous) throw new Error("Unordered intelligence change batch");
|
|
7231
|
+
previous = received;
|
|
7232
|
+
if (received <= sequence) continue;
|
|
7233
|
+
if (received !== sequence + 1n) throw new Error("Intelligence change gap; resume the previous cursor");
|
|
7234
|
+
sequence = received;
|
|
7235
|
+
if (item.removed || !item.record) next.delete(item.id);
|
|
7236
|
+
else if (item.record.id !== item.id) throw new Error("Intelligence change identity mismatch");
|
|
7237
|
+
else if (!next.has(item.id) || next.get(item.id).revision <= item.record.revision) next.set(item.id, item.record);
|
|
7238
|
+
}
|
|
7239
|
+
for (const [id, record] of next) {
|
|
7240
|
+
const expiry = Date.parse(record.refresh_after);
|
|
7241
|
+
if (record.contract_version !== "basenews/1" || !Number.isFinite(expiry) || expiry <= now) next.delete(id);
|
|
7242
|
+
}
|
|
7243
|
+
return { scope: current.scope, sequence: sequence.toString(), records: next };
|
|
7244
|
+
}
|
|
7245
|
+
|
|
7153
7246
|
// src/services/polls.ts
|
|
7154
7247
|
var PollsService = class extends ServiceModule {
|
|
7155
7248
|
constructor() {
|
|
@@ -9297,6 +9390,7 @@ var ScaleMule = class {
|
|
|
9297
9390
|
this.leaderboard = new LeaderboardService(this._client);
|
|
9298
9391
|
this.listings = new ListingsService(this._client);
|
|
9299
9392
|
this.communityMaps = new CommunityMapsService(this._client);
|
|
9393
|
+
this.localIntelligence = new LocalIntelligenceService(this._client);
|
|
9300
9394
|
this.polls = new PollsService(this._client);
|
|
9301
9395
|
this.events = new EventsService(this._client);
|
|
9302
9396
|
this.graph = new GraphService(this._client);
|
|
@@ -9475,6 +9569,7 @@ var index_default = ScaleMule;
|
|
|
9475
9569
|
LeaderboardService,
|
|
9476
9570
|
LeadsService,
|
|
9477
9571
|
ListingsService,
|
|
9572
|
+
LocalIntelligenceService,
|
|
9478
9573
|
LoggerService,
|
|
9479
9574
|
MEDIA_PRESETS,
|
|
9480
9575
|
MediaService,
|
|
@@ -9506,6 +9601,7 @@ var index_default = ScaleMule;
|
|
|
9506
9601
|
WebPushManager,
|
|
9507
9602
|
WebhooksService,
|
|
9508
9603
|
WorkspacesService,
|
|
9604
|
+
applyIntelligenceChanges,
|
|
9509
9605
|
buildClientContextHeaders,
|
|
9510
9606
|
calculateTotalParts,
|
|
9511
9607
|
canPerform,
|
package/dist/index.mjs
CHANGED
|
@@ -7026,6 +7026,97 @@ var CommunityMapsGeographyService = class extends ServiceModule {
|
|
|
7026
7026
|
}
|
|
7027
7027
|
};
|
|
7028
7028
|
|
|
7029
|
+
// src/services/local-intelligence.ts
|
|
7030
|
+
var LocalIntelligenceService = class extends ServiceModule {
|
|
7031
|
+
constructor() {
|
|
7032
|
+
super(...arguments);
|
|
7033
|
+
this.basePath = "/v1/news";
|
|
7034
|
+
}
|
|
7035
|
+
scope(publication) {
|
|
7036
|
+
return `/intelligence/publications/${encodeURIComponent(publication)}`;
|
|
7037
|
+
}
|
|
7038
|
+
records(publication, params = {}, options) {
|
|
7039
|
+
return this._get(this.withQuery(`${this.scope(publication)}/records`, params), options);
|
|
7040
|
+
}
|
|
7041
|
+
get(publication, record, options) {
|
|
7042
|
+
return this._get(`${this.scope(publication)}/records/${encodeURIComponent(record)}`, options);
|
|
7043
|
+
}
|
|
7044
|
+
changes(publication, params = {}, options) {
|
|
7045
|
+
return this._get(this.withQuery(`${this.scope(publication)}/changes`, params), options);
|
|
7046
|
+
}
|
|
7047
|
+
briefing(publication, params, options) {
|
|
7048
|
+
return this._get(this.withQuery(`${this.scope(publication)}/briefing`, params), options);
|
|
7049
|
+
}
|
|
7050
|
+
/** Agent-safe explicit preferences: evaluated for this request and never saved. */
|
|
7051
|
+
briefingForPreferences(publication, input, options) {
|
|
7052
|
+
return this.post(`${this.scope(publication)}/briefing`, input, options);
|
|
7053
|
+
}
|
|
7054
|
+
preferences(publication, options) {
|
|
7055
|
+
return this._get(`${this.scope(publication)}/preferences`, options);
|
|
7056
|
+
}
|
|
7057
|
+
savePreferences(publication, expectedRevision, preferences, options) {
|
|
7058
|
+
return this.put(
|
|
7059
|
+
`${this.scope(publication)}/preferences`,
|
|
7060
|
+
{ expected_revision: expectedRevision, preferences },
|
|
7061
|
+
options
|
|
7062
|
+
);
|
|
7063
|
+
}
|
|
7064
|
+
deletePreferences(publication, options) {
|
|
7065
|
+
return this.del(`${this.scope(publication)}/preferences`, options);
|
|
7066
|
+
}
|
|
7067
|
+
feedback(publication, record, recordRevision, outcome, options) {
|
|
7068
|
+
return this.post(
|
|
7069
|
+
`${this.scope(publication)}/records/${encodeURIComponent(record)}/feedback`,
|
|
7070
|
+
{ record_revision: recordRevision, outcome },
|
|
7071
|
+
options
|
|
7072
|
+
);
|
|
7073
|
+
}
|
|
7074
|
+
deleteFeedback(publication, record, options) {
|
|
7075
|
+
return this.del(`${this.scope(publication)}/records/${encodeURIComponent(record)}/feedback`, options);
|
|
7076
|
+
}
|
|
7077
|
+
/** Requires a human editor with publication publish authority. */
|
|
7078
|
+
release(publication, input, idempotencyKey, options) {
|
|
7079
|
+
return this.post(`/publications/${encodeURIComponent(publication)}/intelligence`, input, {
|
|
7080
|
+
...options,
|
|
7081
|
+
headers: { ...options?.headers, "idempotency-key": idempotencyKey }
|
|
7082
|
+
});
|
|
7083
|
+
}
|
|
7084
|
+
withdraw(publication, record, expectedRevision, reason, options) {
|
|
7085
|
+
return this.post(
|
|
7086
|
+
`/publications/${encodeURIComponent(publication)}/intelligence/${encodeURIComponent(record)}/withdraw`,
|
|
7087
|
+
{ expected_revision: expectedRevision, reason },
|
|
7088
|
+
options
|
|
7089
|
+
);
|
|
7090
|
+
}
|
|
7091
|
+
};
|
|
7092
|
+
function applyIntelligenceChanges(current, changes, now = Date.now()) {
|
|
7093
|
+
if (changes.contract_version !== "basenews/1" || changes.scope.application_id !== current.scope.application_id || changes.scope.publication_id !== current.scope.publication_id)
|
|
7094
|
+
throw new Error("Intelligence change scope mismatch");
|
|
7095
|
+
const sequenceValue = (value) => {
|
|
7096
|
+
if (!/^(0|[1-9][0-9]{0,19})$/.test(value)) throw new Error("Invalid intelligence sequence");
|
|
7097
|
+
return BigInt(value);
|
|
7098
|
+
};
|
|
7099
|
+
let sequence = sequenceValue(current.sequence);
|
|
7100
|
+
let previous = -1n;
|
|
7101
|
+
const next = new Map(current.records);
|
|
7102
|
+
for (const item of changes.items) {
|
|
7103
|
+
const received = sequenceValue(item.sequence);
|
|
7104
|
+
if (received <= previous) throw new Error("Unordered intelligence change batch");
|
|
7105
|
+
previous = received;
|
|
7106
|
+
if (received <= sequence) continue;
|
|
7107
|
+
if (received !== sequence + 1n) throw new Error("Intelligence change gap; resume the previous cursor");
|
|
7108
|
+
sequence = received;
|
|
7109
|
+
if (item.removed || !item.record) next.delete(item.id);
|
|
7110
|
+
else if (item.record.id !== item.id) throw new Error("Intelligence change identity mismatch");
|
|
7111
|
+
else if (!next.has(item.id) || next.get(item.id).revision <= item.record.revision) next.set(item.id, item.record);
|
|
7112
|
+
}
|
|
7113
|
+
for (const [id, record] of next) {
|
|
7114
|
+
const expiry = Date.parse(record.refresh_after);
|
|
7115
|
+
if (record.contract_version !== "basenews/1" || !Number.isFinite(expiry) || expiry <= now) next.delete(id);
|
|
7116
|
+
}
|
|
7117
|
+
return { scope: current.scope, sequence: sequence.toString(), records: next };
|
|
7118
|
+
}
|
|
7119
|
+
|
|
7029
7120
|
// src/services/polls.ts
|
|
7030
7121
|
var PollsService = class extends ServiceModule {
|
|
7031
7122
|
constructor() {
|
|
@@ -9173,6 +9264,7 @@ var ScaleMule = class {
|
|
|
9173
9264
|
this.leaderboard = new LeaderboardService(this._client);
|
|
9174
9265
|
this.listings = new ListingsService(this._client);
|
|
9175
9266
|
this.communityMaps = new CommunityMapsService(this._client);
|
|
9267
|
+
this.localIntelligence = new LocalIntelligenceService(this._client);
|
|
9176
9268
|
this.polls = new PollsService(this._client);
|
|
9177
9269
|
this.events = new EventsService(this._client);
|
|
9178
9270
|
this.graph = new GraphService(this._client);
|
|
@@ -9350,6 +9442,7 @@ export {
|
|
|
9350
9442
|
LeaderboardService,
|
|
9351
9443
|
LeadsService,
|
|
9352
9444
|
ListingsService,
|
|
9445
|
+
LocalIntelligenceService,
|
|
9353
9446
|
LoggerService,
|
|
9354
9447
|
MEDIA_PRESETS,
|
|
9355
9448
|
MediaService,
|
|
@@ -9381,6 +9474,7 @@ export {
|
|
|
9381
9474
|
WebPushManager,
|
|
9382
9475
|
WebhooksService,
|
|
9383
9476
|
WorkspacesService,
|
|
9477
|
+
applyIntelligenceChanges,
|
|
9384
9478
|
buildClientContextHeaders,
|
|
9385
9479
|
calculateTotalParts,
|
|
9386
9480
|
canPerform,
|