KosmoKrator

meetings

Granola Lua API for KosmoKrator Agents

Agent-facing Lua documentation and function reference for the Granola KosmoKrator integration.

5 functions 3 read 2 write API key auth

Lua Namespace

Agents call this integration through app.integrations.granola.*. Use lua_read_doc("integrations.granola") inside KosmoKrator to discover the same reference at runtime.

Agent-Facing Lua Docs

This is the rendered version of the full Lua documentation exposed to agents when they inspect the integration namespace.

Granola — Lua API Reference

list_meetings

List recent meetings from Granola with optional search and filtering.

Parameters

NameTypeRequiredDescription
limitintegernoMaximum number of meetings to return (default: 20)
offsetintegernoNumber of meetings to skip for pagination
querystringnoSearch query to filter meetings by title or content
start_datestringnoStart date for filtering (ISO 8601, e.g. "2025-01-01")
end_datestringnoEnd date for filtering (ISO 8601, e.g. "2025-01-31")

Examples

List recent meetings

local result = app.integrations.granola.list_meetings({
  limit = 10
})

for _, meeting in ipairs(result.meetings) do
  print(meeting.title .. " — " .. meeting.date)
end

Search meetings by keyword

local result = app.integrations.granola.list_meetings({
  query = "Q1 review",
  limit = 5
})

Filter by date range

local result = app.integrations.granola.list_meetings({
  start_date = "2025-01-01",
  end_date = "2025-01-31",
  limit = 20
})

get_meeting

Get a single meeting with full transcript, summary, notes, and participants.

Parameters

NameTypeRequiredDescription
idstringyesThe meeting ID

Example

local result = app.integrations.granola.get_meeting({
  id = "meeting-id-123"
})

print("Title: " .. result.title)
print("Date: " .. result.date)
print("Participants: " .. table.concat(result.participants, ", "))
print("Summary: " .. result.summary)
print("Transcript: " .. result.transcript)

create_note

Create a note on a meeting. Use for follow-up notes, action items, or comments.

Parameters

NameTypeRequiredDescription
meeting_idstringyesThe meeting ID to add the note to
contentstringyesThe note content text

Example

local result = app.integrations.granola.create_note({
  meeting_id = "meeting-id-123",
  content = "Follow up with engineering on the API redesign by Friday."
})

print("Note created with ID: " .. result.id)

share_meeting

Share a meeting with other people by email.

Parameters

NameTypeRequiredDescription
meeting_idstringyesThe meeting ID to share
emailsarrayyesEmail addresses of the recipients
messagestringnoOptional message to include

Example

local result = app.integrations.granola.share_meeting({
  meeting_id = "meeting-id-123",
  emails = { "[email protected]", "[email protected]" },
  message = "Here are the notes from today's standup."
})

get_current_user

Get the profile of the currently authenticated Granola user.

Parameters

None.

Example

local result = app.integrations.granola.get_current_user({})

print("Name: " .. result.name)
print("Email: " .. result.email)

Multi-Account Usage

If you have multiple Granola accounts configured, use account-specific namespaces:

-- Default account (always works)
app.integrations.granola.function_name({...})

-- Explicit default (portable across setups)
app.integrations.granola.default.function_name({...})

-- Named accounts
app.integrations.granola.work.function_name({...})
app.integrations.granola.personal.function_name({...})

All functions are identical across accounts — only the credentials differ.

Raw agent markdown
# Granola — Lua API Reference

## list_meetings

List recent meetings from Granola with optional search and filtering.

### Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `limit` | integer | no | Maximum number of meetings to return (default: 20) |
| `offset` | integer | no | Number of meetings to skip for pagination |
| `query` | string | no | Search query to filter meetings by title or content |
| `start_date` | string | no | Start date for filtering (ISO 8601, e.g. `"2025-01-01"`) |
| `end_date` | string | no | End date for filtering (ISO 8601, e.g. `"2025-01-31"`) |

### Examples

#### List recent meetings

```lua
local result = app.integrations.granola.list_meetings({
  limit = 10
})

for _, meeting in ipairs(result.meetings) do
  print(meeting.title .. " — " .. meeting.date)
end
```

#### Search meetings by keyword

