PageSourceSearch

https://beatapi.io/assets/deepseek-api-key-guide.ja-DOe3lyyq.js

js beatapi.io collected 2026-10-04 04:13:37 UTC 21,903 bytes, 102 lines download raw bytes

1import{a as e,t}from"./jsx-runtime-DMbYRYqz.js";import{n}from"./lib-CNLI0OBE.js";var r=e({default:()=>s,meta:()=>a}),i=t(),a={title:`DeepSeek APIキー設定:OpenAI SDKで最初の呼び出し`,seo_title:`DeepSeek APIキー設定:Base URLと初回呼び出し`,description:`DeepSeek APIキーの作成場所、正しいBase URL、OpenAI SDKでの初回呼び出しを解説します。DeepSeek直結の別名とBeatAPIのモデルIDを分けて確認できます。`,created_at:`2026-09-10`,updated_at:`2026-09-10`,author_name:`Beat API Team`,author_image:`/logo.png`,image:`https://media.beatapi.io/blog/deepseek-api-key-guide/cover-v1.webp`,image_alt:`「DeepSeek APIキー設定:OpenAI SDKで最初の呼び出し」の記事カバー画像`,categories:[`api-guides`,`async-tasks`,`cost-control`],read_time:`10分`,headings:[{id:`deepseek-apiキー設定-最初の呼び出しの結論`,title:`DeepSeek APIキー設定:最初の呼び出しの結論`},{id:`キーを作成してエンドポイントを選ぶ`,title:`キーを作成してエンドポイントを選ぶ`},{id:`openaiクライアントで最初の呼び出しを行う`,title:`OpenAIクライアントで最初の呼び出しを行う`},{id:`モデルidを推測せずに対応付ける`,title:`モデルIDを推測せずに対応付ける`},{id:`料金と経路の判断`,title:`料金と経路の判断`},{id:`最初のリクエストを直す`,title:`最初のリクエストを直す`},{id:`faq`,title:`FAQ`}]};function o(e){let t={a:`a`,code:`code`,h2:`h2`,h3:`h3`,li:`li`,p:`p`,pre:`pre`,strong:`strong`,table:`table`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,...n(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(t.h2,{children:`DeepSeek APIキー設定:最初の呼び出しの結論`}),`
2`,(0,i.jsxs)(t.p,{children:[`DeepSeek APIを最初に呼び出すには、`,(0,i.jsx)(t.a,{href:`https://platform.deepseek.com/api_keys`,children:`DeepSeek API Keysページ`}),`でキーを作成し、サーバー側の環境変数へ保存して、OpenAIクライアントのBase URLを `,(0,i.jsx)(t.code,{children:`https://api.deepseek.com`}),` に設定します。現行のFlashモデルを直接呼び出すときは `,(0,i.jsx)(t.code,{children:`deepseek-flash`}),` を使います。BeatAPIでは `,(0,i.jsx)(t.code,{children:`https://api.beatapi.io/v1`}),` と `,(0,i.jsx)(t.code,{children:`deepseek-v4-flash-0731`}),` のようなバージョン付きカタログIDを使います。2つの経路を混ぜないでください。`]}),`
3`,(0,i.jsx)(t.p,{children:`この記事では、初回リクエストで迷いやすい3点を先に解決します。`}),`
4`,(0,i.jsxs)(t.p,{children:[`すでにキーが動作していて料金層を選びたい場合は、次に`,(0,i.jsx)(t.a,{href:`/ja/blog/deepseek-api-pricing-v4-flash-vs-pro`,children:`DeepSeek API料金の計算式とFlash/Pro比較`}),`を確認してください。`]}),`
5`,(0,i.jsxs)(t.ul,{children:[`
6`,(0,i.jsx)(t.li,{children:`キーをどこで作り、どこに保存するか。`}),`
7`,(0,i.jsx)(t.li,{children:`DeepSeek直結とBeatAPIのどちらに、どのBase URLを設定するか。`}),`
8`,(0,i.jsx)(t.li,{children:`OpenAI Python例で、どのモデルIDを送るか。`}),`
9`]}),`
10`,(0,i.jsxs)(t.p,{children:[`仕様と料金は `,(0,i.jsx)(t.strong,{children:`2026年9月10日`}),` に確認しました。DeepSeekによると、旧名の `,(0,i.jsx)(t.code,{children:`deepseek-v4-flash`}),` と `,(0,i.jsx)(t.code,{children:`deepseek-v4-flash-vision-exp`}),` は互換性のために受け付けられますが、元のモデルは廃止済みで、リクエストはDeepSeek-V4.1-Flashで処理されます。新規実装で旧IDを採用する理由にはなりません。`]}),`
11`,(0,i.jsxs)(`div`,{className:`my-7 rounded-xl border border-[#d9d5cc] bg-white/80 p-5 shadow-[0_16px_40px_rgba(31,30,27,0.06)]`,children:[(0,i.jsx)(`div`,{className:`text-xs font-semibold uppercase !text-[#817d72]`,children:`5分で行う初回チェック`}),(0,i.jsx)(`div`,{className:`mt-2 text-base leading-7 !text-[#312f2a]`,children:`サーバー側でキーを作る → 経路を1つ選ぶ → 同じ経路のモデルIDを使う → 小さなリクエストを送る → 応答とリクエストIDを保存する。`}),(0,i.jsxs)(`div`,{className:`mt-4 flex flex-wrap gap-3`,children:[(0,i.jsx)(`a`,{href:`/ja/deepseek-v4-flash-api`,className:`inline-flex rounded-lg bg-[#1f1e1b] px-4 py-2.5 text-sm font-semibold !text-white !no-underline hover:bg-black hover:!text-white`,children:(0,i.jsx)(`span`,{className:`!text-white`,children:`BeatAPIモデルページを見る`})}),(0,i.jsx)(`a`,{href:`/ja/pricing`,className:`inline-flex rounded-lg border border-[#817d72] px-4 py-2.5 text-sm font-semibold !text-[#312f2a] !no-underline hover:bg-[#f3eee6]`,children:(0,i.jsx)(`span`,{className:`!text-[#312f2a]`,children:`現在の料金を確認`})})]})]}),`
12`,(0,i.jsx)(`div`,{className:`my-7 overflow-x-auto rounded-xl border border-[#d9d5cc] bg-[#0f172a] p-3 shadow-[0_16px_40px_rgba(31,30,27,0.1)]`,children:(0,i.jsx)(`img`,{src:`/blog/deepseek-api-key-guide/first-call-workflow.ja.svg`,width:`1200`,height:`700`,loading:`lazy`,decoding:`async`,alt:`DeepSeek APIキー作成から初回の直接接続またはBeatAPIリクエストまでを示す日本語ワークフロー`,className:`h-auto w-full min-w-[720px] max-w-none object-contain sm:min-w-0 sm:max-w-full`})}),`
13`,(0,i.jsx)(`div`,{className:`-mt-4 mb-7 text-sm leading-6 !text-[#817d72]`,children:`スマートフォンでは図を左右にスワイプして、経路とモデルIDの確認点を読んでください。`}),`
14`,(0,i.jsx)(t.h2,{children:`キーを作成してエンドポイントを選ぶ`}),`
15`,(0,i.jsx)(t.p,{children:`APIキーはモデルを選ぶ設定ではなく、認証情報です。リクエストを受けるサービスで作成し、その経路を呼び出すサーバーに保存します。`}),`
16`,(0,i.jsxs)(t.table,{children:[(0,i.jsx)(t.thead,{children:(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.th,{children:`判断項目`}),(0,i.jsx)(t.th,{children:`DeepSeek直結`}),(0,i.jsx)(t.th,{children:`BeatAPI`})]})}),(0,i.jsxs)(t.tbody,{children:[(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`キーの作成場所`}),(0,i.jsx)(t.td,{children:(0,i.jsx)(t.a,{href:`https://platform.deepseek.com/api_keys`,children:`DeepSeek API Keys`})}),(0,i.jsx)(t.td,{children:(0,i.jsx)(t.a,{href:`/ja/dashboard/apikeys`,children:`BeatAPI Dashboard → API Keys`})})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`OpenAI互換のBase URL`}),(0,i.jsx)(t.td,{children:(0,i.jsx)(t.code,{children:`https://api.deepseek.com`})}),(0,i.jsx)(t.td,{children:(0,i.jsx)(t.code,{children:`https://api.beatapi.io/v1`})})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`初回例のパス`}),(0,i.jsx)(t.td,{children:(0,i.jsx)(t.code,{children:`/chat/completions`})}),(0,i.jsx)(t.td,{children:(0,i.jsx)(t.code,{children:`/chat/completions`})})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`モデルIDの種類`}),(0,i.jsxs)(t.td,{children:[(0,i.jsx)(t.code,{children:`deepseek-flash`}),`;`,(0,i.jsx)(t.code,{children:`deepseek-v4-pro`}),` は移行期の公開ID`]}),(0,i.jsxs)(t.td,{children:[(0,i.jsx)(t.code,{children:`deepseek-v4-flash-0731`}),`、`,(0,i.jsx)(t.code,{children:`deepseek-v4-pro-0813`})]})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`アカウントと課金`}),(0,i.jsx)(t.td,{children:`DeepSeekのアカウント`}),(0,i.jsx)(t.td,{children:`1つのBeatAPI残高と利用ログ`})]})]})]}),`
17`,(0,i.jsxs)(t.p,{children:[`DeepSeekの公式ドキュメントは、プラットフォームでAPIキーを申請し、OpenAI互換のBase URLとして `,(0,i.jsx)(t.code,{children:`https://api.deepseek.com`}),` を使う形を示しています。`,(0,i.jsx)(t.a,{href:`/ja/deepseek-v4-flash-api`,children:`BeatAPI DeepSeek V4 Flashページ`}),`は、別のゲートウェイ、キー、公開ID、トークン課金を説明しています。一方のサービスで作ったキーを、もう一方のエンドポイントの認証に使うことはできません。`]}),`
18`,(0,i.jsxs)(t.p,{children:[`どちらの経路でも、認証情報は環境変数に置きます。ブラウザのJavaScript、モバイルアプリのバンドル、公開リポジトリ、URLのクエリ、スクリーンショットへ入れないでください。BeatAPIの`,(0,i.jsx)(t.a,{href:`https://docs.beatapi.io/faq/keys-security`,children:`キーとセキュリティのガイド`}),`は、アプリケーションと環境ごとにキーを分ける運用を勧めています。`]}),`
19`,(0,i.jsx)(t.pre,{children:(0,i.jsx)(t.code,{className:`language-bash`,children:`# このシェルでは経路を1つだけ選びます。
20export DEEPSEEK_API_KEY="replace-with-a-direct-deepseek-key"
21# BeatAPIを使う場合はこちらです。
22export BEATAPI_API_KEY="replace-with-a-beatapi-key"
23`})}),`
24`,(0,i.jsxs)(t.p,{children:[`変数名は任意ですが、通信上は `,(0,i.jsx)(t.code,{children:`Authorization: Bearer ...`}),` ヘッダーが必要です。キーをリクエスト本文に入れないでください。`]}),`
25`,(0,i.jsx)(t.h2,{children:`OpenAIクライアントで最初の呼び出しを行う`}),`
26`,(0,i.jsx)(t.p,{children:`DeepSeek直結の経路はOpenAI互換です。最初は短いプロンプトを使った非ストリーミングのチャット補完にすると、認証、Base URL、モデルIDを切り分けやすくなります。`}),`
27`,(0,i.jsx)(t.pre,{children:(0,i.jsx)(t.code,{className:`language-python`,children:`# pip install openai
28import os
29from openai import OpenAI
30
31client = OpenAI(
32    api_key=os.environ["DEEPSEEK_API_KEY"],
33    base_url="https://api.deepseek.com",
34)
35
36response = client.chat.completions.create(
37    model="deepseek-flash",
38    messages=[
39        {"role": "user", "content": "Reply with the word READY."},
40    ],
41    stream=False,
42)
43
44print(response.choices[0].message.content)
45`})}),`
46`,(0,i.jsxs)(t.p,{children:[`同じクライアントの形でBeatAPIも呼べますが、認証情報、Base URL、モデルIDの `,(0,i.jsx)(t.strong,{children:`3つ`}),` をまとめて変更します。`]}),`
47`,(0,i.jsx)(t.pre,{children:(0,i.jsx)(t.code,{className:`language-python`,children:`from openai import OpenAI
48import os
49
50client = OpenAI(
51    api_key=os.environ["BEATAPI_API_KEY"],
52    base_url="https://api.beatapi.io/v1",
53)
54
55response = client.chat.completions.create(
56    model="deepseek-v4-flash-0731",
57    messages=[{"role": "user", "content": "Reply with the word READY."}],
58    stream=False,
59)
60print(response.choices[0].message.content)
61`})}),`
62`,(0,i.jsx)(t.p,{children:`HTTPの疎通確認を直接行う場合も、同じ対応関係を守ります。`}),`
63`,(0,i.jsx)(t.pre,{children:(0,i.jsx)(t.code,{className:`language-bash`,children:`curl https://api.beatapi.io/v1/chat/completions \\
64  -H "Authorization: Bearer $BEATAPI_API_KEY" \\
65  -H "Content-Type: application/json" \\
66  -d '{
67    "model": "deepseek-v4-flash-0731",
68    "messages": [{"role": "user", "content": "Reply with READY."}],
69    "stream": false
70  }'
71`})}),`
72`,(0,i.jsxs)(t.p,{children:[`初回は `,(0,i.jsx)(t.code,{children:`stream: false`}),` にして、完全な応答を確認します。経路が動いた後で、ストリーミング、タイムアウト、再試行、利用量の記録を順番に追加してください。タイムアウトだけでモデルIDの誤りとは判断できません。`]}),`
73`,(0,i.jsx)(t.h2,{children:`モデルIDを推測せずに対応付ける`}),`
74`,(0,i.jsx)(t.p,{children:`今回の別名の違いは、経路を分ければ問題になりません。`}),`
75`,(0,i.jsxs)(t.table,{children:[(0,i.jsx)(t.thead,{children:(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.th,{children:`呼び出す先`}),(0,i.jsx)(t.th,{children:`使用するID`}),(0,i.jsx)(t.th,{children:`避けること`})]})}),(0,i.jsxs)(t.tbody,{children:[(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`DeepSeek直結のFlash`}),(0,i.jsx)(t.td,{children:(0,i.jsx)(t.code,{children:`deepseek-flash`})}),(0,i.jsxs)(t.td,{children:[`新規実装で廃止済みの `,(0,i.jsx)(t.code,{children:`deepseek-v4-flash`}),` を使わない`]})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`DeepSeek直結のPro移行期`}),(0,i.jsx)(t.td,{children:(0,i.jsx)(t.code,{children:`deepseek-v4-pro`})}),(0,i.jsx)(t.td,{children:`2026年9月14日以降のルーティングを本番導入前に再確認する`})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`BeatAPI Text API`}),(0,i.jsxs)(t.td,{children:[(0,i.jsx)(t.code,{children:`deepseek-v4-flash-0731`}),` または `,(0,i.jsx)(t.code,{children:`deepseek-v4-pro-0813`})]}),(0,i.jsx)(t.td,{children:`日付なしの直結用別名を送らない`})]})]})]}),`
76`,(0,i.jsxs)(t.p,{children:[`DeepSeekの現行クイックスタートは `,(0,i.jsx)(t.code,{children:`deepseek-flash`}),` を使い、`,(0,i.jsx)(t.code,{children:`deepseek-v4-flash`}),` と `,(0,i.jsx)(t.code,{children:`deepseek-v4-flash-vision-exp`}),` を互換性用の旧名としています。BeatAPIは、モデルページと`,(0,i.jsx)(t.a,{href:`https://docs.beatapi.io/text-api/deepseek`,children:`Text APIのDeepSeekドキュメント`}),`でバージョン付きの公開IDを示しています。これは優劣ではなく、2つのAPI面におけるルーティングの違いです。`]}),`
77`,(0,i.jsx)(t.p,{children:`失敗時は、選んだ経路、モデルID、エンドポイント、レスポンスのリクエストIDをログに残します。ただし、キーや秘密情報を含むプロンプトは保存しないでください。BeatAPIでは、リクエスト完了後に公開された利用量と決済情報を確認できます。`}),`
78`,(0,i.jsx)(t.h2,{children:`料金と経路の判断`}),`
79`,(0,i.jsx)(t.p,{children:`次の数字は、2026年9月10日に確認したBeatAPI公開カタログの標準料金です。DeepSeek直結の課金方式や料金が同一だという意味ではありません。`}),`
80`,(0,i.jsxs)(t.table,{children:[(0,i.jsx)(t.thead,{children:(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.th,{children:`必要なこと`}),(0,i.jsx)(t.th,{children:`選ぶ経路`}),(0,i.jsx)(t.th,{children:`BeatAPIで確認した目安`})]})}),(0,i.jsxs)(t.tbody,{children:[(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`DeepSeekへ直接接続する`}),(0,i.jsx)(t.td,{children:`DeepSeek直結`}),(0,i.jsx)(t.td,{children:`DeepSeek側の残高と料金表を確認`})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`Text、画像、動画を1つのアカウントで扱う`}),(0,i.jsx)(t.td,{children:`BeatAPI Flash`}),(0,i.jsx)(t.td,{children:`入力 $0.154 / キャッシュ入力 $0.0049 / 出力 $0.462(100万tokensあたり)`})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`BeatAPIで難しい推論を行う`}),(0,i.jsx)(t.td,{children:`BeatAPI Pro`}),(0,i.jsx)(t.td,{children:`入力 $0.462 / キャッシュ入力 $0.0154 / 出力 $1.386(100万tokensあたり)`})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`設定ファイルで明示的なIDを固定する`}),(0,i.jsx)(t.td,{children:`BeatAPIのバージョン付きID`}),(0,i.jsxs)(t.td,{children:[`現行カタログの `,(0,i.jsx)(t.code,{children:`-0731`}),` または `,(0,i.jsx)(t.code,{children:`-0813`}),` を使う`]})]})]})]}),`
81`,(0,i.jsx)(t.p,{children:`BeatAPIの公開Textドキュメントには、北京時間の平日09:00〜12:00と14:00〜18:00は入力、キャッシュ入力、出力の料金が2倍になると記載されています。コストを見積もる場合は、リクエスト時刻と実際の利用記録を一緒に保存してください。`}),`
82`,(0,i.jsx)(t.p,{children:`初回の小さな呼び出しでは、価格差よりも正しい経路とモデルIDの組み合わせが重要です。本番ã
82®æ¯”較では、入力tokens、キャッシュ入力、出力tokens、ピーク時間、再試行、合格した出力量を同じ条件でそろえます。`}),`
83`,(0,i.jsx)(t.h2,{children:`最初のリクエストを直す`}),`
84`,(0,i.jsxs)(t.table,{children:[(0,i.jsx)(t.thead,{children:(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.th,{children:`症状`}),(0,i.jsx)(t.th,{children:`よくある原因`}),(0,i.jsx)(t.th,{children:`修正`})]})}),(0,i.jsxs)(t.tbody,{children:[(0,i.jsxs)(t.tr,{children:[(0,i.jsxs)(t.td,{children:[(0,i.jsx)(t.code,{children:`401`}),` または認証エラー`]}),(0,i.jsxs)(t.td,{children:[`キーの違い、失効、`,(0,i.jsx)(t.code,{children:`Bearer`}),` の欠落`]}),(0,i.jsx)(t.td,{children:`選択したサービスでキーとヘッダーを確認`})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsxs)(t.td,{children:[`すべてのリクエストが `,(0,i.jsx)(t.code,{children:`404`})]}),(0,i.jsxs)(t.td,{children:[(0,i.jsx)(t.code,{children:`/v1`}),` の重複・欠落、Base URLの誤り`]}),(0,i.jsx)(t.td,{children:`クライアントごとのBase URL表に戻る`})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`モデルが見つからない`}),(0,i.jsx)(t.td,{children:`直結用IDをBeatAPIへ送った`}),(0,i.jsx)(t.td,{children:`経路とモデルIDの組をそろえる`})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`初回応答が空、または遅い`}),(0,i.jsx)(t.td,{children:`非ストリーミング、短すぎるタイムアウト`}),(0,i.jsx)(t.td,{children:`タイムアウトを見直し、後からstreamingを追加`})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`ログにキーが出る`}),(0,i.jsx)(t.td,{children:`エラーやURLへ認証情報を埋め込んだ`}),(0,i.jsx)(t.td,{children:`キーを失効し、交換してログ経路を修正`})]}),(0,i.jsxs)(t.tr,{children:[(0,i.jsx)(t.td,{children:`利用量を環境別に追えない`}),(0,i.jsx)(t.td,{children:`開発と本番で同じキーを共有`}),(0,i.jsx)(t.td,{children:`アプリと環境ごとにキーを分ける`})]})]})]}),`
85`,(0,i.jsx)(t.p,{children:`タイムアウト後に、いきなり新しいキーで再送しないでください。サーバー側で処理が作成済みかを先に確認します。重複した再送は費用を二重にし、元の結果との照合を難しくします。`}),`
86`,(0,i.jsx)(t.h2,{children:`FAQ`}),`
87`,(0,i.jsx)(t.h3,{children:`DeepSeek APIキーはどこで作成しますか?`}),`
88`,(0,i.jsx)(t.p,{children:`直接接続ならDeepSeek PlatformのAPI Keysページ、BeatAPIを使うならBeatAPI DashboardのAPI Keysページで作成します。作成したキーは同じサービスのエンドポイントでだけ使います。`}),`
89`,(0,i.jsx)(t.h3,{children:`OpenAIのPythonまたはJavaScript SDKは使えますか?`}),`
90`,(0,i.jsxs)(t.p,{children:[`はい。DeepSeek公式クイックスタートはOpenAI互換形式を案内しています。サービスに合うBase URLとモデルIDを設定し、サーバー側でキーを管理して `,(0,i.jsx)(t.code,{children:`chat.completions.create`}),` から始めます。`]}),`
91`,(0,i.jsx)(t.h3,{children:`DeepSeekの正しいBase URLは何ですか?`}),`
92`,(0,i.jsxs)(t.p,{children:[`DeepSeek直結のOpenAI互換呼び出しは `,(0,i.jsx)(t.code,{children:`https://api.deepseek.com`}),`、BeatAPIのOpenAI互換呼び出しは `,(0,i.jsx)(t.code,{children:`https://api.beatapi.io/v1`}),` です。`]}),`
93`,(0,i.jsx)(t.h3,{children:`モデルIDが違って見えるのはなぜですか?`}),`
94`,(0,i.jsxs)(t.p,{children:[`DeepSeek直結は現在 `,(0,i.jsx)(t.code,{children:`deepseek-flash`}),` を推奨し、BeatAPIは `,(0,i.jsx)(t.code,{children:`deepseek-v4-flash-0731`}),` のようなバージョン付きカタログIDを使います。別のAPI面に属するためです。旧名の `,(0,i.jsx)(t.code,{children:`deepseek-v4-flash`}),` は廃止済みモデルの互換別名です。`]}),`
95`,(0,i.jsx)(t.h3,{children:`キーをフロントエンドに置いてもよいですか?`}),`
96`,(0,i.jsx)(t.p,{children:`いいえ。サーバー側の環境変数に置き、認証ヘッダーで送ります。公開してしまった場合は、交換する前に失効させてください。`}),`
97`,(0,i.jsx)(t.h3,{children:`BeatAPIでDeepSeek専用キーが必要ですか?`}),`
98`,(0,i.jsx)(t.p,{children:`必要ありません。BeatAPIの公開製品ページでは、1つのBeatAPIキーとUSD残高で対応ã
98™ã‚‹Text、画像、動画、Workflow、Effect、Realtime APIを扱えると説明しています。ただしモデルIDは現行の公開IDを使います。`}),`
99`,(0,i.jsx)(t.h3,{children:`現在の料金はどこで確認しますか?`}),`
100`,(0,i.jsxs)(t.p,{children:[(0,i.jsx)(t.a,{href:`/ja/pricing`,children:`BeatAPI料金ページ`}),`と`,(0,i.jsx)(t.a,{href:`/ja/deepseek-v4-flash-api`,children:`DeepSeek V4 Flash APIページ`}),`を呼び出し時点で確認してください。この記事の数字は確認日時点の値であり、恒久的な料金表ではありません。`]}),`
101`,(0,i.jsx)(t.p,{children:`次に行うことはシンプルです。サービスを1つ選び、サーバー側キーを1つ作り、対応するモデルIDで小さなリクエストを送り、その後で本番用の再試行や同時実行制御を追加してください。`}),`
102`,(0,i.jsxs)(t.p,{children:[`初回呼び出しではなく既存のOpenAIクライアントを移行する場合は、`,(0,i.jsx)(t.a,{href:`/ja/blog/deepseek-api-openai-sdk-migration`,children:`OpenAI SDKからDeepSeekへの移行ガイド`}),`で、旧ID、応答動作、ストリーミング、ツール、切り戻しを別々に確認してください。`]})]})}function s(e={}){let{wrapper:t}={...n(),...e.components};return t?(0,i.jsx)(t,{...e,children:(0,i.jsx)(o,{...e})}):o(e)}export{a as n,r as t};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.