refactor: rename Processor to Webhook and Webhook to Entrypoint

The top-level entity that groups entrypoints and targets is now called
Webhook (was Processor). The inbound URL endpoint entity is now called
Entrypoint (was Webhook). This rename affects database models, handler
comments, routes, and README documentation.

closes #12
This commit is contained in:
clawbot
2026-03-01 15:44:22 -08:00
committed by user
parent b5cf4c3d2f
commit 7bbe47b943
10 changed files with 63 additions and 63 deletions

View File

@@ -1,14 +1,16 @@
package database
// Webhook represents a webhook endpoint that feeds into a processor
// Webhook represents a webhook processing unit that groups entrypoints and targets
type Webhook struct {
BaseModel
ProcessorID string `gorm:"type:uuid;not null" json:"processor_id"`
Path string `gorm:"uniqueIndex;not null" json:"path"` // URL path for this webhook
Description string `json:"description"`
Active bool `gorm:"default:true" json:"active"`
UserID string `gorm:"type:uuid;not null" json:"user_id"`
Name string `gorm:"not null" json:"name"`
Description string `json:"description"`
RetentionDays int `gorm:"default:30" json:"retention_days"` // Days to retain events
// Relations
Processor Processor `json:"processor,omitempty"`
User User `json:"user,omitempty"`
Entrypoints []Entrypoint `json:"entrypoints,omitempty"`
Targets []Target `json:"targets,omitempty"`
}