OutboxEntry
Outbox entry for a pending Book-Keeper call.
Attributes: operation: The external operation to perform. payload_json: JSON-serialised arguments for the call. status: Current lifecycle state. retry_count: Number of failed attempts so far. error: Last error message (if any). created_at: When this entry was created. processed_at: When the relay successfully processed the entry. reference_doctype: Source document type (e.g. ``"PaymentVoucher"``). reference_id: Source document identifier.Source: doctype.py
Fields
Section titled “Fields”| Field | Type | Required | Description | Validators |
|---|---|---|---|---|
| outbox_id | str | Unique outbox entry ID (UUID) | - | |
| operation | str | ( |
"Operation to dispatch: post_gl_entry | cancel_gl_entry | " "post_journal_entry | cancel_journal_entry | sync_account") | - || payload_json | str | | JSON-serialised call arguments | - | | status | str | | Lifecycle state: Pending | Sent | GL Rejected | Dead | - | | retry_count | int | | Number of failed relay attempts | - | | error | None | | Last error message from Book-Keeper or transport | - | | created_at | datetime | | UTC timestamp when the entry was created | - | | processed_at | None | | UTC timestamp when the relay processed the entry | - | | reference_doctype | str | | Source document type (e.g. PaymentVoucher, JournalEntry, Account) | - | | reference_id | str | | Source document identifier | - |
Permissions
Section titled “Permissions”| Role | Create | Delete | Read | Write |
|---|---|---|---|---|
| All | ✓ | ✓ | ✓ | ✓ |
Configuration
Section titled “Configuration”| Setting | Value |
|---|---|
| Submittable | False |
| Track Changes | True |
Controller
Section titled “Controller”Controller hooks are implemented in *_controller.py files.
Available lifecycle hooks:
validate()- Called before save, raise exceptions for validation errorsbefore_insert()- Called before inserting a new documentafter_insert()- Called after successfully insertingbefore_save()- Called before saving (insert or update)after_save()- Called after savingbefore_delete()- Called before deletingafter_delete()- Called after deleting