> For the complete documentation index, see [llms.txt](https://gitbook.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://gitbook.com/docs/documentation/zh/creating-content/blocks/embed-a-url.md).

# 嵌入式 URL

要添加嵌入式 URL，只需粘贴你想嵌入的内容链接并点击 `Enter`.

{% hint style="info" %}
**注意：** 你想嵌入的内容必须是公开可访问的，这样 GitBook 才能访问该文件。例如，嵌入 Google 文档时，共享设置必须设为 *任何知道链接的人*.
{% endhint %}

### 视频

{% embed url="<https://www.youtube.com/watch?v=D_uLM5i0Z4c>" %}

{% hint style="info" %}
**注意：** 你可以通过添加以下内容来让 YouTube 和 Vimeo 嵌入自动播放并循环播放 `?autoplay=1&loop=1` 到视频 URL 的末尾。
{% endhint %}

### Codepen

{% embed url="<https://codepen.io/davidkpiano/pen/wMqXea>" %}

### Spotify

{% embed url="<https://open.spotify.com/track/4FmiciU3ZmfgABlbCSXcWw?si=65zMAhStT2ivTit-kZISWg>" %}

### Markdown 中的表示

```markdown
{% embed url="URL_HERE" %}
```


---

# 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://gitbook.com/docs/documentation/zh/creating-content/blocks/embed-a-url.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.
