Odoo 19.0 Community · Persistent

account.analytic.line: fields, relations and API

The account.analytic.line model ("Analytic Line") is a persistent model declared by the Analytic Accounting module, then extended by 8 other modules. It exposes 51 fields, 43 of them declared directly on the model; 3 fields from other models point to it. Below you will find every field with its technical name, type, label and relations, followed by an Odoo 19 JSON-2 API call.

Model identity

Technical name
account.analytic.line
Label
Analytic Line
Type
Persistent (models.Model)
SQL table
account_analytic_line
Origin module
Analytic Accounting (analytic)
Extended by
account, sale, hr_timesheet, mrp_account, project_stock_account, project_timesheet_holidays, sale_timesheet, website_timesheet
Default order (_order)
date desc, id desc
Inherits from (mixins)
analytic.plan.fields.mixin

Model fields

43 own fields, 2 inherited from mixins and 6 automatic ORM fields. Click a name to get a direct link to that field.

51 of 51 fields shown

Technical nameLabelTypeDetails
allow_billableAllow Billableboolean

related: project_id.allow_billable

added by Sales Timesheet (sale_timesheet)

amountAmountmonetary
required
analytic_distributionAnalytic Distributionjson
computed
analytic_precisionAnalytic Precisioninteger
analytic_profitabilityProfitabilityselection
computed

Values: uncategorized (Uncategorized), revenue (Revenue), loss (Loss)

added by Invoicing (account)

calendar_display_nameCalendar Display Namechar
computed

added by Task Logs (hr_timesheet)

categoryCategoryselection

Values: other (Other)

codeCodechar

added by Invoicing (account)

commercial_partner_idCommercial Partnermany2one
computed

added by Sales Timesheet (sale_timesheet)

company_idCompanymany2one
requiredread-only
currency_idCurrencymany2one
read-only

related: company_id.currency_id

dateDatedate
required
department_idDepartmentmany2one
computed, stored

added by Task Logs (hr_timesheet)

employee_idEmployee

Define an 'hourly cost' on the employee to track the cost of their time.

many2one

added by Task Logs (hr_timesheet)

encoding_uom_idEncoding Uommany2one
computed

added by Task Logs (hr_timesheet)

general_account_idFinancial Accountmany2one
computed, stored

added by Invoicing (account)

global_leave_idGlobal Time Offmany2one

added by Timesheet when on Time Off (project_timesheet_holidays)

holiday_idTime Off Requestmany2one

added by Timesheet when on Time Off (project_timesheet_holidays)

is_so_line_editedIs Sales Order Item Manually Editedboolean

added by Sales Timesheet (sale_timesheet)

job_titleJob Titlechar

related: employee_id.job_title

added by Task Logs (hr_timesheet)

journal_idFinancial Journalmany2one
read-only

related: move_line_id.journal_id

added by Invoicing (account)

manager_idManagermany2one

related: employee_id.parent_id

added by Task Logs (hr_timesheet)

message_partner_idsMessage Partnermany2many
computed

added by Task Logs (hr_timesheet)

milestone_idMilestonemany2one

related: task_id.milestone_id

added by Task Logs (hr_timesheet)

move_line_idJournal Itemmany2one

added by Invoicing (account)

nameDescriptionchar
required
order_idOrdermany2one
read-only

related: so_line.order_id

added by Sales Timesheet (sale_timesheet)

parent_task_idParent Taskmany2one

related: task_id.parent_id

added by Task Logs (hr_timesheet)

partner_idPartnermany2one
computed, stored
product_categoryProduct Categorymany2one

related: product_id.categ_id

added by Invoicing (account)

product_idProductmany2one

added by Invoicing (account)

product_uom_idUnitmany2one
project_idProjectmany2one
computed, stored

added by Task Logs (hr_timesheet)

readonly_timesheetReadonly Timesheetboolean
computed

added by Task Logs (hr_timesheet)

refRef.char

added by Invoicing (account)

sale_order_stateSale Order Stateselection

related: order_id.state

added by Sales Timesheet (sale_timesheet)

so_lineSales Order Item

Sales order item to which the time spent will be added in order to be invoiced to your customer. Remove the sales order item for the timesheet entry to be non-billable.

many2one
computed, stored

added by Sales (sale)

task_idTaskmany2one
computed, stored

added by Task Logs (hr_timesheet)

timesheet_invoice_idInvoice

Invoice created from the timesheet

many2one
read-only

added by Sales Timesheet (sale_timesheet)

timesheet_invoice_typeBillable Typeselection
read-onlycomputed, stored

Values: billable_time (Billed on Timesheets), billable_fixed (Billed at a Fixed price), billable_milestones (Billed on Milestones), billable_manual (Billed Manually), non_billable (Non-Billable), timesheet_revenues (Timesheet Revenues), service_revenues (Service Revenues), other_revenues (Other revenues), other_costs (Other costs)

added by Sales Timesheet (sale_timesheet)

unit_amountQuantityfloat
user_idUsermany2one
computed, stored
account_idProject Accountmany2one

inherited from analytic.plan.fields.mixin

auto_account_idAnalytic Accountmany2one
computed

inherited from analytic.plan.fields.mixin

create_dateCreated ondatetime
read-onlyautomatic
create_uidCreated bymany2one
read-onlyautomatic
display_nameDisplay Namechar
read-onlycomputedautomatic
idIDinteger
read-onlyautomatic
write_dateLast Updated ondatetime
read-onlyautomatic
write_uidLast Updated bymany2one
read-onlyautomatic

Relations

Models linked from this model

Fields of other models pointing here

Reading this model through the API

Odoo 19 JSON-2 API call reading the first five records with real fields of the model. Replace the instance, database and API key with your own.

curl
curl -X POST "https://your-instance.odoo.com/json/2/account.analytic.line/search_read" \
  -H "Authorization: bearer $ODOO_API_KEY" \
  -H "X-Odoo-Database: your-db" \
  -H "Content-Type: application/json" \
  -d '{"domain":[],"fields":["name","amount","company_id","date","currency_id"],"limit":5}'
Python (requests)
import requests

BASE_URL = "https://your-instance.odoo.com/json/2"
headers = {"Authorization": f"bearer {API_KEY}", "X-Odoo-Database": "your-db"}

res = requests.post(
    f"{BASE_URL}/account.analytic.line/search_read",
    headers=headers,
    json={"domain": [], "fields": ["name","amount","company_id","date","currency_id"], "limit": 5},
)
res.raise_for_status()
print(res.json())
  • External API access requires Odoo's Custom plan.
  • XML-RPC and JSON-RPC will be removed in Odoo 22 (fall 2028): use JSON-2.
  • The access rights and record rules of the key's user apply.

Cite this tool

Writing a tutorial, internal documentation or a forum answer? Copy this link to send your readers to the up-to-date reference.

<a href="https://aidoo.ai/en/outils/explorateur-modeles-odoo/account-analytic-line">account.analytic.line (Odoo 19.0)</a>

Sources

Data verified on September 23, 2026 · Odoo 19.0 Community

Have an Odoo project, or want to put your ERP to work with AI? Let's talk

Implementation, custom module development, connecting Claude or ChatGPT to your data: tell us about your context and we will reply within 24 business hours.