KosmoKrator

productivity

Droplr Lua API for KosmoKrator Agents

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

6 functions 4 read 2 write Bearer token auth

Lua Namespace

Agents call this integration through app.integrations.droplr.*. Use lua_read_doc("integrations.droplr") 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.

Droplr — Lua API Reference

list_drops

List drops (short links, files, images, notes) from Droplr with optional filtering.

Parameters

NameTypeRequiredDescription
pageintegernoPage number for pagination (default: 1)
limitintegernoNumber of results per page (default: 20, max: 100)
typestringnoFilter by drop type: LINK, IMAGE, FILE, or NOTE
qstringnoSearch query to filter drops by title or content

Examples

-- List recent drops
local result = app.integrations.droplr.list_drops({
  limit = 10
})

for _, drop in ipairs(result.drops) do
  print(drop.title .. ": " .. drop.short_url)
end

-- Search for links containing "docs"
local result = app.integrations.droplr.list_drops({
  q = "docs",
  type = "LINK"
})

get_drop

Get details of a specific drop by its ID.

Parameters

NameTypeRequiredDescription
idstringyesThe drop ID (short code, e.g., "abc123")

Examples

local result = app.integrations.droplr.get_drop({
  id = "abc123"
})

print(result.title)
print(result.long_url)
print(result.short_url)
print(result.type)
print(result.created_at)

create_drop

Create a new drop (short link) in Droplr.

Parameters

NameTypeRequiredDescription
linkstringyesThe long URL to shorten
titlestringnoOptional title for the drop
variantstringnoVariant type: "redirect" (default) or "frame" (embeds in a frame)

Examples

-- Create a simple short link
local result = app.integrations.droplr.create_drop({
  link = "https://example.com/very/long/url"
})

print("Short URL: " .. result.short_url)

-- Create a titled short link with frame variant
local result = app.integrations.droplr.create_drop({
  link = "https://example.com/docs",
  title = "Documentation",
  variant = "frame"
})

delete_drop

Delete a drop permanently from Droplr.

Parameters

NameTypeRequiredDescription
idstringyesThe drop ID to delete (short code, e.g., "abc123")

Examples

local result = app.integrations.droplr.delete_drop({
  id = "abc123"
})

print(result) -- "Drop 'abc123' has been deleted."

list_boards

List boards (collections of drops) from Droplr.

Parameters

NameTypeRequiredDescription
pageintegernoPage number for pagination (default: 1)
limitintegernoNumber of results per page (default: 20)

Examples

local result = app.integrations.droplr.list_boards({
  limit = 10
})

for _, board in ipairs(result.boards) do
  print(board.name .. " (" .. board.drops_count .. " drops)")
end

get_current_user

Get the authenticated Droplr user’s profile information.

Parameters

None.

Examples

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

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

Multi-Account Usage

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

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

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

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

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

Raw agent markdown
# Droplr — Lua API Reference

## list_drops

List drops (short links, files, images, notes) from Droplr with optional filtering.

### Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `page` | integer | no | Page number for pagination (default: 1) |
| `limit` | integer | no | Number of results per page (default: 20, max: 100) |
| `type` | string | no | Filter by drop type: `LINK`, `IMAGE`, `FILE`, or `NOTE` |
| `q` | string | no | Search query to filter drops by title or content |

### Examples

```lua
-- List recent drops
local result = app.integrations.droplr.list_drops({
  limit = 10
})

for _, drop in ipairs(result.drops) do
  print(drop.title .. ": " .. drop.short_url)
end

-- Search for links containing "docs"
local result = app.integrations.droplr.list_drops({
  q = "docs",
  type = "LINK"
})
```

---

## get_drop

Get details of a specific drop by its ID.

### Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `id` | string | yes | The drop ID (short code, e.g., `"abc123"`) |

### Examples

```lua
local result = app.integrations.droplr.get_drop({
  id = "abc123"
})

print(result.title)
print(result.long_url)
print(result.short_url)
print(result.type)
print(result.created_at)
```

---

## create_drop

Create a new drop (short link) in Droplr.

### Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `link` | string | yes | The long URL to shorten |
| `title` | string | no | Optional title for the drop |
| `variant` | string | no | Variant type: `"redirect"` (default) or `"frame"` (embeds in a frame) |

### Examples

```lua
-- Create a simple short link
local result = app.integrations.droplr.create_drop({
  link = "https://example.com/very/long/url"
})

print("Short URL: " .. result.short_url)

-- Create a titled short link with frame variant
local result = app.integrations.droplr.create_drop({
  link = "https://example.com/docs",
  title = "Documentation",
  variant = "frame"
})
```

---

## delete_drop

Delete a drop permanently from Droplr.

### Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `id` | string | yes | The drop ID to delete (short code, e.g., `"abc123"`) |

### Examples

```lua
local result = app.integrations.droplr.delete_drop({
  id = "abc123"
})

print(result) -- "Drop 'abc123' has been deleted."
```

---

## list_boards

List boards (collections of drops) from Droplr.

### Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `page` | integer | no | Page number for pagination (default: 1) |
| `limit` | integer | no | Number of results per page (default: 20) |

### Examples

```lua
local result = app.integrations.droplr.list_boards({
  limit = 10
})

for _, board in ipairs(result.boards) do
  print(board.name .. " (" .. board.drops_count .. " drops)")
end
```

---

## get_current_user

Get the authenticated Droplr user's profile information.

### Parameters

None.

### Examples

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

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

---

## Multi-Account Usage

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

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

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

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

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

Metadata-Derived Lua Example

local result = app.integrations.droplr.droplr_list_drops({
  page = 1,
  limit = 1,
  type = "example_type",
  q = "example_q"
})
print(result)

Functions

droplr_list_drops

List drops (short links, files, images, notes) from Droplr. Supports filtering by type and search query, with pagination.

Operation
Read read
Full name
droplr.droplr_list_drops
ParameterTypeRequiredDescription
page integer no Page number for pagination (default: 1).
limit integer no Number of results per page (default: 20, max: 100).
type string no Filter by drop type: LINK, IMAGE, FILE, or NOTE.
q string no Search query to filter drops by title or content.

droplr_get_drop

Get details of a specific drop (short link, file, image, or note) by its ID.

Operation
Read read
Full name
droplr.droplr_get_drop
ParameterTypeRequiredDescription
id string yes The drop ID (the short code, e.g., "abc123").

droplr_create_drop

Create a new drop (short link) in Droplr. Provide a long URL to shorten, with optional title and variant.

Operation
Write write
Full name
droplr.droplr_create_drop
ParameterTypeRequiredDescription
link string yes The long URL to shorten (e.g., "https://example.com/very/long/url").
title string no Optional title for the drop.
variant string no Optional variant type: "redirect" (default) or "frame" (embeds in a frame).

droplr_delete_drop

Delete a drop (short link, file, image, or note) from Droplr by its ID. This action is permanent.

Operation
Write write
Full name
droplr.droplr_delete_drop
ParameterTypeRequiredDescription
id string yes The drop ID to delete (the short code, e.g., "abc123").

droplr_list_boards

List boards (collections of drops) from Droplr. Supports pagination.

Operation
Read read
Full name
droplr.droplr_list_boards
ParameterTypeRequiredDescription
page integer no Page number for pagination (default: 1).
limit integer no Number of results per page (default: 20).

droplr_get_current_user

Get the authenticated Droplr user's profile, including name, email, and plan information.

Operation
Read read
Full name
droplr.droplr_get_current_user
ParameterTypeRequiredDescription
No parameters.