iVendNextDevelopers Request a sandbox

Purchase Receipt

Goods received from a supplier, which puts them into stock.

Area: Purchase and transfer documents · Why it is here: recipe expiry_recall; sample S22; sample S40; retail core · Fields: 95 · Submitted (booked) records: send docstatus: 1 to book it as you create it, or submit a draft with submit.

Read and write it

Every call runs as your app's own user, with its key in one header, at the retailer's own address. The user reads and writes only what its role allows: your app's user, and the rights the retailer gives it.

Read a list (only name unless you ask for fields):

curl -s "https://⟨site⟩/api/resource/Purchase%20Receipt?fields=%5B%22*%22%5D&limit_page_length=20" \
  -H "Authorization: token ⟨api key⟩:⟨api secret⟩"

Read one, with its tables:

curl -s "https://⟨site⟩/api/resource/Purchase%20Receipt/⟨name⟩" -H "Authorization: token ⟨api key⟩:⟨api secret⟩"

Create one (the required fields first), if your app's role may:

curl -s -X POST "https://⟨site⟩/api/resource/Purchase%20Receipt" -H "Authorization: token ⟨api key⟩:⟨api secret⟩" \
  -H "Content-Type: application/json" -d '{"naming_series": …, "supplier": …, "posting_date": …, "posting_time": …, "company": …, "currency": …}'

Change one with PUT /api/resource/Purchase%20Receipt/⟨name⟩ and the fields you change; a table sent there replaces its rows, so send its existing rows too. All the record calls and their answers: the API reference.

Samples that use it

s22_customer_loyalty · s40_expiry_recall · s41_regulated_register

Fields

Read from the product at POS 2.1.0.667 (till app 60147699c): its own fields, the fields iVendNext adds to it, and iVendNext's changes to any of them. Read-only fields are set by iVendNext; a hidden one is not on the form but can be read. Every record also has name (its id, in the address), owner, creation, modified, modified_by and docstatus (0 a draft, 1 submitted, 2 cancelled), all read-only.

Field Field name Type Required Read-only Hidden Links to
Title title Data yes
Series naming_series Select yes one of: MAT-PRE-.YYYY.-, MAT-PR-RET-.YYYY.-
Supplier supplier Link yes Supplier
Supplier Name supplier_name Data yes
Supplier Delivery Note supplier_delivery_note Data
Subcontracting Receipt subcontracting_receipt Link Subcontracting Receipt
Date posting_date Date yes
Posting Time posting_time Time yes
Edit Posting Date and Time set_posting_time Check
Company company Link yes Company
Apply Putaway Rule apply_putaway_rule Check
Is Return is_return Check yes
Return Against Purchase Receipt return_against Link yes Purchase Receipt
Cost Center cost_center Link Cost Center
Project project Link Project
Currency currency Link yes Currency
Exchange Rate conversion_rate Float yes
Price List buying_price_list Link Price List
Price List Currency price_list_currency Link yes Currency
Price List Exchange Rate plc_conversion_rate Float
Ignore Pricing Rule ignore_pricing_rule Check
Scan Barcode scan_barcode Data
Accepted Warehouse set_warehouse Link Warehouse
Set From Warehouse set_from_warehouse Link Warehouse
Rejected Warehouse rejected_warehouse Link Warehouse
Is Subcontracted is_subcontracted Check yes
Supplier Warehouse supplier_warehouse Link Warehouse
Items items Table yes Purchase Receipt Item
Total Quantity total_qty Float yes
Total Net Weight total_net_weight Float yes
Total (Company Currency) base_total Currency yes
Net Total (Company Currency) base_net_total Currency yes yes
Total total Currency yes
Net Total net_total Currency yes
Tax Withholding Net Total tax_withholding_net_total Currency yes yes
Base Tax Withholding Net Total base_tax_withholding_net_total Currency yes yes
Tax Category tax_category Link Tax Category
Purchase Taxes and Charges Template taxes_and_charges Link Purchase Taxes and Charges Template
Shipping Rule shipping_rule Link Shipping Rule
Incoterm incoterm Link Incoterm
Named Place named_place Data
Purchase Taxes and Charges taxes Table Purchase Taxes and Charges
Taxes and Charges Added (Company Currency) base_taxes_and_charges_added Currency yes
Taxes and Charges Deducted (Company Currency) base_taxes_and_charges_deducted Currency yes
Total Taxes and Charges (Company Currency) base_total_taxes_and_charges Currency yes
Taxes and Charges Added taxes_and_charges_added Currency yes
Taxes and Charges Deducted taxes_and_charges_deducted Currency yes
Total Taxes and Charges total_taxes_and_charges Currency yes
Grand Total (Company Currency) base_grand_total Currency yes
Rounding Adjustment (Company Currency) base_rounding_adjustment Currency yes
Rounded Total (Company Currency) base_rounded_total Currency yes
In Words (Company Currency) base_in_words Data yes
Grand Total grand_total Currency yes
Rounding Adjustment rounding_adjustment Currency yes
Rounded Total rounded_total Currency yes
In Words in_words Data yes
Disable Rounded Total disable_rounded_total Check
Apply Additional Discount On apply_discount_on Select one of: Grand Total, Net Total
Additional Discount Amount (Company Currency) base_discount_amount Currency yes
Additional Discount Percentage additional_discount_percentage Float
Additional Discount Amount discount_amount Currency
Taxes and Charges Calculation other_charges_calculation Text Editor yes
Pricing Rule Detail pricing_rules Table yes Pricing Rule Detail
Consumed Items supplied_items Table Purchase Receipt Item Supplied
Supplier Address supplier_address Link Address
Address address_display Small Text yes
Contact Person contact_person Link Contact
Contact contact_display Small Text yes
Mobile No contact_mobile Small Text yes
Contact Email contact_email Small Text yes
Shipping Address Template shipping_address Link Address
Shipping Address shipping_address_display Small Text yes
Billing Address billing_address Link Address
Billing Address billing_address_display Small Text yes
Terms tc_name Link Terms and Conditions
Terms and Conditions terms Text Editor
Status status Select yes yes one of: Draft, Partly Billed, To Bill, Completed, Return Issued, Cancelled, Closed
% Amount Billed per_billed Percent yes
% Returned per_returned Percent yes
Auto Repeat auto_repeat Link yes Auto Repeat
Letter Head letter_head Link Letter Head
Group same items group_same_items Check
Print Heading select_print_heading Link Print Heading
Print Language language Data yes
Transporter Name transporter_name Data
Vehicle Number lr_no Data
Vehicle Date lr_date Date
Instructions instructions Small Text
Is Internal Supplier is_internal_supplier Check yes
Represents Company represents_company Link yes Company
Inter Company Reference inter_company_reference Link yes Delivery Note
Remarks remarks Small Text
Range range Data yes
Amended From amended_from Link yes yes Purchase Receipt
Is Old Subcontracting Flow is_old_subcontracting_flow Check yes yes

