One product on a sales order, with the quantity ordered and its price. Where that quantity is now (approved, in production, delivered, invoiced) is on its status lines, SalesOrderLineStatuses.

Label in Fledge: Verkooporderregels

URLhttps://odata-api.fledge.nl/v2-8/SalesOrderLines
Keyadministration_idsales_order_header_idsales_order_line_id
AdministrationRows belong to one administration: always filter on administration_id.
OperationsGET listGET onePOSTPATCHDELETE
Read licensesBASISURENPC
Write licensesVERKOOP
ScopesFLEDGE_PORTALFLEDGE_TERMINAL

Example requests

A page of rows, with only the fields you need. See Authentication for the token.

curl -G "https://odata-api.fledge.nl/v2-8/SalesOrderLines" \
  --data-urlencode '$filter=administration_id eq 1' \
  --data-urlencode '$select=sales_order_header_id,sales_order_line_id,confirmation_delivery_date,discount_percentage,intrastat_item_id' \
  --data-urlencode '$top=50' \
  -H "Authorization: Bearer $TOKEN"
const url = new URL('https://odata-api.fledge.nl/v2-8/SalesOrderLines');
url.searchParams.set('$filter', 'administration_id eq 1');
url.searchParams.set('$select', 'sales_order_header_id,sales_order_line_id,confirmation_delivery_date,discount_percentage,intrastat_item_id');
url.searchParams.set('$top', '50');

const response = await fetch(url, { headers: { Authorization: `Bearer ${token}` } });
const { value } = await response.json();
var url = "https://odata-api.fledge.nl/v2-8/SalesOrderLines" + "?" + string.Join("&",
    "$filter=" + Uri.EscapeDataString("administration_id eq 1"),
    "$select=" + Uri.EscapeDataString("sales_order_header_id,sales_order_line_id,confirmation_delivery_date,discount_percentage,intrastat_item_id"),
    "$top=" + Uri.EscapeDataString("50"));

http.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token);
var json = await http.GetStringAsync(url);

One row by its key:

GET https://odata-api.fledge.nl/v2-8/SalesOrderLines(administration_id=1,sales_order_header_id='{sales_order_header_id}',sales_order_line_id={sales_order_line_id})

Fields

FieldTypeDescription
administration_idkeyInt32Administratienummer
sales_order_line_idkeyInt32Regelnummer
sales_order_header_idkeyStringVerkoopordernummer
apply_replacement_valueBooleanVervangingswaarde toepassen (j/n)
approval_1BooleanFiat 1: Fiattering 1
approval_2BooleanFiat 2: Fiattering 2
approval_3BooleanFiat 3: Fiattering 3
article_group_idInt32Artikelgroep
article_idStringArtikelcode
benchmark_for_intrastatDecimalMaatstaf voor intrastat-aangifte.
vat_categoryStringRubriek BTW omzet aangifte
changed_byInt32User wijzig
confirmation_delivery_dateDateBevestigde leverdatum

The delivery date confirmed to the customer for this line, when there is one.

confirmation_date_1DateDatum bevestiging
confirmation_date_2DateDatum bevestiging
confirmation_week_1Int32Weeknr. bevestiging: Weeknummer bevestiging
confirmation_week_2Int32Weeknr. bevestiging: Weeknummer bevestiging
confirmed_date_shift_reasonStringReden verschuiving
confirmed_delivery_date_confirmed_on_dateDateLeverdatum bevestigd op
costDecimalKostprijs
created_byInt32User aanmaak
creation_dateDateDatum aanmaak
creditor_idInt32Crediteurnummer
currency_code_idInt32Valutanummer
currency_unitInt32Eenheid valuta
description_1StringOmschrijving
description_2StringOmschrijving
description_3StringOmschrijving
discount_percentageDecimalKortingspercentage 1

The line's discount in percent. The only discount that is applied.

drawing_numberStringTekeningnummer
exchange_rateDecimalKoers
finishing_statusInt32Status afwerking
force_cost_priceBooleanForceer kostprijs (ja/nee)
functionInt32Funktie regel
  • 1 Article
  • 2 Text line
  • 3 Subtotal (no longer used)
  • 4 Repair
