> For the complete documentation index, see [llms.txt](https://ai-docs.fptcloud.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://ai-docs.fptcloud.com/ai-factory-guideline-jp/fpt-ai-studio/sbisu/moderutesuto-sesshon/chtoriaru/moderuno-1.md).

# モデルの統合方法

{% hint style="info" %}
注：セッションのステータスが RUNNING の場合、Get API Endpoint が有効になります
{% endhint %}

<figure><img src="/files/vGT1ucGgKqLlJRa3iieX" alt=""><figcaption></figcaption></figure>

{% stepper %}
{% step %}

### 必要な情報を取得する

提供内容：

<table><thead><tr><th width="132.59991455078125">オブジェクト</th><th>説明</th></tr></thead><tbody><tr><td>エンドポイントURL</td><td>アプリケーションがサービスとやり取りするためにリクエストを送信するアドレス。</td></tr><tr><td>ベアラートークン</td><td><p>APIへのアクセス権限を証明する文字列。 </p><p>注意:</p><ul><li>トークンをパブリックなコードやリポジトリに 公開しないでください。</li><li>環境変数やセキュアな保管庫に保管してく ださい。</li></ul></td></tr><tr><td>モデル</td><td>インタラクティブセッションズプラットフォーム上でホストされている特定のAIモデルを一意に識別する識別子。</td></tr><tr><td>サンプルコード</td><td><p>詳細情報（以下を含む）：</p><ul><li>エンドポイントURL</li><li>ベアラートークン</li><li>モデルID</li><li>メッセージ（システム、ユーザー、アシスタント）</li><li>温度</li></ul></td></tr></tbody></table>
{% endstep %}

{% step %}

### 統合プラットフォームを選択

{% endstep %}

{% step %}

### APIにリクエストを送信

Pythonを使用した例：

```json
import requests
url = "https://api.gptcloud.com/aiam/v1/chat/completions"
headers = {
    "Content-Type": "application/json",
    "Authorization": "Bearer pR2vV0zGZ0nP6tQ3gFJk9wXn0"
}
payload = {
    "model": "62d8b2e6-42f9-4c17-95f8-4ca93d74f396",
    "messages": [
        {"role": "system", "content": "You are a helpful assistant."},
        {"role": "user", "content": "Hello!"}
    ],
    "temperature": 0.7
}
response = requests.post(url, headers=headers, json=payload)
print(response.json())
```

{% endstep %}
{% endstepper %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://ai-docs.fptcloud.com/ai-factory-guideline-jp/fpt-ai-studio/sbisu/moderutesuto-sesshon/chtoriaru/moderuno-1.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
