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": "9e9e88e7-c6f4-47b8-a323-3aecb99df720",
  "purchase_order_id": "6e5bb79e-0154-40b2-9796-c1642862de8d",
  "purchase_order_reference_back_office": "sample string 3",
  "purchase_order": {
    "id": "fd69bdce-cef9-41df-8f35-1b5566fe827f",
    "id2": 2,
    "jobs_id": "f528a49a-5b0d-4a4b-a62b-21fb110dc207",
    "jobs_reference_back_office": "sample string 4",
    "supplier_company_id": "89b1d0ea-360e-4b2a-908e-1f4fc84aca86",
    "supplier_company_code": "sample string 6",
    "user_id": "99350ebe-0e5e-40fb-b2b0-6e24bbc77413",
    "user_code": "sample string 8",
    "description": "sample string 9",
    "memo": "sample string 10",
    "total_lines": 11,
    "date_create": "2026-05-13T19:42:15.5759393+00:00",
    "date_update": "2026-05-13T19:42:15.5759393+00:00",
    "date_delivery": "2026-05-13T19:42:15.5759393+00:00",
    "confirmed_date_delivery": "2026-05-13T19:42:15.5759393+00:00",
    "delivery_db_address_id": "c4b3bc4b-cadf-49bd-a019-793d24035c39",
    "approved_by_user_id": "427707a3-ef88-4ae3-8a37-7a93c8c96aa7",
    "approved_by_user_code": "sample string 18",
    "technical_user_id": "509c0ffe-4052-45ba-b594-535fddbbd52f",
    "technical_user_code": "sample string 20",
    "purchase_order_status_id": "2325abf5-6481-44ee-9eb7-81dbdad298ff",
    "purchase_order_status_code": "sample string 22",
    "article_stock_location_id": "b56c058e-f22a-4fd4-9fc8-dd4ad6b88fc0",
    "is_pickup": true,
    "reference_back_office": "sample string 25",
    "modified_dateutc": "2026-05-13T19:42:15.5759393+00:00"
  },
  "article_id": "e875b947-43d1-42ae-bcd0-0544410ec93a",
  "article_code": "sample string 5",
  "article": {
    "id": "34bcd7d9-76a0-4196-adc7-91de9dc36411",
    "article_category_id": "b66bb75b-ab5e-4905-aa2e-965e186456a5",
    "article_category": {
      "id": "cd591b38-6384-40ac-871c-847d49b01dd4",
      "parent_id": "696d034b-dc55-43af-99fc-41becbc3d7c4",
      "parent_code": "sample string 3",
      "code": "sample string 4",
      "name": "sample string 5",
      "modified_dateutc": "2026-05-13T19:42:15.5759393+00:00"
    },
    "article_category_code": "sample string 3",
    "article_group_1_id": "5897a279-d9b1-47f2-af07-1ea77e6bbdde",
    "article_group_1_code": "sample string 5",
    "article_group_2_id": "09523834-f67c-4f54-9874-6e0830c0c7f4",
    "article_group_2_code": "sample string 7",
    "article_group_3_id": "92ebe32e-50bf-4360-bfc1-0a30163db173",
    "article_group_3_code": "sample string 9",
    "article_group_4_id": "16cac50a-4b56-407d-93f4-f52b9161d1f2",
    "article_group_4_code": "sample string 11",
    "article_group_5_id": "bb9a23ae-6fd9-43cf-8f23-b4cf1e9ae178",
    "article_group_5_code": "sample string 13",
    "article_group_6_id": "46177ed2-abfd-4980-8495-28da9c014b5c",
    "article_group_6_code": "sample string 15",
    "physical_stock": 16,
    "back_order_client": 17,
    "back_order_supplier": 18,
    "expected_delivery_date_bo_supplier": "2026-05-13T19:42:15.5759393+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-05-13T19:42:15.5759393+00:00",
    "date_update": "2026-05-13T19:42:15.5759393+00:00",
    "modified_dateutc": "2026-05-13T19:42:15.5759393+00:00",
    "article_color_id": "7a1018bc-0525-41ea-950b-2c59bfd726b8",
    "article_color_code": "sample string 38",
    "article_color": {
      "id": "915254af-b763-402e-99ea-8e4bf72dea02",
      "name": "sample string 2",
      "code": "sample string 3",
      "modified_dateutc": "2026-05-13T19:42:15.5759393+00:00"
    },
    "warranty_period_nb_months": 39,
    "use_serial": true,
    "_replace_id": "76420cfe-b5ea-4767-99d3-d74b8ee35609",
    "replace_article_code": "sample string 42",
    "db_unit_of_measure_id_selling": "9a1d91e5-6df8-4454-b30e-e0b00f926084",
    "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-05-13T19:42:15.5759393+00:00"
}

Response Information

Resource Description :

IHttpActionResult

None.

Response Formats

application/json, text/json

Sample:

Sample not available.