live · mainnetoc · docs
specs · api · guides
docs / documentation

@orangecheck/me-client


@orangecheck/me-client / configFromTemplate

Function: configFromTemplate()

function configFromTemplate(useCase: IntegratorArchetype, identity: ProjectIdentity): IntegratorPriceConfig;

Defined in: me-client/src/templates.ts:292

Build a complete IntegratorPriceConfig from an archetype id + the project's identity fields. Every subtype gets an entry — the archetype's listed subtypes get the template's pricing; everything else gets enabled: false with conservative defaults so the config is type-complete and the integrator can flip-on later subtypes without re-deriving prices.

Throws synchronously if useCase isn't a known archetype id.

Parameters

ParameterType
useCaseIntegratorArchetype
identityProjectIdentity

Returns

IntegratorPriceConfig