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": "f93fdf3c-dded-4ff0-8779-19d377ea3eeb",
  "purchase_order_id": "3ffb7bca-aa11-4731-87e9-eaffca7cfb22",
  "purchase_order_reference_back_office": "sample string 3",
  "purchase_order": {
    "id": "43e6cc16-f068-4fd2-9197-6e16e2e33cc2",
    "id2": 2,
    "jobs_id": "aac49528-4696-4a97-8ac8-d7ce96ba3071",
    "jobs_reference_back_office": "sample string 4",
    "supplier_company_id": "dcad2bcf-f778-48b2-982a-1e11dd010ef9",
    "supplier_company_code": "sample string 6",
    "user_id": "aefa1c56-fe1f-41cf-92a5-65d99ad09fe6",
    "user_code": "sample string 8",
    "description": "sample string 9",
    "memo": "sample string 10",
    "total_lines": 11,
    "date_create": "2026-07-01T07:38:09.5339325+00:00",
    "date_update": "2026-07-01T07:38:09.5339325+00:00",
    "date_delivery": "2026-07-01T07:38:09.5339325+00:00",
    "confirmed_date_delivery": "2026-07-01T07:38:09.5339325+00:00",
    "delivery_db_address_id": "1e546cbf-8e7a-408a-8fca-86ab668c3faf",
    "approved_by_user_id": "1a147a96-6ec3-4f6d-9a24-62f545c52f82",
    "approved_by_user_code": "sample string 18",
    "technical_user_id": "f2f85243-c0e9-4a65-8b50-90a4bcce432c",
    "technical_user_code": "sample string 20",
    "purchase_order_status_id": "df4f13bf-749a-4476-9ee6-abc8173b02b3",
    "purchase_order_status_code": "sample string 22",
    "article_stock_location_id": "678e7a6c-eedc-4476-a0eb-033efa33e833",
    "is_pickup": true,
    "reference_back_office": "sample string 25",
    "modified_dateutc": "2026-07-01T07:38:09.5339325+00:00"
  },
  "article_id": "a3eaa01e-1c34-46cc-ac92-c7005bb60829",
  "article_code": "sample string 5",
  "article": {
    "id": "dba9424d-bf58-4533-82e7-bbacb7d95f41",
    "article_category_id": "faeb4553-d423-4a18-95a5-3d7226f81780",
    "article_category": {
      "id": "2567b469-9c86-462d-b856-c40eaaed4fb1",
      "parent_id": "726e1bbb-87fa-4161-9953-3149751bc4d8",
      "parent_code": "sample string 3",
      "code": "sample string 4",
      "name": "sample string 5",
      "modified_dateutc": "2026-07-01T07:38:09.5339325+00:00"
    },
    "article_category_code": "sample string 3",
    "article_group_1_id": "89232357-00be-447f-836c-4fadb235c268",
    "article_group_1_code": "sample string 5",
    "article_group_2_id": "ae00cbac-6ff9-460c-be3a-0bd5c9dba43e",
    "article_group_2_code": "sample string 7",
    "article_group_3_id": "4fc79709-c688-4fcc-aa67-e1d5ac14c12a",
    "article_group_3_code": "sample string 9",
    "article_group_4_id": "ba21c03c-0010-4329-93b3-9bf3605f3319",
    "article_group_4_code": "sample string 11",
    "article_group_5_id": "f9e0a6c6-b514-409a-80e8-66dc6e9c3790",
    "article_group_5_code": "sample string 13",
    "article_group_6_id": "fafcf48b-58f3-4613-b989-c028d6e77109",
    "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-01T07:38:09.5339325+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-01T07:38:09.5339325+00:00",
    "date_update": "2026-07-01T07:38:09.5339325+00:00",
    "modified_dateutc": "2026-07-01T07:38:09.5339325+00:00",
    "article_color_id": "ce150ef1-ec0e-48f3-9c14-0f79cce20605",
    "article_color_code": "sample string 38",
    "article_color": {
      "id": "5e1c27ad-d9c8-434a-9051-5d1899a32cb4",
      "name": "sample string 2",
      "code": "sample string 3",
      "modified_dateutc": "2026-07-01T07:38:09.5339325+00:00"
    },
    "warranty_period_nb_months": 39,
    "use_serial": true,
    "_replace_id": "838597f1-f4ec-45b3-991d-d70bc29f8098",
    "replace_article_code": "sample string 42",
    "db_unit_of_measure_id_selling": "88706821-2a76-470d-b6f5-c79212c35c82",
    "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-01T07:38:09.5339325+00:00"
}

Response Information

Resource Description :

IHttpActionResult

None.

Response Formats

application/json, text/json

Sample:

Sample not available.