/fuel-pump-inventories-purchase-orders-post-one

Summary

  • Source repository: jef-systems/jef-fuel-pump-inventories-backend

  • Source SHA: 72119609d80692052adc7462ef8cbe24eb23f022

  • Source run id: 28366940754

  • Lambda function: jef-fuel-pump-inventories-post-003

  • HTTP method: POST

  • API path: /fuel-pump-inventories-purchase-orders-post-one

  • Endpoint URL: https://fsqf5slhc1.execute-api.ap-southeast-1.amazonaws.com/prod/fuel-pump-inventories-purchase-orders-post-one

  • Payload mode: json-body

Description

Function

jef-fuel-pump-inventories-post-003 Logical ID: jef-fuel-pump-inventories:jef-fuel-pump-inventories-purchase-orders:post-one Order Number: 003

Module

jef-fuel-pump-inventories

Action

post-one

Method

POST

Invocation Mode

ASYNC

Resource Path

/fuel-pump-inventories-purchase-orders-post-one Endpoint Name: jef-fuel-pump-inventories-purchase-orders-post-one

Table

jef-fuel-pump-inventories-purchase-orders

Primary Key

purchase_order_id

API Gateway Response

status\_code

202

message

Request accepted for asynchronous processing.

Payload Example

purchase\_order\_id

c39a1319-2df5-45eb-a7cc-b8c23b44c74c

gas\_station\_id

7cd83abd-1c94-42ba-8be4-8304c34bec6c

purchase\_order\_number

value-001

date

2026-05-17

supplier\_name

Sample Name

delivery\_reference\_number

value-001

total\_liters

1

total\_amount

1

created

2026-06-29T10:53:22Z

updated

2026-06-29T10:53:22Z

children.jef-fuel-pump-inventories-purchase-order-line-items\[0\].purchase\_order\_line\_item\_id

ed7b60d1-02f0-4689-a164-a6a35c96ba3c

children.jef-fuel-pump-inventories-purchase-order-line-items\[0\].purchase\_order\_id

c39a1319-2df5-45eb-a7cc-b8c23b44c74c

children.jef-fuel-pump-inventories-purchase-order-line-items\[0\].gas\_station\_id

9ccbe503-d431-47ec-b60e-bd0f886d5a6f

children.jef-fuel-pump-inventories-purchase-order-line-items\[0\].line\_number

1

children.jef-fuel-pump-inventories-purchase-order-line-items\[0\].pump\_id

c442b932-80ac-46c2-bf6c-f050543efbdd

children.jef-fuel-pump-inventories-purchase-order-line-items\[0\].pump

value-001

children.jef-fuel-pump-inventories-purchase-order-line-items\[0\].product

value-001

children.jef-fuel-pump-inventories-purchase-order-line-items\[0\].liters

1

children.jef-fuel-pump-inventories-purchase-order-line-items\[0\].price\_per\_liter

1

children.jef-fuel-pump-inventories-purchase-order-line-items\[0\].total\_amount

1

children.jef-fuel-pump-inventories-purchase-order-line-items\[0\].delivery\_reference\_number

value-001

children.jef-fuel-pump-inventories-purchase-order-line-items\[0\].notes

value-001

children.jef-fuel-pump-inventories-purchase-order-line-items\[0\].status

value-001

children.jef-fuel-pump-inventories-purchase-order-line-items\[0\].created

2026-06-29T10:53:22Z

children.jef-fuel-pump-inventories-purchase-order-line-items\[0\].updated

2026-06-29T10:53:22Z

Payload Schema

