Files
probo/pkg/server/api/console/v1/graphql/audit_log.graphql
Sacha Al Himdani cd6c46212a Add log export for audit logs and SCIM events
Route audit-log and SCIM-event exports through export_jobs with typed
arguments, an iam BuildAndUploadExport/SendExportEmail implementation,
and a concurrent export-job worker with stale recovery. Stream JSONL via
page.WalkAll into S3, and expose the request flow on console, connect,
MCP, and CLI.

Co-authored-by: Bryan Frimin <bryan@getprobo.com>
Signed-off-by: Sacha Al Himdani <sacha@probo.com>
2026-07-29 18:57:31 +02:00

87 lines
2.0 KiB
GraphQL

enum AuditLogActorType
@goModel(
model: "go.probo.inc/probo/pkg/coredata.AuditLogActorType"
) {
USER
@goEnum(
value: "go.probo.inc/probo/pkg/coredata.AuditLogActorTypeUser"
)
API_KEY
@goEnum(
value: "go.probo.inc/probo/pkg/coredata.AuditLogActorTypeAPIKey"
)
SYSTEM
@goEnum(
value: "go.probo.inc/probo/pkg/coredata.AuditLogActorTypeSystem"
)
}
enum AuditLogEntryOrderField
@goModel(
model: "go.probo.inc/probo/pkg/coredata.AuditLogEntryOrderField"
) {
CREATED_AT
@goEnum(
value: "go.probo.inc/probo/pkg/coredata.AuditLogEntryOrderFieldCreatedAt"
)
}
input AuditLogEntryOrder
@goModel(
model: "go.probo.inc/probo/pkg/server/api/console/v1/types.AuditLogEntryOrderBy"
) {
field: AuditLogEntryOrderField!
direction: OrderDirection!
}
input AuditLogEntryFilter {
action: String
actorId: ID
resourceType: String
resourceId: ID
}
type AuditLogEntry implements Node {
id: ID!
organization: Organization @goField(forceResolver: true)
actorId: ID!
actorType: AuditLogActorType!
action: String!
resourceType: String!
resourceId: ID!
metadata: String
createdAt: Datetime!
permission(action: String!): Boolean! @goField(forceResolver: true)
}
type AuditLogEntryConnection
@goModel(
model: "go.probo.inc/probo/pkg/server/api/console/v1/types.AuditLogEntryConnection"
) {
edges: [AuditLogEntryEdge!]!
pageInfo: PageInfo!
totalCount: Int! @goField(forceResolver: true)
}
type AuditLogEntryEdge {
cursor: CursorKey!
node: AuditLogEntry!
}
extend type Mutation {
requestAuditLogExport(
input: RequestAuditLogExportInput!
): RequestAuditLogExportPayload!
}
input RequestAuditLogExportInput {
organizationId: ID!
fromTime: Datetime!
toTime: Datetime!
}
type RequestAuditLogExportPayload {
exportJobId: ID!
}