本文へ移動
cccskills
無料GitHub で公開日本語紹介

brightdata-sdk-patterns

Bright DataのPython SDKやREST APIをアプリ独自の型付きインターフェースで包み、取得結果やエラーを統一して変更に備える設計を支援します。

原文原文の説明を見る

Wrap the official Bright Data Python SDK and REST contracts behind a typed, testable client boundary. Use when adding SDK calls, isolating provider upgrades, or normalizing scraper and Browser API results. Trigger with: "wrap the Bright Data SDK", "design a Bright Data client", "pin Bright Data Python dependencies".

jeremylongshore/tons-of-skills-marketplaceスター 2,884(GitHub 2,884 + cccskills 0)

実行スコア 未検証

インストール方法を見る

こんなときに便利

  • Bright Data呼び出しを独自クライアントで包む
  • スクレイパーの結果形式を統一したいとき
  • SDK更新前に契約テストを整えたいとき
  • 認証情報ごとに接続処理を分けたいとき

日本語での紹介

できること

Bright Dataの公式Python SDKやREST APIを、アプリ側で管理する小さなインターフェースの背後に配置する設計を支援します。SDKの応答オブジェクトをそのまま業務コードへ渡さず、取得結果や処理状況をアプリ独自の形式に変換します。APIキー、プロキシゾーン、Browser APIなどの接続方法を分け、プロバイダー固有のエラーも安定したアプリ側のエラー分類に整理します。依存バージョンを固定し、テスト用の応答例を使って、SDK更新前に契約や挙動を確認します。

こんなときに便利

Bright Dataへの呼び出しを新たに追加するとき、SDK更新の影響をアプリ全体に広げたくないとき、スクレイパーやBrowser APIの応答形式をそろえたいときに向いています。プロダクト選択や認証情報の扱いを明示し、接続先の変更を管理しやすくしたい場合にも役立ちます。

使い方の例

  • 「Bright Data SDKを呼ぶアプリ独自のクライアントを設計して」
  • 「スクレイパーの結果を共通のレコード形式に変換して」
  • 「SDK更新前に確認するテスト用フィクスチャを用意して」

注意点

Bright Dataの承認済みアカウント、またはオフラインのテスト用データと、現行の公式ドキュメントが必要です。収集目的は許可された公開データに限る前提です。ライブAPI呼び出しは、このスキルの手順には含まれません。

この紹介文は、公開されている SKILL.md をもとに AI(OpenAI Codex)が作成しました。正確な仕様は下の原文を確認してください。

含まれるファイル(2)

  • SKILL.md3.6 KB
  • references/official-docs.md704 B

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

Bright Data Typed Client Boundary

Overview

Use the official Python SDK where it matches the workload, but keep product choice, authorization, retry policy, and domain schemas outside vendor objects. Pin the dependency and expose a small application-owned interface.

Prerequisites

  • A Python project with a lockfile and supported runtime
  • An approved Bright Data product and credential mode
  • Synthetic contract fixtures for every exposed operation

Instructions

Step 1: Pin and inspect

Read the lockfile and Grep for direct Bright Data imports. Pin the reviewed SDK release through the repository dependency workflow rather than embedding a version in this skill.

Step 2: Define the port

Write an application interface that returns normalized records and provider receipts, not raw SDK response objects.

from dataclasses import dataclass

@dataclass(frozen=True)
class CollectionReceipt:
    operation_id: str
    state: str
    records: int | None
    provider_code: str | None

Step 3: Implement adapters

Keep API-key, proxy-zone, and Browser API adapters separate. Map documented terminal states and current x-brd-* errors into stable application failure classes.

Step 4: Verify the seam

Use Bash(python:*) to run type checks and fixture tests. Compare the locked SDK behavior with the current official SDK docs before any upgrade.

Tool Discipline

Use Read and Grep to locate dependency and transport boundaries. Use Write and Edit for the typed port, provider adapters, and tests. Use Bash(python:*) only for local type/test commands; live SDK calls require a separate authorized workflow.