{
  "type": "object",
  "additionalProperties": "False",
  "payload_mode": "parent-plus-children-wrapper",
  "allow_children_wrapper": "True",
  "children_wrapper_field": "children",
  "allow_batch": "False",
  "table": "jef-fuel-pump-inventories-purchase-orders",
  "primary_key": "purchase_order_id",
  "required[0]": "gas_station_id",
  "required[1]": "purchase_order_number",
  "required[2]": "date",
  "required[3]": "supplier_name",
  "required[4]": "total_liters",
  "required[5]": "total_amount",
  "properties.purchase_order_id.field": "purchase_order_id",
  "properties.purchase_order_id.type": "S",
  "properties.purchase_order_id.required": "False",
  "properties.purchase_order_id.source_required": "True",
  "properties.purchase_order_id.server_generated": "True",
  "properties.purchase_order_id.autogenerated": "False",
  "properties.purchase_order_id.frontend_autocomputed": "False",
  "properties.purchase_order_id.format": "uuidv4",
  "properties.purchase_order_id.regex": "^[1-9a-fA-F][0-9a-fA-F]{7}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$",
  "properties.gas_station_id.field": "gas_station_id",
  "properties.gas_station_id.type": "S",
  "properties.gas_station_id.required": "True",
  "properties.gas_station_id.source_required": "True",
  "properties.gas_station_id.server_generated": "True",
  "properties.gas_station_id.autogenerated": "False",
  "properties.gas_station_id.frontend_autocomputed": "False",
  "properties.gas_station_id.format": "uuidv4",
  "properties.gas_station_id.regex": "^[1-9a-fA-F][0-9a-fA-F]{7}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$",
  "properties.purchase_order_number.field": "purchase_order_number",
  "properties.purchase_order_number.type": "S",
  "properties.purchase_order_number.required": "True",
  "properties.purchase_order_number.source_required": "True",
  "properties.purchase_order_number.server_generated": "False",
  "properties.purchase_order_number.autogenerated": "False",
  "properties.purchase_order_number.frontend_autocomputed": "False",
  "properties.purchase_order_number.regex": "^[A-Za-z0-9_-]{1,64}$",
  "properties.date.field": "date",
  "properties.date.type": "S",
  "properties.date.required": "True",
  "properties.date.source_required": "True",
  "properties.date.server_generated": "False",
  "properties.date.autogenerated": "False",
  "properties.date.frontend_autocomputed": "False",
  "properties.date.regex": "^\\d{4}-\\d{2}-\\d{2}$",
  "properties.supplier_name.field": "supplier_name",
  "properties.supplier_name.type": "S",
  "properties.supplier_name.required": "True",
  "properties.supplier_name.source_required": "True",
  "properties.supplier_name.server_generated": "False",
  "properties.supplier_name.autogenerated": "False",
  "properties.supplier_name.frontend_autocomputed": "False",
  "properties.supplier_name.regex": "^[A-Za-z0-9 .,'_-]{1,120}$",
  "properties.delivery_reference_number.field": "delivery_reference_number",
  "properties.delivery_reference_number.type": "S",
  "properties.delivery_reference_number.required": "False",
  "properties.delivery_reference_number.source_required": "False",
  "properties.delivery_reference_number.server_generated": "False",
  "properties.delivery_reference_number.autogenerated": "False",
  "properties.delivery_reference_number.frontend_autocomputed": "False",
  "properties.delivery_reference_number.regex": "^[A-Za-z0-9_-]{1,64}$",
  "properties.total_liters.field": "total_liters",
  "properties.total_liters.type": "N",
  "properties.total_liters.required": "True",
  "properties.total_liters.source_required": "True",
  "properties.total_liters.server_generated": "False",
  "properties.total_liters.autogenerated": "False",
  "properties.total_liters.frontend_autocomputed": "False",
  "properties.total_liters.regex": "^-?\\d+(\\.\\d+)?$",
  "properties.total_amount.field": "total_amount",
  "properties.total_amount.type": "N",
  "properties.total_amount.required": "True",
  "properties.total_amount.source_required": "True",
  "properties.total_amount.server_generated": "False",
  "properties.total_amount.autogenerated": "False",
  "properties.total_amount.frontend_autocomputed": "False",
  "properties.total_amount.regex": "^-?\\d+(\\.\\d+)?$",
  "properties.created.field": "created",
  "properties.created.type": "S",
  "properties.created.required": "False",
  "properties.created.source_required": "True",
  "properties.created.server_generated": "True",
  "properties.created.autogenerated": "False",
  "properties.created.frontend_autocomputed": "False",
  "properties.created.format": "iso8601",
  "properties.created.regex": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d{1,6})?Z?$",
  "properties.updated.field": "updated",
  "properties.updated.type": "S",
  "properties.updated.required": "False",
  "properties.updated.source_required": "True",
  "properties.updated.server_generated": "True",
  "properties.updated.autogenerated": "False",
  "properties.updated.frontend_autocomputed": "False",
  "properties.updated.format": "iso8601",
  "properties.updated.regex": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d{1,6})?Z?$",
  "children[0].parent_table": "jef-fuel-pump-inventories-purchase-orders",
  "children[0].child_table": "jef-fuel-pump-inventories-purchase-order-line-items",
  "children[0].parent_key": "purchase_order_id",
  "children[0].child_foreign_key": "purchase_order_id",
  "children[0].child_index_name": "gsi_1",
  "children[0].child_index_key": "gsi_1_pk",
  "children[0].aliases[0]": "jef-fuel-pump-inventories-purchase-order-line-items",
  "children[0].aliases[1]": "purchase-order-line-items",
  "children[0].aliases[2]": "fuel-pump-inventories-purchase-order-line-items",
  "children[0].aliases[3]": "jef_fuel_pump_inventories_purchase_order_line_items",
  "children[0].aliases[4]": "purchase_order_line_items",
  "children[0].aliases[5]": "fuel_pump_inventories_purchase_order_line_items",
  "children[0].aliases[6]": "items",
  "root.type": "object",
  "root.attributes.purchase_order_id.field": "purchase_order_id",
  "root.attributes.purchase_order_id.type": "S",
  "root.attributes.purchase_order_id.required": "False",
  "root.attributes.purchase_order_id.source_required": "True",
  "root.attributes.purchase_order_id.server_generated": "True",
  "root.attributes.purchase_order_id.autogenerated": "False",
  "root.attributes.purchase_order_id.frontend_autocomputed": "False",
  "root.attributes.purchase_order_id.format": "uuidv4",
  "root.attributes.purchase_order_id.regex": "^[1-9a-fA-F][0-9a-fA-F]{7}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$",
  "root.attributes.gas_station_id.field": "gas_station_id",
  "root.attributes.gas_station_id.type": "S",
  "root.attributes.gas_station_id.required": "True",
  "root.attributes.gas_station_id.source_required": "True",
  "root.attributes.gas_station_id.server_generated": "True",
  "root.attributes.gas_station_id.autogenerated": "False",
  "root.attributes.gas_station_id.frontend_autocomputed": "False",
  "root.attributes.gas_station_id.format": "uuidv4",
  "root.attributes.gas_station_id.regex": "^[1-9a-fA-F][0-9a-fA-F]{7}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$",
  "root.attributes.purchase_order_number.field": "purchase_order_number",
  "root.attributes.purchase_order_number.type": "S",
  "root.attributes.purchase_order_number.required": "True",
  "root.attributes.purchase_order_number.source_required": "True",
  "root.attributes.purchase_order_number.server_generated": "False",
  "root.attributes.purchase_order_number.autogenerated": "False",
  "root.attributes.purchase_order_number.frontend_autocomputed": "False",
  "root.attributes.purchase_order_number.regex": "^[A-Za-z0-9_-]{1,64}$",
  "root.attributes.date.field": "date",
  "root.attributes.date.type": "S",
  "root.attributes.date.required": "True",
  "root.attributes.date.source_required": "True",
  "root.attributes.date.server_generated": "False",
  "root.attributes.date.autogenerated": "False",
  "root.attributes.date.frontend_autocomputed": "False",
  "root.attributes.date.regex": "^\\d{4}-\\d{2}-\\d{2}$",
  "root.attributes.supplier_name.field": "supplier_name",
  "root.attributes.supplier_name.type": "S",
  "root.attributes.supplier_name.required": "True",
  "root.attributes.supplier_name.source_required": "True",
  "root.attributes.supplier_name.server_generated": "False",
  "root.attributes.supplier_name.autogenerated": "False",
  "root.attributes.supplier_name.frontend_autocomputed": "False",
  "root.attributes.supplier_name.regex": "^[A-Za-z0-9 .,'_-]{1,120}$",
  "root.attributes.delivery_reference_number.field": "delivery_reference_number",
  "root.attributes.delivery_reference_number.type": "S",
  "root.attributes.delivery_reference_number.required": "False",
  "root.attributes.delivery_reference_number.source_required": "False",
  "root.attributes.delivery_reference_number.server_generated": "False",
  "root.attributes.delivery_reference_number.autogenerated": "False",
  "root.attributes.delivery_reference_number.frontend_autocomputed": "False",
  "root.attributes.delivery_reference_number.regex": "^[A-Za-z0-9_-]{1,64}$",
  "root.attributes.total_liters.field": "total_liters",
  "root.attributes.total_liters.type": "N",
  "root.attributes.total_liters.required": "True",
  "root.attributes.total_liters.source_required": "True",
  "root.attributes.total_liters.server_generated": "False",
  "root.attributes.total_liters.autogenerated": "False",
  "root.attributes.total_liters.frontend_autocomputed": "False",
  "root.attributes.total_liters.regex": "^-?\\d+(\\.\\d+)?$",
  "root.attributes.total_amount.field": "total_amount",
  "root.attributes.total_amount.type": "N",
  "root.attributes.total_amount.required": "True",
  "root.attributes.total_amount.source_required": "True",
  "root.attributes.total_amount.server_generated": "False",
  "root.attributes.total_amount.autogenerated": "False",
  "root.attributes.total_amount.frontend_autocomputed": "False",
  "root.attributes.total_amount.regex": "^-?\\d+(\\.\\d+)?$",
  "root.attributes.created.field": "created",
  "root.attributes.created.type": "S",
  "root.attributes.created.required": "False",
  "root.attributes.created.source_required": "True",
  "root.attributes.created.server_generated": "True",
  "root.attributes.created.autogenerated": "False",
  "root.attributes.created.frontend_autocomputed": "False",
  "root.attributes.created.format": "iso8601",
  "root.attributes.created.regex": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d{1,6})?Z?$",
  "root.attributes.updated.field": "updated",
  "root.attributes.updated.type": "S",
  "root.attributes.updated.required": "False",
  "root.attributes.updated.source_required": "True",
  "root.attributes.updated.server_generated": "True",
  "root.attributes.updated.autogenerated": "False",
  "root.attributes.updated.frontend_autocomputed": "False",
  "root.attributes.updated.format": "iso8601",
  "root.attributes.updated.regex": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d{1,6})?Z?$"
}

