Skip to main content

Cards

Cards represent physical MAES fuel cards that can be managed through the API.

Card Lifecycle

┌─────────┐      activate()      ┌─────────┐
│ NEW │ ──────────────────► │ ACTIVE │
└─────────┘ └────┬────┘

┌───────────┴───────────┐
│ │
disable() enable()
│ │
▼ │
┌──────────┐ │
│ INACTIVE │ ─────────────────┘
└──────────┘

Card Statuses

StatusDescriptionCan EnableCan Disable
newCard synced but not yet activated
activeCard activated with fuel enabled
inactiveCard activated but fuel disabled

Card Properties

PropertyTypeDescription
idUUIDUnique identifier
cardNumberstringPhysical card number
maesCardIdstringMAES internal ID
environmentenumsandbox or production
statusenumnew, active, inactive
licensePlatestringVehicle license plate
driverstringDriver name
expirationDatedatetimeCard expiration date
authGasolinebooleanGasoline authorization
authDieselbooleanDiesel authorization
authLpgbooleanLPG authorization
authHeatingOilbooleanHeating oil authorization
syncStatusenumsynced, pending, failed
lastSyncedAtdatetimeLast sync timestamp

Fuel Authorizations

Each card has four fuel type authorizations:

AuthorizationDescription
authGasolineGasoline/Petrol (E5/E10)
authDieselDiesel fuel
authLpgLPG/Autogas
authHeatingOilHeating oil

When you enable a card, all four authorizations are set to true. When you disable a card, all four are set to false.

Card Operations

Activate a Card

Activates a new card with license plate and driver information.

POST /projects/{projectId}/cards/{cardId}/activate
{
"licensePlate": "AB-123-CD",
"driver": "John Doe"
}
info

Only cards with status: new can be activated. After activation, all fuel authorizations are enabled by default.

Enable a Card

Enables all fuel authorizations for an inactive card.

POST /projects/{projectId}/cards/{cardId}/enable

Disable a Card

Disables all fuel authorizations for an active card.

POST /projects/{projectId}/cards/{cardId}/disable

Sync Status

Cards are synced from MAES portal in the background:

Sync StatusDescription
syncedData is up-to-date with MAES
pendingOperation in progress
failedSync failed (check syncErrorMessage)

Example Card Object

{
"id": "09c9861c-4c4b-411f-be85-c16ed7e26da4",
"cardNumber": "782521009000153700",
"maesCardId": "134208",
"environment": "production",
"status": "active",
"licensePlate": "AB-123-CD",
"driver": "John Doe",
"expirationDate": "2027-12-31T00:00:00.000Z",
"authGasoline": true,
"authDiesel": true,
"authLpg": true,
"authHeatingOil": true,
"syncStatus": "synced",
"lastSyncedAt": "2025-12-27T16:24:05.712Z",
"createdAt": "2025-12-26T10:30:00.000Z",
"updatedAt": "2025-12-27T16:24:05.712Z"
}