Repository navigation
docs enterprise state model
This file fixes the state names used across the suite and the rule that keeps different kinds of state apart. Transition tables (actor, validation, effects, reversal) live in section 6 of the owning module; this file is the canonical list of names. A module may not rename a state or add one without updating this catalog.
A record that an employee creates in the field has up to three independent states.
| Kind | Question it answers | Decided by | Shared definition |
|---|---|---|---|
| Operational state | What is happening in the real world? | The people doing the work | Per entity, §3 |
| Sync state | Where is this record between the device and the organization? | Device and server | §2, 10-offline-sync |
| Review state | Has the organization accepted this record administratively? | Reviewers | 04-business-rules §7 (BR-REV) |
They combine freely. Example for one trip:
| Moment | Operational | Sync | Review |
|---|---|---|---|
| Driver finishes the trip with no signal | COMPLETED |
SAVED_ON_DEVICE |
DRAFT |
| Phone reaches the network | COMPLETED |
SENT, then ACCEPTED
|
SUBMITTED |
| Supervisor asks for the missing toll receipt | COMPLETED |
ACCEPTED |
RETURNED |
| Driver adds the receipt offline | COMPLETED |
SAVED_ON_DEVICE (new operation) |
RETURNED |
| Server receives it; supervisor approves | COMPLETED |
ACCEPTED |
APPROVED |
A screen never shows one of these as if it were another: "finished" is not "received", and "received" is not "approved".
Device side, per operation:
stateDiagram-v2
[*] --> SAVED_ON_DEVICE
SAVED_ON_DEVICE --> SENDING: network available and dependencies sent
SENDING --> SAVED_ON_DEVICE: transient failure, retry later
SENDING --> SENT: server stored the operation
SENT --> ACCEPTED: server applied it
SENT --> NEEDS_REVIEW: server kept it for a person to resolve
SENT --> REJECTED: server refused it permanently
NEEDS_REVIEW --> ACCEPTED: resolved in favour
NEEDS_REVIEW --> REJECTED: resolved against
ACCEPTED --> [*]
REJECTED --> [*]
| State | Interface text (pt-BR) | Meaning |
|---|---|---|
SAVED_ON_DEVICE |
Salvo no aparelho | Durable on the phone only. |
SENDING |
Enviando | A delivery attempt is running. Shown as "Salvo no aparelho" with a progress hint. |
SENT |
Enviado | The server stored the operation and will answer. |
ACCEPTED |
Aceito pela empresa | Applied to the organization's records. Not the same as approved. |
NEEDS_REVIEW |
Precisa de revisão | Kept by the server; a person must resolve it. |
REJECTED |
Não aceito | Refused permanently, with a reason. Stays visible on the device until the user dismisses it. |
Server intake result per operation: ACCEPTED, ACCEPTED_FOR_REVIEW, REJECTED (permanent, with an error code), RETRY (transient; the device keeps SAVED_ON_DEVICE).
EMP-OFFL-004 presents only observed facts: a stored final receipt can establish its outcome directly, without invented intermediate SENT timestamps. SENDING is an exact live-attempt progress hint, never durable state. An immutable ACCEPTED_FOR_REVIEW receipt does not change when a later owning review source resolves the business record; that separate resolution must be observed before showing its outcome. Attachment delivery is independent evidence, and none of these sync states means business approval or payment.
Every state name below is canonical. "Kind" is O (operational), S (sync), R (review), L (lifecycle of a configuration or right).
| Entity | Kind | States | Owner |
|---|---|---|---|
| Organization | L |
PENDING_SETUP, ACTIVE, SUSPENDED, ARCHIVED, CLOSED
|
organizations |
| Legal entity | L |
DECLARED, VERIFICATION_REQUESTED, VERIFIED, REFUSED, LAPSED, REVOKED
|
organizations |
| Operating unit, team, cost centre | L |
ACTIVE, ARCHIVED
|
organizations |
| Consolidation grant (group) | L |
PROPOSED, ACTIVE, ENDED, DECLINED
|
organizations |
| Employee record | L |
ACTIVE, INACTIVE, TERMINATED
|
identity |
| Membership | L |
INVITED, ACTIVE, SUSPENDED, ENDED
|
identity |
| Invitation | L |
PENDING, ACCEPTED, DECLINED, EXPIRED, REVOKED, SUPERSEDED
|
identity |
| Activation code | L |
ISSUED, USED, EXPIRED, REVOKED, LOCKED
|
identity |
| Device | L |
ENROLLED, REVOKED
|
identity |
| Role assignment | L |
SCHEDULED, ACTIVE, ENDED (derived: INEFFECTIVE) |
07-permissions |
| Asset lifecycle | L |
DRAFT, ACTIVE, INACTIVE, DISPOSED, ARCHIVED
|
fleet |
| Asset availability (derived) | O |
AVAILABLE, RESERVED, IN_USE, IN_MAINTENANCE, BLOCKED, UNAVAILABLE
|
fleet |
| Asset assignment | L |
SCHEDULED, ACTIVE, ENDED
|
fleet |
| Reservation | O |
REQUESTED, CONFIRMED, FULFILLED, CANCELLED, NO_SHOW, EXPIRED
|
fleet |
| Meter reading | L |
VALID, SUSPECT, VOIDED
|
fleet |
| Mission | O |
DRAFT, PLANNED, ASSIGNED, ACCEPTED, DECLINED, IN_PROGRESS, COMPLETED, CANCELLED
|
trips |
| Trip | O |
PLANNED, ASSIGNED, ACCEPTED, IN_PROGRESS, PAUSED, COMPLETED, CANCELLED
|
trips |
| Trip | R | BR-REV states, plus VOIDED
|
trips |
| Checklist run | O |
IN_PROGRESS, COMPLETED_OK, COMPLETED_WITH_ISSUES, BLOCKING
|
maintenance |
| Incident and damage | O |
REPORTED, ACKNOWLEDGED, IN_TREATMENT, RESOLVED, DISMISSED
|
maintenance |
| Tracking session | O |
NOT_STARTED, RECORDING, SUSPENDED, INTERRUPTED, ENDED
|
gps-navigation |
| Track quality | L |
PRECISE, APPROXIMATE, INSUFFICIENT
|
gps-navigation |
| Live position freshness (derived) | O |
CURRENT, STALE, NO_SIGNAL
|
gps-navigation |
| Operation | S | §2 | 10-offline-sync |
| Fueling | R | BR-REV states, plus VOIDED
|
fuelings |
| Consumption interval (derived) | L |
COMPUTED, INSUFFICIENT_DATA, SUPERSEDED
|
fuelings |
| Document: storage | L |
UPLOADING, RECEIVED, STORED, QUARANTINED, FAILED, REPLACED, DELETED
|
documents |
| Document: extraction | L |
NONE, PENDING, DONE, FAILED
|
documents |
| Document: structure | L |
NOT_APPLICABLE, UNCHECKED, STRUCTURE_OK, STRUCTURE_INVALID
|
documents |
| Document: conference | R |
UNCONFERRED, CONFERRED_OK, DIVERGENT, ILLEGIBLE
|
documents |
| Document: reconciliation | L |
UNALLOCATED, PARTIALLY_ALLOCATED, RECONCILED, OVER_ALLOCATED
|
documents |
| Document: fiscal consultation | L |
NOT_CONSULTED, AUTHORIZED_AS_OF, CANCELLED_AS_OF, UNAVAILABLE
|
documents |
| Expense | R | BR-REV states, plus VOIDED
|
expenses-finance |
| Approval step | R |
PENDING, APPROVED, RETURNED, REJECTED, SKIPPED
|
expenses-finance |
| Payable | L |
OPEN, PARTIALLY_SETTLED, SETTLED, CANCELLED
|
expenses-finance |
| Advance | L |
REQUESTED, APPROVED, PAID, PARTIALLY_ACCOUNTED, ACCOUNTED, REJECTED, CANCELLED
|
expenses-finance |
| Budget hold | L |
ACTIVE, CONSUMED, RELEASED, EXPIRED
|
expenses-finance |
| Period | L |
OPEN, LOCKED, REOPENED (a month without history is OPEN at the implicit revision 1; LOCK, REOPEN with reason and RELOCK append history; LOCKED revisions are even, EDR-148) |
expenses-finance |
| Work order | O |
DRAFT, REQUESTED, QUOTED, APPROVED, SCHEDULED, IN_EXECUTION, COMPLETED, CLOSED, REJECTED, CANCELLED
|
maintenance |
| Maintenance plan occurrence | O |
UPCOMING, DUE, OVERDUE, DONE, SKIPPED
|
maintenance |
| Stock measurement reconciliation | L |
OPEN, EXPLAINED, ADJUSTED
|
fuel-stock |
| Finding | R |
OPEN, IN_REVIEW, CONFIRMED, JUSTIFIED, FALSE_POSITIVE, DISMISSED, SUPERSEDED
|
intelligence |
| Export job | L |
QUEUED, RUNNING, READY, EXPIRED, FAILED (RUNNING→QUEUED is a fenced lease release; the last attempt or a lease expired on it ends FAILED with EXPORT_ATTEMPTS_EXHAUSTED) |
intelligence |
| Import batch | L |
UPLOADED, PARSED, MAPPED, VALIDATED, CONFIRMED, APPLYING, APPLIED, APPLIED_WITH_ERRORS, FAILED, CANCELLED, REVERTED
|
imports-notifications-integrations |
| Notification | L |
PENDING, DELIVERED, FAILED, SUPPRESSED (PENDING = registered request not yet dispatched; DELIVERED/SUPPRESSED are per-recipient IN_APP history with reasons INELIGIBLE, MUTED, LIMITED; FAILED belongs to the external channels of EMP-NOTIF-002) |
imports-notifications-integrations |
| Integration connection | L |
CONFIGURED, ACTIVE, DEGRADED, DISABLED
|
imports-notifications-integrations |
| Station claim | R |
DRAFT, AWAITING_PROOF, CHECKING, NEEDS_INFORMATION, IN_REVIEW, APPROVED, DENIED, CANCELLED, EXPIRED (existing, wire-frozen) |
station-claims |
| Station authority | L |
ACTIVE, SUSPENDED, REVOKED, EXPIRED (existing grant states) |
station-claims |
| Contest case | R |
OPEN, UNDER_REVIEW, UPHELD, DISMISSED
|
station-claims |
| Announced price | L |
ACTIVE, EXPIRED, WITHDRAWN, SUPERSEDED
|
station-commerce |
| Promotion | L |
SCHEDULED, ACTIVE, ENDED, WITHDRAWN
|
station-commerce |
| Agreement | L |
PROPOSED, ACTIVE, SUSPENDED, ENDED, DECLINED, EXPIRED
|
station-commerce |
| Fueling authorization (voucher) | O |
ISSUED, REDEEMED, EXPIRED, CANCELLED, LOCKED
|
station-commerce |
| Subscription | L |
TRIALING, ACTIVE, PAST_DUE, SUSPENDED, CANCELLING, CANCELLED
|
subscriptions |
| API key | L |
ACTIVE, ROTATING, REVOKED, EXPIRED
|
data |
| Support session | L |
REQUESTED, APPROVED, ACTIVE, ENDED, DENIED, EXPIRED
|
back-office |
Mapping of the request's station-claim vocabulary to the frozen states: rascunho = DRAFT; enviado = AWAITING_PROOF or CHECKING; em análise = IN_REVIEW; pendente de informação = NEEDS_INFORMATION; aprovado = APPROVED; rejeitado = DENIED; expirado = EXPIRED (claim) or EXPIRED (authority); suspenso and revogado = SUSPENDED and REVOKED of the station authority; contestado = an open contest case linked to the authority or claim. Claims keep the existing wire-frozen names (STATION_PROFILE_CONTRACT_FREEZE) so that one coherent model exists.
- States are closed lists. An unknown state received from a newer server is shown as "unknown — update the app", never mapped to a known one (existing B-BR-P16 practice).
- Transitions are commands. Each transition has an actor, a permission, a validation and an audit event (BR-AUD-001). There is no free "set state".
- Terminal states stay terminal. A new attempt is a new record linked to the old one (a new claim, a new invitation, a new trip).
- Reversal is explicit. Where a transition can be undone, the module names the inverse command. Where it cannot, the correction is an amendment or a void (BR-AMD).
-
Derived states are computed, not stored as truth. Availability, freshness and
INEFFECTIVEare evaluated when read; a cached copy is a projection that can be rebuilt. - Time-driven transitions run on the server. Expiry is also checked at read time, so that a stopped job cannot leave an expired code, price or position looking valid.
-
Concurrent transitions resolve to one outcome. Every transition names the expected current state or revision; the loser receives
CONFLICTand nothing changes.
- Home
- Roadmap
- docs-README
- docs-android-build
- docs-android-design-system
- docs-android-forum
- docs-android-games
- docs-android-map-engine
- docs-android-navigation
- docs-android-ocr-image
- docs-android-ocr-live-framing
- docs-android-premium-area
- docs-android-premium-integration
- docs-android-release
- docs-android-ui-containers
- docs-architecture-android-stack
- docs-architecture-android
- docs-architecture-backend
- docs-architecture-data-sources
- docs-architecture-overview
- docs-architecture-sources-ev-research
- docs-architecture-sources-national-limits
- docs-architecture-sources-national-stations
- docs-architecture-sources-register
- docs-assets-app-tutorial-CAPTURE_CONTRACT
- docs-assets-app-tutorial-FABLE_LANDING_POLISH_PROMPT
- docs-assets-app-tutorial-README
- docs-assets-attribution
- docs-assets-brand-README
- docs-assets-flags-ATTRIBUTION
- docs-assets-fuel-icons-README
- docs-assets-games-fuel-v1-README
- docs-assets-home-icons-README
- docs-assets-landing-fleet-android-20261012-BRIEF
- docs-assets-landing-hero-20261011-BRIEF
- docs-assets-landing-illustrated-20261012-BRIEF
- docs-assets-landing-illustrated-20261012-README
- docs-assets-landing-minimal-20261012-BRIEF
- docs-assets-landing-open-data-20261026-BRIEF
- docs-assets-landing-redesign-20261011-PREPARATION_EVIDENCE
- docs-assets-landing-redesign-20261011-README
- docs-assets-landing-redesign-20261011-REFERENCE_BRIEF
- docs-assets-landing-sync-20261012-BRIEF
- docs-assets-map-icons-README
- docs-backend-anp-ingestion
- docs-backend-api
- docs-backend-community-pricing
- docs-backend-data-model
- docs-backend-domain-model
- docs-backend-driver-private-data
- docs-backend-forum-architecture
- docs-backend-forum-bulletins
- docs-backend-forum-sources
- docs-backend-payments-provider-admission
- docs-backend-payments-provider-register
- docs-backend-photos-capture
- docs-backend-photos-subset-submission
- docs-backend-premium-api
- docs-backend-premium-cloud-protocol
- docs-backend-testing
- docs-backend-toolchain
- docs-brand-app-icons
- docs-brand-identity
- docs-decisions-001-kotlin-compose-stack
- docs-decisions-002-price-import-immutability
- docs-decisions-003-nominatim-reverse-geocode
- docs-decisions-005-modular-monolith-and-postgresql
- docs-decisions-006-official-catalog-and-exact-contracts
- docs-decisions-007-anonymous-proof-of-possession
- docs-decisions-008-privacy-and-retention
- docs-decisions-009-community-consensus-and-projections
- docs-decisions-010-private-object-evidence
- docs-decisions-012-licensing-and-hosted-business
- docs-decisions-015-kotlin-multiplatform-shared-domain
- docs-decisions-016-android-commercial-community-ios-deferred
- docs-decisions-017-station-profile-and-verified-representation
- docs-decisions-021-community-first-contribution
- docs-decisions-022-comaps-derived-native-map-engine
- docs-decisions-023-admin-suite-granted-tiers-contributors
- docs-decisions-025-private-abastevo-empresas-organization-boundary
- docs-decisions-026-multilingual-public-site
- docs-decisions-README
- docs-enterprise-README
- docs-enterprise-architecture
- docs-enterprise-backlog-INDEX
- docs-enterprise-backlog-ep00-governance
- docs-enterprise-backlog-ep01-platform
- docs-enterprise-backlog-ep02-organizations
- docs-enterprise-backlog-ep03-identity-access
- docs-enterprise-backlog-ep04-sync
- docs-enterprise-backlog-ep05-fleet-meters
- docs-enterprise-backlog-ep06-trips
- docs-enterprise-backlog-ep07-gps-navigation
- docs-enterprise-backlog-ep08-fuelings
- docs-enterprise-backlog-ep09-documents
- docs-enterprise-backlog-ep10-expenses-finance
- docs-enterprise-backlog-ep11-maintenance
- docs-enterprise-backlog-ep12-fuel-stock
- docs-enterprise-backlog-ep13-intelligence
- docs-enterprise-backlog-ep14-station-claims
- docs-enterprise-backlog-ep15-station-commerce
- docs-enterprise-backlog-ep16-subscriptions
- docs-enterprise-backlog-ep17-data
- docs-enterprise-backlog-ep18-imports-notifications-integrations
- docs-enterprise-backlog-ep19-back-office
- docs-enterprise-backlog-ep20-release
- docs-enterprise-business-rules
- docs-enterprise-contract
- docs-enterprise-conventions
- docs-enterprise-data-offering
- docs-enterprise-decisions
- docs-enterprise-domain-model
- docs-enterprise-glossary
- docs-enterprise-journeys
- docs-enterprise-modules-back-office
- docs-enterprise-modules-data
- docs-enterprise-modules-documents
- docs-enterprise-modules-expenses-finance
- docs-enterprise-modules-fleet
- docs-enterprise-modules-fuel-stock
- docs-enterprise-modules-fuelings
- docs-enterprise-modules-gps-navigation
- docs-enterprise-modules-identity
- docs-enterprise-modules-imports-notifications-integrations
- docs-enterprise-modules-intelligence
- docs-enterprise-modules-maintenance
- docs-enterprise-modules-organizations
- docs-enterprise-modules-station-claims
- docs-enterprise-modules-station-commerce
- docs-enterprise-modules-subscriptions
- docs-enterprise-modules-trips
- docs-enterprise-offline-sync
- docs-enterprise-permissions
- docs-enterprise-portal-routes
- docs-enterprise-privacy-security
- docs-enterprise-product-vision
- docs-enterprise-source-admission
- docs-enterprise-state-model
- docs-enterprise-testing
- docs-enterprise-ux-app
- docs-enterprise-ux-web
- docs-operations-README
- docs-operations-backup
- docs-operations-deploy-agent
- docs-operations-dou-editions
- docs-operations-edge-cache
- docs-operations-enterprise-activation
- docs-operations-map-static-overlay
- docs-operations-moderation-feedback
- docs-operations-moderation-profiles
- docs-operations-monitoring
- docs-operations-operator-access
- docs-operations-payments
- docs-operations-premium-billing
- docs-operations-recovery
- docs-operations-registry-daily-sync
- docs-operations-registry-runs
- docs-product-README
- docs-product-admin-tiers
- docs-product-community-community-first
- docs-product-community-experience
- docs-product-community-metrics
- docs-product-community-moderation
- docs-product-community-safety
- docs-product-community-terms-pt-br
- docs-product-driver-suite-README
- docs-product-driver-suite-android-state
- docs-product-driver-suite-cloud-sync
- docs-product-driver-suite-cost-profiles-and-maintenance
- docs-product-driver-suite-driver-model-and-earnings
- docs-product-driver-suite-foundation-decisions
- docs-product-driver-suite-gps-lifecycle
- docs-product-driver-suite-mobile-hub
- docs-product-driver-suite-odometer-review
- docs-product-driver-suite-outbox-wire
- docs-product-driver-suite-quick-refuel
- docs-product-driver-suite-reports
- docs-product-driver-suite-shifts-and-distance
- docs-product-driver-suite-signed-commands
- docs-product-ev-README
- docs-product-ev-charging-stop-planner
- docs-product-ev-energy-model
- docs-product-ev-financial-method
- docs-product-ev-journey-ui
- docs-product-ev-preparation
- docs-product-ev-typed-data
- docs-product-exploration
- docs-product-forum-contract
- docs-product-forum-policies
- docs-product-glossary
- docs-product-landing-content
- docs-product-landing-guides
- docs-product-landing-organic-growth-i18n-plan
- docs-product-licensing
- docs-product-map-discovery
- docs-product-map-favorites-and-trips
- docs-product-map-reports-routing-guidance
- docs-product-notification-content
- docs-product-official-prices
- docs-product-open-source-business
- docs-product-overview
- docs-product-payments-README
- docs-product-payments-offer-policy
- docs-product-premium-README
- docs-product-premium-financial-method
- docs-product-premium-source-policy
- docs-product-stations-catalog
- docs-product-stations-fuel-feedback
- docs-product-stations-fuel-quality
- docs-product-stations-identity-and-ev-catalog
- docs-product-stations-profile-contract
- docs-product-stations-profile-representation
- docs-product-stations-registry-sources
- docs-product-vehicle-registration
- docs-product-vehicles-and-occurrences
- docs-security-android-terms-acceptance
- docs-security-free-account-access
- docs-security-identity-profile
- docs-security-media-location-policy
- docs-security-privacy-notice
- docs-security-privacy-policy
- docs-security-retention
- docs-security-risks
- docs-security-security-privacy
- docs-store-README
- docs-store-play-readiness
- docs-store-play-store-listing
- docs-store-ugc-safety
Source: AlexandreZanata/Abastevo @ e4a67580fc368a59bc1c0f1e0466fc011313f330