@stellar-light/api-client 1.0.0 → 1.1.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/README.md CHANGED
@@ -50,6 +50,7 @@ const research = await scout.searchResearch({
50
50
  |---|---|
51
51
  | `getStatus()` | `GET /api/status` |
52
52
  | `searchProjects(params)` | `GET /api/projects/search` |
53
+ | `searchRepos(params)` | `GET /api/repos/search` |
53
54
  | `getHackathons(params)` | `GET /api/hackathons` |
54
55
  | `getHackathon(slug)` | `GET /api/hackathons/{slug}` |
55
56
  | `compareHackathons(slugs)` | `GET /api/hackathons/compare` |
package/dist/index.d.ts CHANGED
@@ -64,8 +64,10 @@ interface paths {
64
64
  hackathon?: string;
65
65
  /** @description Filter to SCF-funded projects only */
66
66
  scfAwarded?: boolean;
67
- /** @description Max results returned */
67
+ /** @description Max results returned (per-page) */
68
68
  limit?: components["parameters"]["limit"];
69
+ /** @description Number of matching rows to skip before returning (pagination). Page until offset + meta.counts.returned >= meta.counts.total. */
70
+ offset?: components["parameters"]["offset"];
69
71
  };
70
72
  header?: never;
71
73
  path?: never;
@@ -92,6 +94,56 @@ interface paths {
92
94
  patch?: never;
93
95
  trace?: never;
94
96
  };
97
+ "/api/repos/search": {
98
+ parameters: {
99
+ query?: never;
100
+ header?: never;
101
+ path?: never;
102
+ cookie?: never;
103
+ };
104
+ /**
105
+ * Search the Stellar GitHub repo / code-reference index
106
+ * @description Search ~1,900 indexed-and-scored Stellar ecosystem GitHub repos by tech/keyword — the code layer beneath the project directory. Answers *'show me the repos / code for X'* and prior-art **code** lookups that project search can't. Indexes GitHub topics + description + language + README, expands synonyms (zk→zero-knowledge/snark, oracle→price-feed, …), and ranks by `repoScore` (0–100 = freshness + traction + hackathon/SCF/builder authority). Lead with high-score repos as the strongest references and cite each repo's `url` / `homepageUrl`. The same graded repos are injected inline into `/api/projects/search` as `codeReferences`.
107
+ */
108
+ get: {
109
+ parameters: {
110
+ query?: {
111
+ /** @description Keyword query (free text) */
112
+ q?: components["parameters"]["q"];
113
+ /** @description Filter by primary language (case-insensitive substring, e.g. 'Rust', 'TypeScript') */
114
+ language?: string;
115
+ /** @description Only return repos with repoScore ≥ this (0–100). Use 40+ for high-signal references. */
116
+ minScore?: number;
117
+ /** @description Max results returned (per-page) */
118
+ limit?: components["parameters"]["limit"];
119
+ /** @description Number of matching rows to skip before returning (pagination). Page until offset + meta.counts.returned >= meta.counts.total. */
120
+ offset?: components["parameters"]["offset"];
121
+ };
122
+ header?: never;
123
+ path?: never;
124
+ cookie?: never;
125
+ };
126
+ requestBody?: never;
127
+ responses: {
128
+ /** @description Repo search results graded by repoScore */
129
+ 200: {
130
+ headers: {
131
+ [name: string]: unknown;
132
+ };
133
+ content: {
134
+ "application/json": components["schemas"]["RepoSearchResponse"];
135
+ };
136
+ };
137
+ };
138
+ };
139
+ put?: never;
140
+ post?: never;
141
+ delete?: never;
142
+ options?: never;
143
+ head?: never;
144
+ patch?: never;
145
+ trace?: never;
146
+ };
95
147
  "/api/hackathons": {
96
148
  parameters: {
97
149
  query?: never;
@@ -112,7 +164,7 @@ interface paths {
112
164
  organizer?: string;
113
165
  /** @description Restrict to one feed (curated vs DoraHacks) */
114
166
  source?: "curated" | "dorahacks";
115
- /** @description Max results returned */
167
+ /** @description Max results returned (per-page) */
116
168
  limit?: components["parameters"]["limit"];
117
169
  };
118
170
  header?: never;
@@ -205,7 +257,7 @@ interface paths {
205
257
  get: {
206
258
  parameters: {
207
259
  query: {
208
- /** @description 2–5 hackathon slugs */
260
+ /** @description 2–5 hackathon slugs, comma-separated (?slugs=a,b) */
209
261
  slugs: string[];
210
262
  };
211
263
  header?: never;
@@ -253,8 +305,10 @@ interface paths {
253
305
  skill?: string;
254
306
  /** @description Filter by SCF tier */
255
307
  scfTier?: string;
256
- /** @description Max results returned */
308
+ /** @description Max results returned (per-page) */
257
309
  limit?: components["parameters"]["limit"];
310
+ /** @description Number of matching rows to skip before returning (pagination). Page until offset + meta.counts.returned >= meta.counts.total. */
311
+ offset?: components["parameters"]["offset"];
258
312
  };
259
313
  header?: never;
260
314
  path?: never;
@@ -281,6 +335,109 @@ interface paths {
281
335
  patch?: never;
282
336
  trace?: never;
283
337
  };
338
+ "/api/partners": {
339
+ parameters: {
340
+ query?: never;
341
+ header?: never;
342
+ path?: never;
343
+ cookie?: never;
344
+ };
345
+ /**
346
+ * List ecosystem partners
347
+ * @description Published partners (anchors, on/off ramps, infrastructure, tooling, protocols, wallets, audit firms). Each carries partner-claimed facts AND system-verified signals (GitHub activity, on-chain footprint, SCF involvement) plus a `freshness` object — consumers should down-rank or skip partners flagged `freshness.excludeFromMatching`. Fresh partners sort first.
348
+ */
349
+ get: {
350
+ parameters: {
351
+ query?: {
352
+ /** @description Filter by partner type */
353
+ type?: "anchor" | "on-off-ramp" | "infrastructure" | "tooling" | "protocol" | "wallet" | "audit-firm" | "legal" | "agency" | "other";
354
+ /** @description Filter by sector served (defi, payments, rwa, stablecoins, …) */
355
+ sector?: string;
356
+ /** @description Filter by region served (global, latam, africa, …) */
357
+ region?: string;
358
+ /** @description Set to 1 to return only partners currently accepting new clients */
359
+ accepting?: "1";
360
+ /** @description Keyword query (free text) */
361
+ q?: components["parameters"]["q"];
362
+ /** @description Max results returned (per-page) */
363
+ limit?: components["parameters"]["limit"];
364
+ };
365
+ header?: never;
366
+ path?: never;
367
+ cookie?: never;
368
+ };
369
+ requestBody?: never;
370
+ responses: {
371
+ /** @description Partner directory */
372
+ 200: {
373
+ headers: {
374
+ [name: string]: unknown;
375
+ };
376
+ content: {
377
+ "application/json": Record<string, never>;
378
+ };
379
+ };
380
+ };
381
+ };
382
+ put?: never;
383
+ post?: never;
384
+ delete?: never;
385
+ options?: never;
386
+ head?: never;
387
+ patch?: never;
388
+ trace?: never;
389
+ };
390
+ "/api/partners/{slug}": {
391
+ parameters: {
392
+ query?: never;
393
+ header?: never;
394
+ path?: never;
395
+ cookie?: never;
396
+ };
397
+ /**
398
+ * Get one partner's full profile
399
+ * @description Full published profile for one partner by slug, including verified signals + freshness. 404 for unknown or unpublished slugs.
400
+ */
401
+ get: {
402
+ parameters: {
403
+ query?: never;
404
+ header?: never;
405
+ path: {
406
+ /** @description Partner slug */
407
+ slug: string;
408
+ };
409
+ cookie?: never;
410
+ };
411
+ requestBody?: never;
412
+ responses: {
413
+ /** @description Partner profile */
414
+ 200: {
415
+ headers: {
416
+ [name: string]: unknown;
417
+ };
418
+ content: {
419
+ "application/json": Record<string, never>;
420
+ };
421
+ };
422
+ /** @description Partner not found or not published */
423
+ 404: {
424
+ headers: {
425
+ [name: string]: unknown;
426
+ };
427
+ content: {
428
+ "application/json": components["schemas"]["ErrorResponse"];
429
+ };
430
+ };
431
+ };
432
+ };
433
+ put?: never;
434
+ post?: never;
435
+ delete?: never;
436
+ options?: never;
437
+ head?: never;
438
+ patch?: never;
439
+ trace?: never;
440
+ };
284
441
  "/api/rfps": {
285
442
  parameters: {
286
443
  query?: never;
@@ -299,8 +456,10 @@ interface paths {
299
456
  status?: "open" | "closed";
300
457
  /** @description Filter by quarter slug (e.g. 'q1-2026') */
301
458
  quarter?: string;
302
- /** @description Max results returned */
459
+ /** @description Max results returned (per-page) */
303
460
  limit?: components["parameters"]["limit"];
461
+ /** @description Number of matching rows to skip before returning (pagination). Page until offset + meta.counts.returned >= meta.counts.total. */
462
+ offset?: components["parameters"]["offset"];
304
463
  };
305
464
  header?: never;
306
465
  path?: never;
@@ -336,7 +495,7 @@ interface paths {
336
495
  };
337
496
  /**
338
497
  * Vector search over the Stellar research corpus
339
- * @description Vector search over a 4,541-chunk corpus of primary Stellar sources: SEPs, SCF Handbook, dev docs, foundational papers (Mazières SCP), lumenloop community playbooks, Soroban audit reports (Certora, OtterSec, Halborn, OpenZeppelin, Code4rena, etc.), Electric Capital Developer Reports, SDF blog. Returns top-K chunks with severity metadata for audit chunks. Score field is cosine similarity (0–1, higher = more relevant).
498
+ * @description Vector search over a 4,541-chunk corpus of primary Stellar sources: SEPs, SCF Handbook, dev docs, foundational papers (Mazières SCP), lumenloop community playbooks, Soroban audit reports (Certora, OtterSec, Halborn, OpenZeppelin, Code4rena, etc.), Electric Capital Developer Reports, SDF blog. Returns top-K chunks with severity metadata for audit chunks. Each result carries a `confidence` object — `{ score (0-1), label (high/medium/low), relevance, freshness, authority, ageDays }` — blending match strength, source-aware recency, and source authority so an agent can tell a strong, fresh, canonical hit from a weak or stale one. Sort by `confidence.score` for trust-ranked results; `meta.scoreModel.version` identifies the model. The raw `score` field remains cosine similarity (0–1, higher = more relevant).
340
499
  */
341
500
  get: {
342
501
  parameters: {
@@ -674,7 +833,10 @@ interface components {
674
833
  [key: string]: unknown;
675
834
  };
676
835
  counts?: {
836
+ /** @description Rows in this page (post limit/offset slice) */
677
837
  returned?: number;
838
+ /** @description Rows matching the filter before slicing (paginated endpoints). Page until offset + returned >= total. */
839
+ total?: number;
678
840
  };
679
841
  };
680
842
  ErrorResponse: {
@@ -720,7 +882,7 @@ interface components {
720
882
  category: "Infrastructure" | "Tooling" | "User-Facing App" | "Asset" | "Protocol/Contract" | "Anchor" | "Partner Integration";
721
883
  shortDescription?: string;
722
884
  /** @enum {string} */
723
- status: "Live" | "Development" | "Abandoned";
885
+ status: "Draft" | "Development" | "Pre-Release" | "Live";
724
886
  logoUrl?: string | null;
725
887
  scfAwarded?: boolean;
726
888
  scfTotalAwardedUSD?: number | null;
@@ -732,6 +894,19 @@ interface components {
732
894
  score?: number;
733
895
  /** Format: uri */
734
896
  url?: string;
897
+ /** @description Editorial ranking boost (0-100); higher = more canonical for its category. */
898
+ prominence?: number;
899
+ verificationLevel?: string | null;
900
+ /** @description Capability tags (Wallet, DEX, Lending, Oracle, SDK, RPC, Faucet, NFT, RWA, Anchor, Stablecoin, Indexer, Explorer, Security, Gaming). */
901
+ types?: string[];
902
+ /** @description The project OWN canonical homes - cite these as the primary source, not StellarLight or any directory. Only present, non-empty fields are included. */
903
+ links?: {
904
+ website?: string;
905
+ github?: string;
906
+ docs?: string;
907
+ twitter?: string;
908
+ discord?: string;
909
+ };
735
910
  };
736
911
  ProjectSearchResponse: {
737
912
  meta: components["schemas"]["Meta"] & {
@@ -743,6 +918,8 @@ interface components {
743
918
  matchModeLabel?: string;
744
919
  };
745
920
  projects: components["schemas"]["Project"][];
921
+ /** @description Top graded repos matching the same query, surfaced inline (max 5, first page only; same shape as /api/repos/search). Cite as existing code references for prior-art questions. */
922
+ codeReferences?: components["schemas"]["Repo"][];
746
923
  };
747
924
  HackathonsResponse: {
748
925
  meta?: components["schemas"]["Meta"] & {
@@ -759,6 +936,44 @@ interface components {
759
936
  meta?: components["schemas"]["Meta"];
760
937
  hackathon?: Record<string, never>;
761
938
  };
939
+ /** @description An indexed Stellar ecosystem GitHub repository graded by repoScore. Cite the repo's url / homepageUrl as the primary source. */
940
+ Repo: {
941
+ /** @description owner/name */
942
+ fullName: string;
943
+ owner?: string | null;
944
+ name?: string | null;
945
+ /** Format: uri */
946
+ url?: string | null;
947
+ description?: string | null;
948
+ topics?: string[];
949
+ primaryLanguage?: string | null;
950
+ stars?: number;
951
+ openIssues?: number;
952
+ /** Format: date-time */
953
+ lastCommitAt?: string | null;
954
+ homepageUrl?: string | null;
955
+ isFork?: boolean;
956
+ isArchived?: boolean;
957
+ /** @description The curated project this repo is linked to, if any. */
958
+ project?: {
959
+ slug?: string;
960
+ name?: string | null;
961
+ } | null;
962
+ hackathonWinner?: boolean;
963
+ scfAwarded?: boolean;
964
+ builderReputation?: number;
965
+ judgeScore?: number | null;
966
+ judgedHackathon?: string | null;
967
+ /** @description Quality grade (0–100) = freshness + traction + hackathon/SCF/builder authority. Lead with high-score repos. */
968
+ repoScore: number;
969
+ repoScoreLabel?: string | null;
970
+ /** @description Keyword-relevance score for the current query (higher = better match). */
971
+ score?: number;
972
+ };
973
+ RepoSearchResponse: {
974
+ meta: components["schemas"]["Meta"];
975
+ repos: components["schemas"]["Repo"][];
976
+ };
762
977
  FeedbackRequest: {
763
978
  /** @enum {string} */
764
979
  kind: "bug" | "missing-data" | "wrong-answer" | "suggestion" | "other";
@@ -772,8 +987,10 @@ interface components {
772
987
  parameters: {
773
988
  /** @description Keyword query (free text) */
774
989
  q: string;
775
- /** @description Max results returned */
990
+ /** @description Max results returned (per-page) */
776
991
  limit: number;
992
+ /** @description Number of matching rows to skip before returning (pagination). Page until offset + meta.counts.returned >= meta.counts.total. */
993
+ offset: number;
777
994
  };
778
995
  requestBodies: never;
779
996
  headers: never;
@@ -802,12 +1019,15 @@ interface components {
802
1019
  /** Re-exported component schemas for consumer convenience. */
803
1020
  type Project = components["schemas"]["Project"];
804
1021
  type ProjectSearchResponse = components["schemas"]["ProjectSearchResponse"];
1022
+ type Repo = components["schemas"]["Repo"];
1023
+ type RepoSearchResponse = components["schemas"]["RepoSearchResponse"];
805
1024
  type StatusResponse = components["schemas"]["StatusResponse"];
806
1025
  type HackathonsResponse = components["schemas"]["HackathonsResponse"];
807
1026
  type HackathonDetailResponse = components["schemas"]["HackathonDetailResponse"];
808
1027
  type FeedbackRequest = components["schemas"]["FeedbackRequest"];
809
1028
  /** Query params, lifted from the generated paths for ergonomic call sites. */
810
1029
  type SearchProjectsParams = NonNullable<paths["/api/projects/search"]["get"]["parameters"]["query"]>;
1030
+ type SearchReposParams = NonNullable<paths["/api/repos/search"]["get"]["parameters"]["query"]>;
811
1031
  type GetHackathonsParams = NonNullable<paths["/api/hackathons"]["get"]["parameters"]["query"]>;
812
1032
  type GetBuildersParams = NonNullable<paths["/api/builders"]["get"]["parameters"]["query"]>;
813
1033
  type GetRfpsParams = NonNullable<paths["/api/rfps"]["get"]["parameters"]["query"]>;
@@ -843,6 +1063,12 @@ declare class ScoutClient {
843
1063
  getStatus(): Promise<StatusResponse>;
844
1064
  /** Search 741+ curated Stellar projects (prior art / competitor lookup). */
845
1065
  searchProjects(params?: SearchProjectsParams): Promise<ProjectSearchResponse>;
1066
+ /**
1067
+ * Search ~1,900 indexed-and-scored Stellar GitHub repos by tech/keyword —
1068
+ * the code layer beneath the project directory. Ranked by repoScore
1069
+ * (freshness + traction + hackathon/SCF/builder authority).
1070
+ */
1071
+ searchRepos(params?: SearchReposParams): Promise<RepoSearchResponse>;
846
1072
  /** List Stellar hackathons (curated + DoraHacks merged feed). */
847
1073
  getHackathons(params?: GetHackathonsParams): Promise<HackathonsResponse>;
848
1074
  /** Full detail for one hackathon by slug. */
@@ -875,4 +1101,4 @@ declare class ScoutClient {
875
1101
  private request;
876
1102
  }
877
1103
 
878
- export { type AnalyzeEcosystemParams, type FeedbackRequest, type GetBuildersParams, type GetClustersParams, type GetHackathonsParams, type GetLeaderboardParams, type GetRfpsParams, type HackathonDetailResponse, type HackathonsResponse, type ListSkillsParams, type Project, type ProjectSearchResponse, ScoutApiError, ScoutClient, type ScoutClientOptions, type SearchProjectsParams, type SearchResearchParams, type StatusResponse, type components, type paths };
1104
+ export { type AnalyzeEcosystemParams, type FeedbackRequest, type GetBuildersParams, type GetClustersParams, type GetHackathonsParams, type GetLeaderboardParams, type GetRfpsParams, type HackathonDetailResponse, type HackathonsResponse, type ListSkillsParams, type Project, type ProjectSearchResponse, type Repo, type RepoSearchResponse, ScoutApiError, ScoutClient, type ScoutClientOptions, type SearchProjectsParams, type SearchReposParams, type SearchResearchParams, type StatusResponse, type components, type paths };
package/dist/index.js CHANGED
@@ -13,7 +13,7 @@ var ScoutApiError = class extends Error {
13
13
  }
14
14
  };
15
15
  var DEFAULT_BASE_URL = "https://stellarlight.xyz";
16
- var CLIENT_VERSION = "1.0.0";
16
+ var CLIENT_VERSION = "1.1.0";
17
17
  var ScoutClient = class {
18
18
  baseUrl;
19
19
  timeoutMs;
@@ -36,6 +36,14 @@ var ScoutClient = class {
36
36
  searchProjects(params = {}) {
37
37
  return this.get("/api/projects/search", params);
38
38
  }
39
+ /**
40
+ * Search ~1,900 indexed-and-scored Stellar GitHub repos by tech/keyword —
41
+ * the code layer beneath the project directory. Ranked by repoScore
42
+ * (freshness + traction + hackathon/SCF/builder authority).
43
+ */
44
+ searchRepos(params = {}) {
45
+ return this.get("/api/repos/search", params);
46
+ }
39
47
  /** List Stellar hackathons (curated + DoraHacks merged feed). */
40
48
  getHackathons(params = {}) {
41
49
  return this.get("/api/hackathons", params);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stellar-light/api-client",
3
- "version": "1.0.0",
3
+ "version": "1.1.0",
4
4
  "description": "Typed TypeScript client for the Stellar Scout API — projects, builders, hackathons, SCF, audits, research. Zero dependencies, for autonomous agents and aggregators.",
5
5
  "keywords": [
6
6
  "stellar",