PHPackages                             ermirshehaj/devpos - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. ermirshehaj/devpos

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

ermirshehaj/devpos
==================

This package will fiscalize your business

14JavaScript

Since Jul 1Pushed 2y ago1 watchersCompare

[ Source](https://github.com/ermiri/devpos)[ Packagist](https://packagist.org/packages/ermirshehaj/devpos)[ RSS](/packages/ermirshehaj-devpos/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

DevPos
======

[](#devpos)

This is a package to help you connect with Devpos services such as invoicing,stock management, reports and the main goal to fiscalize invoices against state taxes rules.

Later we will put here all neccessary documentation for using this package.

This package contain a facade named `DevPos` which you can use to perform different actions on any model the system has. Anyway we have included a full project containing routes, views, controllers and anything needed to run the package on your custom laravel project. It will not work 100% bc the views are builded on my custom laravel project, therefore you have to do some editions on blade files.

Please check the documentation for additional informations https://github.com/ermiri/devpos/wiki

Installation
------------

[](#installation)

```
composer require ermirshehaj/devpos

```

It will install the package and you are ready to use it:

```
use ErmirShehaj\DevPos\Facades\DevPos;

//list all tcr
DevPos::tcr()->list();

```

Configuration
-------------

[](#configuration)

It come with a configuration file named `devpos.php`. There you can edit authentication parameters, cache settings and much more:

```
'endPointBase' => 'https://devpos.al',
'tokenEndPoint' => 'https://devpos.al/token',

//devpos login credentials
'tenant' => '0000000001',
'authorization' => 'Basic Zml5j3jsljfs893BhOg==',
'username' => 'admini',
'password' => 'demo@devpos',
'grant_type' => 'password',

```

Authentication
--------------

[](#authentication)

First you have to authenticate yourself into the devpos system which in return will give you an access token needed to run each request againsts their api.

```
use ErmirShehaj\DevPos\Facades\DevPos;

//to authorize using information on `devpos.php` just run:
DevPos::authorize();

//if you need to set manually some parameters:
DevPos::setTenant($tenant) //if you want another tenant than one set on devpos.php config file
        ->setAuthorization($authorization) //if you want a custom
        ->setAuthorization($authorization)//if you want a custom
        ->setUsername($username)//if you want a custom
        ->setPassword($password)//if you want a custom
        ->setGrantType($grant)//if you want a custom
            ->authorize();

```

The method `authorize()` just run a request and if everything is ok it will save the access\_token on session under the key `devpos.access_token`

Models
------

[](#models)

All models are inside `devpos/src/Classes` folder. They act as model but are not the same as laravel model.They have standart methods like:

```
- list //get models
- create //create model
- update //update model
- destroy //delete model

```

Check the wiki page for more details

Routes
------

[](#routes)

You can see/edit routes located at `devpos/route/web.php`.

Controllers
-----------

[](#controllers)

For each model, we have created a controller.

Cache
-----

[](#cache)

We tend to cache every get request(list action on models), except invoices. By default, specified on `devpos.php` config file, it will expire after 1800 seconds.

```
use ErmirShehaj\DevPos\Facades\DevPos;

//to cache a request
DevPos::tcr()->cache()->list() //same as DevPos::tcr()->setCache(true)->list()

//to prevent caching
DevPos::tcr()->setCache(false)->list()

//to bypass caching data bc as default it will read cache first if it exists.
DevPos::tcr()->byPassCache()->list()

//set prefix. To avoid global pollution of cache, we use prefix, default: devpos.
DevPos::tcr()->setCachePrefix('devpos')->list();

//set cache key. It will be saved on cache as: prefix + '.' + key
DevPos::tcr()->setCacheKey('tcrs')->list();

//to get the full cache key: prefix + '.'+ key
$obj->getCacheKeyWithPrefix();

//set timeout
DevPos::tcr()->setCacheTimeout(500)->list();

```

###  Health Score

14

—

LowBetter than 2% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity22

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/98a677cf9f03b06c890523ed57bf5b31edc9d59890da0f3fa47c277a11b95ded?d=identicon)[ermiri](/maintainers/ermiri)

---

Top Contributors

[![ermiri](https://avatars.githubusercontent.com/u/5099870?v=4)](https://github.com/ermiri "ermiri (10 commits)")

### Embed Badge

![Health badge](/badges/ermirshehaj-devpos/health.svg)

```
[![Health](https://phpackages.com/badges/ermirshehaj-devpos/health.svg)](https://phpackages.com/packages/ermirshehaj-devpos)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