Response Schema

{
  "type": "object",
  "properties.ok.type": "boolean",
  "properties.accepted.type": "boolean",
  "properties.is_committed.type": "boolean",
  "properties.request_id.type": "string",
  "properties.message.type": "string",
  "properties.table.type": "string",
  "properties.operation.type": "string",
  "properties.primary_key.type": "string",
  "properties.primary_key_value.type": "string",
  "properties.item_write_count.type": "number",
  "properties.child_write_count.type": "number"
}

Request Payload

{
  "purchase_order_id": "c39a1319-2df5-45eb-a7cc-b8c23b44c74c",
  "gas_station_id": "7cd83abd-1c94-42ba-8be4-8304c34bec6c",
  "purchase_order_number": "value-001",
  "date": "2026-05-17",
  "supplier_name": "Sample Name",
  "delivery_reference_number": "value-001",
  "total_liters": "1",
  "total_amount": "1",
  "created": "2026-06-29T10:53:22Z",
  "updated": "2026-06-29T10:53:22Z",
  "children.jef-fuel-pump-inventories-purchase-order-line-items[0].purchase_order_line_item_id": "ed7b60d1-02f0-4689-a164-a6a35c96ba3c",
  "children.jef-fuel-pump-inventories-purchase-order-line-items[0].purchase_order_id": "c39a1319-2df5-45eb-a7cc-b8c23b44c74c",
  "children.jef-fuel-pump-inventories-purchase-order-line-items[0].gas_station_id": "9ccbe503-d431-47ec-b60e-bd0f886d5a6f",
  "children.jef-fuel-pump-inventories-purchase-order-line-items[0].line_number": "1",
  "children.jef-fuel-pump-inventories-purchase-order-line-items[0].pump_id": "c442b932-80ac-46c2-bf6c-f050543efbdd",
  "children.jef-fuel-pump-inventories-purchase-order-line-items[0].pump": "value-001",
  "children.jef-fuel-pump-inventories-purchase-order-line-items[0].product": "value-001",
  "children.jef-fuel-pump-inventories-purchase-order-line-items[0].liters": "1",
  "children.jef-fuel-pump-inventories-purchase-order-line-items[0].price_per_liter": "1",
  "children.jef-fuel-pump-inventories-purchase-order-line-items[0].total_amount": "1",
  "children.jef-fuel-pump-inventories-purchase-order-line-items[0].delivery_reference_number": "value-001",
  "children.jef-fuel-pump-inventories-purchase-order-line-items[0].notes": "value-001",
  "children.jef-fuel-pump-inventories-purchase-order-line-items[0].status": "value-001",
  "children.jef-fuel-pump-inventories-purchase-order-line-items[0].created": "2026-06-29T10:53:22Z",
  "children.jef-fuel-pump-inventories-purchase-order-line-items[0].updated": "2026-06-29T10:53:22Z"
}

