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": "7b90ba6a-8da8-4816-9df4-b2922ce9f6eb",
  "purchase_order_id": "63df6a52-ba0e-4e8a-a859-88092d153b1d",
  "purchase_order_reference_back_office": "sample string 3",
  "purchase_order": {
    "id": "fca91c3f-859a-4c6d-b287-fb36c92e58ea",
    "id2": 2,
    "jobs_id": "8ed1398d-5ae6-45a0-a762-14c02992aff5",
    "jobs_reference_back_office": "sample string 4",
    "supplier_company_id": "4a9a5572-582b-4f26-aeec-eb56f3fc3298",
    "supplier_company_code": "sample string 6",
    "user_id": "3df03e31-0ed4-43c5-aa8d-1af91eb82ef7",
    "user_code": "sample string 8",
    "description": "sample string 9",
    "memo": "sample string 10",
    "total_lines": 11,
    "date_create": "2026-05-15T06:21:14.8896844+00:00",
    "date_update": "2026-05-15T06:21:14.8896844+00:00",
    "date_delivery": "2026-05-15T06:21:14.8896844+00:00",
    "confirmed_date_delivery": "2026-05-15T06:21:14.8896844+00:00",
    "delivery_db_address_id": "9eb3a0df-e34b-48f5-9c7f-0489ae931feb",
    "approved_by_user_id": "cd90ff45-1525-4ebd-9df6-ea0a0b3791d2",
    "approved_by_user_code": "sample string 18",
    "technical_user_id": "033437f2-a164-4055-a5f6-c496e089dd37",
    "technical_user_code": "sample string 20",
    "purchase_order_status_id": "5137cad3-0fec-4da6-a50f-c180a90ed6bc",
    "purchase_order_status_code": "sample string 22",
    "article_stock_location_id": "5031c926-1159-4df4-ac62-70b71cc18d66",
    "is_pickup": true,
    "reference_back_office": "sample string 25",
    "modified_dateutc": "2026-05-15T06:21:14.8896844+00:00"
  },
  "article_id": "a9d4a7d1-36d4-4988-8f4a-01ce536bb6cb",
  "article_code": "sample string 5",
  "article": {
    "id": "b42c6c10-716f-4200-9aab-6343f9162689",
    "article_category_id": "d934a3c8-8521-49f6-a744-e92ad19b07d2",
    "article_category": {
      "id": "60e80507-bab2-48e0-acfc-6f0c0e4a6292",
      "parent_id": "b57d557b-4253-4587-bd4c-480c65d16c43",
      "parent_code": "sample string 3",
      "code": "sample string 4",
      "name": "sample string 5",
      "modified_dateutc": "2026-05-15T06:21:14.8896844+00:00"
    },
    "article_category_code": "sample string 3",
    "article_group_1_id": "a6fbabe5-a8e3-4813-8321-68215a078ccb",
    "article_group_1_code": "sample string 5",
    "article_group_2_id": "8c2fba89-0e3c-49e3-a467-fea2b3c38b7c",
    "article_group_2_code": "sample string 7",
    "article_group_3_id": "8c32bd26-ace4-4361-8f8a-45da8bcc0bbb",
    "article_group_3_code": "sample string 9",
    "article_group_4_id": "7633aebf-65c1-49ac-bca6-dbe34c329ddf",
    "article_group_4_code": "sample string 11",
    "article_group_5_id": "fb587b2c-a2e8-476b-b03a-75c8345b11cc",
    "article_group_5_code": "sample string 13",
    "article_group_6_id": "1690f5dd-07c2-4392-ae4a-21bdb8180303",
    "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-15T06:21:14.8896844+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-15T06:21:14.8896844+00:00",
    "date_update": "2026-05-15T06:21:14.8896844+00:00",
    "modified_dateutc": "2026-05-15T06:21:14.8896844+00:00",
    "article_color_id": "7ea4e9d7-7908-4966-bf08-2e2ca47f520f",
    "article_color_code": "sample string 38",
    "article_color": {
      "id": "b599cbc6-1922-4de9-a498-6e04ad388bcb",
      "name": "sample string 2",
      "code": "sample string 3",
      "modified_dateutc": "2026-05-15T06:21:14.8896844+00:00"
    },
    "warranty_period_nb_months": 39,
    "use_serial": true,
    "_replace_id": "fd4e1524-b62a-497a-b289-23c6f6dba3f7",
    "replace_article_code": "sample string 42",
    "db_unit_of_measure_id_selling": "8aa2a534-e46a-4300-a1df-fbb49067ebde",
    "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-15T06:21:14.8896844+00:00"
}

Response Information

Resource Description :

IHttpActionResult

None.

Response Formats

application/json, text/json

Sample:

Sample not available.