@goperigon/perigon-ts 4.6.2 → 4.7.0
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/index.cjs +1 -1
- package/dist/index.d.ts +67 -0
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
'use strict';var zod=require('zod');var We="https://api.perigon.io".replace(/\/+$/,""),w=class{constructor(o={}){this.configuration=o;}set config(o){this.configuration=o;}get basePath(){return We}get fetchApi(){return this.configuration.fetchApi}get middleware(){return this.configuration.middleware||[]}get queryParamsStringify(){return this.configuration.queryParamsStringify||B}get accessToken(){let o=this.configuration.apiKey;return o?typeof o=="function"?o:async()=>o:void 0}get headers(){return this.configuration.headers}get credentials(){return this.configuration.credentials}},Ge=new w,k=class extends Error{constructor(a,i){super(i);this.cause=a;this.name="FetchError";}},m=class extends Error{constructor(o,a){let i=`HTTP ${o.status}: ${o.statusText}`;super(i),this.name="HttpError",this.status=o.status,this.statusText=o.statusText,this.response=o,this.body=a;}},P=class extends m{constructor(o,a){super(o,a),this.name="BadRequestError",this.message=a?.message||"Bad request - please check your input parameters";}},q=class extends m{constructor(o,a){super(o,a),this.name="UnauthorizedError",this.message="Authentication required - please check your credentials";}},C=class extends m{constructor(o,a){super(o,a),this.name="ForbiddenError",this.message="Access denied - insufficient permissions";}},j=class extends m{constructor(o,a){super(o,a),this.name="NotFoundError",this.message=a?.message||"Resource not found";}},A=class extends m{constructor(o,a){super(o,a),this.name="RateLimitError",this.message="Rate limit exceeded - please try again later";let i=o.headers.get("retry-after");i&&(this.retryAfter=parseInt(i,10));}},I=class extends m{constructor(o,a){super(o,a),this.name="ServerError",this.message="Server error - please try again later";}},D=class extends Error{constructor(o){super("Network error - please check your connection"),this.name="NetworkError",this.cause=o;}};function De(u,o){return u.status===400?new P(u,o):u.status===401?new q(u,o):u.status===403?new C(u,o):u.status===404?new j(u,o):u.status===429?new A(u,o):u.status>499?new I(u,o):new m(u,o)}var b=class b{constructor(o=Ge){this.configuration=o;this.fetchApi=async(o,a)=>{let i={url:o,init:a};for(let n of this.middleware)n.pre&&(i=await n.pre({fetch:this.fetchApi,...i})||i);let r;try{r=await(this.configuration.fetchApi||fetch)(i.url,i.init);}catch(n){for(let p of this.middleware)p.onError&&(r=await p.onError({fetch:this.fetchApi,url:i.url,init:i.init,error:n,response:r?r.clone():void 0})||r);if(r===void 0)throw n instanceof Error?new k(n,"The request failed and the interceptors did not return an alternative response"):n}for(let n of this.middleware)n.post&&(r=await n.post({fetch:this.fetchApi,url:i.url,init:i.init,response:r.clone()})||r);return r};this.middleware=o.middleware;}withMiddleware(...o){let a=this.clone();return a.middleware=a.middleware.concat(...o),a}withPreMiddleware(...o){let a=o.map(i=>({pre:i}));return this.withMiddleware(...a)}withPostMiddleware(...o){let a=o.map(i=>({post:i}));return this.withMiddleware(...a)}isJsonMime(o){return o?b.jsonRegex.test(o):false}async request(o,a){let{url:i,init:r}=await this.createFetchParams(o,a),n=await this.fetchApi(i,r);if(n&&n.status>=200&&n.status<300)return n;let p;try{n.headers.get("content-type")?.includes("application/json")&&(p=await n.json());}catch{}throw De(n,p)}async createFetchParams(o,a){let i=this.configuration.basePath+o.path;o.query!==void 0&&Object.keys(o.query).length!==0&&(i+="?"+this.configuration.queryParamsStringify(o.query));let r=Object.assign({},this.configuration.headers,o.headers);Object.keys(r).forEach(G=>r[G]===void 0?delete r[G]:{});let n=typeof a=="function"?a:async()=>a,p={method:o.method,headers:r,body:o.body,credentials:this.configuration.credentials},s={...p,...await n({init:p,context:o})},l;Fe(s.body)||s.body instanceof URLSearchParams||Be(s.body)?l=s.body:this.isJsonMime(r["Content-Type"])?l=JSON.stringify(s.body):l=s.body;let c={...s,body:l};return {url:i,init:c}}clone(){let o=this.constructor,a=new o(this.configuration);return a.middleware=this.middleware.slice(),a}};b.jsonRegex=new RegExp("^(:?application/json|[^;/ ]+/[^;/ ]+[+]json)[ ]*(:?;.*)?$","i");var g=b;function Be(u){return typeof Blob<"u"&&u instanceof Blob}function Fe(u){return typeof FormData<"u"&&u instanceof FormData}var eo={csv:",",ssv:" ",tsv:" ",pipes:"|"};function B(u,o=""){return Object.keys(u).map(a=>F(a,u[a],o)).filter(a=>a.length>0).join("&")}function F(u,o,a=""){let i=a+(a.length?`[${u}]`:u);if(o instanceof Array){let r=o.map(n=>encodeURIComponent(String(n))).join(`&${encodeURIComponent(i)}=`);return `${encodeURIComponent(i)}=${r}`}if(o instanceof Set){let r=Array.from(o);return F(u,r,a)}return o instanceof Date?`${encodeURIComponent(i)}=${encodeURIComponent(o.toISOString())}`:o instanceof Object?B(o,i):`${encodeURIComponent(i)}=${encodeURIComponent(String(o))}`}function to(u,o){let a=u[o];return a!=null}var R=zod.z.enum(["createdAt","updatedAt","relevance","count","totalCount"]),ao={CreatedAt:"createdAt",UpdatedAt:"updatedAt",Relevance:"relevance",Count:"count",TotalCount:"totalCount"},z=zod.z.enum(["relevance","date","reverseDate","reverseAddDate","addDate","pubDate","refreshDate"]),no={Relevance:"relevance",Date:"date",ReverseDate:"reverseDate",ReverseAddDate:"reverseAddDate",AddDate:"addDate",PubDate:"pubDate",RefreshDate:"refreshDate"},H=zod.z.object({name:zod.z.string().optional().nullable()}),Oe=zod.z.object({name:zod.z.string().optional().nullable(),score:zod.z.number().optional().nullable()}),O=zod.z.object({id:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),domains:zod.z.array(zod.z.string()).optional().nullable(),symbols:zod.z.array(zod.z.string()).optional().nullable()}),Le=zod.z.object({data:zod.z.string().optional().nullable(),type:zod.z.string().optional().nullable(),mentions:zod.z.number().optional().nullable()}),Ne=zod.z.object({name:zod.z.string().optional().nullable(),type:zod.z.string().optional().nullable()}),Ue=zod.z.object({id:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable()}),v=zod.z.object({country:zod.z.string().optional().nullable(),state:zod.z.string().optional().nullable(),county:zod.z.string().optional().nullable(),city:zod.z.string().optional().nullable(),area:zod.z.string().optional().nullable()}),h=zod.z.object({name:zod.z.string().optional().nullable(),count:zod.z.number().optional().nullable()}),T=zod.z.object({id:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),fullName:zod.z.string().optional().nullable(),headline:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),title:zod.z.string().optional().nullable(),locations:zod.z.array(v).optional().nullable(),updatedAt:zod.z.string().optional().nullable(),topTopics:zod.z.array(h).optional().nullable(),topSources:zod.z.array(h).optional().nullable(),topCategories:zod.z.array(h).optional().nullable(),topLabels:zod.z.array(h).optional().nullable(),topCountries:zod.z.array(h).optional().nullable(),avgMonthlyPosts:zod.z.number().optional().nullable(),twitterHandle:zod.z.string().optional().nullable(),twitterBio:zod.z.string().optional().nullable(),imageUrl:zod.z.string().optional().nullable(),linkedinUrl:zod.z.string().optional().nullable(),linkedinConnections:zod.z.number().optional().nullable(),linkedinFollowers:zod.z.number().optional().nullable(),facebookUrl:zod.z.string().optional().nullable(),instagramUrl:zod.z.string().optional().nullable(),websiteUrl:zod.z.string().optional().nullable(),blogUrl:zod.z.string().optional().nullable(),tumblrUrl:zod.z.string().optional().nullable(),youtubeUrl:zod.z.string().optional().nullable()}),Me=zod.z.object({name:zod.z.string().optional().nullable(),weight:zod.z.number().optional().nullable()}),$e=zod.z.object({name:zod.z.string().optional().nullable()}),Ke=zod.z.object({id:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),domains:zod.z.array(zod.z.string()).optional().nullable(),symbols:zod.z.array(zod.z.string()).optional().nullable(),count:zod.z.number().optional().nullable()}),L=zod.z.object({point:zod.z.string().optional().nullable(),references:zod.z.array(zod.z.string()).optional().nullable()}),Qe=zod.z.object({country:zod.z.string().optional().nullable(),state:zod.z.string().optional().nullable(),county:zod.z.string().optional().nullable(),city:zod.z.string().optional().nullable(),area:zod.z.string().optional().nullable(),count:zod.z.number().optional().nullable()}),Ve=zod.z.object({wikidataId:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),count:zod.z.number().optional().nullable()}),N=zod.z.object({wikidataId:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable()}),U=zod.z.object({question:zod.z.string().optional().nullable(),answer:zod.z.string().optional().nullable(),references:zod.z.array(zod.z.string()).optional().nullable()}),S=zod.z.object({name:zod.z.string().optional().nullable(),count:zod.z.number().optional().nullable()}),M=zod.z.object({positive:zod.z.number().optional().nullable(),negative:zod.z.number().optional().nullable(),neutral:zod.z.number().optional().nullable()}),$=zod.z.object({lat:zod.z.number().optional().nullable(),lon:zod.z.number().optional().nullable()}),K=zod.z.object({country:zod.z.string().optional().nullable(),state:zod.z.string().optional().nullable(),county:zod.z.string().optional().nullable(),city:zod.z.string().optional().nullable(),coordinates:$.optional().nullable()}),Q=zod.z.object({domain:zod.z.string().optional().nullable(),paywall:zod.z.boolean().optional().nullable(),location:K.optional().nullable()}),V=zod.z.object({name:zod.z.string().optional().nullable()}),J=zod.z.object({createdAt:zod.z.string().optional().nullable(),updatedAt:zod.z.string().optional().nullable(),initializedAt:zod.z.string().optional().nullable(),id:zod.z.string().optional().nullable(),duplicateOf:zod.z.string().optional().nullable(),slug:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),summary:zod.z.string().optional().nullable(),shortSummary:zod.z.string().optional().nullable(),summaryReferences:zod.z.array(zod.z.string()).optional().nullable(),imageSource:Q.optional().nullable(),imageUrl:zod.z.string().optional().nullable(),keyPoints:zod.z.array(L).optional().nullable(),questions:zod.z.array(U).optional().nullable(),uniqueSources:zod.z.array(zod.z.string()).optional().nullable(),selectedArticles:zod.z.array(zod.z.unknown()).optional().nullable(),sentiment:M.optional().nullable(),uniqueCount:zod.z.number().optional().nullable(),reprintCount:zod.z.number().optional().nullable(),totalCount:zod.z.number().optional().nullable(),countries:zod.z.array(S).optional().nullable(),topCountries:zod.z.array(zod.z.string()).optional().nullable(),topics:zod.z.array(S).optional().nullable(),topTopics:zod.z.array(V).optional().nullable(),categories:zod.z.array(S).optional().nullable(),topCategories:zod.z.array(H).optional().nullable(),taxonomies:zod.z.array(S).optional().nullable(),topTaxonomies:zod.z.array(H).optional().nullable(),people:zod.z.array(Ve).optional().nullable(),topPeople:zod.z.array(N).optional().nullable(),companies:zod.z.array(Ke).optional().nullable(),topCompanies:zod.z.array(O).optional().nullable(),locations:zod.z.array(Qe).optional().nullable(),topLocations:zod.z.array(v).optional().nullable(),highlights:zod.z.record(zod.z.string(),zod.z.array(zod.z.string())).optional().nullable()}),Je=zod.z.object({osmId:zod.z.string().optional().nullable(),road:zod.z.string().optional().nullable(),quarter:zod.z.string().optional().nullable(),suburb:zod.z.string().optional().nullable(),city:zod.z.string().optional().nullable(),town:zod.z.string().optional().nullable(),county:zod.z.string().optional().nullable(),stateDistrict:zod.z.string().optional().nullable(),state:zod.z.string().optional().nullable(),postcode:zod.z.string().optional().nullable(),country:zod.z.string().optional().nullable(),countryCode:zod.z.string().optional().nullable(),amenity:zod.z.string().optional().nullable(),neighbourhood:zod.z.string().optional().nullable(),coordinates:$.optional().nullable()}),W=zod.z.object({url:zod.z.string().optional().nullable(),authorsByline:zod.z.string().optional().nullable(),articleId:zod.z.string().optional().nullable(),clusterId:zod.z.string().optional().nullable(),source:Q.optional().nullable(),imageUrl:zod.z.string().optional().nullable(),country:zod.z.string().optional().nullable(),language:zod.z.string().optional().nullable(),pubDate:zod.z.string().optional().nullable(),addDate:zod.z.string().optional().nullable(),refreshDate:zod.z.string().optional().nullable(),score:zod.z.number().optional().nullable(),title:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),content:zod.z.string().optional().nullable(),enContentWordCount:zod.z.number().optional().nullable(),medium:zod.z.string().optional().nullable(),links:zod.z.array(zod.z.string()).optional().nullable(),labels:zod.z.array($e).optional().nullable(),eventTypes:zod.z.array(Ne).optional().nullable(),matchedAuthors:zod.z.array(Ue).optional().nullable(),claim:zod.z.string().optional().nullable(),verdict:zod.z.string().optional().nullable(),keywords:zod.z.array(Me).optional().nullable(),topics:zod.z.array(V).optional().nullable(),categories:zod.z.array(H).optional().nullable(),taxonomies:zod.z.array(Oe).optional().nullable(),entities:zod.z.array(Le).optional().nullable(),companies:zod.z.array(O).optional().nullable(),sentiment:M.optional().nullable(),summary:zod.z.string().optional().nullable(),shortSummary:zod.z.string().optional().nullable(),translation:zod.z.string().optional().nullable(),translatedTitle:zod.z.string().optional().nullable(),translatedDescription:zod.z.string().optional().nullable(),translatedSummary:zod.z.string().optional().nullable(),locations:zod.z.array(v).optional().nullable(),reprint:zod.z.boolean().optional().nullable(),reprintGroupId:zod.z.string().optional().nullable(),places:zod.z.array(Je).optional().nullable(),people:zod.z.array(N).optional().nullable(),cluster:J.optional().nullable(),journalists:zod.z.array(T).optional().nullable(),highlights:zod.z.record(zod.z.string(),zod.z.array(zod.z.string())).optional().nullable()}),E=zod.z.object({lat:zod.z.number().optional().nullable(),lon:zod.z.number().optional().nullable(),radius:zod.z.number().optional().nullable()}),Ye=zod.z.object({articleId:zod.z.array(zod.z.string()).optional().nullable(),clusterId:zod.z.array(zod.z.string()).optional().nullable(),source:zod.z.array(zod.z.string()).optional().nullable(),excludeSource:zod.z.array(zod.z.string()).optional().nullable(),sourceGroup:zod.z.array(zod.z.string()).optional().nullable(),language:zod.z.array(zod.z.string()).optional().nullable(),excludeLanguage:zod.z.array(zod.z.string()).optional().nullable(),label:zod.z.array(zod.z.string()).optional().nullable(),excludeLabel:zod.z.array(zod.z.string()).optional().nullable(),taxonomy:zod.z.array(zod.z.string()).optional().nullable(),category:zod.z.array(zod.z.string()).optional().nullable(),topic:zod.z.array(zod.z.string()).optional().nullable(),excludeTopic:zod.z.array(zod.z.string()).optional().nullable(),country:zod.z.array(zod.z.string()).optional().nullable(),excludeCountry:zod.z.array(zod.z.string()).optional().nullable(),locationsCountry:zod.z.array(zod.z.string()).optional().nullable(),excludeLocationsCountry:zod.z.array(zod.z.string()).optional().nullable(),state:zod.z.array(zod.z.string()).optional().nullable(),excludeState:zod.z.array(zod.z.string()).optional().nullable(),county:zod.z.array(zod.z.string()).optional().nullable(),excludeCounty:zod.z.array(zod.z.string()).optional().nullable(),city:zod.z.array(zod.z.string()).optional().nullable(),excludeCity:zod.z.array(zod.z.string()).optional().nullable(),sourceCountry:zod.z.array(zod.z.string()).optional().nullable(),sourceState:zod.z.array(zod.z.string()).optional().nullable(),sourceCounty:zod.z.array(zod.z.string()).optional().nullable(),sourceCity:zod.z.array(zod.z.string()).optional().nullable(),coordinates:E.optional().nullable(),sourceCoordinates:E.optional().nullable(),companyId:zod.z.array(zod.z.string()).optional().nullable(),excludeCompanyId:zod.z.array(zod.z.string()).optional().nullable(),companyDomain:zod.z.array(zod.z.string()).optional().nullable(),excludeCompanyDomain:zod.z.array(zod.z.string()).optional().nullable(),companySymbol:zod.z.array(zod.z.string()).optional().nullable(),excludeCompanySymbol:zod.z.array(zod.z.string()).optional().nullable(),companyName:zod.z.array(zod.z.string()).optional().nullable(),personWikidataId:zod.z.array(zod.z.string()).optional().nullable(),excludePersonWikidataId:zod.z.array(zod.z.string()).optional().nullable(),personName:zod.z.array(zod.z.string()).optional().nullable(),excludePersonName:zod.z.array(zod.z.string()).optional().nullable(),AND:zod.z.array(zod.z.unknown()).optional().nullable(),OR:zod.z.array(zod.z.unknown()).optional().nullable(),NOT:zod.z.array(zod.z.unknown()).optional().nullable()}),Y=zod.z.object({prompt:zod.z.string(),filter:Ye.optional().nullable(),pubDateFrom:zod.z.union([zod.z.string().date(),zod.z.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),pubDateTo:zod.z.union([zod.z.string().date(),zod.z.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),showReprints:zod.z.boolean().optional().nullable(),size:zod.z.number().optional().nullable(),page:zod.z.number().optional().nullable()}),_e=zod.z.object({score:zod.z.number().optional().nullable(),data:W.optional().nullable()}),_=zod.z.object({status:zod.z.number(),results:zod.z.array(_e)}),Xe=zod.z.object({symbol:zod.z.string().optional().nullable(),exchange:zod.z.string().optional().nullable(),exchangeShortName:zod.z.string().optional().nullable(),ipoDate:zod.z.string().optional().nullable()}),Ze=zod.z.object({careers:zod.z.string().optional().nullable(),about:zod.z.string().optional().nullable(),blog:zod.z.string().optional().nullable(),events:zod.z.string().optional().nullable(),sitemap:zod.z.string().optional().nullable(),updates:zod.z.string().optional().nullable(),linkedin:zod.z.string().optional().nullable(),facebook:zod.z.string().optional().nullable(),instagram:zod.z.string().optional().nullable(),medium:zod.z.string().optional().nullable(),reddit:zod.z.string().optional().nullable(),threads:zod.z.string().optional().nullable(),tiktok:zod.z.string().optional().nullable(),x:zod.z.string().optional().nullable(),wellfound:zod.z.string().optional().nullable(),youtube:zod.z.string().optional().nullable(),wikipedia:zod.z.string().optional().nullable()}),et=zod.z.object({id:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),updatedAt:zod.z.string().optional().nullable(),primaryRecordId:zod.z.string().optional().nullable(),altNames:zod.z.array(zod.z.string()).optional().nullable(),domains:zod.z.array(zod.z.string()).optional().nullable(),monthlyVisits:zod.z.number().optional().nullable(),globalRank:zod.z.number().optional().nullable(),description:zod.z.string().optional().nullable(),ceo:zod.z.string().optional().nullable(),industry:zod.z.string().optional().nullable(),sector:zod.z.string().optional().nullable(),country:zod.z.string().optional().nullable(),fullTimeEmployees:zod.z.number().optional().nullable(),address:zod.z.string().optional().nullable(),city:zod.z.string().optional().nullable(),state:zod.z.string().optional().nullable(),zip:zod.z.string().optional().nullable(),logo:zod.z.string().optional().nullable(),favicon:zod.z.string().optional().nullable(),isEtf:zod.z.boolean().optional().nullable(),isActivelyTrading:zod.z.boolean().optional().nullable(),isFund:zod.z.boolean().optional().nullable(),isAdr:zod.z.boolean().optional().nullable(),symbols:zod.z.array(Xe).optional().nullable(),naics:zod.z.string().optional().nullable(),sic:zod.z.string().optional().nullable(),cusip:zod.z.string().optional().nullable(),cik:zod.z.string().optional().nullable(),isin:zod.z.string().optional().nullable(),yearFounded:zod.z.number().optional().nullable(),revenue:zod.z.string().optional().nullable(),webResources:Ze.optional().nullable()}),X=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),results:zod.z.array(et)}),Z=zod.z.object({name:zod.z.string(),displayName:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),domains:zod.z.array(zod.z.string())}),x=zod.z.object({url:zod.z.string().optional().nullable()}),y=zod.z.object({time:zod.z.string().optional().nullable(),precision:zod.z.string().optional().nullable()}),d=zod.z.object({wikidataId:zod.z.string().optional().nullable(),label:zod.z.string().optional().nullable()}),tt=zod.z.object({wikidataId:zod.z.string().optional().nullable(),label:zod.z.string().optional().nullable(),startTime:y.optional().nullable(),endTime:y.optional().nullable()}),ot=zod.z.object({wikidataId:zod.z.string().optional().nullable(),label:zod.z.string().optional().nullable(),startTime:y.optional().nullable(),endTime:y.optional().nullable(),employer:d.optional().nullable()}),at=zod.z.object({wikidataId:zod.z.string().optional().nullable(),createdAt:zod.z.string().optional().nullable(),updatedAt:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),gender:d.optional().nullable(),dateOfBirth:y.optional().nullable(),dateOfDeath:y.optional().nullable(),description:zod.z.string().optional().nullable(),aliases:zod.z.array(zod.z.string()).optional().nullable(),occupation:zod.z.array(d).optional().nullable(),position:zod.z.array(ot).optional().nullable(),politicalParty:zod.z.array(tt).optional().nullable(),image:x.optional().nullable(),_abstract:zod.z.string().optional().nullable()}),ee=zod.z.object({name:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),id:zod.z.string().optional().nullable(),domain:zod.z.string().optional().nullable(),aliases:zod.z.array(zod.z.string()).optional().nullable()}),te=zod.z.object({name:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),aliases:zod.z.array(zod.z.string()).optional().nullable(),wikidataId:zod.z.string().optional().nullable()}),oe=zod.z.object({name:zod.z.string(),displayName:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),people:zod.z.array(te),companies:zod.z.array(ee),visible:zod.z.boolean().optional().nullable()}),ro=zod.z.object({status:zod.z.number().optional().nullable(),message:zod.z.string().optional().nullable(),timestamp:zod.z.number().optional().nullable()}),ae=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),results:zod.z.array(T)}),ne=zod.z.object({name:zod.z.string().optional().nullable(),displayName:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),domains:zod.z.array(zod.z.string()).optional().nullable()}),re=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),results:zod.z.array(at)}),ie=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),articles:zod.z.array(W)}),nt=zod.z.object({pageId:zod.z.string().optional().nullable(),sectionId:zod.z.string().optional().nullable(),wikiPageId:zod.z.number().optional().nullable(),wikiRevisionId:zod.z.number().optional().nullable(),wikiRevisionTs:zod.z.string().optional().nullable(),wikiCode:zod.z.string().optional().nullable(),wikiNamespace:zod.z.number().optional().nullable(),wikiTitle:zod.z.string().optional().nullable(),wikidataId:zod.z.string().optional().nullable(),wikidataInstanceOf:zod.z.array(d).optional().nullable(),redirectTitles:zod.z.array(zod.z.string()).optional().nullable(),pageviews:zod.z.number().optional().nullable(),title:zod.z.string().optional().nullable(),styleLevel:zod.z.number().optional().nullable(),content:zod.z.string().optional().nullable()}),rt=zod.z.object({score:zod.z.number().optional().nullable(),data:nt.optional().nullable()}),f=zod.z.object({name:zod.z.string().optional().nullable(),count:zod.z.number().optional().nullable()}),it=zod.z.object({id:zod.z.string().optional().nullable(),domain:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),primaryRecordId:zod.z.string().optional().nullable(),updatedAt:zod.z.string().optional().nullable(),altNames:zod.z.array(zod.z.string()).optional().nullable(),description:zod.z.string().optional().nullable(),avgMonthlyPosts:zod.z.number().optional().nullable(),paywall:zod.z.boolean().optional().nullable(),location:K.optional().nullable(),topCategories:zod.z.array(f).optional().nullable(),topTopics:zod.z.array(f).optional().nullable(),topCountries:zod.z.array(f).optional().nullable(),topLabels:zod.z.array(f).optional().nullable(),avgBiasRating:zod.z.string().optional().nullable(),adFontesBiasRating:zod.z.string().optional().nullable(),allSidesBiasRating:zod.z.string().optional().nullable(),mbfcBiasRating:zod.z.string().optional().nullable(),monthlyVisits:zod.z.number().optional().nullable(),globalRank:zod.z.number().optional().nullable(),logoLarge:x.optional().nullable(),logoFavIcon:x.optional().nullable(),logoSquare:x.optional().nullable()}),le=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),results:zod.z.array(it)}),se=zod.z.object({status:zod.z.number().optional().nullable(),results:zod.z.array(zod.z.unknown()).optional().nullable()}),lt=zod.z.object({clusterId:zod.z.string().optional().nullable(),createdAt:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),triggeredAt:zod.z.string().optional().nullable(),summary:zod.z.string().optional().nullable(),shortSummary:zod.z.string().optional().nullable(),changelog:zod.z.string().optional().nullable(),keyPoints:zod.z.array(L).optional().nullable(),questions:zod.z.array(U).optional().nullable()}),pe=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),results:zod.z.array(lt)}),ue=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),results:zod.z.array(J)}),ce=zod.z.object({prompt:zod.z.string().optional().nullable(),maxArticleCount:zod.z.number().optional().nullable(),returnedArticleCount:zod.z.number().optional().nullable(),summarizeFields:zod.z.enum(["TITLE","CONTENT","SUMMARY"]).optional().nullable(),method:zod.z.enum(["ARTICLES","CLUSTERS"]).optional().nullable(),model:zod.z.enum(["gpt-5.4-mini","gpt-5.4-nano","gpt-5-mini","gpt-5-nano","gpt-4o","gpt-4o-mini","gpt-4.1","gpt-4.1-mini","llama-3.3-70b-versatile","openai/gpt-oss-120b"]).optional().nullable(),temperature:zod.z.number().optional().nullable(),topP:zod.z.number().optional().nullable(),maxTokens:zod.z.number().optional().nullable()}),me=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),summary:zod.z.string(),results:zod.z.array(W)}),st=zod.z.object({category:zod.z.string().optional().nullable(),subcategory:zod.z.string().optional().nullable()}),pt=zod.z.object({id:zod.z.number().optional().nullable(),createdAt:zod.z.union([zod.z.string().date(),zod.z.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),updatedAt:zod.z.union([zod.z.string().date(),zod.z.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),name:zod.z.string().optional().nullable(),labels:st.optional().nullable()}),ye=zod.z.object({total:zod.z.number(),data:zod.z.array(pt)}),he=zod.z.object({name:zod.z.string().optional().nullable(),displayName:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),people:zod.z.array(te).optional().nullable(),companies:zod.z.array(ee).optional().nullable(),visible:zod.z.boolean().optional().nullable()}),ut=zod.z.object({id:zod.z.string().optional().nullable(),title:zod.z.string().optional().nullable(),styleLevel:zod.z.number().optional().nullable(),loc:zod.z.array(zod.z.number()).optional().nullable(),textRaw:zod.z.string().optional().nullable(),textRich:zod.z.string().optional().nullable()}),ct=zod.z.object({id:zod.z.string().optional().nullable(),scrapedAt:zod.z.string().optional().nullable(),wikiPageId:zod.z.number().optional().nullable(),wikiRevisionId:zod.z.number().optional().nullable(),wikiRevisionTs:zod.z.string().optional().nullable(),wikiCode:zod.z.string().optional().nullable(),wikiNamespace:zod.z.number().optional().nullable(),wikiTitle:zod.z.string().optional().nullable(),url:zod.z.string().optional().nullable(),topImage:zod.z.string().optional().nullable(),wikidataId:zod.z.string().optional().nullable(),wikidataInstanceOf:zod.z.array(d).optional().nullable(),redirectTitles:zod.z.array(zod.z.string()).optional().nullable(),summary:zod.z.string().optional().nullable(),sections:zod.z.array(ut).optional().nullable(),categories:zod.z.array(zod.z.string()).optional().nullable(),externalLinks:zod.z.array(zod.z.string()).optional().nullable(),references:zod.z.array(zod.z.string()).optional().nullable(),pageviews:zod.z.number().optional().nullable()}),mt=zod.z.object({pageId:zod.z.array(zod.z.string()).optional().nullable(),sectionId:zod.z.array(zod.z.string()).optional().nullable(),wikiPageId:zod.z.array(zod.z.number()).optional().nullable(),wikiRevisionId:zod.z.array(zod.z.number()).optional().nullable(),wikiCode:zod.z.array(zod.z.string()).optional().nullable(),wikiNamespace:zod.z.array(zod.z.number()).optional().nullable(),wikidataId:zod.z.array(zod.z.string()).optional().nullable(),wikidataInstanceOfId:zod.z.array(zod.z.string()).optional().nullable(),wikidataInstanceOfLabel:zod.z.array(zod.z.string()).optional().nullable(),AND:zod.z.array(zod.z.unknown()).optional().nullable(),OR:zod.z.array(zod.z.unknown()).optional().nullable(),NOT:zod.z.array(zod.z.unknown()).optional().nullable()}),de=zod.z.object({prompt:zod.z.string(),filter:mt.optional().nullable(),wikiRevisionFrom:zod.z.union([zod.z.string().date(),zod.z.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),wikiRevisionTo:zod.z.union([zod.z.string().date(),zod.z.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),pageviewsFrom:zod.z.number().optional().nullable(),pageviewsTo:zod.z.number().optional().nullable(),size:zod.z.number().optional().nullable(),page:zod.z.number().optional().nullable()}),ge=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),results:zod.z.array(ct)}),be=zod.z.object({status:zod.z.number(),results:zod.z.array(rt)});var ht=zod.z.object({createSourceGroupParams:Z}),dt=zod.z.object({...ht.shape}),gt=zod.z.object({createWatchlistParams:oe}),bt=zod.z.object({...gt.shape}),St=zod.z.object({id:zod.z.number()}),ft=zod.z.object({...St.shape}),xt=zod.z.object({id:zod.z.number()}),Rt=zod.z.object({...xt.shape}),Tt=zod.z.object({id:zod.z.string()}),wt=zod.z.object({...Tt.shape}),kt=zod.z.object({id:zod.z.number()}),Pt=zod.z.object({...kt.shape}),fe=zod.z.object({q:zod.z.string().optional(),name:zod.z.string().optional(),clusterId:zod.z.array(zod.z.string()).optional(),excludeClusterId:zod.z.array(zod.z.string()).optional(),sortBy:R.optional(),page:zod.z.number().optional(),size:zod.z.number().optional(),from:zod.z.date().optional(),to:zod.z.date().optional(),initializedFrom:zod.z.date().optional(),initializedTo:zod.z.date().optional(),updatedFrom:zod.z.date().optional(),updatedTo:zod.z.date().optional(),topic:zod.z.array(zod.z.string()).optional(),category:zod.z.array(zod.z.string()).optional(),taxonomy:zod.z.array(zod.z.string()).optional(),source:zod.z.array(zod.z.string()).optional(),sourceGroup:zod.z.array(zod.z.string()).optional(),minUniqueSources:zod.z.number().optional(),personWikidataId:zod.z.array(zod.z.string()).optional(),personName:zod.z.string().optional(),companyId:zod.z.array(zod.z.string()).optional(),companyName:zod.z.string().optional(),companyDomain:zod.z.array(zod.z.string()).optional(),companySymbol:zod.z.array(zod.z.string()).optional(),country:zod.z.array(zod.z.string()).optional(),state:zod.z.array(zod.z.string()).optional(),city:zod.z.array(zod.z.string()).optional(),area:zod.z.array(zod.z.string()).optional(),minClusterSize:zod.z.number().optional(),maxClusterSize:zod.z.number().optional(),nameExists:zod.z.boolean().optional(),positiveSentimentFrom:zod.z.number().optional(),positiveSentimentTo:zod.z.number().optional(),neutralSentimentFrom:zod.z.number().optional(),neutralSentimentTo:zod.z.number().optional(),negativeSentimentFrom:zod.z.number().optional(),negativeSentimentTo:zod.z.number().optional(),showStoryPageInfo:zod.z.boolean().optional(),showNumResults:zod.z.boolean().optional(),showDuplicates:zod.z.boolean().optional(),showHighlighting:zod.z.boolean().optional(),highlightFragmentSize:zod.z.number().optional(),highlightNumFragments:zod.z.number().optional(),highlightPreTag:zod.z.string().optional(),highlightPostTag:zod.z.string().optional(),highlightQ:zod.z.string().optional(),expandArticles:zod.z.boolean().optional(),splitBy:zod.z.enum(["HOUR","DAY","WEEK","MONTH","NONE"])}),qt=zod.z.object({...fe.shape}),xe=zod.z.object({clusterId:zod.z.array(zod.z.string()).optional(),from:zod.z.date().optional(),to:zod.z.date().optional(),sortBy:zod.z.enum(["createdAt","triggeredAt"]).optional(),page:zod.z.number().optional(),size:zod.z.number().optional(),changelogExists:zod.z.boolean().optional()}),Ct=zod.z.object({...xe.shape}),jt=zod.z.object({id:zod.z.number()}),At=zod.z.object({...jt.shape}),Re=zod.z.object({name:zod.z.string().optional(),domain:zod.z.string().optional(),page:zod.z.string().optional(),size:zod.z.string().optional(),sortBy:zod.z.string(),sortOrder:zod.z.string()}),It=zod.z.object({...Re.shape}),Te=zod.z.object({name:zod.z.string().optional(),page:zod.z.string().optional(),size:zod.z.string().optional(),sortBy:zod.z.string(),sortOrder:zod.z.string()}),Ht=zod.z.object({...Te.shape}),we=zod.z.object({name:zod.z.array(zod.z.string()).optional()}),zt=zod.z.object({...we.shape}),ke=zod.z.object({name:zod.z.array(zod.z.string()).optional()}),vt=zod.z.object({...ke.shape}),Pe=zod.z.object({q:zod.z.string().optional(),title:zod.z.string().optional(),desc:zod.z.string().optional(),content:zod.z.string().optional(),summary:zod.z.string().optional(),url:zod.z.string().optional(),articleId:zod.z.array(zod.z.string()).optional(),clusterId:zod.z.array(zod.z.string()).optional(),sortBy:z.optional(),page:zod.z.number().optional(),size:zod.z.number().optional(),from:zod.z.date().optional(),to:zod.z.date().optional(),addDateFrom:zod.z.date().optional(),addDateTo:zod.z.date().optional(),refreshDateFrom:zod.z.date().optional(),refreshDateTo:zod.z.date().optional(),medium:zod.z.array(zod.z.string()).optional(),source:zod.z.array(zod.z.string()).optional(),sourceGroup:zod.z.array(zod.z.string()).optional(),excludeSourceGroup:zod.z.array(zod.z.string()).optional(),excludeSource:zod.z.array(zod.z.string()).optional(),watchlist:zod.z.array(zod.z.string()).optional(),excludeWatchlist:zod.z.array(zod.z.string()).optional(),paywall:zod.z.boolean().optional(),byline:zod.z.array(zod.z.string()).optional(),author:zod.z.array(zod.z.string()).optional(),excludeAuthor:zod.z.array(zod.z.string()).optional(),journalistId:zod.z.array(zod.z.string()).optional(),excludeJournalistId:zod.z.array(zod.z.string()).optional(),language:zod.z.array(zod.z.string()).optional(),excludeLanguage:zod.z.array(zod.z.string()).optional(),searchTranslation:zod.z.boolean().optional(),label:zod.z.array(zod.z.string()).optional(),excludeLabel:zod.z.array(zod.z.string()).optional(),category:zod.z.array(zod.z.string()).optional(),excludeCategory:zod.z.array(zod.z.string()).optional(),topic:zod.z.array(zod.z.string()).optional(),excludeTopic:zod.z.array(zod.z.string()).optional(),linkTo:zod.z.string().optional(),showReprints:zod.z.boolean().optional(),reprintGroupId:zod.z.string().optional(),city:zod.z.array(zod.z.string()).optional(),excludeCity:zod.z.array(zod.z.string()).optional(),area:zod.z.array(zod.z.string()).optional(),state:zod.z.array(zod.z.string()).optional(),excludeState:zod.z.array(zod.z.string()).optional(),county:zod.z.array(zod.z.string()).optional(),excludeCounty:zod.z.array(zod.z.string()).optional(),locationsCountry:zod.z.array(zod.z.string()).optional(),country:zod.z.array(zod.z.string()).optional(),excludeLocationsCountry:zod.z.array(zod.z.string()).optional(),location:zod.z.array(zod.z.string()).optional(),lat:zod.z.number().optional(),lon:zod.z.number().optional(),maxDistance:zod.z.number().optional(),sourceCity:zod.z.array(zod.z.string()).optional(),excludeSourceCity:zod.z.array(zod.z.string()).optional(),sourceCounty:zod.z.array(zod.z.string()).optional(),excludeSourceCounty:zod.z.array(zod.z.string()).optional(),sourceCountry:zod.z.array(zod.z.string()).optional(),excludeSourceCountry:zod.z.array(zod.z.string()).optional(),sourceState:zod.z.array(zod.z.string()).optional(),excludeSourceState:zod.z.array(zod.z.string()).optional(),sourceLat:zod.z.number().optional(),sourceLon:zod.z.number().optional(),sourceMaxDistance:zod.z.number().optional(),personWikidataId:zod.z.array(zod.z.string()).optional(),excludePersonWikidataId:zod.z.array(zod.z.string()).optional(),personName:zod.z.array(zod.z.string()).optional(),excludePersonName:zod.z.array(zod.z.string()).optional(),companyId:zod.z.array(zod.z.string()).optional(),excludeCompanyId:zod.z.array(zod.z.string()).optional(),companyName:zod.z.string().optional(),companyDomain:zod.z.array(zod.z.string()).optional(),excludeCompanyDomain:zod.z.array(zod.z.string()).optional(),companySymbol:zod.z.array(zod.z.string()).optional(),excludeCompanySymbol:zod.z.array(zod.z.string()).optional(),showNumResults:zod.z.boolean().optional(),positiveSentimentFrom:zod.z.number().optional(),positiveSentimentTo:zod.z.number().optional(),neutralSentimentFrom:zod.z.number().optional(),neutralSentimentTo:zod.z.number().optional(),negativeSentimentFrom:zod.z.number().optional(),negativeSentimentTo:zod.z.number().optional(),taxonomy:zod.z.array(zod.z.string()).optional(),prefixTaxonomy:zod.z.string().optional(),showHighlighting:zod.z.boolean().optional(),highlightFragmentSize:zod.z.number().optional(),highlightNumFragments:zod.z.number().optional(),highlightPreTag:zod.z.string().optional(),highlightPostTag:zod.z.string().optional(),highlightQ:zod.z.string().optional()}),Wt=zod.z.object({...Pe.shape}),qe=zod.z.object({id:zod.z.array(zod.z.string()).optional(),symbol:zod.z.array(zod.z.string()).optional(),domain:zod.z.array(zod.z.string()).optional(),country:zod.z.array(zod.z.string()).optional(),exchange:zod.z.array(zod.z.string()).optional(),numEmployeesFrom:zod.z.number().optional(),numEmployeesTo:zod.z.number().optional(),ipoFrom:zod.z.date().optional(),ipoTo:zod.z.date().optional(),q:zod.z.string().optional(),name:zod.z.string().optional(),industry:zod.z.string().optional(),sector:zod.z.string().optional(),size:zod.z.number().optional(),page:zod.z.number().optional()}),Gt=zod.z.object({...qe.shape}),Ce=zod.z.object({id:zod.z.array(zod.z.string()).optional(),q:zod.z.string().optional(),name:zod.z.string().optional(),twitter:zod.z.string().optional(),size:zod.z.number().optional(),page:zod.z.number().optional(),source:zod.z.array(zod.z.string()).optional(),topic:zod.z.array(zod.z.string()).optional(),category:zod.z.array(zod.z.string()).optional(),label:zod.z.array(zod.z.string()).optional(),minMonthlyPosts:zod.z.number().optional(),maxMonthlyPosts:zod.z.number().optional(),country:zod.z.array(zod.z.string()).optional(),updatedAtFrom:zod.z.date().optional(),updatedAtTo:zod.z.date().optional(),showNumResults:zod.z.boolean().optional()}),Dt=zod.z.object({...Ce.shape}),je=zod.z.object({name:zod.z.string().optional(),wikidataId:zod.z.array(zod.z.string()).optional(),occupationId:zod.z.array(zod.z.string()).optional(),occupationLabel:zod.z.string().optional(),page:zod.z.number().optional(),size:zod.z.number().optional()}),Bt=zod.z.object({...je.shape}),Ae=zod.z.object({domain:zod.z.array(zod.z.string()).optional(),name:zod.z.string().optional(),sourceGroup:zod.z.string().optional(),sortBy:R.optional(),page:zod.z.number().optional(),size:zod.z.number().optional(),minMonthlyVisits:zod.z.number().optional(),maxMonthlyVisits:zod.z.number().optional(),minMonthlyPosts:zod.z.number().optional(),maxMonthlyPosts:zod.z.number().optional(),country:zod.z.array(zod.z.string()).optional(),sourceCountry:zod.z.array(zod.z.string()).optional(),sourceState:zod.z.array(zod.z.string()).optional(),sourceCounty:zod.z.array(zod.z.string()).optional(),sourceCity:zod.z.array(zod.z.string()).optional(),sourceLat:zod.z.number().optional(),sourceLon:zod.z.number().optional(),sourceMaxDistance:zod.z.number().optional(),category:zod.z.array(zod.z.string()).optional(),topic:zod.z.array(zod.z.string()).optional(),label:zod.z.array(zod.z.string()).optional(),paywall:zod.z.boolean().optional(),showSubdomains:zod.z.boolean().optional(),showNumResults:zod.z.boolean().optional()}),Ft=zod.z.object({...Ae.shape}),Ie=zod.z.object({q:zod.z.string().optional(),name:zod.z.string().optional(),clusterId:zod.z.array(zod.z.string()).optional(),excludeClusterId:zod.z.array(zod.z.string()).optional(),sortBy:R.optional(),page:zod.z.number().optional(),size:zod.z.number().optional(),from:zod.z.date().optional(),to:zod.z.date().optional(),initializedFrom:zod.z.date().optional(),initializedTo:zod.z.date().optional(),updatedFrom:zod.z.date().optional(),updatedTo:zod.z.date().optional(),topic:zod.z.array(zod.z.string()).optional(),category:zod.z.array(zod.z.string()).optional(),taxonomy:zod.z.array(zod.z.string()).optional(),source:zod.z.array(zod.z.string()).optional(),sourceGroup:zod.z.array(zod.z.string()).optional(),minUniqueSources:zod.z.number().optional(),personWikidataId:zod.z.array(zod.z.string()).optional(),personName:zod.z.string().optional(),companyId:zod.z.array(zod.z.string()).optional(),companyName:zod.z.string().optional(),companyDomain:zod.z.array(zod.z.string()).optional(),companySymbol:zod.z.array(zod.z.string()).optional(),country:zod.z.array(zod.z.string()).optional(),state:zod.z.array(zod.z.string()).optional(),city:zod.z.array(zod.z.string()).optional(),area:zod.z.array(zod.z.string()).optional(),minClusterSize:zod.z.number().optional(),maxClusterSize:zod.z.number().optional(),nameExists:zod.z.boolean().optional(),positiveSentimentFrom:zod.z.number().optional(),positiveSentimentTo:zod.z.number().optional(),neutralSentimentFrom:zod.z.number().optional(),neutralSentimentTo:zod.z.number().optional(),negativeSentimentFrom:zod.z.number().optional(),negativeSentimentTo:zod.z.number().optional(),showStoryPageInfo:zod.z.boolean().optional(),showNumResults:zod.z.boolean().optional(),showDuplicates:zod.z.boolean().optional(),showHighlighting:zod.z.boolean().optional(),highlightFragmentSize:zod.z.number().optional(),highlightNumFragments:zod.z.number().optional(),highlightPreTag:zod.z.string().optional(),highlightPostTag:zod.z.string().optional(),highlightQ:zod.z.string().optional(),expandArticles:zod.z.boolean().optional()}),Et=zod.z.object({...Ie.shape}),He=zod.z.object({q:zod.z.string().optional(),title:zod.z.string().optional(),desc:zod.z.string().optional(),content:zod.z.string().optional(),summary:zod.z.string().optional(),url:zod.z.string().optional(),articleId:zod.z.array(zod.z.string()).optional(),clusterId:zod.z.array(zod.z.string()).optional(),sortBy:z.optional(),page:zod.z.number().optional(),size:zod.z.number().optional(),from:zod.z.date().optional(),to:zod.z.date().optional(),addDateFrom:zod.z.date().optional(),addDateTo:zod.z.date().optional(),refreshDateFrom:zod.z.date().optional(),refreshDateTo:zod.z.date().optional(),medium:zod.z.array(zod.z.string()).optional(),source:zod.z.array(zod.z.string()).optional(),sourceGroup:zod.z.array(zod.z.string()).optional(),excludeSourceGroup:zod.z.array(zod.z.string()).optional(),excludeSource:zod.z.array(zod.z.string()).optional(),watchlist:zod.z.array(zod.z.string()).optional(),excludeWatchlist:zod.z.array(zod.z.string()).optional(),paywall:zod.z.boolean().optional(),byline:zod.z.array(zod.z.string()).optional(),author:zod.z.array(zod.z.string()).optional(),excludeAuthor:zod.z.array(zod.z.string()).optional(),journalistId:zod.z.array(zod.z.string()).optional(),excludeJournalistId:zod.z.array(zod.z.string()).optional(),language:zod.z.array(zod.z.string()).optional(),excludeLanguage:zod.z.array(zod.z.string()).optional(),searchTranslation:zod.z.boolean().optional(),label:zod.z.array(zod.z.string()).optional(),excludeLabel:zod.z.array(zod.z.string()).optional(),category:zod.z.array(zod.z.string()).optional(),excludeCategory:zod.z.array(zod.z.string()).optional(),topic:zod.z.array(zod.z.string()).optional(),excludeTopic:zod.z.array(zod.z.string()).optional(),linkTo:zod.z.string().optional(),showReprints:zod.z.boolean().optional(),reprintGroupId:zod.z.string().optional(),city:zod.z.array(zod.z.string()).optional(),excludeCity:zod.z.array(zod.z.string()).optional(),area:zod.z.array(zod.z.string()).optional(),state:zod.z.array(zod.z.string()).optional(),excludeState:zod.z.array(zod.z.string()).optional(),county:zod.z.array(zod.z.string()).optional(),excludeCounty:zod.z.array(zod.z.string()).optional(),locationsCountry:zod.z.array(zod.z.string()).optional(),country:zod.z.array(zod.z.string()).optional(),excludeLocationsCountry:zod.z.array(zod.z.string()).optional(),location:zod.z.array(zod.z.string()).optional(),lat:zod.z.number().optional(),lon:zod.z.number().optional(),maxDistance:zod.z.number().optional(),sourceCity:zod.z.array(zod.z.string()).optional(),excludeSourceCity:zod.z.array(zod.z.string()).optional(),sourceCounty:zod.z.array(zod.z.string()).optional(),excludeSourceCounty:zod.z.array(zod.z.string()).optional(),sourceCountry:zod.z.array(zod.z.string()).optional(),excludeSourceCountry:zod.z.array(zod.z.string()).optional(),sourceState:zod.z.array(zod.z.string()).optional(),excludeSourceState:zod.z.array(zod.z.string()).optional(),sourceLat:zod.z.number().optional(),sourceLon:zod.z.number().optional(),sourceMaxDistance:zod.z.number().optional(),personWikidataId:zod.z.array(zod.z.string()).optional(),excludePersonWikidataId:zod.z.array(zod.z.string()).optional(),personName:zod.z.array(zod.z.string()).optional(),excludePersonName:zod.z.array(zod.z.string()).optional(),companyId:zod.z.array(zod.z.string()).optional(),excludeCompanyId:zod.z.array(zod.z.string()).optional(),companyName:zod.z.string().optional(),companyDomain:zod.z.array(zod.z.string()).optional(),excludeCompanyDomain:zod.z.array(zod.z.string()).optional(),companySymbol:zod.z.array(zod.z.string()).optional(),excludeCompanySymbol:zod.z.array(zod.z.string()).optional(),showNumResults:zod.z.boolean().optional(),positiveSentimentFrom:zod.z.number().optional(),positiveSentimentTo:zod.z.number().optional(),neutralSentimentFrom:zod.z.number().optional(),neutralSentimentTo:zod.z.number().optional(),negativeSentimentFrom:zod.z.number().optional(),negativeSentimentTo:zod.z.number().optional(),taxonomy:zod.z.array(zod.z.string()).optional(),prefixTaxonomy:zod.z.string().optional(),showHighlighting:zod.z.boolean().optional(),highlightFragmentSize:zod.z.number().optional(),highlightNumFragments:zod.z.number().optional(),highlightPreTag:zod.z.string().optional(),highlightPostTag:zod.z.string().optional(),highlightQ:zod.z.string().optional()}),Ot=zod.z.object({summaryBody:ce}),Lt=zod.z.object({...He.shape,...Ot.shape}),ze=zod.z.object({name:zod.z.string().optional(),category:zod.z.string().optional(),subcategory:zod.z.string().optional(),page:zod.z.number().optional(),size:zod.z.number().optional()}),Nt=zod.z.object({...ze.shape}),ve=zod.z.object({q:zod.z.string().optional(),title:zod.z.string().optional(),summary:zod.z.string().optional(),text:zod.z.string().optional(),reference:zod.z.string().optional(),id:zod.z.array(zod.z.string()).optional(),wikiPageId:zod.z.array(zod.z.number()).optional(),wikiRevisionId:zod.z.array(zod.z.number()).optional(),wikiCode:zod.z.array(zod.z.string()).optional(),wikiNamespace:zod.z.array(zod.z.number()).optional(),wikidataId:zod.z.array(zod.z.string()).optional(),wikidataInstanceOfId:zod.z.array(zod.z.string()).optional(),wikidataInstanceOfLabel:zod.z.array(zod.z.string()).optional(),category:zod.z.array(zod.z.string()).optional(),sectionId:zod.z.array(zod.z.string()).optional(),wikiRevisionFrom:zod.z.date().optional(),wikiRevisionTo:zod.z.date().optional(),scrapedAtFrom:zod.z.date().optional(),scrapedAtTo:zod.z.date().optional(),pageviewsFrom:zod.z.number().optional(),pageviewsTo:zod.z.number().optional(),withPageviews:zod.z.boolean().optional(),showNumResults:zod.z.boolean().optional(),page:zod.z.number().optional(),size:zod.z.number().optional(),sortBy:zod.z.enum(["relevance","revisionTsDesc","revisionTsAsc","pageViewsDesc","pageViewsAsc","scrapedAtDesc","scrapedAtAsc"]).optional()}),Ut=zod.z.object({...ve.shape}),Mt=zod.z.object({patchSourceGroupParams:ne}),$t=zod.z.object({id:zod.z.number()}),Kt=zod.z.object({...Mt.shape,...$t.shape}),Qt=zod.z.object({updateWatchlistParams:he}),Vt=zod.z.object({id:zod.z.number()}),Jt=zod.z.object({...Qt.shape,...Vt.shape}),Yt=zod.z.object({articleSearchParams:Y}),_t=zod.z.object({...Yt.shape}),Xt=zod.z.object({wikipediaSearchParams:de}),Zt=zod.z.object({...Xt.shape}),Se=class extends g{async createSourceGroup(o,a){let i=dt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups",method:"POST",headers:r,body:i.createSourceGroupParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async createWatchlist(o,a){let i=bt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists",method:"POST",headers:r,body:i.createWatchlistParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async deleteSourceGroup(o,a){let i=ft.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"DELETE",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async deleteWatchlist(o,a){let i=Rt.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"DELETE",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async getJournalistById(o,a){let i=wt.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let p=await(await this.request({path:"/v1/journalists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"GET",headers:r},a)).json();return T.parse(p)}async getSourceGroup(o,a){let i=Pt.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"GET",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async getStoryCounts(o,a){let i=qt.parse(o),r=fe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/stories/stats",method:"GET",headers:n,query:r},a)).json();return se.parse(s)}async getStoryHistory(o={},a){let i=Ct.parse(o),r=xe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/stories/history",method:"GET",headers:n,query:r},a)).json();return pe.parse(s)}async getWatchlist(o,a){let i=At.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"GET",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async listSourceGroups(o,a){let i=It.parse(o),r=Re.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/sourceGroups",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async listWatchlists(o,a){let i=Ht.parse(o),r=Te.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/watchlists",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async resolveSourceGroups(o={},a){let i=zt.parse(o),r=we.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/sourceGroups/resolve",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async resolveWatchlists(o={},a){let i=vt.parse(o),r=ke.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/watchlists/resolve",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async searchArticles(o={},a){let i=Wt.parse(o),r=Pe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/articles/all",method:"GET",headers:n,query:r},a)).json();return ie.parse(s)}async searchCompanies(o={},a){let i=Gt.parse(o),r=qe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/companies/all",method:"GET",headers:n,query:r},a)).json();return X.parse(s)}async searchJournalists(o={},a){let i=Dt.parse(o),r=Ce.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/journalists/all",method:"GET",headers:n,query:r},a)).json();return ae.parse(s)}async searchPeople(o={},a){let i=Bt.parse(o),r=je.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/people/all",method:"GET",headers:n,query:r},a)).json();return re.parse(s)}async searchSources(o={},a){let i=Ft.parse(o),r=Ae.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/sources/all",method:"GET",headers:n,query:r},a)).json();return le.parse(s)}async searchStories(o={},a){let i=Et.parse(o),r=Ie.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/stories/all",method:"GET",headers:n,query:r},a)).json();return ue.parse(s)}async searchSummarizer(o,a){let i=Lt.parse(o),r=He.parse(i),n={};if(n["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/summarize",method:"POST",headers:n,query:r,body:i.summaryBody},a)).json();return me.parse(s)}async searchTopics(o={},a){let i=Nt.parse(o),r=ze.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/topics/all",method:"GET",headers:n,query:r},a)).json();return ye.parse(s)}async searchWikipedia(o={},a){let i=Ut.parse(o),r=ve.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/wikipedia/all",method:"GET",headers:n,query:r},a)).json();return ge.parse(s)}async updateSourceGroup(o,a){let i=Kt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"PATCH",headers:r,body:i.patchSourceGroupParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async updateWatchlist(o,a){let i=Jt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"PATCH",headers:r,body:i.updateWatchlistParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async vectorSearchArticles(o,a){let i=_t.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let p=await(await this.request({path:"/v1/vector/news/all",method:"POST",headers:r,body:i.articleSearchParams},a)).json();return _.parse(p)}async vectorSearchWikipedia(o,a){let i=Zt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let p=await(await this.request({path:"/v1/vector/wikipedia/all",method:"POST",headers:r,body:i.wikipediaSearchParams},a)).json();return be.parse(p)}},so={Hour:"HOUR",Day:"DAY",Week:"WEEK",Month:"MONTH",None:"NONE"},po={CreatedAt:"createdAt",TriggeredAt:"triggeredAt"},uo={Relevance:"relevance",RevisionTsDesc:"revisionTsDesc",RevisionTsAsc:"revisionTsAsc",PageViewsDesc:"pageViewsDesc",PageViewsAsc:"pageViewsAsc",ScrapedAtDesc:"scrapedAtDesc",ScrapedAtAsc:"scrapedAtAsc"};
|
|
1
|
+
'use strict';var zod=require('zod');var We="https://api.perigon.io".replace(/\/+$/,""),w=class{constructor(o={}){this.configuration=o;}set config(o){this.configuration=o;}get basePath(){return We}get fetchApi(){return this.configuration.fetchApi}get middleware(){return this.configuration.middleware||[]}get queryParamsStringify(){return this.configuration.queryParamsStringify||B}get accessToken(){let o=this.configuration.apiKey;return o?typeof o=="function"?o:async()=>o:void 0}get headers(){return this.configuration.headers}get credentials(){return this.configuration.credentials}},Ge=new w,k=class extends Error{constructor(a,i){super(i);this.cause=a;this.name="FetchError";}},m=class extends Error{constructor(o,a){let i=`HTTP ${o.status}: ${o.statusText}`;super(i),this.name="HttpError",this.status=o.status,this.statusText=o.statusText,this.response=o,this.body=a;}},P=class extends m{constructor(o,a){super(o,a),this.name="BadRequestError",this.message=a?.message||"Bad request - please check your input parameters";}},q=class extends m{constructor(o,a){super(o,a),this.name="UnauthorizedError",this.message="Authentication required - please check your credentials";}},C=class extends m{constructor(o,a){super(o,a),this.name="ForbiddenError",this.message="Access denied - insufficient permissions";}},j=class extends m{constructor(o,a){super(o,a),this.name="NotFoundError",this.message=a?.message||"Resource not found";}},A=class extends m{constructor(o,a){super(o,a),this.name="RateLimitError",this.message="Rate limit exceeded - please try again later";let i=o.headers.get("retry-after");i&&(this.retryAfter=parseInt(i,10));}},I=class extends m{constructor(o,a){super(o,a),this.name="ServerError",this.message="Server error - please try again later";}},D=class extends Error{constructor(o){super("Network error - please check your connection"),this.name="NetworkError",this.cause=o;}};function De(u,o){return u.status===400?new P(u,o):u.status===401?new q(u,o):u.status===403?new C(u,o):u.status===404?new j(u,o):u.status===429?new A(u,o):u.status>499?new I(u,o):new m(u,o)}var b=class b{constructor(o=Ge){this.configuration=o;this.fetchApi=async(o,a)=>{let i={url:o,init:a};for(let n of this.middleware)n.pre&&(i=await n.pre({fetch:this.fetchApi,...i})||i);let r;try{r=await(this.configuration.fetchApi||fetch)(i.url,i.init);}catch(n){for(let p of this.middleware)p.onError&&(r=await p.onError({fetch:this.fetchApi,url:i.url,init:i.init,error:n,response:r?r.clone():void 0})||r);if(r===void 0)throw n instanceof Error?new k(n,"The request failed and the interceptors did not return an alternative response"):n}for(let n of this.middleware)n.post&&(r=await n.post({fetch:this.fetchApi,url:i.url,init:i.init,response:r.clone()})||r);return r};this.middleware=o.middleware;}withMiddleware(...o){let a=this.clone();return a.middleware=a.middleware.concat(...o),a}withPreMiddleware(...o){let a=o.map(i=>({pre:i}));return this.withMiddleware(...a)}withPostMiddleware(...o){let a=o.map(i=>({post:i}));return this.withMiddleware(...a)}isJsonMime(o){return o?b.jsonRegex.test(o):false}async request(o,a){let{url:i,init:r}=await this.createFetchParams(o,a),n=await this.fetchApi(i,r);if(n&&n.status>=200&&n.status<300)return n;let p;try{n.headers.get("content-type")?.includes("application/json")&&(p=await n.json());}catch{}throw De(n,p)}async createFetchParams(o,a){let i=this.configuration.basePath+o.path;o.query!==void 0&&Object.keys(o.query).length!==0&&(i+="?"+this.configuration.queryParamsStringify(o.query));let r=Object.assign({},this.configuration.headers,o.headers);Object.keys(r).forEach(G=>r[G]===void 0?delete r[G]:{});let n=typeof a=="function"?a:async()=>a,p={method:o.method,headers:r,body:o.body,credentials:this.configuration.credentials},s={...p,...await n({init:p,context:o})},l;Fe(s.body)||s.body instanceof URLSearchParams||Be(s.body)?l=s.body:this.isJsonMime(r["Content-Type"])?l=JSON.stringify(s.body):l=s.body;let c={...s,body:l};return {url:i,init:c}}clone(){let o=this.constructor,a=new o(this.configuration);return a.middleware=this.middleware.slice(),a}};b.jsonRegex=new RegExp("^(:?application/json|[^;/ ]+/[^;/ ]+[+]json)[ ]*(:?;.*)?$","i");var g=b;function Be(u){return typeof Blob<"u"&&u instanceof Blob}function Fe(u){return typeof FormData<"u"&&u instanceof FormData}var eo={csv:",",ssv:" ",tsv:" ",pipes:"|"};function B(u,o=""){return Object.keys(u).map(a=>F(a,u[a],o)).filter(a=>a.length>0).join("&")}function F(u,o,a=""){let i=a+(a.length?`[${u}]`:u);if(o instanceof Array){let r=o.map(n=>encodeURIComponent(String(n))).join(`&${encodeURIComponent(i)}=`);return `${encodeURIComponent(i)}=${r}`}if(o instanceof Set){let r=Array.from(o);return F(u,r,a)}return o instanceof Date?`${encodeURIComponent(i)}=${encodeURIComponent(o.toISOString())}`:o instanceof Object?B(o,i):`${encodeURIComponent(i)}=${encodeURIComponent(String(o))}`}function to(u,o){let a=u[o];return a!=null}var R=zod.z.enum(["createdAt","updatedAt","relevance","count","totalCount"]),ao={CreatedAt:"createdAt",UpdatedAt:"updatedAt",Relevance:"relevance",Count:"count",TotalCount:"totalCount"},z=zod.z.enum(["relevance","date","reverseDate","reverseAddDate","addDate","pubDate","refreshDate"]),no={Relevance:"relevance",Date:"date",ReverseDate:"reverseDate",ReverseAddDate:"reverseAddDate",AddDate:"addDate",PubDate:"pubDate",RefreshDate:"refreshDate"},H=zod.z.object({name:zod.z.string().optional().nullable()}),Oe=zod.z.object({name:zod.z.string().optional().nullable(),score:zod.z.number().optional().nullable()}),O=zod.z.object({id:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),domains:zod.z.array(zod.z.string()).optional().nullable(),symbols:zod.z.array(zod.z.string()).optional().nullable()}),Le=zod.z.object({data:zod.z.string().optional().nullable(),type:zod.z.string().optional().nullable(),mentions:zod.z.number().optional().nullable()}),Ne=zod.z.object({name:zod.z.string().optional().nullable(),type:zod.z.string().optional().nullable()}),Ue=zod.z.object({id:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable()}),v=zod.z.object({country:zod.z.string().optional().nullable(),state:zod.z.string().optional().nullable(),county:zod.z.string().optional().nullable(),city:zod.z.string().optional().nullable(),area:zod.z.string().optional().nullable()}),h=zod.z.object({name:zod.z.string().optional().nullable(),count:zod.z.number().optional().nullable()}),T=zod.z.object({id:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),fullName:zod.z.string().optional().nullable(),headline:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),title:zod.z.string().optional().nullable(),locations:zod.z.array(v).optional().nullable(),updatedAt:zod.z.string().optional().nullable(),topTopics:zod.z.array(h).optional().nullable(),topSources:zod.z.array(h).optional().nullable(),topCategories:zod.z.array(h).optional().nullable(),topLabels:zod.z.array(h).optional().nullable(),topCountries:zod.z.array(h).optional().nullable(),avgMonthlyPosts:zod.z.number().optional().nullable(),twitterHandle:zod.z.string().optional().nullable(),twitterBio:zod.z.string().optional().nullable(),imageUrl:zod.z.string().optional().nullable(),linkedinUrl:zod.z.string().optional().nullable(),linkedinConnections:zod.z.number().optional().nullable(),linkedinFollowers:zod.z.number().optional().nullable(),facebookUrl:zod.z.string().optional().nullable(),instagramUrl:zod.z.string().optional().nullable(),websiteUrl:zod.z.string().optional().nullable(),blogUrl:zod.z.string().optional().nullable(),tumblrUrl:zod.z.string().optional().nullable(),youtubeUrl:zod.z.string().optional().nullable()}),Me=zod.z.object({name:zod.z.string().optional().nullable(),weight:zod.z.number().optional().nullable()}),$e=zod.z.object({name:zod.z.string().optional().nullable()}),Ke=zod.z.object({id:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),domains:zod.z.array(zod.z.string()).optional().nullable(),symbols:zod.z.array(zod.z.string()).optional().nullable(),count:zod.z.number().optional().nullable()}),L=zod.z.object({point:zod.z.string().optional().nullable(),references:zod.z.array(zod.z.string()).optional().nullable()}),Qe=zod.z.object({country:zod.z.string().optional().nullable(),state:zod.z.string().optional().nullable(),county:zod.z.string().optional().nullable(),city:zod.z.string().optional().nullable(),area:zod.z.string().optional().nullable(),count:zod.z.number().optional().nullable()}),Ve=zod.z.object({wikidataId:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),count:zod.z.number().optional().nullable()}),N=zod.z.object({wikidataId:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable()}),U=zod.z.object({question:zod.z.string().optional().nullable(),answer:zod.z.string().optional().nullable(),references:zod.z.array(zod.z.string()).optional().nullable()}),S=zod.z.object({name:zod.z.string().optional().nullable(),count:zod.z.number().optional().nullable()}),M=zod.z.object({positive:zod.z.number().optional().nullable(),negative:zod.z.number().optional().nullable(),neutral:zod.z.number().optional().nullable()}),$=zod.z.object({lat:zod.z.number().optional().nullable(),lon:zod.z.number().optional().nullable()}),K=zod.z.object({country:zod.z.string().optional().nullable(),state:zod.z.string().optional().nullable(),county:zod.z.string().optional().nullable(),city:zod.z.string().optional().nullable(),coordinates:$.optional().nullable()}),Q=zod.z.object({domain:zod.z.string().optional().nullable(),paywall:zod.z.boolean().optional().nullable(),location:K.optional().nullable()}),V=zod.z.object({name:zod.z.string().optional().nullable()}),J=zod.z.object({createdAt:zod.z.string().optional().nullable(),updatedAt:zod.z.string().optional().nullable(),initializedAt:zod.z.string().optional().nullable(),id:zod.z.string().optional().nullable(),duplicateOf:zod.z.string().optional().nullable(),slug:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),summary:zod.z.string().optional().nullable(),shortSummary:zod.z.string().optional().nullable(),summaryReferences:zod.z.array(zod.z.string()).optional().nullable(),imageSource:Q.optional().nullable(),imageUrl:zod.z.string().optional().nullable(),keyPoints:zod.z.array(L).optional().nullable(),questions:zod.z.array(U).optional().nullable(),uniqueSources:zod.z.array(zod.z.string()).optional().nullable(),selectedArticles:zod.z.array(zod.z.unknown()).optional().nullable(),sentiment:M.optional().nullable(),uniqueCount:zod.z.number().optional().nullable(),reprintCount:zod.z.number().optional().nullable(),totalCount:zod.z.number().optional().nullable(),countries:zod.z.array(S).optional().nullable(),topCountries:zod.z.array(zod.z.string()).optional().nullable(),topics:zod.z.array(S).optional().nullable(),topTopics:zod.z.array(V).optional().nullable(),categories:zod.z.array(S).optional().nullable(),topCategories:zod.z.array(H).optional().nullable(),taxonomies:zod.z.array(S).optional().nullable(),topTaxonomies:zod.z.array(H).optional().nullable(),people:zod.z.array(Ve).optional().nullable(),topPeople:zod.z.array(N).optional().nullable(),companies:zod.z.array(Ke).optional().nullable(),topCompanies:zod.z.array(O).optional().nullable(),locations:zod.z.array(Qe).optional().nullable(),topLocations:zod.z.array(v).optional().nullable(),highlights:zod.z.record(zod.z.string(),zod.z.array(zod.z.string())).optional().nullable(),sourceDiversity:zod.z.number().optional().nullable()}),Je=zod.z.object({osmId:zod.z.string().optional().nullable(),road:zod.z.string().optional().nullable(),quarter:zod.z.string().optional().nullable(),suburb:zod.z.string().optional().nullable(),city:zod.z.string().optional().nullable(),town:zod.z.string().optional().nullable(),county:zod.z.string().optional().nullable(),stateDistrict:zod.z.string().optional().nullable(),state:zod.z.string().optional().nullable(),postcode:zod.z.string().optional().nullable(),country:zod.z.string().optional().nullable(),countryCode:zod.z.string().optional().nullable(),amenity:zod.z.string().optional().nullable(),neighbourhood:zod.z.string().optional().nullable(),coordinates:$.optional().nullable()}),W=zod.z.object({url:zod.z.string().optional().nullable(),authorsByline:zod.z.string().optional().nullable(),articleId:zod.z.string().optional().nullable(),clusterId:zod.z.string().optional().nullable(),source:Q.optional().nullable(),imageUrl:zod.z.string().optional().nullable(),country:zod.z.string().optional().nullable(),language:zod.z.string().optional().nullable(),pubDate:zod.z.string().optional().nullable(),addDate:zod.z.string().optional().nullable(),refreshDate:zod.z.string().optional().nullable(),score:zod.z.number().optional().nullable(),title:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),content:zod.z.string().optional().nullable(),enContentWordCount:zod.z.number().optional().nullable(),medium:zod.z.string().optional().nullable(),links:zod.z.array(zod.z.string()).optional().nullable(),labels:zod.z.array($e).optional().nullable(),eventTypes:zod.z.array(Ne).optional().nullable(),matchedAuthors:zod.z.array(Ue).optional().nullable(),claim:zod.z.string().optional().nullable(),verdict:zod.z.string().optional().nullable(),keywords:zod.z.array(Me).optional().nullable(),topics:zod.z.array(V).optional().nullable(),categories:zod.z.array(H).optional().nullable(),taxonomies:zod.z.array(Oe).optional().nullable(),entities:zod.z.array(Le).optional().nullable(),companies:zod.z.array(O).optional().nullable(),sentiment:M.optional().nullable(),summary:zod.z.string().optional().nullable(),shortSummary:zod.z.string().optional().nullable(),translation:zod.z.string().optional().nullable(),translatedTitle:zod.z.string().optional().nullable(),translatedDescription:zod.z.string().optional().nullable(),translatedSummary:zod.z.string().optional().nullable(),locations:zod.z.array(v).optional().nullable(),reprint:zod.z.boolean().optional().nullable(),reprintGroupId:zod.z.string().optional().nullable(),places:zod.z.array(Je).optional().nullable(),people:zod.z.array(N).optional().nullable(),cluster:J.optional().nullable(),journalists:zod.z.array(T).optional().nullable(),highlights:zod.z.record(zod.z.string(),zod.z.array(zod.z.string())).optional().nullable()}),E=zod.z.object({lat:zod.z.number().optional().nullable(),lon:zod.z.number().optional().nullable(),radius:zod.z.number().optional().nullable()}),Ye=zod.z.object({articleId:zod.z.array(zod.z.string()).optional().nullable(),clusterId:zod.z.array(zod.z.string()).optional().nullable(),source:zod.z.array(zod.z.string()).optional().nullable(),excludeSource:zod.z.array(zod.z.string()).optional().nullable(),sourceGroup:zod.z.array(zod.z.string()).optional().nullable(),language:zod.z.array(zod.z.string()).optional().nullable(),excludeLanguage:zod.z.array(zod.z.string()).optional().nullable(),label:zod.z.array(zod.z.string()).optional().nullable(),excludeLabel:zod.z.array(zod.z.string()).optional().nullable(),taxonomy:zod.z.array(zod.z.string()).optional().nullable(),category:zod.z.array(zod.z.string()).optional().nullable(),topic:zod.z.array(zod.z.string()).optional().nullable(),excludeTopic:zod.z.array(zod.z.string()).optional().nullable(),country:zod.z.array(zod.z.string()).optional().nullable(),excludeCountry:zod.z.array(zod.z.string()).optional().nullable(),locationsCountry:zod.z.array(zod.z.string()).optional().nullable(),excludeLocationsCountry:zod.z.array(zod.z.string()).optional().nullable(),state:zod.z.array(zod.z.string()).optional().nullable(),excludeState:zod.z.array(zod.z.string()).optional().nullable(),county:zod.z.array(zod.z.string()).optional().nullable(),excludeCounty:zod.z.array(zod.z.string()).optional().nullable(),city:zod.z.array(zod.z.string()).optional().nullable(),excludeCity:zod.z.array(zod.z.string()).optional().nullable(),sourceCountry:zod.z.array(zod.z.string()).optional().nullable(),sourceState:zod.z.array(zod.z.string()).optional().nullable(),sourceCounty:zod.z.array(zod.z.string()).optional().nullable(),sourceCity:zod.z.array(zod.z.string()).optional().nullable(),coordinates:E.optional().nullable(),sourceCoordinates:E.optional().nullable(),companyId:zod.z.array(zod.z.string()).optional().nullable(),excludeCompanyId:zod.z.array(zod.z.string()).optional().nullable(),companyDomain:zod.z.array(zod.z.string()).optional().nullable(),excludeCompanyDomain:zod.z.array(zod.z.string()).optional().nullable(),companySymbol:zod.z.array(zod.z.string()).optional().nullable(),excludeCompanySymbol:zod.z.array(zod.z.string()).optional().nullable(),companyName:zod.z.array(zod.z.string()).optional().nullable(),personWikidataId:zod.z.array(zod.z.string()).optional().nullable(),excludePersonWikidataId:zod.z.array(zod.z.string()).optional().nullable(),personName:zod.z.array(zod.z.string()).optional().nullable(),excludePersonName:zod.z.array(zod.z.string()).optional().nullable(),AND:zod.z.array(zod.z.unknown()).optional().nullable(),OR:zod.z.array(zod.z.unknown()).optional().nullable(),NOT:zod.z.array(zod.z.unknown()).optional().nullable()}),Y=zod.z.object({prompt:zod.z.string(),filter:Ye.optional().nullable(),pubDateFrom:zod.z.union([zod.z.string().date(),zod.z.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),pubDateTo:zod.z.union([zod.z.string().date(),zod.z.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),showReprints:zod.z.boolean().optional().nullable(),size:zod.z.number().optional().nullable(),page:zod.z.number().optional().nullable()}),_e=zod.z.object({score:zod.z.number().optional().nullable(),data:W.optional().nullable()}),_=zod.z.object({status:zod.z.number(),results:zod.z.array(_e)}),Xe=zod.z.object({symbol:zod.z.string().optional().nullable(),exchange:zod.z.string().optional().nullable(),exchangeShortName:zod.z.string().optional().nullable(),ipoDate:zod.z.string().optional().nullable()}),Ze=zod.z.object({careers:zod.z.string().optional().nullable(),about:zod.z.string().optional().nullable(),blog:zod.z.string().optional().nullable(),events:zod.z.string().optional().nullable(),sitemap:zod.z.string().optional().nullable(),updates:zod.z.string().optional().nullable(),linkedin:zod.z.string().optional().nullable(),facebook:zod.z.string().optional().nullable(),instagram:zod.z.string().optional().nullable(),medium:zod.z.string().optional().nullable(),reddit:zod.z.string().optional().nullable(),threads:zod.z.string().optional().nullable(),tiktok:zod.z.string().optional().nullable(),x:zod.z.string().optional().nullable(),wellfound:zod.z.string().optional().nullable(),youtube:zod.z.string().optional().nullable(),wikipedia:zod.z.string().optional().nullable()}),et=zod.z.object({id:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),updatedAt:zod.z.string().optional().nullable(),primaryRecordId:zod.z.string().optional().nullable(),altNames:zod.z.array(zod.z.string()).optional().nullable(),domains:zod.z.array(zod.z.string()).optional().nullable(),monthlyVisits:zod.z.number().optional().nullable(),globalRank:zod.z.number().optional().nullable(),description:zod.z.string().optional().nullable(),ceo:zod.z.string().optional().nullable(),industry:zod.z.string().optional().nullable(),sector:zod.z.string().optional().nullable(),country:zod.z.string().optional().nullable(),fullTimeEmployees:zod.z.number().optional().nullable(),address:zod.z.string().optional().nullable(),city:zod.z.string().optional().nullable(),state:zod.z.string().optional().nullable(),zip:zod.z.string().optional().nullable(),logo:zod.z.string().optional().nullable(),favicon:zod.z.string().optional().nullable(),isEtf:zod.z.boolean().optional().nullable(),isActivelyTrading:zod.z.boolean().optional().nullable(),isFund:zod.z.boolean().optional().nullable(),isAdr:zod.z.boolean().optional().nullable(),symbols:zod.z.array(Xe).optional().nullable(),naics:zod.z.string().optional().nullable(),sic:zod.z.string().optional().nullable(),cusip:zod.z.string().optional().nullable(),cik:zod.z.string().optional().nullable(),isin:zod.z.string().optional().nullable(),yearFounded:zod.z.number().optional().nullable(),revenue:zod.z.string().optional().nullable(),webResources:Ze.optional().nullable()}),X=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),results:zod.z.array(et)}),Z=zod.z.object({name:zod.z.string(),displayName:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),domains:zod.z.array(zod.z.string())}),x=zod.z.object({url:zod.z.string().optional().nullable()}),y=zod.z.object({time:zod.z.string().optional().nullable(),precision:zod.z.string().optional().nullable()}),d=zod.z.object({wikidataId:zod.z.string().optional().nullable(),label:zod.z.string().optional().nullable()}),tt=zod.z.object({wikidataId:zod.z.string().optional().nullable(),label:zod.z.string().optional().nullable(),startTime:y.optional().nullable(),endTime:y.optional().nullable()}),ot=zod.z.object({wikidataId:zod.z.string().optional().nullable(),label:zod.z.string().optional().nullable(),startTime:y.optional().nullable(),endTime:y.optional().nullable(),employer:d.optional().nullable()}),at=zod.z.object({wikidataId:zod.z.string().optional().nullable(),createdAt:zod.z.string().optional().nullable(),updatedAt:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),gender:d.optional().nullable(),dateOfBirth:y.optional().nullable(),dateOfDeath:y.optional().nullable(),description:zod.z.string().optional().nullable(),aliases:zod.z.array(zod.z.string()).optional().nullable(),occupation:zod.z.array(d).optional().nullable(),position:zod.z.array(ot).optional().nullable(),politicalParty:zod.z.array(tt).optional().nullable(),image:x.optional().nullable(),_abstract:zod.z.string().optional().nullable()}),ee=zod.z.object({name:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),id:zod.z.string().optional().nullable(),domain:zod.z.string().optional().nullable(),aliases:zod.z.array(zod.z.string()).optional().nullable()}),te=zod.z.object({name:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),aliases:zod.z.array(zod.z.string()).optional().nullable(),wikidataId:zod.z.string().optional().nullable()}),oe=zod.z.object({name:zod.z.string(),displayName:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),people:zod.z.array(te),companies:zod.z.array(ee),visible:zod.z.boolean().optional().nullable()}),ro=zod.z.object({status:zod.z.number().optional().nullable(),message:zod.z.string().optional().nullable(),timestamp:zod.z.number().optional().nullable()}),ae=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),results:zod.z.array(T)}),ne=zod.z.object({name:zod.z.string().optional().nullable(),displayName:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),domains:zod.z.array(zod.z.string()).optional().nullable()}),re=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),results:zod.z.array(at)}),ie=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),articles:zod.z.array(W)}),nt=zod.z.object({pageId:zod.z.string().optional().nullable(),sectionId:zod.z.string().optional().nullable(),wikiPageId:zod.z.number().optional().nullable(),wikiRevisionId:zod.z.number().optional().nullable(),wikiRevisionTs:zod.z.string().optional().nullable(),wikiCode:zod.z.string().optional().nullable(),wikiNamespace:zod.z.number().optional().nullable(),wikiTitle:zod.z.string().optional().nullable(),wikidataId:zod.z.string().optional().nullable(),wikidataInstanceOf:zod.z.array(d).optional().nullable(),redirectTitles:zod.z.array(zod.z.string()).optional().nullable(),pageviews:zod.z.number().optional().nullable(),title:zod.z.string().optional().nullable(),styleLevel:zod.z.number().optional().nullable(),content:zod.z.string().optional().nullable()}),rt=zod.z.object({score:zod.z.number().optional().nullable(),data:nt.optional().nullable()}),f=zod.z.object({name:zod.z.string().optional().nullable(),count:zod.z.number().optional().nullable()}),it=zod.z.object({id:zod.z.string().optional().nullable(),domain:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),primaryRecordId:zod.z.string().optional().nullable(),updatedAt:zod.z.string().optional().nullable(),altNames:zod.z.array(zod.z.string()).optional().nullable(),description:zod.z.string().optional().nullable(),avgMonthlyPosts:zod.z.number().optional().nullable(),paywall:zod.z.boolean().optional().nullable(),location:K.optional().nullable(),topCategories:zod.z.array(f).optional().nullable(),topTopics:zod.z.array(f).optional().nullable(),topCountries:zod.z.array(f).optional().nullable(),topLabels:zod.z.array(f).optional().nullable(),avgBiasRating:zod.z.string().optional().nullable(),adFontesBiasRating:zod.z.string().optional().nullable(),allSidesBiasRating:zod.z.string().optional().nullable(),mbfcBiasRating:zod.z.string().optional().nullable(),monthlyVisits:zod.z.number().optional().nullable(),globalRank:zod.z.number().optional().nullable(),logoLarge:x.optional().nullable(),logoFavIcon:x.optional().nullable(),logoSquare:x.optional().nullable()}),le=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),results:zod.z.array(it)}),se=zod.z.object({status:zod.z.number().optional().nullable(),results:zod.z.array(zod.z.unknown()).optional().nullable()}),lt=zod.z.object({clusterId:zod.z.string().optional().nullable(),createdAt:zod.z.string().optional().nullable(),name:zod.z.string().optional().nullable(),triggeredAt:zod.z.string().optional().nullable(),summary:zod.z.string().optional().nullable(),shortSummary:zod.z.string().optional().nullable(),changelog:zod.z.string().optional().nullable(),keyPoints:zod.z.array(L).optional().nullable(),questions:zod.z.array(U).optional().nullable()}),pe=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),results:zod.z.array(lt)}),ue=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),results:zod.z.array(J)}),ce=zod.z.object({prompt:zod.z.string().optional().nullable(),maxArticleCount:zod.z.number().optional().nullable(),returnedArticleCount:zod.z.number().optional().nullable(),summarizeFields:zod.z.enum(["TITLE","CONTENT","SUMMARY"]).optional().nullable(),method:zod.z.enum(["ARTICLES","CLUSTERS"]).optional().nullable(),model:zod.z.enum(["gpt-5.4-mini","gpt-5.4-nano","gpt-5-mini","gpt-5-nano","gpt-4o","gpt-4o-mini","gpt-4.1","gpt-4.1-mini","llama-3.3-70b-versatile","openai/gpt-oss-120b"]).optional().nullable(),temperature:zod.z.number().optional().nullable(),topP:zod.z.number().optional().nullable(),maxTokens:zod.z.number().optional().nullable()}),me=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),summary:zod.z.string(),results:zod.z.array(W)}),st=zod.z.object({category:zod.z.string().optional().nullable(),subcategory:zod.z.string().optional().nullable()}),pt=zod.z.object({id:zod.z.number().optional().nullable(),createdAt:zod.z.union([zod.z.string().date(),zod.z.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),updatedAt:zod.z.union([zod.z.string().date(),zod.z.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),name:zod.z.string().optional().nullable(),labels:st.optional().nullable()}),ye=zod.z.object({total:zod.z.number(),data:zod.z.array(pt)}),he=zod.z.object({name:zod.z.string().optional().nullable(),displayName:zod.z.string().optional().nullable(),description:zod.z.string().optional().nullable(),people:zod.z.array(te).optional().nullable(),companies:zod.z.array(ee).optional().nullable(),visible:zod.z.boolean().optional().nullable()}),ut=zod.z.object({id:zod.z.string().optional().nullable(),title:zod.z.string().optional().nullable(),styleLevel:zod.z.number().optional().nullable(),loc:zod.z.array(zod.z.number()).optional().nullable(),textRaw:zod.z.string().optional().nullable(),textRich:zod.z.string().optional().nullable()}),ct=zod.z.object({id:zod.z.string().optional().nullable(),scrapedAt:zod.z.string().optional().nullable(),wikiPageId:zod.z.number().optional().nullable(),wikiRevisionId:zod.z.number().optional().nullable(),wikiRevisionTs:zod.z.string().optional().nullable(),wikiCode:zod.z.string().optional().nullable(),wikiNamespace:zod.z.number().optional().nullable(),wikiTitle:zod.z.string().optional().nullable(),url:zod.z.string().optional().nullable(),topImage:zod.z.string().optional().nullable(),wikidataId:zod.z.string().optional().nullable(),wikidataInstanceOf:zod.z.array(d).optional().nullable(),redirectTitles:zod.z.array(zod.z.string()).optional().nullable(),summary:zod.z.string().optional().nullable(),sections:zod.z.array(ut).optional().nullable(),categories:zod.z.array(zod.z.string()).optional().nullable(),externalLinks:zod.z.array(zod.z.string()).optional().nullable(),references:zod.z.array(zod.z.string()).optional().nullable(),pageviews:zod.z.number().optional().nullable()}),mt=zod.z.object({pageId:zod.z.array(zod.z.string()).optional().nullable(),sectionId:zod.z.array(zod.z.string()).optional().nullable(),wikiPageId:zod.z.array(zod.z.number()).optional().nullable(),wikiRevisionId:zod.z.array(zod.z.number()).optional().nullable(),wikiCode:zod.z.array(zod.z.string()).optional().nullable(),wikiNamespace:zod.z.array(zod.z.number()).optional().nullable(),wikidataId:zod.z.array(zod.z.string()).optional().nullable(),wikidataInstanceOfId:zod.z.array(zod.z.string()).optional().nullable(),wikidataInstanceOfLabel:zod.z.array(zod.z.string()).optional().nullable(),AND:zod.z.array(zod.z.unknown()).optional().nullable(),OR:zod.z.array(zod.z.unknown()).optional().nullable(),NOT:zod.z.array(zod.z.unknown()).optional().nullable()}),de=zod.z.object({prompt:zod.z.string(),filter:mt.optional().nullable(),wikiRevisionFrom:zod.z.union([zod.z.string().date(),zod.z.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),wikiRevisionTo:zod.z.union([zod.z.string().date(),zod.z.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),pageviewsFrom:zod.z.number().optional().nullable(),pageviewsTo:zod.z.number().optional().nullable(),size:zod.z.number().optional().nullable(),page:zod.z.number().optional().nullable()}),ge=zod.z.object({status:zod.z.number(),numResults:zod.z.number(),results:zod.z.array(ct)}),be=zod.z.object({status:zod.z.number(),results:zod.z.array(rt)});var ht=zod.z.object({createSourceGroupParams:Z}),dt=zod.z.object({...ht.shape}),gt=zod.z.object({createWatchlistParams:oe}),bt=zod.z.object({...gt.shape}),St=zod.z.object({id:zod.z.number()}),ft=zod.z.object({...St.shape}),xt=zod.z.object({id:zod.z.number()}),Rt=zod.z.object({...xt.shape}),Tt=zod.z.object({id:zod.z.string()}),wt=zod.z.object({...Tt.shape}),kt=zod.z.object({id:zod.z.number()}),Pt=zod.z.object({...kt.shape}),fe=zod.z.object({q:zod.z.string().optional(),name:zod.z.string().optional(),clusterId:zod.z.array(zod.z.string()).optional(),excludeClusterId:zod.z.array(zod.z.string()).optional(),sortBy:R.optional(),page:zod.z.number().optional(),size:zod.z.number().optional(),from:zod.z.date().optional(),to:zod.z.date().optional(),initializedFrom:zod.z.date().optional(),initializedTo:zod.z.date().optional(),updatedFrom:zod.z.date().optional(),updatedTo:zod.z.date().optional(),topic:zod.z.array(zod.z.string()).optional(),category:zod.z.array(zod.z.string()).optional(),taxonomy:zod.z.array(zod.z.string()).optional(),source:zod.z.array(zod.z.string()).optional(),sourceGroup:zod.z.array(zod.z.string()).optional(),minUniqueSources:zod.z.number().optional(),minSourceDiversity:zod.z.number().optional(),personWikidataId:zod.z.array(zod.z.string()).optional(),personName:zod.z.string().optional(),companyId:zod.z.array(zod.z.string()).optional(),companyName:zod.z.string().optional(),companyDomain:zod.z.array(zod.z.string()).optional(),companySymbol:zod.z.array(zod.z.string()).optional(),country:zod.z.array(zod.z.string()).optional(),state:zod.z.array(zod.z.string()).optional(),city:zod.z.array(zod.z.string()).optional(),area:zod.z.array(zod.z.string()).optional(),minClusterSize:zod.z.number().optional(),maxClusterSize:zod.z.number().optional(),nameExists:zod.z.boolean().optional(),positiveSentimentFrom:zod.z.number().optional(),positiveSentimentTo:zod.z.number().optional(),neutralSentimentFrom:zod.z.number().optional(),neutralSentimentTo:zod.z.number().optional(),negativeSentimentFrom:zod.z.number().optional(),negativeSentimentTo:zod.z.number().optional(),showStoryPageInfo:zod.z.boolean().optional(),showNumResults:zod.z.boolean().optional(),showDuplicates:zod.z.boolean().optional(),showHighlighting:zod.z.boolean().optional(),highlightFragmentSize:zod.z.number().optional(),highlightNumFragments:zod.z.number().optional(),highlightPreTag:zod.z.string().optional(),highlightPostTag:zod.z.string().optional(),highlightQ:zod.z.string().optional(),expandArticles:zod.z.boolean().optional(),splitBy:zod.z.enum(["HOUR","DAY","WEEK","MONTH","NONE"])}),qt=zod.z.object({...fe.shape}),xe=zod.z.object({clusterId:zod.z.array(zod.z.string()).optional(),from:zod.z.date().optional(),to:zod.z.date().optional(),sortBy:zod.z.enum(["createdAt","triggeredAt"]).optional(),page:zod.z.number().optional(),size:zod.z.number().optional(),changelogExists:zod.z.boolean().optional()}),Ct=zod.z.object({...xe.shape}),jt=zod.z.object({id:zod.z.number()}),At=zod.z.object({...jt.shape}),Re=zod.z.object({name:zod.z.string().optional(),domain:zod.z.string().optional(),page:zod.z.string().optional(),size:zod.z.string().optional(),sortBy:zod.z.string(),sortOrder:zod.z.string()}),It=zod.z.object({...Re.shape}),Te=zod.z.object({name:zod.z.string().optional(),page:zod.z.string().optional(),size:zod.z.string().optional(),sortBy:zod.z.string(),sortOrder:zod.z.string()}),Ht=zod.z.object({...Te.shape}),we=zod.z.object({name:zod.z.array(zod.z.string()).optional()}),zt=zod.z.object({...we.shape}),ke=zod.z.object({name:zod.z.array(zod.z.string()).optional()}),vt=zod.z.object({...ke.shape}),Pe=zod.z.object({q:zod.z.string().optional(),title:zod.z.string().optional(),desc:zod.z.string().optional(),content:zod.z.string().optional(),summary:zod.z.string().optional(),url:zod.z.string().optional(),articleId:zod.z.array(zod.z.string()).optional(),clusterId:zod.z.array(zod.z.string()).optional(),sortBy:z.optional(),page:zod.z.number().optional(),size:zod.z.number().optional(),from:zod.z.date().optional(),to:zod.z.date().optional(),addDateFrom:zod.z.date().optional(),addDateTo:zod.z.date().optional(),refreshDateFrom:zod.z.date().optional(),refreshDateTo:zod.z.date().optional(),medium:zod.z.array(zod.z.string()).optional(),source:zod.z.array(zod.z.string()).optional(),sourceGroup:zod.z.array(zod.z.string()).optional(),excludeSourceGroup:zod.z.array(zod.z.string()).optional(),excludeSource:zod.z.array(zod.z.string()).optional(),watchlist:zod.z.array(zod.z.string()).optional(),excludeWatchlist:zod.z.array(zod.z.string()).optional(),paywall:zod.z.boolean().optional(),byline:zod.z.array(zod.z.string()).optional(),author:zod.z.array(zod.z.string()).optional(),excludeAuthor:zod.z.array(zod.z.string()).optional(),journalistId:zod.z.array(zod.z.string()).optional(),excludeJournalistId:zod.z.array(zod.z.string()).optional(),language:zod.z.array(zod.z.string()).optional(),excludeLanguage:zod.z.array(zod.z.string()).optional(),searchTranslation:zod.z.boolean().optional(),label:zod.z.array(zod.z.string()).optional(),excludeLabel:zod.z.array(zod.z.string()).optional(),category:zod.z.array(zod.z.string()).optional(),excludeCategory:zod.z.array(zod.z.string()).optional(),topic:zod.z.array(zod.z.string()).optional(),excludeTopic:zod.z.array(zod.z.string()).optional(),linkTo:zod.z.string().optional(),showReprints:zod.z.boolean().optional(),reprintGroupId:zod.z.string().optional(),city:zod.z.array(zod.z.string()).optional(),excludeCity:zod.z.array(zod.z.string()).optional(),area:zod.z.array(zod.z.string()).optional(),state:zod.z.array(zod.z.string()).optional(),excludeState:zod.z.array(zod.z.string()).optional(),county:zod.z.array(zod.z.string()).optional(),excludeCounty:zod.z.array(zod.z.string()).optional(),locationsCountry:zod.z.array(zod.z.string()).optional(),country:zod.z.array(zod.z.string()).optional(),excludeLocationsCountry:zod.z.array(zod.z.string()).optional(),location:zod.z.array(zod.z.string()).optional(),lat:zod.z.number().optional(),lon:zod.z.number().optional(),maxDistance:zod.z.number().optional(),sourceCity:zod.z.array(zod.z.string()).optional(),excludeSourceCity:zod.z.array(zod.z.string()).optional(),sourceCounty:zod.z.array(zod.z.string()).optional(),excludeSourceCounty:zod.z.array(zod.z.string()).optional(),sourceCountry:zod.z.array(zod.z.string()).optional(),excludeSourceCountry:zod.z.array(zod.z.string()).optional(),sourceState:zod.z.array(zod.z.string()).optional(),excludeSourceState:zod.z.array(zod.z.string()).optional(),sourceLat:zod.z.number().optional(),sourceLon:zod.z.number().optional(),sourceMaxDistance:zod.z.number().optional(),personWikidataId:zod.z.array(zod.z.string()).optional(),excludePersonWikidataId:zod.z.array(zod.z.string()).optional(),personName:zod.z.array(zod.z.string()).optional(),excludePersonName:zod.z.array(zod.z.string()).optional(),companyId:zod.z.array(zod.z.string()).optional(),excludeCompanyId:zod.z.array(zod.z.string()).optional(),companyName:zod.z.string().optional(),companyDomain:zod.z.array(zod.z.string()).optional(),excludeCompanyDomain:zod.z.array(zod.z.string()).optional(),companySymbol:zod.z.array(zod.z.string()).optional(),excludeCompanySymbol:zod.z.array(zod.z.string()).optional(),showNumResults:zod.z.boolean().optional(),positiveSentimentFrom:zod.z.number().optional(),positiveSentimentTo:zod.z.number().optional(),neutralSentimentFrom:zod.z.number().optional(),neutralSentimentTo:zod.z.number().optional(),negativeSentimentFrom:zod.z.number().optional(),negativeSentimentTo:zod.z.number().optional(),taxonomy:zod.z.array(zod.z.string()).optional(),prefixTaxonomy:zod.z.string().optional(),showHighlighting:zod.z.boolean().optional(),highlightFragmentSize:zod.z.number().optional(),highlightNumFragments:zod.z.number().optional(),highlightPreTag:zod.z.string().optional(),highlightPostTag:zod.z.string().optional(),highlightQ:zod.z.string().optional()}),Wt=zod.z.object({...Pe.shape}),qe=zod.z.object({id:zod.z.array(zod.z.string()).optional(),symbol:zod.z.array(zod.z.string()).optional(),domain:zod.z.array(zod.z.string()).optional(),country:zod.z.array(zod.z.string()).optional(),exchange:zod.z.array(zod.z.string()).optional(),numEmployeesFrom:zod.z.number().optional(),numEmployeesTo:zod.z.number().optional(),ipoFrom:zod.z.date().optional(),ipoTo:zod.z.date().optional(),q:zod.z.string().optional(),name:zod.z.string().optional(),industry:zod.z.string().optional(),sector:zod.z.string().optional(),size:zod.z.number().optional(),page:zod.z.number().optional()}),Gt=zod.z.object({...qe.shape}),Ce=zod.z.object({id:zod.z.array(zod.z.string()).optional(),q:zod.z.string().optional(),name:zod.z.string().optional(),twitter:zod.z.string().optional(),size:zod.z.number().optional(),page:zod.z.number().optional(),source:zod.z.array(zod.z.string()).optional(),topic:zod.z.array(zod.z.string()).optional(),category:zod.z.array(zod.z.string()).optional(),label:zod.z.array(zod.z.string()).optional(),minMonthlyPosts:zod.z.number().optional(),maxMonthlyPosts:zod.z.number().optional(),country:zod.z.array(zod.z.string()).optional(),updatedAtFrom:zod.z.date().optional(),updatedAtTo:zod.z.date().optional(),showNumResults:zod.z.boolean().optional()}),Dt=zod.z.object({...Ce.shape}),je=zod.z.object({name:zod.z.string().optional(),wikidataId:zod.z.array(zod.z.string()).optional(),occupationId:zod.z.array(zod.z.string()).optional(),occupationLabel:zod.z.string().optional(),page:zod.z.number().optional(),size:zod.z.number().optional()}),Bt=zod.z.object({...je.shape}),Ae=zod.z.object({domain:zod.z.array(zod.z.string()).optional(),name:zod.z.string().optional(),sourceGroup:zod.z.string().optional(),sortBy:R.optional(),page:zod.z.number().optional(),size:zod.z.number().optional(),minMonthlyVisits:zod.z.number().optional(),maxMonthlyVisits:zod.z.number().optional(),minMonthlyPosts:zod.z.number().optional(),maxMonthlyPosts:zod.z.number().optional(),country:zod.z.array(zod.z.string()).optional(),sourceCountry:zod.z.array(zod.z.string()).optional(),sourceState:zod.z.array(zod.z.string()).optional(),sourceCounty:zod.z.array(zod.z.string()).optional(),sourceCity:zod.z.array(zod.z.string()).optional(),sourceLat:zod.z.number().optional(),sourceLon:zod.z.number().optional(),sourceMaxDistance:zod.z.number().optional(),category:zod.z.array(zod.z.string()).optional(),topic:zod.z.array(zod.z.string()).optional(),label:zod.z.array(zod.z.string()).optional(),paywall:zod.z.boolean().optional(),showSubdomains:zod.z.boolean().optional(),showNumResults:zod.z.boolean().optional()}),Ft=zod.z.object({...Ae.shape}),Ie=zod.z.object({q:zod.z.string().optional(),name:zod.z.string().optional(),clusterId:zod.z.array(zod.z.string()).optional(),excludeClusterId:zod.z.array(zod.z.string()).optional(),sortBy:R.optional(),page:zod.z.number().optional(),size:zod.z.number().optional(),from:zod.z.date().optional(),to:zod.z.date().optional(),initializedFrom:zod.z.date().optional(),initializedTo:zod.z.date().optional(),updatedFrom:zod.z.date().optional(),updatedTo:zod.z.date().optional(),topic:zod.z.array(zod.z.string()).optional(),category:zod.z.array(zod.z.string()).optional(),taxonomy:zod.z.array(zod.z.string()).optional(),source:zod.z.array(zod.z.string()).optional(),sourceGroup:zod.z.array(zod.z.string()).optional(),minUniqueSources:zod.z.number().optional(),minSourceDiversity:zod.z.number().optional(),personWikidataId:zod.z.array(zod.z.string()).optional(),personName:zod.z.string().optional(),companyId:zod.z.array(zod.z.string()).optional(),companyName:zod.z.string().optional(),companyDomain:zod.z.array(zod.z.string()).optional(),companySymbol:zod.z.array(zod.z.string()).optional(),country:zod.z.array(zod.z.string()).optional(),state:zod.z.array(zod.z.string()).optional(),city:zod.z.array(zod.z.string()).optional(),area:zod.z.array(zod.z.string()).optional(),minClusterSize:zod.z.number().optional(),maxClusterSize:zod.z.number().optional(),nameExists:zod.z.boolean().optional(),positiveSentimentFrom:zod.z.number().optional(),positiveSentimentTo:zod.z.number().optional(),neutralSentimentFrom:zod.z.number().optional(),neutralSentimentTo:zod.z.number().optional(),negativeSentimentFrom:zod.z.number().optional(),negativeSentimentTo:zod.z.number().optional(),showStoryPageInfo:zod.z.boolean().optional(),showNumResults:zod.z.boolean().optional(),showDuplicates:zod.z.boolean().optional(),showHighlighting:zod.z.boolean().optional(),highlightFragmentSize:zod.z.number().optional(),highlightNumFragments:zod.z.number().optional(),highlightPreTag:zod.z.string().optional(),highlightPostTag:zod.z.string().optional(),highlightQ:zod.z.string().optional(),expandArticles:zod.z.boolean().optional()}),Et=zod.z.object({...Ie.shape}),He=zod.z.object({q:zod.z.string().optional(),title:zod.z.string().optional(),desc:zod.z.string().optional(),content:zod.z.string().optional(),summary:zod.z.string().optional(),url:zod.z.string().optional(),articleId:zod.z.array(zod.z.string()).optional(),clusterId:zod.z.array(zod.z.string()).optional(),sortBy:z.optional(),page:zod.z.number().optional(),size:zod.z.number().optional(),from:zod.z.date().optional(),to:zod.z.date().optional(),addDateFrom:zod.z.date().optional(),addDateTo:zod.z.date().optional(),refreshDateFrom:zod.z.date().optional(),refreshDateTo:zod.z.date().optional(),medium:zod.z.array(zod.z.string()).optional(),source:zod.z.array(zod.z.string()).optional(),sourceGroup:zod.z.array(zod.z.string()).optional(),excludeSourceGroup:zod.z.array(zod.z.string()).optional(),excludeSource:zod.z.array(zod.z.string()).optional(),watchlist:zod.z.array(zod.z.string()).optional(),excludeWatchlist:zod.z.array(zod.z.string()).optional(),paywall:zod.z.boolean().optional(),byline:zod.z.array(zod.z.string()).optional(),author:zod.z.array(zod.z.string()).optional(),excludeAuthor:zod.z.array(zod.z.string()).optional(),journalistId:zod.z.array(zod.z.string()).optional(),excludeJournalistId:zod.z.array(zod.z.string()).optional(),language:zod.z.array(zod.z.string()).optional(),excludeLanguage:zod.z.array(zod.z.string()).optional(),searchTranslation:zod.z.boolean().optional(),label:zod.z.array(zod.z.string()).optional(),excludeLabel:zod.z.array(zod.z.string()).optional(),category:zod.z.array(zod.z.string()).optional(),excludeCategory:zod.z.array(zod.z.string()).optional(),topic:zod.z.array(zod.z.string()).optional(),excludeTopic:zod.z.array(zod.z.string()).optional(),linkTo:zod.z.string().optional(),showReprints:zod.z.boolean().optional(),reprintGroupId:zod.z.string().optional(),city:zod.z.array(zod.z.string()).optional(),excludeCity:zod.z.array(zod.z.string()).optional(),area:zod.z.array(zod.z.string()).optional(),state:zod.z.array(zod.z.string()).optional(),excludeState:zod.z.array(zod.z.string()).optional(),county:zod.z.array(zod.z.string()).optional(),excludeCounty:zod.z.array(zod.z.string()).optional(),locationsCountry:zod.z.array(zod.z.string()).optional(),country:zod.z.array(zod.z.string()).optional(),excludeLocationsCountry:zod.z.array(zod.z.string()).optional(),location:zod.z.array(zod.z.string()).optional(),lat:zod.z.number().optional(),lon:zod.z.number().optional(),maxDistance:zod.z.number().optional(),sourceCity:zod.z.array(zod.z.string()).optional(),excludeSourceCity:zod.z.array(zod.z.string()).optional(),sourceCounty:zod.z.array(zod.z.string()).optional(),excludeSourceCounty:zod.z.array(zod.z.string()).optional(),sourceCountry:zod.z.array(zod.z.string()).optional(),excludeSourceCountry:zod.z.array(zod.z.string()).optional(),sourceState:zod.z.array(zod.z.string()).optional(),excludeSourceState:zod.z.array(zod.z.string()).optional(),sourceLat:zod.z.number().optional(),sourceLon:zod.z.number().optional(),sourceMaxDistance:zod.z.number().optional(),personWikidataId:zod.z.array(zod.z.string()).optional(),excludePersonWikidataId:zod.z.array(zod.z.string()).optional(),personName:zod.z.array(zod.z.string()).optional(),excludePersonName:zod.z.array(zod.z.string()).optional(),companyId:zod.z.array(zod.z.string()).optional(),excludeCompanyId:zod.z.array(zod.z.string()).optional(),companyName:zod.z.string().optional(),companyDomain:zod.z.array(zod.z.string()).optional(),excludeCompanyDomain:zod.z.array(zod.z.string()).optional(),companySymbol:zod.z.array(zod.z.string()).optional(),excludeCompanySymbol:zod.z.array(zod.z.string()).optional(),showNumResults:zod.z.boolean().optional(),positiveSentimentFrom:zod.z.number().optional(),positiveSentimentTo:zod.z.number().optional(),neutralSentimentFrom:zod.z.number().optional(),neutralSentimentTo:zod.z.number().optional(),negativeSentimentFrom:zod.z.number().optional(),negativeSentimentTo:zod.z.number().optional(),taxonomy:zod.z.array(zod.z.string()).optional(),prefixTaxonomy:zod.z.string().optional(),showHighlighting:zod.z.boolean().optional(),highlightFragmentSize:zod.z.number().optional(),highlightNumFragments:zod.z.number().optional(),highlightPreTag:zod.z.string().optional(),highlightPostTag:zod.z.string().optional(),highlightQ:zod.z.string().optional()}),Ot=zod.z.object({summaryBody:ce}),Lt=zod.z.object({...He.shape,...Ot.shape}),ze=zod.z.object({name:zod.z.string().optional(),category:zod.z.string().optional(),subcategory:zod.z.string().optional(),page:zod.z.number().optional(),size:zod.z.number().optional()}),Nt=zod.z.object({...ze.shape}),ve=zod.z.object({q:zod.z.string().optional(),title:zod.z.string().optional(),summary:zod.z.string().optional(),text:zod.z.string().optional(),reference:zod.z.string().optional(),id:zod.z.array(zod.z.string()).optional(),wikiPageId:zod.z.array(zod.z.number()).optional(),wikiRevisionId:zod.z.array(zod.z.number()).optional(),wikiCode:zod.z.array(zod.z.string()).optional(),wikiNamespace:zod.z.array(zod.z.number()).optional(),wikidataId:zod.z.array(zod.z.string()).optional(),wikidataInstanceOfId:zod.z.array(zod.z.string()).optional(),wikidataInstanceOfLabel:zod.z.array(zod.z.string()).optional(),category:zod.z.array(zod.z.string()).optional(),sectionId:zod.z.array(zod.z.string()).optional(),wikiRevisionFrom:zod.z.date().optional(),wikiRevisionTo:zod.z.date().optional(),scrapedAtFrom:zod.z.date().optional(),scrapedAtTo:zod.z.date().optional(),pageviewsFrom:zod.z.number().optional(),pageviewsTo:zod.z.number().optional(),withPageviews:zod.z.boolean().optional(),showNumResults:zod.z.boolean().optional(),page:zod.z.number().optional(),size:zod.z.number().optional(),sortBy:zod.z.enum(["relevance","revisionTsDesc","revisionTsAsc","pageViewsDesc","pageViewsAsc","scrapedAtDesc","scrapedAtAsc"]).optional()}),Ut=zod.z.object({...ve.shape}),Mt=zod.z.object({patchSourceGroupParams:ne}),$t=zod.z.object({id:zod.z.number()}),Kt=zod.z.object({...Mt.shape,...$t.shape}),Qt=zod.z.object({updateWatchlistParams:he}),Vt=zod.z.object({id:zod.z.number()}),Jt=zod.z.object({...Qt.shape,...Vt.shape}),Yt=zod.z.object({articleSearchParams:Y}),_t=zod.z.object({...Yt.shape}),Xt=zod.z.object({wikipediaSearchParams:de}),Zt=zod.z.object({...Xt.shape}),Se=class extends g{async createSourceGroup(o,a){let i=dt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups",method:"POST",headers:r,body:i.createSourceGroupParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async createWatchlist(o,a){let i=bt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists",method:"POST",headers:r,body:i.createWatchlistParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async deleteSourceGroup(o,a){let i=ft.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"DELETE",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async deleteWatchlist(o,a){let i=Rt.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"DELETE",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async getJournalistById(o,a){let i=wt.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let p=await(await this.request({path:"/v1/journalists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"GET",headers:r},a)).json();return T.parse(p)}async getSourceGroup(o,a){let i=Pt.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"GET",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async getStoryCounts(o,a){let i=qt.parse(o),r=fe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/stories/stats",method:"GET",headers:n,query:r},a)).json();return se.parse(s)}async getStoryHistory(o={},a){let i=Ct.parse(o),r=xe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/stories/history",method:"GET",headers:n,query:r},a)).json();return pe.parse(s)}async getWatchlist(o,a){let i=At.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"GET",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async listSourceGroups(o,a){let i=It.parse(o),r=Re.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/sourceGroups",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async listWatchlists(o,a){let i=Ht.parse(o),r=Te.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/watchlists",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async resolveSourceGroups(o={},a){let i=zt.parse(o),r=we.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/sourceGroups/resolve",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async resolveWatchlists(o={},a){let i=vt.parse(o),r=ke.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/watchlists/resolve",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async searchArticles(o={},a){let i=Wt.parse(o),r=Pe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/articles/all",method:"GET",headers:n,query:r},a)).json();return ie.parse(s)}async searchCompanies(o={},a){let i=Gt.parse(o),r=qe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/companies/all",method:"GET",headers:n,query:r},a)).json();return X.parse(s)}async searchJournalists(o={},a){let i=Dt.parse(o),r=Ce.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/journalists/all",method:"GET",headers:n,query:r},a)).json();return ae.parse(s)}async searchPeople(o={},a){let i=Bt.parse(o),r=je.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/people/all",method:"GET",headers:n,query:r},a)).json();return re.parse(s)}async searchSources(o={},a){let i=Ft.parse(o),r=Ae.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/sources/all",method:"GET",headers:n,query:r},a)).json();return le.parse(s)}async searchStories(o={},a){let i=Et.parse(o),r=Ie.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/stories/all",method:"GET",headers:n,query:r},a)).json();return ue.parse(s)}async searchSummarizer(o,a){let i=Lt.parse(o),r=He.parse(i),n={};if(n["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/summarize",method:"POST",headers:n,query:r,body:i.summaryBody},a)).json();return me.parse(s)}async searchTopics(o={},a){let i=Nt.parse(o),r=ze.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/topics/all",method:"GET",headers:n,query:r},a)).json();return ye.parse(s)}async searchWikipedia(o={},a){let i=Ut.parse(o),r=ve.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/wikipedia/all",method:"GET",headers:n,query:r},a)).json();return ge.parse(s)}async updateSourceGroup(o,a){let i=Kt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"PATCH",headers:r,body:i.patchSourceGroupParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async updateWatchlist(o,a){let i=Jt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"PATCH",headers:r,body:i.updateWatchlistParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async vectorSearchArticles(o,a){let i=_t.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let p=await(await this.request({path:"/v1/vector/news/all",method:"POST",headers:r,body:i.articleSearchParams},a)).json();return _.parse(p)}async vectorSearchWikipedia(o,a){let i=Zt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let p=await(await this.request({path:"/v1/vector/wikipedia/all",method:"POST",headers:r,body:i.wikipediaSearchParams},a)).json();return be.parse(p)}},so={Hour:"HOUR",Day:"DAY",Week:"WEEK",Month:"MONTH",None:"NONE"},po={CreatedAt:"createdAt",TriggeredAt:"triggeredAt"},uo={Relevance:"relevance",RevisionTsDesc:"revisionTsDesc",RevisionTsAsc:"revisionTsAsc",PageViewsDesc:"pageViewsDesc",PageViewsAsc:"pageViewsAsc",ScrapedAtDesc:"scrapedAtDesc",ScrapedAtAsc:"scrapedAtAsc"};
|
|
2
2
|
exports.AllEndpointSortBy=no;exports.AllEndpointSortBySchema=z;exports.ArticleSchema=W;exports.ArticleSearchFilterSchema=Ye;exports.ArticleSearchParamsSchema=Y;exports.ArticlesVectorSearchResultSchema=_;exports.BASE_PATH=We;exports.BadRequestError=P;exports.BaseAPI=g;exports.COLLECTION_FORMATS=eo;exports.CategoryHolderSchema=H;exports.CategoryWithScoreHolderSchema=Oe;exports.CompanyCountSchema=Ke;exports.CompanyHolderSchema=O;exports.CompanySchema=et;exports.CompanySearchResultSchema=X;exports.Configuration=w;exports.CoordinateFilterSchema=E;exports.CoordinateSchema=$;exports.CreateSourceGroupBodySchema=ht;exports.CreateSourceGroupParamsSchema=Z;exports.CreateSourceGroupRequestSchema=dt;exports.CreateWatchlistBodySchema=gt;exports.CreateWatchlistParamsSchema=oe;exports.CreateWatchlistRequestSchema=bt;exports.DefaultConfig=Ge;exports.DeleteSourceGroupPathSchema=St;exports.DeleteSourceGroupRequestSchema=ft;exports.DeleteWatchlistPathSchema=xt;exports.DeleteWatchlistRequestSchema=Rt;exports.EntityHolderSchema=Le;exports.ErrorResponseSchema=ro;exports.EventTypeHolderSchema=Ne;exports.FetchError=k;exports.ForbiddenError=C;exports.GetJournalistByIdPathSchema=Tt;exports.GetJournalistByIdRequestSchema=wt;exports.GetSourceGroupPathSchema=kt;exports.GetSourceGroupRequestSchema=Pt;exports.GetStoryCountsQuerySchema=fe;exports.GetStoryCountsRequestSchema=qt;exports.GetStoryCountsSplitByEnum=so;exports.GetStoryHistoryQuerySchema=xe;exports.GetStoryHistoryRequestSchema=Ct;exports.GetStoryHistorySortByEnum=po;exports.GetWatchlistPathSchema=jt;exports.GetWatchlistRequestSchema=At;exports.HttpError=m;exports.IdNameHolderSchema=Ue;exports.ImageHolderSchema=x;exports.JournalistSchema=T;exports.JournalistSearchResultSchema=ae;exports.KeyPointSchema=L;exports.KeywordHolderSchema=Me;exports.LabelHolderSchema=$e;exports.ListSourceGroupsQuerySchema=Re;exports.ListSourceGroupsRequestSchema=It;exports.ListWatchlistsQuerySchema=Te;exports.ListWatchlistsRequestSchema=Ht;exports.LocationCountSchema=Qe;exports.LocationHolderSchema=v;exports.NameCountSchema=h;exports.NetworkError=D;exports.NewsClusterSchema=J;exports.NotFoundError=j;exports.PatchSourceGroupParamsSchema=ne;exports.PeopleSearchResultSchema=re;exports.PersonCountSchema=Ve;exports.PersonHolderSchema=N;exports.PersonSchema=at;exports.PlaceSchema=Je;exports.QuerySearchResultSchema=ie;exports.QuestionSchema=U;exports.RateLimitError=A;exports.RecordStatHolderSchema=S;exports.ResolveSourceGroupsQuerySchema=we;exports.ResolveSourceGroupsRequestSchema=zt;exports.ResolveWatchlistsQuerySchema=ke;exports.ResolveWatchlistsRequestSchema=vt;exports.ScoredDataArticleSchema=_e;exports.ScoredDataWikiDataSchema=rt;exports.SearchArticlesQuerySchema=Pe;exports.SearchArticlesRequestSchema=Wt;exports.SearchCompaniesQuerySchema=qe;exports.SearchCompaniesRequestSchema=Gt;exports.SearchJournalistsQuerySchema=Ce;exports.SearchJournalistsRequestSchema=Dt;exports.SearchPeopleQuerySchema=je;exports.SearchPeopleRequestSchema=Bt;exports.SearchSourcesQuerySchema=Ae;exports.SearchSourcesRequestSchema=Ft;exports.SearchStoriesQuerySchema=Ie;exports.SearchStoriesRequestSchema=Et;exports.SearchSummarizerBodySchema=Ot;exports.SearchSummarizerQuerySchema=He;exports.SearchSummarizerRequestSchema=Lt;exports.SearchTopicsQuerySchema=ze;exports.SearchTopicsRequestSchema=Nt;exports.SearchWikipediaQuerySchema=ve;exports.SearchWikipediaRequestSchema=Ut;exports.SearchWikipediaSortByEnum=uo;exports.SentimentHolderSchema=M;exports.ServerError=I;exports.SortBy=ao;exports.SortBySchema=R;exports.SourceHolderSchema=Q;exports.SourceLocationSchema=K;exports.SourceSchema=it;exports.SourceSearchResultSchema=le;exports.SourceTopStatHolderSchema=f;exports.StatResultSchema=se;exports.StoryHistoryRecordSchema=lt;exports.StoryHistoryResultSchema=pe;exports.StorySearchResultSchema=ue;exports.SummaryBodySchema=ce;exports.SummarySearchResultSchema=me;exports.SymbolHolderSchema=Xe;exports.TopicDtoSchema=pt;exports.TopicHolderSchema=V;exports.TopicLabelsSchema=st;exports.TopicSearchResultSchema=ye;exports.UnauthorizedError=q;exports.UpdateSourceGroupBodySchema=Mt;exports.UpdateSourceGroupPathSchema=$t;exports.UpdateSourceGroupRequestSchema=Kt;exports.UpdateWatchlistBodySchema=Qt;exports.UpdateWatchlistParamsSchema=he;exports.UpdateWatchlistPathSchema=Vt;exports.UpdateWatchlistRequestSchema=Jt;exports.V1Api=Se;exports.VectorSearchArticlesBodySchema=Yt;exports.VectorSearchArticlesRequestSchema=_t;exports.VectorSearchWikipediaBodySchema=Xt;exports.VectorSearchWikipediaRequestSchema=Zt;exports.WatchlistCompanySchema=ee;exports.WatchlistPersonSchema=te;exports.WebResourcesSchema=Ze;exports.WikiDataSchema=nt;exports.WikiPageSchema=ct;exports.WikiPageSectionHolderSchema=ut;exports.WikidataDateHolderSchema=y;exports.WikidataLabelHolderSchema=d;exports.WikidataPoliticalPartyHolderSchema=tt;exports.WikidataPositionHolderSchema=ot;exports.WikipediaSearchFilterSchema=mt;exports.WikipediaSearchParamsSchema=de;exports.WikipediaSearchResultSchema=ge;exports.WikipediaVectorSearchResultSchema=be;exports.createHttpError=De;exports.exists=to;exports.querystring=B;//# sourceMappingURL=index.cjs.map
|
|
3
3
|
//# sourceMappingURL=index.cjs.map
|
package/dist/index.d.ts
CHANGED
|
@@ -1012,6 +1012,7 @@ declare const NewsClusterSchema: z.ZodObject<{
|
|
|
1012
1012
|
area?: string | null | undefined;
|
|
1013
1013
|
}>, "many">>>;
|
|
1014
1014
|
highlights: z.ZodNullable<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>>;
|
|
1015
|
+
sourceDiversity: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
1015
1016
|
}, "strip", z.ZodTypeAny, {
|
|
1016
1017
|
name?: string | null | undefined;
|
|
1017
1018
|
createdAt?: string | null | undefined;
|
|
@@ -1121,6 +1122,7 @@ declare const NewsClusterSchema: z.ZodObject<{
|
|
|
1121
1122
|
area?: string | null | undefined;
|
|
1122
1123
|
}[] | null | undefined;
|
|
1123
1124
|
highlights?: Record<string, string[]> | null | undefined;
|
|
1125
|
+
sourceDiversity?: number | null | undefined;
|
|
1124
1126
|
}, {
|
|
1125
1127
|
name?: string | null | undefined;
|
|
1126
1128
|
createdAt?: string | null | undefined;
|
|
@@ -1230,6 +1232,7 @@ declare const NewsClusterSchema: z.ZodObject<{
|
|
|
1230
1232
|
area?: string | null | undefined;
|
|
1231
1233
|
}[] | null | undefined;
|
|
1232
1234
|
highlights?: Record<string, string[]> | null | undefined;
|
|
1235
|
+
sourceDiversity?: number | null | undefined;
|
|
1233
1236
|
}>;
|
|
1234
1237
|
type NewsCluster = z.infer<typeof NewsClusterSchema>;
|
|
1235
1238
|
declare const PlaceSchema: z.ZodObject<{
|
|
@@ -1864,6 +1867,7 @@ declare const ArticleSchema: z.ZodObject<{
|
|
|
1864
1867
|
area?: string | null | undefined;
|
|
1865
1868
|
}>, "many">>>;
|
|
1866
1869
|
highlights: z.ZodNullable<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>>;
|
|
1870
|
+
sourceDiversity: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
1867
1871
|
}, "strip", z.ZodTypeAny, {
|
|
1868
1872
|
name?: string | null | undefined;
|
|
1869
1873
|
createdAt?: string | null | undefined;
|
|
@@ -1973,6 +1977,7 @@ declare const ArticleSchema: z.ZodObject<{
|
|
|
1973
1977
|
area?: string | null | undefined;
|
|
1974
1978
|
}[] | null | undefined;
|
|
1975
1979
|
highlights?: Record<string, string[]> | null | undefined;
|
|
1980
|
+
sourceDiversity?: number | null | undefined;
|
|
1976
1981
|
}, {
|
|
1977
1982
|
name?: string | null | undefined;
|
|
1978
1983
|
createdAt?: string | null | undefined;
|
|
@@ -2082,6 +2087,7 @@ declare const ArticleSchema: z.ZodObject<{
|
|
|
2082
2087
|
area?: string | null | undefined;
|
|
2083
2088
|
}[] | null | undefined;
|
|
2084
2089
|
highlights?: Record<string, string[]> | null | undefined;
|
|
2090
|
+
sourceDiversity?: number | null | undefined;
|
|
2085
2091
|
}>>>;
|
|
2086
2092
|
journalists: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
2087
2093
|
id: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
@@ -2495,6 +2501,7 @@ declare const ArticleSchema: z.ZodObject<{
|
|
|
2495
2501
|
area?: string | null | undefined;
|
|
2496
2502
|
}[] | null | undefined;
|
|
2497
2503
|
highlights?: Record<string, string[]> | null | undefined;
|
|
2504
|
+
sourceDiversity?: number | null | undefined;
|
|
2498
2505
|
} | null | undefined;
|
|
2499
2506
|
journalists?: {
|
|
2500
2507
|
name?: string | null | undefined;
|
|
@@ -2769,6 +2776,7 @@ declare const ArticleSchema: z.ZodObject<{
|
|
|
2769
2776
|
area?: string | null | undefined;
|
|
2770
2777
|
}[] | null | undefined;
|
|
2771
2778
|
highlights?: Record<string, string[]> | null | undefined;
|
|
2779
|
+
sourceDiversity?: number | null | undefined;
|
|
2772
2780
|
} | null | undefined;
|
|
2773
2781
|
journalists?: {
|
|
2774
2782
|
name?: string | null | undefined;
|
|
@@ -4144,6 +4152,7 @@ declare const ScoredDataArticleSchema: z.ZodObject<{
|
|
|
4144
4152
|
area?: string | null | undefined;
|
|
4145
4153
|
}>, "many">>>;
|
|
4146
4154
|
highlights: z.ZodNullable<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>>;
|
|
4155
|
+
sourceDiversity: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
4147
4156
|
}, "strip", z.ZodTypeAny, {
|
|
4148
4157
|
name?: string | null | undefined;
|
|
4149
4158
|
createdAt?: string | null | undefined;
|
|
@@ -4253,6 +4262,7 @@ declare const ScoredDataArticleSchema: z.ZodObject<{
|
|
|
4253
4262
|
area?: string | null | undefined;
|
|
4254
4263
|
}[] | null | undefined;
|
|
4255
4264
|
highlights?: Record<string, string[]> | null | undefined;
|
|
4265
|
+
sourceDiversity?: number | null | undefined;
|
|
4256
4266
|
}, {
|
|
4257
4267
|
name?: string | null | undefined;
|
|
4258
4268
|
createdAt?: string | null | undefined;
|
|
@@ -4362,6 +4372,7 @@ declare const ScoredDataArticleSchema: z.ZodObject<{
|
|
|
4362
4372
|
area?: string | null | undefined;
|
|
4363
4373
|
}[] | null | undefined;
|
|
4364
4374
|
highlights?: Record<string, string[]> | null | undefined;
|
|
4375
|
+
sourceDiversity?: number | null | undefined;
|
|
4365
4376
|
}>>>;
|
|
4366
4377
|
journalists: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
4367
4378
|
id: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
@@ -4775,6 +4786,7 @@ declare const ScoredDataArticleSchema: z.ZodObject<{
|
|
|
4775
4786
|
area?: string | null | undefined;
|
|
4776
4787
|
}[] | null | undefined;
|
|
4777
4788
|
highlights?: Record<string, string[]> | null | undefined;
|
|
4789
|
+
sourceDiversity?: number | null | undefined;
|
|
4778
4790
|
} | null | undefined;
|
|
4779
4791
|
journalists?: {
|
|
4780
4792
|
name?: string | null | undefined;
|
|
@@ -5049,6 +5061,7 @@ declare const ScoredDataArticleSchema: z.ZodObject<{
|
|
|
5049
5061
|
area?: string | null | undefined;
|
|
5050
5062
|
}[] | null | undefined;
|
|
5051
5063
|
highlights?: Record<string, string[]> | null | undefined;
|
|
5064
|
+
sourceDiversity?: number | null | undefined;
|
|
5052
5065
|
} | null | undefined;
|
|
5053
5066
|
journalists?: {
|
|
5054
5067
|
name?: string | null | undefined;
|
|
@@ -5326,6 +5339,7 @@ declare const ScoredDataArticleSchema: z.ZodObject<{
|
|
|
5326
5339
|
area?: string | null | undefined;
|
|
5327
5340
|
}[] | null | undefined;
|
|
5328
5341
|
highlights?: Record<string, string[]> | null | undefined;
|
|
5342
|
+
sourceDiversity?: number | null | undefined;
|
|
5329
5343
|
} | null | undefined;
|
|
5330
5344
|
journalists?: {
|
|
5331
5345
|
name?: string | null | undefined;
|
|
@@ -5603,6 +5617,7 @@ declare const ScoredDataArticleSchema: z.ZodObject<{
|
|
|
5603
5617
|
area?: string | null | undefined;
|
|
5604
5618
|
}[] | null | undefined;
|
|
5605
5619
|
highlights?: Record<string, string[]> | null | undefined;
|
|
5620
|
+
sourceDiversity?: number | null | undefined;
|
|
5606
5621
|
} | null | undefined;
|
|
5607
5622
|
journalists?: {
|
|
5608
5623
|
name?: string | null | undefined;
|
|
@@ -6227,6 +6242,7 @@ declare const ArticlesVectorSearchResultSchema: z.ZodObject<{
|
|
|
6227
6242
|
area?: string | null | undefined;
|
|
6228
6243
|
}>, "many">>>;
|
|
6229
6244
|
highlights: z.ZodNullable<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>>;
|
|
6245
|
+
sourceDiversity: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
6230
6246
|
}, "strip", z.ZodTypeAny, {
|
|
6231
6247
|
name?: string | null | undefined;
|
|
6232
6248
|
createdAt?: string | null | undefined;
|
|
@@ -6336,6 +6352,7 @@ declare const ArticlesVectorSearchResultSchema: z.ZodObject<{
|
|
|
6336
6352
|
area?: string | null | undefined;
|
|
6337
6353
|
}[] | null | undefined;
|
|
6338
6354
|
highlights?: Record<string, string[]> | null | undefined;
|
|
6355
|
+
sourceDiversity?: number | null | undefined;
|
|
6339
6356
|
}, {
|
|
6340
6357
|
name?: string | null | undefined;
|
|
6341
6358
|
createdAt?: string | null | undefined;
|
|
@@ -6445,6 +6462,7 @@ declare const ArticlesVectorSearchResultSchema: z.ZodObject<{
|
|
|
6445
6462
|
area?: string | null | undefined;
|
|
6446
6463
|
}[] | null | undefined;
|
|
6447
6464
|
highlights?: Record<string, string[]> | null | undefined;
|
|
6465
|
+
sourceDiversity?: number | null | undefined;
|
|
6448
6466
|
}>>>;
|
|
6449
6467
|
journalists: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
6450
6468
|
id: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
@@ -6858,6 +6876,7 @@ declare const ArticlesVectorSearchResultSchema: z.ZodObject<{
|
|
|
6858
6876
|
area?: string | null | undefined;
|
|
6859
6877
|
}[] | null | undefined;
|
|
6860
6878
|
highlights?: Record<string, string[]> | null | undefined;
|
|
6879
|
+
sourceDiversity?: number | null | undefined;
|
|
6861
6880
|
} | null | undefined;
|
|
6862
6881
|
journalists?: {
|
|
6863
6882
|
name?: string | null | undefined;
|
|
@@ -7132,6 +7151,7 @@ declare const ArticlesVectorSearchResultSchema: z.ZodObject<{
|
|
|
7132
7151
|
area?: string | null | undefined;
|
|
7133
7152
|
}[] | null | undefined;
|
|
7134
7153
|
highlights?: Record<string, string[]> | null | undefined;
|
|
7154
|
+
sourceDiversity?: number | null | undefined;
|
|
7135
7155
|
} | null | undefined;
|
|
7136
7156
|
journalists?: {
|
|
7137
7157
|
name?: string | null | undefined;
|
|
@@ -7409,6 +7429,7 @@ declare const ArticlesVectorSearchResultSchema: z.ZodObject<{
|
|
|
7409
7429
|
area?: string | null | undefined;
|
|
7410
7430
|
}[] | null | undefined;
|
|
7411
7431
|
highlights?: Record<string, string[]> | null | undefined;
|
|
7432
|
+
sourceDiversity?: number | null | undefined;
|
|
7412
7433
|
} | null | undefined;
|
|
7413
7434
|
journalists?: {
|
|
7414
7435
|
name?: string | null | undefined;
|
|
@@ -7686,6 +7707,7 @@ declare const ArticlesVectorSearchResultSchema: z.ZodObject<{
|
|
|
7686
7707
|
area?: string | null | undefined;
|
|
7687
7708
|
}[] | null | undefined;
|
|
7688
7709
|
highlights?: Record<string, string[]> | null | undefined;
|
|
7710
|
+
sourceDiversity?: number | null | undefined;
|
|
7689
7711
|
} | null | undefined;
|
|
7690
7712
|
journalists?: {
|
|
7691
7713
|
name?: string | null | undefined;
|
|
@@ -7966,6 +7988,7 @@ declare const ArticlesVectorSearchResultSchema: z.ZodObject<{
|
|
|
7966
7988
|
area?: string | null | undefined;
|
|
7967
7989
|
}[] | null | undefined;
|
|
7968
7990
|
highlights?: Record<string, string[]> | null | undefined;
|
|
7991
|
+
sourceDiversity?: number | null | undefined;
|
|
7969
7992
|
} | null | undefined;
|
|
7970
7993
|
journalists?: {
|
|
7971
7994
|
name?: string | null | undefined;
|
|
@@ -8246,6 +8269,7 @@ declare const ArticlesVectorSearchResultSchema: z.ZodObject<{
|
|
|
8246
8269
|
area?: string | null | undefined;
|
|
8247
8270
|
}[] | null | undefined;
|
|
8248
8271
|
highlights?: Record<string, string[]> | null | undefined;
|
|
8272
|
+
sourceDiversity?: number | null | undefined;
|
|
8249
8273
|
} | null | undefined;
|
|
8250
8274
|
journalists?: {
|
|
8251
8275
|
name?: string | null | undefined;
|
|
@@ -10814,6 +10838,7 @@ declare const QuerySearchResultSchema: z.ZodObject<{
|
|
|
10814
10838
|
area?: string | null | undefined;
|
|
10815
10839
|
}>, "many">>>;
|
|
10816
10840
|
highlights: z.ZodNullable<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>>;
|
|
10841
|
+
sourceDiversity: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
10817
10842
|
}, "strip", z.ZodTypeAny, {
|
|
10818
10843
|
name?: string | null | undefined;
|
|
10819
10844
|
createdAt?: string | null | undefined;
|
|
@@ -10923,6 +10948,7 @@ declare const QuerySearchResultSchema: z.ZodObject<{
|
|
|
10923
10948
|
area?: string | null | undefined;
|
|
10924
10949
|
}[] | null | undefined;
|
|
10925
10950
|
highlights?: Record<string, string[]> | null | undefined;
|
|
10951
|
+
sourceDiversity?: number | null | undefined;
|
|
10926
10952
|
}, {
|
|
10927
10953
|
name?: string | null | undefined;
|
|
10928
10954
|
createdAt?: string | null | undefined;
|
|
@@ -11032,6 +11058,7 @@ declare const QuerySearchResultSchema: z.ZodObject<{
|
|
|
11032
11058
|
area?: string | null | undefined;
|
|
11033
11059
|
}[] | null | undefined;
|
|
11034
11060
|
highlights?: Record<string, string[]> | null | undefined;
|
|
11061
|
+
sourceDiversity?: number | null | undefined;
|
|
11035
11062
|
}>>>;
|
|
11036
11063
|
journalists: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
11037
11064
|
id: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
@@ -11445,6 +11472,7 @@ declare const QuerySearchResultSchema: z.ZodObject<{
|
|
|
11445
11472
|
area?: string | null | undefined;
|
|
11446
11473
|
}[] | null | undefined;
|
|
11447
11474
|
highlights?: Record<string, string[]> | null | undefined;
|
|
11475
|
+
sourceDiversity?: number | null | undefined;
|
|
11448
11476
|
} | null | undefined;
|
|
11449
11477
|
journalists?: {
|
|
11450
11478
|
name?: string | null | undefined;
|
|
@@ -11719,6 +11747,7 @@ declare const QuerySearchResultSchema: z.ZodObject<{
|
|
|
11719
11747
|
area?: string | null | undefined;
|
|
11720
11748
|
}[] | null | undefined;
|
|
11721
11749
|
highlights?: Record<string, string[]> | null | undefined;
|
|
11750
|
+
sourceDiversity?: number | null | undefined;
|
|
11722
11751
|
} | null | undefined;
|
|
11723
11752
|
journalists?: {
|
|
11724
11753
|
name?: string | null | undefined;
|
|
@@ -11997,6 +12026,7 @@ declare const QuerySearchResultSchema: z.ZodObject<{
|
|
|
11997
12026
|
area?: string | null | undefined;
|
|
11998
12027
|
}[] | null | undefined;
|
|
11999
12028
|
highlights?: Record<string, string[]> | null | undefined;
|
|
12029
|
+
sourceDiversity?: number | null | undefined;
|
|
12000
12030
|
} | null | undefined;
|
|
12001
12031
|
journalists?: {
|
|
12002
12032
|
name?: string | null | undefined;
|
|
@@ -12275,6 +12305,7 @@ declare const QuerySearchResultSchema: z.ZodObject<{
|
|
|
12275
12305
|
area?: string | null | undefined;
|
|
12276
12306
|
}[] | null | undefined;
|
|
12277
12307
|
highlights?: Record<string, string[]> | null | undefined;
|
|
12308
|
+
sourceDiversity?: number | null | undefined;
|
|
12278
12309
|
} | null | undefined;
|
|
12279
12310
|
journalists?: {
|
|
12280
12311
|
name?: string | null | undefined;
|
|
@@ -13533,6 +13564,7 @@ declare const StorySearchResultSchema: z.ZodObject<{
|
|
|
13533
13564
|
area?: string | null | undefined;
|
|
13534
13565
|
}>, "many">>>;
|
|
13535
13566
|
highlights: z.ZodNullable<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>>;
|
|
13567
|
+
sourceDiversity: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
13536
13568
|
}, "strip", z.ZodTypeAny, {
|
|
13537
13569
|
name?: string | null | undefined;
|
|
13538
13570
|
createdAt?: string | null | undefined;
|
|
@@ -13642,6 +13674,7 @@ declare const StorySearchResultSchema: z.ZodObject<{
|
|
|
13642
13674
|
area?: string | null | undefined;
|
|
13643
13675
|
}[] | null | undefined;
|
|
13644
13676
|
highlights?: Record<string, string[]> | null | undefined;
|
|
13677
|
+
sourceDiversity?: number | null | undefined;
|
|
13645
13678
|
}, {
|
|
13646
13679
|
name?: string | null | undefined;
|
|
13647
13680
|
createdAt?: string | null | undefined;
|
|
@@ -13751,6 +13784,7 @@ declare const StorySearchResultSchema: z.ZodObject<{
|
|
|
13751
13784
|
area?: string | null | undefined;
|
|
13752
13785
|
}[] | null | undefined;
|
|
13753
13786
|
highlights?: Record<string, string[]> | null | undefined;
|
|
13787
|
+
sourceDiversity?: number | null | undefined;
|
|
13754
13788
|
}>, "many">;
|
|
13755
13789
|
}, "strip", z.ZodTypeAny, {
|
|
13756
13790
|
status: number;
|
|
@@ -13863,6 +13897,7 @@ declare const StorySearchResultSchema: z.ZodObject<{
|
|
|
13863
13897
|
area?: string | null | undefined;
|
|
13864
13898
|
}[] | null | undefined;
|
|
13865
13899
|
highlights?: Record<string, string[]> | null | undefined;
|
|
13900
|
+
sourceDiversity?: number | null | undefined;
|
|
13866
13901
|
}[];
|
|
13867
13902
|
numResults: number;
|
|
13868
13903
|
}, {
|
|
@@ -13976,6 +14011,7 @@ declare const StorySearchResultSchema: z.ZodObject<{
|
|
|
13976
14011
|
area?: string | null | undefined;
|
|
13977
14012
|
}[] | null | undefined;
|
|
13978
14013
|
highlights?: Record<string, string[]> | null | undefined;
|
|
14014
|
+
sourceDiversity?: number | null | undefined;
|
|
13979
14015
|
}[];
|
|
13980
14016
|
numResults: number;
|
|
13981
14017
|
}>;
|
|
@@ -14610,6 +14646,7 @@ declare const SummarySearchResultSchema: z.ZodObject<{
|
|
|
14610
14646
|
area?: string | null | undefined;
|
|
14611
14647
|
}>, "many">>>;
|
|
14612
14648
|
highlights: z.ZodNullable<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>>;
|
|
14649
|
+
sourceDiversity: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
14613
14650
|
}, "strip", z.ZodTypeAny, {
|
|
14614
14651
|
name?: string | null | undefined;
|
|
14615
14652
|
createdAt?: string | null | undefined;
|
|
@@ -14719,6 +14756,7 @@ declare const SummarySearchResultSchema: z.ZodObject<{
|
|
|
14719
14756
|
area?: string | null | undefined;
|
|
14720
14757
|
}[] | null | undefined;
|
|
14721
14758
|
highlights?: Record<string, string[]> | null | undefined;
|
|
14759
|
+
sourceDiversity?: number | null | undefined;
|
|
14722
14760
|
}, {
|
|
14723
14761
|
name?: string | null | undefined;
|
|
14724
14762
|
createdAt?: string | null | undefined;
|
|
@@ -14828,6 +14866,7 @@ declare const SummarySearchResultSchema: z.ZodObject<{
|
|
|
14828
14866
|
area?: string | null | undefined;
|
|
14829
14867
|
}[] | null | undefined;
|
|
14830
14868
|
highlights?: Record<string, string[]> | null | undefined;
|
|
14869
|
+
sourceDiversity?: number | null | undefined;
|
|
14831
14870
|
}>>>;
|
|
14832
14871
|
journalists: z.ZodNullable<z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
14833
14872
|
id: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
@@ -15241,6 +15280,7 @@ declare const SummarySearchResultSchema: z.ZodObject<{
|
|
|
15241
15280
|
area?: string | null | undefined;
|
|
15242
15281
|
}[] | null | undefined;
|
|
15243
15282
|
highlights?: Record<string, string[]> | null | undefined;
|
|
15283
|
+
sourceDiversity?: number | null | undefined;
|
|
15244
15284
|
} | null | undefined;
|
|
15245
15285
|
journalists?: {
|
|
15246
15286
|
name?: string | null | undefined;
|
|
@@ -15515,6 +15555,7 @@ declare const SummarySearchResultSchema: z.ZodObject<{
|
|
|
15515
15555
|
area?: string | null | undefined;
|
|
15516
15556
|
}[] | null | undefined;
|
|
15517
15557
|
highlights?: Record<string, string[]> | null | undefined;
|
|
15558
|
+
sourceDiversity?: number | null | undefined;
|
|
15518
15559
|
} | null | undefined;
|
|
15519
15560
|
journalists?: {
|
|
15520
15561
|
name?: string | null | undefined;
|
|
@@ -15793,6 +15834,7 @@ declare const SummarySearchResultSchema: z.ZodObject<{
|
|
|
15793
15834
|
area?: string | null | undefined;
|
|
15794
15835
|
}[] | null | undefined;
|
|
15795
15836
|
highlights?: Record<string, string[]> | null | undefined;
|
|
15837
|
+
sourceDiversity?: number | null | undefined;
|
|
15796
15838
|
} | null | undefined;
|
|
15797
15839
|
journalists?: {
|
|
15798
15840
|
name?: string | null | undefined;
|
|
@@ -16072,6 +16114,7 @@ declare const SummarySearchResultSchema: z.ZodObject<{
|
|
|
16072
16114
|
area?: string | null | undefined;
|
|
16073
16115
|
}[] | null | undefined;
|
|
16074
16116
|
highlights?: Record<string, string[]> | null | undefined;
|
|
16117
|
+
sourceDiversity?: number | null | undefined;
|
|
16075
16118
|
} | null | undefined;
|
|
16076
16119
|
journalists?: {
|
|
16077
16120
|
name?: string | null | undefined;
|
|
@@ -17544,6 +17587,10 @@ declare const GetStoryCountsQuerySchema: z.ZodObject<{
|
|
|
17544
17587
|
* Integer. Specifies the minimum number of unique sources required for a story to appear in results. Higher values return more significant stories covered by multiple publications. Default is 3.
|
|
17545
17588
|
*/
|
|
17546
17589
|
minUniqueSources: z.ZodOptional<z.ZodNumber>;
|
|
17590
|
+
/**
|
|
17591
|
+
* Float. Minimum ratio of unique sources to unique articles (uniqueSources / uniqueCount). Filters out stories dominated by a single publisher. For example, a value of 0.05 requires at least 1 unique source per 20 articles. Not applied by default.
|
|
17592
|
+
*/
|
|
17593
|
+
minSourceDiversity: z.ZodOptional<z.ZodNumber>;
|
|
17547
17594
|
/**
|
|
17548
17595
|
* String Array. Filter stories by Wikidata IDs of top mentioned people. Returns stories where these individuals appear prominently. Refer to the /people endpoint for a complete list of tracked individuals.
|
|
17549
17596
|
*/
|
|
@@ -17698,6 +17745,7 @@ declare const GetStoryCountsQuerySchema: z.ZodObject<{
|
|
|
17698
17745
|
updatedFrom?: Date | undefined;
|
|
17699
17746
|
updatedTo?: Date | undefined;
|
|
17700
17747
|
minUniqueSources?: number | undefined;
|
|
17748
|
+
minSourceDiversity?: number | undefined;
|
|
17701
17749
|
minClusterSize?: number | undefined;
|
|
17702
17750
|
maxClusterSize?: number | undefined;
|
|
17703
17751
|
nameExists?: boolean | undefined;
|
|
@@ -17748,6 +17796,7 @@ declare const GetStoryCountsQuerySchema: z.ZodObject<{
|
|
|
17748
17796
|
updatedFrom?: Date | undefined;
|
|
17749
17797
|
updatedTo?: Date | undefined;
|
|
17750
17798
|
minUniqueSources?: number | undefined;
|
|
17799
|
+
minSourceDiversity?: number | undefined;
|
|
17751
17800
|
minClusterSize?: number | undefined;
|
|
17752
17801
|
maxClusterSize?: number | undefined;
|
|
17753
17802
|
nameExists?: boolean | undefined;
|
|
@@ -17845,6 +17894,10 @@ declare const GetStoryCountsRequestSchema: z.ZodObject<{
|
|
|
17845
17894
|
* Integer. Specifies the minimum number of unique sources required for a story to appear in results. Higher values return more significant stories covered by multiple publications. Default is 3.
|
|
17846
17895
|
*/
|
|
17847
17896
|
minUniqueSources: z.ZodOptional<z.ZodNumber>;
|
|
17897
|
+
/**
|
|
17898
|
+
* Float. Minimum ratio of unique sources to unique articles (uniqueSources / uniqueCount). Filters out stories dominated by a single publisher. For example, a value of 0.05 requires at least 1 unique source per 20 articles. Not applied by default.
|
|
17899
|
+
*/
|
|
17900
|
+
minSourceDiversity: z.ZodOptional<z.ZodNumber>;
|
|
17848
17901
|
/**
|
|
17849
17902
|
* String Array. Filter stories by Wikidata IDs of top mentioned people. Returns stories where these individuals appear prominently. Refer to the /people endpoint for a complete list of tracked individuals.
|
|
17850
17903
|
*/
|
|
@@ -17999,6 +18052,7 @@ declare const GetStoryCountsRequestSchema: z.ZodObject<{
|
|
|
17999
18052
|
updatedFrom?: Date | undefined;
|
|
18000
18053
|
updatedTo?: Date | undefined;
|
|
18001
18054
|
minUniqueSources?: number | undefined;
|
|
18055
|
+
minSourceDiversity?: number | undefined;
|
|
18002
18056
|
minClusterSize?: number | undefined;
|
|
18003
18057
|
maxClusterSize?: number | undefined;
|
|
18004
18058
|
nameExists?: boolean | undefined;
|
|
@@ -18049,6 +18103,7 @@ declare const GetStoryCountsRequestSchema: z.ZodObject<{
|
|
|
18049
18103
|
updatedFrom?: Date | undefined;
|
|
18050
18104
|
updatedTo?: Date | undefined;
|
|
18051
18105
|
minUniqueSources?: number | undefined;
|
|
18106
|
+
minSourceDiversity?: number | undefined;
|
|
18052
18107
|
minClusterSize?: number | undefined;
|
|
18053
18108
|
maxClusterSize?: number | undefined;
|
|
18054
18109
|
nameExists?: boolean | undefined;
|
|
@@ -20360,6 +20415,10 @@ declare const SearchStoriesQuerySchema: z.ZodObject<{
|
|
|
20360
20415
|
* Integer. Specifies the minimum number of unique sources required for a story to appear in results. Higher values return more significant stories covered by multiple publications. Default is 3.
|
|
20361
20416
|
*/
|
|
20362
20417
|
minUniqueSources: z.ZodOptional<z.ZodNumber>;
|
|
20418
|
+
/**
|
|
20419
|
+
* Float. Minimum ratio of unique sources to unique articles (uniqueSources / uniqueCount). Filters out stories dominated by a single publisher. For example, a value of 0.05 requires at least 1 unique source per 20 articles. Not applied by default.
|
|
20420
|
+
*/
|
|
20421
|
+
minSourceDiversity: z.ZodOptional<z.ZodNumber>;
|
|
20363
20422
|
/**
|
|
20364
20423
|
* String Array. Filter stories by Wikidata IDs of top mentioned people. Returns stories where these individuals appear prominently. Refer to the /people endpoint for a complete list of tracked individuals.
|
|
20365
20424
|
*/
|
|
@@ -20506,6 +20565,7 @@ declare const SearchStoriesQuerySchema: z.ZodObject<{
|
|
|
20506
20565
|
updatedFrom?: Date | undefined;
|
|
20507
20566
|
updatedTo?: Date | undefined;
|
|
20508
20567
|
minUniqueSources?: number | undefined;
|
|
20568
|
+
minSourceDiversity?: number | undefined;
|
|
20509
20569
|
minClusterSize?: number | undefined;
|
|
20510
20570
|
maxClusterSize?: number | undefined;
|
|
20511
20571
|
nameExists?: boolean | undefined;
|
|
@@ -20555,6 +20615,7 @@ declare const SearchStoriesQuerySchema: z.ZodObject<{
|
|
|
20555
20615
|
updatedFrom?: Date | undefined;
|
|
20556
20616
|
updatedTo?: Date | undefined;
|
|
20557
20617
|
minUniqueSources?: number | undefined;
|
|
20618
|
+
minSourceDiversity?: number | undefined;
|
|
20558
20619
|
minClusterSize?: number | undefined;
|
|
20559
20620
|
maxClusterSize?: number | undefined;
|
|
20560
20621
|
nameExists?: boolean | undefined;
|
|
@@ -20652,6 +20713,10 @@ declare const SearchStoriesRequestSchema: z.ZodObject<{
|
|
|
20652
20713
|
* Integer. Specifies the minimum number of unique sources required for a story to appear in results. Higher values return more significant stories covered by multiple publications. Default is 3.
|
|
20653
20714
|
*/
|
|
20654
20715
|
minUniqueSources: z.ZodOptional<z.ZodNumber>;
|
|
20716
|
+
/**
|
|
20717
|
+
* Float. Minimum ratio of unique sources to unique articles (uniqueSources / uniqueCount). Filters out stories dominated by a single publisher. For example, a value of 0.05 requires at least 1 unique source per 20 articles. Not applied by default.
|
|
20718
|
+
*/
|
|
20719
|
+
minSourceDiversity: z.ZodOptional<z.ZodNumber>;
|
|
20655
20720
|
/**
|
|
20656
20721
|
* String Array. Filter stories by Wikidata IDs of top mentioned people. Returns stories where these individuals appear prominently. Refer to the /people endpoint for a complete list of tracked individuals.
|
|
20657
20722
|
*/
|
|
@@ -20798,6 +20863,7 @@ declare const SearchStoriesRequestSchema: z.ZodObject<{
|
|
|
20798
20863
|
updatedFrom?: Date | undefined;
|
|
20799
20864
|
updatedTo?: Date | undefined;
|
|
20800
20865
|
minUniqueSources?: number | undefined;
|
|
20866
|
+
minSourceDiversity?: number | undefined;
|
|
20801
20867
|
minClusterSize?: number | undefined;
|
|
20802
20868
|
maxClusterSize?: number | undefined;
|
|
20803
20869
|
nameExists?: boolean | undefined;
|
|
@@ -20847,6 +20913,7 @@ declare const SearchStoriesRequestSchema: z.ZodObject<{
|
|
|
20847
20913
|
updatedFrom?: Date | undefined;
|
|
20848
20914
|
updatedTo?: Date | undefined;
|
|
20849
20915
|
minUniqueSources?: number | undefined;
|
|
20916
|
+
minSourceDiversity?: number | undefined;
|
|
20850
20917
|
minClusterSize?: number | undefined;
|
|
20851
20918
|
maxClusterSize?: number | undefined;
|
|
20852
20919
|
nameExists?: boolean | undefined;
|
package/dist/index.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import {z as z$1}from'zod';var We="https://api.perigon.io".replace(/\/+$/,""),w=class{constructor(o={}){this.configuration=o;}set config(o){this.configuration=o;}get basePath(){return We}get fetchApi(){return this.configuration.fetchApi}get middleware(){return this.configuration.middleware||[]}get queryParamsStringify(){return this.configuration.queryParamsStringify||B}get accessToken(){let o=this.configuration.apiKey;return o?typeof o=="function"?o:async()=>o:void 0}get headers(){return this.configuration.headers}get credentials(){return this.configuration.credentials}},Ge=new w,k=class extends Error{constructor(a,i){super(i);this.cause=a;this.name="FetchError";}},m=class extends Error{constructor(o,a){let i=`HTTP ${o.status}: ${o.statusText}`;super(i),this.name="HttpError",this.status=o.status,this.statusText=o.statusText,this.response=o,this.body=a;}},P=class extends m{constructor(o,a){super(o,a),this.name="BadRequestError",this.message=a?.message||"Bad request - please check your input parameters";}},q=class extends m{constructor(o,a){super(o,a),this.name="UnauthorizedError",this.message="Authentication required - please check your credentials";}},C=class extends m{constructor(o,a){super(o,a),this.name="ForbiddenError",this.message="Access denied - insufficient permissions";}},j=class extends m{constructor(o,a){super(o,a),this.name="NotFoundError",this.message=a?.message||"Resource not found";}},A=class extends m{constructor(o,a){super(o,a),this.name="RateLimitError",this.message="Rate limit exceeded - please try again later";let i=o.headers.get("retry-after");i&&(this.retryAfter=parseInt(i,10));}},I=class extends m{constructor(o,a){super(o,a),this.name="ServerError",this.message="Server error - please try again later";}},D=class extends Error{constructor(o){super("Network error - please check your connection"),this.name="NetworkError",this.cause=o;}};function De(u,o){return u.status===400?new P(u,o):u.status===401?new q(u,o):u.status===403?new C(u,o):u.status===404?new j(u,o):u.status===429?new A(u,o):u.status>499?new I(u,o):new m(u,o)}var b=class b{constructor(o=Ge){this.configuration=o;this.fetchApi=async(o,a)=>{let i={url:o,init:a};for(let n of this.middleware)n.pre&&(i=await n.pre({fetch:this.fetchApi,...i})||i);let r;try{r=await(this.configuration.fetchApi||fetch)(i.url,i.init);}catch(n){for(let p of this.middleware)p.onError&&(r=await p.onError({fetch:this.fetchApi,url:i.url,init:i.init,error:n,response:r?r.clone():void 0})||r);if(r===void 0)throw n instanceof Error?new k(n,"The request failed and the interceptors did not return an alternative response"):n}for(let n of this.middleware)n.post&&(r=await n.post({fetch:this.fetchApi,url:i.url,init:i.init,response:r.clone()})||r);return r};this.middleware=o.middleware;}withMiddleware(...o){let a=this.clone();return a.middleware=a.middleware.concat(...o),a}withPreMiddleware(...o){let a=o.map(i=>({pre:i}));return this.withMiddleware(...a)}withPostMiddleware(...o){let a=o.map(i=>({post:i}));return this.withMiddleware(...a)}isJsonMime(o){return o?b.jsonRegex.test(o):false}async request(o,a){let{url:i,init:r}=await this.createFetchParams(o,a),n=await this.fetchApi(i,r);if(n&&n.status>=200&&n.status<300)return n;let p;try{n.headers.get("content-type")?.includes("application/json")&&(p=await n.json());}catch{}throw De(n,p)}async createFetchParams(o,a){let i=this.configuration.basePath+o.path;o.query!==void 0&&Object.keys(o.query).length!==0&&(i+="?"+this.configuration.queryParamsStringify(o.query));let r=Object.assign({},this.configuration.headers,o.headers);Object.keys(r).forEach(G=>r[G]===void 0?delete r[G]:{});let n=typeof a=="function"?a:async()=>a,p={method:o.method,headers:r,body:o.body,credentials:this.configuration.credentials},s={...p,...await n({init:p,context:o})},l;Fe(s.body)||s.body instanceof URLSearchParams||Be(s.body)?l=s.body:this.isJsonMime(r["Content-Type"])?l=JSON.stringify(s.body):l=s.body;let c={...s,body:l};return {url:i,init:c}}clone(){let o=this.constructor,a=new o(this.configuration);return a.middleware=this.middleware.slice(),a}};b.jsonRegex=new RegExp("^(:?application/json|[^;/ ]+/[^;/ ]+[+]json)[ ]*(:?;.*)?$","i");var g=b;function Be(u){return typeof Blob<"u"&&u instanceof Blob}function Fe(u){return typeof FormData<"u"&&u instanceof FormData}var eo={csv:",",ssv:" ",tsv:" ",pipes:"|"};function B(u,o=""){return Object.keys(u).map(a=>F(a,u[a],o)).filter(a=>a.length>0).join("&")}function F(u,o,a=""){let i=a+(a.length?`[${u}]`:u);if(o instanceof Array){let r=o.map(n=>encodeURIComponent(String(n))).join(`&${encodeURIComponent(i)}=`);return `${encodeURIComponent(i)}=${r}`}if(o instanceof Set){let r=Array.from(o);return F(u,r,a)}return o instanceof Date?`${encodeURIComponent(i)}=${encodeURIComponent(o.toISOString())}`:o instanceof Object?B(o,i):`${encodeURIComponent(i)}=${encodeURIComponent(String(o))}`}function to(u,o){let a=u[o];return a!=null}var R=z$1.enum(["createdAt","updatedAt","relevance","count","totalCount"]),ao={CreatedAt:"createdAt",UpdatedAt:"updatedAt",Relevance:"relevance",Count:"count",TotalCount:"totalCount"},z=z$1.enum(["relevance","date","reverseDate","reverseAddDate","addDate","pubDate","refreshDate"]),no={Relevance:"relevance",Date:"date",ReverseDate:"reverseDate",ReverseAddDate:"reverseAddDate",AddDate:"addDate",PubDate:"pubDate",RefreshDate:"refreshDate"},H=z$1.object({name:z$1.string().optional().nullable()}),Oe=z$1.object({name:z$1.string().optional().nullable(),score:z$1.number().optional().nullable()}),O=z$1.object({id:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),domains:z$1.array(z$1.string()).optional().nullable(),symbols:z$1.array(z$1.string()).optional().nullable()}),Le=z$1.object({data:z$1.string().optional().nullable(),type:z$1.string().optional().nullable(),mentions:z$1.number().optional().nullable()}),Ne=z$1.object({name:z$1.string().optional().nullable(),type:z$1.string().optional().nullable()}),Ue=z$1.object({id:z$1.string().optional().nullable(),name:z$1.string().optional().nullable()}),v=z$1.object({country:z$1.string().optional().nullable(),state:z$1.string().optional().nullable(),county:z$1.string().optional().nullable(),city:z$1.string().optional().nullable(),area:z$1.string().optional().nullable()}),h=z$1.object({name:z$1.string().optional().nullable(),count:z$1.number().optional().nullable()}),T=z$1.object({id:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),fullName:z$1.string().optional().nullable(),headline:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),title:z$1.string().optional().nullable(),locations:z$1.array(v).optional().nullable(),updatedAt:z$1.string().optional().nullable(),topTopics:z$1.array(h).optional().nullable(),topSources:z$1.array(h).optional().nullable(),topCategories:z$1.array(h).optional().nullable(),topLabels:z$1.array(h).optional().nullable(),topCountries:z$1.array(h).optional().nullable(),avgMonthlyPosts:z$1.number().optional().nullable(),twitterHandle:z$1.string().optional().nullable(),twitterBio:z$1.string().optional().nullable(),imageUrl:z$1.string().optional().nullable(),linkedinUrl:z$1.string().optional().nullable(),linkedinConnections:z$1.number().optional().nullable(),linkedinFollowers:z$1.number().optional().nullable(),facebookUrl:z$1.string().optional().nullable(),instagramUrl:z$1.string().optional().nullable(),websiteUrl:z$1.string().optional().nullable(),blogUrl:z$1.string().optional().nullable(),tumblrUrl:z$1.string().optional().nullable(),youtubeUrl:z$1.string().optional().nullable()}),Me=z$1.object({name:z$1.string().optional().nullable(),weight:z$1.number().optional().nullable()}),$e=z$1.object({name:z$1.string().optional().nullable()}),Ke=z$1.object({id:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),domains:z$1.array(z$1.string()).optional().nullable(),symbols:z$1.array(z$1.string()).optional().nullable(),count:z$1.number().optional().nullable()}),L=z$1.object({point:z$1.string().optional().nullable(),references:z$1.array(z$1.string()).optional().nullable()}),Qe=z$1.object({country:z$1.string().optional().nullable(),state:z$1.string().optional().nullable(),county:z$1.string().optional().nullable(),city:z$1.string().optional().nullable(),area:z$1.string().optional().nullable(),count:z$1.number().optional().nullable()}),Ve=z$1.object({wikidataId:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),count:z$1.number().optional().nullable()}),N=z$1.object({wikidataId:z$1.string().optional().nullable(),name:z$1.string().optional().nullable()}),U=z$1.object({question:z$1.string().optional().nullable(),answer:z$1.string().optional().nullable(),references:z$1.array(z$1.string()).optional().nullable()}),S=z$1.object({name:z$1.string().optional().nullable(),count:z$1.number().optional().nullable()}),M=z$1.object({positive:z$1.number().optional().nullable(),negative:z$1.number().optional().nullable(),neutral:z$1.number().optional().nullable()}),$=z$1.object({lat:z$1.number().optional().nullable(),lon:z$1.number().optional().nullable()}),K=z$1.object({country:z$1.string().optional().nullable(),state:z$1.string().optional().nullable(),county:z$1.string().optional().nullable(),city:z$1.string().optional().nullable(),coordinates:$.optional().nullable()}),Q=z$1.object({domain:z$1.string().optional().nullable(),paywall:z$1.boolean().optional().nullable(),location:K.optional().nullable()}),V=z$1.object({name:z$1.string().optional().nullable()}),J=z$1.object({createdAt:z$1.string().optional().nullable(),updatedAt:z$1.string().optional().nullable(),initializedAt:z$1.string().optional().nullable(),id:z$1.string().optional().nullable(),duplicateOf:z$1.string().optional().nullable(),slug:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),summary:z$1.string().optional().nullable(),shortSummary:z$1.string().optional().nullable(),summaryReferences:z$1.array(z$1.string()).optional().nullable(),imageSource:Q.optional().nullable(),imageUrl:z$1.string().optional().nullable(),keyPoints:z$1.array(L).optional().nullable(),questions:z$1.array(U).optional().nullable(),uniqueSources:z$1.array(z$1.string()).optional().nullable(),selectedArticles:z$1.array(z$1.unknown()).optional().nullable(),sentiment:M.optional().nullable(),uniqueCount:z$1.number().optional().nullable(),reprintCount:z$1.number().optional().nullable(),totalCount:z$1.number().optional().nullable(),countries:z$1.array(S).optional().nullable(),topCountries:z$1.array(z$1.string()).optional().nullable(),topics:z$1.array(S).optional().nullable(),topTopics:z$1.array(V).optional().nullable(),categories:z$1.array(S).optional().nullable(),topCategories:z$1.array(H).optional().nullable(),taxonomies:z$1.array(S).optional().nullable(),topTaxonomies:z$1.array(H).optional().nullable(),people:z$1.array(Ve).optional().nullable(),topPeople:z$1.array(N).optional().nullable(),companies:z$1.array(Ke).optional().nullable(),topCompanies:z$1.array(O).optional().nullable(),locations:z$1.array(Qe).optional().nullable(),topLocations:z$1.array(v).optional().nullable(),highlights:z$1.record(z$1.string(),z$1.array(z$1.string())).optional().nullable()}),Je=z$1.object({osmId:z$1.string().optional().nullable(),road:z$1.string().optional().nullable(),quarter:z$1.string().optional().nullable(),suburb:z$1.string().optional().nullable(),city:z$1.string().optional().nullable(),town:z$1.string().optional().nullable(),county:z$1.string().optional().nullable(),stateDistrict:z$1.string().optional().nullable(),state:z$1.string().optional().nullable(),postcode:z$1.string().optional().nullable(),country:z$1.string().optional().nullable(),countryCode:z$1.string().optional().nullable(),amenity:z$1.string().optional().nullable(),neighbourhood:z$1.string().optional().nullable(),coordinates:$.optional().nullable()}),W=z$1.object({url:z$1.string().optional().nullable(),authorsByline:z$1.string().optional().nullable(),articleId:z$1.string().optional().nullable(),clusterId:z$1.string().optional().nullable(),source:Q.optional().nullable(),imageUrl:z$1.string().optional().nullable(),country:z$1.string().optional().nullable(),language:z$1.string().optional().nullable(),pubDate:z$1.string().optional().nullable(),addDate:z$1.string().optional().nullable(),refreshDate:z$1.string().optional().nullable(),score:z$1.number().optional().nullable(),title:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),content:z$1.string().optional().nullable(),enContentWordCount:z$1.number().optional().nullable(),medium:z$1.string().optional().nullable(),links:z$1.array(z$1.string()).optional().nullable(),labels:z$1.array($e).optional().nullable(),eventTypes:z$1.array(Ne).optional().nullable(),matchedAuthors:z$1.array(Ue).optional().nullable(),claim:z$1.string().optional().nullable(),verdict:z$1.string().optional().nullable(),keywords:z$1.array(Me).optional().nullable(),topics:z$1.array(V).optional().nullable(),categories:z$1.array(H).optional().nullable(),taxonomies:z$1.array(Oe).optional().nullable(),entities:z$1.array(Le).optional().nullable(),companies:z$1.array(O).optional().nullable(),sentiment:M.optional().nullable(),summary:z$1.string().optional().nullable(),shortSummary:z$1.string().optional().nullable(),translation:z$1.string().optional().nullable(),translatedTitle:z$1.string().optional().nullable(),translatedDescription:z$1.string().optional().nullable(),translatedSummary:z$1.string().optional().nullable(),locations:z$1.array(v).optional().nullable(),reprint:z$1.boolean().optional().nullable(),reprintGroupId:z$1.string().optional().nullable(),places:z$1.array(Je).optional().nullable(),people:z$1.array(N).optional().nullable(),cluster:J.optional().nullable(),journalists:z$1.array(T).optional().nullable(),highlights:z$1.record(z$1.string(),z$1.array(z$1.string())).optional().nullable()}),E=z$1.object({lat:z$1.number().optional().nullable(),lon:z$1.number().optional().nullable(),radius:z$1.number().optional().nullable()}),Ye=z$1.object({articleId:z$1.array(z$1.string()).optional().nullable(),clusterId:z$1.array(z$1.string()).optional().nullable(),source:z$1.array(z$1.string()).optional().nullable(),excludeSource:z$1.array(z$1.string()).optional().nullable(),sourceGroup:z$1.array(z$1.string()).optional().nullable(),language:z$1.array(z$1.string()).optional().nullable(),excludeLanguage:z$1.array(z$1.string()).optional().nullable(),label:z$1.array(z$1.string()).optional().nullable(),excludeLabel:z$1.array(z$1.string()).optional().nullable(),taxonomy:z$1.array(z$1.string()).optional().nullable(),category:z$1.array(z$1.string()).optional().nullable(),topic:z$1.array(z$1.string()).optional().nullable(),excludeTopic:z$1.array(z$1.string()).optional().nullable(),country:z$1.array(z$1.string()).optional().nullable(),excludeCountry:z$1.array(z$1.string()).optional().nullable(),locationsCountry:z$1.array(z$1.string()).optional().nullable(),excludeLocationsCountry:z$1.array(z$1.string()).optional().nullable(),state:z$1.array(z$1.string()).optional().nullable(),excludeState:z$1.array(z$1.string()).optional().nullable(),county:z$1.array(z$1.string()).optional().nullable(),excludeCounty:z$1.array(z$1.string()).optional().nullable(),city:z$1.array(z$1.string()).optional().nullable(),excludeCity:z$1.array(z$1.string()).optional().nullable(),sourceCountry:z$1.array(z$1.string()).optional().nullable(),sourceState:z$1.array(z$1.string()).optional().nullable(),sourceCounty:z$1.array(z$1.string()).optional().nullable(),sourceCity:z$1.array(z$1.string()).optional().nullable(),coordinates:E.optional().nullable(),sourceCoordinates:E.optional().nullable(),companyId:z$1.array(z$1.string()).optional().nullable(),excludeCompanyId:z$1.array(z$1.string()).optional().nullable(),companyDomain:z$1.array(z$1.string()).optional().nullable(),excludeCompanyDomain:z$1.array(z$1.string()).optional().nullable(),companySymbol:z$1.array(z$1.string()).optional().nullable(),excludeCompanySymbol:z$1.array(z$1.string()).optional().nullable(),companyName:z$1.array(z$1.string()).optional().nullable(),personWikidataId:z$1.array(z$1.string()).optional().nullable(),excludePersonWikidataId:z$1.array(z$1.string()).optional().nullable(),personName:z$1.array(z$1.string()).optional().nullable(),excludePersonName:z$1.array(z$1.string()).optional().nullable(),AND:z$1.array(z$1.unknown()).optional().nullable(),OR:z$1.array(z$1.unknown()).optional().nullable(),NOT:z$1.array(z$1.unknown()).optional().nullable()}),Y=z$1.object({prompt:z$1.string(),filter:Ye.optional().nullable(),pubDateFrom:z$1.union([z$1.string().date(),z$1.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),pubDateTo:z$1.union([z$1.string().date(),z$1.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),showReprints:z$1.boolean().optional().nullable(),size:z$1.number().optional().nullable(),page:z$1.number().optional().nullable()}),_e=z$1.object({score:z$1.number().optional().nullable(),data:W.optional().nullable()}),_=z$1.object({status:z$1.number(),results:z$1.array(_e)}),Xe=z$1.object({symbol:z$1.string().optional().nullable(),exchange:z$1.string().optional().nullable(),exchangeShortName:z$1.string().optional().nullable(),ipoDate:z$1.string().optional().nullable()}),Ze=z$1.object({careers:z$1.string().optional().nullable(),about:z$1.string().optional().nullable(),blog:z$1.string().optional().nullable(),events:z$1.string().optional().nullable(),sitemap:z$1.string().optional().nullable(),updates:z$1.string().optional().nullable(),linkedin:z$1.string().optional().nullable(),facebook:z$1.string().optional().nullable(),instagram:z$1.string().optional().nullable(),medium:z$1.string().optional().nullable(),reddit:z$1.string().optional().nullable(),threads:z$1.string().optional().nullable(),tiktok:z$1.string().optional().nullable(),x:z$1.string().optional().nullable(),wellfound:z$1.string().optional().nullable(),youtube:z$1.string().optional().nullable(),wikipedia:z$1.string().optional().nullable()}),et=z$1.object({id:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),updatedAt:z$1.string().optional().nullable(),primaryRecordId:z$1.string().optional().nullable(),altNames:z$1.array(z$1.string()).optional().nullable(),domains:z$1.array(z$1.string()).optional().nullable(),monthlyVisits:z$1.number().optional().nullable(),globalRank:z$1.number().optional().nullable(),description:z$1.string().optional().nullable(),ceo:z$1.string().optional().nullable(),industry:z$1.string().optional().nullable(),sector:z$1.string().optional().nullable(),country:z$1.string().optional().nullable(),fullTimeEmployees:z$1.number().optional().nullable(),address:z$1.string().optional().nullable(),city:z$1.string().optional().nullable(),state:z$1.string().optional().nullable(),zip:z$1.string().optional().nullable(),logo:z$1.string().optional().nullable(),favicon:z$1.string().optional().nullable(),isEtf:z$1.boolean().optional().nullable(),isActivelyTrading:z$1.boolean().optional().nullable(),isFund:z$1.boolean().optional().nullable(),isAdr:z$1.boolean().optional().nullable(),symbols:z$1.array(Xe).optional().nullable(),naics:z$1.string().optional().nullable(),sic:z$1.string().optional().nullable(),cusip:z$1.string().optional().nullable(),cik:z$1.string().optional().nullable(),isin:z$1.string().optional().nullable(),yearFounded:z$1.number().optional().nullable(),revenue:z$1.string().optional().nullable(),webResources:Ze.optional().nullable()}),X=z$1.object({status:z$1.number(),numResults:z$1.number(),results:z$1.array(et)}),Z=z$1.object({name:z$1.string(),displayName:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),domains:z$1.array(z$1.string())}),x=z$1.object({url:z$1.string().optional().nullable()}),y=z$1.object({time:z$1.string().optional().nullable(),precision:z$1.string().optional().nullable()}),d=z$1.object({wikidataId:z$1.string().optional().nullable(),label:z$1.string().optional().nullable()}),tt=z$1.object({wikidataId:z$1.string().optional().nullable(),label:z$1.string().optional().nullable(),startTime:y.optional().nullable(),endTime:y.optional().nullable()}),ot=z$1.object({wikidataId:z$1.string().optional().nullable(),label:z$1.string().optional().nullable(),startTime:y.optional().nullable(),endTime:y.optional().nullable(),employer:d.optional().nullable()}),at=z$1.object({wikidataId:z$1.string().optional().nullable(),createdAt:z$1.string().optional().nullable(),updatedAt:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),gender:d.optional().nullable(),dateOfBirth:y.optional().nullable(),dateOfDeath:y.optional().nullable(),description:z$1.string().optional().nullable(),aliases:z$1.array(z$1.string()).optional().nullable(),occupation:z$1.array(d).optional().nullable(),position:z$1.array(ot).optional().nullable(),politicalParty:z$1.array(tt).optional().nullable(),image:x.optional().nullable(),_abstract:z$1.string().optional().nullable()}),ee=z$1.object({name:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),id:z$1.string().optional().nullable(),domain:z$1.string().optional().nullable(),aliases:z$1.array(z$1.string()).optional().nullable()}),te=z$1.object({name:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),aliases:z$1.array(z$1.string()).optional().nullable(),wikidataId:z$1.string().optional().nullable()}),oe=z$1.object({name:z$1.string(),displayName:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),people:z$1.array(te),companies:z$1.array(ee),visible:z$1.boolean().optional().nullable()}),ro=z$1.object({status:z$1.number().optional().nullable(),message:z$1.string().optional().nullable(),timestamp:z$1.number().optional().nullable()}),ae=z$1.object({status:z$1.number(),numResults:z$1.number(),results:z$1.array(T)}),ne=z$1.object({name:z$1.string().optional().nullable(),displayName:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),domains:z$1.array(z$1.string()).optional().nullable()}),re=z$1.object({status:z$1.number(),numResults:z$1.number(),results:z$1.array(at)}),ie=z$1.object({status:z$1.number(),numResults:z$1.number(),articles:z$1.array(W)}),nt=z$1.object({pageId:z$1.string().optional().nullable(),sectionId:z$1.string().optional().nullable(),wikiPageId:z$1.number().optional().nullable(),wikiRevisionId:z$1.number().optional().nullable(),wikiRevisionTs:z$1.string().optional().nullable(),wikiCode:z$1.string().optional().nullable(),wikiNamespace:z$1.number().optional().nullable(),wikiTitle:z$1.string().optional().nullable(),wikidataId:z$1.string().optional().nullable(),wikidataInstanceOf:z$1.array(d).optional().nullable(),redirectTitles:z$1.array(z$1.string()).optional().nullable(),pageviews:z$1.number().optional().nullable(),title:z$1.string().optional().nullable(),styleLevel:z$1.number().optional().nullable(),content:z$1.string().optional().nullable()}),rt=z$1.object({score:z$1.number().optional().nullable(),data:nt.optional().nullable()}),f=z$1.object({name:z$1.string().optional().nullable(),count:z$1.number().optional().nullable()}),it=z$1.object({id:z$1.string().optional().nullable(),domain:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),primaryRecordId:z$1.string().optional().nullable(),updatedAt:z$1.string().optional().nullable(),altNames:z$1.array(z$1.string()).optional().nullable(),description:z$1.string().optional().nullable(),avgMonthlyPosts:z$1.number().optional().nullable(),paywall:z$1.boolean().optional().nullable(),location:K.optional().nullable(),topCategories:z$1.array(f).optional().nullable(),topTopics:z$1.array(f).optional().nullable(),topCountries:z$1.array(f).optional().nullable(),topLabels:z$1.array(f).optional().nullable(),avgBiasRating:z$1.string().optional().nullable(),adFontesBiasRating:z$1.string().optional().nullable(),allSidesBiasRating:z$1.string().optional().nullable(),mbfcBiasRating:z$1.string().optional().nullable(),monthlyVisits:z$1.number().optional().nullable(),globalRank:z$1.number().optional().nullable(),logoLarge:x.optional().nullable(),logoFavIcon:x.optional().nullable(),logoSquare:x.optional().nullable()}),le=z$1.object({status:z$1.number(),numResults:z$1.number(),results:z$1.array(it)}),se=z$1.object({status:z$1.number().optional().nullable(),results:z$1.array(z$1.unknown()).optional().nullable()}),lt=z$1.object({clusterId:z$1.string().optional().nullable(),createdAt:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),triggeredAt:z$1.string().optional().nullable(),summary:z$1.string().optional().nullable(),shortSummary:z$1.string().optional().nullable(),changelog:z$1.string().optional().nullable(),keyPoints:z$1.array(L).optional().nullable(),questions:z$1.array(U).optional().nullable()}),pe=z$1.object({status:z$1.number(),numResults:z$1.number(),results:z$1.array(lt)}),ue=z$1.object({status:z$1.number(),numResults:z$1.number(),results:z$1.array(J)}),ce=z$1.object({prompt:z$1.string().optional().nullable(),maxArticleCount:z$1.number().optional().nullable(),returnedArticleCount:z$1.number().optional().nullable(),summarizeFields:z$1.enum(["TITLE","CONTENT","SUMMARY"]).optional().nullable(),method:z$1.enum(["ARTICLES","CLUSTERS"]).optional().nullable(),model:z$1.enum(["gpt-5.4-mini","gpt-5.4-nano","gpt-5-mini","gpt-5-nano","gpt-4o","gpt-4o-mini","gpt-4.1","gpt-4.1-mini","llama-3.3-70b-versatile","openai/gpt-oss-120b"]).optional().nullable(),temperature:z$1.number().optional().nullable(),topP:z$1.number().optional().nullable(),maxTokens:z$1.number().optional().nullable()}),me=z$1.object({status:z$1.number(),numResults:z$1.number(),summary:z$1.string(),results:z$1.array(W)}),st=z$1.object({category:z$1.string().optional().nullable(),subcategory:z$1.string().optional().nullable()}),pt=z$1.object({id:z$1.number().optional().nullable(),createdAt:z$1.union([z$1.string().date(),z$1.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),updatedAt:z$1.union([z$1.string().date(),z$1.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),name:z$1.string().optional().nullable(),labels:st.optional().nullable()}),ye=z$1.object({total:z$1.number(),data:z$1.array(pt)}),he=z$1.object({name:z$1.string().optional().nullable(),displayName:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),people:z$1.array(te).optional().nullable(),companies:z$1.array(ee).optional().nullable(),visible:z$1.boolean().optional().nullable()}),ut=z$1.object({id:z$1.string().optional().nullable(),title:z$1.string().optional().nullable(),styleLevel:z$1.number().optional().nullable(),loc:z$1.array(z$1.number()).optional().nullable(),textRaw:z$1.string().optional().nullable(),textRich:z$1.string().optional().nullable()}),ct=z$1.object({id:z$1.string().optional().nullable(),scrapedAt:z$1.string().optional().nullable(),wikiPageId:z$1.number().optional().nullable(),wikiRevisionId:z$1.number().optional().nullable(),wikiRevisionTs:z$1.string().optional().nullable(),wikiCode:z$1.string().optional().nullable(),wikiNamespace:z$1.number().optional().nullable(),wikiTitle:z$1.string().optional().nullable(),url:z$1.string().optional().nullable(),topImage:z$1.string().optional().nullable(),wikidataId:z$1.string().optional().nullable(),wikidataInstanceOf:z$1.array(d).optional().nullable(),redirectTitles:z$1.array(z$1.string()).optional().nullable(),summary:z$1.string().optional().nullable(),sections:z$1.array(ut).optional().nullable(),categories:z$1.array(z$1.string()).optional().nullable(),externalLinks:z$1.array(z$1.string()).optional().nullable(),references:z$1.array(z$1.string()).optional().nullable(),pageviews:z$1.number().optional().nullable()}),mt=z$1.object({pageId:z$1.array(z$1.string()).optional().nullable(),sectionId:z$1.array(z$1.string()).optional().nullable(),wikiPageId:z$1.array(z$1.number()).optional().nullable(),wikiRevisionId:z$1.array(z$1.number()).optional().nullable(),wikiCode:z$1.array(z$1.string()).optional().nullable(),wikiNamespace:z$1.array(z$1.number()).optional().nullable(),wikidataId:z$1.array(z$1.string()).optional().nullable(),wikidataInstanceOfId:z$1.array(z$1.string()).optional().nullable(),wikidataInstanceOfLabel:z$1.array(z$1.string()).optional().nullable(),AND:z$1.array(z$1.unknown()).optional().nullable(),OR:z$1.array(z$1.unknown()).optional().nullable(),NOT:z$1.array(z$1.unknown()).optional().nullable()}),de=z$1.object({prompt:z$1.string(),filter:mt.optional().nullable(),wikiRevisionFrom:z$1.union([z$1.string().date(),z$1.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),wikiRevisionTo:z$1.union([z$1.string().date(),z$1.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),pageviewsFrom:z$1.number().optional().nullable(),pageviewsTo:z$1.number().optional().nullable(),size:z$1.number().optional().nullable(),page:z$1.number().optional().nullable()}),ge=z$1.object({status:z$1.number(),numResults:z$1.number(),results:z$1.array(ct)}),be=z$1.object({status:z$1.number(),results:z$1.array(rt)});var ht=z$1.object({createSourceGroupParams:Z}),dt=z$1.object({...ht.shape}),gt=z$1.object({createWatchlistParams:oe}),bt=z$1.object({...gt.shape}),St=z$1.object({id:z$1.number()}),ft=z$1.object({...St.shape}),xt=z$1.object({id:z$1.number()}),Rt=z$1.object({...xt.shape}),Tt=z$1.object({id:z$1.string()}),wt=z$1.object({...Tt.shape}),kt=z$1.object({id:z$1.number()}),Pt=z$1.object({...kt.shape}),fe=z$1.object({q:z$1.string().optional(),name:z$1.string().optional(),clusterId:z$1.array(z$1.string()).optional(),excludeClusterId:z$1.array(z$1.string()).optional(),sortBy:R.optional(),page:z$1.number().optional(),size:z$1.number().optional(),from:z$1.date().optional(),to:z$1.date().optional(),initializedFrom:z$1.date().optional(),initializedTo:z$1.date().optional(),updatedFrom:z$1.date().optional(),updatedTo:z$1.date().optional(),topic:z$1.array(z$1.string()).optional(),category:z$1.array(z$1.string()).optional(),taxonomy:z$1.array(z$1.string()).optional(),source:z$1.array(z$1.string()).optional(),sourceGroup:z$1.array(z$1.string()).optional(),minUniqueSources:z$1.number().optional(),personWikidataId:z$1.array(z$1.string()).optional(),personName:z$1.string().optional(),companyId:z$1.array(z$1.string()).optional(),companyName:z$1.string().optional(),companyDomain:z$1.array(z$1.string()).optional(),companySymbol:z$1.array(z$1.string()).optional(),country:z$1.array(z$1.string()).optional(),state:z$1.array(z$1.string()).optional(),city:z$1.array(z$1.string()).optional(),area:z$1.array(z$1.string()).optional(),minClusterSize:z$1.number().optional(),maxClusterSize:z$1.number().optional(),nameExists:z$1.boolean().optional(),positiveSentimentFrom:z$1.number().optional(),positiveSentimentTo:z$1.number().optional(),neutralSentimentFrom:z$1.number().optional(),neutralSentimentTo:z$1.number().optional(),negativeSentimentFrom:z$1.number().optional(),negativeSentimentTo:z$1.number().optional(),showStoryPageInfo:z$1.boolean().optional(),showNumResults:z$1.boolean().optional(),showDuplicates:z$1.boolean().optional(),showHighlighting:z$1.boolean().optional(),highlightFragmentSize:z$1.number().optional(),highlightNumFragments:z$1.number().optional(),highlightPreTag:z$1.string().optional(),highlightPostTag:z$1.string().optional(),highlightQ:z$1.string().optional(),expandArticles:z$1.boolean().optional(),splitBy:z$1.enum(["HOUR","DAY","WEEK","MONTH","NONE"])}),qt=z$1.object({...fe.shape}),xe=z$1.object({clusterId:z$1.array(z$1.string()).optional(),from:z$1.date().optional(),to:z$1.date().optional(),sortBy:z$1.enum(["createdAt","triggeredAt"]).optional(),page:z$1.number().optional(),size:z$1.number().optional(),changelogExists:z$1.boolean().optional()}),Ct=z$1.object({...xe.shape}),jt=z$1.object({id:z$1.number()}),At=z$1.object({...jt.shape}),Re=z$1.object({name:z$1.string().optional(),domain:z$1.string().optional(),page:z$1.string().optional(),size:z$1.string().optional(),sortBy:z$1.string(),sortOrder:z$1.string()}),It=z$1.object({...Re.shape}),Te=z$1.object({name:z$1.string().optional(),page:z$1.string().optional(),size:z$1.string().optional(),sortBy:z$1.string(),sortOrder:z$1.string()}),Ht=z$1.object({...Te.shape}),we=z$1.object({name:z$1.array(z$1.string()).optional()}),zt=z$1.object({...we.shape}),ke=z$1.object({name:z$1.array(z$1.string()).optional()}),vt=z$1.object({...ke.shape}),Pe=z$1.object({q:z$1.string().optional(),title:z$1.string().optional(),desc:z$1.string().optional(),content:z$1.string().optional(),summary:z$1.string().optional(),url:z$1.string().optional(),articleId:z$1.array(z$1.string()).optional(),clusterId:z$1.array(z$1.string()).optional(),sortBy:z.optional(),page:z$1.number().optional(),size:z$1.number().optional(),from:z$1.date().optional(),to:z$1.date().optional(),addDateFrom:z$1.date().optional(),addDateTo:z$1.date().optional(),refreshDateFrom:z$1.date().optional(),refreshDateTo:z$1.date().optional(),medium:z$1.array(z$1.string()).optional(),source:z$1.array(z$1.string()).optional(),sourceGroup:z$1.array(z$1.string()).optional(),excludeSourceGroup:z$1.array(z$1.string()).optional(),excludeSource:z$1.array(z$1.string()).optional(),watchlist:z$1.array(z$1.string()).optional(),excludeWatchlist:z$1.array(z$1.string()).optional(),paywall:z$1.boolean().optional(),byline:z$1.array(z$1.string()).optional(),author:z$1.array(z$1.string()).optional(),excludeAuthor:z$1.array(z$1.string()).optional(),journalistId:z$1.array(z$1.string()).optional(),excludeJournalistId:z$1.array(z$1.string()).optional(),language:z$1.array(z$1.string()).optional(),excludeLanguage:z$1.array(z$1.string()).optional(),searchTranslation:z$1.boolean().optional(),label:z$1.array(z$1.string()).optional(),excludeLabel:z$1.array(z$1.string()).optional(),category:z$1.array(z$1.string()).optional(),excludeCategory:z$1.array(z$1.string()).optional(),topic:z$1.array(z$1.string()).optional(),excludeTopic:z$1.array(z$1.string()).optional(),linkTo:z$1.string().optional(),showReprints:z$1.boolean().optional(),reprintGroupId:z$1.string().optional(),city:z$1.array(z$1.string()).optional(),excludeCity:z$1.array(z$1.string()).optional(),area:z$1.array(z$1.string()).optional(),state:z$1.array(z$1.string()).optional(),excludeState:z$1.array(z$1.string()).optional(),county:z$1.array(z$1.string()).optional(),excludeCounty:z$1.array(z$1.string()).optional(),locationsCountry:z$1.array(z$1.string()).optional(),country:z$1.array(z$1.string()).optional(),excludeLocationsCountry:z$1.array(z$1.string()).optional(),location:z$1.array(z$1.string()).optional(),lat:z$1.number().optional(),lon:z$1.number().optional(),maxDistance:z$1.number().optional(),sourceCity:z$1.array(z$1.string()).optional(),excludeSourceCity:z$1.array(z$1.string()).optional(),sourceCounty:z$1.array(z$1.string()).optional(),excludeSourceCounty:z$1.array(z$1.string()).optional(),sourceCountry:z$1.array(z$1.string()).optional(),excludeSourceCountry:z$1.array(z$1.string()).optional(),sourceState:z$1.array(z$1.string()).optional(),excludeSourceState:z$1.array(z$1.string()).optional(),sourceLat:z$1.number().optional(),sourceLon:z$1.number().optional(),sourceMaxDistance:z$1.number().optional(),personWikidataId:z$1.array(z$1.string()).optional(),excludePersonWikidataId:z$1.array(z$1.string()).optional(),personName:z$1.array(z$1.string()).optional(),excludePersonName:z$1.array(z$1.string()).optional(),companyId:z$1.array(z$1.string()).optional(),excludeCompanyId:z$1.array(z$1.string()).optional(),companyName:z$1.string().optional(),companyDomain:z$1.array(z$1.string()).optional(),excludeCompanyDomain:z$1.array(z$1.string()).optional(),companySymbol:z$1.array(z$1.string()).optional(),excludeCompanySymbol:z$1.array(z$1.string()).optional(),showNumResults:z$1.boolean().optional(),positiveSentimentFrom:z$1.number().optional(),positiveSentimentTo:z$1.number().optional(),neutralSentimentFrom:z$1.number().optional(),neutralSentimentTo:z$1.number().optional(),negativeSentimentFrom:z$1.number().optional(),negativeSentimentTo:z$1.number().optional(),taxonomy:z$1.array(z$1.string()).optional(),prefixTaxonomy:z$1.string().optional(),showHighlighting:z$1.boolean().optional(),highlightFragmentSize:z$1.number().optional(),highlightNumFragments:z$1.number().optional(),highlightPreTag:z$1.string().optional(),highlightPostTag:z$1.string().optional(),highlightQ:z$1.string().optional()}),Wt=z$1.object({...Pe.shape}),qe=z$1.object({id:z$1.array(z$1.string()).optional(),symbol:z$1.array(z$1.string()).optional(),domain:z$1.array(z$1.string()).optional(),country:z$1.array(z$1.string()).optional(),exchange:z$1.array(z$1.string()).optional(),numEmployeesFrom:z$1.number().optional(),numEmployeesTo:z$1.number().optional(),ipoFrom:z$1.date().optional(),ipoTo:z$1.date().optional(),q:z$1.string().optional(),name:z$1.string().optional(),industry:z$1.string().optional(),sector:z$1.string().optional(),size:z$1.number().optional(),page:z$1.number().optional()}),Gt=z$1.object({...qe.shape}),Ce=z$1.object({id:z$1.array(z$1.string()).optional(),q:z$1.string().optional(),name:z$1.string().optional(),twitter:z$1.string().optional(),size:z$1.number().optional(),page:z$1.number().optional(),source:z$1.array(z$1.string()).optional(),topic:z$1.array(z$1.string()).optional(),category:z$1.array(z$1.string()).optional(),label:z$1.array(z$1.string()).optional(),minMonthlyPosts:z$1.number().optional(),maxMonthlyPosts:z$1.number().optional(),country:z$1.array(z$1.string()).optional(),updatedAtFrom:z$1.date().optional(),updatedAtTo:z$1.date().optional(),showNumResults:z$1.boolean().optional()}),Dt=z$1.object({...Ce.shape}),je=z$1.object({name:z$1.string().optional(),wikidataId:z$1.array(z$1.string()).optional(),occupationId:z$1.array(z$1.string()).optional(),occupationLabel:z$1.string().optional(),page:z$1.number().optional(),size:z$1.number().optional()}),Bt=z$1.object({...je.shape}),Ae=z$1.object({domain:z$1.array(z$1.string()).optional(),name:z$1.string().optional(),sourceGroup:z$1.string().optional(),sortBy:R.optional(),page:z$1.number().optional(),size:z$1.number().optional(),minMonthlyVisits:z$1.number().optional(),maxMonthlyVisits:z$1.number().optional(),minMonthlyPosts:z$1.number().optional(),maxMonthlyPosts:z$1.number().optional(),country:z$1.array(z$1.string()).optional(),sourceCountry:z$1.array(z$1.string()).optional(),sourceState:z$1.array(z$1.string()).optional(),sourceCounty:z$1.array(z$1.string()).optional(),sourceCity:z$1.array(z$1.string()).optional(),sourceLat:z$1.number().optional(),sourceLon:z$1.number().optional(),sourceMaxDistance:z$1.number().optional(),category:z$1.array(z$1.string()).optional(),topic:z$1.array(z$1.string()).optional(),label:z$1.array(z$1.string()).optional(),paywall:z$1.boolean().optional(),showSubdomains:z$1.boolean().optional(),showNumResults:z$1.boolean().optional()}),Ft=z$1.object({...Ae.shape}),Ie=z$1.object({q:z$1.string().optional(),name:z$1.string().optional(),clusterId:z$1.array(z$1.string()).optional(),excludeClusterId:z$1.array(z$1.string()).optional(),sortBy:R.optional(),page:z$1.number().optional(),size:z$1.number().optional(),from:z$1.date().optional(),to:z$1.date().optional(),initializedFrom:z$1.date().optional(),initializedTo:z$1.date().optional(),updatedFrom:z$1.date().optional(),updatedTo:z$1.date().optional(),topic:z$1.array(z$1.string()).optional(),category:z$1.array(z$1.string()).optional(),taxonomy:z$1.array(z$1.string()).optional(),source:z$1.array(z$1.string()).optional(),sourceGroup:z$1.array(z$1.string()).optional(),minUniqueSources:z$1.number().optional(),personWikidataId:z$1.array(z$1.string()).optional(),personName:z$1.string().optional(),companyId:z$1.array(z$1.string()).optional(),companyName:z$1.string().optional(),companyDomain:z$1.array(z$1.string()).optional(),companySymbol:z$1.array(z$1.string()).optional(),country:z$1.array(z$1.string()).optional(),state:z$1.array(z$1.string()).optional(),city:z$1.array(z$1.string()).optional(),area:z$1.array(z$1.string()).optional(),minClusterSize:z$1.number().optional(),maxClusterSize:z$1.number().optional(),nameExists:z$1.boolean().optional(),positiveSentimentFrom:z$1.number().optional(),positiveSentimentTo:z$1.number().optional(),neutralSentimentFrom:z$1.number().optional(),neutralSentimentTo:z$1.number().optional(),negativeSentimentFrom:z$1.number().optional(),negativeSentimentTo:z$1.number().optional(),showStoryPageInfo:z$1.boolean().optional(),showNumResults:z$1.boolean().optional(),showDuplicates:z$1.boolean().optional(),showHighlighting:z$1.boolean().optional(),highlightFragmentSize:z$1.number().optional(),highlightNumFragments:z$1.number().optional(),highlightPreTag:z$1.string().optional(),highlightPostTag:z$1.string().optional(),highlightQ:z$1.string().optional(),expandArticles:z$1.boolean().optional()}),Et=z$1.object({...Ie.shape}),He=z$1.object({q:z$1.string().optional(),title:z$1.string().optional(),desc:z$1.string().optional(),content:z$1.string().optional(),summary:z$1.string().optional(),url:z$1.string().optional(),articleId:z$1.array(z$1.string()).optional(),clusterId:z$1.array(z$1.string()).optional(),sortBy:z.optional(),page:z$1.number().optional(),size:z$1.number().optional(),from:z$1.date().optional(),to:z$1.date().optional(),addDateFrom:z$1.date().optional(),addDateTo:z$1.date().optional(),refreshDateFrom:z$1.date().optional(),refreshDateTo:z$1.date().optional(),medium:z$1.array(z$1.string()).optional(),source:z$1.array(z$1.string()).optional(),sourceGroup:z$1.array(z$1.string()).optional(),excludeSourceGroup:z$1.array(z$1.string()).optional(),excludeSource:z$1.array(z$1.string()).optional(),watchlist:z$1.array(z$1.string()).optional(),excludeWatchlist:z$1.array(z$1.string()).optional(),paywall:z$1.boolean().optional(),byline:z$1.array(z$1.string()).optional(),author:z$1.array(z$1.string()).optional(),excludeAuthor:z$1.array(z$1.string()).optional(),journalistId:z$1.array(z$1.string()).optional(),excludeJournalistId:z$1.array(z$1.string()).optional(),language:z$1.array(z$1.string()).optional(),excludeLanguage:z$1.array(z$1.string()).optional(),searchTranslation:z$1.boolean().optional(),label:z$1.array(z$1.string()).optional(),excludeLabel:z$1.array(z$1.string()).optional(),category:z$1.array(z$1.string()).optional(),excludeCategory:z$1.array(z$1.string()).optional(),topic:z$1.array(z$1.string()).optional(),excludeTopic:z$1.array(z$1.string()).optional(),linkTo:z$1.string().optional(),showReprints:z$1.boolean().optional(),reprintGroupId:z$1.string().optional(),city:z$1.array(z$1.string()).optional(),excludeCity:z$1.array(z$1.string()).optional(),area:z$1.array(z$1.string()).optional(),state:z$1.array(z$1.string()).optional(),excludeState:z$1.array(z$1.string()).optional(),county:z$1.array(z$1.string()).optional(),excludeCounty:z$1.array(z$1.string()).optional(),locationsCountry:z$1.array(z$1.string()).optional(),country:z$1.array(z$1.string()).optional(),excludeLocationsCountry:z$1.array(z$1.string()).optional(),location:z$1.array(z$1.string()).optional(),lat:z$1.number().optional(),lon:z$1.number().optional(),maxDistance:z$1.number().optional(),sourceCity:z$1.array(z$1.string()).optional(),excludeSourceCity:z$1.array(z$1.string()).optional(),sourceCounty:z$1.array(z$1.string()).optional(),excludeSourceCounty:z$1.array(z$1.string()).optional(),sourceCountry:z$1.array(z$1.string()).optional(),excludeSourceCountry:z$1.array(z$1.string()).optional(),sourceState:z$1.array(z$1.string()).optional(),excludeSourceState:z$1.array(z$1.string()).optional(),sourceLat:z$1.number().optional(),sourceLon:z$1.number().optional(),sourceMaxDistance:z$1.number().optional(),personWikidataId:z$1.array(z$1.string()).optional(),excludePersonWikidataId:z$1.array(z$1.string()).optional(),personName:z$1.array(z$1.string()).optional(),excludePersonName:z$1.array(z$1.string()).optional(),companyId:z$1.array(z$1.string()).optional(),excludeCompanyId:z$1.array(z$1.string()).optional(),companyName:z$1.string().optional(),companyDomain:z$1.array(z$1.string()).optional(),excludeCompanyDomain:z$1.array(z$1.string()).optional(),companySymbol:z$1.array(z$1.string()).optional(),excludeCompanySymbol:z$1.array(z$1.string()).optional(),showNumResults:z$1.boolean().optional(),positiveSentimentFrom:z$1.number().optional(),positiveSentimentTo:z$1.number().optional(),neutralSentimentFrom:z$1.number().optional(),neutralSentimentTo:z$1.number().optional(),negativeSentimentFrom:z$1.number().optional(),negativeSentimentTo:z$1.number().optional(),taxonomy:z$1.array(z$1.string()).optional(),prefixTaxonomy:z$1.string().optional(),showHighlighting:z$1.boolean().optional(),highlightFragmentSize:z$1.number().optional(),highlightNumFragments:z$1.number().optional(),highlightPreTag:z$1.string().optional(),highlightPostTag:z$1.string().optional(),highlightQ:z$1.string().optional()}),Ot=z$1.object({summaryBody:ce}),Lt=z$1.object({...He.shape,...Ot.shape}),ze=z$1.object({name:z$1.string().optional(),category:z$1.string().optional(),subcategory:z$1.string().optional(),page:z$1.number().optional(),size:z$1.number().optional()}),Nt=z$1.object({...ze.shape}),ve=z$1.object({q:z$1.string().optional(),title:z$1.string().optional(),summary:z$1.string().optional(),text:z$1.string().optional(),reference:z$1.string().optional(),id:z$1.array(z$1.string()).optional(),wikiPageId:z$1.array(z$1.number()).optional(),wikiRevisionId:z$1.array(z$1.number()).optional(),wikiCode:z$1.array(z$1.string()).optional(),wikiNamespace:z$1.array(z$1.number()).optional(),wikidataId:z$1.array(z$1.string()).optional(),wikidataInstanceOfId:z$1.array(z$1.string()).optional(),wikidataInstanceOfLabel:z$1.array(z$1.string()).optional(),category:z$1.array(z$1.string()).optional(),sectionId:z$1.array(z$1.string()).optional(),wikiRevisionFrom:z$1.date().optional(),wikiRevisionTo:z$1.date().optional(),scrapedAtFrom:z$1.date().optional(),scrapedAtTo:z$1.date().optional(),pageviewsFrom:z$1.number().optional(),pageviewsTo:z$1.number().optional(),withPageviews:z$1.boolean().optional(),showNumResults:z$1.boolean().optional(),page:z$1.number().optional(),size:z$1.number().optional(),sortBy:z$1.enum(["relevance","revisionTsDesc","revisionTsAsc","pageViewsDesc","pageViewsAsc","scrapedAtDesc","scrapedAtAsc"]).optional()}),Ut=z$1.object({...ve.shape}),Mt=z$1.object({patchSourceGroupParams:ne}),$t=z$1.object({id:z$1.number()}),Kt=z$1.object({...Mt.shape,...$t.shape}),Qt=z$1.object({updateWatchlistParams:he}),Vt=z$1.object({id:z$1.number()}),Jt=z$1.object({...Qt.shape,...Vt.shape}),Yt=z$1.object({articleSearchParams:Y}),_t=z$1.object({...Yt.shape}),Xt=z$1.object({wikipediaSearchParams:de}),Zt=z$1.object({...Xt.shape}),Se=class extends g{async createSourceGroup(o,a){let i=dt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups",method:"POST",headers:r,body:i.createSourceGroupParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async createWatchlist(o,a){let i=bt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists",method:"POST",headers:r,body:i.createWatchlistParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async deleteSourceGroup(o,a){let i=ft.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"DELETE",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async deleteWatchlist(o,a){let i=Rt.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"DELETE",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async getJournalistById(o,a){let i=wt.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let p=await(await this.request({path:"/v1/journalists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"GET",headers:r},a)).json();return T.parse(p)}async getSourceGroup(o,a){let i=Pt.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"GET",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async getStoryCounts(o,a){let i=qt.parse(o),r=fe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/stories/stats",method:"GET",headers:n,query:r},a)).json();return se.parse(s)}async getStoryHistory(o={},a){let i=Ct.parse(o),r=xe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/stories/history",method:"GET",headers:n,query:r},a)).json();return pe.parse(s)}async getWatchlist(o,a){let i=At.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"GET",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async listSourceGroups(o,a){let i=It.parse(o),r=Re.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/sourceGroups",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async listWatchlists(o,a){let i=Ht.parse(o),r=Te.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/watchlists",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async resolveSourceGroups(o={},a){let i=zt.parse(o),r=we.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/sourceGroups/resolve",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async resolveWatchlists(o={},a){let i=vt.parse(o),r=ke.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/watchlists/resolve",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async searchArticles(o={},a){let i=Wt.parse(o),r=Pe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/articles/all",method:"GET",headers:n,query:r},a)).json();return ie.parse(s)}async searchCompanies(o={},a){let i=Gt.parse(o),r=qe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/companies/all",method:"GET",headers:n,query:r},a)).json();return X.parse(s)}async searchJournalists(o={},a){let i=Dt.parse(o),r=Ce.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/journalists/all",method:"GET",headers:n,query:r},a)).json();return ae.parse(s)}async searchPeople(o={},a){let i=Bt.parse(o),r=je.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/people/all",method:"GET",headers:n,query:r},a)).json();return re.parse(s)}async searchSources(o={},a){let i=Ft.parse(o),r=Ae.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/sources/all",method:"GET",headers:n,query:r},a)).json();return le.parse(s)}async searchStories(o={},a){let i=Et.parse(o),r=Ie.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/stories/all",method:"GET",headers:n,query:r},a)).json();return ue.parse(s)}async searchSummarizer(o,a){let i=Lt.parse(o),r=He.parse(i),n={};if(n["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/summarize",method:"POST",headers:n,query:r,body:i.summaryBody},a)).json();return me.parse(s)}async searchTopics(o={},a){let i=Nt.parse(o),r=ze.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/topics/all",method:"GET",headers:n,query:r},a)).json();return ye.parse(s)}async searchWikipedia(o={},a){let i=Ut.parse(o),r=ve.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/wikipedia/all",method:"GET",headers:n,query:r},a)).json();return ge.parse(s)}async updateSourceGroup(o,a){let i=Kt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"PATCH",headers:r,body:i.patchSourceGroupParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async updateWatchlist(o,a){let i=Jt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"PATCH",headers:r,body:i.updateWatchlistParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async vectorSearchArticles(o,a){let i=_t.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let p=await(await this.request({path:"/v1/vector/news/all",method:"POST",headers:r,body:i.articleSearchParams},a)).json();return _.parse(p)}async vectorSearchWikipedia(o,a){let i=Zt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let p=await(await this.request({path:"/v1/vector/wikipedia/all",method:"POST",headers:r,body:i.wikipediaSearchParams},a)).json();return be.parse(p)}},so={Hour:"HOUR",Day:"DAY",Week:"WEEK",Month:"MONTH",None:"NONE"},po={CreatedAt:"createdAt",TriggeredAt:"triggeredAt"},uo={Relevance:"relevance",RevisionTsDesc:"revisionTsDesc",RevisionTsAsc:"revisionTsAsc",PageViewsDesc:"pageViewsDesc",PageViewsAsc:"pageViewsAsc",ScrapedAtDesc:"scrapedAtDesc",ScrapedAtAsc:"scrapedAtAsc"};
|
|
1
|
+
import {z as z$1}from'zod';var We="https://api.perigon.io".replace(/\/+$/,""),w=class{constructor(o={}){this.configuration=o;}set config(o){this.configuration=o;}get basePath(){return We}get fetchApi(){return this.configuration.fetchApi}get middleware(){return this.configuration.middleware||[]}get queryParamsStringify(){return this.configuration.queryParamsStringify||B}get accessToken(){let o=this.configuration.apiKey;return o?typeof o=="function"?o:async()=>o:void 0}get headers(){return this.configuration.headers}get credentials(){return this.configuration.credentials}},Ge=new w,k=class extends Error{constructor(a,i){super(i);this.cause=a;this.name="FetchError";}},m=class extends Error{constructor(o,a){let i=`HTTP ${o.status}: ${o.statusText}`;super(i),this.name="HttpError",this.status=o.status,this.statusText=o.statusText,this.response=o,this.body=a;}},P=class extends m{constructor(o,a){super(o,a),this.name="BadRequestError",this.message=a?.message||"Bad request - please check your input parameters";}},q=class extends m{constructor(o,a){super(o,a),this.name="UnauthorizedError",this.message="Authentication required - please check your credentials";}},C=class extends m{constructor(o,a){super(o,a),this.name="ForbiddenError",this.message="Access denied - insufficient permissions";}},j=class extends m{constructor(o,a){super(o,a),this.name="NotFoundError",this.message=a?.message||"Resource not found";}},A=class extends m{constructor(o,a){super(o,a),this.name="RateLimitError",this.message="Rate limit exceeded - please try again later";let i=o.headers.get("retry-after");i&&(this.retryAfter=parseInt(i,10));}},I=class extends m{constructor(o,a){super(o,a),this.name="ServerError",this.message="Server error - please try again later";}},D=class extends Error{constructor(o){super("Network error - please check your connection"),this.name="NetworkError",this.cause=o;}};function De(u,o){return u.status===400?new P(u,o):u.status===401?new q(u,o):u.status===403?new C(u,o):u.status===404?new j(u,o):u.status===429?new A(u,o):u.status>499?new I(u,o):new m(u,o)}var b=class b{constructor(o=Ge){this.configuration=o;this.fetchApi=async(o,a)=>{let i={url:o,init:a};for(let n of this.middleware)n.pre&&(i=await n.pre({fetch:this.fetchApi,...i})||i);let r;try{r=await(this.configuration.fetchApi||fetch)(i.url,i.init);}catch(n){for(let p of this.middleware)p.onError&&(r=await p.onError({fetch:this.fetchApi,url:i.url,init:i.init,error:n,response:r?r.clone():void 0})||r);if(r===void 0)throw n instanceof Error?new k(n,"The request failed and the interceptors did not return an alternative response"):n}for(let n of this.middleware)n.post&&(r=await n.post({fetch:this.fetchApi,url:i.url,init:i.init,response:r.clone()})||r);return r};this.middleware=o.middleware;}withMiddleware(...o){let a=this.clone();return a.middleware=a.middleware.concat(...o),a}withPreMiddleware(...o){let a=o.map(i=>({pre:i}));return this.withMiddleware(...a)}withPostMiddleware(...o){let a=o.map(i=>({post:i}));return this.withMiddleware(...a)}isJsonMime(o){return o?b.jsonRegex.test(o):false}async request(o,a){let{url:i,init:r}=await this.createFetchParams(o,a),n=await this.fetchApi(i,r);if(n&&n.status>=200&&n.status<300)return n;let p;try{n.headers.get("content-type")?.includes("application/json")&&(p=await n.json());}catch{}throw De(n,p)}async createFetchParams(o,a){let i=this.configuration.basePath+o.path;o.query!==void 0&&Object.keys(o.query).length!==0&&(i+="?"+this.configuration.queryParamsStringify(o.query));let r=Object.assign({},this.configuration.headers,o.headers);Object.keys(r).forEach(G=>r[G]===void 0?delete r[G]:{});let n=typeof a=="function"?a:async()=>a,p={method:o.method,headers:r,body:o.body,credentials:this.configuration.credentials},s={...p,...await n({init:p,context:o})},l;Fe(s.body)||s.body instanceof URLSearchParams||Be(s.body)?l=s.body:this.isJsonMime(r["Content-Type"])?l=JSON.stringify(s.body):l=s.body;let c={...s,body:l};return {url:i,init:c}}clone(){let o=this.constructor,a=new o(this.configuration);return a.middleware=this.middleware.slice(),a}};b.jsonRegex=new RegExp("^(:?application/json|[^;/ ]+/[^;/ ]+[+]json)[ ]*(:?;.*)?$","i");var g=b;function Be(u){return typeof Blob<"u"&&u instanceof Blob}function Fe(u){return typeof FormData<"u"&&u instanceof FormData}var eo={csv:",",ssv:" ",tsv:" ",pipes:"|"};function B(u,o=""){return Object.keys(u).map(a=>F(a,u[a],o)).filter(a=>a.length>0).join("&")}function F(u,o,a=""){let i=a+(a.length?`[${u}]`:u);if(o instanceof Array){let r=o.map(n=>encodeURIComponent(String(n))).join(`&${encodeURIComponent(i)}=`);return `${encodeURIComponent(i)}=${r}`}if(o instanceof Set){let r=Array.from(o);return F(u,r,a)}return o instanceof Date?`${encodeURIComponent(i)}=${encodeURIComponent(o.toISOString())}`:o instanceof Object?B(o,i):`${encodeURIComponent(i)}=${encodeURIComponent(String(o))}`}function to(u,o){let a=u[o];return a!=null}var R=z$1.enum(["createdAt","updatedAt","relevance","count","totalCount"]),ao={CreatedAt:"createdAt",UpdatedAt:"updatedAt",Relevance:"relevance",Count:"count",TotalCount:"totalCount"},z=z$1.enum(["relevance","date","reverseDate","reverseAddDate","addDate","pubDate","refreshDate"]),no={Relevance:"relevance",Date:"date",ReverseDate:"reverseDate",ReverseAddDate:"reverseAddDate",AddDate:"addDate",PubDate:"pubDate",RefreshDate:"refreshDate"},H=z$1.object({name:z$1.string().optional().nullable()}),Oe=z$1.object({name:z$1.string().optional().nullable(),score:z$1.number().optional().nullable()}),O=z$1.object({id:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),domains:z$1.array(z$1.string()).optional().nullable(),symbols:z$1.array(z$1.string()).optional().nullable()}),Le=z$1.object({data:z$1.string().optional().nullable(),type:z$1.string().optional().nullable(),mentions:z$1.number().optional().nullable()}),Ne=z$1.object({name:z$1.string().optional().nullable(),type:z$1.string().optional().nullable()}),Ue=z$1.object({id:z$1.string().optional().nullable(),name:z$1.string().optional().nullable()}),v=z$1.object({country:z$1.string().optional().nullable(),state:z$1.string().optional().nullable(),county:z$1.string().optional().nullable(),city:z$1.string().optional().nullable(),area:z$1.string().optional().nullable()}),h=z$1.object({name:z$1.string().optional().nullable(),count:z$1.number().optional().nullable()}),T=z$1.object({id:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),fullName:z$1.string().optional().nullable(),headline:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),title:z$1.string().optional().nullable(),locations:z$1.array(v).optional().nullable(),updatedAt:z$1.string().optional().nullable(),topTopics:z$1.array(h).optional().nullable(),topSources:z$1.array(h).optional().nullable(),topCategories:z$1.array(h).optional().nullable(),topLabels:z$1.array(h).optional().nullable(),topCountries:z$1.array(h).optional().nullable(),avgMonthlyPosts:z$1.number().optional().nullable(),twitterHandle:z$1.string().optional().nullable(),twitterBio:z$1.string().optional().nullable(),imageUrl:z$1.string().optional().nullable(),linkedinUrl:z$1.string().optional().nullable(),linkedinConnections:z$1.number().optional().nullable(),linkedinFollowers:z$1.number().optional().nullable(),facebookUrl:z$1.string().optional().nullable(),instagramUrl:z$1.string().optional().nullable(),websiteUrl:z$1.string().optional().nullable(),blogUrl:z$1.string().optional().nullable(),tumblrUrl:z$1.string().optional().nullable(),youtubeUrl:z$1.string().optional().nullable()}),Me=z$1.object({name:z$1.string().optional().nullable(),weight:z$1.number().optional().nullable()}),$e=z$1.object({name:z$1.string().optional().nullable()}),Ke=z$1.object({id:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),domains:z$1.array(z$1.string()).optional().nullable(),symbols:z$1.array(z$1.string()).optional().nullable(),count:z$1.number().optional().nullable()}),L=z$1.object({point:z$1.string().optional().nullable(),references:z$1.array(z$1.string()).optional().nullable()}),Qe=z$1.object({country:z$1.string().optional().nullable(),state:z$1.string().optional().nullable(),county:z$1.string().optional().nullable(),city:z$1.string().optional().nullable(),area:z$1.string().optional().nullable(),count:z$1.number().optional().nullable()}),Ve=z$1.object({wikidataId:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),count:z$1.number().optional().nullable()}),N=z$1.object({wikidataId:z$1.string().optional().nullable(),name:z$1.string().optional().nullable()}),U=z$1.object({question:z$1.string().optional().nullable(),answer:z$1.string().optional().nullable(),references:z$1.array(z$1.string()).optional().nullable()}),S=z$1.object({name:z$1.string().optional().nullable(),count:z$1.number().optional().nullable()}),M=z$1.object({positive:z$1.number().optional().nullable(),negative:z$1.number().optional().nullable(),neutral:z$1.number().optional().nullable()}),$=z$1.object({lat:z$1.number().optional().nullable(),lon:z$1.number().optional().nullable()}),K=z$1.object({country:z$1.string().optional().nullable(),state:z$1.string().optional().nullable(),county:z$1.string().optional().nullable(),city:z$1.string().optional().nullable(),coordinates:$.optional().nullable()}),Q=z$1.object({domain:z$1.string().optional().nullable(),paywall:z$1.boolean().optional().nullable(),location:K.optional().nullable()}),V=z$1.object({name:z$1.string().optional().nullable()}),J=z$1.object({createdAt:z$1.string().optional().nullable(),updatedAt:z$1.string().optional().nullable(),initializedAt:z$1.string().optional().nullable(),id:z$1.string().optional().nullable(),duplicateOf:z$1.string().optional().nullable(),slug:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),summary:z$1.string().optional().nullable(),shortSummary:z$1.string().optional().nullable(),summaryReferences:z$1.array(z$1.string()).optional().nullable(),imageSource:Q.optional().nullable(),imageUrl:z$1.string().optional().nullable(),keyPoints:z$1.array(L).optional().nullable(),questions:z$1.array(U).optional().nullable(),uniqueSources:z$1.array(z$1.string()).optional().nullable(),selectedArticles:z$1.array(z$1.unknown()).optional().nullable(),sentiment:M.optional().nullable(),uniqueCount:z$1.number().optional().nullable(),reprintCount:z$1.number().optional().nullable(),totalCount:z$1.number().optional().nullable(),countries:z$1.array(S).optional().nullable(),topCountries:z$1.array(z$1.string()).optional().nullable(),topics:z$1.array(S).optional().nullable(),topTopics:z$1.array(V).optional().nullable(),categories:z$1.array(S).optional().nullable(),topCategories:z$1.array(H).optional().nullable(),taxonomies:z$1.array(S).optional().nullable(),topTaxonomies:z$1.array(H).optional().nullable(),people:z$1.array(Ve).optional().nullable(),topPeople:z$1.array(N).optional().nullable(),companies:z$1.array(Ke).optional().nullable(),topCompanies:z$1.array(O).optional().nullable(),locations:z$1.array(Qe).optional().nullable(),topLocations:z$1.array(v).optional().nullable(),highlights:z$1.record(z$1.string(),z$1.array(z$1.string())).optional().nullable(),sourceDiversity:z$1.number().optional().nullable()}),Je=z$1.object({osmId:z$1.string().optional().nullable(),road:z$1.string().optional().nullable(),quarter:z$1.string().optional().nullable(),suburb:z$1.string().optional().nullable(),city:z$1.string().optional().nullable(),town:z$1.string().optional().nullable(),county:z$1.string().optional().nullable(),stateDistrict:z$1.string().optional().nullable(),state:z$1.string().optional().nullable(),postcode:z$1.string().optional().nullable(),country:z$1.string().optional().nullable(),countryCode:z$1.string().optional().nullable(),amenity:z$1.string().optional().nullable(),neighbourhood:z$1.string().optional().nullable(),coordinates:$.optional().nullable()}),W=z$1.object({url:z$1.string().optional().nullable(),authorsByline:z$1.string().optional().nullable(),articleId:z$1.string().optional().nullable(),clusterId:z$1.string().optional().nullable(),source:Q.optional().nullable(),imageUrl:z$1.string().optional().nullable(),country:z$1.string().optional().nullable(),language:z$1.string().optional().nullable(),pubDate:z$1.string().optional().nullable(),addDate:z$1.string().optional().nullable(),refreshDate:z$1.string().optional().nullable(),score:z$1.number().optional().nullable(),title:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),content:z$1.string().optional().nullable(),enContentWordCount:z$1.number().optional().nullable(),medium:z$1.string().optional().nullable(),links:z$1.array(z$1.string()).optional().nullable(),labels:z$1.array($e).optional().nullable(),eventTypes:z$1.array(Ne).optional().nullable(),matchedAuthors:z$1.array(Ue).optional().nullable(),claim:z$1.string().optional().nullable(),verdict:z$1.string().optional().nullable(),keywords:z$1.array(Me).optional().nullable(),topics:z$1.array(V).optional().nullable(),categories:z$1.array(H).optional().nullable(),taxonomies:z$1.array(Oe).optional().nullable(),entities:z$1.array(Le).optional().nullable(),companies:z$1.array(O).optional().nullable(),sentiment:M.optional().nullable(),summary:z$1.string().optional().nullable(),shortSummary:z$1.string().optional().nullable(),translation:z$1.string().optional().nullable(),translatedTitle:z$1.string().optional().nullable(),translatedDescription:z$1.string().optional().nullable(),translatedSummary:z$1.string().optional().nullable(),locations:z$1.array(v).optional().nullable(),reprint:z$1.boolean().optional().nullable(),reprintGroupId:z$1.string().optional().nullable(),places:z$1.array(Je).optional().nullable(),people:z$1.array(N).optional().nullable(),cluster:J.optional().nullable(),journalists:z$1.array(T).optional().nullable(),highlights:z$1.record(z$1.string(),z$1.array(z$1.string())).optional().nullable()}),E=z$1.object({lat:z$1.number().optional().nullable(),lon:z$1.number().optional().nullable(),radius:z$1.number().optional().nullable()}),Ye=z$1.object({articleId:z$1.array(z$1.string()).optional().nullable(),clusterId:z$1.array(z$1.string()).optional().nullable(),source:z$1.array(z$1.string()).optional().nullable(),excludeSource:z$1.array(z$1.string()).optional().nullable(),sourceGroup:z$1.array(z$1.string()).optional().nullable(),language:z$1.array(z$1.string()).optional().nullable(),excludeLanguage:z$1.array(z$1.string()).optional().nullable(),label:z$1.array(z$1.string()).optional().nullable(),excludeLabel:z$1.array(z$1.string()).optional().nullable(),taxonomy:z$1.array(z$1.string()).optional().nullable(),category:z$1.array(z$1.string()).optional().nullable(),topic:z$1.array(z$1.string()).optional().nullable(),excludeTopic:z$1.array(z$1.string()).optional().nullable(),country:z$1.array(z$1.string()).optional().nullable(),excludeCountry:z$1.array(z$1.string()).optional().nullable(),locationsCountry:z$1.array(z$1.string()).optional().nullable(),excludeLocationsCountry:z$1.array(z$1.string()).optional().nullable(),state:z$1.array(z$1.string()).optional().nullable(),excludeState:z$1.array(z$1.string()).optional().nullable(),county:z$1.array(z$1.string()).optional().nullable(),excludeCounty:z$1.array(z$1.string()).optional().nullable(),city:z$1.array(z$1.string()).optional().nullable(),excludeCity:z$1.array(z$1.string()).optional().nullable(),sourceCountry:z$1.array(z$1.string()).optional().nullable(),sourceState:z$1.array(z$1.string()).optional().nullable(),sourceCounty:z$1.array(z$1.string()).optional().nullable(),sourceCity:z$1.array(z$1.string()).optional().nullable(),coordinates:E.optional().nullable(),sourceCoordinates:E.optional().nullable(),companyId:z$1.array(z$1.string()).optional().nullable(),excludeCompanyId:z$1.array(z$1.string()).optional().nullable(),companyDomain:z$1.array(z$1.string()).optional().nullable(),excludeCompanyDomain:z$1.array(z$1.string()).optional().nullable(),companySymbol:z$1.array(z$1.string()).optional().nullable(),excludeCompanySymbol:z$1.array(z$1.string()).optional().nullable(),companyName:z$1.array(z$1.string()).optional().nullable(),personWikidataId:z$1.array(z$1.string()).optional().nullable(),excludePersonWikidataId:z$1.array(z$1.string()).optional().nullable(),personName:z$1.array(z$1.string()).optional().nullable(),excludePersonName:z$1.array(z$1.string()).optional().nullable(),AND:z$1.array(z$1.unknown()).optional().nullable(),OR:z$1.array(z$1.unknown()).optional().nullable(),NOT:z$1.array(z$1.unknown()).optional().nullable()}),Y=z$1.object({prompt:z$1.string(),filter:Ye.optional().nullable(),pubDateFrom:z$1.union([z$1.string().date(),z$1.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),pubDateTo:z$1.union([z$1.string().date(),z$1.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),showReprints:z$1.boolean().optional().nullable(),size:z$1.number().optional().nullable(),page:z$1.number().optional().nullable()}),_e=z$1.object({score:z$1.number().optional().nullable(),data:W.optional().nullable()}),_=z$1.object({status:z$1.number(),results:z$1.array(_e)}),Xe=z$1.object({symbol:z$1.string().optional().nullable(),exchange:z$1.string().optional().nullable(),exchangeShortName:z$1.string().optional().nullable(),ipoDate:z$1.string().optional().nullable()}),Ze=z$1.object({careers:z$1.string().optional().nullable(),about:z$1.string().optional().nullable(),blog:z$1.string().optional().nullable(),events:z$1.string().optional().nullable(),sitemap:z$1.string().optional().nullable(),updates:z$1.string().optional().nullable(),linkedin:z$1.string().optional().nullable(),facebook:z$1.string().optional().nullable(),instagram:z$1.string().optional().nullable(),medium:z$1.string().optional().nullable(),reddit:z$1.string().optional().nullable(),threads:z$1.string().optional().nullable(),tiktok:z$1.string().optional().nullable(),x:z$1.string().optional().nullable(),wellfound:z$1.string().optional().nullable(),youtube:z$1.string().optional().nullable(),wikipedia:z$1.string().optional().nullable()}),et=z$1.object({id:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),updatedAt:z$1.string().optional().nullable(),primaryRecordId:z$1.string().optional().nullable(),altNames:z$1.array(z$1.string()).optional().nullable(),domains:z$1.array(z$1.string()).optional().nullable(),monthlyVisits:z$1.number().optional().nullable(),globalRank:z$1.number().optional().nullable(),description:z$1.string().optional().nullable(),ceo:z$1.string().optional().nullable(),industry:z$1.string().optional().nullable(),sector:z$1.string().optional().nullable(),country:z$1.string().optional().nullable(),fullTimeEmployees:z$1.number().optional().nullable(),address:z$1.string().optional().nullable(),city:z$1.string().optional().nullable(),state:z$1.string().optional().nullable(),zip:z$1.string().optional().nullable(),logo:z$1.string().optional().nullable(),favicon:z$1.string().optional().nullable(),isEtf:z$1.boolean().optional().nullable(),isActivelyTrading:z$1.boolean().optional().nullable(),isFund:z$1.boolean().optional().nullable(),isAdr:z$1.boolean().optional().nullable(),symbols:z$1.array(Xe).optional().nullable(),naics:z$1.string().optional().nullable(),sic:z$1.string().optional().nullable(),cusip:z$1.string().optional().nullable(),cik:z$1.string().optional().nullable(),isin:z$1.string().optional().nullable(),yearFounded:z$1.number().optional().nullable(),revenue:z$1.string().optional().nullable(),webResources:Ze.optional().nullable()}),X=z$1.object({status:z$1.number(),numResults:z$1.number(),results:z$1.array(et)}),Z=z$1.object({name:z$1.string(),displayName:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),domains:z$1.array(z$1.string())}),x=z$1.object({url:z$1.string().optional().nullable()}),y=z$1.object({time:z$1.string().optional().nullable(),precision:z$1.string().optional().nullable()}),d=z$1.object({wikidataId:z$1.string().optional().nullable(),label:z$1.string().optional().nullable()}),tt=z$1.object({wikidataId:z$1.string().optional().nullable(),label:z$1.string().optional().nullable(),startTime:y.optional().nullable(),endTime:y.optional().nullable()}),ot=z$1.object({wikidataId:z$1.string().optional().nullable(),label:z$1.string().optional().nullable(),startTime:y.optional().nullable(),endTime:y.optional().nullable(),employer:d.optional().nullable()}),at=z$1.object({wikidataId:z$1.string().optional().nullable(),createdAt:z$1.string().optional().nullable(),updatedAt:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),gender:d.optional().nullable(),dateOfBirth:y.optional().nullable(),dateOfDeath:y.optional().nullable(),description:z$1.string().optional().nullable(),aliases:z$1.array(z$1.string()).optional().nullable(),occupation:z$1.array(d).optional().nullable(),position:z$1.array(ot).optional().nullable(),politicalParty:z$1.array(tt).optional().nullable(),image:x.optional().nullable(),_abstract:z$1.string().optional().nullable()}),ee=z$1.object({name:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),id:z$1.string().optional().nullable(),domain:z$1.string().optional().nullable(),aliases:z$1.array(z$1.string()).optional().nullable()}),te=z$1.object({name:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),aliases:z$1.array(z$1.string()).optional().nullable(),wikidataId:z$1.string().optional().nullable()}),oe=z$1.object({name:z$1.string(),displayName:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),people:z$1.array(te),companies:z$1.array(ee),visible:z$1.boolean().optional().nullable()}),ro=z$1.object({status:z$1.number().optional().nullable(),message:z$1.string().optional().nullable(),timestamp:z$1.number().optional().nullable()}),ae=z$1.object({status:z$1.number(),numResults:z$1.number(),results:z$1.array(T)}),ne=z$1.object({name:z$1.string().optional().nullable(),displayName:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),domains:z$1.array(z$1.string()).optional().nullable()}),re=z$1.object({status:z$1.number(),numResults:z$1.number(),results:z$1.array(at)}),ie=z$1.object({status:z$1.number(),numResults:z$1.number(),articles:z$1.array(W)}),nt=z$1.object({pageId:z$1.string().optional().nullable(),sectionId:z$1.string().optional().nullable(),wikiPageId:z$1.number().optional().nullable(),wikiRevisionId:z$1.number().optional().nullable(),wikiRevisionTs:z$1.string().optional().nullable(),wikiCode:z$1.string().optional().nullable(),wikiNamespace:z$1.number().optional().nullable(),wikiTitle:z$1.string().optional().nullable(),wikidataId:z$1.string().optional().nullable(),wikidataInstanceOf:z$1.array(d).optional().nullable(),redirectTitles:z$1.array(z$1.string()).optional().nullable(),pageviews:z$1.number().optional().nullable(),title:z$1.string().optional().nullable(),styleLevel:z$1.number().optional().nullable(),content:z$1.string().optional().nullable()}),rt=z$1.object({score:z$1.number().optional().nullable(),data:nt.optional().nullable()}),f=z$1.object({name:z$1.string().optional().nullable(),count:z$1.number().optional().nullable()}),it=z$1.object({id:z$1.string().optional().nullable(),domain:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),primaryRecordId:z$1.string().optional().nullable(),updatedAt:z$1.string().optional().nullable(),altNames:z$1.array(z$1.string()).optional().nullable(),description:z$1.string().optional().nullable(),avgMonthlyPosts:z$1.number().optional().nullable(),paywall:z$1.boolean().optional().nullable(),location:K.optional().nullable(),topCategories:z$1.array(f).optional().nullable(),topTopics:z$1.array(f).optional().nullable(),topCountries:z$1.array(f).optional().nullable(),topLabels:z$1.array(f).optional().nullable(),avgBiasRating:z$1.string().optional().nullable(),adFontesBiasRating:z$1.string().optional().nullable(),allSidesBiasRating:z$1.string().optional().nullable(),mbfcBiasRating:z$1.string().optional().nullable(),monthlyVisits:z$1.number().optional().nullable(),globalRank:z$1.number().optional().nullable(),logoLarge:x.optional().nullable(),logoFavIcon:x.optional().nullable(),logoSquare:x.optional().nullable()}),le=z$1.object({status:z$1.number(),numResults:z$1.number(),results:z$1.array(it)}),se=z$1.object({status:z$1.number().optional().nullable(),results:z$1.array(z$1.unknown()).optional().nullable()}),lt=z$1.object({clusterId:z$1.string().optional().nullable(),createdAt:z$1.string().optional().nullable(),name:z$1.string().optional().nullable(),triggeredAt:z$1.string().optional().nullable(),summary:z$1.string().optional().nullable(),shortSummary:z$1.string().optional().nullable(),changelog:z$1.string().optional().nullable(),keyPoints:z$1.array(L).optional().nullable(),questions:z$1.array(U).optional().nullable()}),pe=z$1.object({status:z$1.number(),numResults:z$1.number(),results:z$1.array(lt)}),ue=z$1.object({status:z$1.number(),numResults:z$1.number(),results:z$1.array(J)}),ce=z$1.object({prompt:z$1.string().optional().nullable(),maxArticleCount:z$1.number().optional().nullable(),returnedArticleCount:z$1.number().optional().nullable(),summarizeFields:z$1.enum(["TITLE","CONTENT","SUMMARY"]).optional().nullable(),method:z$1.enum(["ARTICLES","CLUSTERS"]).optional().nullable(),model:z$1.enum(["gpt-5.4-mini","gpt-5.4-nano","gpt-5-mini","gpt-5-nano","gpt-4o","gpt-4o-mini","gpt-4.1","gpt-4.1-mini","llama-3.3-70b-versatile","openai/gpt-oss-120b"]).optional().nullable(),temperature:z$1.number().optional().nullable(),topP:z$1.number().optional().nullable(),maxTokens:z$1.number().optional().nullable()}),me=z$1.object({status:z$1.number(),numResults:z$1.number(),summary:z$1.string(),results:z$1.array(W)}),st=z$1.object({category:z$1.string().optional().nullable(),subcategory:z$1.string().optional().nullable()}),pt=z$1.object({id:z$1.number().optional().nullable(),createdAt:z$1.union([z$1.string().date(),z$1.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),updatedAt:z$1.union([z$1.string().date(),z$1.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),name:z$1.string().optional().nullable(),labels:st.optional().nullable()}),ye=z$1.object({total:z$1.number(),data:z$1.array(pt)}),he=z$1.object({name:z$1.string().optional().nullable(),displayName:z$1.string().optional().nullable(),description:z$1.string().optional().nullable(),people:z$1.array(te).optional().nullable(),companies:z$1.array(ee).optional().nullable(),visible:z$1.boolean().optional().nullable()}),ut=z$1.object({id:z$1.string().optional().nullable(),title:z$1.string().optional().nullable(),styleLevel:z$1.number().optional().nullable(),loc:z$1.array(z$1.number()).optional().nullable(),textRaw:z$1.string().optional().nullable(),textRich:z$1.string().optional().nullable()}),ct=z$1.object({id:z$1.string().optional().nullable(),scrapedAt:z$1.string().optional().nullable(),wikiPageId:z$1.number().optional().nullable(),wikiRevisionId:z$1.number().optional().nullable(),wikiRevisionTs:z$1.string().optional().nullable(),wikiCode:z$1.string().optional().nullable(),wikiNamespace:z$1.number().optional().nullable(),wikiTitle:z$1.string().optional().nullable(),url:z$1.string().optional().nullable(),topImage:z$1.string().optional().nullable(),wikidataId:z$1.string().optional().nullable(),wikidataInstanceOf:z$1.array(d).optional().nullable(),redirectTitles:z$1.array(z$1.string()).optional().nullable(),summary:z$1.string().optional().nullable(),sections:z$1.array(ut).optional().nullable(),categories:z$1.array(z$1.string()).optional().nullable(),externalLinks:z$1.array(z$1.string()).optional().nullable(),references:z$1.array(z$1.string()).optional().nullable(),pageviews:z$1.number().optional().nullable()}),mt=z$1.object({pageId:z$1.array(z$1.string()).optional().nullable(),sectionId:z$1.array(z$1.string()).optional().nullable(),wikiPageId:z$1.array(z$1.number()).optional().nullable(),wikiRevisionId:z$1.array(z$1.number()).optional().nullable(),wikiCode:z$1.array(z$1.string()).optional().nullable(),wikiNamespace:z$1.array(z$1.number()).optional().nullable(),wikidataId:z$1.array(z$1.string()).optional().nullable(),wikidataInstanceOfId:z$1.array(z$1.string()).optional().nullable(),wikidataInstanceOfLabel:z$1.array(z$1.string()).optional().nullable(),AND:z$1.array(z$1.unknown()).optional().nullable(),OR:z$1.array(z$1.unknown()).optional().nullable(),NOT:z$1.array(z$1.unknown()).optional().nullable()}),de=z$1.object({prompt:z$1.string(),filter:mt.optional().nullable(),wikiRevisionFrom:z$1.union([z$1.string().date(),z$1.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),wikiRevisionTo:z$1.union([z$1.string().date(),z$1.string().datetime()]).transform(u=>new Date(u)).optional().nullable(),pageviewsFrom:z$1.number().optional().nullable(),pageviewsTo:z$1.number().optional().nullable(),size:z$1.number().optional().nullable(),page:z$1.number().optional().nullable()}),ge=z$1.object({status:z$1.number(),numResults:z$1.number(),results:z$1.array(ct)}),be=z$1.object({status:z$1.number(),results:z$1.array(rt)});var ht=z$1.object({createSourceGroupParams:Z}),dt=z$1.object({...ht.shape}),gt=z$1.object({createWatchlistParams:oe}),bt=z$1.object({...gt.shape}),St=z$1.object({id:z$1.number()}),ft=z$1.object({...St.shape}),xt=z$1.object({id:z$1.number()}),Rt=z$1.object({...xt.shape}),Tt=z$1.object({id:z$1.string()}),wt=z$1.object({...Tt.shape}),kt=z$1.object({id:z$1.number()}),Pt=z$1.object({...kt.shape}),fe=z$1.object({q:z$1.string().optional(),name:z$1.string().optional(),clusterId:z$1.array(z$1.string()).optional(),excludeClusterId:z$1.array(z$1.string()).optional(),sortBy:R.optional(),page:z$1.number().optional(),size:z$1.number().optional(),from:z$1.date().optional(),to:z$1.date().optional(),initializedFrom:z$1.date().optional(),initializedTo:z$1.date().optional(),updatedFrom:z$1.date().optional(),updatedTo:z$1.date().optional(),topic:z$1.array(z$1.string()).optional(),category:z$1.array(z$1.string()).optional(),taxonomy:z$1.array(z$1.string()).optional(),source:z$1.array(z$1.string()).optional(),sourceGroup:z$1.array(z$1.string()).optional(),minUniqueSources:z$1.number().optional(),minSourceDiversity:z$1.number().optional(),personWikidataId:z$1.array(z$1.string()).optional(),personName:z$1.string().optional(),companyId:z$1.array(z$1.string()).optional(),companyName:z$1.string().optional(),companyDomain:z$1.array(z$1.string()).optional(),companySymbol:z$1.array(z$1.string()).optional(),country:z$1.array(z$1.string()).optional(),state:z$1.array(z$1.string()).optional(),city:z$1.array(z$1.string()).optional(),area:z$1.array(z$1.string()).optional(),minClusterSize:z$1.number().optional(),maxClusterSize:z$1.number().optional(),nameExists:z$1.boolean().optional(),positiveSentimentFrom:z$1.number().optional(),positiveSentimentTo:z$1.number().optional(),neutralSentimentFrom:z$1.number().optional(),neutralSentimentTo:z$1.number().optional(),negativeSentimentFrom:z$1.number().optional(),negativeSentimentTo:z$1.number().optional(),showStoryPageInfo:z$1.boolean().optional(),showNumResults:z$1.boolean().optional(),showDuplicates:z$1.boolean().optional(),showHighlighting:z$1.boolean().optional(),highlightFragmentSize:z$1.number().optional(),highlightNumFragments:z$1.number().optional(),highlightPreTag:z$1.string().optional(),highlightPostTag:z$1.string().optional(),highlightQ:z$1.string().optional(),expandArticles:z$1.boolean().optional(),splitBy:z$1.enum(["HOUR","DAY","WEEK","MONTH","NONE"])}),qt=z$1.object({...fe.shape}),xe=z$1.object({clusterId:z$1.array(z$1.string()).optional(),from:z$1.date().optional(),to:z$1.date().optional(),sortBy:z$1.enum(["createdAt","triggeredAt"]).optional(),page:z$1.number().optional(),size:z$1.number().optional(),changelogExists:z$1.boolean().optional()}),Ct=z$1.object({...xe.shape}),jt=z$1.object({id:z$1.number()}),At=z$1.object({...jt.shape}),Re=z$1.object({name:z$1.string().optional(),domain:z$1.string().optional(),page:z$1.string().optional(),size:z$1.string().optional(),sortBy:z$1.string(),sortOrder:z$1.string()}),It=z$1.object({...Re.shape}),Te=z$1.object({name:z$1.string().optional(),page:z$1.string().optional(),size:z$1.string().optional(),sortBy:z$1.string(),sortOrder:z$1.string()}),Ht=z$1.object({...Te.shape}),we=z$1.object({name:z$1.array(z$1.string()).optional()}),zt=z$1.object({...we.shape}),ke=z$1.object({name:z$1.array(z$1.string()).optional()}),vt=z$1.object({...ke.shape}),Pe=z$1.object({q:z$1.string().optional(),title:z$1.string().optional(),desc:z$1.string().optional(),content:z$1.string().optional(),summary:z$1.string().optional(),url:z$1.string().optional(),articleId:z$1.array(z$1.string()).optional(),clusterId:z$1.array(z$1.string()).optional(),sortBy:z.optional(),page:z$1.number().optional(),size:z$1.number().optional(),from:z$1.date().optional(),to:z$1.date().optional(),addDateFrom:z$1.date().optional(),addDateTo:z$1.date().optional(),refreshDateFrom:z$1.date().optional(),refreshDateTo:z$1.date().optional(),medium:z$1.array(z$1.string()).optional(),source:z$1.array(z$1.string()).optional(),sourceGroup:z$1.array(z$1.string()).optional(),excludeSourceGroup:z$1.array(z$1.string()).optional(),excludeSource:z$1.array(z$1.string()).optional(),watchlist:z$1.array(z$1.string()).optional(),excludeWatchlist:z$1.array(z$1.string()).optional(),paywall:z$1.boolean().optional(),byline:z$1.array(z$1.string()).optional(),author:z$1.array(z$1.string()).optional(),excludeAuthor:z$1.array(z$1.string()).optional(),journalistId:z$1.array(z$1.string()).optional(),excludeJournalistId:z$1.array(z$1.string()).optional(),language:z$1.array(z$1.string()).optional(),excludeLanguage:z$1.array(z$1.string()).optional(),searchTranslation:z$1.boolean().optional(),label:z$1.array(z$1.string()).optional(),excludeLabel:z$1.array(z$1.string()).optional(),category:z$1.array(z$1.string()).optional(),excludeCategory:z$1.array(z$1.string()).optional(),topic:z$1.array(z$1.string()).optional(),excludeTopic:z$1.array(z$1.string()).optional(),linkTo:z$1.string().optional(),showReprints:z$1.boolean().optional(),reprintGroupId:z$1.string().optional(),city:z$1.array(z$1.string()).optional(),excludeCity:z$1.array(z$1.string()).optional(),area:z$1.array(z$1.string()).optional(),state:z$1.array(z$1.string()).optional(),excludeState:z$1.array(z$1.string()).optional(),county:z$1.array(z$1.string()).optional(),excludeCounty:z$1.array(z$1.string()).optional(),locationsCountry:z$1.array(z$1.string()).optional(),country:z$1.array(z$1.string()).optional(),excludeLocationsCountry:z$1.array(z$1.string()).optional(),location:z$1.array(z$1.string()).optional(),lat:z$1.number().optional(),lon:z$1.number().optional(),maxDistance:z$1.number().optional(),sourceCity:z$1.array(z$1.string()).optional(),excludeSourceCity:z$1.array(z$1.string()).optional(),sourceCounty:z$1.array(z$1.string()).optional(),excludeSourceCounty:z$1.array(z$1.string()).optional(),sourceCountry:z$1.array(z$1.string()).optional(),excludeSourceCountry:z$1.array(z$1.string()).optional(),sourceState:z$1.array(z$1.string()).optional(),excludeSourceState:z$1.array(z$1.string()).optional(),sourceLat:z$1.number().optional(),sourceLon:z$1.number().optional(),sourceMaxDistance:z$1.number().optional(),personWikidataId:z$1.array(z$1.string()).optional(),excludePersonWikidataId:z$1.array(z$1.string()).optional(),personName:z$1.array(z$1.string()).optional(),excludePersonName:z$1.array(z$1.string()).optional(),companyId:z$1.array(z$1.string()).optional(),excludeCompanyId:z$1.array(z$1.string()).optional(),companyName:z$1.string().optional(),companyDomain:z$1.array(z$1.string()).optional(),excludeCompanyDomain:z$1.array(z$1.string()).optional(),companySymbol:z$1.array(z$1.string()).optional(),excludeCompanySymbol:z$1.array(z$1.string()).optional(),showNumResults:z$1.boolean().optional(),positiveSentimentFrom:z$1.number().optional(),positiveSentimentTo:z$1.number().optional(),neutralSentimentFrom:z$1.number().optional(),neutralSentimentTo:z$1.number().optional(),negativeSentimentFrom:z$1.number().optional(),negativeSentimentTo:z$1.number().optional(),taxonomy:z$1.array(z$1.string()).optional(),prefixTaxonomy:z$1.string().optional(),showHighlighting:z$1.boolean().optional(),highlightFragmentSize:z$1.number().optional(),highlightNumFragments:z$1.number().optional(),highlightPreTag:z$1.string().optional(),highlightPostTag:z$1.string().optional(),highlightQ:z$1.string().optional()}),Wt=z$1.object({...Pe.shape}),qe=z$1.object({id:z$1.array(z$1.string()).optional(),symbol:z$1.array(z$1.string()).optional(),domain:z$1.array(z$1.string()).optional(),country:z$1.array(z$1.string()).optional(),exchange:z$1.array(z$1.string()).optional(),numEmployeesFrom:z$1.number().optional(),numEmployeesTo:z$1.number().optional(),ipoFrom:z$1.date().optional(),ipoTo:z$1.date().optional(),q:z$1.string().optional(),name:z$1.string().optional(),industry:z$1.string().optional(),sector:z$1.string().optional(),size:z$1.number().optional(),page:z$1.number().optional()}),Gt=z$1.object({...qe.shape}),Ce=z$1.object({id:z$1.array(z$1.string()).optional(),q:z$1.string().optional(),name:z$1.string().optional(),twitter:z$1.string().optional(),size:z$1.number().optional(),page:z$1.number().optional(),source:z$1.array(z$1.string()).optional(),topic:z$1.array(z$1.string()).optional(),category:z$1.array(z$1.string()).optional(),label:z$1.array(z$1.string()).optional(),minMonthlyPosts:z$1.number().optional(),maxMonthlyPosts:z$1.number().optional(),country:z$1.array(z$1.string()).optional(),updatedAtFrom:z$1.date().optional(),updatedAtTo:z$1.date().optional(),showNumResults:z$1.boolean().optional()}),Dt=z$1.object({...Ce.shape}),je=z$1.object({name:z$1.string().optional(),wikidataId:z$1.array(z$1.string()).optional(),occupationId:z$1.array(z$1.string()).optional(),occupationLabel:z$1.string().optional(),page:z$1.number().optional(),size:z$1.number().optional()}),Bt=z$1.object({...je.shape}),Ae=z$1.object({domain:z$1.array(z$1.string()).optional(),name:z$1.string().optional(),sourceGroup:z$1.string().optional(),sortBy:R.optional(),page:z$1.number().optional(),size:z$1.number().optional(),minMonthlyVisits:z$1.number().optional(),maxMonthlyVisits:z$1.number().optional(),minMonthlyPosts:z$1.number().optional(),maxMonthlyPosts:z$1.number().optional(),country:z$1.array(z$1.string()).optional(),sourceCountry:z$1.array(z$1.string()).optional(),sourceState:z$1.array(z$1.string()).optional(),sourceCounty:z$1.array(z$1.string()).optional(),sourceCity:z$1.array(z$1.string()).optional(),sourceLat:z$1.number().optional(),sourceLon:z$1.number().optional(),sourceMaxDistance:z$1.number().optional(),category:z$1.array(z$1.string()).optional(),topic:z$1.array(z$1.string()).optional(),label:z$1.array(z$1.string()).optional(),paywall:z$1.boolean().optional(),showSubdomains:z$1.boolean().optional(),showNumResults:z$1.boolean().optional()}),Ft=z$1.object({...Ae.shape}),Ie=z$1.object({q:z$1.string().optional(),name:z$1.string().optional(),clusterId:z$1.array(z$1.string()).optional(),excludeClusterId:z$1.array(z$1.string()).optional(),sortBy:R.optional(),page:z$1.number().optional(),size:z$1.number().optional(),from:z$1.date().optional(),to:z$1.date().optional(),initializedFrom:z$1.date().optional(),initializedTo:z$1.date().optional(),updatedFrom:z$1.date().optional(),updatedTo:z$1.date().optional(),topic:z$1.array(z$1.string()).optional(),category:z$1.array(z$1.string()).optional(),taxonomy:z$1.array(z$1.string()).optional(),source:z$1.array(z$1.string()).optional(),sourceGroup:z$1.array(z$1.string()).optional(),minUniqueSources:z$1.number().optional(),minSourceDiversity:z$1.number().optional(),personWikidataId:z$1.array(z$1.string()).optional(),personName:z$1.string().optional(),companyId:z$1.array(z$1.string()).optional(),companyName:z$1.string().optional(),companyDomain:z$1.array(z$1.string()).optional(),companySymbol:z$1.array(z$1.string()).optional(),country:z$1.array(z$1.string()).optional(),state:z$1.array(z$1.string()).optional(),city:z$1.array(z$1.string()).optional(),area:z$1.array(z$1.string()).optional(),minClusterSize:z$1.number().optional(),maxClusterSize:z$1.number().optional(),nameExists:z$1.boolean().optional(),positiveSentimentFrom:z$1.number().optional(),positiveSentimentTo:z$1.number().optional(),neutralSentimentFrom:z$1.number().optional(),neutralSentimentTo:z$1.number().optional(),negativeSentimentFrom:z$1.number().optional(),negativeSentimentTo:z$1.number().optional(),showStoryPageInfo:z$1.boolean().optional(),showNumResults:z$1.boolean().optional(),showDuplicates:z$1.boolean().optional(),showHighlighting:z$1.boolean().optional(),highlightFragmentSize:z$1.number().optional(),highlightNumFragments:z$1.number().optional(),highlightPreTag:z$1.string().optional(),highlightPostTag:z$1.string().optional(),highlightQ:z$1.string().optional(),expandArticles:z$1.boolean().optional()}),Et=z$1.object({...Ie.shape}),He=z$1.object({q:z$1.string().optional(),title:z$1.string().optional(),desc:z$1.string().optional(),content:z$1.string().optional(),summary:z$1.string().optional(),url:z$1.string().optional(),articleId:z$1.array(z$1.string()).optional(),clusterId:z$1.array(z$1.string()).optional(),sortBy:z.optional(),page:z$1.number().optional(),size:z$1.number().optional(),from:z$1.date().optional(),to:z$1.date().optional(),addDateFrom:z$1.date().optional(),addDateTo:z$1.date().optional(),refreshDateFrom:z$1.date().optional(),refreshDateTo:z$1.date().optional(),medium:z$1.array(z$1.string()).optional(),source:z$1.array(z$1.string()).optional(),sourceGroup:z$1.array(z$1.string()).optional(),excludeSourceGroup:z$1.array(z$1.string()).optional(),excludeSource:z$1.array(z$1.string()).optional(),watchlist:z$1.array(z$1.string()).optional(),excludeWatchlist:z$1.array(z$1.string()).optional(),paywall:z$1.boolean().optional(),byline:z$1.array(z$1.string()).optional(),author:z$1.array(z$1.string()).optional(),excludeAuthor:z$1.array(z$1.string()).optional(),journalistId:z$1.array(z$1.string()).optional(),excludeJournalistId:z$1.array(z$1.string()).optional(),language:z$1.array(z$1.string()).optional(),excludeLanguage:z$1.array(z$1.string()).optional(),searchTranslation:z$1.boolean().optional(),label:z$1.array(z$1.string()).optional(),excludeLabel:z$1.array(z$1.string()).optional(),category:z$1.array(z$1.string()).optional(),excludeCategory:z$1.array(z$1.string()).optional(),topic:z$1.array(z$1.string()).optional(),excludeTopic:z$1.array(z$1.string()).optional(),linkTo:z$1.string().optional(),showReprints:z$1.boolean().optional(),reprintGroupId:z$1.string().optional(),city:z$1.array(z$1.string()).optional(),excludeCity:z$1.array(z$1.string()).optional(),area:z$1.array(z$1.string()).optional(),state:z$1.array(z$1.string()).optional(),excludeState:z$1.array(z$1.string()).optional(),county:z$1.array(z$1.string()).optional(),excludeCounty:z$1.array(z$1.string()).optional(),locationsCountry:z$1.array(z$1.string()).optional(),country:z$1.array(z$1.string()).optional(),excludeLocationsCountry:z$1.array(z$1.string()).optional(),location:z$1.array(z$1.string()).optional(),lat:z$1.number().optional(),lon:z$1.number().optional(),maxDistance:z$1.number().optional(),sourceCity:z$1.array(z$1.string()).optional(),excludeSourceCity:z$1.array(z$1.string()).optional(),sourceCounty:z$1.array(z$1.string()).optional(),excludeSourceCounty:z$1.array(z$1.string()).optional(),sourceCountry:z$1.array(z$1.string()).optional(),excludeSourceCountry:z$1.array(z$1.string()).optional(),sourceState:z$1.array(z$1.string()).optional(),excludeSourceState:z$1.array(z$1.string()).optional(),sourceLat:z$1.number().optional(),sourceLon:z$1.number().optional(),sourceMaxDistance:z$1.number().optional(),personWikidataId:z$1.array(z$1.string()).optional(),excludePersonWikidataId:z$1.array(z$1.string()).optional(),personName:z$1.array(z$1.string()).optional(),excludePersonName:z$1.array(z$1.string()).optional(),companyId:z$1.array(z$1.string()).optional(),excludeCompanyId:z$1.array(z$1.string()).optional(),companyName:z$1.string().optional(),companyDomain:z$1.array(z$1.string()).optional(),excludeCompanyDomain:z$1.array(z$1.string()).optional(),companySymbol:z$1.array(z$1.string()).optional(),excludeCompanySymbol:z$1.array(z$1.string()).optional(),showNumResults:z$1.boolean().optional(),positiveSentimentFrom:z$1.number().optional(),positiveSentimentTo:z$1.number().optional(),neutralSentimentFrom:z$1.number().optional(),neutralSentimentTo:z$1.number().optional(),negativeSentimentFrom:z$1.number().optional(),negativeSentimentTo:z$1.number().optional(),taxonomy:z$1.array(z$1.string()).optional(),prefixTaxonomy:z$1.string().optional(),showHighlighting:z$1.boolean().optional(),highlightFragmentSize:z$1.number().optional(),highlightNumFragments:z$1.number().optional(),highlightPreTag:z$1.string().optional(),highlightPostTag:z$1.string().optional(),highlightQ:z$1.string().optional()}),Ot=z$1.object({summaryBody:ce}),Lt=z$1.object({...He.shape,...Ot.shape}),ze=z$1.object({name:z$1.string().optional(),category:z$1.string().optional(),subcategory:z$1.string().optional(),page:z$1.number().optional(),size:z$1.number().optional()}),Nt=z$1.object({...ze.shape}),ve=z$1.object({q:z$1.string().optional(),title:z$1.string().optional(),summary:z$1.string().optional(),text:z$1.string().optional(),reference:z$1.string().optional(),id:z$1.array(z$1.string()).optional(),wikiPageId:z$1.array(z$1.number()).optional(),wikiRevisionId:z$1.array(z$1.number()).optional(),wikiCode:z$1.array(z$1.string()).optional(),wikiNamespace:z$1.array(z$1.number()).optional(),wikidataId:z$1.array(z$1.string()).optional(),wikidataInstanceOfId:z$1.array(z$1.string()).optional(),wikidataInstanceOfLabel:z$1.array(z$1.string()).optional(),category:z$1.array(z$1.string()).optional(),sectionId:z$1.array(z$1.string()).optional(),wikiRevisionFrom:z$1.date().optional(),wikiRevisionTo:z$1.date().optional(),scrapedAtFrom:z$1.date().optional(),scrapedAtTo:z$1.date().optional(),pageviewsFrom:z$1.number().optional(),pageviewsTo:z$1.number().optional(),withPageviews:z$1.boolean().optional(),showNumResults:z$1.boolean().optional(),page:z$1.number().optional(),size:z$1.number().optional(),sortBy:z$1.enum(["relevance","revisionTsDesc","revisionTsAsc","pageViewsDesc","pageViewsAsc","scrapedAtDesc","scrapedAtAsc"]).optional()}),Ut=z$1.object({...ve.shape}),Mt=z$1.object({patchSourceGroupParams:ne}),$t=z$1.object({id:z$1.number()}),Kt=z$1.object({...Mt.shape,...$t.shape}),Qt=z$1.object({updateWatchlistParams:he}),Vt=z$1.object({id:z$1.number()}),Jt=z$1.object({...Qt.shape,...Vt.shape}),Yt=z$1.object({articleSearchParams:Y}),_t=z$1.object({...Yt.shape}),Xt=z$1.object({wikipediaSearchParams:de}),Zt=z$1.object({...Xt.shape}),Se=class extends g{async createSourceGroup(o,a){let i=dt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups",method:"POST",headers:r,body:i.createSourceGroupParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async createWatchlist(o,a){let i=bt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists",method:"POST",headers:r,body:i.createWatchlistParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async deleteSourceGroup(o,a){let i=ft.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"DELETE",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async deleteWatchlist(o,a){let i=Rt.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"DELETE",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async getJournalistById(o,a){let i=wt.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let p=await(await this.request({path:"/v1/journalists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"GET",headers:r},a)).json();return T.parse(p)}async getSourceGroup(o,a){let i=Pt.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"GET",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async getStoryCounts(o,a){let i=qt.parse(o),r=fe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/stories/stats",method:"GET",headers:n,query:r},a)).json();return se.parse(s)}async getStoryHistory(o={},a){let i=Ct.parse(o),r=xe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/stories/history",method:"GET",headers:n,query:r},a)).json();return pe.parse(s)}async getWatchlist(o,a){let i=At.parse(o),r={};if(this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"GET",headers:r},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async listSourceGroups(o,a){let i=It.parse(o),r=Re.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/sourceGroups",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async listWatchlists(o,a){let i=Ht.parse(o),r=Te.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/watchlists",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async resolveSourceGroups(o={},a){let i=zt.parse(o),r=we.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/sourceGroups/resolve",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async resolveWatchlists(o={},a){let i=vt.parse(o),r=ke.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let p=await this.request({path:"/v1/api/watchlists/resolve",method:"GET",headers:n,query:r},a),s=p.headers.get("content-type");if(s&&s.includes("application/json"))return await p.json()}async searchArticles(o={},a){let i=Wt.parse(o),r=Pe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/articles/all",method:"GET",headers:n,query:r},a)).json();return ie.parse(s)}async searchCompanies(o={},a){let i=Gt.parse(o),r=qe.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/companies/all",method:"GET",headers:n,query:r},a)).json();return X.parse(s)}async searchJournalists(o={},a){let i=Dt.parse(o),r=Ce.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/journalists/all",method:"GET",headers:n,query:r},a)).json();return ae.parse(s)}async searchPeople(o={},a){let i=Bt.parse(o),r=je.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/people/all",method:"GET",headers:n,query:r},a)).json();return re.parse(s)}async searchSources(o={},a){let i=Ft.parse(o),r=Ae.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/sources/all",method:"GET",headers:n,query:r},a)).json();return le.parse(s)}async searchStories(o={},a){let i=Et.parse(o),r=Ie.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/stories/all",method:"GET",headers:n,query:r},a)).json();return ue.parse(s)}async searchSummarizer(o,a){let i=Lt.parse(o),r=He.parse(i),n={};if(n["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/summarize",method:"POST",headers:n,query:r,body:i.summaryBody},a)).json();return me.parse(s)}async searchTopics(o={},a){let i=Nt.parse(o),r=ze.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/topics/all",method:"GET",headers:n,query:r},a)).json();return ye.parse(s)}async searchWikipedia(o={},a){let i=Ut.parse(o),r=ve.parse(i),n={};if(this.configuration&&this.configuration.accessToken){let l=this.configuration.accessToken,c=await l("apiKeyAuth",[]);c&&(n.Authorization=`Bearer ${c}`);}let s=await(await this.request({path:"/v1/wikipedia/all",method:"GET",headers:n,query:r},a)).json();return ge.parse(s)}async updateSourceGroup(o,a){let i=Kt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/sourceGroups/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"PATCH",headers:r,body:i.patchSourceGroupParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async updateWatchlist(o,a){let i=Jt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let n=await this.request({path:"/v1/api/watchlists/{id}".replace("{id}",encodeURIComponent(String(i.id))),method:"PATCH",headers:r,body:i.updateWatchlistParams},a),p=n.headers.get("content-type");if(p&&p.includes("application/json"))return await n.json()}async vectorSearchArticles(o,a){let i=_t.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let p=await(await this.request({path:"/v1/vector/news/all",method:"POST",headers:r,body:i.articleSearchParams},a)).json();return _.parse(p)}async vectorSearchWikipedia(o,a){let i=Zt.parse(o),r={};if(r["Content-Type"]="application/json",this.configuration&&this.configuration.accessToken){let s=this.configuration.accessToken,l=await s("apiKeyAuth",[]);l&&(r.Authorization=`Bearer ${l}`);}let p=await(await this.request({path:"/v1/vector/wikipedia/all",method:"POST",headers:r,body:i.wikipediaSearchParams},a)).json();return be.parse(p)}},so={Hour:"HOUR",Day:"DAY",Week:"WEEK",Month:"MONTH",None:"NONE"},po={CreatedAt:"createdAt",TriggeredAt:"triggeredAt"},uo={Relevance:"relevance",RevisionTsDesc:"revisionTsDesc",RevisionTsAsc:"revisionTsAsc",PageViewsDesc:"pageViewsDesc",PageViewsAsc:"pageViewsAsc",ScrapedAtDesc:"scrapedAtDesc",ScrapedAtAsc:"scrapedAtAsc"};
|
|
2
2
|
export{no as AllEndpointSortBy,z as AllEndpointSortBySchema,W as ArticleSchema,Ye as ArticleSearchFilterSchema,Y as ArticleSearchParamsSchema,_ as ArticlesVectorSearchResultSchema,We as BASE_PATH,P as BadRequestError,g as BaseAPI,eo as COLLECTION_FORMATS,H as CategoryHolderSchema,Oe as CategoryWithScoreHolderSchema,Ke as CompanyCountSchema,O as CompanyHolderSchema,et as CompanySchema,X as CompanySearchResultSchema,w as Configuration,E as CoordinateFilterSchema,$ as CoordinateSchema,ht as CreateSourceGroupBodySchema,Z as CreateSourceGroupParamsSchema,dt as CreateSourceGroupRequestSchema,gt as CreateWatchlistBodySchema,oe as CreateWatchlistParamsSchema,bt as CreateWatchlistRequestSchema,Ge as DefaultConfig,St as DeleteSourceGroupPathSchema,ft as DeleteSourceGroupRequestSchema,xt as DeleteWatchlistPathSchema,Rt as DeleteWatchlistRequestSchema,Le as EntityHolderSchema,ro as ErrorResponseSchema,Ne as EventTypeHolderSchema,k as FetchError,C as ForbiddenError,Tt as GetJournalistByIdPathSchema,wt as GetJournalistByIdRequestSchema,kt as GetSourceGroupPathSchema,Pt as GetSourceGroupRequestSchema,fe as GetStoryCountsQuerySchema,qt as GetStoryCountsRequestSchema,so as GetStoryCountsSplitByEnum,xe as GetStoryHistoryQuerySchema,Ct as GetStoryHistoryRequestSchema,po as GetStoryHistorySortByEnum,jt as GetWatchlistPathSchema,At as GetWatchlistRequestSchema,m as HttpError,Ue as IdNameHolderSchema,x as ImageHolderSchema,T as JournalistSchema,ae as JournalistSearchResultSchema,L as KeyPointSchema,Me as KeywordHolderSchema,$e as LabelHolderSchema,Re as ListSourceGroupsQuerySchema,It as ListSourceGroupsRequestSchema,Te as ListWatchlistsQuerySchema,Ht as ListWatchlistsRequestSchema,Qe as LocationCountSchema,v as LocationHolderSchema,h as NameCountSchema,D as NetworkError,J as NewsClusterSchema,j as NotFoundError,ne as PatchSourceGroupParamsSchema,re as PeopleSearchResultSchema,Ve as PersonCountSchema,N as PersonHolderSchema,at as PersonSchema,Je as PlaceSchema,ie as QuerySearchResultSchema,U as QuestionSchema,A as RateLimitError,S as RecordStatHolderSchema,we as ResolveSourceGroupsQuerySchema,zt as ResolveSourceGroupsRequestSchema,ke as ResolveWatchlistsQuerySchema,vt as ResolveWatchlistsRequestSchema,_e as ScoredDataArticleSchema,rt as ScoredDataWikiDataSchema,Pe as SearchArticlesQuerySchema,Wt as SearchArticlesRequestSchema,qe as SearchCompaniesQuerySchema,Gt as SearchCompaniesRequestSchema,Ce as SearchJournalistsQuerySchema,Dt as SearchJournalistsRequestSchema,je as SearchPeopleQuerySchema,Bt as SearchPeopleRequestSchema,Ae as SearchSourcesQuerySchema,Ft as SearchSourcesRequestSchema,Ie as SearchStoriesQuerySchema,Et as SearchStoriesRequestSchema,Ot as SearchSummarizerBodySchema,He as SearchSummarizerQuerySchema,Lt as SearchSummarizerRequestSchema,ze as SearchTopicsQuerySchema,Nt as SearchTopicsRequestSchema,ve as SearchWikipediaQuerySchema,Ut as SearchWikipediaRequestSchema,uo as SearchWikipediaSortByEnum,M as SentimentHolderSchema,I as ServerError,ao as SortBy,R as SortBySchema,Q as SourceHolderSchema,K as SourceLocationSchema,it as SourceSchema,le as SourceSearchResultSchema,f as SourceTopStatHolderSchema,se as StatResultSchema,lt as StoryHistoryRecordSchema,pe as StoryHistoryResultSchema,ue as StorySearchResultSchema,ce as SummaryBodySchema,me as SummarySearchResultSchema,Xe as SymbolHolderSchema,pt as TopicDtoSchema,V as TopicHolderSchema,st as TopicLabelsSchema,ye as TopicSearchResultSchema,q as UnauthorizedError,Mt as UpdateSourceGroupBodySchema,$t as UpdateSourceGroupPathSchema,Kt as UpdateSourceGroupRequestSchema,Qt as UpdateWatchlistBodySchema,he as UpdateWatchlistParamsSchema,Vt as UpdateWatchlistPathSchema,Jt as UpdateWatchlistRequestSchema,Se as V1Api,Yt as VectorSearchArticlesBodySchema,_t as VectorSearchArticlesRequestSchema,Xt as VectorSearchWikipediaBodySchema,Zt as VectorSearchWikipediaRequestSchema,ee as WatchlistCompanySchema,te as WatchlistPersonSchema,Ze as WebResourcesSchema,nt as WikiDataSchema,ct as WikiPageSchema,ut as WikiPageSectionHolderSchema,y as WikidataDateHolderSchema,d as WikidataLabelHolderSchema,tt as WikidataPoliticalPartyHolderSchema,ot as WikidataPositionHolderSchema,mt as WikipediaSearchFilterSchema,de as WikipediaSearchParamsSchema,ge as WikipediaSearchResultSchema,be as WikipediaVectorSearchResultSchema,De as createHttpError,to as exists,B as querystring};//# sourceMappingURL=index.js.map
|
|
3
3
|
//# sourceMappingURL=index.js.map
|