fature.al eshte platforma e faturimit dhe fiskalizimit per bizneset ne Shqiperi. Hap nje llogari
Skip to content
fature.al API Menu

Krijo fature elektronike (E-Invoice)

POST /api/v1/invoice/e-invoice Requires authentication Rate limited by the `api-global` limiter v1

Send a bearer token in the Authorization header.

Fatura dergohet automatikisht ne sistemin qendror te e-faturave. Klienti identifikohet me NIPT.

Bleresi shkon i plote ne sistemin e e-faturave, prandaj client.address dhe client.city duhen ose ne kerkese, ose te ruajtura me pare tek klienti ne fature.al. Kur mungon nje e dhene e nevojshme, kerkesa refuzohet me 400 dhe fusha errors thote sakte cfare duhet plotesuar.

Lloji i dokumentit#

process shkon si ProfileID ne dokumentin UBL, doc_type si lloji i dokumentit. Te dyja jane te detyrueshme:

Dokumenti doc_type process Kerkon original_invoice_iic
Fature shitjeje 380 P1 jo
Note krediti 381 P9 po
Note debiti 383 P9 po

Nje note krediti dhe nje note debiti korrigjojne nje fature tjeter, prandaj kerkojne original_invoice_iic, IIC-ne qe ju ktheu ajo fature:

  • shkon si BillingReference ne dokumentin UBL;
  • shkon si reference korrigjimi ne regjistrimin e CIS;
  • pa te, kerkesa refuzohet me 422.

Per te kthyer nje fature te plote perdorni endpoint-in e anulimit, jo nje note krediti: ai e shenon origjinalin si te kthyer.

Zbritja mbi faturen#

invoice_discount_type me invoice_discount_value dergohen gjithmone bashke, dhe zbresin te gjithe faturen. Nje rresht i vetem zbritet me lines[].discount, dhe te dyja mund te jene ne te njejten fature.

invoice_discount_type Si lexohet invoice_discount_value Kufiri
percent perqindje mbi totalin me TVSH 100
amount vlere me TVSH, ne monedhen e fatures totali i fatures

Zbritja shperndahet mbi grupet e TVSH-se sipas peshes se secilit ne total, dhe TVSH-ja rillogaritet mbi vleren e ulur, keshtu qe nje fature me disa norma TVSH-je mbetet e sakte. lines[].discount eshte perqindje mbi cmimin e njesise se atij rreshti. price mbetet cmimi i plote dhe total vjen tashme i ulur: price here quantity, me zbritjen e hequr.

Ne dokumentin UBL zbritja del si AllowanceCharge, me nje ze per cdo norme TVSH-je.

Full URL: https://fature.al/api/v1/invoice/e-invoice

Body parameters

