Install the package with Composer:
composer require biila-io/laravel-procountor-api
The package will automatically register itself.
You should add to services.php
config file the following configuration:
return [
// ...
'procountor' => [
'client_id' => env('PROCOUNTOR_CLIENT_ID'),
'client_secret' => env('PROCOUNTOR_CLIENT_SECRET'),
'redirect_uri' => env('PROCOUNTOR_REDIRECT_URI'),
'api_key' => env('PROCOUNTOR_API_KEY'),
],
]
Procountor::getConfig()
- Get the Procountor config instance.
Procountor::accessToken()
- Get the access token.
Procountor::accessTokenExpiresAt()
- Get the access token expiration time.
Procountor::refreshAccessToken()
- Refresh the access token.
Procountor::getAccountingCode()
- Get the accounting code defined in the config.
Procountor::getInvoices($query)
- Get a list of invoices.
Procountor::getInvoice($invoiceId)
- Get the details for given invoice id.
Procountor::storeInvoice($data)
- Store invoice to Procountor with given data.
Procountor::verifyInvoice($invoiceId)
- Verify a stored invoice in Procountor.
Procountor::approveInvoice($invoiceId)
- Approve a stored invoice in Procountor.
Procountor::invalidateInvoice($invoiceId)
- Invalidate a stored invoice in Procountor.
Procountor::getAttachments($query)
- Get a list of attachments.
Procountor::getAttachment($attachmentId)
- Get details of given attachment id.
Procountor::uploadAttachment($filePath, $referenceId, $disk, $filename)
- Upload an attachment to Procountor.
Convenient Laravel Commands is open-sourced software licensed under the MIT license.