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": "c799c035-43f8-4b2c-a752-6373e717f332",
  "purchase_order_id": "e99f2e6e-4dd7-407f-8ae4-e94568c5f658",
  "purchase_order_reference_back_office": "sample string 3",
  "purchase_order": {
    "id": "673942e2-3fc7-4112-ad16-c0714a2d9f6e",
    "id2": 2,
    "jobs_id": "f989342c-c3a4-4129-a873-40d651a98b52",
    "jobs_reference_back_office": "sample string 4",
    "supplier_company_id": "bcc4c4ae-0341-4776-a007-75e81bdf1bbf",
    "supplier_company_code": "sample string 6",
    "user_id": "6663eaab-b48b-458d-86de-07d514f58b25",
    "user_code": "sample string 8",
    "description": "sample string 9",
    "memo": "sample string 10",
    "total_lines": 11,
    "date_create": "2026-05-04T05:06:36.1108069+00:00",
    "date_update": "2026-05-04T05:06:36.1108069+00:00",
    "date_delivery": "2026-05-04T05:06:36.1108069+00:00",
    "confirmed_date_delivery": "2026-05-04T05:06:36.1108069+00:00",
    "delivery_db_address_id": "0aa454ac-19b3-4f78-bdc6-67ca1dbb0046",
    "approved_by_user_id": "c9c59eab-5693-41b3-89fb-7e416f9468e4",
    "approved_by_user_code": "sample string 18",
    "technical_user_id": "2807ee41-b7d5-472f-ab4d-502f3e444e9d",
    "technical_user_code": "sample string 20",
    "purchase_order_status_id": "87a88bc6-dba3-4c5c-b239-87cf9c1022b5",
    "purchase_order_status_code": "sample string 22",
    "article_stock_location_id": "81d506ce-7f1b-4736-bcd4-50360bc9e0ab",
    "is_pickup": true,
    "reference_back_office": "sample string 25",
    "modified_dateutc": "2026-05-04T05:06:36.1108069+00:00"
  },
  "article_id": "a0b897ef-a340-48c4-ae35-bf5ffd5897b4",
  "article_code": "sample string 5",
  "article": {
    "id": "ba37c174-3f77-4aa4-85d5-c91c6bd781b6",
    "article_category_id": "0d80578f-f036-4c3d-b13b-46996c74b1a3",
    "article_category": {
      "id": "a19447c9-c36f-4c1a-9e9a-7070556487f8",
      "parent_id": "47d76aad-7489-469e-910a-c096ca83f2ea",
      "parent_code": "sample string 3",
      "code": "sample string 4",
      "name": "sample string 5",
      "modified_dateutc": "2026-05-04T05:06:36.1108069+00:00"
    },
    "article_category_code": "sample string 3",
    "article_group_1_id": "8ddc9710-6a62-49c0-a69e-215240db04b1",
    "article_group_1_code": "sample string 5",
    "article_group_2_id": "8b20a832-1792-42d8-aa12-786ad1dd8a62",
    "article_group_2_code": "sample string 7",
    "article_group_3_id": "142d5289-287c-4a57-9211-a36ef3a5e762",
    "article_group_3_code": "sample string 9",
    "article_group_4_id": "2457cfa9-cb35-4fa3-85ff-4487ea527377",
    "article_group_4_code": "sample string 11",
    "article_group_5_id": "8507b9fa-be08-4af3-817c-a87391a7929a",
    "article_group_5_code": "sample string 13",
    "article_group_6_id": "841cb6cb-6186-47e5-adcc-06429b6927c8",
    "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-04T05:06:36.1108069+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-04T05:06:36.1108069+00:00",
    "date_update": "2026-05-04T05:06:36.1108069+00:00",
    "modified_dateutc": "2026-05-04T05:06:36.1108069+00:00",
    "article_color_id": "88cba14f-18e1-4d78-b59e-5a40dbf735b9",
    "article_color_code": "sample string 38",
    "article_color": {
      "id": "b7c4b902-1b02-462a-8ed9-a42e8102d246",
      "name": "sample string 2",
      "code": "sample string 3",
      "modified_dateutc": "2026-05-04T05:06:36.1108069+00:00"
    },
    "warranty_period_nb_months": 39,
    "use_serial": true,
    "_replace_id": "fc0dd51b-cdf9-4cb1-b402-169b05e1afc4",
    "replace_article_code": "sample string 42",
    "db_unit_of_measure_id_selling": "c9a2eb12-f2ac-46a9-867a-464d86c7fb00",
    "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-04T05:06:36.1108069+00:00"
}

Response Information

Resource Description :

IHttpActionResult

None.

Response Formats

application/json, text/json

Sample:

Sample not available.