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": "abb0e6e5-03ee-47e9-b3d4-2a469f83282d",
  "purchase_order_id": "685243d1-c732-4cbc-9845-579b8f62b929",
  "purchase_order_reference_back_office": "sample string 3",
  "purchase_order": {
    "id": "cd8f1f31-4012-4f89-b6d0-a1c4ee70cd52",
    "id2": 2,
    "jobs_id": "fe0bda74-8e69-44a8-a8e4-551a8824c115",
    "jobs_reference_back_office": "sample string 4",
    "supplier_company_id": "3475d1b7-3657-42c6-a54c-ccad29edfd9a",
    "supplier_company_code": "sample string 6",
    "user_id": "dd4afb45-8f25-4c8f-939a-bbe690a25e67",
    "user_code": "sample string 8",
    "description": "sample string 9",
    "memo": "sample string 10",
    "total_lines": 11,
    "date_create": "2026-04-18T03:51:55.7422347+00:00",
    "date_update": "2026-04-18T03:51:55.7422347+00:00",
    "date_delivery": "2026-04-18T03:51:55.7422347+00:00",
    "confirmed_date_delivery": "2026-04-18T03:51:55.7422347+00:00",
    "delivery_db_address_id": "3d2a5936-0586-4a4d-9fbc-d0b4d9418939",
    "approved_by_user_id": "95f3d856-9b07-4795-b680-9a6443e2cd59",
    "approved_by_user_code": "sample string 18",
    "technical_user_id": "fbc2df7c-3fe7-497a-a491-9af67041dde0",
    "technical_user_code": "sample string 20",
    "purchase_order_status_id": "c97465c7-fbea-4b1e-9530-7a245a7bf775",
    "purchase_order_status_code": "sample string 22",
    "article_stock_location_id": "10de8501-bb12-4c69-9302-87189f7e7938",
    "is_pickup": true,
    "reference_back_office": "sample string 25",
    "modified_dateutc": "2026-04-18T03:51:55.7422347+00:00"
  },
  "article_id": "0bc6ea04-6e1a-4a2d-b0c9-6378a7f240fb",
  "article_code": "sample string 5",
  "article": {
    "id": "fa19885b-86cf-469e-9d85-b5def5050ac7",
    "article_category_id": "0fd36693-29a6-428d-b342-59d72f5b6d9a",
    "article_category": {
      "id": "b22d0ea1-b7b5-409c-9ee8-1a8855dc26b0",
      "parent_id": "07bc968c-f10e-4c05-882e-201a660f6229",
      "parent_code": "sample string 3",
      "code": "sample string 4",
      "name": "sample string 5",
      "modified_dateutc": "2026-04-18T03:51:55.7422347+00:00"
    },
    "article_category_code": "sample string 3",
    "article_group_1_id": "7121ed35-a8e2-466c-a344-90ffa9a990fb",
    "article_group_1_code": "sample string 5",
    "article_group_2_id": "b5f8d8ae-103d-4215-9e69-a2c8d83d84fb",
    "article_group_2_code": "sample string 7",
    "article_group_3_id": "b318ee9c-2fb1-414c-bd4c-3d9e4ac8f2f4",
    "article_group_3_code": "sample string 9",
    "article_group_4_id": "ef8edf08-5610-4e5a-8be6-33b509aa86c9",
    "article_group_4_code": "sample string 11",
    "article_group_5_id": "eeba5110-2c49-49f4-b9b0-85abe58104a4",
    "article_group_5_code": "sample string 13",
    "article_group_6_id": "d7f8c2e1-c69a-4a00-96ac-32508566eb2f",
    "article_group_6_code": "sample string 15",
    "physical_stock": 16,
    "back_order_client": 17,
    "back_order_supplier": 18,
    "expected_delivery_date_bo_supplier": "2026-04-18T03:51:55.7422347+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-04-18T03:51:55.7422347+00:00",
    "date_update": "2026-04-18T03:51:55.7422347+00:00",
    "modified_dateutc": "2026-04-18T03:51:55.7422347+00:00",
    "article_color_id": "93ff6217-42dd-46f6-8087-bdb226e300a5",
    "article_color_code": "sample string 38",
    "article_color": {
      "id": "53d9c4ca-829d-46c7-8fd1-b565ff6e1d6e",
      "name": "sample string 2",
      "code": "sample string 3",
      "modified_dateutc": "2026-04-18T03:51:55.7422347+00:00"
    },
    "warranty_period_nb_months": 39,
    "use_serial": true,
    "_replace_id": "4e403b39-e744-4af1-af57-431a3d10f7aa",
    "replace_article_code": "sample string 42",
    "db_unit_of_measure_id_selling": "6b006598-5e29-4a92-aff7-8994c42ea525",
    "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-04-18T03:51:55.7422347+00:00"
}

Response Information

Resource Description :

IHttpActionResult

None.

Response Formats

application/json, text/json

Sample:

Sample not available.