@signaliz/sdk 1.0.64 → 1.0.65
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-PDOG4IUP.mjs → chunk-FOHZG634.mjs} +13 -7
- package/dist/index.d.mts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +13 -7
- package/dist/index.mjs +1 -1
- package/dist/mcp-config.js +13 -7
- package/dist/mcp-config.mjs +1 -1
- package/package.json +1 -1
|
@@ -1911,6 +1911,16 @@ function normalizeSignalDiscoverySignal(value) {
|
|
|
1911
1911
|
if (!companyName || !companyDomain) {
|
|
1912
1912
|
throw new Error("Signals Everything response violated the company attribution contract.");
|
|
1913
1913
|
}
|
|
1914
|
+
const eventDate = String(signal.event_date ?? signal.date ?? signal.signal_date ?? "").trim();
|
|
1915
|
+
const sourceUrl = String(signal.source_url ?? signal.url ?? "").trim();
|
|
1916
|
+
const evidence = Array.isArray(signal.evidence) ? signal.evidence.map((item) => ({
|
|
1917
|
+
url: String(item?.url ?? "").trim(),
|
|
1918
|
+
publishedAt: String(item?.published_at ?? item?.publishedAt ?? "").trim(),
|
|
1919
|
+
source: String(item?.source ?? "").trim()
|
|
1920
|
+
})).filter((item) => Boolean(item.url)) : [];
|
|
1921
|
+
if (!eventDate || !sourceUrl || !evidence.some((item) => item.url === sourceUrl && item.publishedAt === eventDate)) {
|
|
1922
|
+
throw new Error("Signals Everything response violated the dated-evidence and source-URL contract.");
|
|
1923
|
+
}
|
|
1914
1924
|
return {
|
|
1915
1925
|
id: signal.id,
|
|
1916
1926
|
company: {
|
|
@@ -1921,16 +1931,12 @@ function normalizeSignalDiscoverySignal(value) {
|
|
|
1921
1931
|
title: signal.title ?? "",
|
|
1922
1932
|
type: signal.type ?? signal.signal_type ?? "unknown",
|
|
1923
1933
|
summary: signal.summary ?? signal.content ?? signal.description ?? "",
|
|
1924
|
-
eventDate
|
|
1925
|
-
evidence
|
|
1926
|
-
url: String(item?.url ?? ""),
|
|
1927
|
-
publishedAt: String(item?.published_at ?? item?.publishedAt ?? ""),
|
|
1928
|
-
source: String(item?.source ?? "")
|
|
1929
|
-
})).filter((item) => Boolean(item.url)) : [],
|
|
1934
|
+
eventDate,
|
|
1935
|
+
evidence,
|
|
1930
1936
|
content: signal.summary ?? signal.content ?? signal.description ?? "",
|
|
1931
1937
|
date: signal.event_date ?? signal.date ?? signal.signal_date ?? null,
|
|
1932
1938
|
detectedAt: signal.event_date ?? signal.detected_at ?? null,
|
|
1933
|
-
sourceUrl
|
|
1939
|
+
sourceUrl,
|
|
1934
1940
|
sourceType: signal.source_type ?? null,
|
|
1935
1941
|
confidence: signal.confidence ?? signal.confidence_score ?? null,
|
|
1936
1942
|
classification: signal.signal_classification ?? signal.classification ?? null,
|
package/dist/index.d.mts
CHANGED
|
@@ -373,7 +373,7 @@ interface SignalDiscoverySignal {
|
|
|
373
373
|
title: string;
|
|
374
374
|
type: string;
|
|
375
375
|
summary: string;
|
|
376
|
-
eventDate
|
|
376
|
+
eventDate: string;
|
|
377
377
|
evidence: Array<{
|
|
378
378
|
url: string;
|
|
379
379
|
publishedAt: string;
|
|
@@ -384,7 +384,7 @@ interface SignalDiscoverySignal {
|
|
|
384
384
|
/** Compatibility alias for eventDate. */
|
|
385
385
|
date?: string | null;
|
|
386
386
|
detectedAt?: string | null;
|
|
387
|
-
sourceUrl
|
|
387
|
+
sourceUrl: string;
|
|
388
388
|
sourceType?: string | null;
|
|
389
389
|
confidence?: number | null;
|
|
390
390
|
classification?: Record<string, unknown> | string | null;
|
package/dist/index.d.ts
CHANGED
|
@@ -373,7 +373,7 @@ interface SignalDiscoverySignal {
|
|
|
373
373
|
title: string;
|
|
374
374
|
type: string;
|
|
375
375
|
summary: string;
|
|
376
|
-
eventDate
|
|
376
|
+
eventDate: string;
|
|
377
377
|
evidence: Array<{
|
|
378
378
|
url: string;
|
|
379
379
|
publishedAt: string;
|
|
@@ -384,7 +384,7 @@ interface SignalDiscoverySignal {
|
|
|
384
384
|
/** Compatibility alias for eventDate. */
|
|
385
385
|
date?: string | null;
|
|
386
386
|
detectedAt?: string | null;
|
|
387
|
-
sourceUrl
|
|
387
|
+
sourceUrl: string;
|
|
388
388
|
sourceType?: string | null;
|
|
389
389
|
confidence?: number | null;
|
|
390
390
|
classification?: Record<string, unknown> | string | null;
|
package/dist/index.js
CHANGED
|
@@ -1938,6 +1938,16 @@ function normalizeSignalDiscoverySignal(value) {
|
|
|
1938
1938
|
if (!companyName || !companyDomain) {
|
|
1939
1939
|
throw new Error("Signals Everything response violated the company attribution contract.");
|
|
1940
1940
|
}
|
|
1941
|
+
const eventDate = String(signal.event_date ?? signal.date ?? signal.signal_date ?? "").trim();
|
|
1942
|
+
const sourceUrl = String(signal.source_url ?? signal.url ?? "").trim();
|
|
1943
|
+
const evidence = Array.isArray(signal.evidence) ? signal.evidence.map((item) => ({
|
|
1944
|
+
url: String(item?.url ?? "").trim(),
|
|
1945
|
+
publishedAt: String(item?.published_at ?? item?.publishedAt ?? "").trim(),
|
|
1946
|
+
source: String(item?.source ?? "").trim()
|
|
1947
|
+
})).filter((item) => Boolean(item.url)) : [];
|
|
1948
|
+
if (!eventDate || !sourceUrl || !evidence.some((item) => item.url === sourceUrl && item.publishedAt === eventDate)) {
|
|
1949
|
+
throw new Error("Signals Everything response violated the dated-evidence and source-URL contract.");
|
|
1950
|
+
}
|
|
1941
1951
|
return {
|
|
1942
1952
|
id: signal.id,
|
|
1943
1953
|
company: {
|
|
@@ -1948,16 +1958,12 @@ function normalizeSignalDiscoverySignal(value) {
|
|
|
1948
1958
|
title: signal.title ?? "",
|
|
1949
1959
|
type: signal.type ?? signal.signal_type ?? "unknown",
|
|
1950
1960
|
summary: signal.summary ?? signal.content ?? signal.description ?? "",
|
|
1951
|
-
eventDate
|
|
1952
|
-
evidence
|
|
1953
|
-
url: String(item?.url ?? ""),
|
|
1954
|
-
publishedAt: String(item?.published_at ?? item?.publishedAt ?? ""),
|
|
1955
|
-
source: String(item?.source ?? "")
|
|
1956
|
-
})).filter((item) => Boolean(item.url)) : [],
|
|
1961
|
+
eventDate,
|
|
1962
|
+
evidence,
|
|
1957
1963
|
content: signal.summary ?? signal.content ?? signal.description ?? "",
|
|
1958
1964
|
date: signal.event_date ?? signal.date ?? signal.signal_date ?? null,
|
|
1959
1965
|
detectedAt: signal.event_date ?? signal.detected_at ?? null,
|
|
1960
|
-
sourceUrl
|
|
1966
|
+
sourceUrl,
|
|
1961
1967
|
sourceType: signal.source_type ?? null,
|
|
1962
1968
|
confidence: signal.confidence ?? signal.confidence_score ?? null,
|
|
1963
1969
|
classification: signal.signal_classification ?? signal.classification ?? null,
|
package/dist/index.mjs
CHANGED
package/dist/mcp-config.js
CHANGED
|
@@ -1942,6 +1942,16 @@ function normalizeSignalDiscoverySignal(value) {
|
|
|
1942
1942
|
if (!companyName || !companyDomain) {
|
|
1943
1943
|
throw new Error("Signals Everything response violated the company attribution contract.");
|
|
1944
1944
|
}
|
|
1945
|
+
const eventDate = String(signal.event_date ?? signal.date ?? signal.signal_date ?? "").trim();
|
|
1946
|
+
const sourceUrl = String(signal.source_url ?? signal.url ?? "").trim();
|
|
1947
|
+
const evidence = Array.isArray(signal.evidence) ? signal.evidence.map((item) => ({
|
|
1948
|
+
url: String(item?.url ?? "").trim(),
|
|
1949
|
+
publishedAt: String(item?.published_at ?? item?.publishedAt ?? "").trim(),
|
|
1950
|
+
source: String(item?.source ?? "").trim()
|
|
1951
|
+
})).filter((item) => Boolean(item.url)) : [];
|
|
1952
|
+
if (!eventDate || !sourceUrl || !evidence.some((item) => item.url === sourceUrl && item.publishedAt === eventDate)) {
|
|
1953
|
+
throw new Error("Signals Everything response violated the dated-evidence and source-URL contract.");
|
|
1954
|
+
}
|
|
1945
1955
|
return {
|
|
1946
1956
|
id: signal.id,
|
|
1947
1957
|
company: {
|
|
@@ -1952,16 +1962,12 @@ function normalizeSignalDiscoverySignal(value) {
|
|
|
1952
1962
|
title: signal.title ?? "",
|
|
1953
1963
|
type: signal.type ?? signal.signal_type ?? "unknown",
|
|
1954
1964
|
summary: signal.summary ?? signal.content ?? signal.description ?? "",
|
|
1955
|
-
eventDate
|
|
1956
|
-
evidence
|
|
1957
|
-
url: String(item?.url ?? ""),
|
|
1958
|
-
publishedAt: String(item?.published_at ?? item?.publishedAt ?? ""),
|
|
1959
|
-
source: String(item?.source ?? "")
|
|
1960
|
-
})).filter((item) => Boolean(item.url)) : [],
|
|
1965
|
+
eventDate,
|
|
1966
|
+
evidence,
|
|
1961
1967
|
content: signal.summary ?? signal.content ?? signal.description ?? "",
|
|
1962
1968
|
date: signal.event_date ?? signal.date ?? signal.signal_date ?? null,
|
|
1963
1969
|
detectedAt: signal.event_date ?? signal.detected_at ?? null,
|
|
1964
|
-
sourceUrl
|
|
1970
|
+
sourceUrl,
|
|
1965
1971
|
sourceType: signal.source_type ?? null,
|
|
1966
1972
|
confidence: signal.confidence ?? signal.confidence_score ?? null,
|
|
1967
1973
|
classification: signal.signal_classification ?? signal.classification ?? null,
|
package/dist/mcp-config.mjs
CHANGED
package/package.json
CHANGED