MCPcopy Create free account

hub / github.com/PerpetualSoftware/pad / functions

Functions28,840 in github.com/PerpetualSoftware/pad

↓ 5 callersMethodEndAppDelivery
(deliveryID string)
internal/webhooks/app_delivery.go:50
↓ 5 callersMethodEnsureChatDMContext
EnsureChatDMContext lets the monitor cancel its background DM ensure on exit.
internal/cli/client.go:3686
↓ 5 callersFunctionEnvConfig
EnvConfig reads the decision-provider settings from the environment. The variables follow the PAD_MAILEROO_API_KEY pattern in internal/config: PAD_DE
internal/decision/config.go:60
↓ 5 callersMethodError
()
internal/server/handlers_items_bulk.go:103
↓ 5 callersFunctionErrorType
ErrorType retains the failure's type without rendering untrusted error text. HTTP and conversion errors can repeat URLs, response bodies or credential
internal/logging/redaction.go:237
↓ 5 callersMethodFTSMatch
FTSMatch returns the full-text search predicate and its arguments. SQLite quotes tokens and prefixes the last eligible part. PostgreSQL preserves both
internal/store/dialect.go:114
↓ 5 callersMethodFinishRotate
FinishRotate is rotate's phase 2: disabling -> active with a new client secret (discarded: the app receives one through redeem) and a new install code
internal/store/app_lifecycle.go:208
↓ 5 callersMethodFor
For returns the routing as the given user sees it. Under the mentioned rule that is built from the user's own mentions alone, so nothing of another pe
internal/needs/needs.go:105
↓ 5 callersFunctionGenerateUsername
--- Username backfill --- GenerateUsername derives a URL-safe username from a display name. Falls back to the email local part if the name produces an
internal/store/users.go:1828
↓ 5 callersMethodGetAgentRole
(workspaceID, idOrSlug string)
internal/store/agent_roles.go:40
↓ 5 callersMethodGetAllItemProgress
GetAllItemProgress returns child item completion counts for every item in the given collection within a workspace. includeArchived controls whether s
internal/store/items.go:5496
↓ 5 callersMethodGetAttachmentVariant
GetAttachmentVariant returns the derived attachment row for parentID with the given variant key (e.g. "thumb-sm"), or (nil, nil) if no such row exists
internal/store/attachments.go:444
↓ 5 callersMethodGetCollection
(wsSlug, collSlug string)
internal/cli/client.go:302
↓ 5 callersMethodGetDashboard
--- Dashboard --- GetDashboard returns the workspace dashboard as raw JSON. The DashboardResponse type lives in the server package, so we use json.Raw
internal/cli/client.go:1525
↓ 5 callersMethodGetMemberCollectionAccessQ
GetMemberCollectionAccessQ is GetMemberCollectionAccess parameterized over its executor (see Queryer).
internal/store/workspace_members.go:707
↓ 5 callersMethodGetParentMap
GetParentMap returns a map of item ID -> parent item ID for all parent links in a workspace. Used for efficient batch lookups (e.g., dashboard, list e
internal/store/items.go:5031
↓ 5 callersMethodGetShareLink
GetShareLink retrieves a share link by ID.
internal/store/share_links.go:118
↓ 5 callersMethodGetUserByUsername
GetUserByUsername retrieves a user by username (case-insensitive).
internal/store/users.go:196
↓ 5 callersMethodGetWatchByUserItem
GetWatchByUserItem returns the (at most one) watch a user holds on a specific item, or (nil, nil) if none exists.
internal/store/watches.go:33
↓ 5 callersMethodGetWebhook
GetWebhook retrieves a single webhook by ID.
internal/store/webhooks.go:72
↓ 5 callersMethodGetWorkspace
(slug string)
internal/cli/client.go:233
↓ 5 callersMethodGetWorkspaceGroup
(ctx context.Context, userID, id string)
internal/store/workspace_groups.go:84
↓ 5 callersMethodGetWorkspaceImportStatus
GetWorkspaceImportStatus answers the workspace's import marker, or nil when it has none (the normal case).
internal/store/workspace_import_status.go:36
↓ 5 callersMethodInsertItemVerifications
InsertItemVerifications stores one batch of verdicts on one item, in one transaction, all stamped with the same created_at. Each row's ItemID, ViaItem
internal/store/verifications.go:51
↓ 5 callersMethodInstallClientIDTx
InstallClientIDTx returns the install's client id.
internal/store/install_clients.go:239
↓ 5 callersMethodItemLastRestoreSeq
ItemLastRestoreSeq returns the DURABLE per-item restore boundary (items.last_restore_seq) — the item.seq of the most recent version restore (BUG-2264)
internal/collab/room.go:358
↓ 5 callersMethodIterator
Iterator returns an iterator for rrule.Set
internal/schedule/internal/rrule/rruleset.go:134
↓ 5 callersFunctionJudge
Judge sets State on every row, and PossiblyStale where a linked PR merged after the row was recorded. rows may be any subset of one item's history; "s
internal/verification/verification.go:113
↓ 5 callersMethodListAgentRoles
(workspaceID string)
internal/store/agent_roles.go:64
↓ 5 callersMethodListAllItemsReport
ListAllItemsReport is ListAllItems from startOffset, also returning the first page's UndeclaredKeys (BUG-4024).
internal/cli/client.go:451
↓ 5 callersFunctionListAllTemplates
ListAllTemplates returns every registered template, including ones flagged Hidden. Intended for internal tooling (e.g. tests, demo seeding) that needs
internal/collections/templates.go:1144
↓ 5 callersMethodListItemVersionsResolvedSnapshot
ListItemVersionsResolvedSnapshot reads the item's body and its newest `limit` versions (limit <= 0: all) in one read snapshot, and resolves the versio
internal/store/items.go:6739
↓ 5 callersMethodListStarredItems
ListStarredItems returns all items starred by a user in a workspace, enriched with collection and assignment info. Only non-deleted items are returned
internal/store/item_stars.go:96
↓ 5 callersMethodListUserAppGrants
ListUserAppGrants returns the user's live delegated app grants: a binding of kind delegated whose grant still has an active access or refresh token he
internal/store/app_grants.go:36
↓ 5 callersMethodMCPBearerAuth
MCPBearerAuth is the auth gate for the /mcp Streamable HTTP endpoint. Behaviour, in order: 1. No Authorization header, or one that doesn't start wit
internal/server/middleware_mcp_auth.go:78
↓ 5 callersMethodMaxOpLogID
MaxOpLogID is consulted ONLY by ForceRefreshRoom (BUG-2264), which reads it under the per-item lock WITH appendMu held (inbound persistence frozen) to
internal/collab/room.go:351
↓ 5 callersFunctionMetricsMiddleware
MetricsMiddleware returns a chi middleware that records Prometheus metrics for every HTTP request: count, duration, and response size. Path labels us
internal/server/middleware_metrics.go:19
↓ 5 callersFunctionMigrateCloseStateChange
MigrateCloseStateChange reports whether moving an item from the source collection to the destination would change its CloseState, given the destinatio
internal/models/close_state.go:71
↓ 5 callersMethodMigrateItemFieldValues
MigrateItemFieldValues bulk-updates items in a collection when select options are renamed. Each entry in renames maps old_value → new_value for the gi
internal/store/collections.go:998
↓ 5 callersMethodMinGap
MinGap measures a schedule at its write (TASK-4236). n is how many occurrences the sample from Start found: gapSample, or more when an RDATE lies past
internal/schedule/engine.go:471
↓ 5 callersFunctionMkdirTemp
MkdirTemp makes os.TempDir()/prefix<pid>-<random> after a sweep of earlier prefix directories whose owner is gone, and holds its owner.lock for the li
internal/testtmp/testtmp.go:47
↓ 5 callersMethodNeedsCandidateItems
NeedsCandidateItems returns the live items in scope that are router candidates: in a live, non-system collection, and an ask, a flagged item or holdin
internal/store/needs_read.go:149
↓ 5 callersFunctionNewEventsObserver
NewEventsObserver returns an observer writing into m.
internal/metrics/events_observer.go:19
↓ 5 callersFunctionNewMessage
NewMessage builds the message for one device: the fixed title and body for kind, and Data{nid, cid, kind, count}. id is the batch-local message id.
internal/notify/body.go:71
↓ 5 callersFunctionNewRRule
NewRRule construct a new RRule instance
internal/schedule/internal/rrule/rrule.go:151
↓ 5 callersFunctionNewRateLimiters
NewRateLimiters creates rate limiters with sensible defaults.
internal/server/middleware_ratelimit.go:456
↓ 5 callersFunctionNewRedisBus
NewRedisBus creates a Redis-backed Bus with the default replay buffer size and opens the shared subscription immediately. The client should already be
internal/watchevents/redis_bus.go:441
↓ 5 callersFunctionNewRedisBusWithKeys
NewRedisBusWithKeys is NewRedisBusWithReplaySize with an explicit key namespace (BUG-2724). cmd/pad/cmd_server.go uses this one, passing the value sha
internal/watchevents/redis_bus.go:468
↓ 5 callersFunctionNewRedisHealth
NewRedisHealth builds a prober for client. onProbe may be nil.
internal/server/redis_health.go:118
↓ 5 callersFunctionNewRedisTransport
NewRedisTransport returns a transport on keys' access_kicks channel. It uses its OWN client, cloned from client's options with context timeouts enable
internal/accesskick/accesskick.go:57
↓ 5 callersFunctionNewSupervisor
NewSupervisor builds a Supervisor. It starts no process: the first job does.
internal/materialize/supervisor.go:189
↓ 5 callersFunctionNormalizeFilenameWithSource
NormalizeFilenameWithSource is NormalizeFilename that also reports which of its branches decided the result, so the door that stores the name can reco
internal/attachments/filename.go:119
↓ 5 callersMethodNowRFC3339
NowRFC3339 returns the SQL expression for current UTC time in RFC3339 format. SQLite: strftime('%Y-%m-%dT%H:%M:%SZ', 'now') PostgreSQL: TO_CHAR(NOW()
internal/store/dialect.go:73
↓ 5 callersMethodOctetLength
OctetLength returns SQL for the BYTE length of a text-ish column, as the driver will hand it to Scan. The distinction matters here rather than being
internal/store/dialect.go:94
↓ 5 callersMethodPlanAttachmentCopy
PlanAttachmentCopy plans the attachment side of a cross-workspace item copy. It writes nothing. DR-11a, restated because it is the whole point of the
internal/store/attachments_copy_plan.go:373
↓ 5 callersMethodPreviewScheduleCarryFor
PreviewScheduleCarryFor is PreviewScheduleCarry for a reader who may see only some selected children (canRead nil: all) and link ends or gate blockers
internal/store/schedule_carry_copy.go:332
↓ 5 callersFunctionPriorityColor
PriorityColor returns a *color.Color appropriate for the given priority string.
internal/cli/format.go:50
↓ 5 callersFunctionProjectRewrittenLen
ProjectRewrittenLen returns the byte length RewriteBracketsAt WOULD produce for the same arguments, and how many rewrites it would apply, without buil
internal/links/links.go:393
↓ 5 callersMethodPushItemKeyed
PushItemKeyed is PushItem with an idempotency key (TASK-3585). With a key it retries once with that key after a transport error or a 5xx, and only aga
internal/cli/client.go:895
↓ 5 callersMethodPutNotificationSettings
PutNotificationSettings replaces userID's settings wholesale: a field left false is stored false, so a client that turns one off and sends the rest un
internal/store/notification_settings.go:33
↓ 5 callersFunctionQuestionFingerprint
QuestionFingerprint is hex sha256 of the model and one question's full definition. An answer is current only while its fingerprint still matches: rewo
internal/decision/runner.go:354
↓ 5 callersMethodRead
(p []byte)
internal/cli/client_import.go:38
↓ 5 callersMethodRead
(p []byte)
internal/server/handlers_import_bundle.go:101
↓ 5 callersMethodRead
(_ []byte)
cmd/pad/templates_picker_test.go:14
↓ 5 callersMethodReadCursor
ReadCursor returns when userID last marked workspaceID caught up (TASK-3615). found is false when the user never has: the catch-up window then falls b
internal/store/read_cursors.go:13
↓ 5 callersMethodRedeemContextCode
RedeemContextCode consumes code for installID, whose token carries epoch, and returns the item it names if, under the §6 locks, everything the code wa
internal/store/app_item_actions.go:366
↓ 5 callersMethodRemoveOAuthProvider
RemoveOAuthProvider removes a provider from the user's oauth_providers list, and forgets the provider account it was bound to, so a relink may bind a
internal/store/users.go:890
↓ 5 callersMethodRenewSessionIfStale
RenewSessionIfStale implements sliding-window expiration. When a session is past its renewal threshold (less than half its renewal window remaining) i
internal/store/sessions.go:341
↓ 5 callersFunctionReservedFieldKeysIn
ReservedFieldKeysIn returns the keys of a caller-supplied field map that name system metadata, sorted. Two kinds of map consult it, for the same reas
internal/items/overrides.go:94
↓ 5 callersMethodResolveBacklinksVisibility
ResolveBacklinksVisibility computes the (fullCollectionIDs, grantedItemIDs) access vectors for `userID` in `workspaceID`, REQUEST-INDEPENDENT. Mirrors
internal/store/backlinks_visibility.go:59
↓ 5 callersFunctionResolveWorkerID
ResolveWorkerID decides what goes in the X-Pad-Worker header (TASK-3613): the opaque id this session holds item leases under, so two sessions that sha
internal/cli/session_worker.go:26
↓ 5 callersMethodRetryable
Retryable reports whether any endpoint's failure is worth another drain pass. It is the ack decision, stated once here rather than re-derived by every
internal/webhooks/dispatcher.go:215
↓ 5 callersMethodRevokeAccessTokenFamily
RevokeAccessTokenFamily mirrors RevokeRefreshTokenFamily for access tokens. fosite calls these in pairs when revoking by request_id (the unified Revok
internal/store/oauth.go:627
↓ 5 callersMethodScan
(dest ...any)
internal/store/push_dispatch.go:66
↓ 5 callersFunctionScore
Score builds a Score question over an ORDERED scale, lowest level first. At least two levels are required.
internal/decision/decision.go:83
↓ 5 callersMethodSetAllowedWorkspaces
SetAllowedWorkspaces is the symmetric writer used by oauth/authorize/decide (TASK-952). Centralizing the key string here keeps producers + consumers i
internal/oauth/session.go:138
↓ 5 callersMethodSetBeforeCommitmentPinHookForTesting
SetBeforeCommitmentPinHookForTesting sets the pre-lock commitment seam. Production code must not call this. Set it only with no request in flight.
internal/store/testing_helpers.go:355
↓ 5 callersMethodSetLastRestoreSeq
SetLastRestoreSeq records the item.seq of the most recent restore for itemID, kept monotonically non-decreasing (a later restore always has a higher s
internal/collab/manager.go:250
↓ 5 callersMethodSetLinkClockForTesting
SetLinkClockForTesting sets the clock the linked-change time budget reads. Production code must not call this. Set it only with no request in flight.
internal/store/testing_helpers.go:363
↓ 5 callersMethodSetParentLinkAs
SetParentLinkAs is SetParentLink recording the account that wrote the link in item_links.user_id (BUG-3372). Request paths use it; "" names no account
internal/store/items.go:4581
↓ 5 callersMethodSetPushGateway
SetPushGateway sets the push gateway URL (PAD_PUSH_GATEWAY_URL). Empty means this server offers no push. Called once at startup, before the server acc
internal/server/handlers_push_devices.go:34
↓ 5 callersMethodSetScopeFlags
SetScopeFlags updates the three boolean scope flags atomically. All three values are written every call — there's no PATCH semantic at the store layer
internal/store/oauth_connections.go:279
↓ 5 callersMethodSetWebhookDispatcher
SetWebhookDispatcher attaches a webhook dispatcher for outgoing notifications. Delivery goroutines are routed through s.goAsync so they're tracked on
internal/server/server.go:1285
↓ 5 callersMethodSetWorkerID
SetWorkerID makes this client send id as X-Pad-Worker instead of the one ResolveWorkerID would pick: the `--worker-id` flag, which is also how a local
internal/cli/session_worker.go:110
↓ 5 callersFunctionShorthandNames
ShorthandNames lists the shorthand names, sorted, for help text.
internal/schedule/shorthand.go:27
↓ 5 callersMethodStartMaterializeRecovery
StartMaterializeRecovery starts the op-log recovery worker and its two triggers. A no-op without a Materializer (SetMaterializer) or without a collab
internal/server/materialize_recovery.go:194
↓ 5 callersFunctionStillDropped
StillDropped filters a MigrateResult.Dropped list down to the keys that are genuinely absent from the FINAL field map. Dropped is computed during mig
internal/items/migrate.go:219
↓ 5 callersMethodStop
Stop ends probing and waits for the goroutine to exit. Idempotent, and safe on a prober that was never started. MUST NOT be called from an onProbe ca
internal/server/redis_health.go:184
↓ 5 callersFunctionStripFrontmatter
StripFrontmatter removes YAML frontmatter (between --- delimiters) from content.
internal/cli/agents.go:249
↓ 5 callersFunctionStructuredFieldIsAppendable
StructuredFieldIsAppendable reports whether an append to key would be ACCEPTED on an item carrying fieldsJSON — i.e. whether the Append* helpers would
internal/models/item.go:1104
↓ 5 callersFunctionSweep
Sweep removes dir/prefix<pid>-* directories owned by this user whose owner has exited: the directory's owner.lock can be taken, or, for a directory wi
internal/testtmp/testtmp.go:69
↓ 5 callersFunctionText
Text returns the fixed body for kind. It is content-free by rule: no item title, comment text, workspace name or actor name ever reaches a push provid
internal/notify/body.go:39
↓ 5 callersFunctionTokenAllowedWorkspaceSet
TokenAllowedWorkspaceSet returns the token's allow-list as a slug-set for filtering a multi-workspace result, or nil when no per-slug gate applies. It
internal/server/context.go:239
↓ 5 callersMethodTopLevel
TopLevel returns the highest-probability level of a Score answer: its index and its name from the legend. ok is false for any other kind, or when the
internal/decision/decision.go:247
↓ 5 callersFunctionTracePGConnected
TracePGConnected records a test Postgres connection only when explicitly enabled. Call after a successful Ping, query, or migration, never sql.Open. h
internal/store/storetest/pgtrace.go:14
↓ 5 callersFunctionUndeclaredFieldKeys
UndeclaredFieldKeys returns the keys of fields the schema does not declare, sorted, excluding system-written metadata (BUG-2850). These keys are stor
internal/items/coerce.go:137
↓ 5 callersFunctionUnified
Unified renders a line-based unified diff of oldText → newText with the given lines of context (PLAN-3578: what a patch write hands back so the caller
internal/diff/unified.go:16
↓ 5 callersFunctionUniqueFieldConflictsMessage
UniqueFieldConflictsMessage is the one sentence every migrate door refuses with, so a move, a bulk move, a copy and its preview say the same thing.
internal/store/unique_fields.go:149
↓ 5 callersMethodUnreadSummary
UnreadSummary returns only memberships with unread messages and their total (TASK-4038).
internal/store/conversations.go:707
↓ 5 callersMethodUnsubscribe
Unsubscribe delegates to the inner bus and decrements the SSE connection gauge.
internal/metrics/instrumented_bus.go:89
← previousnext →2,901–3,000 of 28,840, ranked by callers