intrastat_item_idStringIntrastat goederencode

The goods code (IntrastatGoodsCodes), despite the name.

invoice_value_for_intrastatDecimalFactuurwaarde voor intrastat-aangifte.

The invoice value for the Intrastat declaration, not the invoiced amount.

is_confirmedBooleanBevestigd ja/nee

Whether the line is on an order confirmation. Set back to false when a delivery note is made.

memo_1StringMemo

Memo for sales and production.

memo_2StringMemo 1 (faktuur)

Memo for the invoice.

memo_3StringMemo (pakbon)

Memo for the delivery note.

modification_dateDateDatum wijzig
order_codeStringBestelkode
order_dateDateDatum order
order_weekInt32
planning_dateDateDatum planning

The planned delivery date of this line. Required, and can differ from the order's planning_date.

planning_weekInt32
pre_or_post_calculation_priceBooleanVC/NC prijs: Prijs op basis van VC of NC

false means post-calculation (nacalculatie): the price is set later, so it can be 0 until the line is invoiced.

gross_price_foreign_currencyDecimalVerkoopprijs vv
net_price_foreign_currencyDecimalVerkoopprijs netto: Verkoopprijs vv netto

The price per unit in the order's foreign currency, after discount_percentage and without VAT.

gross_price_local_currencyDecimalVerkoopprijs lv

The price per unit before discount_percentage.

net_price_local_currencyDecimalVerkooprpijs netto: Verkoopprijs lv netto

The price per unit in the local currency, after discount_percentage and without VAT. Line value = quantity times this.

price_with_vatDecimalVerkoopprijs incl. BTW
print_article_idBooleanAfdrukken artikelkode
print_memoBooleanAfdrukken memo
print_priceBooleanAfdrukken prijs
print_quantityBooleanAfdrukken aantal
profit_marginDecimalWinstmarge
quantityDecimalAantal besteld

The quantity ordered, in the article's price unit (Articles.calculation_unit); the app shows it in the sales unit. Prices are per price unit, so quantity times net price is the value. Not what is still open: that's the sum of the open status lines.

sales_quotation_header_idStringOffertenummer
sales_quotation_line_idInt32Regelnummer
referenceStringReferentie verkooporderregel
revisionStringRevisie
revenue_group_idInt32Omzetgroep
sales_order_typeInt32Type verkooporderorder

A copy of the order's sales_order_header_type (0 normal, 2 take-away), not sales_order_type_id.

  • 0 Normal order
  • 2 Take-away order (afhaalorder)
sales_price_systemInt32Verkoopprijssysteem
sequenceInt32Volgorde
statistical_value_intrastatDecimalStatistische waarde voor intrastat-aangifte
vat_code_idInt32BTW nummer
warehouse_address_idInt32Adresnummer
warehouse_aisle_idInt32Magazijn
warehouse_shelf_idInt32Locatie
weight_for_intrastatDecimalNetto-gewicht voor gebruik in intrastat-aangifte
workflow_typeInt32Workflow type
  • 0 Normal
  • 1 Accelerated invoicing (versneld factureren, the checkbox Kostenartikel), for transport, rent or costs; approval goes straight to invoicing

Relations

Read a related row or list in the same request with $expand, and give it its own $select; a list also needs a $top.

NavigationEntity set
AdministrationAdministrationsone
ArticleArticlesone
ArticleGroupArticleGroupsone
ChangedByUserUsersone
CreatedByUserUsersone
RevenueGroupRevenueGroupsone
SalesOrderHeaderSalesOrderHeadersone
SalesQuotationLineSalesQuotationLinesone
WarehouseAddressWarehouseAddressesone
WarehouseAisleWarehouseAislesone
WarehouseShelfWarehouseShelfsone
DocumentLinksDocumentLinksmany
ProductionOrderHeadersProductionOrderHeadersmany
SalesOrderLineStatusesSalesOrderLineStatusesmany
SalesPurchaseOrderLinksSalesPurchaseOrderLinksmany
ServiceProductionLinksServiceProductionLinksmany
Wingman