Prismatic-skills integration-patterns
Architecture patterns, manifest usage, code generation guides, and reference documentation for building Prismatic Code Native Integrations.
install
source · Clone the upstream repo
git clone https://github.com/prismatic-io/prismatic-skills
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/prismatic-io/prismatic-skills "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/integration-patterns" ~/.claude/skills/prismatic-io-prismatic-skills-integration-patterns && rm -rf "$T"
manifest:
skills/integration-patterns/SKILL.mdsource content
Integration Patterns
Reference documentation for building Prismatic Code Native Integrations (CNI).
<disallowed-tools> Do NOT use these MCP tools — they return incomplete data that causes broken scaffolds and missing connections downstream. A hook will deny them, but avoid the wasted round trip.
— Usemcp__prism__prism_components_list
insteadrun.ts find-components <keyword>
— Usemcp__prism__prism_components_init
insteadrun.ts scaffold-component
— Usemcp__prism__prism_components_publish
insteadrun.ts publish-component
— Manifests are auto-generated during scaffoldingmcp__prism__prism_components_generate_manifest
— Handled bymcp__prism__prism_install_component_manifestrun.ts scaffold-project --components
— Handled bymcp__prism__prism_install_legacy_component_manifest
</disallowed-tools>run.ts scaffold-project --components
Architecture Patterns
Standard Integration Pattern
- Components accessed via manifests and componentRegistry
- Standard connection configuration
- Any component/manifest combination
Component Manifest Pattern
All components are accessed via manifests:
- Install:
npx cni-component-manifest <component-key> - Register in componentRegistry.ts with
componentManifests() - Import actions and call
:.perform()import slackActions from "./manifests/slack/actions"; await slackActions.postMessage.perform({...})
- See
references/manifest-pattern.md
Config Mantra
Every config element MUST use wrapper functions:
for simple valuesconfigVar()
for connectionsconnectionConfigVar()
for data sourcesdataSourceConfigVar()- See
references/cni-examples/config-patterns-correct-vs-incorrect.md
Phase: Inline API Research
When the DAG emits
status: "inline_task" for API research, perform the research directly (no sub-agent). Key strategies:
- Start broad: First WebFetch fetches the entry-point URL with a comprehensive prompt extracting auth, base URL, endpoints, webhooks, and rate limits in one pass
- Anchor deduplication: Many APIs publish all docs on a single page with
links. Strip fragments before fetching —#anchor
is the same page ashttps://docs.example.com/api#postshttps://docs.example.com/api - Follow-up fetches: Only for genuinely different URL paths (e.g.,
vs/api/authentication
)/api - Max 10 WebFetch calls: If docs are insufficient after 10 fetches, note gaps and move on
- Official docs only: Stay on the documentation domain. No third-party sources (Zapier, Make, Stack Overflow)
- Auth priority: OAuth2 > API Key > Bearer Token > Basic Auth
- Output format: Structured JSON with
,authentication
,baseUrl
,resources
,webhooksrateLimiting - See
for connection setup patternsreferences/cni-examples/component-auth-patterns.md
Phase-Specific References
Load only the references relevant to your current workflow phase. This keeps context focused and avoids attention budget waste.
All Phases: Voice & Narration
- Orby's voice, personality traits, explanation depth rules, and phase milestone templates. Load at session start.references/narration-guide.md
Phase 2: Requirements Gathering
- Spec items now carry
(narration backbone),agent_context
(per-option consequence maps), andimplications
(Prismatic doc URLs). The agent uses these inline — no external references needed for most questions. Docs are fetched on demand only when agent_context is insufficient or the user asks a follow-up beyond what the curated content covers.docs
Phase 3: Credential Collection
- Authentication setupreferences/auth-setup.md
Phase 4: Scaffold
- Component manifest usage patternsreferences/manifest-pattern.md
- Spectral SDK basicsreferences/spectral-quickstart.md
- SDK type reference — authoritative source for flow, errorConfig, retryConfig, queueConfig, configVar types. When the YAML spec and these types disagree, the types win.references/spectral-types.md
Phase 5: Code Generation (PRIMARY PHASE)
See the
<spec-loading> block in cni-builder.md for progressive disclosure rules.
The references below are the full set available — load per the agent's guidance.
- LOAD FIRST — Maps integration.yaml answers directly to TypeScript code snippets. Spec items withreferences/answer-to-code-cookbook.md
fields point to specific headings in this file — Grep for those headings to find exact patterns, especially after context compaction.cookbook_section
- SDK type reference — validate generated code against actual typesreferences/spectral-types.md
- File generation patterns and context objectreferences/code-generation-guide.md
- Common mistakes — wrong/right examples for config pages, flow callbacks, imports, component usage, trigger configuration. Consult when prismatic-tools validate-phase returns guidance items.references/code-anti-patterns.md
- Writing style rules for generatedreferences/documentation-style.md
files (no second-person pronouns, no product name, active voice)documentation.md
- Config wrapper functions (CRITICAL)references/cni-examples/config-patterns-correct-vs-incorrect.md
- Component usage patternsreferences/cni-examples/using-components.md
- Test data structure requirementsreferences/trigger-metadata-spec.md- Templates:
- Structural templates for all source files${CLAUDE_PLUGIN_ROOT}/templates/integration/
Conditional references for Phase 5 (load based on requirements):
- If webhook trigger:
,references/cni-examples/webhook-patterns.mdreferences/cni-examples/webhook-payload-access.md - If lifecycle hooks needed:
references/cni-examples/lifecycle-events.md - If state persistence needed:
references/cni-examples/state-persistence.md - If OAuth connection:
references/cni-examples/oauth-connection.md - If multi-flow:
references/cni-examples/multi-flow.md - If data sources:
references/cni-examples/data-sources.md - If JSON forms:
references/cni-examples/json-forms.md - If integration-agnostic connections:
references/cni-examples/integration-agnostic-connections.md - If templated connections:
references/cni-examples/templated-connections.md - If no component exists for source/destination:
references/cni-examples/direct-http-patterns.md - After code generation, run
to confirm requirements were transcribed into generated codeprismatic-tools verify-code
Phase 6-7: Build, Deploy & Test
- Common errors and fixesreferences/troubleshooting-errors.md
- Test and debug patternsreferences/cni-examples/testing-debugging.md
- Error handling patternsreferences/cni-examples/error-handling.md
Phase 8: Iterate
- Network setup (if connectivity issues)references/network-configuration.md
All References
Full reference list for manual lookup:
- Orby voice, personality, explanation depth, phase milestonesreferences/narration-guide.md
- Maps integration.yaml answers → TypeScript codereferences/answer-to-code-cookbook.md
- Common code generation mistakes with wrong/right examplesreferences/code-anti-patterns.md
- Writing style rules for generated documentation.mdreferences/documentation-style.md
- Complete phase-by-phase workflowreferences/workflow-phases.md
- Workflow overviewreferences/workflow-guide.md
- File generation patterns and context objectreferences/code-generation-guide.md
- Component manifest usage patternsreferences/manifest-pattern.md
- Authentication setupreferences/auth-setup.md
- Network setupreferences/network-configuration.md
- Spectral SDK basicsreferences/spectral-quickstart.md
- Test data structure requirementsreferences/trigger-metadata-spec.md
- Common errors and fixesreferences/troubleshooting-errors.md
- Simple integrationreferences/cni-examples/basic-api-to-slack.md
- Webhook handlingreferences/cni-examples/webhook-patterns.md
- Accessing trigger payloadsreferences/cni-examples/webhook-payload-access.md
- onInstanceDeploy, onInstanceDeletereferences/cni-examples/lifecycle-events.md
- State types and usagereferences/cni-examples/state-persistence.md
- Config wrapper functionsreferences/cni-examples/config-patterns-correct-vs-incorrect.md
- Data source patternsreferences/cni-examples/data-sources.md
- JSON Forms for complex configreferences/cni-examples/json-forms.md
- Multi-flow integrationsreferences/cni-examples/multi-flow.md
- OAuth connection setupreferences/cni-examples/oauth-connection.md
- Component usage patternsreferences/cni-examples/using-components.md
- Error handling patternsreferences/cni-examples/error-handling.md
- Shared connectionsreferences/cni-examples/integration-agnostic-connections.md
- Templated connection patternsreferences/cni-examples/templated-connections.md
- Test and debug patternsreferences/cni-examples/testing-debugging.md
- Direct HTTP/axios patterns when no component existsreferences/cni-examples/direct-http-patterns.md