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": "e431c5ec-b8d3-41bd-8141-e1c5cb47d8fe",
  "purchase_order_id": "6b8a478f-8208-41fe-86a2-c64c1ab19a0f",
  "purchase_order_reference_back_office": "sample string 3",
  "purchase_order": {
    "id": "7628f16a-a0a3-4248-aaa8-cfa9f93de107",
    "id2": 2,
    "jobs_id": "7fd6c7ca-264f-4e2c-830a-944f51952f25",
    "jobs_reference_back_office": "sample string 4",
    "supplier_company_id": "374030f0-6891-4113-a069-23c802d408d9",
    "supplier_company_code": "sample string 6",
    "user_id": "3aff08e1-35f8-457d-9061-4c32d2ec955a",
    "user_code": "sample string 8",
    "description": "sample string 9",
    "memo": "sample string 10",
    "total_lines": 11,
    "date_create": "2026-11-14T12:10:30.4479328+00:00",
    "date_update": "2026-11-14T12:10:30.4479328+00:00",
    "date_delivery": "2026-11-14T12:10:30.4479328+00:00",
    "confirmed_date_delivery": "2026-11-14T12:10:30.4479328+00:00",
    "delivery_db_address_id": "0b6c8ae6-baaf-4f4b-aff2-c8868a2f4e28",
    "approved_by_user_id": "0dcc33cf-6d3c-43ed-a9f8-ee50d6d535a4",
    "approved_by_user_code": "sample string 18",
    "technical_user_id": "5099519d-101c-489c-9bbb-fea500781aaf",
    "technical_user_code": "sample string 20",
    "purchase_order_status_id": "fdd7fa29-b3aa-443e-b8f6-ed680997f033",
    "purchase_order_status_code": "sample string 22",
    "article_stock_location_id": "8fb976af-39e3-4eec-bd78-704412de98a3",
    "is_pickup": true,
    "reference_back_office": "sample string 25",
    "modified_dateutc": "2026-11-14T12:10:30.4592921+00:00"
  },
  "article_id": "9164a4b5-4fb6-42c4-997c-2f2852d5bb5f",
  "article_code": "sample string 5",
  "article": {
    "id": "d5b2558f-8fc8-4fc8-b370-2a8df8550733",
    "article_category_id": "fbe5a1ce-7ed4-401b-b4e2-3af67d42853c",
    "article_category": {
      "id": "34ec56c0-1156-462d-ac16-915b5d06f734",
      "parent_id": "a162aeba-cd73-47b9-ade7-e3d2ef1881c1",
      "parent_code": "sample string 3",
      "code": "sample string 4",
      "name": "sample string 5",
      "modified_dateutc": "2026-11-14T12:10:30.4592921+00:00"
    },
    "article_category_code": "sample string 3",
    "article_group_1_id": "e056c47b-6350-4e2c-a773-9820b4c3e54d",
    "article_group_1_code": "sample string 5",
    "article_group_2_id": "2e8f3d4e-0076-4b00-970c-2dcfe5a678b7",
    "article_group_2_code": "sample string 7",
    "article_group_3_id": "1fb98c9e-0d89-4941-8dfd-52d729865c04",
    "article_group_3_code": "sample string 9",
    "article_group_4_id": "b351d6e8-676f-4dad-9b06-4bda58d703d1",
    "article_group_4_code": "sample string 11",
    "article_group_5_id": "b2075b6c-050f-4d52-a3e0-765034ff08df",
    "article_group_5_code": "sample string 13",
    "article_group_6_id": "fb0895fe-7fc5-4d04-abfb-2c38f0c6d057",
    "article_group_6_code": "sample string 15",
    "physical_stock": 16,
    "back_order_client": 17,
    "back_order_supplier": 18,
    "expected_delivery_date_bo_supplier": "2026-11-14T12:10:30.4592921+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-11-14T12:10:30.4592921+00:00",
    "date_update": "2026-11-14T12:10:30.4592921+00:00",
    "modified_dateutc": "2026-11-14T12:10:30.4592921+00:00",
    "article_color_id": "95438f76-4704-4cb9-a921-e828d8bec926",
    "article_color_code": "sample string 38",
    "article_color": {
      "id": "58e5a3aa-f46b-4fe1-8608-7acb4e953b54",
      "name": "sample string 2",
      "code": "sample string 3",
      "modified_dateutc": "2026-11-14T12:10:30.4592921+00:00"
    },
    "warranty_period_nb_months": 39,
    "use_serial": true,
    "_replace_id": "25c4effc-5554-49c2-9774-9b6164c23fac",
    "replace_article_code": "sample string 42",
    "db_unit_of_measure_id_selling": "bff41a23-61ef-4590-83b1-ac55f2b626c6",
    "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-11-14T12:10:30.4592921+00:00"
}

Response Information

Resource Description :

IHttpActionResult

None.

Response Formats

application/json, text/json

Sample:

Sample not available.