Name Type Required Description
internalId string yes ID unike e fatures ne sistemin tuaj. Sherben edhe si celes idempotence: i njejti `internalId` brenda te njejtit vit kthen `409` ne vend qe te leshoje nje fature te dyte, prandaj nje riprovim pas nje lidhjeje qe u nderpre eshte i sigurt.
client object yes Bleresi. I detyrueshem per nje e-fature, sepse dokumenti shkon i plote ne sistemin qendror. Dergoni `client.internal_id` per nje klient te ruajtur, ose NIPT-in me emrin dhe shtetin per nje te ri.
client.internal_id integer, nullable no ID e nje klienti te ruajtur ne fature.al. Kur e dergoni, klienti gjendet me te dhe fushat e tjera nuk lexohen.
client.nuis string no NIPT-i i bleresit. I detyrueshem kur nuk dergoni `client.internal_id`.
client.name string no Emri i bleresit. I detyrueshem kur nuk dergoni `client.internal_id`.
client.address string, nullable no Adresa e bleresit qe shkon ne sistemin e e-faturave. Duhet ose ne kete kerkese ose e ruajtur me pare ne fature.al.
client.city string, nullable no Qyteti i bleresit qe shkon ne sistemin e e-faturave. Duhet ose ne kete kerkese ose i ruajtur me pare ne fature.al.
client.country string no Kodi i shtetit ISO 3166-1 alpha-3.
lines array yes Rreshtat e fatures, te pakten nje.
lines[].product_name string yes Emri i produktit ose i sherbimit.
lines[].product_code string yes Kodi i produktit ne katalogun tuaj.
lines[].unit string yes Njesia matese si tekst, ajo qe lexon njeriu.
lines[].quantity number yes Sasia.
lines[].price number yes Cmimi per njesi, me TVSH.
lines[].total number yes Totali i rreshtit, me TVSH.
lines[].discount number, min 0, max 100, nullable no Zbritja e ketij rreshti, ne perqindje mbi cmimin e njesise. Eshte opsionale: pa te, ose me vlere bosh, rreshti kalon pikerisht si me pare dhe mungesa e saj nuk kthen kurre gabim. `price` mbetet cmimi i plote i njesise, ndersa `total` vjen tashme i ulur: `price` here `quantity`, me zbritjen e hequr. Nje `total` qe nuk perputhet me ate shifer e refuzon kerkesen me `400`, dhe `errors` tregon cili eshte rreshti dhe cila vlere pritej.
lines[].vat integer, one of 0, 6, 10, 20, nullable no Norma e TVSH-se ne perqindje: `0`, `6`, `10` ose `20`. Kur biznesi juaj nuk eshte ne skemen e TVSH-se, rreshti regjistrohet me TVSH `0` dhe me perjashtim `TAX_FREE` sido qe ta dergoni kete fushe. Kerkesa nuk refuzohet.
lines[].vat_exempt_type string, one of TYPE_1, TYPE_2, EXPORT_OF_GOODS, TAX_FREE, nullable no Arsyeja e perjashtimit nga TVSH, kur rreshti eshte i perjashtuar.
invoice_discount_type string, one of percent, amount, nullable no Si lexohet `invoice_discount_value`: `percent` si perqindje, `amount` si vlere fikse me TVSH. Zbritja zbatohet mbi te gjithe faturen, kurre mbi nje rresht te vetem: rreshtat ruhen ashtu si i dergoni dhe ulet vetem totali. Punon vetem ne cift me `invoice_discount_value`. Njera pa tjetren injorohet ne heshtje, dhe fatura del pa zbritje.
invoice_discount_value number, min 0, nullable no Vlera e zbritjes, e lexuar sipas `invoice_discount_type`: perqindje kur tipi eshte `percent`, e kufizuar ne 100; vlere me TVSH ne monedhen e fatures kur tipi eshte `amount`, e kufizuar ne totalin e fatures. Zeroja e le faturen pa zbritje. Ne dokumentin UBL del si AllowanceCharge me nje ze per cdo norme TVSH-je, sepse zbritja shperndahet mbi grupet e TVSH-se sipas peshes se secilit ne total. Detajet dhe shembujt: faqja Zbritjet ne fature.
bank_account integer, nullable no ID e nje llogarie bankare te ruajtur ne fature.al.
bank_account_iban string, nullable no IBAN-i i llogarise. Alternative ndaj `bank_account`, kur mbani IBAN-in dhe jo ID-ne.
bankAccount object, nullable no Llogaria bankare e shkruar e plote, kur nuk e keni ende ne fature.al. Ruhet si llogari e kompanise suaj, dhe nje IBAN qe ekziston tashme riperdoret ne vend qe te dyfishohet.
bankAccount.name string, nullable no Emri i bankes.
bankAccount.iban string, nullable no IBAN-i i llogarise.
bankAccount.currency string, nullable no Monedha e llogarise.
bankAccount.swift string, nullable no Kodi SWIFT/BIC i bankes.
bankAccount.notes string, nullable no Shenime qe shoqerojne llogarine ne fature.
bankAccount.holder string, nullable no Mbajtesi i llogarise.
currency string, nullable no Monedha e fatures. Pa te merret ALL.
exchange_rate number, nullable no Sa leke vlen nje njesi e monedhes se fatures. Pa te, ose me nje vlere jo pozitive, merret 1. Per monedha qe vlejne me pak se nje lek, si JPY ose HUF, dergoni vlere nen 1.
due_date string, nullable no Afati i pageses, ne formatin `YYYY-MM-DD`.
supply_start_date string, nullable no Fillimi i periudhes se furnizimit, per fatura qe mbulojne nje interval.
supply_end_date string, nullable no Fundi i periudhes se furnizimit.
reverse_charge boolean, nullable no Ngarkesa e kundert: TVSH-ja deklarohet nga bleresi, jo nga shitesi.
notes string, nullable no Shenime qe shfaqen ne fature.
periodic_invoice boolean, nullable no Shenon nje fature qe i perket nje cikli te perseritur faturimi.
original_invoice_iic string, nullable yes IIC-ja e fatures qe ky dokument korrigjon, ajo qe ju ktheu fatura origjinale. E detyrueshme per nje note krediti (`doc_type=381`) dhe per nje note debiti (`doc_type=383`), sepse te dyja korrigjojne nje fature tjeter. Nuk pranohet per llojet e tjera te dokumentit. Required depending on doc_type.

