User Story
- Able to get one particular purchase.
REST API
JSON Structure
[
{
"id": "string",
"createdAt": "2024-07-30T07:55:50.867Z",
"updatedAt": "2024-07-30T07:55:50.867Z",
"vendor": {
"id": "string",
"createdAt": "2024-07-30T07:55:50.867Z",
"updatedAt": "2024-07-30T07:55:50.867Z",
"name": "string",
"gstin": "string",
"address": "string",
"phone": "string",
"whatsapp": "string",
"alternatePhone": "string",
"representative": "string",
"notes": "string"
},
"items": [
{
"id": "string",
"createdAt": "2024-07-30T07:55:50.867Z",
"updatedAt": "2024-07-30T07:55:50.867Z",
"product": {
"id": "string",
"createdAt": "2024-07-30T07:55:50.867Z",
"updatedAt": "2024-07-30T07:55:50.867Z",
"name": "string",
"description": "string",
"brand": "string",
"model": "string",
"make": "string",
"quantity": 0,
"price": 0,
"costPrice": 0,
"unit": "string",
"hsnCode": "string",
"gstPercentage": 0,
"scanCode": "string",
"images": [
{
"id": "string",
"createdAt": "2024-07-30T07:55:50.867Z",
"updatedAt": "2024-07-30T07:55:50.867Z",
"name": "string",
"url": "string"
}
],
"categories": [
{
"id": "string",
"createdAt": "2024-07-30T07:55:50.867Z",
"updatedAt": "2024-07-30T07:55:50.867Z",
"name": "string",
"images": [
{
"id": "string",
"createdAt": "2024-07-30T07:55:50.867Z",
"updatedAt": "2024-07-30T07:55:50.867Z",
"name": "string",
"url": "string"
}
],
"products": ["string"]
}
]
},
"purchase": "string",
"quantity": 0,
"price": 0
}
],
"discount": 0,
"subTotal": 0,
"total": 0,
"isOnCredit": true,
"date": "2024-07-30T07:55:50.867Z",
"transactions": [
{
"id": "string",
"createdAt": "2024-07-30T07:55:50.868Z",
"updatedAt": "2024-07-30T07:55:50.868Z",
"paymentMode": "CASH",
"transaction": {
"id": "string",
"createdAt": "2024-07-30T07:55:50.868Z",
"updatedAt": "2024-07-30T07:55:50.868Z",
"description": "string",
"account": {
"id": "string",
"createdAt": "2024-07-30T07:55:50.868Z",
"updatedAt": "2024-07-30T07:55:50.868Z",
"name": "string",
"number": "string",
"bank": "string",
"branch": "string",
"openingBalance": 0,
"accountBalance": 0,
"openingBalanceDate": "2024-07-30T07:55:50.868Z",
"notes": "string",
"isDefault": true
},
"amount": 0,
"date": "2024-07-30T07:55:50.868Z",
"type": "DEBIT",
"category": {
"id": "string",
"createdAt": "2024-07-30T07:55:50.868Z",
"updatedAt": "2024-07-30T07:55:50.868Z",
"name": "string",
"description": "string"
},
"notes": "string",
"isTransfer": true
},
"purchase": "string"
}
],
"notes": "string"
}
]