pfProductFinancialTransactionResource
Description
Defines a financial transaction for a product. For example, a sale, purchase, or stocktake.
The pfProductFinancialTransactionResource schema inherits from pfFinancialTransactionType.
Properties
Name | Description | Required | Type |
---|---|---|---|
Product | Details of the product that is the subject of the transaction. | Yes | icarProductReferenceType |
Units | The units in which the transaction quantity is measured. UN/CEFACT units SHOULD be used where these are applicable. | No | string |
TransactionKind | Identifies the kind of transaction. | Yes | pfFinancialTransactionKindType |
AccrualDate | The accrual date of the transaction. | No | date-time |
CashDate | The cash date of the transaction. This date should be used to populate the eventDateTime. | No | date-time |
TransactionQuantity | The number of units (e.g. head, kilograms, litres) in the transaction. | No | Number |
TransactionValue | The total value of the transaction in the currency specified. | Yes | Number |
UnitValue | The value per unit of the transaction in the currency specified. | No | Number |
Currency | The currency of the transaction expressed using the ISO 4217 3-character code such as AUD, GBP, USD, NZD. | No | string |
Notes | Notes recorded for the transaction. | No | string |
ContactName | The name of the contact for the transaction. | No | string |
ExternalReference | The array of external references to the transaction. For example, the reference to the invoice. | No | Array of icarIdentifierType |
ResourceReference | Reference to an associated resource such as the matching inventory transaction record or livestock movement event. | No | icarResourceReferenceType |
Id | Unique identifier in the source system for this event. | No | string |
EventDateTime | RFC3339 UTC date and time (see https://ijmacd.github.io/rfc3339-iso8601/). | No | date-time |
TraitLabel | If the event represents a formal trait, identifies the recording system and trait. | No | icarIdentifierType |
Responsible | Use if an observation is manually recorded, or an event is carried out or authorised by a person. SHOULD be a person object. | No | string |
ContemporaryGroup | For manually recorded events, record any contemporary group code that would affect statistical analysis. | No | string |
Remark | A comment or remark field for additional user-specified information about the event. | No | string |
Self | Uniform resource identifier (URI) of the resource (rel=self). | No | string |
Meta | Meta-data for the resource. Mandatory if you wish to support synchronisation. | No | icarMetaDataType |
Location | Unique location scheme and identifier combination. | No | icarIdentifierType |
Examples
Example 1
{
"resourceType": "/financial/product-financial-transaction",
"dataPointKey": "sample-product-financial-transaction-1",
"id": "c607ca0f-f0f1-4293-9cbb-d52435d4b624",
"meta": {
"source": "com.figured.product.transaction",
"sourceId": "69c0c586-70ea-47dd-a1dc-885a1a6af39c",
"modified": "2023-07-23T10:33:00Z",
"created": "2023-07-23T10:33:00Z",
"creator": "com.figured"
},
"location": {
"scheme": "com.figured.farmcode",
"id": "0a0aa"
},
"eventDateTime": "2023-07-14T11:00:00Z",
"transactionKind": "Purchase",
"accrualDate": "2023-06-30T08:00:00Z",
"cashDate": "2023-07-14T11:00:00Z",
"transactionQuantity": 200,
"transactionValue": 568,
"unitValue": 2.84,
"currency": "NZD",
"resourceReference": {
"identifier": {
"scheme": "nz.co.xyzfuel.delivery",
"id": "FKZ-4729"
},
"reltype": "InventoryTransaction",
"href": "https://api.purefarming.com/data/inventory/inventory-transaction/d104dddc-9c57-4d47-bbc7-f84517007d9f"
},
"notes": "Farm delivery 91 octane petrol",
"contactName": "Sharon Thomas",
"externalReference": [
{
"scheme": "nz.co.xyzfuel.invoice",
"id": "23-FKZ-37"
}
],
"product": {
"identifier": {
"scheme": "nz.co.saturn",
"id": "KY123412341234"
},
"family": "Fuel",
"identifiers": [
{
"scheme": "nz.co.xyzfuel.product",
"id": "Bulk 91"
}
],
"name": "Petrol 91",
"gtin": "12345678901234",
"unspc": "151015"
},
"units": "LTR"
}