Responses

201 Created

Field Type Description
status boolean
data object
data.invoice object
data.invoice.id integer Fatureal invoice id. Store it next to your own internalId
data.invoice.number string, nullable Fiscal invoice number
data.invoice.iic string, nullable IIC / NSLF
data.invoice.fic string, nullable FIC / NIVF. Null while the invoice waits for a deferred fiscalisation
data.invoice.tcrCode string, nullable TCR code of the fiscal device that issued it
data.invoice.businessCode string, nullable Business unit code the invoice was issued under
data.invoice.operatorCode string, nullable Operator code the invoice was issued under
data.invoice.fiscalizedAt string Creation timestamp (YYYY-MM-DD HH:MM:SS)
data.invoice.verifyURL string, nullable Government verification URL, the one behind the QR code
data.invoice.pdf string Direct download URL for the document. On an e-invoice that already has an EIC this points at the official e-invoice PDF instead of ours
data.invoice.eic string, nullable EIC. The key is present only on an e-invoice that already has one, so treat it as absent rather than null on every other invoice

400 Te dhena te paplota ose te pavlefshme. `errors` thote sakte cfare duhet plotesuar.

Field Type Description
status boolean Always false. A successful response carries `status: true` and a `data` object instead
message string The exception message. Empty when the failure carries no exception of its own
errors array Messages to show the operator or to log. Absent when the failure has nothing to add beyond `message`

403 Abonimi ka mbaruar, ose veprimi nuk lejohet per kete llogari.

Field Type Description
status boolean Always false. A successful response carries `status: true` and a `data` object instead
message string The exception message. Empty when the failure carries no exception of its own
errors array Messages to show the operator or to log. Absent when the failure has nothing to add beyond `message`

409 Nje fature me kete `internalId` po procesohet ose ekziston tashme per kete vit.

Field Type Description
status boolean Always false. A successful response carries `status: true` and a `data` object instead
message string The exception message. Empty when the failure carries no exception of its own
errors array Messages to show the operator or to log. Absent when the failure has nothing to add beyond `message`

422 Te dhenat nuk kaluan validimin. Kjo pergjigje perdor fushen `success`, jo `status`. `internalId` qe mungon kthehet me zarfin standard te gabimit.

Field Type Description
success boolean Always false
message string A single summary line, the same for every validation failure
errors object The failing fields, each with the messages for it. Dotted keys point into nested objects and array items, e.g. `lines.0.quantity`

429 Kufiri i kerkesave u arrit. Kufiri per endpoint kthen zarfin standard te gabimit; kufiri i pergjithshem kthen vetem `message` bashke me header-in `Retry-After`.

Field Type Description
status boolean Always false. A successful response carries `status: true` and a `data` object instead
message string The exception message. Empty when the failure carries no exception of its own
errors array Messages to show the operator or to log. Absent when the failure has nothing to add beyond `message`

500 Gabim i papritur ne server.

Field Type Description
status boolean Always false. A successful response carries `status: true` and a `data` object instead
message string The exception message. Empty when the failure carries no exception of its own
errors array Messages to show the operator or to log. Absent when the failure has nothing to add beyond `message`

503 Sherbimi i fiskalizimit eshte i paarritshem. Fatura ruhet dhe fiskalizohet automatikisht me vone.

Field Type Description
status boolean Always false. A successful response carries `status: true` and a `data` object instead
message string The exception message. Empty when the failure carries no exception of its own
errors array Messages to show the operator or to log. Absent when the failure has nothing to add beyond `message`

Example request

