MCPcopy Create free account

hub / github.com/PerpetualSoftware/pad / functions

Functions31,685 in github.com/PerpetualSoftware/pad

↓ 8 callersFunctionauditUser
auditUser creates a user that subsequent audit rows can FK-reference. The schema requires user_id REFERENCES users(id), so we can't insert audit rows
internal/store/mcp_audit_test.go:39
↓ 8 callersFunctionauthKind
authKind returns how this request's principal was established, or "" when no credential was accepted — the fresh-install window and the legacy no-auth
internal/server/middleware_auth.go:112
↓ 8 callersFunctionbearerToken
Request credentials (TASK-4323). A token read from a header or a cookie is held as a secret.Secret, so a log line or a %v that picks it up shows the m
internal/server/request_credentials.go:21
↓ 8 callersMethodbefore
(other *sessionActivityTimestamp)
internal/server/session_activity.go:43
↓ 8 callersFunctionboardJSON
(t *testing.T, r *CallToolResult)
internal/mcp/board_test.go:72
↓ 8 callersFunctionboundItemID
(t *testing.T, srv *Server, id string)
internal/server/handlers_attachments_attach_test.go:67
↓ 8 callersFunctionbracketOffsets
bracketOffsets returns the byte offset of every `[[` that has a matching `]]` after it, scanning the way the parser does.
internal/links/rewrite_brackets_diff_test.go:470
↓ 8 callersFunctionbtn
(label: string | RegExp, scope: ParentNode = host)
web/src/routes/(console)/needs/needsPage.svelte.test.ts:115
↓ 8 callersFunctionbug3691LiveItems
(t *testing.T, s *Store, workspaceID string)
internal/store/bug3691_app_plan_limit_test.go:29
↓ 8 callersFunctionbug3691SetWorkspacePlanCap
BUG-3691: ProvisionAppInstall and UpgradeAppInstall must enforce the items_per_workspace plan limit when passed WithPlanLimit(), aborting the entire t
internal/store/bug3691_app_plan_limit_test.go:16
↓ 8 callersFunctionbug3825Export
BUG-3825: ImportWorkspace inserted each archive item's fields as they were, and nothing checked unique_scope: workspace_collection. A duplicate can on
internal/store/bug3825_import_unique_values_test.go:18
↓ 8 callersMethodbuildDashboardResponse
buildDashboardResponse is the canonical full dashboard-assembly path. The HTTP handler (handleGetDashboard) is now a thin wrapper around it, and the b
internal/server/handlers_dashboard.go:451
↓ 8 callersFunctionbuildDoneContextMap
buildDoneContextMap builds a map of collection ID → (schema, settings) for quick lookups during dashboard / lineage traversals.
internal/server/handlers_dashboard.go:330
↓ 8 callersFunctionbuildFositeRequest
buildFositeRequest produces a fully-populated *fosite.Request so adapter tests can drive Create*Session methods without depending on fosite's HTTP ent
internal/oauth/server_test.go:942
↓ 8 callersFunctioncanPromptForConfig
()
cmd/pad/configure.go:363
↓ 8 callersFunctioncanSee
(id: string, collection: string)
web/src/lib/stores/localIndexMovedOutFloor.svelte.test.ts:68
↓ 8 callersMethodchallengeFor
challengeFor runs oauth-login from remote and returns the 2FA challenge.
internal/server/task4137_pkce_twofactor_test.go:74
↓ 8 callersFunctionchatCount
(t *testing.T, s *Store, convID string)
internal/store/conversations_test.go:40
↓ 8 callersFunctionchildState
(child: Item, collection: Collection | undefined)
web/src/lib/collections/childProgress.ts:46
↓ 8 callersFunctioncommentCmd
--- comments ---
cmd/pad/cmd_item.go:3370
↓ 8 callersMethodcommit
commit checks the budget, then commits with no deadline context: a deadline that fired during COMMIT would leave the outcome unknown.
internal/store/commitment_cascade.go:62
↓ 8 callersFunctioncompletedOn
completedOn returns the completed count of one day.
internal/server/handlers_me_agenda_counts_test.go:26
↓ 8 callersFunctionconfigurePush
configurePush wires the push gateway from cfg and, when one is configured, starts the push dispatcher (TASK-3939 B2c). A gateway URL with no usable se
cmd/pad/cmd_server.go:1637
↓ 8 callersMethodcontext
(tok, query string)
internal/server/plan3598_item_context_test.go:65
↓ 8 callersFunctioncountDecisionJobs
(t *testing.T, s *Store)
internal/store/decisions_test.go:24
↓ 8 callersMethodcreateItemTx
createItemTx is the tx-taking form of item creation (PLAN-2357 / DR-9a) and the single implementation behind BOTH CreateItem and the cross-workspace c
internal/store/items.go:551
↓ 8 callersFunctioncreateTestUserDirect
(t *testing.T, srv *Server, email string)
internal/server/task3401_app_api_test.go:175
↓ 8 callersFunctioncredentialKey
credentialKey also recognises compound names such as access_token, webhook_secret and Proxy-Authorization, regardless of case or separators.
internal/logging/redaction.go:21
↓ 8 callersFunctiondeadlineLinkFixture
(t *testing.T, n int)
internal/store/commitment_renegotiate_cascade_test.go:11
↓ 8 callersFunctiondeadlocked
(errs []error)
internal/store/commitment_links_pg_test.go:143
↓ 8 callersFunctiondecodeScheduleView
(raw json.RawMessage)
cmd/pad/cmd_schedule.go:143
↓ 8 callersFunctiondelegatedFixture
(t *testing.T, installID, offered string)
internal/server/task3399_delegated_flow_test.go:26
↓ 8 callersMethoddevices
()
internal/server/handlers_push_devices_test.go:69
↓ 8 callersMethoddispatch
dispatch runs one MCP tool call through the in-process HTTP dispatcher against the real server, as the fixture's owner.
internal/mcp/dispatch_http_clear_assignment_test.go:105
↓ 8 callersFunctiondrainFixture
drainFixture wires a server to a webhook sink and returns the workspace the events belong to.
internal/server/outbox_drain_test.go:72
↓ 8 callersMethodenrichItemForResponse
enrichItemForResponse populates derived closure and parent info on a single item. An optional non-nil visibleIDs marks a restricted caller, whose rela
internal/server/item_lineage.go:91
↓ 8 callersMethodenrichItemsWithParent
enrichItemsWithParent batch-populates parent link info on a slice of items. Used by list endpoints where calling enrichItemForResponse per-item is too
internal/server/item_lineage.go:15
↓ 8 callersFunctionexists
(path string)
internal/testtmp/lock_unix_test.go:51
↓ 8 callersFunctionexportJSONFrom
(t *testing.T)
internal/server/bug3354_import_bundle_bomb_test.go:56
↓ 8 callersFunctionfail
(path, format string, args ...any)
internal/appmanifest/manifest.go:132
↓ 8 callersFunctionfakeYjsRow
fakeYjsRow constructs a single row for the fakeOpLog seeding helpers. The store assigns ids in production; tests don't depend on them.
internal/collab/manager_test.go:1864
↓ 8 callersMethodfanOutLocally
fanOutLocally distributes an event to all local subscribers for the event's workspace and stores it in the replay buffer, with no id-space information
internal/events/redis_bus.go:2718
↓ 8 callersMethodfill
()
internal/schedule/caps.go:37
↓ 8 callersFunctionfixtureDoc
fixtureDoc returns a small cmdhelp.Document with the items the catalog tests need most often. Catalog actions only require their own cmdPath to be pre
internal/mcp/registry_test.go:51
↓ 8 callersFunctionformatItemAsMarkdown
formatItemAsMarkdown turns the JSON body returned by `pad item show --format json` into a self-contained markdown document: heading with ref + title,
internal/mcp/resources.go:335
↓ 8 callersFunctionfreezeRefill
BUG-3308: per-address buckets key an IPv6 client on its /64, and every limiter's map has a size cap whose eviction cannot hand an attacker back their
internal/server/middleware_ratelimit_bug3308_test.go:27
↓ 8 callersFunctiongetConfig
--- helpers --- getConfig is loadConfig for commands: a config.toml that fails to load ends the process with the error.
cmd/pad/main.go:308
↓ 8 callersMethodgetLimiter
getLimiter returns key's bucket, creating it if absent, without charging it. Tests read a bucket through it; production code charges through allow ins
internal/server/middleware_ratelimit.go:146
↓ 8 callersMethodgetOrCreate
getOrCreate returns the existing Room for itemID or, atomically under m.mu, mints a new one. Holding m.mu across the lookup + insertion keeps the grac
internal/collab/manager.go:1012
↓ 8 callersFunctiongotTimes
(occ []Occurrence)
internal/schedule/bounds_test.go:25
↓ 8 callersFunctiongraphField
(field, code string)
internal/server/handlers_commitment_links.go:91
↓ 8 callersFunctiongraphNode
(resp GraphResponse, ref string)
internal/server/handlers_graph_test.go:23
↓ 8 callersFunctiongroupList
(t *testing.T, s *Server, u *models.User, mods ...func(context.Context) context.Context)
internal/server/handlers_workspace_groups_test.go:69
↓ 8 callersFunctionhasNUL
(vals ...string)
internal/store/schedule_carry_v2.go:132
↓ 8 callersMethodhook
(t *testing.T)
internal/server/handlers_apps_webhooks_test.go:23
↓ 8 callersFunctionhydrateItemComputedMetadata
(item *models.Item)
internal/store/items.go:7469
↓ 8 callersFunctionidentityGateSuite
(g: SurfaceGate)
web/src/test/identityGateSuite.ts:71
↓ 8 callersFunctionimportLimitFixture
BUG-2793. `POST /workspaces` enforces the user-scoped `workspaces` plan limit; `POST /workspaces/import` did not, and it mints a workspace through the
internal/server/handlers_workspace_import_plan_limit_test.go:27
↓ 8 callersFunctioninitializedWorkspace
initializedWorkspace is a workspace on an instance that has a user, so the fresh-install bypass does not apply.
internal/server/bug3334_fail_closed_test.go:35
↓ 8 callersFunctioninsertRawOutboxRow
insertRawOutboxRow writes a row STRAIGHT TO SQL, bypassing writeOutboxTx. That bypass is the point rather than a shortcut: rows over the row cap cann
internal/store/event_outbox_bounds_test.go:47
↓ 8 callersFunctionisItemDone
isItemDone reports whether an item is in a terminal state for its collection's configured done field. Falls back to the default-terminal list against
internal/server/handlers_dashboard.go:359
↓ 8 callersFunctionisolateHome
isolateHome points BOTH home variables at dir: os.UserHomeDir reads HOME on unix and USERPROFILE on Windows, and a test that sets only one would mutat
internal/cli/session_owner_test.go:25
↓ 8 callersMethoditemLock
itemLock returns the lazily-allocated mutex guarding setup-phase operations on itemID, pinning its map entry for the lifetime of the process. Sweeper-
internal/collab/manager.go:319
↓ 8 callersFunctionitoa
itoa is a tiny strconv.Itoa wrapper kept local to avoid an extra import in this single-file test.
internal/server/handlers_admin_users_test.go:198
↓ 8 callersFunctionkeys
(m interface{})
internal/cmdhelp/json_test.go:671
↓ 8 callersFunctionlink
(this: { parser: { parseInline(t: Tokens.Generic[]): string } }, { href, title, tokens }: Tokens.Link)
web/src/lib/chat/markdown.ts:34
↓ 8 callersFunctionliveFrame
(clientID, clock uint64)
internal/collab/awareness_test.go:132
↓ 8 callersFunctionloadTemplates
loadTemplates accepts a filesystem rooted at the template data directory.
internal/collections/templates_manifest.go:149
↓ 8 callersFunctionmatchDelimiter
(code: string, openIndex: number, open: string, close: string)
web/src/test/identityFenceSource.ts:190
↓ 8 callersMethodmaybeInjectWorkspace
maybeInjectWorkspace defaults the `workspace` input from the dispatcher's WorkspaceLister when the caller didn't pass one explicitly (TASK-1076). The
internal/mcp/dispatch_http_advanced.go:817
↓ 8 callersFunctionmeAgendaTransition
(t *testing.T, w *agendaWorld, it *models.Item, at, status string)
internal/server/handlers_me_agenda_test.go:58
↓ 8 callersFunctionmergeActivityMeta
mergeActivityMeta combines two activity metadata JSON strings, accumulating the "changes" field. If both contain changes, they are joined with "; ". O
internal/store/activities.go:515
↓ 8 callersMethodmilestone
()
internal/server/handlers_milestone_test.go:20
↓ 8 callersFunctionmimeDispoFixture
BUG-2413: the attachment read path must fail CLOSED on Content-Disposition — a stored MIME that is not explicitly inline-safe is served as an attachme
internal/server/handlers_attachments_download_mime_test.go:27
↓ 8 callersFunctionmint
()
web/e2e/task-3415-real-install.spec.ts:228
↓ 8 callersMethodmissEvidence
(t *testing.T)
internal/store/commitment_move_deadline_test.go:35
↓ 8 callersMethodms
TASK-4358: the milestone write doors and the reader-scoped read.
internal/server/handlers_milestone_test.go:14
↓ 8 callersFunctionmustMintWebView
(t *testing.T, srv *Server, parentTok string, replacePrevious bool)
internal/server/handlers_webview_session_test.go:34
↓ 8 callersFunctionmyInvitationIDs
(t *testing.T, f *accessFixture, tok string)
internal/server/bug2136_invite_consent_test.go:29
↓ 8 callersMethodneedsAdmittedWorkspaces
needsAdmittedWorkspaces is the workspaces the caller may be shown needs from: memberships and guest workspaces, narrowed to a token's consent allow-li
internal/server/handlers_me_needs.go:194
↓ 8 callersFunctionnewAppTestDispatcher
()
internal/webhooks/app_delivery_test.go:87
↓ 8 callersFunctionnewAttRestoreFixture
(t *testing.T)
internal/store/attachments_restore_test.go:25
↓ 8 callersFunctionnewAttributionFixture
(t *testing.T)
internal/server/bug3372_attribution_test.go:31
↓ 8 callersFunctionnewAuditTestStore
Store-layer tests for the MCP audit log (PLAN-943 TASK-960). What's covered: - InsertMCPAuditEntry validates required fields and round-trips correct
internal/store/mcp_audit_test.go:25
↓ 8 callersFunctionnewBlankFixture
(t *testing.T)
internal/server/bug3028_relation_blank_test.go:25
↓ 8 callersFunctionnewChatGPTMCPServer
newChatGPTMCPServer is the ChatGPT catalog's server (TASK-3321): the same registry and dispatcher as remote /mcp, its own tool list, instructions and
cmd/pad/cmd_server_chatgpt.go:20
↓ 8 callersFunctionnewMCPSessionTracker
newMCPSessionTracker constructs a tracker with no per-group cap, the given TTL, and optional onChange callback. ttl <= 0 falls back to the default; on
internal/server/middleware_mcp_session.go:91
↓ 8 callersFunctionnewStampFixture
newStampFixture makes the state the stamp exists for: an item whose op-log holds a row above its (NULL) watermark while items.content is current — wha
internal/server/bug3124_watermark_stamp_test.go:33
↓ 8 callersFunctionnewTabsFixture
(t *testing.T)
internal/server/handlers_workspace_tabs_test.go:23
↓ 8 callersFunctionnewTransformFixture
(t *testing.T, srv *Server)
internal/server/handlers_attachments_transform_authz_test.go:52
↓ 8 callersFunctionnormalizeMime
Strip parameters and case, matching the server's `NormalizeMIME`.
web/src/lib/attachments/display.ts:190
↓ 8 callersMethodnotMine
"Not mine" (TASK-4643): the store half. Runs on both backends via testStore (PAD_TEST_POSTGRES_URL selects Postgres); the migration test runs each bac
internal/store/needs_not_mine_test.go:16
↓ 8 callersFunctionnulRepairRemedy
nulRepairRemedy is the sentence appended to a strict refusal, naming the flag that would have accepted it. It says something DIFFERENT when the flag
internal/server/import_nul_repair.go:102
↓ 8 callersFunctionnullIfEmpty
(v string)
internal/store/webhook_deliveries.go:141
↓ 8 callersFunctionoauthLoginBody
(email string)
internal/server/handlers_bug3322_totp_doors_test.go:45
↓ 8 callersMethodobserver
()
internal/events/observer.go:303
↓ 8 callersMethodoff
(event: 'beforeTransaction', fn: (props: { transaction: LocalChangeProbe }) => void)
web/src/lib/items/confirmedBase.ts:126
↓ 8 callersFunctionoffsetOf
offsetOf converts a stored offset to the pure layer's.
internal/store/commitment_links.go:156
↓ 8 callersMethodopen
open starts a long-lived MCP request (a GET stream, or a listen POST) and returns a channel closed when its handler returns.
internal/server/bug3837_mcp_credential_tick_test.go:96
↓ 8 callersMethodopen
()
web/src/lib/api/client401Keepers.test.ts:35
← previousnext →2,101–2,200 of 31,685, ranked by callers