```lua
local result = app.integrations.granola.list_meetings({
  query = "Q1 review",
  limit = 5
})
```

#### Filter by date range

```lua
local result = app.integrations.granola.list_meetings({
  start_date = "2025-01-01",
  end_date = "2025-01-31",
  limit = 20
})
```

---

## get_meeting

Get a single meeting with full transcript, summary, notes, and participants.

### Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `id` | string | yes | The meeting ID |

### Example

```lua
local result = app.integrations.granola.get_meeting({
  id = "meeting-id-123"
})

print("Title: " .. result.title)
print("Date: " .. result.date)
print("Participants: " .. table.concat(result.participants, ", "))
print("Summary: " .. result.summary)
print("Transcript: " .. result.transcript)
```

---

## create_note

Create a note on a meeting. Use for follow-up notes, action items, or comments.

### Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `meeting_id` | string | yes | The meeting ID to add the note to |
| `content` | string | yes | The note content text |

### Example

```lua
local result = app.integrations.granola.create_note({
  meeting_id = "meeting-id-123",
  content = "Follow up with engineering on the API redesign by Friday."
})

print("Note created with ID: " .. result.id)
```

---

## share_meeting

Share a meeting with other people by email.

### Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `meeting_id` | string | yes | The meeting ID to share |
| `emails` | array | yes | Email addresses of the recipients |
| `message` | string | no | Optional message to include |

### Example

```lua
local result = app.integrations.granola.share_meeting({
  meeting_id = "meeting-id-123",
  emails = { "[email protected]", "[email protected]" },
  message = "Here are the notes from today's standup."
})
```

---

## get_current_user

Get the profile of the currently authenticated Granola user.

### Parameters

None.

### Example

```lua
local result = app.integrations.granola.get_current_user({})

print("Name: " .. result.name)
print("Email: " .. result.email)
```

---

## Multi-Account Usage

If you have multiple Granola accounts configured, use account-specific namespaces:

```lua
-- Default account (always works)
app.integrations.granola.function_name({...})

-- Explicit default (portable across setups)
app.integrations.granola.default.function_name({...})

-- Named accounts
app.integrations.granola.work.function_name({...})
app.integrations.granola.personal.function_name({...})
```

All functions are identical across accounts — only the credentials differ.

Metadata-Derived Lua Example

local result = app.integrations.granola.granola_list_meetings({
  limit = 1,
  offset = 1,
  query = "example_query",
  start_date = "example_start_date",
  end_date = "example_end_date"
})
print(result)

Functions

granola_list_meetings

List recent meetings from Granola. Returns meeting titles, dates, participants, and summaries. Supports search by query and date filtering.

Operation
Read read
Full name
granola.granola_list_meetings
ParameterTypeRequiredDescription
limit integer no Maximum number of meetings to return (default: 20).
offset integer no Number of meetings to skip for pagination.
query string no Search query to filter meetings by title or content.
start_date string no Start date for filtering meetings (ISO 8601, e.g., "2025-01-01").
end_date string no End date for filtering meetings (ISO 8601, e.g., "2025-01-31").

granola_get_meeting

Get a single meeting from Granola by ID. Returns the full meeting details including transcript, summary, notes, and participant list.

Operation
Read read
Full name
granola.granola_get_meeting
ParameterTypeRequiredDescription
id string yes The meeting ID.

granola_create_note

Create a note on a Granola meeting. Use this to add follow-up notes, action items, or comments to a meeting.

Operation
Write write
Full name
granola.granola_create_note
ParameterTypeRequiredDescription
meeting_id string yes The meeting ID to add the note to.
content string yes The note content text.

granola_share_meeting

Share a Granola meeting with other people. Specify email addresses of recipients and an optional message.

Operation
Write write
Full name
granola.granola_share_meeting
ParameterTypeRequiredDescription
meeting_id string yes The meeting ID to share.
emails array yes Email addresses of the recipients (e.g., ["[email protected]", "[email protected]"]).
message string no Optional message to include with the shared meeting.

granola_get_current_user

Get the profile of the currently authenticated Granola user. Returns name, email, and account details.

Operation
Read read
Full name
granola.granola_get_current_user
ParameterTypeRequiredDescription
No parameters.