Skip to content

Commit cc5e771

Browse files
author
searchcode bot
committed
Regenerate from the customer API contract
Generated from contracts/customer-api.json in the private source repository. Do not edit these files by hand; they are overwritten on the next contract change.
0 parents  commit cc5e771

9 files changed

Lines changed: 1064 additions & 0 deletions

File tree

.github/workflows/publish.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# GENERATED. Publishes @searchcode/cli when a version tag is pushed.
2+
name: publish
3+
4+
on:
5+
push:
6+
tags: ['v*']
7+
8+
jobs:
9+
publish:
10+
runs-on: ubuntu-latest
11+
permissions:
12+
contents: read
13+
id-token: write
14+
steps:
15+
- uses: actions/checkout@v4
16+
- uses: actions/setup-node@v4
17+
with:
18+
node-version: '22'
19+
registry-url: 'https://registry.npmjs.org'
20+
- run: npm install
21+
- run: npm test
22+
- run: npm publish --provenance --access public
23+
env:
24+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

.github/workflows/test.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# GENERATED. Runs the package's tests on every push and pull request.
2+
name: test
3+
4+
on:
5+
push:
6+
branches: [main]
7+
pull_request:
8+
9+
jobs:
10+
test:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v4
14+
- uses: actions/setup-node@v4
15+
with:
16+
node-version: '22'
17+
registry-url: 'https://registry.npmjs.org'
18+
- run: npm install
19+
- run: npm test

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
node_modules
2+
package-lock.json

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2026 searchcode.ai
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 109 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,109 @@
1+
<!--
2+
GENERATED. This repository is produced from the searchcode.ai customer API contract.
3+
Edits here are overwritten on the next contract change — open an issue instead.
4+
-->
5+
6+
# @searchcode/cli
7+
8+
[![npm](https://img.shields.io/npm/v/@searchcode/cli.svg)](https://www.npmjs.com/package/@searchcode/cli) [![license](https://img.shields.io/badge/license-MIT-blue.svg)](./LICENSE)
9+
10+
Search the source code of the public web from your terminal. Find every site running a library,
11+
embedding an endpoint, or carrying a tracking id — then look up what any of those domains is
12+
built with.
13+
14+
Powered by [searchcode.ai](https://searchcode.ai).
15+
16+
## Install
17+
18+
```bash
19+
npm install -g @searchcode/cli
20+
```
21+
22+
Or run it without installing:
23+
24+
```bash
25+
npx @searchcode/cli search --q "js.stripe.com/v3"
26+
```
27+
28+
## Set up
29+
30+
```bash
31+
export SEARCHCODE_API_KEY="your-key"
32+
```
33+
34+
[Get a key](https://searchcode.ai/). The free plan needs no card, and
35+
[free source search in the browser](https://searchcode.ai/) needs no account at all.
36+
37+
## Examples
38+
39+
```bash
40+
# every site embedding the Stripe v3 script
41+
searchcode search --q "js.stripe.com/v3"
42+
43+
# narrow to one top-level domain, as raw JSON
44+
searchcode search --q "js.stripe.com/v3" --tld de --json
45+
46+
# what is this domain built with?
47+
searchcode profile --domain example.com
48+
49+
# how many sites use React?
50+
searchcode count --kind tech --signal React
51+
```
52+
53+
## Commands
54+
55+
| Command | Credits | Plan | What it does |
56+
| --- | --- | --- | --- |
57+
| `search` | 5 | Free | Search the source code of the public web |
58+
| `count` | 1 | Free | Count the sites carrying one signal |
59+
| `tech-sites` | 3 | Free | List every site using a technology |
60+
| `export` | 5 | Solo | Export matching domains in bulk |
61+
| `profile` | 3 | Pro | Show what one domain is built with |
62+
| `read` | 5 | Pro | Read the retained source behind a search hit |
63+
| `owner` | 5 | Pro | Find domains sharing a tracking identifier |
64+
| `domains` | 1 | Free | Browse the ranked domain index |
65+
| `shops` | 1 | Enterprise | Browse captured e-commerce storefronts |
66+
| `shop-stats` | 1 | Enterprise | Aggregate statistics over the shop catalog |
67+
| `products` | 2 | Enterprise | Read captured product records |
68+
| `shops-discover` | 1 | Enterprise | Discover storefronts with resumable paging |
69+
| `catalog` | 2 | Enterprise | Read a store catalog page by page |
70+
| `catalog-doc` | 2 | Enterprise | Fetch one catalog document |
71+
72+
Run `searchcode <command> --help` for a command's arguments and flags.
73+
74+
## Global flags
75+
76+
| Flag | Effect |
77+
| --- | --- |
78+
| `--json` | print the raw API response instead of the readable rendering |
79+
| `--key` | override `SEARCHCODE_API_KEY` for one call |
80+
| `--help` | show help for the command, or the command list |
81+
82+
## Exit codes
83+
84+
| Code | Meaning |
85+
| --- | --- |
86+
| 0 | success |
87+
| 1 | the API returned an error (the message says what and why) |
88+
| 2 | your command was wrong: unknown command, missing argument, or no key |
89+
90+
## How this repository is produced
91+
92+
Every file here is generated from the searchcode.ai customer API contract. When the API changes,
93+
the contract changes, these packages are regenerated, their tests run, and a new version is
94+
published. That is why the commands, tools, credit costs and plan requirements documented here
95+
can never drift from what the API actually does.
96+
97+
Found a problem? [Open an issue](https://github.com/searchcode-ai) — please don't send a pull request against generated
98+
files, they are overwritten on the next contract change.
99+
100+
## Links
101+
102+
- [Documentation](https://searchcode.ai/docs/)
103+
- [Free source search, no account needed](https://searchcode.ai/)
104+
- [Plans and pricing](https://searchcode.ai/docs/plans/)
105+
- Contact: hello@searchcode.ai
106+
107+
## License
108+
109+
MIT

package.json

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
{
2+
"name": "@searchcode/cli",
3+
"description": "Command-line client for searchcode.ai — search the source code of the public web from your terminal.",
4+
"version": "0.1.0",
5+
"license": "MIT",
6+
"type": "module",
7+
"engines": {
8+
"node": ">=18"
9+
},
10+
"publishConfig": {
11+
"access": "public"
12+
},
13+
"author": "searchcode.ai <hello@searchcode.ai>",
14+
"homepage": "https://searchcode.ai/docs/",
15+
"keywords": [
16+
"searchcode",
17+
"source-code-search",
18+
"website-technology",
19+
"technology-lookup",
20+
"web-intelligence",
21+
"builtwith-alternative",
22+
"publicwww-alternative",
23+
"cli"
24+
],
25+
"repository": {
26+
"type": "git",
27+
"url": "git+https://github.com/searchcode-ai/searchcode-cli.git"
28+
},
29+
"bugs": {
30+
"url": "https://github.com/searchcode-ai/searchcode-cli/issues"
31+
},
32+
"bin": {
33+
"searchcode": "src/index.js"
34+
},
35+
"files": [
36+
"src"
37+
],
38+
"dependencies": {
39+
"@searchcode/core": "^0.1.0"
40+
},
41+
"scripts": {
42+
"test": "node --test test/*.test.js"
43+
}
44+
}

0 commit comments

Comments
 (0)