Response

{
  "type": "object",
  "properties.ok.type": "boolean",
  "properties.accepted.type": "boolean",
  "properties.is_committed.type": "boolean",
  "properties.request_id.type": "string",
  "properties.message.type": "string",
  "properties.table.type": "string",
  "properties.operation.type": "string",
  "properties.primary_key.type": "string",
  "properties.primary_key_value.type": "string",
  "properties.item_write_count.type": "number",
  "properties.child_write_count.type": "number"
}

CMD curl

curl -X POST "https://fsqf5slhc1.execute-api.ap-southeast-1.amazonaws.com/prod/fuel-pump-inventories-purchase-orders-post-one" -H "Content-Type: application/json" --data-raw "{\"purchase_order_id\": \"c39a1319-2df5-45eb-a7cc-b8c23b44c74c\", \"gas_station_id\": \"7cd83abd-1c94-42ba-8be4-8304c34bec6c\", \"purchase_order_number\": \"value-001\", \"date\": \"2026-05-17\", \"supplier_name\": \"Sample Name\", \"delivery_reference_number\": \"value-001\", \"total_liters\": 1, \"total_amount\": 1, \"created\": \"2026-06-29T10:53:22Z\", \"updated\": \"2026-06-29T10:53:22Z\", \"children\": {\"jef-fuel-pump-inventories-purchase-order-line-items\": [{\"purchase_order_line_item_id\": \"ed7b60d1-02f0-4689-a164-a6a35c96ba3c\", \"purchase_order_id\": \"c39a1319-2df5-45eb-a7cc-b8c23b44c74c\", \"gas_station_id\": \"9ccbe503-d431-47ec-b60e-bd0f886d5a6f\", \"line_number\": 1, \"pump_id\": \"c442b932-80ac-46c2-bf6c-f050543efbdd\", \"pump\": \"value-001\", \"product\": \"value-001\", \"liters\": 1, \"price_per_liter\": 1, \"total_amount\": 1, \"delivery_reference_number\": \"value-001\", \"notes\": \"value-001\", \"status\": \"value-001\", \"created\": \"2026-06-29T10:53:22Z\", \"updated\": \"2026-06-29T10:53:22Z\"}]}}"

