Getting Proforma Invoice List
Function: proforma_invoice_list()
Purpose
This SDK function retrieves a paginated list of proforma invoices from the system. It is useful when you want to fetch all proforma invoices for reporting, billing workflows, dashboard display, financial calculation, or to select a specific invoice for further operations such as viewing, editing, or converting to a final invoice. This endpoint returns invoice metadata including invoice status, payment status, total amounts, and due dates.
Parameters
| parameter | type | description |
|---|---|---|
| limit | integer | Optional. Number of records to return per request. SDK uses default value if not provided. |
| offset | integer | Optional. Number of records to skip before starting to return records. Used for pagination. |
Use Case
This function is typically used when a system needs to show a complete list of proforma invoices in a financial dashboard, accounting module, or administrative panel. A QA, developer, or integrator may call this function to validate invoice values, check calculation logic, or verify invoice status transitions. In standard workflows, the list endpoint is used to retrieve invoices before selecting a specific invoice for detailed inspection. Both Python and PHP SDKs provide simple wrapper methods, allowing you to call the endpoint without manually handling authentication or low-level HTTP implementations. The example below demonstrates how the function is executed using placeholder values.
def proforma_invoice_list():
SDKConfig.PRINT_REQUEST_DATA = True
SDKConfig.PRINT_RAW_RESPONSE = False
token_file_path = "shared_token.json"
file_token_mgr = FileTokenManager(token_file_path)
exsited_sdk: ExsitedSDK = ExsitedSDK().init_sdk(
request_token_dto=CommonData.get_request_token_dto(),
file_token_mgr=file_token_mgr
)
try:
response = exsited_sdk.proforma_invoice.proforma_invoice_list()
print(response)
except ABException as ab:
print(ab)
print(ab.get_errors())
print(ab.raw_response)
Response
The response contains a list of proforma invoices with attributes such as status, uuid, invoiceId, financial totals, payment status, issue date, and due date. It also includes pagination information to allow navigation through larger datasets. Each invoice is returned in a structured DTO format. Below is a placeholder-based representation of how both SDKs output the results.
ProformaInvoiceListDTO(
proformaInvoices=[
ProformaInvoiceDTO(
status='STATUS_PLACEHOLDER',
uuid='PROFORMA_INVOICE_UUID_1',
invoiceId='INVOICE_ID_1',
operationAcceptanceRequired='BOOLEAN_PLACEHOLDER',
operationAcceptancePaymentRequired='BOOLEAN_PLACEHOLDER',
operationAcceptanceDateSelector='DATE_SELECTOR_PLACEHOLDER',
operationAcceptanceTermsAndConditions='TERMS_PLACEHOLDER',
totalAmount='TOTAL_AMOUNT_1',
dueAmount='DUE_AMOUNT_1',
paidAmount='PAID_AMOUNT_1',
invoiceStatus='INVOICE_STATUS_1',
paymentStatus='PAYMENT_STATUS_1',
issueDate='ISSUE_DATE_1',
dueDate='DUE_DATE_1'
),
ProformaInvoiceDTO(
status='STATUS_PLACEHOLDER',
uuid='PROFORMA_INVOICE_UUID_2',
invoiceId='INVOICE_ID_2',
operationAcceptanceRequired='BOOLEAN_PLACEHOLDER',
operationAcceptancePaymentRequired='BOOLEAN_PLACEHOLDER',
operationAcceptanceDateSelector='DATE_SELECTOR_PLACEHOLDER',
operationAcceptanceTermsAndConditions='TERMS_PLACEHOLDER',
totalAmount='TOTAL_AMOUNT_2',
dueAmount='DUE_AMOUNT_2',
paidAmount='PAID_AMOUNT_2',
invoiceStatus='INVOICE_STATUS_2',
paymentStatus='PAYMENT_STATUS_2',
issueDate='ISSUE_DATE_2',
dueDate='DUE_DATE_2'
)
],
pagination=PaginationDTO(
records=TOTAL_RECORDS_PLACEHOLDER,
limit=LIMIT_PLACEHOLDER,
offset=OFFSET_PLACEHOLDER,
previousPage='PREVIOUS_PAGE_LINK_PLACEHOLDER',
nextPage='NEXT_PAGE_LINK_PLACEHOLDER'
)
)
Getting Proforma Invoice Details
Function: proforma_invoice_details()
Purpose
This SDK function retrieves the complete details of a specific proforma invoice using its invoice ID. It is used when a system needs to display full invoice information on detail screens, validate invoice amounts during QA testing, verify acceptance conditions, check statuses before conversion to a final invoice, or use invoice data for finance-related processing. This endpoint returns all relevant fields for a single proforma invoice in a structured format.
Parameters
| parameter | type | description |
|---|---|---|
| proforma_invoice_id | string | Required. The proforma invoice ID to retrieve details for. This must match the invoiceId value of an existing proforma invoice. |
Use Case
This function is generally used whenever a user selects a specific proforma invoice from a list to view its full details. QA engineers use this endpoint to validate financial accuracy, date correctness, status values, and acceptance rules for a given invoice. Developers commonly use it to populate invoice detail views, trigger workflows based on invoice attributes, or verify that the invoice is eligible for subsequent actions such as acceptance, approval, or conversion. The SDK abstracts authentication and request handling, allowing you to simply pass the invoice ID and retrieve all details. Below are the placeholder-based examples for Python and PHP implementations.
def proforma_invoice_details():
SDKConfig.PRINT_REQUEST_DATA = True
SDKConfig.PRINT_RAW_RESPONSE = False
token_file_path = "PATH_TO_TOKEN_FILE.json"
file_token_mgr = FileTokenManager(token_file_path)
exsited_sdk = ExsitedSDK().init_sdk(
request_token_dto=CommonData.get_request_token_dto(),
file_token_mgr=file_token_mgr
)
response = exsited_sdk.proforma_invoice.proforma_invoice_details(
id="PROFORMA_INVOICE_ID_PLACEHOLDER"
)
print(response)
Response
The response returns a structured object containing the full details of the requested proforma invoice. The returned data includes the invoice UUID, invoiceId, financial totals, acceptance settings, status values, issue and due dates. This output is used to display detailed information or to support logic such as validating whether an invoice can be accepted or processed further. Below is a placeholder-based response example for both Python and PHP SDKs.
ProformaInvoiceDetailsDTO(
proformaInvoice=ProformaInvoiceDTO(
status='STATUS_PLACEHOLDER',
uuid='PROFORMA_INVOICE_UUID_PLACEHOLDER',
invoiceId='PROFORMA_INVOICE_ID_PLACEHOLDER',
operationAcceptanceRequired='BOOLEAN_PLACEHOLDER',
operationAcceptancePaymentRequired='BOOLEAN_PLACEHOLDER',
operationAcceptanceDateSelector='DATE_SELECTOR_PLACEHOLDER',
operationAcceptanceTermsAndConditions='TERMS_PLACEHOLDER',
totalAmount='TOTAL_AMOUNT_PLACEHOLDER',
dueAmount='DUE_AMOUNT_PLACEHOLDER',
paidAmount='PAID_AMOUNT_PLACEHOLDER',
invoiceStatus='INVOICE_STATUS_PLACEHOLDER',
paymentStatus='PAYMENT_STATUS_PLACEHOLDER',
issueDate='ISSUE_DATE_PLACEHOLDER',
dueDate='DUE_DATE_PLACEHOLDER'
)
)
Creating Proforma Invoice Payment
Function: proforma_invoice_create()
Purpose
This endpoint allows recording a payment against a specific proforma invoice. It is typically used to track payments made by customers before a proforma invoice is converted into a final invoice. The API supports specifying the payment date, payment method, reference, applied amount, and additional notes. Using this endpoint ensures that financial records remain accurate and up-to-date, reflecting real-time payments applied to pending proforma invoices.
Parameters
| parameter | type | description |
|---|---|---|
| proforma_invoice_id | string | Required. The proforma invoice ID to which the payment will be applied. |
Use Case
Suppose a customer makes a partial or full payment against a proforma invoice. Using this endpoint, the system can programmatically record the payment and update the invoice's financial status. Both Python and PHP SDKs provide convenient methods to perform this action by passing the invoice ID and payment data in the request object. This is essential for financial reconciliation, reporting, and ensuring that due amounts are tracked accurately.
def proforma_invoice_create():
SDKConfig.PRINT_REQUEST_DATA = True
SDKConfig.PRINT_RAW_RESPONSE = False
token_file_path = "PATH_TO_TOKEN_FILE.json"
file_token_mgr = FileTokenManager(token_file_path)
exsited_sdk = ExsitedSDK().init_sdk(
request_token_dto=CommonData.get_request_token_dto(),
file_token_mgr=file_token_mgr
)
request_data = PaymentCreateDTO(
payment=PaymentDataDTO(
date='PAYMENT_DATE_PLACEHOLDER',
note='NOTE_PLACEHOLDER',
paymentNote='PAYMENT_NOTE_PLACEHOLDER',
paymentApplied=[PaymentAppliedDTO(
processor='PAYMENT_PROCESSOR_PLACEHOLDER',
amount='AMOUNT_PLACEHOLDER',
reference='REFERENCE_PLACEHOLDER'
)]
)
)
response = exsited_sdk.proforma_invoice.proforma_invoice_create(
id='PROFORMA_INVOICE_ID_PLACEHOLDER',
request_data=request_data
)
print(response)
Response
The response confirms that the payment was successfully recorded against the specified proforma invoice. In this case, the proformaInvoice object may be null if the system does not return full invoice details immediately after creating the payment. Applications can use this response to confirm success and update internal records accordingly.
ProformaInvoiceDetailsDTO(
proformaInvoice=None
)