alcales/laravel-docuware

Docuware SDK Laravel

v0.0.1 2020-11-16 15:58 UTC

This package is auto-updated.

Last update: 2025-07-20 05:40:08 UTC


README

You can install the package via composer:

composer require alcales/laravel-docuware

The package will automatically register itself.

Optionally you can publish the config-file:

php artisan vendor:publish --provider="ALCales\Docuware\DocuwareServiceProvider" --tag="config"

Here's what that looks like:

return [

    'url_root' => env('DOCUWARE_URL'),

    'user' => env('DOCUWARE_USER'),

    'password' => env('DOCUWARE_PASSWORD'),

];

you can define the credentials in environment variables in the .env file

DOCUWARE_URL=
DOCUWARE_USER=
DOCUWARE_PASSWORD=

Usage

Initialize.

$docuware = new Docuware($urlHost, $user, $password);

// If the credentials are not defined in the constructor, the ones established in the environment variables of the `.env` file will be obtained.
$docuware = new Docuware();

Principal funtions

$documentListArray = $docuware->getDocumentsList('your_gabinet_id');

$downloadedSuccessfully = $docuware->downloadDocument('your_gabinet_id', 'your_document_id', 'your_storage_path');

$fields = [
    new DocuwareField('Name', 'Alejandro', 'String'),
    new DocuwareField('Ages', 28, 'Int'),
];

$updateSuccessfully = $docuware->updateIndexValues('your_gabinet_id', 'your_document_id', $fields);