Skip to content

Interface: IReviewSource

Makaio Framework


Makaio Framework / contracts / IReviewSource

Defined in: ../../../packages/contracts/src/capabilities/review/types.ts:121

Review source capability provider.

Sources handle source-specific I/O: VCS reads, CLI invocation, trigger comments, and rate-limit metadata.

readonly capabilities: object

Defined in: ../../../packages/contracts/src/capabilities/review/types.ts:129

Source capabilities

canFetch: boolean

canTrigger: boolean

isPush: boolean


readonly capabilityId: "review-source"

Defined in: ../../../packages/contracts/src/capabilities/review/types.ts:123

Must be ‘review-source’


readonly displayName: string

Defined in: ../../../packages/contracts/src/capability/types.ts:11

Human-readable name for display in UI

ICapabilityProvider.displayName


readonly id: string

Defined in: ../../../packages/contracts/src/capability/types.ts:9

Unique identifier for this provider instance

ICapabilityProvider.id


readonly optional preferredProcessorKey?: string

Defined in: ../../../packages/contracts/src/capabilities/review/types.ts:127

Preferred processor key for this source


readonly optional providerKey?: string

Defined in: ../../../packages/contracts/src/capability/types.ts:17

Stable provider identity used for joins across registries.

Unlike id, this should remain stable across runtime re-registration.

ICapabilityProvider.providerKey


readonly reviewer: string

Defined in: ../../../packages/contracts/src/capabilities/review/types.ts:125

Reviewer family this source feeds (e.g., ‘coderabbit’)

optional fetchSnapshot(params): Promise<ReviewSourceSnapshot>

Defined in: ../../../packages/contracts/src/capabilities/review/types.ts:145

Fetch raw snapshot from the source.

FetchFindingsParams & ReviewRequestContext

Fetch parameters merged with VCS routing context

Promise<ReviewSourceSnapshot>

Raw snapshot of source data before processing


optional getRateLimit(): { lastUpdatedAt: number; limit: number; remaining: number; resetsAt: number; sourceId: string; } | null

Defined in: ../../../packages/contracts/src/capabilities/review/types.ts:150

Get current rate limit state.

Current rate limit or null if not applicable

{ lastUpdatedAt: number; limit: number; remaining: number; resetsAt: number; sourceId: string; }

lastUpdatedAt: number

Epoch ms when this was last updated

limit: number

Total limit

remaining: number

Remaining review triggers

resetsAt: number

Epoch ms when limit resets

sourceId: string

Source that this rate limit applies to


null


optional trigger(params): Promise<ReviewTriggerResult>

Defined in: ../../../packages/contracts/src/capabilities/review/types.ts:139

Trigger a review (e.g., post “@coderabbitai review” comment).

ReviewTriggerParams & ReviewRequestContext

Trigger parameters merged with VCS routing context

Promise<ReviewTriggerResult>

Result indicating whether the trigger succeeded


optional validate(): Promise<{ error?: string; valid: boolean; }>

Defined in: ../../../packages/contracts/src/capability/types.ts:22

Optional validation method to check provider configuration/credentials.

Promise<{ error?: string; valid: boolean; }>

Validation result with optional error message

ICapabilityProvider.validate