Path: api/v1/rtv
This API is JSON:API compliant.
This endpoint supports the following methods:
GET
This endpoint requires an OAuth bearer token, and returns errors in a standard shape. See API Conventions for authentication, error responses and paging, which apply to every endpoint.
The resource type for this endpoint is RTV
The identifier is rtvno
Relationships
A relationship links this RTV to another resource. Includable relationships can be embedded via the include query parameter (see Includes below). Patchable relationships can be changed via PATCH.
| Relationship | Type | Returns | Includable | Patchable |
|---|---|---|---|---|
| comments | RTVComment | array | ✓ | ✗ |
| from | CardFile | object | ✓ | ✗ |
| stock | RTVStock | array | ✓ | ✗ |
| vendor | CardFile | object | ✓ | ✗ |
Includes
Use the include query parameter to embed Includable relationships in a single response, for example:GET /api/v1/rtv/{rtvno}?include=vendor,from,stock,comments
Embedded resources are returned in a top-level included array, not nested inside the relationship. Match each one back to its relationship by type and id.
For example, requesting include=vendor returns the vendor reference under relationships and the full resource in the included array. The reference and the included entry share the same type and id:
GET /api/v1/rtv/{rtvno}?include=vendor
{
"data": {
"type": "RTV",
"id": "1001",
"relationships": {
"vendor": {
"data": { "type": "CardFile", "id": "2002" }
}
}
},
"included": [
{
"type": "CardFile",
"id": "2002",
"attributes": { ... }
}
]
}
Attributes
The RTV resource type attributes are as follows:
| Attribute | Type | Description |
|---|---|---|
| accFee | number | The account fee amount on the return. |
| accFeeTax | number | The account fee tax amount on the return. |
| accFeeTaxCode | string | The tax code applied to the account fee on the return. |
| branchCode | string | The branch code. Branches are optional in Jim2 - this is only set when your site is configured to use branches. |
| calcPricesFromTaxPaid | boolean | Whether prices are calculated from the tax-paid (tax-inclusive) amount. |
| companyCode | string | The company code. |
| credNoteNo | string | The credit note number for the return. |
| currencyCode | string | The currency code. |
| dateIn | string (DateTime in ISO format) | The date-in for the return to vendor. |
| dateOut | string (DateTime in ISO format) | The date-out for the return to vendor. |
| exchangeRate | number | The currency exchange rate applied to the return. |
| freight | number | The freight amount on the return. |
| freightTax | number | The freight tax amount on the return. |
| freightTaxAdj | Nullable`1 | The freight tax adjustment on the return. |
| freightTaxCode | string | The tax code applied to freight on the return. |
| glDeptCode | string | The GL department code. GL departments are optional in Jim2 - this is only set when your site is configured to use GL departments. |
| notes | string | Notes on the return. |
| objectMode | integer | The object mode of the return. |
| poNo | integer | The purchase order number this return to vendor relates to. |
| raNumber | string | The return-authorisation number. |
| status | string | The return-to-vendor's current status. |
| subBranchCode | string | The sub-branch code. Sub-branches are optional in Jim2 - this is only set when your site is configured to use sub-branches. |
| taxAdj | Nullable`1 | The tax adjustment on the return. |
Path: api/v1/rtv/10?include=vendor,from,stock,comments Response: This example shows the maximum set of fields the endpoint can return, all populated. A real response only contains the data that applies to that record, so fields that are empty or not relevant are omitted — do not assume every field shown here will be present in every response.
Example GET (Return specific)
{
"data": {
"attributes": {
"accFee": 12.0,
"accFeeTax": 1.2,
"accFeeTaxCode": "G",
"branchCode": "SYD",
"calcPricesFromTaxPaid": false,
"companyCode": "P.COMPANY2",
"credNoteNo": "CN-2025-0042",
"currencyCode": "AUD",
"dateIn": "2025-11-24T09:15:00",
"dateOut": "2025-11-26T14:30:00",
"exchangeRate": 1.0,
"freight": 33.0,
"freightTax": 3.3,
"freightTaxAdj": 0,
"freightTaxCode": "G",
"glDeptCode": "1",
"notes": "Faulty units returned to vendor for credit.",
"objectMode": 0,
"poNo": 30,
"raNumber": "RA-778812",
"status": "Booked",
"subBranchCode": "SALE",
"taxAdj": 0
},
"id": "10",
"links": {
"self": "/api/v1/rtv/10"
},
"relationships": {
"comments": {
"data": [
{
"id": "10-1",
"type": "RTVComment"
}
]
},
"from": {
"data": {
"id": "16",
"type": "CardFile"
}
},
"stock": {
"data": [
{
"id": "10-1",
"type": "RTVStock"
}
]
},
"vendor": {
"data": {
"id": "15",
"type": "CardFile"
}
}
},
"type": "RTV"
},
"included": [
{
"attributes": {
"aBN": "53004085616",
"aCN": "004085616",
"address": {
"country": "Australia",
"isAddressResidential": false,
"postCode": "2000",
"state": "NSW",
"streetAddress": "12 Vendor Street",
"suburb": "Sydney"
},
"branchCode": "SYD",
"cardCode": "VENDORCO",
"cardNo": 15,
"contact": "Bill Vendor",
"customer": {
"accFeePerc": 2.5,
"backorder": "Allow Backorders",
"batchInvGroupBy": "Customer",
"bPayRefNo": "123456789",
"creditHold": "OFF( Auto )",
"creditLimit": 50000.0,
"currencyCode": "AUD",
"custPONo": "PO-STANDING-15",
"priceLevel": "Wholesale",
"requiredDays": 30,
"requiredHours": 0,
"sendInvVia": "Email",
"sendStatementVia": "Email",
"taxExclCode": "E",
"taxInclCode": "G",
"taxPaid": true,
"terms": "30D",
"groups": [
{
"id": 3,
"name": "Preferred Vendors",
"type": "Non Report",
"level": null
}
]
},
"groups": [
{
"id": 3,
"name": "Preferred Vendors",
"type": "Non Report",
"level": null
}
],
"delAddress": {
"country": "Australia",
"isAddressResidential": false,
"postCode": "2000",
"state": "NSW",
"streetAddress": "12 Vendor Street",
"suburb": "Sydney"
},
"gLDeptCode": "1",
"name": "Vendor Co Pty Ltd",
"shipAmount": 15.0,
"shipVia": "Courier",
"subBranchCode": "SALE"
},
"id": "15",
"relationships": {
"accountManager": {
"data": {
"id": "2",
"type": "CardFile"
}
},
"contacts": {
"data": [
{
"id": "15-1",
"type": "CardFileContact"
}
]
},
"parent": {
"data": {
"id": "14",
"type": "CardFile"
}
}
},
"type": "CardFile"
},
{
"attributes": {
"aBN": "45123456789",
"aCN": "123456789",
"address": {
"country": "Australia",
"isAddressResidential": false,
"postCode": "3000",
"state": "VIC",
"streetAddress": "8 Sender Road",
"suburb": "Melbourne"
},
"branchCode": "SYD",
"cardCode": "FROMCO",
"cardNo": 16,
"contact": "Fay From",
"customer": {
"accFeePerc": 0.0,
"backorder": "Allow Backorders",
"batchInvGroupBy": "Customer",
"bPayRefNo": "987654321",
"creditHold": "OFF( Auto )",
"creditLimit": 25000.0,
"currencyCode": "AUD",
"custPONo": "PO-STANDING-16",
"priceLevel": "Wholesale",
"requiredDays": 14,
"requiredHours": 0,
"sendInvVia": "Email",
"sendStatementVia": "Print",
"taxExclCode": "E",
"taxInclCode": "G",
"taxPaid": true,
"terms": "14D",
"groups": [
{
"id": 4,
"name": "Suppliers",
"type": "Non Report",
"level": null
}
]
},
"groups": [
{
"id": 4,
"name": "Suppliers",
"type": "Non Report",
"level": null
}
],
"delAddress": {
"country": "Australia",
"isAddressResidential": false,
"postCode": "3000",
"state": "VIC",
"streetAddress": "8 Sender Road",
"suburb": "Melbourne"
},
"gLDeptCode": "1",
"name": "From Co Pty Ltd",
"shipAmount": 10.0,
"shipVia": "Courier",
"subBranchCode": "SALE"
},
"id": "16",
"relationships": {
"accountManager": {
"data": {
"id": "2",
"type": "CardFile"
}
},
"contacts": {
"data": [
{
"id": "16-1",
"type": "CardFileContact"
}
]
},
"parent": {
"data": {
"id": "14",
"type": "CardFile"
}
}
},
"type": "CardFile"
},
{
"id": "10-1",
"type": "RTVStock",
"attributes": {
"qtyRet": 2.0,
"qtyPicked": 2.0,
"unitPriceTF": 20.0,
"unitPriceTP": 22.0,
"poNo": 30,
"poLineId": 1,
"configNo": 4501,
"addinit": "API",
"adddate": "2025-11-24T09:15:00",
"stockId": 3,
"stockCode": "SAMSUNG.MON.CONNECT",
"unit": "EACH",
"description": "Samsung Monitor Connector.",
"modifyinit": "API",
"modifydate": "2025-11-24T09:15:00"
}
},
{
"id": "10-1",
"type": "RTVComment",
"attributes": {
"include": true,
"status": "Booked",
"comment": "Faulty units returned to vendor for credit.",
"modifyInit": "SYS",
"modifyDate": "2025-11-24T09:15:00+11:00"
}
}
]
}