Billing Tasks
A billing task is a single job in the platform’s processing queue. The platform does its heavy work in the background, and each piece of work is tracked as a billing task. This lets you see what the system is doing and spot anything that has gone wrong.
Overview
Section titled “Overview”Most of the platform’s longer jobs run as billing tasks. Common examples are:
- Generating invoices during a billing run
- Importing call data record files from carriers
- Sending bill emails to customers
- Collecting payments by Direct Debit or card
You don’t create or run billing tasks by hand. The platform adds them to the queue and works through them in priority order. The Billing Tasks list is there so you can watch progress and troubleshoot, not to start jobs yourself.
Where Billing Tasks Come From
Section titled “Where Billing Tasks Come From”- Billing runs queue invoice production once you request bills. See Request Bills.
- CDR processing queues an import task for each call data file. See Supply Files.
- Email Bills queues a task per batch of emails. See Email Bills.
- Payment runs queue collection tasks for Direct Debit and card payments. See Payment Runs.
Key Fields
Section titled “Key Fields”Billing Task
Section titled “Billing Task”This section contains the core information about the billing task, including the task type, status, customer association, and attachment details.
| Field | Description |
|---|---|
| Billing Task Type | The type of billing task to be performed |
| Billing Task Status | Current status of the billing task |
| Customer | Customer this billing task is for, if applicable |
| Task For | ID of the specific object this task is attached to |
Task Details
Section titled “Task Details”Detailed information about the task execution including timing, parameters, and processing flags.
| Field | Description |
|---|---|
| Parameters | JSON parameters for the billing task execution |
| Priority | Processing priority of this billing task |
| Retry Count | Number of times this task has been retried |
| Added Date | Date when this billing task was added to the queue |
| Delay Date | Date when this billing task should be processed (if delayed) |
| Started Date | Date when processing of this billing task began |
| Ended Date | Date when processing of this billing task completed |
| Test Mode | Whether this task is running in test mode |
| Activity Log | Log of processing activities for this billing task |
System Information
Section titled “System Information”System-generated information and activity tracking for this billing task.
| Field | Description |
|---|---|
| Last Modified | Timestamp of the most recent modification to this billing task |
| Created | Timestamp when this billing task was created |
A few fields are worth explaining:
- Billing Task Status tells you where the job is:
- Pending: waiting in the queue to start.
- Running: currently being processed.
- Completed: finished successfully.
- Error: hit a problem but may be retried.
- Failed: stopped after running out of retries or hitting a fatal problem.
- Skipped: deliberately passed over (for example, superseded by a later task).
- Billing Task Type is the kind of job, such as invoice generation or CDR import.
- Customer and Task For link the task to the record it relates to, when it applies to one.
- Parameters holds the job’s inputs as JSON. Activity Log records what happened step by step, which is the first place to look when a task shows an Error or Failed status.
- Retry Count shows how many times the platform has re-attempted the job. Priority controls the order tasks run in.
- Test Mode flags tasks that ran as a dry run rather than for real.
Monitoring Billing Tasks
Section titled “Monitoring Billing Tasks”Viewing the Queue
Section titled “Viewing the Queue”Open the Billing Tasks list to see recent and current jobs. The list is colour-coded by status, so running, completed, error, failed and skipped tasks stand out at a glance.
Troubleshooting a Stuck or Failed Task
Section titled “Troubleshooting a Stuck or Failed Task”- Open the task from the list.
- Check the Billing Task Status and Retry Count.
- Read the Activity Log for the error message and the step that failed.
- Fix the underlying cause (for example, a bad CDR file or a payment provider issue), then let the platform retry on its next pass.
Tasks normally clear themselves once the cause is resolved. If a task is no longer needed, you can delete it from the list.
Important: Billing tasks run automatically as part of daily processing and billing runs. You don’t need to start them, and they should not be left for manual action.
Access
Section titled “Access”- Permission: Users need the Billing Tasks permission to view the queue. Assign it through the usual user or user group permissions.
- Visibility: The list is most useful to billing and support administrators monitoring a run.
Related
Section titled “Related”- Billing Run: the main workflow that queues invoice production.
- Supply Files (CDRs): how call data files are uploaded and queued for import.
- Email Bills: sending invoices, which queues email tasks.
- Payment Runs: collecting payments, which queues collection tasks.
Want billing that runs itself in the background while you get on with your day? see how SAFE Billing Platform automates the whole billing cycle