TextBlock
The TextBlock
type represents a block of text. It can be part of a larger document or stand alone.
Schema
Field | Type | Description |
---|---|---|
id | string | Unique identifier |
createdAt | datetime | Creation timestamp |
updatedAt | datetime | Last update timestamp |
sourceId | string | ID of the data source |
remoteId | string | ID in original system |
text | string | Text content |
html | string | HTML content |
tagName | string | HTML tag name |
classNames | string[] | HTML class names |
order | number | Block order |
properties | object | Additional properties |
Related Types
Example Usage
// Get all text blocks
const { data } = await unbody.get
.textBlock
.select("text", "tagName", "order")
.exec();
// Search text blocks
const { data } = await unbody.get
.textBlock
.search.about("my search query")
.exec();
// Filter text blocks
const { data } = await unbody.get
.textBlock
.where({ tagName: "p" })
.exec();
Next Steps
- Learn about searching text blocks
- Explore filtering options
- See sorting capabilities