@forsyteco/app-provider
v1.0.0
Published
Provider SDK contract for Forsyte app/integration adapters, grouped by capability (documents, contacts, matters, practice).
Downloads
125
Readme
@forsyteco/app-provider
Provider SDK contract for Forsyte app/integration adapters.
This package defines a generic app/integration contract grouped by capability, so an integration declares only what it can do:
- documents (read + write): folders, documents, tree,
get_document(pull content into Forsyte),create_document(push a document, e.g. a risk-assessment PDF, to the source) - contacts: contacts (with
ContactType), addresses, andPartyType(the role a contact plays on a matter — "Client" is aPartyTypevalue, not the entity) - matters: matters, matter types, practice areas, users
- practice (writes): posting slips, disbursements, notes (
NoteType=file | assessment)
It is standalone and intentionally independent of @forsyteco/data-gateway-provider; the two may
coexist while consumers migrate.
Operation naming convention
list_*— fetch many (read)get_*— fetch one including its content (read)create_*— write one to the source system
Install
pnpm add @forsyteco/app-providerBuild
pnpm build
pnpm typecheck
pnpm test
pnpm test:covPublic API
Import from the root barrel or per-capability subpaths:
import { AppCapability, ProviderCapabilities, PROVIDER_CAPABILITIES } from "@forsyteco/app-provider";
import { FoldersRepository, DocumentsRepository } from "@forsyteco/app-provider/documents";
import { ContactsRepository, PartyType } from "@forsyteco/app-provider/contacts";
import { MattersRepository } from "@forsyteco/app-provider/matters";
import { NotesRepository, NoteType } from "@forsyteco/app-provider/practice";License
Apache-2.0
