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": "e4c08be7-35f4-40c6-813d-68c3e9b492ab",
  "purchase_order_id": "d8667cc4-ba7a-4621-b58b-94164f1f32a4",
  "purchase_order_reference_back_office": "sample string 3",
  "purchase_order": {
    "id": "1bbc03dd-becf-44ac-a6ef-55faec180677",
    "id2": 2,
    "jobs_id": "3d275ed0-0f67-422d-88a1-be055b5c9781",
    "jobs_reference_back_office": "sample string 4",
    "supplier_company_id": "2d299129-1172-44e7-8f9d-301be4b344ab",
    "supplier_company_code": "sample string 6",
    "user_id": "c62342c1-3c04-4c91-9900-fbb7eb7f69a6",
    "user_code": "sample string 8",
    "description": "sample string 9",
    "memo": "sample string 10",
    "total_lines": 11,
    "date_create": "2026-10-06T09:39:47.2528016+00:00",
    "date_update": "2026-10-06T09:39:47.2528016+00:00",
    "date_delivery": "2026-10-06T09:39:47.2528016+00:00",
    "confirmed_date_delivery": "2026-10-06T09:39:47.2528016+00:00",
    "delivery_db_address_id": "0803757c-030d-4857-93e4-b189b757a8b2",
    "approved_by_user_id": "ec22024f-8b87-497a-959d-038533af5a1c",
    "approved_by_user_code": "sample string 18",
    "technical_user_id": "3cb94c52-aca7-480b-947d-b510638c2e39",
    "technical_user_code": "sample string 20",
    "purchase_order_status_id": "78dbedd0-fc42-412b-bb6a-32048cac0717",
    "purchase_order_status_code": "sample string 22",
    "article_stock_location_id": "3dd26361-2dea-4577-b5d6-bbbc60850326",
    "is_pickup": true,
    "reference_back_office": "sample string 25",
    "modified_dateutc": "2026-10-06T09:39:47.2528016+00:00"
  },
  "article_id": "afd79470-d8b7-41e4-8d9e-1e13014d074c",
  "article_code": "sample string 5",
  "article": {
    "id": "64f4a77f-f858-44f4-ab75-658acdf66ed9",
    "article_category_id": "0565661a-ab73-4eb7-9fe9-648bcb64ea91",
    "article_category": {
      "id": "24de04b1-6bbf-4aac-8843-735eb4d23dd4",
      "parent_id": "6ea689bc-6a73-4d5b-abc5-5553153d1ddb",
      "parent_code": "sample string 3",
      "code": "sample string 4",
      "name": "sample string 5",
      "modified_dateutc": "2026-10-06T09:39:47.2528016+00:00"
    },
    "article_category_code": "sample string 3",
    "article_group_1_id": "d37b0e73-004d-40ca-90f8-fb275e46c359",
    "article_group_1_code": "sample string 5",
    "article_group_2_id": "bbafef6e-4fe9-4f58-a9fe-8d61b9931083",
    "article_group_2_code": "sample string 7",
    "article_group_3_id": "814d4274-c336-44a9-818b-e8184b2bdd9c",
    "article_group_3_code": "sample string 9",
    "article_group_4_id": "2ed22924-57f3-4a4c-929e-596e45fbf7ea",
    "article_group_4_code": "sample string 11",
    "article_group_5_id": "9cc7ce8e-796b-419a-b4a1-afad5da144ec",
    "article_group_5_code": "sample string 13",
    "article_group_6_id": "2e5d10f7-bfb2-4869-8c57-eac5175fc1af",
    "article_group_6_code": "sample string 15",
    "physical_stock": 16,
    "back_order_client": 17,
    "back_order_supplier": 18,
    "expected_delivery_date_bo_supplier": "2026-10-06T09:39:47.2691975+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-10-06T09:39:47.2691975+00:00",
    "date_update": "2026-10-06T09:39:47.2691975+00:00",
    "modified_dateutc": "2026-10-06T09:39:47.2691975+00:00",
    "article_color_id": "dc25ed1a-1ae5-4011-b319-78a3c8ba7e0f",
    "article_color_code": "sample string 38",
    "article_color": {
      "id": "0d5a10dd-fdec-40d4-a8ad-8ece612f4dc4",
      "name": "sample string 2",
      "code": "sample string 3",
      "modified_dateutc": "2026-10-06T09:39:47.2691975+00:00"
    },
    "warranty_period_nb_months": 39,
    "use_serial": true,
    "_replace_id": "a4e18af5-cec3-446f-8181-4af0dcbd39a8",
    "replace_article_code": "sample string 42",
    "db_unit_of_measure_id_selling": "2f599bfe-a06a-43f6-b90d-e26dd9bd8c42",
    "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-10-06T09:39:47.2691975+00:00"
}

Response Information

Resource Description :

IHttpActionResult

None.

Response Formats

application/json, text/json

Sample:

Sample not available.