Table: Pricing Rule Detail

The rows of pricing_rules. Each row also has idx (its place), parent, parentfield and parenttype.

Field Field name Type Required Read-only Hidden Links to
Pricing Rule pricing_rule Link yes Pricing Rule
Item Code item_code Data yes
Margin Type margin_type Data yes yes
Rate or Discount rate_or_discount Data yes yes
Child Docname child_docname Data yes yes
Rule Applied rule_applied Check yes

Table: Purchase Receipt Item

The rows of items. Each row also has idx (its place), parent, parentfield and parenttype.

Field Field name Type Required Read-only Hidden Links to
Barcode barcode Data
Has Item Scanned has_item_scanned Check yes
Item Code item_code Link yes Item
Product Bundle product_bundle Link yes Product Bundle
Supplier Part Number supplier_part_no Data yes yes
Item Name item_name Data yes
Description description Text Editor
Brand brand Link yes yes Brand
Item Group item_group Link yes Item Group
Image image Attach yes
Received Quantity received_qty Float yes yes
Accepted Quantity qty Float
Rejected Quantity rejected_qty Float
UOM uom Link yes UOM
Stock UOM stock_uom Link yes yes UOM
Conversion Factor conversion_factor Float yes
Retain Sample retain_sample Check yes
Sample Quantity sample_quantity Int
Received Qty in Stock UOM received_stock_qty Float yes
Accepted Qty in Stock UOM stock_qty Float yes
Returned Qty in Stock UOM returned_qty Float yes
Price List Rate price_list_rate Currency
Price List Rate (Company Currency) base_price_list_rate Currency yes
Margin Type margin_type Select one of: Percentage, Amount
Margin Rate or Amount margin_rate_or_amount Float
Rate With Margin rate_with_margin Currency yes
Discount on Price List Rate (%) discount_percentage Percent
Discount Amount discount_amount Currency
Rate With Margin (Company Currency) base_rate_with_margin Currency
Rate rate Currency
Amount amount Currency yes
Rate (Company Currency) base_rate Currency yes yes
Amount (Company Currency) base_amount Currency yes
Pricing Rules pricing_rules Small Text yes yes
Rate of Stock UOM stock_uom_rate Currency yes
Is Free Item is_free_item Check yes
Apply TDS apply_tds Check yes yes
Net Rate net_rate Currency yes
Net Amount net_amount Currency yes
Item Tax Template item_tax_template Link Item Tax Template
Net Rate (Company Currency) base_net_rate Currency yes
Net Amount (Company Currency) base_net_amount Currency yes
Valuation Rate valuation_rate Currency yes yes
Sales Incoming Rate sales_incoming_rate Currency yes
Item Tax Amount Included in Value item_tax_amount Currency yes yes
Raw Materials Supplied Cost rm_supp_cost Currency yes yes
Landed Cost Voucher Amount landed_cost_voucher_amount Currency yes
Rate Difference with Purchase Invoice rate_difference_with_purchase_invoice Currency yes
Billed Amt billed_amt Currency yes
Accepted Warehouse warehouse Link Warehouse
Rejected Warehouse rejected_warehouse Link Warehouse
From Warehouse from_warehouse Link yes Warehouse
Material Request material_request Link yes Material Request
Purchase Order purchase_order Link yes Purchase Order
Purchase Invoice purchase_invoice Link yes Purchase Invoice
Allow Zero Valuation Rate allow_zero_valuation_rate Check
Return Qty from Rejected Warehouse return_qty_from_rejected_warehouse Check yes
Is Fixed Asset is_fixed_asset Check yes yes
Asset Location asset_location Link Location
Asset Category asset_category Link yes Asset Category
Required By schedule_date Date yes
Quality Inspection quality_inspection Link Quality Inspection
Material Request Item material_request_item Data yes yes
Purchase Order Item purchase_order_item Data yes yes
Purchase Invoice Item purchase_invoice_item Data yes yes
Purchase Receipt Item purchase_receipt_item Data yes yes
Delivery Note Item delivery_note_item Data yes
Putaway Rule putaway_rule Link yes Putaway Rule
Serial and Batch Bundle serial_and_batch_bundle Link Serial and Batch Bundle
Has Serial Expiry (added by iVendNext) custom_has_serial_expiry Check yes
Total Tax (added by iVendNext) custom_total_tax Float yes
Tax Total Breakup (added by iVendNext) custom_tax_breakup Text yes
Use Serial No / Batch Fields use_serial_batch_fields Check
Rejected Serial and Batch Bundle rejected_serial_and_batch_bundle Link Serial and Batch Bundle
Serial No serial_no Text
Rejected Serial No rejected_serial_no Text
Batch No batch_no Link Batch
Include Exploded Items include_exploded_items Check yes
BOM bom Link yes BOM
Weight Per Unit weight_per_unit Float
Total Weight total_weight Float yes
Weight UOM weight_uom Link UOM
Manufacturer manufacturer Link Manufacturer
Manufacturer Part Number manufacturer_part_no Data
Expense Account expense_account Link Account
Item Tax Rate item_tax_rate Code yes yes
WIP Composite Asset wip_composite_asset Link Asset
Provisional Expense Account provisional_expense_account Link Account
Project project Link Project
Cost Center cost_center Link Cost Center
Page Break page_break Check
Sales Order sales_order Link yes Sales Order
Sales Order Item sales_order_item Data yes yes
Subcontracting Receipt Item subcontracting_receipt_item Data yes yes
Serial Expiry Date (added by iVendNext) custom_serial_expiry_date Date

