Skip to content

Commit e62bf56

Browse files
docs: note setDefaultOpenAIKey in quickstart (#76)
1 parent 8d2930a commit e62bf56

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

docs/src/content/docs/guides/quickstart.mdx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,10 @@ import quickstartExample from '../../../../../examples/docs/quickstart/index.ts?
3131
export OPENAI_API_KEY=sk-...
3232
```
3333

34+
Alternatively you can call `setDefaultOpenAIKey('<api key>')` to set the key
35+
programmatically and use `setTracingExportApiKey('<api key>')` for tracing.
36+
See [the config guide](/openai-agents-js/guides/config) for more details.
37+
3438
</Steps>
3539

3640
## Create your first agent

docs/src/content/docs/ja/guides/quickstart.mdx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@ import quickstartExample from '../../../../../../examples/docs/quickstart/index.
3131
export OPENAI_API_KEY=sk-...
3232
```
3333

34+
代わりに `setDefaultOpenAIKey('<api key>')` を呼び出して API キーを設定することもできます。トレーシング用には `setTracingExportApiKey('<api key>')` を使用してください。詳しくは [設定ガイド](/openai-agents-js/ja/guides/config) をご覧ください。
35+
3436
</Steps>
3537

3638
## 最初のエージェントの作成

0 commit comments

Comments
 (0)