Creates a new purchase order order line

Request Information

URI Parameters :

None.

Body Parameters :

purchase_order_details
NameDescriptionTypeAdditional information
id

Primary Key

globally unique identifier
purchase_order_id

Foreign key of the purchase_order

globally unique identifier

Optionally required : purchase_order_id, purchase_order_reference or purchase_order must be provided

purchase_order_reference_back_office

Embedded entity "purchase_order" using ERP PK when adding/updating

string

Optionally required : purchase_order_id, purchase_order_reference_back_office or purchase_order must be provided

purchase_order

Embedded entity "purchase_order" when adding/updating

purchase_order

Optionally required : purchase_order_id, purchase_order_reference_back_office or purchase_order must be provided

article_id

Foreign key of article

globally unique identifier

Optionally required : article_id, article_code or article must be provided

article_code

Embedded entity "article" using ERP PK when adding/updating

string

Optionally required : article_id, article_code or article must be provided

article

Embedded entity "article" when adding/updating

article

Optionally required : article_id, article_code or article must be provided

line_number

Line Number, auto filled with (Highest+1) if value is 0/null

integer
code

Code of the article (auto filled if empty)

string

Max length: 255

supplier_code

Code of the supplier for this article

string

Max length: 255

name

Article Name (will be auto filled if article.name+description are empty)

string

Max length: 255

description

Article description (will be auto filled by article.short_description if name+description are empty)

string

Max length: 255

price

Unit Price

decimal number

Matching regular expression pattern: ^[0-9]\d*(\.\d+)?$

Range: inclusive between 0.1 and 1.79769313486232E+308

quantity

Quantity

decimal number

Required

Range: inclusive between 0.1 and 1.79769313486232E+308

memo

Line memo/remark

string
cost_price

Unit Cost Price (statistic purpose)

decimal number

Matching regular expression pattern: ^[0-9]\d*(\.\d+)?$

reference_back_office

Field used for Embedded entity (store there your ERP PK)

string

Max length: 50

modified_dateutc

Readonly system field managed by database, filled with GetUtcDate when adding,updating

date

Request Formats :

application/json, text/json