Table: Purchase Receipt Item Supplied

The rows of supplied_items. Each row also has idx (its place), parent, parentfield and parenttype.

Field Field name Type Required Read-only Hidden Links to
Item Code main_item_code Link yes Item
Raw Material Item Code rm_item_code Link yes Item
Item Name item_name Data yes
BOM Detail No bom_detail_no Data yes yes
Description description Text Editor yes
Stock Uom stock_uom Link yes UOM
Conversion Factor conversion_factor Float yes yes
Reference Name reference_name Data yes yes
Rate rate Currency yes
Amount amount Currency yes
Available Qty For Consumption required_qty Float yes
Qty to Be Consumed consumed_qty Float yes
Current Stock current_stock Float yes
Batch No batch_no Link Batch
Serial No serial_no Text
Purchase Order purchase_order Link yes yes Purchase Order

Table: Purchase Taxes and Charges

The rows of taxes. Each row also has idx (its place), parent, parentfield and parenttype.

Field Field name Type Required Read-only Hidden Links to
Consider Tax or Charge for category Select yes one of: Valuation and Total, Valuation, Total
Add or Deduct add_deduct_tax Select yes one of: Add, Deduct
Type charge_type Select yes one of: Actual, On Net Total, On Previous Row Amount, On Previous Row Total, On Item Quantity
Reference Row # row_id Data
Is this Tax included in Basic Rate? included_in_print_rate Check
Considered In Paid Amount included_in_paid_amount Check
Account Head account_head Link yes Account
Description description Small Text yes
Is Tax Withholding Account is_tax_withholding_account Check yes
Tax Rate rate Float
Cost Center cost_center Link Cost Center
Account Currency account_currency Link yes Currency
Amount tax_amount Currency
Tax Amount After Discount Amount tax_amount_after_discount_amount Currency yes
Total total Currency yes
Amount (Company Currency) base_tax_amount Currency yes
Total (Company Currency) base_total Currency yes
Tax Amount After Discount Amount base_tax_amount_after_discount_amount Currency yes
Item Wise Tax Detail item_wise_tax_detail Code yes yes

All record types · What you can use

This record type in the kit