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": "c90226e9-45f2-4677-bfa3-a9bef690a0e5",
  "purchase_order_id": "0f923702-2565-4b59-b42f-5cdb3d8bbfca",
  "purchase_order_reference_back_office": "sample string 3",
  "purchase_order": {
    "id": "4a553e8e-404a-4e51-bbeb-941a9daee91e",
    "id2": 2,
    "jobs_id": "12214e40-aa6e-4e49-95e5-500c07e7f7de",
    "jobs_reference_back_office": "sample string 4",
    "supplier_company_id": "dbc1481c-1db2-4b91-9db7-d56adaa71bb4",
    "supplier_company_code": "sample string 6",
    "user_id": "5f25a50b-cf60-4fb9-9eb5-adaac6b1e26f",
    "user_code": "sample string 8",
    "description": "sample string 9",
    "memo": "sample string 10",
    "total_lines": 11,
    "date_create": "2026-08-20T17:09:46.1087974+00:00",
    "date_update": "2026-08-20T17:09:46.1087974+00:00",
    "date_delivery": "2026-08-20T17:09:46.1087974+00:00",
    "confirmed_date_delivery": "2026-08-20T17:09:46.1087974+00:00",
    "delivery_db_address_id": "0f332b45-e88d-41ed-b0a8-e3894fd74940",
    "approved_by_user_id": "ddb2a465-a73a-491a-ad34-ad02268cf893",
    "approved_by_user_code": "sample string 18",
    "technical_user_id": "83f1dcf2-a7db-4942-939b-831edb69ea76",
    "technical_user_code": "sample string 20",
    "purchase_order_status_id": "76e1807f-a8af-4500-b6a7-e9530d3f1feb",
    "purchase_order_status_code": "sample string 22",
    "article_stock_location_id": "f1b7e4b8-fa2e-4a8e-ac65-236201f20647",
    "is_pickup": true,
    "reference_back_office": "sample string 25",
    "modified_dateutc": "2026-08-20T17:09:46.1087974+00:00"
  },
  "article_id": "f90a1535-e246-4a09-b57f-e6b790ee5065",
  "article_code": "sample string 5",
  "article": {
    "id": "5491faea-25b8-438c-8b07-8506ba944c1f",
    "article_category_id": "9e972f46-6ea1-47c0-aded-865ac7920f8d",
    "article_category": {
      "id": "362693d9-eb0f-4166-b2d6-12392c5578e2",
      "parent_id": "e3dbbfbf-8f4a-4277-beb5-e518a4b0eb8b",
      "parent_code": "sample string 3",
      "code": "sample string 4",
      "name": "sample string 5",
      "modified_dateutc": "2026-08-20T17:09:46.1087974+00:00"
    },
    "article_category_code": "sample string 3",
    "article_group_1_id": "8e18eff5-01a4-4541-aa27-693732904395",
    "article_group_1_code": "sample string 5",
    "article_group_2_id": "26564050-a735-4b9d-9f57-b7fc220a4fb9",
    "article_group_2_code": "sample string 7",
    "article_group_3_id": "ab173676-2efa-4d97-914e-fbaa143d1c5c",
    "article_group_3_code": "sample string 9",
    "article_group_4_id": "a228cf01-b108-4755-9e06-8e6d64c5c5e7",
    "article_group_4_code": "sample string 11",
    "article_group_5_id": "be8b5352-5a9c-425d-9f78-02a989bb8080",
    "article_group_5_code": "sample string 13",
    "article_group_6_id": "89f598de-12d2-4e10-a655-0f94b94d0fad",
    "article_group_6_code": "sample string 15",
    "physical_stock": 16,
    "back_order_client": 17,
    "back_order_supplier": 18,
    "expected_delivery_date_bo_supplier": "2026-08-20T17:09:46.1087974+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-08-20T17:09:46.1087974+00:00",
    "date_update": "2026-08-20T17:09:46.1087974+00:00",
    "modified_dateutc": "2026-08-20T17:09:46.1087974+00:00",
    "article_color_id": "979dfe02-066b-4cc3-a0aa-141d53597d74",
    "article_color_code": "sample string 38",
    "article_color": {
      "id": "a9ababd5-a04c-4a8d-b60b-062aed0e0729",
      "name": "sample string 2",
      "code": "sample string 3",
      "modified_dateutc": "2026-08-20T17:09:46.1087974+00:00"
    },
    "warranty_period_nb_months": 39,
    "use_serial": true,
    "_replace_id": "6c400704-c5d3-4d39-a15f-171b19fb6452",
    "replace_article_code": "sample string 42",
    "db_unit_of_measure_id_selling": "0a3928d2-f4d5-4109-a6d3-5babc688e323",
    "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-08-20T17:09:46.1087974+00:00"
}

Response Information

Resource Description :

IHttpActionResult

None.

Response Formats

application/json, text/json

Sample:

Sample not available.