Sample:
{
  "id": "c79a6afd-09cd-47ee-8302-429aa92d3cc2",
  "purchase_order_id": "9512fe32-676a-445b-b6e9-4e7c7a5a3bd0",
  "purchase_order_reference_back_office": "sample string 3",
  "purchase_order": {
    "id": "edeb5a60-97f5-480b-a325-76cdf9127233",
    "id2": 2,
    "jobs_id": "c6159394-c7c6-45d3-94fa-c5bbf5266ca8",
    "jobs_reference_back_office": "sample string 4",
    "supplier_company_id": "c05a4879-73a2-40f2-951b-4beaccfb19ab",
    "supplier_company_code": "sample string 6",
    "user_id": "a6bf0c84-62c0-4cae-bd9b-7c927db16072",
    "user_code": "sample string 8",
    "description": "sample string 9",
    "memo": "sample string 10",
    "total_lines": 11,
    "date_create": "2026-03-09T05:36:01.6408864+00:00",
    "date_update": "2026-03-09T05:36:01.6565104+00:00",
    "date_delivery": "2026-03-09T05:36:01.6565104+00:00",
    "confirmed_date_delivery": "2026-03-09T05:36:01.6565104+00:00",
    "delivery_db_address_id": "fe820fdd-686d-4c99-9e59-0c9ea1497c0a",
    "approved_by_user_id": "92fc8f72-071a-40ae-94f4-d09f8c1005b3",
    "approved_by_user_code": "sample string 18",
    "technical_user_id": "1acd706c-6816-4009-9fe8-ecb2871aaff9",
    "technical_user_code": "sample string 20",
    "purchase_order_status_id": "8065657c-5159-4c62-84e5-7a26c1555c5a",
    "purchase_order_status_code": "sample string 22",
    "article_stock_location_id": "dc5f9305-b09f-4a93-9a47-d3acdc4bafa2",
    "is_pickup": true,
    "reference_back_office": "sample string 25",
    "modified_dateutc": "2026-03-09T05:36:01.6565104+00:00"
  },
  "article_id": "a009b8a8-13d8-43c1-b3c8-14f52d73533a",
  "article_code": "sample string 5",
  "article": {
    "id": "68c09555-2181-45b4-a89f-22a4437e155b",
    "article_category_id": "dac99718-22d9-4d97-92f0-0cce32e8288d",
    "article_category": {
      "id": "54595506-7d9a-42c4-b4e3-53d37f92f854",
      "parent_id": "e4847f81-12d4-4d0d-a434-e5a2028a09ae",
      "parent_code": "sample string 3",
      "code": "sample string 4",
      "name": "sample string 5",
      "modified_dateutc": "2026-03-09T05:36:01.6565104+00:00"
    },
    "article_category_code": "sample string 3",
    "article_group_1_id": "7ea9b4b5-01b8-4b63-8b4b-d2f845a31715",
    "article_group_1_code": "sample string 5",
    "article_group_2_id": "99625313-2123-4339-91d3-825a3fe8911b",
    "article_group_2_code": "sample string 7",
    "article_group_3_id": "1efc2ffc-d211-434c-9383-4800aa36d68b",
    "article_group_3_code": "sample string 9",
    "article_group_4_id": "bf47b6a2-26f9-4b62-9254-04c45442219b",
    "article_group_4_code": "sample string 11",
    "article_group_5_id": "381f1fc8-1fb3-4302-b750-6f0b7325595a",
    "article_group_5_code": "sample string 13",
    "article_group_6_id": "254b9720-a240-4df3-abda-ba30628a6b9a",
    "article_group_6_code": "sample string 15",
    "physical_stock": 16,
    "back_order_client": 17,
    "back_order_supplier": 18,
    "expected_delivery_date_bo_supplier": "2026-03-09T05:36:01.6565104+00:00",
    "article_increment": 20,
    "min_article_quantity": 21,
    "entered_price": 22.0,
    "cost_price": 23.1,
    "no_stock": true,
    "archived": true,
    "is_travel_fee": true,
    "is_mileage_fee": true,
    "code": "sample string 28",
    "name": "sample string 29",
    "description_short": "sample string 30",
    "description_long": "sample string 31",
    "barcode": "sample string 32",
    "notes": "sample string 33",
    "date_create": "2026-03-09T05:36:01.6565104+00:00",
    "date_update": "2026-03-09T05:36:01.6565104+00:00",
    "modified_dateutc": "2026-03-09T05:36:01.6565104+00:00",
    "article_color_id": "0ab7b42b-5013-4924-bb3c-88cc1d1e2611",
    "article_color_code": "sample string 38",
    "article_color": {
      "id": "fd84678a-345d-49ad-8810-71320feaf6f4",
      "name": "sample string 2",
      "code": "sample string 3",
      "modified_dateutc": "2026-03-09T05:36:01.6565104+00:00"
    },
    "warranty_period_nb_months": 39,
    "use_serial": true,
    "_replace_id": "c0439104-8f1d-45de-9ebd-3dcf664fa307",
    "replace_article_code": "sample string 42",
    "db_unit_of_measure_id_selling": "ea91196c-aa47-48fb-ab6c-d684f0b5dbc5",
    "db_unit_of_measure_code_selling": "sample string 44",
    "translations": [
      {
        "field_name": "sample string 1",
        "language_code": "sample string 2",
        "value_translated": "sample string 3"
      },
      {
        "field_name": "sample string 1",
        "language_code": "sample string 2",
        "value_translated": "sample string 3"
      }
    ]
  },
  "line_number": 6,
  "code": "sample string 7",
  "supplier_code": "sample string 8",
  "name": "sample string 9",
  "description": "sample string 10",
  "price": 11.0,
  "quantity": 12.0,
  "memo": "sample string 13",
  "cost_price": 14.0,
  "reference_back_office": "sample string 15",
  "modified_dateutc": "2026-03-09T05:36:01.6565104+00:00"
}

Response Information

Resource Description :

IHttpActionResult

None.

Response Formats

application/json, text/json

Sample:

Sample not available.