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": "f9222243-e95a-47b1-b9af-4d7bfb7a7614",
  "purchase_order_id": "bfd6fb09-60bd-41c4-a4cb-66823d7730a3",
  "purchase_order_reference_back_office": "sample string 3",
  "purchase_order": {
    "id": "1893e0d8-35d5-4ca0-8918-4aacc8259c2c",
    "id2": 2,
    "jobs_id": "86733b65-0699-44f6-99ae-c6a13f1247fd",
    "jobs_reference_back_office": "sample string 4",
    "supplier_company_id": "b6811e44-a5c1-41d0-be48-5c8f103b075b",
    "supplier_company_code": "sample string 6",
    "user_id": "9e8d2376-4805-4c87-812c-b54b0cc99cba",
    "user_code": "sample string 8",
    "description": "sample string 9",
    "memo": "sample string 10",
    "total_lines": 11,
    "date_create": "2026-09-12T12:35:19.7735151+00:00",
    "date_update": "2026-09-12T12:35:19.7735151+00:00",
    "date_delivery": "2026-09-12T12:35:19.7735151+00:00",
    "confirmed_date_delivery": "2026-09-12T12:35:19.7735151+00:00",
    "delivery_db_address_id": "e97798eb-607c-4e12-bd38-9dd1ea1a8885",
    "approved_by_user_id": "2191ca21-7273-49f1-b431-1eca7484eeea",
    "approved_by_user_code": "sample string 18",
    "technical_user_id": "c08f6d4a-3b55-405b-8da0-0a244135e226",
    "technical_user_code": "sample string 20",
    "purchase_order_status_id": "6b6432b5-1c17-423f-8529-70a5dfc599da",
    "purchase_order_status_code": "sample string 22",
    "article_stock_location_id": "9d751190-90af-4475-88a1-97083e65bb8f",
    "is_pickup": true,
    "reference_back_office": "sample string 25",
    "modified_dateutc": "2026-09-12T12:35:19.7735151+00:00"
  },
  "article_id": "35e32690-e0ab-4837-a673-a6212a758129",
  "article_code": "sample string 5",
  "article": {
    "id": "44a86876-d440-4614-9e48-4f8698ae216e",
    "article_category_id": "088c5c61-cc0a-45fc-a309-7b6798e177c7",
    "article_category": {
      "id": "42590abf-f409-4d1b-b8ce-7f80edf81d30",
      "parent_id": "e1c63c5e-143f-43ff-8817-f46c69a0aa8a",
      "parent_code": "sample string 3",
      "code": "sample string 4",
      "name": "sample string 5",
      "modified_dateutc": "2026-09-12T12:35:19.7735151+00:00"
    },
    "article_category_code": "sample string 3",
    "article_group_1_id": "d74b1dc1-1343-497c-a880-b10b0f091ddd",
    "article_group_1_code": "sample string 5",
    "article_group_2_id": "295123cf-bd43-4c94-ac74-9e49a01ef0e8",
    "article_group_2_code": "sample string 7",
    "article_group_3_id": "ec31fc53-9afe-4e3d-9c22-a110e3e43333",
    "article_group_3_code": "sample string 9",
    "article_group_4_id": "dc27b3b8-9370-414a-8f85-9de43871b4b1",
    "article_group_4_code": "sample string 11",
    "article_group_5_id": "6429ad07-8b12-430b-8b33-d47e4659eb74",
    "article_group_5_code": "sample string 13",
    "article_group_6_id": "c02c0714-73d0-4b6e-a03b-4c7d53389808",
    "article_group_6_code": "sample string 15",
    "physical_stock": 16,
    "back_order_client": 17,
    "back_order_supplier": 18,
    "expected_delivery_date_bo_supplier": "2026-09-12T12:35:19.7735151+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-09-12T12:35:19.7735151+00:00",
    "date_update": "2026-09-12T12:35:19.7735151+00:00",
    "modified_dateutc": "2026-09-12T12:35:19.7735151+00:00",
    "article_color_id": "72f6855d-6a5b-40df-9f0f-6bd4ad85a27b",
    "article_color_code": "sample string 38",
    "article_color": {
      "id": "6c6c8d0d-7814-4895-9825-826243a04a68",
      "name": "sample string 2",
      "code": "sample string 3",
      "modified_dateutc": "2026-09-12T12:35:19.7735151+00:00"
    },
    "warranty_period_nb_months": 39,
    "use_serial": true,
    "_replace_id": "b5543f87-c9f2-4364-acc3-50c493956344",
    "replace_article_code": "sample string 42",
    "db_unit_of_measure_id_selling": "5ec77b0a-8f24-4358-856c-4500096e2ef4",
    "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-09-12T12:35:19.7735151+00:00"
}

Response Information

Resource Description :

IHttpActionResult

None.

Response Formats

application/json, text/json

Sample:

Sample not available.