Financial Document endpoints
PHP 8.0 and later.
To install the bindings via Composer, add the following to composer.json
:
{
"repositories": [
{
"type": "vcs",
"url": "https://github.com/GIT_USER_ID/GIT_REPO_ID.git"
}
],
"require": {
"GIT_USER_ID/GIT_REPO_ID": "*@dev"
}
}
Then run composer install
Download the files and include autoload.php
:
<?php
require_once('/path/to/OpenAPIClient-php/vendor/autoload.php');
Please follow the installation procedure and then run the following:
<?php
require_once(__DIR__ . '/vendor/autoload.php');
try {
$token = ''; // API Token
$file = ''; //TODO change by a file
$document = FilePath::fromPath($file); // Any concrete class that implements _FileInterface_
$client = MindeeClientFactory::financialDocument(new Token($token));
$result = $client->parse($document);
echo $result->customerName()."\n";
echo $result->customerAddress()."\n";
} catch (Exception $e) {
echo 'Exception :', $e->getMessage(), PHP_EOL;
}
- Category
- Category1
- CustomerAddress
- CustomerAddress1
- CustomerCompanyRegistrationsInner
- CustomerCompanyRegistrationsInner1
- CustomerName
- CustomerName1
- DateOfIssue
- DateOfIssue1
- DocumentTypeBeta
- DueDate
- DueDate1
- ErrorPredictResponse
- ErrorPredictResponseApiRequest
- ErrorPredictResponseApiRequestError
- ImageOrientation
- InvoiceNumber
- InvoiceNumber1
- JSONPredict
- LineItemsInner
- LineItemsInner1
- Locale
- Locale1
- MindeeFinancialDocument1DocPrediction
- MindeeFinancialDocument1PagePrediction
- PurchaseTime
- PurchaseTime1
- ReferenceNumbersInner
- ReferenceNumbersInner1
- SubCategory
- SubCategory1
- SuccessPredictResponse
- SuccessPredictResponseApiRequest
- SuccessPredictResponseDocument
- SuccessPredictResponseDocumentInference
- SuccessPredictResponseDocumentInferencePagesInner
- SuccessPredictResponseDocumentInferenceProduct
- SupplierAddress
- SupplierAddress1
- SupplierCompanyRegistrationsInner
- SupplierCompanyRegistrationsInner1
- SupplierName
- SupplierName1
- SupplierPaymentDetailsInner
- SupplierPaymentDetailsInner1
- TaxesInner
- TaxesInner1
- TipAndGratuity
- TipAndGratuity1
- TotalAmountIncludingTaxesTipsFeesAndOtherCharges
- TotalAmountIncludingTaxesTipsFeesAndOtherCharges1
- TotalNetOfTaxesFeesAndDiscount
- TotalNetOfTaxesFeesAndDiscount1
- TotalTax
- TotalTax1
- Type: API key
- API key parameter name: Authorization
- Location: HTTP header
To run the tests, use:
composer install
vendor/bin/phpunit