@recursiv/sdk 0.7.22 → 0.7.23
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 +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/resources/protocols.d.ts +19 -1
- package/dist/resources/protocols.js +4 -0
- package/llm.md +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -110,7 +110,7 @@ for await (const chunk of r.agents.chatStream(agent.id, { message: 'Hello!' }))
|
|
|
110
110
|
| `r.admin` | User management, stats, content reports (`listReports`, `resolveReport`, `dismissReport`) |
|
|
111
111
|
| `r.dispatcher` | Task queue, claims, signals, outcomes, webhooks |
|
|
112
112
|
| `r.goals` | Org goals with task rollups (group dispatcher tasks) |
|
|
113
|
-
| `r.protocols` | `list` returns bounded adapter `maturity`, `limitations`, and exhaustive `supported`/`planned`/`unsupported` implementation capabilities (not provider health or enablement); settings, candidate refresh/status, search, and read-only quarantined candidate review via `listCandidates` / `getCandidate` |
|
|
113
|
+
| `r.protocols` | Public reading: `publicNetworks`, `searchPublicProfiles`, `getPublicProfile`, `getPublicAuthorFeed`, `getFollowingFeed`, `getPublicConversation`; private app subscriptions: `listSubscriptions`, `subscribeToProfile`, `unsubscribeFromProfile`, `onSubscriptionChange`. `list` returns bounded adapter `maturity`, `limitations`, and exhaustive `supported`/`planned`/`unsupported` implementation capabilities (not provider health or enablement); settings, candidate refresh/status, search, and read-only quarantined candidate review via `listCandidates` / `getCandidate` |
|
|
114
114
|
|
|
115
115
|
Full reference: see [llm.md](./llm.md) (ships with this package) or the type definitions in `dist/`.
|
|
116
116
|
|
package/dist/index.d.ts
CHANGED
|
@@ -189,7 +189,7 @@ export type { UploadMediaInput, UploadUrlInput, UploadUrlResult } from './resour
|
|
|
189
189
|
export { WalletResource } from './resources/wallet.js';
|
|
190
190
|
export { ProtocolsResource } from './resources/protocols.js';
|
|
191
191
|
export { PROTOCOL_ADAPTER_MATURITIES, PROTOCOL_CAPABILITY_OPERATIONS, PROTOCOL_CAPABILITY_STATUSES, } from './resources/protocols.js';
|
|
192
|
-
export type { SocialProfile, SocialSubscription, SocialSubscriptionChange, SocialProfilePage, SocialNetwork, SocialPost, SocialAuthorFeed, SocialFollowingFeed, SocialFollowingSource, SearchPublicProfilesParams, HostedProtocolConnections, HostedProtocol, HostedProtocolIdentity, HostedNostrChallenge, HostedNostrIdentityProof, HostedPostPreview, ConnectHostedIdentityInput, PreviewHostedPostInput, PublishHostedPostInput, ListProtocolCandidatesParams, ProtocolAdapterMaturity, ProtocolAdapterMetadata, ProtocolCandidateListResponse, ProtocolCandidatePageMeta, ProtocolCapabilityOperation, ProtocolCapabilityStatus, ProtocolCollectionStatus, ProtocolQuarantinedCandidate, ProtocolRefreshResult, ProtocolSettings, ProtocolSettingsUpdateResult, UpdateSettingsInput as UpdateProtocolSettingsInput, } from './resources/protocols.js';
|
|
192
|
+
export type { SocialProfile, SocialSubscription, SocialSubscriptionChange, SocialProfilePage, SocialNetwork, SocialPost, SocialConversation, SocialAuthorFeed, SocialFollowingFeed, SocialFollowingSource, SearchPublicProfilesParams, HostedProtocolConnections, HostedProtocol, HostedProtocolIdentity, HostedNostrChallenge, HostedNostrIdentityProof, HostedPostPreview, ConnectHostedIdentityInput, PreviewHostedPostInput, PublishHostedPostInput, ListProtocolCandidatesParams, ProtocolAdapterMaturity, ProtocolAdapterMetadata, ProtocolCandidateListResponse, ProtocolCandidatePageMeta, ProtocolCapabilityOperation, ProtocolCapabilityStatus, ProtocolCollectionStatus, ProtocolQuarantinedCandidate, ProtocolRefreshResult, ProtocolSettings, ProtocolSettingsUpdateResult, UpdateSettingsInput as UpdateProtocolSettingsInput, } from './resources/protocols.js';
|
|
193
193
|
export { InboxResource } from './resources/inbox.js';
|
|
194
194
|
export { NetworkResource } from './resources/network.js';
|
|
195
195
|
export { SimulatorResource } from './resources/simulator.js';
|
|
@@ -201,8 +201,9 @@ export interface SocialNetwork {
|
|
|
201
201
|
url: string;
|
|
202
202
|
};
|
|
203
203
|
coverage: string;
|
|
204
|
-
capabilities: Array<'profile_search' | 'profile_read' | 'original_author_posts' | 'minds_subscription' | 'following_feed'>;
|
|
204
|
+
capabilities: Array<'profile_search' | 'profile_read' | 'original_author_posts' | 'minds_subscription' | 'following_feed' | 'conversation_read'>;
|
|
205
205
|
profileSearchPagination: boolean;
|
|
206
|
+
conversationCoverage?: string;
|
|
206
207
|
}
|
|
207
208
|
/** Public source identity, independent of any local Minds user or handle. */
|
|
208
209
|
export interface SocialProfile {
|
|
@@ -248,6 +249,8 @@ export interface SocialPost {
|
|
|
248
249
|
protocol: string;
|
|
249
250
|
nativeId: string;
|
|
250
251
|
sourceUrl: string;
|
|
252
|
+
/** Opaque provider-local reference returned by public reads. */
|
|
253
|
+
readRef?: string;
|
|
251
254
|
author: Omit<SocialProfile, 'subscription'>;
|
|
252
255
|
text: string;
|
|
253
256
|
createdAt: string;
|
|
@@ -266,6 +269,15 @@ export interface SocialAuthorFeed {
|
|
|
266
269
|
cursor: string | null;
|
|
267
270
|
coverage: 'original_posts';
|
|
268
271
|
}
|
|
272
|
+
export interface SocialConversation {
|
|
273
|
+
focus: SocialPost;
|
|
274
|
+
/** Oldest available ancestor first, ending with the immediate parent. */
|
|
275
|
+
ancestors: SocialPost[];
|
|
276
|
+
/** Available direct replies to focus, not all descendants. */
|
|
277
|
+
replies: SocialPost[];
|
|
278
|
+
coverage: 'public_provider_window';
|
|
279
|
+
limited: boolean;
|
|
280
|
+
}
|
|
269
281
|
export interface SocialFollowingSource {
|
|
270
282
|
subscriptionId: string;
|
|
271
283
|
protocol: string;
|
|
@@ -306,6 +318,12 @@ export declare class ProtocolsResource {
|
|
|
306
318
|
protocol?: string;
|
|
307
319
|
cursor?: string;
|
|
308
320
|
}): Promise<SingleResponse<SocialFollowingFeed>>;
|
|
321
|
+
/** Read the selected source post and its bounded public conversation; never publishes or imports it. */
|
|
322
|
+
getPublicConversation(params: {
|
|
323
|
+
protocol: string;
|
|
324
|
+
post: string;
|
|
325
|
+
readRef?: string;
|
|
326
|
+
}): Promise<SingleResponse<SocialConversation>>;
|
|
309
327
|
/** Save a private reading subscription after resolving the immutable native ID. */
|
|
310
328
|
subscribeToProfile(input: {
|
|
311
329
|
protocol: string;
|
|
@@ -78,6 +78,10 @@ export class ProtocolsResource {
|
|
|
78
78
|
getFollowingFeed(params = {}) {
|
|
79
79
|
return this.client.get('/protocols/social/following-feed', { protocol: params.protocol, cursor: params.cursor });
|
|
80
80
|
}
|
|
81
|
+
/** Read the selected source post and its bounded public conversation; never publishes or imports it. */
|
|
82
|
+
getPublicConversation(params) {
|
|
83
|
+
return this.client.get('/protocols/social/conversation', { protocol: params.protocol, post: params.post, readRef: params.readRef });
|
|
84
|
+
}
|
|
81
85
|
/** Save a private reading subscription after resolving the immutable native ID. */
|
|
82
86
|
subscribeToProfile(input) {
|
|
83
87
|
return this.client.post('/protocols/social/subscriptions', input).then(result => {
|
package/llm.md
CHANGED
|
@@ -619,7 +619,7 @@ if (subscription.active) {
|
|
|
619
619
|
- `r.admin` — Admin operations (user management, stats, network settings); content reports: `listReports({ status? })`, `resolveReport(id)`, `dismissReport(id)` (project-bound keys see only their app's reports)
|
|
620
620
|
- `r.inviteCodes` / `r.inviteCodesAdmin` — Invite code management
|
|
621
621
|
- `r.organizationSettings` / `r.organizationSecurity` — Org configuration
|
|
622
|
-
- `r.protocols` — Protocol discovery/settings: `const { data: adapters } = await r.protocols.list()` returns bounded `{ id, name, icon, color, maturity, capabilities, limitations }` metadata; `supported` means implemented, not configured, healthy, authorized, or enabled. Methods: `list`, `status`, `listCandidates`, `getCandidate`, `search`, `getSettings`, `refresh`, `updateSettings`.
|
|
622
|
+
- `r.protocols` — Public reading: `publicNetworks`, `searchPublicProfiles`, `getPublicProfile`, `getPublicAuthorFeed`, `getFollowingFeed`, `getPublicConversation`; private app subscriptions: `listSubscriptions`, `subscribeToProfile`, `unsubscribeFromProfile`, `onSubscriptionChange`. Example after selecting a returned source post: `const { data: thread } = await r.protocols.getPublicConversation({ protocol: post.protocol, post: post.nativeId, readRef: post.readRef })`. Render `focus`, oldest-first `ancestors` and direct `replies`; `public_provider_window` never promises every reply, and `limited` marks known omissions. Requires both `users:read` and `posts:read` on the current human app key. Protocol discovery/settings: `const { data: adapters } = await r.protocols.list()` returns bounded `{ id, name, icon, color, maturity, capabilities, limitations }` metadata; `supported` means implemented, not configured, healthy, authorized, or enabled. Methods: `list`, `status`, `listCandidates`, `getCandidate`, `search`, `getSettings`, `refresh`, `updateSettings`.
|
|
623
623
|
- `listCandidates({ protocol?, limit?, cursor? })` and `getCandidate(id)` are read-only quarantine review, not published-post search. Both require `admin` scope, a project-bound key, a live admin role, and existing project-admin access. The key supplies app/network scope; neither method accepts another project or network. They never invoke refresh, change settings, or publish.
|
|
624
624
|
- Lists return `{ data: ProtocolQuarantinedCandidate[], meta: { limit, has_more, next_cursor } }`; use the opaque `next_cursor`, not offset pagination. The API defaults `limit` to 20 and permits at most 50. Details return `{ data: ProtocolQuarantinedCandidate }`. Every candidate has `state: 'quarantined'` and `content_format: 'plain'`; render its bounded `content` as text, respect `content_truncated`, and distinguish upstream `published_at` from local `observed_at` / `created_at`.
|
|
625
625
|
- Safe source IDs are preserved byte-exact. `external_id: null` means unsafe or malformed provenance was withheld, not an invented ID; `author.native_id` may likewise be absent or withheld. Preserve nulls in both list and detail views, and use the candidate's own `id` for `getCandidate`.
|