Output

  • Pinned SDK dependency and application-owned port
  • Separate credential/product adapters
  • Normalized receipts and fixture-backed failure mapping

Examples

Expose trigger_collection, get_progress, and download_snapshot through your own protocol. Keep a vendor response fixture at the boundary, map it once, and let downstream code depend only on CollectionReceipt.

Error Handling

FailureMeaningResponse
SDK object escapes the adapterProvider coupling reaches domain codeNormalize the response at the boundary
Upgrade changes a field or stateLockfile moved without contract reviewHold the upgrade and refresh fixtures from documentation
Client selects a product implicitlyPolicy and cost behavior become hiddenRequire an explicit product configuration

Resources

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

コメント

ログインなしで書き込めます。使ってみた感想、質問、動かなかった環境などを気軽にどうぞ。

まだコメントはありません。最初のコメントを書いてみませんか。

送信するとすぐに公開されます。メールアドレスや電話番号などの個人情報は書かないでください。URL は 2 つまでです。

0 / 1000 文字

このフォームは reCAPTCHA で保護されており、Google のプライバシーポリシーと利用規約が適用されます。

同じリポジトリのスキル

abridge-ci-integration

無料概要あり

Abridge連携コードのCIに合成データを使った回帰チェックを加え、同意状態、ノート確認、ログの秘匿、ロールバックなど顧客側の処理を検証します。

  • Abridge連携の回帰テストを追加したいとき
  • 同意やノート確認の処理を検証したいとき
  • ログに機微情報が出ないか確かめたいとき
jeremylongshore/tons-of-skills-marketplace2,8842026年10月29日 更新

abridge-common-errors

無料概要あり

Abridgeの録音、記録の確認、Epicへの引き渡し、アクセスの不具合を観測情報から切り分け、患者情報を抑えた証拠と担当窓口への引き継ぎ資料を整理するスキル。

  • 録音とアップロード障害の切り分け
  • 記録生成の遅延や編集画面の不具合調査
  • Epic連携障害の担当窓口の特定
jeremylongshore/tons-of-skills-marketplace2,8842026年10月29日 更新

abridge-core-workflow-a

無料概要あり

同意確認から録音、生成メモの根拠確認、編集、最終確定まで、臨床文書作成の手順と確認ポイントを整理するスキルです。

  • 診療メモ作成の手順を導入・監査したいとき
  • 同意から医師の確認までの流れを整理したいとき
  • 下書きの根拠確認と停止条件を定めたいとき
jeremylongshore/tons-of-skills-marketplace2,8842026年10月29日 更新

abridge-core-workflow-b

無料概要あり

Abridgeで臨床家が確認した記録内容が、承認済みの手順でEpicの適切なテンプレート欄へ渡るか、テスト記録を使って対応関係や例外を検証するスキルです。

  • AbridgeとEpicの記録欄の対応を確認したいとき
  • 部門ごとの連携設定を監査したいとき
  • 承認済みテスト記録で連携を検証したいとき
jeremylongshore/tons-of-skills-marketplace2,8842026年10月29日 更新

abridge-cost-tuning

無料概要あり

Abridgeの導入・更新判断に向け、利用定着率や業務の完了状況、診療記録の品質、支援負担を契約に基づく費用情報と照らし、継続や改善の選択肢を整理するスキル。

  • Abridge導入後の定着率確認
  • 契約更新の判断材料をまとめたいとき
  • 診療環境ごとの業務成果の比較
jeremylongshore/tons-of-skills-marketplace2,8842026年10月29日 更新

abridge-debug-bundle

無料概要あり

Abridgeの障害調査で、録音や診療記録を含めず、許可した項目だけを集めたサポート用資料と確認用マニフェストを作成します。

  • 障害サポート用の証拠をまとめたいとき
  • 共有資料の除外項目を記録したいとき
  • 調査情報を安全な経路で引き継ぎたいとき
jeremylongshore/tons-of-skills-marketplace2,8842026年10月29日 更新

jeremylongshore のスキルをすべて見る

このスキルの問題を報告する