Get Data Source

Retrieves a data source schema by ID. Data sources contain the properties (schema) for database entries.

Usage #

// Import the typed helper
import { getDataSource } from "@hotglue/sdk/notion";
const result = await client.execute({
...getDataSource({
data_source_id: string,
}),
userId: "user_123",
});
// result is typed as GetDataSourceOutput
const result = await client.execute({
integration: "notion",
tool: "get_data_source",
userId: "user_123",
input: {
data_source_id: string,
},
});
// The agent will automatically use this tool when needed
const agent = new Agent({
tools: () => hotglueTools({
integrations: ["notion"],
userId: "user_123",
}),
});
await agent.generate("run the Get Data Source tool");

Required Permissions #

read_content

Input Schema #

data_source_id string required

The ID of the data source to retrieve

Output Schema #

id string required
object string required
created_time string required
last_edited_time string required
title object[]
url string

This tool calls: #

GET https://api.notion.com/v1/data_sources/{data_source_id}