MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / headerToConfigValue

Function headerToConfigValue

packages/core/config/src/sink.ts:25–29  ·  view source on GitHub ↗
(value: PluginHeaderValue)

Source from the content-addressed store, hash-verified

23type PluginHeaderValue = string | { secretId: string; prefix?: string };
24
25export const headerToConfigValue = (value: PluginHeaderValue): ConfigHeaderValue => {
26 if (typeof value === "string") return value;
27 const ref = `${SECRET_REF_PREFIX}${value.secretId}`;
28 return value.prefix ? { value: ref, prefix: value.prefix } : ref;
29};
30
31export const headersToConfigValues = (
32 headers: Record<string, PluginHeaderValue> | undefined,

Callers 1

headersToConfigValuesFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected