Documentation Index
Fetch the complete documentation index at: https://docs.olostep.com/llms.txt
Use this file to discover all available pages before exploring further.
NPMパッケージ: olostep-cli
Olostep APIのCLI: map、answer、scrape、scrape-get、crawl、batch-scrape、batch-update。レスポンスはスクリプト、CI、エージェント向けにJSON(整形済み)です。
このパッケージをインストールすると、OS用のスタンドアロンバイナリがダウンロードされます。olostepを実行するのにPythonは不要です。
インストール時に、ポストインストールステップでパッケージのGitHubリリースから対応するバイナリがダウンロードされます。それが失敗した場合、このパッケージバージョンとプラットフォームに対応するリリースが存在することを確認し、再インストールしてください。
インストール
要件: Node.js 16+(npm / npx のみ; CLI自体はネイティブバイナリです)。
npm install -g olostep-cli
グローバルインストールなしで実行:
npx -y olostep-cli@latest --help
プラットフォーム: macOS (Apple SiliconとIntel)、Linux x64、Windows x64。
APIキー
環境に**OLOSTEP_API_KEY**を設定するか、olostepを実行するディレクトリに.envファイルを配置してください。
キーの作成: Olostep API Keys。
export OLOSTEP_API_KEY=your_key_here
olostep --help
| フラグ | 動作 |
|---|
--out <path> | JSONをファイルに書き込みます(必要に応じて親ディレクトリが作成されます)。 |
--out - | JSONをstdoutのみに書き込みます(UTF-8、インデント付き)。パイプやサブプロセスキャプチャに適しています。 |
進行状況とログ行はstderrに出力されるため、stdoutは解析可能なままです。
olostep map "https://example.com" --top-n 20 --out - | jq '.urls[:10]'
olostep scrape "https://example.com" --out - | jq .result.markdown_content
--outを省略した場合、ファイルはoutput/に保存されます(デフォルトの--outパスを参照)。
コマンド
すべてのオプションについてはolostep <command> --helpを使用してください。ほとんどのコマンドは--timeout(HTTP、秒)を受け入れます。
map: URLの発見
| オプション | 説明 |
|---|
--out | ファイルパスまたは- |
--top-n | 最大URL数 |
--search-query | 発見をガイド |
--include-subdomain / --no-include-subdomain | サブドメイン |
--include-url / --exclude-url | 繰り返し可能なパターン |
--cursor | ページネーション |
--limit(削除済み)ではなく--top-nを使用してください。
olostep map "https://example.com" --top-n 100 --search-query "blog"
answer: 調査された回答
回答が準備完了になるまでポーリングします。
| オプション | 説明 |
|---|
--out | ファイルまたは- |
--json-format | オプションの構造化出力ヒント(JSONオブジェクト文字列) |
--poll-interval / --poll-timeout | ポーリング(秒) |
--model(削除済み)ではなく--json-formatを使用してください。
olostep answer "What does this company build?" --out answer.json
olostep answer "Extract facts" --json-format '{"company":"","year":""}' --out -
scrape: 1つのURL
フォーマット: html、markdown、text、json、raw_pdf、screenshot(カンマ区切り; デフォルトはmarkdown)。
| オプション | 説明 |
|---|
--formats | カンマ区切り |
--country | 国コード |
--wait-before-scraping | スクレイプ前の待機時間(ミリ秒) |
--payload-json | 高度なオプションをJSONオブジェクト文字列として |
--payload-file | 同じ、ファイルから(--payload-jsonと一緒に使用しない) |
olostep scrape "https://example.com" --formats markdown,html
olostep scrape "https://example.com" --payload-file scrape-options.json --out -
scrape-get: スクレイプIDによる取得
olostep scrape-get "scrape_abc123" --out -
crawl: サイトクロール
取得フォーマット: markdown、html、json。
注目すべきフラグ: --max-pages、--max-depth、--include-subdomain、--include-external、--include-url、--exclude-url、--search-query、--top-n、--webhook、--crawl-timeout、--follow-robots-txt / --ignore-robots-txt、--formats、--pages-limit、--pages-search-query、--poll-seconds、--poll-timeout、--dry-run(ペイロードを表示、リクエストなし)。
olostep crawl "https://docs.example.com" --max-pages 50 --formats markdown,html
olostep crawl "https://example.com" --max-pages 10 --dry-run
batch-scrape: CSV
CSV列: custom_idまたはid、および**url**。
| オプション | 説明 |
|---|
--formats | markdown、html、json |
--country | オプション |
--parser-id | 構造化抽出パーサー |
--poll-seconds、--log-every、--items-limit | ポーリング / ページング |
--dry-run | ペイロードのみを表示 |
olostep batch-scrape urls.csv --formats markdown,html
batch-update: バッチメタデータ
**--metadata-jsonまたは--metadata-file(JSONオブジェクト)**のいずれかが必要です。
olostep batch-update "batch_abc123" --metadata-json '{"team":"growth"}'
デフォルトの--outパス
--outを省略した場合:
| コマンド | デフォルト |
|---|
map | output/map.json |
answer | output/answer.json |
scrape | output/scrape.json |
scrape-get | output/scrape_get.json |
crawl | output/crawl_results.json |
batch-scrape | output/batch_results.json |
batch-update | output/batch_update.json |
グローバルフラグ
| フラグ | 説明 |
|---|
-V, --version | バージョン |
-h, --help | ヘルプ |
関連ドキュメント
リポジトリ: github.com/olostep-api/CLI
セキュリティ
APIキーをソース管理から外し、漏洩した場合はローテーションしてください。