Skip to content

Commit c5ae717

Browse files
committed
Update docs
1 parent 5dd744e commit c5ae717

File tree

7 files changed

+23
-21
lines changed

7 files changed

+23
-21
lines changed

pages/balance_updates/balance-update-object.json

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
"credit_amount": "-567.50",
1212
"description": "Invoice raised",
1313
"method": "auto",
14-
"method_display": "System Generated",
1514
"related_item": {
1615
"id": 54,
1716
"display_id": "INV-54",
@@ -38,6 +37,5 @@
3837
"role_type": "Client",
3938
"url": "https://secure.tutorcruncher.com/api/clients/42/"
4039
},
41-
"update_type": "invoice_creation",
42-
"update_type_display": "Invoice Creation"
40+
"update_type": "invoice_creation"
4341
}

pages/balance_updates/balance-update-object.yml

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,6 @@ attributes:
4242
name: method
4343
type: string
4444
description: The payment method used for the balance update. Options for this field are ['cash', 'cheque', 'credit_card', 'transferwise', 'debit_card', 'bank_transfer', 'direct_debit', 'bonus_credit', 'manual', 'voucher', 'correction'].
45-
-
46-
name: method_display
47-
type: string
48-
description: Human-readable display name for the payment method.
4945
-
5046
name: related_item
5147
type: object
@@ -77,10 +73,6 @@ attributes:
7773
name: update_type
7874
type: string
7975
description: The type of update being performed (e.g., "via_api", "manual").
80-
-
81-
name: update_type_display
82-
type: string
83-
description: Human-readable display name for the update type.
8476

8577
filters:
8678
-
@@ -99,3 +91,19 @@ filters:
9991
name: update_type
10092
type: string
10193
description: Filter by the Balance Updates update_type. Options for this field are ['proforma_invoice_paid', 'invoice_creation', 'invoice_payment', 'po_creation', 'po_payment', 'adjustment', 'refund', 'stripe_bank_transfer_refund', 'voucher', 'credit_note', 'debit_note', 'via_api', 'top_up', 'app_fee']'
94+
-
95+
name: credit_amount_gte
96+
type: decimal
97+
description: Filter by Balance Updates with a credit_amount greater than or equal to this value.
98+
-
99+
name: credit_amount_lte
100+
type: decimal
101+
description: Filter by Balance Updates with a credit_amount less than or equal to this value.
102+
-
103+
name: created_gte
104+
type: datetime
105+
description: Filter by Balance Updates created on or after this date and time.
106+
-
107+
name: created_lte
108+
type: datetime
109+
description: Filter by Balance Updates created on or before this date and time.

pages/balance_updates/create-a-balance-update.json

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,7 @@
1919
"credit_amount": "100.00",
2020
"description": "This is a test description about why the credit was added to this client",
2121
"method": "cash",
22-
"method_display": "Cash",
2322
"related_item": null,
24-
"update_type": "via_api",
25-
"update_type_display": "Via API"
23+
"update_type": "via_api"
2624
}
2725

pages/balance_updates/create-a-balance-update.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
### Creating a Balance Update
22

3-
Creating a Balance Update can be completed by simply supplying the `client`, `credit_amount` and `method` as the
3+
Creating a Balance Update can be completed by simply supplying the `role`, `credit_amount` and `method` as the
44
`description` and `send_receipt` fields are optional. The `credit_amount` field must always be a positive value,
55
however if the method is set to `"correction"` then `credit_amount` can be a negative value. If `send_receipt` is set
66
to `True` then the `Payment receipt` email will be sent to the client if the email definition is enabled.

pages/balance_updates/create-a-balance-update.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
headers = {'Authorization': 'token <API KEY>'}
44
data = {
5-
"client": 67,
5+
"role": 67,
66
"credit_amount": 100,
77
"method": "cash",
88
"description": "Client paid by cash.",

pages/balance_updates/get-a-balance-update.json

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
"credit_amount": "-567.50",
1212
"description": "Invoice raised",
1313
"method": "auto",
14-
"method_display": "System Generated",
1514
"related_item": {
1615
"id": 54,
1716
"display_id": "INV-54",
@@ -38,6 +37,5 @@
3837
"role_type": "Client",
3938
"url": "https://secure.tutorcruncher.com/api/clients/42/"
4039
},
41-
"update_type": "invoice_creation",
42-
"update_type_display": "Invoice Creation"
40+
"update_type": "invoice_creation"
4341
}

pages/balance_updates/list-all-balance-updates.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77
"id": 182,
88
"created": "2025-09-30T15:03:58.676657+01:00",
99
"credit_amount": "-567.50",
10-
"method_display": "System Generated",
10+
"method": "auto",
1111
"role": 42,
12-
"update_type_display": "Invoice Creation",
12+
"update_type": "invoice_creation",
1313
"url": "https://secure.tutorcruncher.com/api/balance-updates/182/"
1414
}
1515
]

0 commit comments

Comments
 (0)