PowerShell curl

curl.exe -X POST "https://fsqf5slhc1.execute-api.ap-southeast-1.amazonaws.com/prod/fuel-pump-inventories-purchase-orders-post-one" -H "Content-Type: application/json" --data-raw '{"purchase_order_id": "c39a1319-2df5-45eb-a7cc-b8c23b44c74c", "gas_station_id": "7cd83abd-1c94-42ba-8be4-8304c34bec6c", "purchase_order_number": "value-001", "date": "2026-05-17", "supplier_name": "Sample Name", "delivery_reference_number": "value-001", "total_liters": 1, "total_amount": 1, "created": "2026-06-29T10:53:22Z", "updated": "2026-06-29T10:53:22Z", "children": {"jef-fuel-pump-inventories-purchase-order-line-items": [{"purchase_order_line_item_id": "ed7b60d1-02f0-4689-a164-a6a35c96ba3c", "purchase_order_id": "c39a1319-2df5-45eb-a7cc-b8c23b44c74c", "gas_station_id": "9ccbe503-d431-47ec-b60e-bd0f886d5a6f", "line_number": 1, "pump_id": "c442b932-80ac-46c2-bf6c-f050543efbdd", "pump": "value-001", "product": "value-001", "liters": 1, "price_per_liter": 1, "total_amount": 1, "delivery_reference_number": "value-001", "notes": "value-001", "status": "value-001", "created": "2026-06-29T10:53:22Z", "updated": "2026-06-29T10:53:22Z"}]}}'