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": "b4c89d55-b85f-4e66-87a2-af33f54ee352",
  "purchase_order_id": "c1d27d50-8d7c-4d73-a4d7-0b1b32fb9f71",
  "purchase_order_reference_back_office": "sample string 3",
  "purchase_order": {
    "id": "61605f52-d3f6-4ad3-96b4-a0ae65de5835",
    "id2": 2,
    "jobs_id": "342a3cf8-2a68-41a3-af50-d4cf90871806",
    "jobs_reference_back_office": "sample string 4",
    "supplier_company_id": "76bb2424-8f28-41f5-b41d-5ac532e68b8a",
    "supplier_company_code": "sample string 6",
    "user_id": "1b51412a-4e3b-47aa-8e7c-997aa46a3fca",
    "user_code": "sample string 8",
    "description": "sample string 9",
    "memo": "sample string 10",
    "total_lines": 11,
    "date_create": "2026-07-04T15:05:28.9937119+00:00",
    "date_update": "2026-07-04T15:05:28.9937119+00:00",
    "date_delivery": "2026-07-04T15:05:28.9937119+00:00",
    "confirmed_date_delivery": "2026-07-04T15:05:28.9937119+00:00",
    "delivery_db_address_id": "b39ccc53-6237-470a-a12d-753482ade0fc",
    "approved_by_user_id": "16d92c21-8702-4b52-8d7b-e328e41cc1ae",
    "approved_by_user_code": "sample string 18",
    "technical_user_id": "5ad728a7-3c5f-48f6-a959-55adaacd1514",
    "technical_user_code": "sample string 20",
    "purchase_order_status_id": "2c8b8ef1-4899-44a1-ac50-cf24c764ff9f",
    "purchase_order_status_code": "sample string 22",
    "article_stock_location_id": "d36e7bcd-ff2a-40e3-87db-d1b3e25040e4",
    "is_pickup": true,
    "reference_back_office": "sample string 25",
    "modified_dateutc": "2026-07-04T15:05:28.9937119+00:00"
  },
  "article_id": "2882555e-14c6-4cfb-af28-f054ab3fa71f",
  "article_code": "sample string 5",
  "article": {
    "id": "99f15986-33e6-4151-b787-ed7693c04396",
    "article_category_id": "3459559c-8ede-42ae-94d1-0ef851acab9d",
    "article_category": {
      "id": "94c5ab76-81af-4a3c-a30a-d80a4d688570",
      "parent_id": "d4ed52c9-97af-4927-8483-cb9806dc1f70",
      "parent_code": "sample string 3",
      "code": "sample string 4",
      "name": "sample string 5",
      "modified_dateutc": "2026-07-04T15:05:28.9937119+00:00"
    },
    "article_category_code": "sample string 3",
    "article_group_1_id": "4843344c-433e-4cc9-9acb-b3fabfcc81f6",
    "article_group_1_code": "sample string 5",
    "article_group_2_id": "eb0c15f0-90d2-4caf-8244-9da160b4331c",
    "article_group_2_code": "sample string 7",
    "article_group_3_id": "6fc61473-1a40-4beb-8e68-47d177322b81",
    "article_group_3_code": "sample string 9",
    "article_group_4_id": "399802e6-4502-4116-9cfd-eea0d7ccec35",
    "article_group_4_code": "sample string 11",
    "article_group_5_id": "d429de8d-4ad4-49b9-b039-936fa5c220e4",
    "article_group_5_code": "sample string 13",
    "article_group_6_id": "72ef46ad-818f-4e49-a224-5cc0dbe08ed7",
    "article_group_6_code": "sample string 15",
    "physical_stock": 16,
    "back_order_client": 17,
    "back_order_supplier": 18,
    "expected_delivery_date_bo_supplier": "2026-07-04T15:05:28.9937119+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-07-04T15:05:28.9937119+00:00",
    "date_update": "2026-07-04T15:05:28.9937119+00:00",
    "modified_dateutc": "2026-07-04T15:05:28.9937119+00:00",
    "article_color_id": "0cabcdf4-fdca-4613-bec4-d7743a469ba7",
    "article_color_code": "sample string 38",
    "article_color": {
      "id": "e416b33d-8660-447a-8973-72c584b69892",
      "name": "sample string 2",
      "code": "sample string 3",
      "modified_dateutc": "2026-07-04T15:05:28.9937119+00:00"
    },
    "warranty_period_nb_months": 39,
    "use_serial": true,
    "_replace_id": "c091db4d-3062-47fe-8547-fc118db5ed03",
    "replace_article_code": "sample string 42",
    "db_unit_of_measure_id_selling": "0dc363c0-ce57-4c8d-ba3d-256be1a5bce6",
    "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-07-04T15:05:28.9937119+00:00"
}

Response Information

Resource Description :

IHttpActionResult

None.

Response Formats

application/json, text/json

Sample:

Sample not available.