cURL
curl -X POST 'https://fature.al/api/v1/invoice/e-invoice' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'X-Client-Id: YOUR_CLIENT_ID' \
  -H 'X-Client-Secret: YOUR_CLIENT_SECRET' \
  -H 'Accept: application/json' \
  -H 'Content-Type: application/json' \
  -d '{
    "internalId": "EINV-2026-000412",
    "client": {
        "internal_id": 8812,
        "nuis": "L62221018T",
        "name": "Ei3 Software Solution shpk",
        "address": "1 Example Street",
        "city": "Berlin",
        "country": "ALB"
    },
    "lines": [
        {
            "product_name": "Kafe",
            "product_code": "KAF-001",
            "unit": "cope",
            "quantity": 2,
            "price": 150,
            "total": 300,
            "discount": 10,
            "vat": 20,
            "vat_exempt_type": "EXPORT_OF_GOODS"
        }
    ],
    "invoice_discount_type": "percent",
    "invoice_discount_value": 10,
    "bank_account": 42,
    "bank_account_iban": "AL35202111090000000001234567",
    "bankAccount": {
        "name": "BKT",
        "iban": "AL35202111090000000001234567",
        "currency": "ALL",
        "swift": "NCBAALTX",
        "notes": "notes",
        "holder": "Ei3 Software Solution shpk"
    },
    "currency": "ALL",
    "exchange_rate": 100.5,
    "due_date": "2026-10-04",
    "supply_start_date": "2026-09-01",
    "supply_end_date": "2026-09-30",
    "reverse_charge": false,
    "notes": "Faleminderit per blerjen",
    "periodic_invoice": false,
    "original_invoice_iic": "8FE72E2ACD1C500A83F8C89B4E2E3E1D"
}'
PHP (Laravel)
use Illuminate\Support\Facades\Http;

$response = Http::withHeaders([
    'Authorization' => 'Bearer YOUR_TOKEN',
    'X-Client-Id' => 'YOUR_CLIENT_ID',
    'X-Client-Secret' => 'YOUR_CLIENT_SECRET',
    'Accept' => 'application/json',
    'Content-Type' => 'application/json',
])->post('https://fature.al/api/v1/invoice/e-invoice', [
    'internalId' => 'EINV-2026-000412',
    'client' => [
        'internal_id' => 8812,
        'nuis' => 'L62221018T',
        'name' => 'Ei3 Software Solution shpk',
        'address' => '1 Example Street',
        'city' => 'Berlin',
        'country' => 'ALB',
    ],
    'lines' => [
        [
            'product_name' => 'Kafe',
            'product_code' => 'KAF-001',
            'unit' => 'cope',
            'quantity' => 2,
            'price' => 150,
            'total' => 300,
            'discount' => 10,
            'vat' => 20,
            'vat_exempt_type' => 'EXPORT_OF_GOODS',
        ],
    ],
    'invoice_discount_type' => 'percent',
    'invoice_discount_value' => 10,
    'bank_account' => 42,
    'bank_account_iban' => 'AL35202111090000000001234567',
    'bankAccount' => [
        'name' => 'BKT',
        'iban' => 'AL35202111090000000001234567',
        'currency' => 'ALL',
        'swift' => 'NCBAALTX',
        'notes' => 'notes',
        'holder' => 'Ei3 Software Solution shpk',
    ],
    'currency' => 'ALL',
    'exchange_rate' => 100.5,
    'due_date' => '2026-10-04',
    'supply_start_date' => '2026-09-01',
    'supply_end_date' => '2026-09-30',
    'reverse_charge' => false,
    'notes' => 'Faleminderit per blerjen',
    'periodic_invoice' => false,
    'original_invoice_iic' => '8FE72E2ACD1C500A83F8C89B4E2E3E1D',
]);

$data = $response->json();
PHP (Guzzle)
use GuzzleHttp\Client;

$client = new Client();

