> For the complete documentation index, see [llms.txt](https://docs.apryse.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.apryse.com/core/create/document-creation-api/floats.md).

# Floats

Use the doc creation API to create float programmatically in a doc.

A `Float` takes its content out of the main document flow and positions it relative to a reference point, with the surrounding content wrapped around it. Floats are how you build [pull quotes](https://en.wikipedia.org/wiki/Pull_quote), side figures, watermarks, and logos that do not disturb the text they sit next to.

{% hint style="info" %}
**Info**

The float class is named `Float` in most languages, `FloatContainer` in PHP and Ruby, `PTFloat` in Objective-C, and `PDFNet.Float` in JavaScript.
{% endhint %}

## Create a float

`AddFloat` creates a float anchored at a paragraph. The returned object is a content container, so you fill it exactly like a document.

{% tabs %}
{% tab title="C#" %}
{% code lineNumbers="true" %}

```csharp
Paragraph para = doc.AddParagraph();

// The float is taken out of the main flow; the paragraph text wraps around it.
Float box = para.AddFloat();
box.SetHorizontalReferencePoint(Float.FloatReferencePoint.e_reference_page);
box.SetVerticalReferencePoint(Float.FloatReferencePoint.e_reference_paragraph);
box.SetPositionX(270);
box.SetPositionY(0);
box.SetObstructionType(Float.FloatObstructionType.e_square);
box.AddParagraph().AddImage(90, 90, input_path + "butterfly.png");

para.AddText("Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do " +
             "eiusmod tempor incididunt ut labore et dolore magna aliqua.");
```

{% endcode %}
{% endtab %}

{% tab title="C++" %}
{% code lineNumbers="true" %}

```cpp
Paragraph para = doc.AddParagraph();

// The float is taken out of the main flow; the paragraph text wraps around it.
Float box = para.AddFloat();
box.SetHorizontalReferencePoint(Float::e_reference_page);
box.SetVerticalReferencePoint(Float::e_reference_paragraph);
box.SetPositionX(270);
box.SetPositionY(0);
box.SetObstructionType(Float::e_square);
box.AddParagraph().AddImage(90, 90, input_path + "butterfly.png");

para.AddText("Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do "
             "eiusmod tempor incididunt ut labore et dolore magna aliqua.");
```

{% endcode %}
{% endtab %}

{% tab title="Go" %}
{% code lineNumbers="true" %}

```go
para := doc.AddParagraph()

// The float is taken out of the main flow; the paragraph text wraps around it.
box := para.AddFloat()
box.SetHorizontalReferencePoint(FloatE_reference_page)
box.SetVerticalReferencePoint(FloatE_reference_paragraph)
box.SetPositionX(270)
box.SetPositionY(0)
box.SetObstructionType(FloatE_square)
box.AddParagraph().AddImage(90, 90, inputPath+"butterfly.png")

para.AddText("Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do " +
    "eiusmod tempor incididunt ut labore et dolore magna aliqua.")
```

{% endcode %}
{% endtab %}

{% tab title="Java" %}
{% code lineNumbers="true" %}

```java
Paragraph para = doc.addParagraph();

// The float is taken out of the main flow; the paragraph text wraps around it.
Float box = para.addFloat();
box.setHorizontalReferencePoint(Float.ReferencePoint.e_reference_page);
box.setVerticalReferencePoint(Float.ReferencePoint.e_reference_paragraph);
box.setPositionX(270);
box.setPositionY(0);
box.setObstructionType(Float.ObstructionType.e_square);
box.addParagraph().addImage(90, 90, input_path + "butterfly.png");

para.addText("Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do "
        + "eiusmod tempor incididunt ut labore et dolore magna aliqua.");
```

{% endcode %}
{% endtab %}

{% tab title="JavaScript" %}
{% code lineNumbers="true" %}

```javascript
const para = await doc.addParagraph();

// The float is taken out of the main flow; the paragraph text wraps around it.
const box = await para.addFloat();
box.setHorizontalReferencePoint(PDFNet.Float.ReferencePoint.e_reference_page);
box.setVerticalReferencePoint(PDFNet.Float.ReferencePoint.e_reference_paragraph);
box.setPositionX(270);
box.setPositionY(0);
box.setObstructionType(PDFNet.Float.ObstructionType.e_square);
await (await box.addParagraph()).addImage(90, 90, inputPath + 'butterfly.png');

await para.addText('Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do ' +
    'eiusmod tempor incididunt ut labore et dolore magna aliqua.');
```

{% endcode %}
{% endtab %}

{% tab title="Obj-C" %}
{% code lineNumbers="true" %}

```objectivec
PTParagraph* para = [doc AddParagraph];

// The float is taken out of the main flow; the paragraph text wraps around it.
PTFloat* box = [para AddFloat];
[box SetHorizontalReferencePoint:e_ptfloat_reference_page];
[box SetVerticalReferencePoint:e_ptfloat_reference_paragraph];
[box SetPositionX:270];
[box SetPositionY:0];
[box SetObstructionType:e_ptfloat_square];
[[box AddParagraph] AddImageWithPath:90 height:90
                                path:[input_path stringByAppendingString:@"butterfly.png"]];

[para AddText:@"Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do "
               "eiusmod tempor incididunt ut labore et dolore magna aliqua."];
```

{% endcode %}
{% endtab %}

{% tab title="PHP" %}
{% code lineNumbers="true" %}

```php
$para = $doc->AddParagraph();

// The float is taken out of the main flow; the paragraph text wraps around it.
$box = $para->AddFloat();
$box->SetHorizontalReferencePoint(FloatContainer::e_reference_page);
$box->SetVerticalReferencePoint(FloatContainer::e_reference_paragraph);
$box->SetPositionX(270);
$box->SetPositionY(0);
$box->SetObstructionType(FloatContainer::e_square);
$box->AddParagraph()->AddImage(90, 90, $input_path."butterfly.png");

$para->AddText("Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do " .
               "eiusmod tempor incididunt ut labore et dolore magna aliqua.");
```

{% endcode %}
{% endtab %}

{% tab title="Python" %}
{% code lineNumbers="true" %}

```python
para = doc.AddParagraph()

# The float is taken out of the main flow; the paragraph text wraps around it.
box = para.AddFloat()
box.SetHorizontalReferencePoint(Float.e_reference_page)
box.SetVerticalReferencePoint(Float.e_reference_paragraph)
box.SetPositionX(270)
box.SetPositionY(0)
box.SetObstructionType(Float.e_square)
box.AddParagraph().AddImage(90, 90, input_path + "butterfly.png")

para.AddText("Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do "
             "eiusmod tempor incididunt ut labore et dolore magna aliqua.")
```

{% endcode %}
{% endtab %}

{% tab title="Ruby" %}
{% code lineNumbers="true" %}

```ruby
para = doc.AddParagraph()

# The float is taken out of the main flow; the paragraph text wraps around it.
box = para.AddFloat()
box.SetHorizontalReferencePoint(FloatContainer::E_reference_page)
box.SetVerticalReferencePoint(FloatContainer::E_reference_paragraph)
box.SetPositionX(270)
box.SetPositionY(0)
box.SetObstructionType(FloatContainer::E_square)
box.AddParagraph().AddImage(90, 90, input_path + "butterfly.png")

para.AddText("Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do " +
             "eiusmod tempor incididunt ut labore et dolore magna aliqua.")
```

{% endcode %}
{% endtab %}
{% endtabs %}

<figure><img src="https://3779731113-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fziw3GiL98Xfj63F3He8h%2Fuploads%2FlgKfPKEHBfL80bu3swTp%2Ffloat_square.png?alt=media&amp;token=cb194052-025a-4a06-af2a-0c2c65c6ac4c" alt="Example of a float with image of a blue butterfly positioned over text."><figcaption></figcaption></figure>

The float is created **before** the text is added, but the order does not matter: floats are positioned independently of their place in the paragraph.

## Reference points

The horizontal and vertical positions are measured from separately chosen reference points, set with `SetHorizontalReferencePoint` and `SetVerticalReferencePoint`.

| Value                   | Position is measured from                                            |
| ----------------------- | -------------------------------------------------------------------- |
| `e_reference_page`      | The page edge. Use for content pinned to a fixed spot on the page.   |
| `e_reference_paragraph` | The anchoring paragraph. Use for content that travels with the text. |
| `e_reference_character` | The exact anchor position within the text.                           |

Mixing reference points in a document is common: a page reference horizontally puts the float in a fixed column, while a paragraph reference vertically keeps it beside the text it belongs to, even when that text moves to another page.

`SetPositionX` and `SetPositionY` give the offset in points from the chosen reference points. Y grows downwards.

## Obstruction types

`SetObstructionType` controls how the main content reacts to the float.

| Value                | Effect                                           |
| -------------------- | ------------------------------------------------ |
| `e_square`           | Text wraps around the float's bounding box.      |
| `e_tight`            | Text wraps closely around the float's outline.   |
| `e_top_and_bottom`   | Text stops above the float and resumes below it. |
| `e_behind_text`      | No wrapping; the float is drawn behind the text. |
| `e_in_front_of_text` | No wrapping; the float is drawn over the text.   |

`e_behind_text` is the usual choice for watermarks and background artwork, since it leaves the layout of the main content untouched.

## Common patterns

There are common patterns used with documents, including patterns around pull quotes and watermarks.

### Pull quote

Combine a float with a shape text box to get a styled callout beside the article text.

{% tabs %}
{% tab title="C#" %}
{% code lineNumbers="true" %}

```csharp
Float pullQuote = lead.AddFloat();
pullQuote.SetHorizontalReferencePoint(Float.FloatReferencePoint.e_reference_page);
pullQuote.SetVerticalReferencePoint(Float.FloatReferencePoint.e_reference_paragraph);
pullQuote.SetPositionX(380);
pullQuote.SetPositionY(10);
pullQuote.SetObstructionType(Float.FloatObstructionType.e_square);

Shape quoteBox = pullQuote.AddParagraph()
    .AddShape(Shape.ShapeType.e_rectangle_rounded_corners, 190, 70);
quoteBox.SetCornerRadius(6);
quoteBox.SetBackgroundColor(240, 246, 255);

Paragraph quote = quoteBox.GetTextBox().AddParagraph(
    "\"The content tree lets you describe a document, not a page.\"");
quote.GetTextStyledElement().SetItalic(true);
```

{% endcode %}
{% endtab %}

{% tab title="C++" %}
{% code lineNumbers="true" %}

```cpp
Float pull_quote = lead.AddFloat();
pull_quote.SetHorizontalReferencePoint(Float::e_reference_page);
pull_quote.SetVerticalReferencePoint(Float::e_reference_paragraph);
pull_quote.SetPositionX(380);
pull_quote.SetPositionY(10);
pull_quote.SetObstructionType(Float::e_square);

Shape quote_box = pull_quote.AddParagraph()
    .AddShape(Shape::e_rectangle_rounded_corners, 190, 70);
quote_box.SetCornerRadius(6);
quote_box.SetBackgroundColor(240, 246, 255);

Paragraph quote = quote_box.GetTextBox().AddParagraph(
    "\"The content tree lets you describe a document, not a page.\"");
quote.GetTextStyledElement().SetItalic(true);
```

{% endcode %}
{% endtab %}

{% tab title="Go" %}
{% code lineNumbers="true" %}

```go
pullQuote := lead.AddFloat()
pullQuote.SetHorizontalReferencePoint(FloatE_reference_page)
pullQuote.SetVerticalReferencePoint(FloatE_reference_paragraph)
pullQuote.SetPositionX(380)
pullQuote.SetPositionY(10)
pullQuote.SetObstructionType(FloatE_square)

quoteBox := pullQuote.AddParagraph().
    AddShape(ShapeE_rectangle_rounded_corners, 190, 70)
quoteBox.SetCornerRadius(6)
quoteBox.SetBackgroundColor(240, 246, 255)

quote := quoteBox.GetTextBox().AddParagraph(
    "\"The content tree lets you describe a document, not a page.\"")
quote.GetTextStyledElement().SetItalic(true)
```

{% endcode %}
{% endtab %}

{% tab title="Java" %}
{% code lineNumbers="true" %}

```java
Float pullQuote = lead.addFloat();
pullQuote.setHorizontalReferencePoint(Float.ReferencePoint.e_reference_page);
pullQuote.setVerticalReferencePoint(Float.ReferencePoint.e_reference_paragraph);
pullQuote.setPositionX(380);
pullQuote.setPositionY(10);
pullQuote.setObstructionType(Float.ObstructionType.e_square);

Shape quoteBox = pullQuote.addParagraph()
        .addShape(Shape.ShapeType.e_rectangle_rounded_corners, 190, 70);
quoteBox.setCornerRadius(6);
quoteBox.setBackgroundColor(240, 246, 255);

Paragraph quote = quoteBox.getTextBox().addParagraph(
        "\"The content tree lets you describe a document, not a page.\"");
quote.getTextStyledElement().setItalic(true);
```

{% endcode %}
{% endtab %}

{% tab title="JavaScript" %}
{% code lineNumbers="true" %}

```javascript
const pullQuote = await lead.addFloat();
pullQuote.setHorizontalReferencePoint(PDFNet.Float.ReferencePoint.e_reference_page);
pullQuote.setVerticalReferencePoint(PDFNet.Float.ReferencePoint.e_reference_paragraph);
pullQuote.setPositionX(380);
pullQuote.setPositionY(10);
pullQuote.setObstructionType(PDFNet.Float.ObstructionType.e_square);

const quoteBox = await (await pullQuote.addParagraph())
    .addShape(PDFNet.Shape.Type.e_rectangle_rounded_corners, 190, 70);
quoteBox.setCornerRadius(6);
quoteBox.setBackgroundColor(240, 246, 255);

const quote = await (await quoteBox.getTextBox()).addParagraphWithText(
    '"The content tree lets you describe a document, not a page."');
(await quote.getTextStyledElement()).setItalic(true);
```

{% endcode %}
{% endtab %}

{% tab title="Obj-C" %}
{% code lineNumbers="true" %}

```objectivec
PTFloat* pull_quote = [lead AddFloat];
[pull_quote SetHorizontalReferencePoint:e_ptfloat_reference_page];
[pull_quote SetVerticalReferencePoint:e_ptfloat_reference_paragraph];
[pull_quote SetPositionX:380];
[pull_quote SetPositionY:10];
[pull_quote SetObstructionType:e_ptfloat_square];

PTShape* quote_box = [[pull_quote AddParagraph]
    AddShape:e_ptshape_rectangle_rounded_corners width:190 height:70];
[quote_box SetCornerRadius:6];
[quote_box SetBackgroundColor:240 green:246 blue:255];

PTParagraph* quote = [[quote_box GetTextBox] AddParagraphWithText:
    @"\"The content tree lets you describe a document, not a page.\""];
[[quote GetTextStyledElement] SetItalic:YES];
```

{% endcode %}
{% endtab %}

{% tab title="PHP" %}
{% code lineNumbers="true" %}

```php
$pull_quote = $lead->AddFloat();
$pull_quote->SetHorizontalReferencePoint(FloatContainer::e_reference_page);
$pull_quote->SetVerticalReferencePoint(FloatContainer::e_reference_paragraph);
$pull_quote->SetPositionX(380);
$pull_quote->SetPositionY(10);
$pull_quote->SetObstructionType(FloatContainer::e_square);

$quote_box = $pull_quote->AddParagraph()
    ->AddShape(Shape::e_rectangle_rounded_corners, 190, 70);
$quote_box->SetCornerRadius(6);
$quote_box->SetBackgroundColor(240, 246, 255);

$quote = $quote_box->GetTextBox()->AddParagraph(
    "\"The content tree lets you describe a document, not a page.\"");
$quote->GetTextStyledElement()->SetItalic(true);
```

{% endcode %}
{% endtab %}

{% tab title="Python" %}
{% code lineNumbers="true" %}

```python
pull_quote = lead.AddFloat()
pull_quote.SetHorizontalReferencePoint(Float.e_reference_page)
pull_quote.SetVerticalReferencePoint(Float.e_reference_paragraph)
pull_quote.SetPositionX(380)
pull_quote.SetPositionY(10)
pull_quote.SetObstructionType(Float.e_square)

quote_box = pull_quote.AddParagraph().AddShape(
    Shape.e_rectangle_rounded_corners, 190, 70)
quote_box.SetCornerRadius(6)
quote_box.SetBackgroundColor(240, 246, 255)

quote = quote_box.GetTextBox().AddParagraph(
    "\"The content tree lets you describe a document, not a page.\"")
quote.GetTextStyledElement().SetItalic(True)
```

{% endcode %}
{% endtab %}

{% tab title="Ruby" %}
{% code lineNumbers="true" %}

```ruby
pull_quote = lead.AddFloat()
pull_quote.SetHorizontalReferencePoint(FloatContainer::E_reference_page)
pull_quote.SetVerticalReferencePoint(FloatContainer::E_reference_paragraph)
pull_quote.SetPositionX(380)
pull_quote.SetPositionY(10)
pull_quote.SetObstructionType(FloatContainer::E_square)

quote_box = pull_quote.AddParagraph().AddShape(
  Shape::E_rectangle_rounded_corners, 190, 70)
quote_box.SetCornerRadius(6)
quote_box.SetBackgroundColor(240, 246, 255)

quote = quote_box.GetTextBox().AddParagraph(
  "\"The content tree lets you describe a document, not a page.\"")
quote.GetTextStyledElement().SetItalic(true)
```

{% endcode %}
{% endtab %}
{% endtabs %}

### Watermark

{% tabs %}
{% tab title="C#" %}
{% code lineNumbers="true" %}

```csharp
Float watermark = doc.AddParagraph().AddFloat();
watermark.SetHorizontalReferencePoint(Float.FloatReferencePoint.e_reference_page);
watermark.SetVerticalReferencePoint(Float.FloatReferencePoint.e_reference_page);
watermark.SetPositionX(150);
watermark.SetPositionY(300);
watermark.SetObstructionType(Float.FloatObstructionType.e_behind_text);

TextStyledElement style = watermark.AddParagraph("DRAFT").GetTextStyledElement();
style.SetFontSize(72);
style.SetBold(true);
style.SetTextColor(230, 230, 230);
```

{% endcode %}
{% endtab %}

{% tab title="C++" %}
{% code lineNumbers="true" %}

```cpp
Float watermark = doc.AddParagraph().AddFloat();
watermark.SetHorizontalReferencePoint(Float::e_reference_page);
watermark.SetVerticalReferencePoint(Float::e_reference_page);
watermark.SetPositionX(150);
watermark.SetPositionY(300);
watermark.SetObstructionType(Float::e_behind_text);

TextStyledElement style = watermark.AddParagraph("DRAFT").GetTextStyledElement();
style.SetFontSize(72);
style.SetBold(true);
style.SetTextColor(230, 230, 230);
```

{% endcode %}
{% endtab %}

{% tab title="Go" %}
{% code lineNumbers="true" %}

```go
watermark := doc.AddParagraph().AddFloat()
watermark.SetHorizontalReferencePoint(FloatE_reference_page)
watermark.SetVerticalReferencePoint(FloatE_reference_page)
watermark.SetPositionX(150)
watermark.SetPositionY(300)
watermark.SetObstructionType(FloatE_behind_text)

style := watermark.AddParagraph("DRAFT").GetTextStyledElement()
style.SetFontSize(72)
style.SetBold(true)
style.SetTextColor(230, 230, 230)
```

{% endcode %}
{% endtab %}

{% tab title="Java" %}
{% code lineNumbers="true" %}

```java
Float watermark = doc.addParagraph().addFloat();
watermark.setHorizontalReferencePoint(Float.ReferencePoint.e_reference_page);
watermark.setVerticalReferencePoint(Float.ReferencePoint.e_reference_page);
watermark.setPositionX(150);
watermark.setPositionY(300);
watermark.setObstructionType(Float.ObstructionType.e_behind_text);

TextStyledElement style = watermark.addParagraph("DRAFT").getTextStyledElement();
style.setFontSize(72);
style.setBold(true);
style.setTextColor(230, 230, 230);
```

{% endcode %}
{% endtab %}

{% tab title="JavaScript" %}
{% code lineNumbers="true" %}

```javascript
const watermark = await (await doc.addParagraph()).addFloat();
watermark.setHorizontalReferencePoint(PDFNet.Float.ReferencePoint.e_reference_page);
watermark.setVerticalReferencePoint(PDFNet.Float.ReferencePoint.e_reference_page);
watermark.setPositionX(150);
watermark.setPositionY(300);
watermark.setObstructionType(PDFNet.Float.ObstructionType.e_behind_text);

const style = await (await watermark.addParagraphWithText('DRAFT')).getTextStyledElement();
style.setFontSize(72);
style.setBold(true);
style.setTextColor(230, 230, 230);
```

{% endcode %}
{% endtab %}

{% tab title="Obj-C" %}
{% code lineNumbers="true" %}

```objectivec
PTFloat* watermark = [[doc AddParagraph] AddFloat];
[watermark SetHorizontalReferencePoint:e_ptfloat_reference_page];
[watermark SetVerticalReferencePoint:e_ptfloat_reference_page];
[watermark SetPositionX:150];
[watermark SetPositionY:300];
[watermark SetObstructionType:e_ptfloat_behind_text];

PTTextStyledElement* style =
    [[watermark AddParagraphWithText:@"DRAFT"] GetTextStyledElement];
[style SetFontSize:72];
[style SetBold:YES];
[style SetTextColor:230 green:230 blue:230];
```

{% endcode %}
{% endtab %}

{% tab title="PHP" %}
{% code lineNumbers="true" %}

```php
$watermark = $doc->AddParagraph()->AddFloat();
$watermark->SetHorizontalReferencePoint(FloatContainer::e_reference_page);
$watermark->SetVerticalReferencePoint(FloatContainer::e_reference_page);
$watermark->SetPositionX(150);
$watermark->SetPositionY(300);
$watermark->SetObstructionType(FloatContainer::e_behind_text);

$style = $watermark->AddParagraph("DRAFT")->GetTextStyledElement();
$style->SetFontSize(72);
$style->SetBold(true);
$style->SetTextColor(230, 230, 230);
```

{% endcode %}
{% endtab %}

{% tab title="Python" %}
{% code lineNumbers="true" %}

```python
watermark = doc.AddParagraph().AddFloat()
watermark.SetHorizontalReferencePoint(Float.e_reference_page)
watermark.SetVerticalReferencePoint(Float.e_reference_page)
watermark.SetPositionX(150)
watermark.SetPositionY(300)
watermark.SetObstructionType(Float.e_behind_text)

style = watermark.AddParagraph("DRAFT").GetTextStyledElement()
style.SetFontSize(72)
style.SetBold(True)
style.SetTextColor(230, 230, 230)
```

{% endcode %}
{% endtab %}

{% tab title="Ruby" %}
{% code lineNumbers="true" %}

```ruby
watermark = doc.AddParagraph().AddFloat()
watermark.SetHorizontalReferencePoint(FloatContainer::E_reference_page)
watermark.SetVerticalReferencePoint(FloatContainer::E_reference_page)
watermark.SetPositionX(150)
watermark.SetPositionY(300)
watermark.SetObstructionType(FloatContainer::E_behind_text)

style = watermark.AddParagraph("DRAFT").GetTextStyledElement()
style.SetFontSize(72)
style.SetBold(true)
style.SetTextColor(230, 230, 230)
```

{% endcode %}
{% endtab %}
{% endtabs %}

## Notes

* A float is positioned during pagination, so its final location depends on where the anchoring paragraph ends up.
* Floats do not stretch the page. Content placed outside the page area is clipped.
* Several floats can be anchored to the same paragraph; position them so they do not overlap.

## Further Reading

* [Images and shapes](/core/create/document-creation-api/images-and-shapes.md) for the content usually placed inside a float.
* [Sections, headers and footers](/core/create/document-creation-api/sections-headers-and-footers.md) for content that repeats on every page instead.


---

# 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://docs.apryse.com/core/create/document-creation-api/floats.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.
