Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/PerpetualSoftware/pad
/ functions
Functions
28,840 in github.com/PerpetualSoftware/pad
⨍
Functions
28,840
◇
Types & classes
3,245
↓ 5 callers
Method
EndAppDelivery
(deliveryID string)
internal/webhooks/app_delivery.go:50
↓ 5 callers
Method
EnsureChatDMContext
EnsureChatDMContext lets the monitor cancel its background DM ensure on exit.
internal/cli/client.go:3686
↓ 5 callers
Function
EnvConfig
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 callers
Method
Error
()
internal/server/handlers_items_bulk.go:103
↓ 5 callers
Function
ErrorType
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 callers
Method
FTSMatch
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 callers
Method
FinishRotate
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 callers
Method
For
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 callers
Function
GenerateUsername
--- 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 callers
Method
GetAgentRole
(workspaceID, idOrSlug string)
internal/store/agent_roles.go:40
↓ 5 callers
Method
GetAllItemProgress
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 callers
Method
GetAttachmentVariant
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 callers
Method
GetCollection
(wsSlug, collSlug string)
internal/cli/client.go:302
↓ 5 callers
Method
GetDashboard
--- 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 callers
Method
GetMemberCollectionAccessQ
GetMemberCollectionAccessQ is GetMemberCollectionAccess parameterized over its executor (see Queryer).
internal/store/workspace_members.go:707
↓ 5 callers
Method
GetParentMap
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 callers
Method
GetShareLink
GetShareLink retrieves a share link by ID.
internal/store/share_links.go:118
↓ 5 callers
Method
GetUserByUsername
GetUserByUsername retrieves a user by username (case-insensitive).
internal/store/users.go:196
↓ 5 callers
Method
GetWatchByUserItem
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 callers
Method
GetWebhook
GetWebhook retrieves a single webhook by ID.
internal/store/webhooks.go:72
↓ 5 callers
Method
GetWorkspace
(slug string)
internal/cli/client.go:233
↓ 5 callers
Method
GetWorkspaceGroup
(ctx context.Context, userID, id string)
internal/store/workspace_groups.go:84
↓ 5 callers
Method
GetWorkspaceImportStatus
GetWorkspaceImportStatus answers the workspace's import marker, or nil when it has none (the normal case).
internal/store/workspace_import_status.go:36
↓ 5 callers
Method
InsertItemVerifications
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 callers
Method
InstallClientIDTx
InstallClientIDTx returns the install's client id.
internal/store/install_clients.go:239
↓ 5 callers
Method
ItemLastRestoreSeq
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 callers
Method
Iterator
Iterator returns an iterator for rrule.Set
internal/schedule/internal/rrule/rruleset.go:134
↓ 5 callers
Function
Judge
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 callers
Method
ListAgentRoles
(workspaceID string)
internal/store/agent_roles.go:64
↓ 5 callers
Method
ListAllItemsReport
ListAllItemsReport is ListAllItems from startOffset, also returning the first page's UndeclaredKeys (BUG-4024).
internal/cli/client.go:451
↓ 5 callers
Function
ListAllTemplates
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 callers
Method
ListItemVersionsResolvedSnapshot
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 callers
Method
ListStarredItems
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 callers
Method
ListUserAppGrants
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 callers
Method
MCPBearerAuth
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 callers
Method
MaxOpLogID
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 callers
Function
MetricsMiddleware
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 callers
Function
MigrateCloseStateChange
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 callers
Method
MigrateItemFieldValues
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 callers
Method
MinGap
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 callers
Function
MkdirTemp
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 callers
Method
NeedsCandidateItems
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 callers
Function
NewEventsObserver
NewEventsObserver returns an observer writing into m.
internal/metrics/events_observer.go:19
↓ 5 callers
Function
NewMessage
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 callers
Function
NewRRule
NewRRule construct a new RRule instance
internal/schedule/internal/rrule/rrule.go:151
↓ 5 callers
Function
NewRateLimiters
NewRateLimiters creates rate limiters with sensible defaults.
internal/server/middleware_ratelimit.go:456
↓ 5 callers
Function
NewRedisBus
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 callers
Function
NewRedisBusWithKeys
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 callers
Function
NewRedisHealth
NewRedisHealth builds a prober for client. onProbe may be nil.
internal/server/redis_health.go:118
↓ 5 callers
Function
NewRedisTransport
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 callers
Function
NewSupervisor
NewSupervisor builds a Supervisor. It starts no process: the first job does.
internal/materialize/supervisor.go:189
↓ 5 callers
Function
NormalizeFilenameWithSource
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 callers
Method
NowRFC3339
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 callers
Method
OctetLength
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 callers
Method
PlanAttachmentCopy
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 callers
Method
PreviewScheduleCarryFor
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 callers
Function
PriorityColor
PriorityColor returns a *color.Color appropriate for the given priority string.
internal/cli/format.go:50
↓ 5 callers
Function
ProjectRewrittenLen
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 callers
Method
PushItemKeyed
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 callers
Method
PutNotificationSettings
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 callers
Function
QuestionFingerprint
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 callers
Method
Read
(p []byte)
internal/cli/client_import.go:38
↓ 5 callers
Method
Read
(p []byte)
internal/server/handlers_import_bundle.go:101
↓ 5 callers
Method
Read
(_ []byte)
cmd/pad/templates_picker_test.go:14
↓ 5 callers
Method
ReadCursor
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 callers
Method
RedeemContextCode
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 callers
Method
RemoveOAuthProvider
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 callers
Method
RenewSessionIfStale
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 callers
Function
ReservedFieldKeysIn
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 callers
Method
ResolveBacklinksVisibility
ResolveBacklinksVisibility computes the (fullCollectionIDs, grantedItemIDs) access vectors for `userID` in `workspaceID`, REQUEST-INDEPENDENT. Mirrors
internal/store/backlinks_visibility.go:59
↓ 5 callers
Function
ResolveWorkerID
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 callers
Method
Retryable
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 callers
Method
RevokeAccessTokenFamily
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 callers
Method
Scan
(dest ...any)
internal/store/push_dispatch.go:66
↓ 5 callers
Function
Score
Score builds a Score question over an ORDERED scale, lowest level first. At least two levels are required.
internal/decision/decision.go:83
↓ 5 callers
Method
SetAllowedWorkspaces
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 callers
Method
SetBeforeCommitmentPinHookForTesting
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 callers
Method
SetLastRestoreSeq
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 callers
Method
SetLinkClockForTesting
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 callers
Method
SetParentLinkAs
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 callers
Method
SetPushGateway
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 callers
Method
SetScopeFlags
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 callers
Method
SetWebhookDispatcher
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 callers
Method
SetWorkerID
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 callers
Function
ShorthandNames
ShorthandNames lists the shorthand names, sorted, for help text.
internal/schedule/shorthand.go:27
↓ 5 callers
Method
StartMaterializeRecovery
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 callers
Function
StillDropped
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 callers
Method
Stop
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 callers
Function
StripFrontmatter
StripFrontmatter removes YAML frontmatter (between --- delimiters) from content.
internal/cli/agents.go:249
↓ 5 callers
Function
StructuredFieldIsAppendable
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 callers
Function
Sweep
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 callers
Function
Text
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 callers
Function
TokenAllowedWorkspaceSet
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 callers
Method
TopLevel
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 callers
Function
TracePGConnected
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 callers
Function
UndeclaredFieldKeys
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 callers
Function
Unified
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 callers
Function
UniqueFieldConflictsMessage
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 callers
Method
UnreadSummary
UnreadSummary returns only memberships with unread messages and their total (TASK-4038).
internal/store/conversations.go:707
↓ 5 callers
Method
Unsubscribe
Unsubscribe delegates to the inner bus and decrements the SSE connection gauge.
internal/metrics/instrumented_bus.go:89
← previous
next →
2,901–3,000 of 28,840, ranked by callers