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": "686c6e34-d6c2-444e-a098-273132312ebd",
  "purchase_order_id": "58af675c-556d-4849-a281-8590696086fb",
  "purchase_order_reference_back_office": "sample string 3",
  "purchase_order": {
    "id": "449e1144-487b-456d-9e6c-d251f2e03e20",
    "id2": 2,
    "jobs_id": "a0f54736-e43a-464f-bf95-4cdaddff1918",
    "jobs_reference_back_office": "sample string 4",
    "supplier_company_id": "d331fe94-26f2-43be-96c5-d379d7c57d59",
    "supplier_company_code": "sample string 6",
    "user_id": "bffb18cd-e70a-40e5-9916-2dbf533d7444",
    "user_code": "sample string 8",
    "description": "sample string 9",
    "memo": "sample string 10",
    "total_lines": 11,
    "date_create": "2026-05-09T12:00:47.4187587+00:00",
    "date_update": "2026-05-09T12:00:47.4187587+00:00",
    "date_delivery": "2026-05-09T12:00:47.4187587+00:00",
    "confirmed_date_delivery": "2026-05-09T12:00:47.4187587+00:00",
    "delivery_db_address_id": "bab3c8e3-3d29-4868-a565-30a02c888423",
    "approved_by_user_id": "b9d61f1b-4a7c-4a0f-97e1-e8a2168bbec8",
    "approved_by_user_code": "sample string 18",
    "technical_user_id": "749927cb-ce3c-4c5e-af40-fd68bf0d519c",
    "technical_user_code": "sample string 20",
    "purchase_order_status_id": "3c5e41bb-543a-4c81-81ba-9693de08b098",
    "purchase_order_status_code": "sample string 22",
    "article_stock_location_id": "e7e142d3-e249-4564-b73f-5d687f9e6718",
    "is_pickup": true,
    "reference_back_office": "sample string 25",
    "modified_dateutc": "2026-05-09T12:00:47.4187587+00:00"
  },
  "article_id": "9dc599fd-2239-4674-8256-e64a121fc56c",
  "article_code": "sample string 5",
  "article": {
    "id": "9134eac3-bcdd-4d65-8a8f-b532ccb58e6f",
    "article_category_id": "a535c518-e892-4d23-ba6c-ed58b3fed806",
    "article_category": {
      "id": "5ccd360a-b997-403a-9088-f8ec6588ab1b",
      "parent_id": "d2157682-5149-41f2-9843-97d36dd61569",
      "parent_code": "sample string 3",
      "code": "sample string 4",
      "name": "sample string 5",
      "modified_dateutc": "2026-05-09T12:00:47.4187587+00:00"
    },
    "article_category_code": "sample string 3",
    "article_group_1_id": "6df6fc6e-e4fe-4c74-8ac4-0896bf698ba0",
    "article_group_1_code": "sample string 5",
    "article_group_2_id": "3dacc907-a2f8-4906-8bbd-e04696765b13",
    "article_group_2_code": "sample string 7",
    "article_group_3_id": "f9dafbc1-41fa-4f21-87a0-12a7bf0a44fb",
    "article_group_3_code": "sample string 9",
    "article_group_4_id": "dc3dcff4-4e01-4722-b298-0065c1091bab",
    "article_group_4_code": "sample string 11",
    "article_group_5_id": "9e5ceed8-8727-416a-b7d1-ab22a840bc05",
    "article_group_5_code": "sample string 13",
    "article_group_6_id": "1df901d1-60fc-43e9-a744-11d193293ca9",
    "article_group_6_code": "sample string 15",
    "physical_stock": 16,
    "back_order_client": 17,
    "back_order_supplier": 18,
    "expected_delivery_date_bo_supplier": "2026-05-09T12:00:47.4187587+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-05-09T12:00:47.4187587+00:00",
    "date_update": "2026-05-09T12:00:47.4187587+00:00",
    "modified_dateutc": "2026-05-09T12:00:47.4187587+00:00",
    "article_color_id": "05f2271c-b2d9-4fb6-8a5d-d9aea7f3f18e",
    "article_color_code": "sample string 38",
    "article_color": {
      "id": "0f3b8bdd-44e9-4b24-abab-1c556ce811e5",
      "name": "sample string 2",
      "code": "sample string 3",
      "modified_dateutc": "2026-05-09T12:00:47.4187587+00:00"
    },
    "warranty_period_nb_months": 39,
    "use_serial": true,
    "_replace_id": "a51b6333-a405-4033-8dd6-0936cdd00144",
    "replace_article_code": "sample string 42",
    "db_unit_of_measure_id_selling": "5e00559a-8973-461f-b03c-c4a9ea9682a4",
    "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-05-09T12:00:47.4187587+00:00"
}

Response Information

Resource Description :

IHttpActionResult

None.

Response Formats

application/json, text/json

Sample:

Sample not available.