Next
Technical | Power Query - Example 
This glossary outlines all of the available input for creating a Transaction with the CreateTransaction mutation
| Field Name | Type | Description | 
|---|---|---|
| id | Guid | Unique identifier for the Transaction, can be used to find the created Transaction later. | 
| sendingDate | Date | Typically the date on which the sender creates the Transaction. | 
| productId | Guid | Unique identifier of the product. | 
| senderLocationId | Guid | Unique identifier of the sender location. | 
| receiverLocationId | Guid | Unique identifier of the receiver location. | 
| quantity | Int | Whole number of product items involved in the Transaction. | 
| Field Name | Type | Description | 
|---|---|---|
| accountId | Guid | Unique identifier of the account, For any Transaction involving a site location, ie. most Transactions, the account is determined automatically from the product supplier and site location. An error will be raised when not given and could not be found. | 
| alterationReference | String | Used to associate an 'altered' Transaction with subsequent 'alteration' Transactions. Can be any value. | 
| carrier | String | Text field describing company or person that is transporting pallets. | 
| carrierReference | String | Typically a consignment number. Copied to ReceiverReference for 'off' Transactions and to SenderReference for 'on' Transactions. | 
| docketNumber | String | Main reference value for the Transaction, Typically 11 digits, is generated for the Transaction and not copied from a related job or order in some other system. | 
| driverContactId | Guid | Unique Identifier of the Contact representing the driver that handled the delivery of the products. | 
| effectiveDate | Date | Date from which the receiver incurs supplier rental changes. Ignored for non-transfer kinds. Calculated if missing for transfer kinds. | 
| fee | Decimal | May be keyed but typically set to Quantity * FeeUnitPrice. | 
| feeCode | String | The code for the fee. | 
| feeUnitPrice | Decimal | Monetary value charged by supplier. | 
| filingDate | Date | For managing document storage - date on which a paper docket is keyed. | 
| isExported | Boolean | Indicates that the Transactions has been exported. | 
| internalReference | String | Free text field but typically set to the Guid of a corresponding record in a transport or warehouse management system. | 
| isDocketNumberGenerated | Boolean | When set to true, the docket number field will be automatically generated according to the account settings of the account. | 
| isManagedRecovery | Boolean | 'MR' system is used by CHEP in the UK. | 
| isComplete | Boolean | Defaults to true when not specified. May be set to false to indicate more information is required to complete the Transaction. Incomplete transfers are not exported to the supplier. | 
| isCancelled | Boolean | Cancelled Transaction become 'information only'. Cancelling is typically preferred over deleting to keep a historical record. | 
| isChecked | Boolean | Optionally initialised to false and then changed to true when Transactions are 'checked', i.e. compared to other Transactions for detecting duplicates, missing data, or other problems. | 
| kind | TransactionKind | Describes what kind of Transaction this record is. automatically added from sender/receiver location and account if not given. | 
| notes | String | Free text field. | 
| privateNotes | String | Free text field that is not submitted to the receiver or printed on a docket. | 
| receiptNumber | String | 6-digit number that is generated for 'on' Transactions in the receiver's database. It is a checksum of the key fields in a Transaction. It is copied or keyed into the corresponding 'off' Transaction in the sender's database to provide proof-of-delivery, i.e. it replaces a signature on paper. | 
| receiverContactId | Guid | Unique Identifier of the Contact representing the receiver location that accepted the products. | 
| receivingDate | Date | Date on which the receiver takes possession of the products. Calculated if missing from the sending date and route transit days. | 
| receivedQuantity | Int | Sent & received quantities provide additional information but are ignored if inconsistent with either the net quantity or the sender & receiver. Absolute values are taken, i.e. negatives are converted to positives. | 
| receiverReference | String | Reference value that is required by the receiver. | 
| receiverTraceQuantity | Int | Indicates the end of the Transaction is traced. Defaults to a copy of the Quantity when tracing. | 
| senderContactId | Guid | Unique Identifier of the Contact representing the sender location that handed over possession of the products. | 
| senderReference | String | Reference value that is helpful for the sender. | 
| senderTraceQuantity | Int | Indicates the start of the Transaction is traced. Defaults to a copy of the Quantity when tracing. | 
| sentQuantity | Int | Sent & received quantities provide additional information but are ignored if inconsistent with either the net quantity or the sender & receiver. Absolute values are taken, i.e. negatives are converted to positives. | 
| source | String | ... | 
| supplierReference | String | Additional reference field for supplier. | 
| submittedTimestamp | DateTime | ... | 
| confirmedTimestamp | DateTime | ... | 
| receivedTimestamp | DateTime | ... | 
Older Versions of the 2ic Postman Example 2ic-postman-collection.postman_collection.zip and the 2ic Pallets Example for Altair 2ic-altair-collection.zip may include deprecated or deleted fields, download the latest version to avoid these errors.
This glossary outlines all of the possible errors when creating a Transaction with the CreateTransaction mutation
| Kind | Message | Reason | Fix | 
|---|---|---|---|
| Error | You are not authorized to run this query.\nDatabase cannot be found. | Database Id not set correctly | See Access for Developers | 
| Error | You are not authorized to run this query.\nUser record cannot be found. | Authorisation (bearer token) not set correctly | See Access for Developers | 
| Error | Unrecognized input fields 'FIELD' for type CreateTransactionInput | Incorrect fields in the CreateTransactionInput fields | Remove/replace incorrect fields | 
| Error | Id not found, targets (location/product/account) | Incorrect id input given to CreateTransactionInput | Check correct id given | 
| Error | Violation of PRIMARY KEY constraint 'PK_Transactions' | Duplicated transactions with the same id | Either generate a unique Guid or key one | 
| Warning | Missing docket number | No docket number given in CreateTransactionInput | Add docket number or IsDocketNumberGenerated = true to the inputs | 
| Warning | Duplicate docket number | Duplicate docket number given in CreateTransactionInput | Edit/generate docket number in inputs | 
| Warning | Docket number too long | Given docket number too long | Amend docket number | 
| Error | Account Supplier Does Not Match Product Supplier | Given account's supplier doesn't match given product's supplier | Review and change Product/Account | 
| Error | Site location not linked to account | Given location (site) isn't linked to an account | Review and change location (site) | 
| Error | EntityNotFoundForField account | Account is missing and could not be found | Add the account id field to the input, or edit the sender/receiver location to include a site | 
| Error | Duplicate Sender/Receiver reference | Matching Transaction within 90 days with matching product, kind and sender/receiver reference | Review matching Transaction and amend | 
| Warning | Disallowed Product | Product given in input is disallowed | Review and change product | 
| Warning | Disallowed Transaction kind | Transaction kind is not allowed on trading account | Review and change or add kind to the inputs | 
| Error | Account Setting Required | Specified Account setting is missing, these are required when generating a docket number with the IsDocketNumberGenerated input | Update account settings within the 2ic app or with the UpdateAccountSetting endpoint | 
| Warning | All Docket Numbers Running out in days | Time Based docket number will no longer be able to generated in the specified amount of days | Update account settings within the 2ic app or with the UpdateAccountSetting endpoint | 
| Error | Trading Partner to different Trading Partner Transaction not allowed | Created Transaction is between two Trading Partner Locations | Amend the sender/receiver locationId of the CreateTransactionInput | 
| Error | Cannot query field "FIELD" on type "TYPE" | Query input has deleted fields present | Remove/replace incorrect fields |