Audit log - Dockhand
{#if $licenseStore.isEnterprise && total > 0} Showing {visibleStart}-{visibleEnd} of {total} {/if} {#if $licenseStore.isEnterprise}
{$auditSseConnected ? 'Live' : 'Connecting'}
{#if showExportMenu}
{/if}
{/if}
{#if $licenseStore.loading}

Loading...

{:else if !$licenseStore.isEnterprise}

Enterprise feature

Audit logging is an enterprise feature that tracks all user actions for compliance and security monitoring.

{:else}
Filters
{#if filterUsernames.length === 0} All users {:else if filterUsernames.length === 1} {filterUsernames[0]} {:else} {filterUsernames.length} users {/if} {#if filterUsernames.length > 0} {/if} {#each users as user} {user} {/each} {#if filterEntityTypes.length === 0} All entities {:else if filterEntityTypes.length === 1} {entityTypes.find(e => e.value === filterEntityTypes[0])?.label || filterEntityTypes[0]} {:else} {filterEntityTypes.length} entities {/if} {#if filterEntityTypes.length > 0} {/if} {#each entityTypes as type} {type.label} {/each} {#if filterActions.length === 0} All actions {:else if filterActions.length === 1} {actionTypes.find(a => a.value === filterActions[0])?.label || filterActions[0]} {:else} {filterActions.length} actions {/if} {#if filterActions.length > 0} {/if} {#each actionTypes as action} {action.label} {/each} {#if environments.length > 0} {@const selectedEnv = environments.find(e => e.id === filterEnvironmentId)} {@const SelectedEnvIcon = selectedEnv ? getIconComponent(selectedEnv.icon || 'globe') : Server} filterEnvironmentId = v ? parseInt(v) : null} > {#if filterEnvironmentId === null} All environments {:else} {selectedEnv?.name || 'Environment'} {/if} All environments {#each environments as env} {@const EnvIcon = getIconComponent(env.icon || 'globe')} {env.name} {/each} {/if} { selectedDatePreset = v || ''; if (v !== 'custom') { applyDatePreset(v || ''); } }} > {#if selectedDatePreset === 'custom'} Custom {:else if selectedDatePreset} {datePresets.find(d => d.value === selectedDatePreset)?.label || 'All time'} {:else} All time {/if} All time {#each datePresets as preset} {preset.label} {/each} Custom range... {#if selectedDatePreset === 'custom'} {/if} {#if filterUsernames.length > 0 || filterEntityTypes.length > 0 || filterActions.length > 0 || filterEnvironmentId !== null || selectedDatePreset} {/if}
Timestamp
Environment
User
Action
Entity
Name
IP address
{#if loading || !initialized}
Loading...
{:else if logs.length === 0}

No audit log entries found

{:else}
{#each visibleLogs as log (log.id)}
showDetails(log)} role="button" tabindex="0" onkeydown={(e) => e.key === 'Enter' && showDetails(log)} >
{formatTimestamp(log.timestamp)}
{#if log.environment_name} {@const LogEnvIcon = getIconComponent(log.environment_icon || 'globe')}
{log.environment_name}
{:else} - {/if}
{log.username}
{log.entity_type}
{log.entity_name || log.entity_id || '-'}
{log.ip_address || '-'}
{/each}
{#if loadingMore}
Loading more...
{/if} {#if !hasMore && logs.length > 0}
End of results ({total.toLocaleString()} entries)
{/if} {/if}
{/if}
Audit log details {#if selectedLog}

{formatTimestamp(selectedLog.timestamp)}

{selectedLog.username}

{selectedLog.action}

{selectedLog.entity_type}

{#if selectedLog.entity_name}

{selectedLog.entity_name}

{/if} {#if selectedLog.entity_id}

{selectedLog.entity_id}

{/if} {#if selectedLog.environment_id}

{selectedLog.environment_id}

{/if} {#if selectedLog.ip_address}

{selectedLog.ip_address}

{/if}
{#if selectedLog.description}

{selectedLog.description}

{/if} {#if selectedLog.user_agent}

{selectedLog.user_agent}

{/if} {#if selectedLog.details}
{JSON.stringify(selectedLog.details, null, 2)}
{/if}
{/if}
{#if showExportMenu} {/if}