Invoice Items
Operations Summary
Core CRUD
List Invoice Items
| http \
GET \
https://api.example.com/api/invoice-items/ \
Authorization:"Token YOUR_API_TOKEN"
|
| from waldur_api_client.client import AuthenticatedClient
from waldur_api_client.api.invoice_items import invoice_items_list # (1)
client = AuthenticatedClient(
base_url="https://api.example.com", token="YOUR_API_TOKEN"
)
response = invoice_items_list.sync(client=client)
for item in response:
print(item)
|
- API Source:
invoice_items_list
| import { invoiceItemsList } from 'waldur-js-client';
try {
const response = await invoiceItemsList({
auth: "Token YOUR_API_TOKEN"
});
console.log('Success:', response);
} catch (error) {
console.error('Error:', error);
}
|
| Name |
Type |
Description |
credit_uuid |
string (uuid) |
|
customer_uuid |
string (uuid) |
|
month |
integer |
|
offering_uuid |
string (uuid) |
|
page |
integer |
A page number within the paginated result set. |
page_size |
integer |
Number of results to return per page. |
project_uuid |
string (uuid) |
|
resource_uuid |
string (uuid) |
|
start_month |
number |
Start month |
start_year |
number |
Start year |
year |
integer |
|
200 -
The response body is an array of objects, where each object has the following structure:
| Field |
Type |
Description |
invoice |
string (uri) |
|
resource |
string (uri) |
|
uuid |
string (uuid) |
|
article_code |
string |
|
unit_price |
string (decimal) |
|
unit |
string |
Enum: month, quarter, half_month, day, hour, quantity |
quantity |
string (decimal) |
|
measured_unit |
string |
Unit of measurement, for example, GB. |
name |
string |
|
start |
string (date-time) |
Date and time when item usage has started. |
end |
string (date-time) |
Date and time when item usage has ended. |
details |
any |
Stores data about scope |
Retrieve
| http \
GET \
https://api.example.com/api/invoice-items/a1b2c3d4-e5f6-7890-abcd-ef1234567890/ \
Authorization:"Token YOUR_API_TOKEN"
|
1
2
3
4
5
6
7
8
9
10
11
12 | from waldur_api_client.client import AuthenticatedClient
from waldur_api_client.api.invoice_items import invoice_items_retrieve # (1)
client = AuthenticatedClient(
base_url="https://api.example.com", token="YOUR_API_TOKEN"
)
response = invoice_items_retrieve.sync(
uuid="a1b2c3d4-e5f6-7890-abcd-ef1234567890",
client=client
)
print(response)
|
- API Source:
invoice_items_retrieve
1
2
3
4
5
6
7
8
9
10
11
12
13 | import { invoiceItemsRetrieve } from 'waldur-js-client';
try {
const response = await invoiceItemsRetrieve({
auth: "Token YOUR_API_TOKEN",
path: {
"uuid": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
}
});
console.log('Success:', response);
} catch (error) {
console.error('Error:', error);
}
|
| Name |
Type |
Required |
uuid |
string (uuid) |
✓ |
200 -
| Field |
Type |
Description |
invoice |
string (uri) |
|
resource |
string (uri) |
|
uuid |
string (uuid) |
|
article_code |
string |
|
unit_price |
string (decimal) |
|
unit |
string |
Enum: month, quarter, half_month, day, hour, quantity |
quantity |
string (decimal) |
|
measured_unit |
string |
Unit of measurement, for example, GB. |
name |
string |
|
start |
string (date-time) |
Date and time when item usage has started. |
end |
string (date-time) |
Date and time when item usage has ended. |
details |
any |
Stores data about scope |
Create compensation invoice item for selected invoice item
Create compensation invoice item for selected invoice item.
Update
Partial Update
Delete
Other Actions
Consumptions
| http \
GET \
https://api.example.com/api/invoice-items/a1b2c3d4-e5f6-7890-abcd-ef1234567890/consumptions/ \
Authorization:"Token YOUR_API_TOKEN"
|
1
2
3
4
5
6
7
8
9
10
11
12 | from waldur_api_client.client import AuthenticatedClient
from waldur_api_client.api.invoice_items import invoice_items_consumptions_retrieve # (1)
client = AuthenticatedClient(
base_url="https://api.example.com", token="YOUR_API_TOKEN"
)
response = invoice_items_consumptions_retrieve.sync(
uuid="a1b2c3d4-e5f6-7890-abcd-ef1234567890",
client=client
)
print(response)
|
- API Source:
invoice_items_consumptions_retrieve
1
2
3
4
5
6
7
8
9
10
11
12
13 | import { invoiceItemsConsumptionsRetrieve } from 'waldur-js-client';
try {
const response = await invoiceItemsConsumptionsRetrieve({
auth: "Token YOUR_API_TOKEN",
path: {
"uuid": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
}
});
console.log('Success:', response);
} catch (error) {
console.error('Error:', error);
}
|
| Name |
Type |
Required |
uuid |
string (uuid) |
✓ |
200 -
| Field |
Type |
Description |
invoice |
string (uri) |
|
resource |
string (uri) |
|
uuid |
string (uuid) |
|
article_code |
string |
|
unit_price |
string (decimal) |
|
unit |
string |
Enum: month, quarter, half_month, day, hour, quantity |
quantity |
string (decimal) |
|
measured_unit |
string |
Unit of measurement, for example, GB. |
name |
string |
|
start |
string (date-time) |
Date and time when item usage has started. |
end |
string (date-time) |
Date and time when item usage has ended. |
details |
any |
Stores data about scope |
Get costs breakdown for a project by year and month
Get costs breakdown for a project by year and month.
Customer costs for period
Get resource cost breakdown for a project over a specified period
Get resource cost breakdown for a project over a specified period.
Calculate total price for filtered invoice items
Calculate total price for filtered invoice items.
Move invoice item from one invoice to another one
Move invoice item from one invoice to another one.