$response = $client->request('POST', 'https://fature.al/api/v1/invoice/e-invoice', [
    'headers' => [
        'Authorization' => 'Bearer YOUR_TOKEN',
        'X-Client-Id' => 'YOUR_CLIENT_ID',
        'X-Client-Secret' => 'YOUR_CLIENT_SECRET',
        'Accept' => 'application/json',
        'Content-Type' => 'application/json',
    ],
    'json' => [
        'internalId' => 'EINV-2026-000412',
        'client' => [
            'internal_id' => 8812,
            'nuis' => 'L62221018T',
            'name' => 'Ei3 Software Solution shpk',
            'address' => '1 Example Street',
            'city' => 'Berlin',
            'country' => 'ALB',
        ],
        'lines' => [
            [
                'product_name' => 'Kafe',
                'product_code' => 'KAF-001',
                'unit' => 'cope',
                'quantity' => 2,
                'price' => 150,
                'total' => 300,
                'discount' => 10,
                'vat' => 20,
                'vat_exempt_type' => 'EXPORT_OF_GOODS',
            ],
        ],
        'invoice_discount_type' => 'percent',
        'invoice_discount_value' => 10,
        'bank_account' => 42,
        'bank_account_iban' => 'AL35202111090000000001234567',
        'bankAccount' => [
            'name' => 'BKT',
            'iban' => 'AL35202111090000000001234567',
            'currency' => 'ALL',
            'swift' => 'NCBAALTX',
            'notes' => 'notes',
            'holder' => 'Ei3 Software Solution shpk',
        ],
        'currency' => 'ALL',
        'exchange_rate' => 100.5,
        'due_date' => '2026-10-04',
        'supply_start_date' => '2026-09-01',
        'supply_end_date' => '2026-09-30',
        'reverse_charge' => false,
        'notes' => 'Faleminderit per blerjen',
        'periodic_invoice' => false,
        'original_invoice_iic' => '8FE72E2ACD1C500A83F8C89B4E2E3E1D',
    ],
]);

$data = json_decode((string) $response->getBody(), true);
JavaScript
const response = await fetch('https://fature.al/api/v1/invoice/e-invoice', {
  method: 'POST',
  headers: {
    'Authorization': 'Bearer YOUR_TOKEN',
    'X-Client-Id': 'YOUR_CLIENT_ID',
    'X-Client-Secret': 'YOUR_CLIENT_SECRET',
    'Accept': 'application/json',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
      "internalId": "EINV-2026-000412",
      "client": {
          "internal_id": 8812,
          "nuis": "L62221018T",
          "name": "Ei3 Software Solution shpk",
          "address": "1 Example Street",
          "city": "Berlin",
          "country": "ALB"
      },
      "lines": [
          {
              "product_name": "Kafe",
              "product_code": "KAF-001",
              "unit": "cope",
              "quantity": 2,
              "price": 150,
              "total": 300,
              "discount": 10,
              "vat": 20,
              "vat_exempt_type": "EXPORT_OF_GOODS"
          }
      ],
      "invoice_discount_type": "percent",
      "invoice_discount_value": 10,
      "bank_account": 42,
      "bank_account_iban": "AL35202111090000000001234567",
      "bankAccount": {
          "name": "BKT",
          "iban": "AL35202111090000000001234567",
          "currency": "ALL",
          "swift": "NCBAALTX",
          "notes": "notes",
          "holder": "Ei3 Software Solution shpk"
      },
      "currency": "ALL",
      "exchange_rate": 100.5,
      "due_date": "2026-10-04",
      "supply_start_date": "2026-09-01",
      "supply_end_date": "2026-09-30",
      "reverse_charge": false,
      "notes": "Faleminderit per blerjen",
      "periodic_invoice": false,
      "original_invoice_iic": "8FE72E2ACD1C500A83F8C89B4E2E3E1D"
  })
});

const data = await response.json();

Example response

201
{
    "status": true,
    "data": {
        "invoice": {
            "id": 1,
            "number": "number",
            "iic": "iic",
            "fic": "fic",
            "tcrCode": "tcrCode",
            "businessCode": "businessCode",
            "operatorCode": "operatorCode",
            "fiscalizedAt": "fiscalizedAt",
            "verifyURL": "https://example.com",
            "pdf": "pdf",
            "eic": "eic"
        }
    }
}
400
{
    "status": true,
    "message": "Hello there",
    "errors": [
        "errors"
    ]
}
403
{
    "status": true,
    "message": "Hello there",
    "errors": [
        "errors"
    ]
}
409
{
    "status": true,
    "message": "Hello there",
    "errors": [
        "errors"
    ]
}
422
{
    "success": true,
    "message": "Hello there",
    "errors": []
}
429
{
    "status": true,
    "message": "Hello there",
    "errors": [
        "errors"
    ]
}
500
{
    "status": true,
    "message": "Hello there",
    "errors": [
        "errors"
    ]
}
503
{
    "status": true,
    "message": "Hello there",
    "errors": [
        "errors"
    ]
}

Regjistrimi eshte falas.

Regjistrohu ne fature.al

This page as Markdown, or the whole API as OpenAPI.