MCPcopy Create free account

hub / github.com/PerpetualSoftware/pad / functions

Functions6,005 in github.com/PerpetualSoftware/pad

↓ 1 callersFunctionbackupSQLite
backupSQLite writes an online-safe, self-contained copy of the SQLite database at srcPath to outPath using `VACUUM INTO`. Unlike an io.Copy of the pad
cmd/pad/cmd_db.go:66
↓ 1 callersFunctionbaseProps
(overrides: Record<string, unknown> = {})
web/src/lib/components/common/Modal.svelte.test.ts:18
↓ 1 callersFunctionbinaryPresent
binaryPresent reports whether any of the given executable names is found on PATH.
internal/cli/agents.go:134
↓ 1 callersFunctionbindPlaybookArgs
bindPlaybookArgs walks the declared arg specs and binds the caller's supplied values. Unsupplied required args land in the `unbound` list so the agent
internal/server/handlers_playbooks.go:385
↓ 1 callersFunctionblockAtCoords
(view: EditorView, x: number, y: number)
web/src/lib/components/editor/block-drag-handle.ts:150
↓ 1 callersFunctionblockedByCmd
()
cmd/pad/cmd_item.go:1525
↓ 1 callersFunctionblocksCmd
--- dependencies ---
cmd/pad/cmd_item.go:1470
↓ 1 callersFunctionbodyHasCloudSecret
bodyHasCloudSecret peeks at the request body (capped at 64 KB) to see whether it's a JSON object with a "cloud_secret" field. Restores the body afterw
internal/server/handlers_cloud.go:131
↓ 1 callersFunctionbool
* Read a boolean param. Absent (undefined/null) returns undefined. Accepts * the literal strings "true"/"false" (transport leniency). Any other prese
web/src/lib/webmcp/dispatch.ts:91
↓ 1 callersFunctionboolToInt
boolToInt is the trivial converter used in test failure messages where formatting "n params + 0 workspace" reads cleaner than a branching message.
internal/mcp/catalog_meta_test.go:199
↓ 1 callersFunctionbootstrapCmd
bootstrapCmd returns the agent bootstrap blob — the consolidated workspace + user + collections + always-on conventions + roles + playbook metadata +
cmd/pad/cmd_bootstrap.go:19
↓ 1 callersFunctionbootstrapSectionBytes
bootstrapSectionBytes returns a per-section byte breakdown of a bootstrap blob. Marshalled with the same encoder behavior as the real handler (compact
internal/server/handlers_bootstrap_test.go:706
↓ 1 callersFunctionbucketEndTime
bucketEndTime returns the Unix timestamp at which the CURRENT 5-minute claim-code bucket rolls over to the next one. Used as the `expires_at` value in
internal/server/handlers_claim_code.go:161
↓ 1 callersFunctionbuildCommand
(cmd *cobra.Command)
internal/cmdhelp/json.go:152
↓ 1 callersFunctionbuildFieldsJSON
* Roll the catalog's flat item params (status / priority / category / parent * plus arbitrary `field` key=value entries) into the `fields` JSON strin
web/src/lib/webmcp/dispatch.ts:180
↓ 1 callersFunctionbuildFlag
(f *pflag.Flag)
internal/cmdhelp/json.go:404
↓ 1 callersFunctionbuildFrame
buildFrame builds a synthetic sync frame. Layout (offsets into the returned []byte, NOT into the user-facing frameBytes parameter): [0]: yMess
cmd/loadtest-collab/main.go:300
↓ 1 callersFunctionbuildItemSort
(sort string, dialect Dialect)
internal/store/items.go:4128
↓ 1 callersFunctionbuildKnownPlaybookTriggers
knownPlaybookTriggers is the set of trigger values the software playbook schema accepts, sourced directly from SoftwarePlaybookTriggers in templates.g
internal/collections/playbook_library_test.go:19
↓ 1 callersFunctionbuildLineageSections
(item *models.Item, links []models.ItemLink)
cmd/pad/lineage.go:218
↓ 1 callersFunctionbuildPlaceholder
Build the placeholder DOM. Kept tiny — purely visual, ignored by ProseMirror's selection model.
web/src/lib/components/editor/attachment-upload.ts:94
↓ 1 callersFunctionbuildRefCell
buildRefCell assembles the flexible REF/TITLE cell within a visible budget. Only the title is truncated — the pin marker, ref, and "(archived)" suffix
internal/cli/format.go:341
↓ 1 callersFunctionbuildRelatedGroups
buildRelatedGroups mirrors cmd/pad/query.go's function of the same name. Reproduced here because the CLI version is in package main. Groups every link
internal/mcp/dispatch_http_links.go:540
↓ 1 callersFunctionbuildRotateToolbar
* Build the image-edit toolbar — rotate trio (left 90°, 180°, right * 90°) plus a crop button. Each button delegates to the supplied * callback; the
web/src/lib/components/editor/attachment-image.ts:541
↓ 1 callersFunctionbuildSQLiteTemplate
buildSQLiteTemplate runs the full migration chain once into a process-wide temp file. The template is checkpointed and left in DELETE journal mode (no
internal/store/store_test.go:97
↓ 1 callersFunctionbuildTagsJSON
Tags: the catalog passes a JSON array of strings; ItemCreate/ItemUpdate * store the canonical JSON-encoded string form.
web/src/lib/webmcp/dispatch.ts:193
↓ 1 callersFunctionbuildTemplate
buildTemplate runs the full migration chain once into a process-wide temp file and returns its path. The template is checkpointed and left in DELETE j
internal/store/storetest/storetest.go:130
↓ 1 callersFunctionbuildTimeline
buildTimeline merges comments, activities, and versions into a single chronological stream, applying deduplication and collapsing logic.
internal/server/handlers_timeline.go:134
↓ 1 callersFunctionbuildToolSurfaceTools
buildToolSurfaceTools projects a catalog slice into the serialized per-tool summaries. Shared by ToolSurfaceJSON (the REST/browser path) and actionMet
internal/mcp/tool_surface.go:147
↓ 1 callersMethodbulkFieldUpdate
bulkFieldUpdate merges field changes into the item's existing fields, validates against the collection schema, runs the open-children guard (unless fo
internal/server/handlers_items_bulk.go:380
↓ 1 callersMethodbulkMoveCollection
bulkMoveCollection moves one item into req.Collection, migrating its fields between schemas — the same core as handleMoveItem, applied per row. A stat
internal/server/handlers_items_bulk.go:524
↓ 1 callersMethodbulkTagUpdate
bulkTagUpdate adds (add=true) or removes (add=false) the given tags from the item's tag set, preserving existing order and de-duplicating.
internal/server/handlers_items_bulk.go:472
↓ 1 callersFunctionbulkUpdateCmd
--- utility ---
cmd/pad/cmd_item.go:2006
↓ 1 callersFunctionbutton
Build a button with consistent typing on the modal.
web/src/lib/components/editor/attachment-crop-modal.ts:359
↓ 1 callersMethodcanEditComment
canEditComment reports whether the requester may edit the given comment: the authenticated author (matching user_id) or a platform admin. A comment wi
internal/server/handlers_comments.go:244
↓ 1 callersFunctioncanPromptForTemplate
canPromptForTemplate returns true when stdin and stdout are both TTYs — i.e. we can interactively prompt the user for a template choice.
cmd/pad/templates_picker.go:62
↓ 1 callersFunctioncanResolve
(id: string)
web/vitest.config.ts:25
↓ 1 callersMethodcancel
Cancel the pending debounce without flushing. Leaves dedupe state intact.
web/src/lib/collab/collabFlush.svelte.ts:121
↓ 1 callersMethodcancelPendingAck
cancelPendingAck removes a request from the pending-acks map. Used after a timeout / write failure to free the slot before retrying.
internal/collab/applier.go:351
↓ 1 callersFunctioncaptureHelpCmdCapabilities
captureHelpCmdCapabilities runs helpCmd via a synthetic root and returns its --capabilities output as a string. Mirrors the runHelp pattern in help_cm
cmd/pad/cmdhelp_real_test.go:170
↓ 1 callersFunctioncaptureHtmlBlockSnapshot
(editor: Editor)
web/src/lib/components/editor/extensions/htmlBlock.ts:49
↓ 1 callersFunctioncaptureView
( path: string, outFile: string, anchorSelector: string )
web/e2e/screenshots.spec.ts:72
↓ 1 callersFunctioncaptureView
(path: string, outFile: string, anchorSelector: string)
web/e2e/blog-screenshots.spec.ts:94
↓ 1 callersMethodcascadeTitleRename
cascadeTitleRename keeps title-form backlinks consistent when an item's title changes. Two effects to maintain inside the rename tx: 1. Sources that
internal/store/wiki_links.go:552
↓ 1 callersFunctioncategoryLabel
(slug: string | undefined)
web/src/lib/utils/templates.ts:27
↓ 1 callersFunctionchainTasks
chainTasks creates n open tasks linked in a blocks chain t0 -> t1 -> ... -> t(n-1) and returns them in order.
internal/server/handlers_graph_test.go:234
↓ 1 callersFunctionchangelogCmd
()
cmd/pad/cmd_project.go:668
↓ 1 callersFunctioncheckElement
(el: HTMLElement)
web/src/lib/utils/hiddenContentDetector.ts:118
↓ 1 callersMethodcheckParentCycleQ
checkParentCycleQ walks the ancestor chain from parentID and returns an error if itemID is found (which would create a cycle). Parameterized over the
internal/store/items.go:2999
↓ 1 callersMethodcheckRedirect
checkRedirect re-validates every redirect hop against the SSRF guard and caps the redirect chain length. Without it, an allowed public endpoint could
internal/webhooks/dispatcher.go:146
↓ 1 callersMethodchildrenDoneFiltersForCollection
childrenDoneFiltersForCollection is the batch version: it gathers one filter per distinct child-item collection across all parent→child links for pare
internal/store/items.go:3334
↓ 1 callersMethodchildrenDoneFiltersForParent
childrenDoneFiltersForParent returns a filter per distinct child-item collection under the given parent. Each filter carries the child collection's re
internal/store/items.go:3282
↓ 1 callersFunctionclampRetryMs
(ms: number)
web/src/lib/api/client.ts:145
↓ 1 callersFunctionclassify404
classify404 splits HTTP 404 by ResourceKind into the right code + hint. Called from classifyHTTPStatusKind only — extracted so the 404-shaped logic do
internal/mcp/errors.go:872
↓ 1 callersFunctioncleanUrl
(href: string)
web/src/lib/utils/markdown.ts:20
↓ 1 callersMethodcleanup
()
internal/server/middleware_ratelimit.go:104
↓ 1 callersFunctioncleanupListeners
()
web/src/lib/scroll/restore.svelte.ts:352
↓ 1 callersMethodclearParentLinkOnce
(itemID string)
internal/store/items.go:3037
↓ 1 callersMethodclearPending
Clear the pending (dirty) markdown — call once a save has landed.
web/src/lib/items/contentSaver.svelte.ts:54
↓ 1 callersFunctioncloneStringSlice
cloneStringSlice returns a copy of in so callers holding the returned model can't mutate the input the caller still owns. nil → nil so the model's sli
internal/store/oauth.go:788
↓ 1 callersMethodcloseAll
closeAll closes every active connection on this room and waits for the readers to drain. Used by RoomManager.Close on server shutdown. Holds r.mu only
internal/collab/room.go:478
↓ 1 callersFunctioncloseLightbox
(dialog: HTMLDialogElement)
web/src/lib/components/editor/attachment-image.ts:677
↓ 1 callersFunctioncoerceDefaultForType
* coerceDefaultForType applies type-aware coercion to a default value * collected from the UI. Mirrors the parsing rules in * `coerceDefaultValue` (
web/src/lib/playbooks/arguments.ts:326
↓ 1 callersFunctioncoerceDefaultValue
(raw: string)
web/src/lib/playbooks/arguments.ts:257
↓ 1 callersFunctioncoerceFields
(schema: unknown)
web/src/lib/components/share/shareView.ts:80
↓ 1 callersFunctioncoerceJSONForImport
coerceJSONForImport normalizes an imported JSON column value to a well-formed default of the expected shape. Used at the import boundary (ImportWorksp
internal/store/export.go:42
↓ 1 callersFunctioncoerceSampleValue
(arg: PlaybookArgument, raw: string)
web/src/lib/playbooks/arguments.ts:459
↓ 1 callersFunctioncoerceSettings
(settings: unknown)
web/src/lib/components/share/shareView.ts:107
↓ 1 callersFunctioncollDurMedian
(list []ReportDuration, slug string)
internal/store/reports_test.go:337
↓ 1 callersMethodcollabRevalidationLoop
collabRevalidationLoop ticks every collabMembershipRevalInterval while the WebSocket is open and re-runs authorizeCollabAccess. On access loss it send
internal/server/handlers_collab.go:250
↓ 1 callersMethodcollectAlwaysOnConventions
collectAlwaysOnConventions returns the active, always-on conventions for a workspace, projected into the bootstrap-friendly shape. Sorted by priority
internal/server/handlers_bootstrap.go:643
↓ 1 callersMethodcollectConventionIndex
collectConventionIndex returns the metadata-only catalog of EVERY active convention in the workspace (all triggers, always-on included), projected int
internal/server/handlers_bootstrap.go:703
↓ 1 callersMethodcollectGrantChainsForBackfill
collectGrantChainsForBackfill returns a map keyed by request_id with the newest session_data + the subject (user_id) per chain. Walks both oauth_acces
internal/store/oauth_connections_backfill.go:153
↓ 1 callersFunctioncollectLocalInfo
(cfg *config.Config)
cmd/pad/server_info.go:178
↓ 1 callersFunctioncollectionCmd
()
cmd/pad/groups.go:148
↓ 1 callersFunctioncollectionDefaultIcon
collectionDefaultIcon returns a default icon for known collection slugs.
cmd/pad/cmd_collection.go:22
↓ 1 callersFunctioncollectionSchema
* Resolve the collection `schema` param to the JSON string the create/update * endpoints persist. The catalog's `schema` is a structured CollectionSc
web/src/lib/webmcp/dispatch.ts:240
↓ 1 callersFunctioncollectionSettings
* Roll the collection settings params (layout / default_view / board_group_by) * into the JSON `settings` string the endpoint persists — the browser
web/src/lib/webmcp/dispatch.ts:260
↓ 1 callersFunctioncollectionSlugForKind
collectionSlugForKind maps an artifact Kind to the destination collection slug in a workspace.
internal/server/handlers_artifact_import.go:23
↓ 1 callersFunctioncollectionsCmd
--- collections ---
cmd/pad/cmd_collection.go:41
↓ 1 callersFunctioncollectionsCreateCmd
()
cmd/pad/cmd_collection.go:146
↓ 1 callersFunctioncollectionsDeleteCmd
collectionsDeleteCmd soft-deletes a collection. Server-side (store/collections.go::DeleteCollection) sets collections.deleted_at on the collection row
cmd/pad/cmd_collection.go:378
↓ 1 callersFunctioncollectionsUpdateCmd
collectionsUpdateCmd updates an existing collection's name, icon, description, prefix, schema, or sort order. Only flags the caller explicitly sets ar
cmd/pad/cmd_collection.go:265
↓ 1 callersFunctioncolorProgressBar
(pct, width int, filledColor *color.Color)
cmd/pad/cmd_project.go:196
↓ 1 callersFunctioncommandPath
(cmd, root *cobra.Command)
internal/cmdhelp/json.go:145
↓ 1 callersFunctioncommentCmd
--- comments ---
cmd/pad/cmd_item.go:1410
↓ 1 callersFunctioncommentEntry
(id string, at time.Time)
internal/server/handlers_timeline_collapse_test.go:34
↓ 1 callersFunctioncommentsCmd
()
cmd/pad/cmd_item.go:1444
↓ 1 callersFunctioncommit
()
web/src/lib/components/editor/extensions/htmlBlock.ts:351
↓ 1 callersFunctioncommitAndFlip
()
web/src/lib/components/editor/extensions/htmlBlock.ts:372
↓ 1 callersFunctioncompilePattern
(pat string)
internal/items/validate.go:20
↓ 1 callersFunctioncompletionCmd
--- serve ---
cmd/pad/main.go:258
↓ 1 callersFunctioncomputeHMAC
computeHMAC returns the hex-encoded HMAC-SHA256 of the body using the secret.
internal/webhooks/dispatcher.go:305
↓ 1 callersFunctionconfigSource
(cfg serverInfoConfig)
cmd/pad/server_info.go:287
↓ 1 callersFunctionconfigureCmd
()
cmd/pad/configure.go:23
↓ 1 callersFunctionconflictHintFor
conflictHintFor generates the actionable hint for ErrConflict.
internal/mcp/errors.go:1121
↓ 1 callersFunctionconnect
(workspaceSlug: string)
web/src/lib/services/sse.svelte.ts:352
↓ 1 callersMethodconnectUrl
* Compute the URL to connect to on this attempt. The base URL * is the (immutable) collab endpoint with `schema_version` * already encoded; we add
web/src/lib/collab/wsProvider.svelte.ts:1141
↓ 1 callersMethodconnectionOwnedByUser
Connection mutation endpoints (PLAN-1519 / TASK-1524 / IDEA-1517 §3). All four mutations follow the same shape: 1. Resolve current user from context
internal/server/handlers_connected_apps.go:250
↓ 1 callersFunctionconsider
(pos: number, yCoord: number)
web/src/lib/components/editor/block-drag-handle.ts:160
← previousnext →1,901–2,000 of 6,005, ranked by callers