Kalo te dokumentacioni

U kopjua

API Cloud për Fiskalizimin

01 · Kërkesa e parë

Nga token-i te fatura fiskale

Përdorni fillimisht mjedisin e zhvillimit. Biznesi dhe pajisja fiskale merren nga token-i, ndaj trupi i kërkesës përmban vetëm të dhënat e dokumentit.

  1. 01

    Merrni kredencialet

    Kërkoni token të regjistruar për mjedisin, biznesin dhe pajisjen që do të përdorni.

  2. 02

    Krijoni docId

    Gjeneroni dhe ruani një identifikues të qëndrueshëm para kërkesës së parë.

  3. 03

    Regjistroni dhe verifikoni

    Dërgoni faturën dhe kontrolloni kodet e përfundimit, jo vetëm HTTP 200.

Faturë e zakonshme minimale
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/register' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "SHOP-2026-000123",
  "articles": [
    {
      "articleId": "ART-1",
      "name": "Kafe",
      "vatCode": "B",
      "price": 120,
      "units": 2,
      "soldIn": "XPP"
    }
  ],
  "payment": [
    {
      "type": "CASH",
      "amount": 240
    }
  ]
}'
Përgjigje e përfunduar
{
  "orderId": "SHOP-2026-000123",
  "fic": "52ca073b-536e-48e9-8678-cc0bf2202046",
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "invoiceNumber": "12/2026/xx123xx123",
  "invoiceType": "CASH",
  "totalPrice": 240
}

02 · Aksesi

Autentikimi dhe kokat HTTP

Çdo endpoint kërkon token Bearer. Zëvendësoni vlerën shembull të integration-app me identifikuesin e qëndrueshëm që i është caktuar integrimit tuaj dhe përdoreni të pandryshuar në çdo kërkesë.

Koka HTTPKërkesaQëllimi
AuthorizationI detyrueshëmToken Bearer për mjedisin e zgjedhur.
Content-TypeI detyrueshëmPërdorni application/json për çdo kërkesë.
integration-appI rekomanduarZëvendësoni your-client-name ose erp-x me identifikuesin e caktuar integrimit tuaj.

03 · Protokolli i rikuperimit

docId parandalon dublikimin

Zgjidheni docId në sistemin tuaj para dërgimit. Ripërdorimi vazhdon të njëjtin operacion fiskal dhe kthen të njëjtin rezultat; nuk duhet të krijojë faturë të dytë.

Gjenerojeni një herë
5–200 karaktere, unik për çdo dokument biznesi.
Ruajeni para POST
Ruani atomikisht docId, trupin e pandryshueshëm të kërkesës dhe ID-në lokale.
Ripërdoreni në rikuperim
Timeout, humbje lidhjeje, 502/503 dhe e-faturë e papërfunduar mbajnë të njëjtin docId.
Vetëm një kërkesë
Mos ekzekutoni register dhe status paralelisht për të njëjtin docId.

Rrjedha e sigurt e rikuperimit

same docId · same body
  1. 01

    POST register

  2. 02

    E paqartë / papërfunduar

  3. 03

    Pritje + jitter

  4. 04

    POST status

  5. 05

    Përfundoi?

  6. 06

    Ridërgo të njëjtën kërkesë

  1. 1Kontrolloni përfundimin: fatura normale kërkon fic; fatura elektronike kërkon fic dhe eic.
  2. 2Për timeout, gabim rrjeti, 502/503 ose rezultat të papërfunduar, përdorni pritje eksponenciale me jitter, maksimumi 30 sekonda.
  3. 3Thirrni /invoice/status me të njëjtin docId. Nëse dokumenti nuk ekziston, ridërgoni /invoice/register me të njëjtin trup kërkese dhe të njëjtin docId.
  4. 4Mos riprovoni gabimet e validimit ose cisError.faultEnv=env:CLIENT pa korrigjuar kërkesën.

Anulimi është dokument i ri fiskal: krijoni docId të ri për anulimin. Çdo riprovim i anulimit përdor docId e anulimit.

Skema e vendimmarrjes së klientit
const docId = await persistOperation(payload)

const result = await register({ ...payload, docId })
if (result.fic && (!payload.isEinvoice || result.eic)) return complete(result)

await backoffWithJitter()
const recovered = await status({ docId })

if (recovered.notFound) {
  return register({ ...payload, docId }) // exact same body
}

return evaluate(recovered)

04 · Modeli i dokumentit

Shembujt e kërkesave për faturë

Hapni llojin e dokumentit për të parë kërkesën, përgjigjen dhe identifikuesit që klienti duhet të kontrollojë.

POST NORMALArtikuj, pagesa të kombinuara dhe blerës opsional. documentType mund të mungojë.
/invoice/registerPërfundimi: fic #invoice-type-normal
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/register' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "SHOP-2026-000123",
  "articles": [
    {
      "articleId": "ART-COFFEE",
      "name": "Kafe ekspres",
      "vatCode": "B",
      "price": 120,
      "units": 2,
      "soldIn": "XPP"
    },
    {
      "articleId": "ART-WATER",
      "name": "Ujë natyral",
      "vatCode": "B",
      "price": 100,
      "units": 1,
      "soldIn": "XPP"
    }
  ],
  "payment": [
    {
      "type": "CASH",
      "amount": 200
    },
    {
      "type": "CARD",
      "amount": 140
    }
  ]
}'
Shembull përgjigjeje
{
  "orderId": "SHOP-2026-000123",
  "fic": "52ca073b-536e-48e9-8678-cc0bf2202046",
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "invoiceNumber": "12/2026/xx123xx123",
  "invoiceType": "CASH",
  "totalPrice": 340
}

Fushat e kërkesës

FushaTipi
docIdstring
articlesobject[]
articles[].articleIdstring
articles[].namestring
articles[].vatCodestring
articles[].pricenumber
articles[].unitsnumber
articles[].soldInstring
paymentobject[]
payment[].typestring
payment[].amountnumber

Fushat e përgjigjes

FushaTipi
orderIdstring
ficstring
iicstring
invoiceNumberstring
invoiceTypestring
totalPricenumber
POST ORDERVetëm artikuj; payment nuk dërgohet dhe krijohet si ORDER.
/invoice/registerPërfundimi: fic #invoice-type-order
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/register' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "ORDER-2026-000124",
  "documentType": "ORDER",
  "articles": [
    {
      "articleId": "ORD-1",
      "name": "Drekë biznesi",
      "vatCode": "B",
      "price": 1200,
      "units": 1,
      "soldIn": "XPP"
    }
  ]
}'
Shembull përgjigjeje
{
  "orderId": "ORDER-2026-000124",
  "fic": "52ca073b-536e-48e9-8678-cc0bf2202046",
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "invoiceNumber": "13/2026/xx123xx123",
  "invoiceType": "CASH",
  "totalPrice": 1200
}

Fushat e kërkesës

FushaTipi
docIdstring
documentTypestring
articlesobject[]
articles[].articleIdstring
articles[].namestring
articles[].vatCodestring
articles[].pricenumber
articles[].unitsnumber
articles[].soldInstring

Fushat e përgjigjes

FushaTipi
orderIdstring
ficstring
iicstring
invoiceNumberstring
invoiceTypestring
totalPricenumber
POST SUMMARYPërdor iic-të ORDER të papërdorura; articles nuk dërgohet.
/invoice/registerPërfundimi: fic #invoice-type-summary
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/register' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "SUMMARY-2026-000125",
  "documentType": "SUMMARY",
  "summaryInvoices": [
    "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
    "A11EBF3F7B7C502D6AAF2321A7CE2CE9"
  ],
  "total": 1800,
  "payment": [
    {
      "type": "CASH",
      "amount": 1800
    }
  ]
}'
Shembull përgjigjeje
{
  "orderId": "SUMMARY-2026-000125",
  "fic": "52ca073b-536e-48e9-8678-cc0bf2202046",
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "invoiceNumber": "14/2026/xx123xx123",
  "invoiceType": "CASH",
  "totalPrice": 1800
}

Fushat e kërkesës

FushaTipi
docIdstring
documentTypestring
summaryInvoicesstring[]
totalnumber
paymentobject[]
payment[].typestring
payment[].amountnumber

Fushat e përgjigjes

FushaTipi
orderIdstring
ficstring
iicstring
invoiceNumberstring
invoiceTypestring
totalPricenumber
POST SELFISSUEKërkon selfIssueType dhe të dhënat e furnitorit te buyer.
/invoice/registerPërfundimi: fic #invoice-type-selfissue
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/register' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "SELFISSUE-2026-000126",
  "documentType": "SELFISSUE",
  "selfIssueType": "DOMESTIC",
  "reverseCharge": true,
  "buyer": {
    "buyerIDType": "NUIS",
    "buyerIDNum": "{{supplierNipt}}",
    "buyerName": "Furnitor SHPK",
    "buyerAddress": "Tiranë",
    "buyerTown": "Tiranë",
    "buyerCountry": "ALB"
  },
  "articles": [
    {
      "articleId": "SVC-1",
      "name": "Shërbim profesional",
      "vatCode": "B",
      "price": 10000,
      "units": 1,
      "soldIn": "HUR"
    }
  ],
  "payment": [
    {
      "type": "CASH",
      "amount": 10000
    }
  ]
}'
Shembull përgjigjeje
{
  "orderId": "SELFISSUE-2026-000126",
  "fic": "52ca073b-536e-48e9-8678-cc0bf2202046",
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "invoiceNumber": "15/2026/xx123xx123",
  "invoiceType": "CASH",
  "totalPrice": 10000
}

Fushat e kërkesës

FushaTipi
docIdstring
documentTypestring
selfIssueTypestring
reverseChargeboolean
buyerobject
buyer.buyerIDTypestring
buyer.buyerIDNumstring
buyer.buyerNamestring
buyer.buyerAddressstring
buyer.buyerTownstring
buyer.buyerCountrystring
articlesobject[]
articles[].articleIdstring
articles[].namestring
articles[].vatCodestring
articles[].pricenumber
articles[].unitsnumber
articles[].soldInstring
paymentobject[]
payment[].typestring
payment[].amountnumber

Fushat e përgjigjes

FushaTipi
orderIdstring
ficstring
iicstring
invoiceNumberstring
invoiceTypestring
totalPricenumber
POST EXPORTKërkon blerës të huaj dhe kodin e TVSH-së së eksportit të biznesit.
/invoice/registerPërfundimi: fic #invoice-type-export
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/register' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "EXPORT-2026-000127",
  "documentType": "EXPORT",
  "supplyPeriod": {
    "start": "2026-08-01",
    "end": "2026-08-28"
  },
  "buyer": {
    "buyerIDType": "VAT",
    "buyerIDNum": "IT12345678901",
    "buyerName": "Acquirente Demo SRL",
    "buyerAddress": "Via Roma 1",
    "buyerTown": "Bari",
    "buyerCountry": "ITA",
    "buyerCountryCode": "IT"
  },
  "articles": [
    {
      "articleId": "EXP-1",
      "name": "Mall për eksport",
      "vatCode": "J",
      "price": 25000,
      "units": 4,
      "soldIn": "XPP"
    }
  ],
  "payment": [
    {
      "type": "TRANSFER",
      "amount": 100000
    }
  ]
}'
Shembull përgjigjeje
{
  "orderId": "EXPORT-2026-000127",
  "fic": "52ca073b-536e-48e9-8678-cc0bf2202046",
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "invoiceNumber": "16/2026/xx123xx123",
  "invoiceType": "CASH",
  "totalPrice": 100000
}

Fushat e kërkesës

FushaTipi
docIdstring
documentTypestring
supplyPeriodobject
supplyPeriod.startstring
supplyPeriod.endstring
buyerobject
buyer.buyerIDTypestring
buyer.buyerIDNumstring
buyer.buyerNamestring
buyer.buyerAddressstring
buyer.buyerTownstring
buyer.buyerCountrystring
buyer.buyerCountryCodestring
articlesobject[]
articles[].articleIdstring
articles[].namestring
articles[].vatCodestring
articles[].pricenumber
articles[].unitsnumber
articles[].soldInstring
paymentobject[]
payment[].typestring
payment[].amountnumber

Fushat e përgjigjes

FushaTipi
orderIdstring
ficstring
iicstring
invoiceNumberstring
invoiceTypestring
totalPricenumber
POST ELEKTRONIKE · P1Faturë elektronike standarde me blerës NUIS dhe pagesë pa para në dorë.
/invoice/registerPërfundimi: fic + eic #invoice-type-electronic-p1
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/register' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "EINVOICE-P1-2026-000128",
  "isEinvoice": true,
  "selectedProcess": "P1",
  "payDeadline": "2026-09-30",
  "buyer": {
    "buyerIDType": "NUIS",
    "buyerIDNum": "{{buyerNipt}}",
    "buyerName": "Blerës SHPK",
    "buyerAddress": "Tiranë",
    "buyerTown": "Tiranë",
    "buyerCountry": "ALB",
    "buyerCountryCode": "AL"
  },
  "articles": [
    {
      "articleId": "SVC-CLOUD",
      "name": "Shërbim cloud",
      "vatCode": "B",
      "price": 10000,
      "units": 1,
      "soldIn": "HUR"
    }
  ],
  "payment": [
    {
      "type": "ACCOUNT",
      "amount": 10000,
      "details": [
        {
          "idNumber": "{{sellerIban}}",
          "name": "Shitësi SHPK",
          "bankName": "Banka",
          "swift_code": "ABCDEFGH",
          "country": "Shqipëri",
          "countryCode": "AL",
          "currency": "ALL"
        }
      ]
    }
  ]
}'
Shembull përgjigjeje
{
  "orderId": "EINVOICE-P1-2026-000128",
  "fic": "52ca073b-536e-48e9-8678-cc0bf2202046",
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "invoiceNumber": "17/2026/xx123xx123",
  "invoiceType": "NONCASH",
  "totalPrice": 10000,
  "eic": "2a8d91cf-8fea-4d86-b79d-4bcb0b153e78"
}

Fushat e kërkesës

FushaTipi
docIdstring
isEinvoiceboolean
selectedProcessstring
payDeadlinestring
buyerobject
buyer.buyerIDTypestring
buyer.buyerIDNumstring
buyer.buyerNamestring
buyer.buyerAddressstring
buyer.buyerTownstring
buyer.buyerCountrystring
buyer.buyerCountryCodestring
articlesobject[]
articles[].articleIdstring
articles[].namestring
articles[].vatCodestring
articles[].pricenumber
articles[].unitsnumber
articles[].soldInstring
paymentobject[]
payment[].typestring
payment[].amountnumber
payment[].detailsobject[]
payment[].details[].idNumberstring
payment[].details[].namestring
payment[].details[].bankNamestring
payment[].details[].swift_codestring
payment[].details[].countrystring
payment[].details[].countryCodestring
payment[].details[].currencystring

Fushat e përgjigjes

FushaTipi
orderIdstring
ficstring
iicstring
invoiceNumberstring
invoiceTypestring
totalPricenumber
eicstring
POST ELEKTRONIKE · P4Faturë parapagimi; prepaidAmount duhet të jetë brenda totalit.
/invoice/registerPërfundimi: fic + eic #invoice-type-electronic-p4
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/register' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "EINVOICE-P4-2026-000129",
  "isEinvoice": true,
  "selectedProcess": "P4",
  "prepaidAmount": 5000,
  "buyer": {
    "buyerIDType": "NUIS",
    "buyerIDNum": "{{buyerNipt}}",
    "buyerName": "Blerës SHPK",
    "buyerAddress": "Tiranë",
    "buyerTown": "Tiranë",
    "buyerCountry": "ALB"
  },
  "articles": [
    {
      "articleId": "ADV-1",
      "name": "Parapagim shërbimi",
      "vatCode": "B",
      "price": 10000,
      "units": 1,
      "soldIn": "XPP"
    }
  ],
  "payment": [
    {
      "type": "TRANSFER",
      "amount": 10000
    }
  ]
}'
Shembull përgjigjeje
{
  "orderId": "EINVOICE-P4-2026-000129",
  "fic": "52ca073b-536e-48e9-8678-cc0bf2202046",
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "invoiceNumber": "18/2026/xx123xx123",
  "invoiceType": "NONCASH",
  "totalPrice": 10000,
  "eic": "0543e84b-6108-48b2-a2af-5db66bb80616"
}

Fushat e kërkesës

FushaTipi
docIdstring
isEinvoiceboolean
selectedProcessstring
prepaidAmountnumber
buyerobject
buyer.buyerIDTypestring
buyer.buyerIDNumstring
buyer.buyerNamestring
buyer.buyerAddressstring
buyer.buyerTownstring
buyer.buyerCountrystring
articlesobject[]
articles[].articleIdstring
articles[].namestring
articles[].vatCodestring
articles[].pricenumber
articles[].unitsnumber
articles[].soldInstring
paymentobject[]
payment[].typestring
payment[].amountnumber

Fushat e përgjigjes

FushaTipi
orderIdstring
ficstring
iicstring
invoiceNumberstring
invoiceTypestring
totalPricenumber
eicstring
POST ELEKTRONIKE · P9/P10Notë krediti ose korrigjim që referon iic elektronike.
/invoice/registerPërfundimi: fic + eic #invoice-type-electronic-p9-p10
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/register' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "EINVOICE-P9-2026-000130",
  "isEinvoice": true,
  "selectedProcess": "P9",
  "correctiveInvoice": {
    "iicRef": "{{electronicIic}}"
  },
  "buyer": {
    "buyerIDType": "NUIS",
    "buyerIDNum": "{{buyerNipt}}",
    "buyerName": "Blerës SHPK",
    "buyerAddress": "Tiranë",
    "buyerTown": "Tiranë",
    "buyerCountry": "ALB"
  },
  "articles": [
    {
      "articleId": "CORR-1",
      "name": "Korrigjim shërbimi",
      "vatCode": "B",
      "price": -1000,
      "units": 1,
      "soldIn": "XPP"
    }
  ],
  "payment": [
    {
      "type": "TRANSFER",
      "amount": -1000
    }
  ]
}'
Shembull përgjigjeje
{
  "orderId": "EINVOICE-P9-2026-000130",
  "fic": "52ca073b-536e-48e9-8678-cc0bf2202046",
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "invoiceNumber": "19/2026/xx123xx123",
  "invoiceType": "NONCASH",
  "totalPrice": -1000,
  "eic": "6df80aec-f690-43ce-a2f2-45ee0cb948ce"
}

Fushat e kërkesës

FushaTipi
docIdstring
isEinvoiceboolean
selectedProcessstring
correctiveInvoiceobject
correctiveInvoice.iicRefstring
buyerobject
buyer.buyerIDTypestring
buyer.buyerIDNumstring
buyer.buyerNamestring
buyer.buyerAddressstring
buyer.buyerTownstring
buyer.buyerCountrystring
articlesobject[]
articles[].articleIdstring
articles[].namestring
articles[].vatCodestring
articles[].pricenumber
articles[].unitsnumber
articles[].soldInstring
paymentobject[]
payment[].typestring
payment[].amountnumber

Fushat e përgjigjes

FushaTipi
orderIdstring
ficstring
iicstring
invoiceNumberstring
invoiceTypestring
totalPricenumber
eicstring
POST ELEKTRONIKE · P11Rrjedhë faturimi elektronik të pjesshëm.
/invoice/registerPërfundimi: fic + eic #invoice-type-electronic-p11
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/register' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "EINVOICE-P11-2026-000131",
  "isEinvoice": true,
  "selectedProcess": "P11",
  "buyer": {
    "buyerIDType": "NUIS",
    "buyerIDNum": "{{buyerNipt}}",
    "buyerName": "Blerës SHPK",
    "buyerAddress": "Tiranë",
    "buyerTown": "Tiranë",
    "buyerCountry": "ALB"
  },
  "articles": [
    {
      "articleId": "PART-1",
      "name": "Faturim i pjesshëm",
      "vatCode": "B",
      "price": 25000,
      "units": 1,
      "soldIn": "XPP"
    }
  ],
  "payment": [
    {
      "type": "TRANSFER",
      "amount": 25000
    }
  ]
}'
Shembull përgjigjeje
{
  "orderId": "EINVOICE-P11-2026-000131",
  "fic": "52ca073b-536e-48e9-8678-cc0bf2202046",
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "invoiceNumber": "20/2026/xx123xx123",
  "invoiceType": "NONCASH",
  "totalPrice": 25000,
  "eic": "55df7eaf-126f-41b7-8270-6fa57080703e"
}

Fushat e kërkesës

FushaTipi
docIdstring
isEinvoiceboolean
selectedProcessstring
buyerobject
buyer.buyerIDTypestring
buyer.buyerIDNumstring
buyer.buyerNamestring
buyer.buyerAddressstring
buyer.buyerTownstring
buyer.buyerCountrystring
articlesobject[]
articles[].articleIdstring
articles[].namestring
articles[].vatCodestring
articles[].pricenumber
articles[].unitsnumber
articles[].soldInstring
paymentobject[]
payment[].typestring
payment[].amountnumber

Fushat e përgjigjes

FushaTipi
orderIdstring
ficstring
iicstring
invoiceNumberstring
invoiceTypestring
totalPricenumber
eicstring
POST ANULIM · FATURE NORMALEdocId i ri për anulimin, me referencë te iic e faturës origjinale.
/invoice/cancelPërfundimi: fic #invoice-type-cancellation
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/cancel' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "CANCEL-2026-000132",
  "correctiveInvoice": {
    "iicRef": "D21EBF3F7B7C502D6AAF2321A7CE2CE8"
  },
  "invoiceNotes": "Anulim me kërkesë të klientit"
}'
Shembull përgjigjeje
{
  "orderId": "CANCEL-2026-000132",
  "fic": "52ca073b-536e-48e9-8678-cc0bf2202046",
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "invoiceNumber": "21/2026/xx123xx123",
  "invoiceType": "CASH",
  "totalPrice": -340
}

Fushat e kërkesës

FushaTipi
docIdstring
correctiveInvoiceobject
correctiveInvoice.iicRefstring
invoiceNotesstring

Fushat e përgjigjes

FushaTipi
orderIdstring
ficstring
iicstring
invoiceNumberstring
invoiceTypestring
totalPricenumber
POST ANULIM · FATURE ELEKTRONIKEAnulim korrigjues P10 për një faturë që ka tashmë eic.
/invoice/cancelPërfundimi: fic + eic #invoice-type-electronic-cancellation
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/cancel' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "CANCEL-EINVOICE-2026-000133",
  "isEinvoice": true,
  "selectedProcess": "P10",
  "correctiveInvoice": {
    "iicRef": "{{electronicIic}}"
  },
  "invoiceNotes": "Anulim i faturës elektronike"
}'
Shembull përgjigjeje
{
  "orderId": "CANCEL-EINVOICE-2026-000133",
  "fic": "52ca073b-536e-48e9-8678-cc0bf2202046",
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "invoiceNumber": "22/2026",
  "invoiceType": "NONCASH",
  "totalPrice": -10000,
  "eic": "d59ef857-47df-4a80-a7d8-22ce70577df3"
}

Fushat e kërkesës

FushaTipi
docIdstring
isEinvoiceboolean
selectedProcessstring
correctiveInvoiceobject
correctiveInvoice.iicRefstring
invoiceNotesstring

Fushat e përgjigjes

FushaTipi
orderIdstring
ficstring
iicstring
invoiceNumberstring
invoiceTypestring
totalPricenumber
eicstring

Harta e proceseve të faturës elektronike

Faturat elektronike mund të zgjasin më shumë sepse fiskalizimi dhe dorëzimi eInvoice janë faza të ndara. Janë të përfunduara vetëm kur kanë të dy kodet.

ProcesiLloji standardRregull shtesë
P1380Faturim i dërgesave kundrejt porosive të blerjes, bazuar në kontratë.
P2380Faturim i dërgesave të mallrave ose shërbimeve bazuar në kontratë.
P3380Faturim i dorëzimit për një porosi blerjeje të rastësishme.
P4386Parapagim; prepaidAmount duhet të jetë mbi 0 dhe jo më i madh se totali.
P5380Pagesë në vend.
P6380Pagesë para dorëzimit.
P7380Faturë me referencë te dokumenti i dërgesës.
P8380Faturë me referencë te dokumentet e dërgesës dhe marrjes.
P9384Notë krediti ose faturë me vlera negative; correctiveInvoice.iicRef duhet të referojë faturë me eic.
P10384Korrigjim ose anulim; correctiveInvoice.iicRef duhet të referojë faturë me eic.
P11326Faturim i pjesshëm dhe përfundimtar.
Kodet UNTDID të llojit të faturës

Përdorni selectedInvoiceType vetëm kur ju duhet një klasifikim i posaçëm i dokumentit. Kur mungon, selectedProcess cakton kodin standard të treguar më sipër.

KodiPërshkrimi
82Faturë për shërbime të matura
84Notë debiti për rregullime financiare
325Faturë paraprake
326Faturë e pjesshme
380Faturë tregtare
383Notë debiti
386Faturë parapagimi
393Faturë e faktorizuar
394Faturë qiraje
395Faturë dërgese
575Faturë e siguruesit
623Faturë e shpërndarësit
780Faturë mallrash

Kodet 80, 381, 384, 385 dhe 389 janë të rezervuara për lloje dokumentesh që caktohen automatikisht nga procesi dhe nuk mund të zgjidhen drejtpërdrejt.

05 · Referenca HTTP

Endpoint-et

Të gjitha endpoint-et përdorin POST me JSON dhe të njëjtat koka HTTP për autentikim.

POST/invoice/registerRegjistro faturë · Krijon dokument të ri ose vazhdon dokumentin e identifikuar nga docId.
Të detyrueshme
docId · articles[]* · payment[]*
Rregullat
NORMAL | ORDER | SUMMARY | SELFISSUE | EXPORT | eInvoice

Fushat e kërkesës

FushaTipi
docIdstring
operatorCodestring?
currencyCurrency?
articlesArticle[] (conditional)
paymentPayment[] (conditional)
invoiceRebateRebate?
buyerBuyer (conditional)
correctiveInvoiceCorrectiveInvoiceRef (conditional)
invoiceNotesstring?
documentTypeNORMAL | ORDER | SUMMARY | SELFISSUE | EXPORT?
selfIssueTypeAGREEMENT | DOMESTIC | ABROAD | SELF | OTHER (conditional)
reverseChargeboolean?
summaryInvoicesstring[] (conditional)
totalnumber (conditional)
supplyPeriod{ start: date; end: date }?
isEinvoiceboolean?
selectedProcessP1 | P2 | P3 | P4 | P5 | P6 | P7 | P8 | P9 | P10 | P11?
selectedInvoiceTypeUNTDID code?
payDeadlinestring(date)?
prepaidAmountnumber (conditional)

Fushat e përgjigjes

FushaTipi
orderIdstring
ficstring?
eicstring?
iicstring?
linkstring(uri)?
errorFiscalError?
invoiceNumberstring?
invoiceOrderNumberinteger?
invoiceTypeCASH | NONCASH?
totalPricenumber?
totalPriceWithoutVatnumber?
totalVatAmountnumber?
taxFreeAmountnumber?
goodsExportnumber?
markUpAmountnumber?
operatorCodestring?
businessUnitCodestring?
tcrCodestring?
sellerNamestring?
sellerNuisstring?
sellerAddressstring?
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/register' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "SHOP-2026-000123",
  "articles": [
    {
      "articleId": "ART-1",
      "name": "Kafe",
      "vatCode": "B",
      "price": 120,
      "units": 2,
      "soldIn": "XPP"
    }
  ],
  "payment": [
    {
      "type": "CASH",
      "amount": 240
    }
  ]
}'
Shembull përgjigjeje
{
  "orderId": "SHOP-2026-000123",
  "fic": "52ca073b-536e-48e9-8678-cc0bf2202046",
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "invoiceNumber": "12/2026/xx123xx123",
  "invoiceType": "CASH",
  "totalPrice": 240
}
POST/invoice/cancelAnulo faturë · Krijon anulim korrigjues për iic e një fature ekzistuese.
Të detyrueshme
new docId · correctiveInvoice.iicRef
Rregullat
no articles · no payment

Fushat e kërkesës

FushaTipi
docIdstring
operatorCodestring?
correctiveInvoiceCorrectiveInvoiceRef
invoiceNotesstring?
isEinvoiceboolean?
selectedProcessP1–P11?
selectedInvoiceTypeUNTDID code?
payDeadlinestring(date)?
prepaidAmountnumber?

Fushat e përgjigjes

FushaTipi
orderIdstring
ficstring?
eicstring?
iicstring?
linkstring(uri)?
errorFiscalError?
invoiceNumberstring?
invoiceOrderNumberinteger?
invoiceTypeCASH | NONCASH?
totalPricenumber?
totalPriceWithoutVatnumber?
totalVatAmountnumber?
taxFreeAmountnumber?
goodsExportnumber?
markUpAmountnumber?
operatorCodestring?
businessUnitCodestring?
tcrCodestring?
sellerNamestring?
sellerNuisstring?
sellerAddressstring?
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/cancel' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "SHOP-2026-000123-CANCEL",
  "correctiveInvoice": {
    "iicRef": "D21EBF3F7B7C502D6AAF2321A7CE2CE8"
  },
  "invoiceNotes": "Customer cancellation"
}'
Shembull përgjigjeje
{
  "orderId": "SHOP-2026-000123-CANCEL",
  "fic": "52ca073b-536e-48e9-8678-cc0bf2202046",
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "invoiceNumber": "13/2026/xx123xx123",
  "invoiceType": "CASH",
  "totalPrice": -240
}
POST/invoice/statusStatusi i faturës · Lexon statusin me docId dhe vazhdon një operacion të papërfunduar.
Të detyrueshme
docId
Rregullat
same docId · may continue processing

Fushat e kërkesës

FushaTipi
docIdstring

Fushat e përgjigjes

FushaTipi
orderIdstring
ficstring?
eicstring?
iicstring?
linkstring(uri)?
errorFiscalError?
invoiceNumberstring?
invoiceOrderNumberinteger?
invoiceTypeCASH | NONCASH?
totalPricenumber?
totalPriceWithoutVatnumber?
totalVatAmountnumber?
taxFreeAmountnumber?
goodsExportnumber?
markUpAmountnumber?
operatorCodestring?
businessUnitCodestring?
tcrCodestring?
sellerNamestring?
sellerNuisstring?
sellerAddressstring?
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/status' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "SHOP-2026-000123"
}'
Shembull përgjigjeje
{
  "orderId": "SHOP-2026-000123",
  "fic": "52ca073b-536e-48e9-8678-cc0bf2202046",
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "invoiceNumber": "12/2026/xx123xx123",
  "invoiceType": "CASH",
  "totalPrice": 240
}
POST/invoice/pdfPDF-ja e faturës · Gjeneron A4 PDF, kupon PNG ose PDF zyrtare elektronike në base64.
Të detyrueshme
iic
Rregullat
A4 | receipt | eInvoice

Fushat e kërkesës

FushaTipi
iicstring
pdfType'A4' | 'receipt' | 'eInvoice'
paperWidth58 | 80 | 110?
lang'sq' | 'en'?

Fushat e përgjigjes

FushaTipi
base64string
langstring?
eicstring?
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/invoice/pdf' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "iic": "D21EBF3F7B7C502D6AAF2321A7CE2CE8",
  "pdfType": "A4",
  "lang": "sq"
}'
Shembull përgjigjeje
{
  "base64": "JVBERi0xLjQKJcfsj6IK...",
  "lang": "sq"
}
POST/balance/initiateHap gjendjen · Raporton gjendjen fillestare të arkës në ALL.
Gjendja e arkës#initiate-balance
Të detyrueshme
docId · amount
Rregullat
once per business day and fiscal device · before the first cash invoice · amount in ALL

Fushat e kërkesës

FushaTipi
docIdstring
amountnumber
notesstring?
operatorCodestring?

Fushat e përgjigjes

FushaTipi
orderIdstring
fcdcstring?
errorFiscalError?
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/balance/initiate' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "SHIFT-2026-08-28-OPEN",
  "amount": 10000
}'
Shembull përgjigjeje
{
  "orderId": "SHIFT-2026-08-28-OPEN",
  "fcdc": "b5c3e1a2-9f44-4c3a-9c1e-2f0d7a5b8e10"
}
POST/balance/depositDepozito para · Raporton para të shtuara në arkë në ALL.
Gjendja e arkës#deposit-balance
Të detyrueshme
docId · amount
Rregullat
amount in ALL

Fushat e kërkesës

FushaTipi
docIdstring
amountnumber
notesstring?
operatorCodestring?

Fushat e përgjigjes

FushaTipi
orderIdstring
fcdcstring?
errorFiscalError?
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/balance/deposit' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "SHIFT-2026-08-28-IN-1",
  "amount": 5000,
  "notes": "Cash added to till"
}'
Shembull përgjigjeje
{
  "orderId": "SHIFT-2026-08-28-IN-1",
  "fcdc": "d6a4e2b3-8e55-4d2b-8b2f-3a1e6b4c9f21"
}
POST/balance/withdrawTërhiq para · Raporton para të hequra nga arka në ALL.
Gjendja e arkës#withdraw-balance
Të detyrueshme
docId · amount
Rregullat
amount in ALL

Fushat e kërkesës

FushaTipi
docIdstring
amountnumber
notesstring?
operatorCodestring?

Fushat e përgjigjes

FushaTipi
orderIdstring
fcdcstring?
errorFiscalError?
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/balance/withdraw' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "docId": "SHIFT-2026-08-28-OUT-1",
  "amount": 2500,
  "notes": "Bank deposit"
}'
Shembull përgjigjeje
{
  "orderId": "SHIFT-2026-08-28-OUT-1",
  "fcdc": "e7b5f3c4-7d66-5e3c-9a3e-4b2f7c5d0a32"
}
POST/utilities/get-taxpayersKërko tatimpagues · Kërkon tatimpagues shqiptarë me NIPT ose emër biznesi.
Utilitetet#get-taxpayers
Të detyrueshme
searchTerm (3–200)
Rregullat
NIPT or business name · searchTerm minimum 3 characters · no activity-status field

Fushat e kërkesës

FushaTipi
searchTermstring (3–200)

Fushat e përgjigjes

FushaTipi
[]Taxpayer[]
[].Tinstring
[].Namestring
[].Addressstring
[].Townstring
[].Countrystring (ISO 3166-1 alpha-3)
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/utilities/get-taxpayers' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{
  "searchTerm": "Vodafone"
}'
Shembull përgjigjeje
[
  {
    "Address": "Rruga Pavaresia, kodi postal 1050, Kashar 61",
    "Country": "ALB",
    "Name": "FONDACIONI VODAFONE ALBANIA",
    "Tin": "K72118452F",
    "Town": "Tirane"
  },
  {
    "Address": "Autostrada Tirane-Durres, Rruga Pavaresia, Nr.61, Kashar",
    "Country": "ALB",
    "Name": "VODAFONE ALBANIA",
    "Tin": "K11715005L",
    "Town": "Kashar"
  }
]
POST/utilities/get-operatorsListo operatorët · Kthen operatorët e biznesit dhe pajisjes së autentikuar.
Utilitetet#get-operators
Të detyrueshme
none
Rregullat
authenticated business + device

Fushat e kërkesës

FushaTipi
body{}

Fushat e përgjigjes

FushaTipi
[]Operator[]
[].namestring
[].opCodestring
Trupi i kërkesës
curl --request POST \
  --url 'https://api.dev.easypos.al/fiscalisation-service/v1/utilities/get-operators' \
  --header 'Authorization: Bearer {{accessToken}}' \
  --header 'Content-Type: application/json' \
  --header 'integration-app: your-client-name' \
  --data '{}'
Shembull përgjigjeje
[
  {
    "name": "test3",
    "opCode": "gh537ez280"
  },
  {
    "name": "User A",
    "opCode": "aa111aa222"
  }
]

06 · Referenca e fushave

Katalogu i skemave të API-së

Hapni një skemë për të parë çdo fushë, tipin e saktë, detyrimin dhe kufizimet e validimit.

RegisterInvoiceRequest22
FushaTipiDetyrimiRregullat
docIdstringE detyrueshme5–200 chars · unique per business document
operatorCodestringOpsionale^[a-z]{2}\d{3}[a-z]{2}\d{3}$
currencyCurrencyOpsionaledefault: ALL / 1
articlesArticle[]Me kushtrequired except SUMMARY · minItems: 1
paymentPayment[]Me kushtrequired except ORDER · minItems: 1
invoiceRebateRebateOpsionalepercentage or value, never both
buyerBuyerMe kushtrequired for eInvoice and EXPORT
correctiveInvoiceCorrectiveInvoiceRefMe kushtrequired for P9 / P10
invoiceNotesstringOpsionalemaxLength: 500
documentTypeenumOpsionaleNORMAL | ORDER | SUMMARY | SELFISSUE | EXPORT
selfIssueTypeenumMe kushtAGREEMENT | DOMESTIC | ABROAD | SELF | OTHER
reverseChargebooleanOpsionaletrue only for SELFISSUE
summaryInvoicesstring[]Me kushtSUMMARY only · minItems: 1 · each iic is 32 hex chars
totalnumberMe kushtSUMMARY only · exact referenced ORDER total
supplyPeriodobjectOpsionalestart/end in one calendar month
supplyPeriod.startstring(date)Me kushtYYYY-MM-DD
supplyPeriod.endstring(date)Me kushtYYYY-MM-DD
isEinvoicebooleanOpsionaledefault: false
selectedProcessenumOpsionaleP1–P11 · default: P1
selectedInvoiceTypestring(enum)Opsionale82 | 84 | 325 | 326 | 380 | 383 | 386 | 393 | 394 | 395 | 575 | 623 | 780
payDeadlinestring(date)OpsionaleYYYY-MM-DD · current year · not in the past
prepaidAmountnumberMe kushtrequired for P4 · >= 0 · max 2 decimals
Article8
FushaTipiDetyrimiRregullat
articleIdstringE detyrueshmemaxLength: 100
namestringE detyrueshmemaxLength: 100
vatCodestring(enum)E detyrueshmeA | B | C | D | E | F | G | H | I | J | K | L · must match the business fiscal configuration
pricenumberE detyrueshmeunit price including VAT
unitsnumberE detyrueshmequantity
soldInstringE detyrueshmeUN/CEFACT unit code, e.g. XPP | KGM | LTR | HUR
totalPricenumberOpsionaledefault: price × units
rebateRebateOpsionaleline-level discount
Rebate2
FushaTipiDetyrimiRregullat
inPercentagenumberMe kushtmutually exclusive with inValue
inValuenumberMe kushtmutually exclusive with inPercentage
Payment3
FushaTipiDetyrimiRregullat
typestring(enum)E detyrueshmeCASH | BANKNOTE | CARD | CHECK | SVOUCHER | COMPANY | ORDER | ACCOUNT | FACTORING | COMPENSATION | TRANSFER | WAIVER | KIND | OTHER
amountnumberE detyrueshmepayment sum must equal calculated invoice total
detailsPaymentDetail[]Me kushtrequired and non-empty for ACCOUNT
PaymentDetail7
FushaTipiDetyrimiRregullat
idNumberstringE detyrueshmeIBAN or account number
namestringE detyrueshmeaccount holder
bankNamestringE detyrueshmebank name
swift_codestringE detyrueshmeSWIFT / BIC
countrystringE detyrueshmecountry name
countryCodestringE detyrueshmeISO 3166-1 alpha-2 · exactly 2 chars
currencystringE detyrueshmeISO 4217 · exactly 3 chars
Buyer7
FushaTipiDetyrimiRregullat
buyerIDTypestring(enum)E detyrueshmeNUIS | ID | PASS | VAT | TAX | SOC | POINTS
buyerIDNumstringE detyrueshmewhen buyerIDType=NUIS: ^[A-Za-z][0-9]{8}[A-Za-z]$ · normalize to uppercase
buyerNamestringE detyrueshmebuyer legal/display name
buyerAddressstringE detyrueshmebuyer address
buyerTownstringE detyrueshmebuyer town
buyerCountrystringE detyrueshmeISO 3166-1 alpha-3, e.g. ALB
buyerCountryCodestringOpsionaleISO 3166-1 alpha-2 · default: AL
Currency2
FushaTipiDetyrimiRregullat
codestringOpsionaleISO 4217 · default: ALL
exRatenumberMe kushtrequired when code != ALL · rate against ALL
CorrectiveInvoiceRef2
FushaTipiDetyrimiRregullat
iicRefstringE detyrueshmeexisting invoice iic · 32 hex chars
issueDateTimestring(date)Opsionaledefaults to original invoice date
CancelInvoiceRequest9
FushaTipiDetyrimiRregullat
docIdstringE detyrueshmenew cancellation id · 5–200 chars
operatorCodestringOpsionale^[a-z]{2}\d{3}[a-z]{2}\d{3}$
correctiveInvoiceCorrectiveInvoiceRefE detyrueshmeiicRef points to original invoice
invoiceNotesstringOpsionalemaxLength: 500
isEinvoicebooleanOpsionaleinherits from original when omitted
selectedProcessenumOpsionaleP1–P11 · electronic default: P10
selectedInvoiceTypestring(enum)Opsionalesame values as RegisterInvoiceRequest
payDeadlinestring(date)OpsionaleYYYY-MM-DD
prepaidAmountnumberOpsionale>= 0 · max 2 decimals
StatusInvoiceRequest1
FushaTipiDetyrimiRregullat
docIdstringE detyrueshmesame invoice docId · 5–200 chars
InvoicePdfRequest4
FushaTipiDetyrimiRregullat
iicstringE detyrueshmeexactly 32 hexadecimal chars
pdfTypestring(enum)OpsionaleA4 | receipt | eInvoice · default: A4
paperWidthinteger(enum)Opsionale58 | 80 | 110 · receipt only · default: 80
langstring(enum)Opsionalesq | en
BalanceRequest4
FushaTipiDetyrimiRregullat
docIdstringE detyrueshme5–200 chars · unique per balance operation · no prescribed naming convention
amountnumberE detyrueshmeamount in ALL
notesstringOpsionaleoperation note
operatorCodestringOpsionale^[a-z]{2}\d{3}[a-z]{2}\d{3}$
GetTaxpayersRequest1
FushaTipiDetyrimiRregullat
searchTermstringE detyrueshmeNIPT or business name · 3–200 chars
InvoiceResponse21
FushaTipiDetyrimiRregullat
orderIdstringE detyrueshmeechoes request docId
ficstringMe kushtnormal completion identifier
eicstringMe kushtrequired with fic for electronic completion
iicstringMe kushtinvoice identifier · 32 hex chars
linkstring(uri)Opsionalepublic verification URL
errorFiscalErrorOpsionalepresent when incomplete or failed
invoiceNumberstringOpsionalefiscal invoice number
invoiceOrderNumberintegerOpsionalefiscal sequence number
invoiceTypestring(enum)OpsionaleCASH | NONCASH
totalPricenumberOpsionalegross total
totalPriceWithoutVatnumberOpsionalenet total
totalVatAmountnumberOpsionaleVAT total
taxFreeAmountnumberOpsionaletax-free total
goodsExportnumberOpsionaleexport amount
markUpAmountnumberOpsionalemarkup amount
operatorCodestringOpsionalefiscal operator code
businessUnitCodestringOpsionalefiscal business-unit code
tcrCodestringOpsionaleempty for electronic invoices
sellerNamestringOpsionaleseller name
sellerNuisstringOpsionaleseller NIPT
sellerAddressstringOpsionaleseller address
InvoiceIncompleteResponse2
FushaTipiDetyrimiRregullat
orderIdstringE detyrueshmeechoes request docId
errorFiscalErrorE detyrueshmefiscalization or eInvoice delivery has not completed
Error2
FushaTipiDetyrimiRregullat
messagestringE detyrueshmevalidation, authorization or domain error message
fieldstringOpsionalefield that failed validation
CisError3
FushaTipiDetyrimiRregullat
faultEnvstring(enum)Opsionaleenv:CLIENT | env:SERVER
faultStringstringOpsionalemessage returned by the tax platform
faultCodestringOpsionaletax-platform error code
FiscalError2
FushaTipiDetyrimiRregullat
cisErrorCisErrorOpsionaletax platform error
otherErrorstringOpsionaletemporary processing error
PdfResponse2
FushaTipiDetyrimiRregullat
base64stringE detyrueshmebase64 PDF or PNG
langstringOpsionaledocument language
EinvoicePdfResponse2
FushaTipiDetyrimiRregullat
base64stringE detyrueshmeofficial eInvoice PDF encoded as base64
eicstringE detyrueshmeelectronic invoice identifier
BalanceResponse3
FushaTipiDetyrimiRregullat
orderIdstringE detyrueshmeechoes request docId
fcdcstringMe kushtbalance-operation completion identifier
errorFiscalErrorOpsionaleprocessing error
Taxpayer5
FushaTipiDetyrimiRregullat
TinstringE detyrueshmetaxpayer NIPT
NamestringE detyrueshmeregistered name
AddressstringE detyrueshmeregistered address
TownstringE detyrueshmeregistered town
CountrystringE detyrueshmeISO 3166-1 alpha-3
Operator2
FushaTipiDetyrimiRregullat
namestringE detyrueshmeoperator display name
opCodestringE detyrueshmeuse as operatorCode in fiscal requests

Harta e kodeve të TVSH-së

vatCode varet nga statusi i TVSH-së dhe konfigurimi fiskal i biznesit, jo vetëm nga artikulli. Për një biznes subjekt të TVSH-së, kategoria standarde 20% është B; A është kategoria 0% për një biznes jo subjekt të TVSH-së.

KodiNormaTrajtimi fiskal
A0%Biznes jo subjekt i TVSH-së
B20%Norma standarde
C0%Furnizim i përjashtuar
D10%Norma e reduktuar
E6%Norma e reduktuar
J0%Eksport mallrash

API-ja aktualisht nuk e kthen këtë mapping. Ruajeni në konfigurimin e integrimit tuaj. Mos përdorni kode të tjera A–L pa një konfigurim fiskal të konfirmuar.

Pagesë e plotë ACCOUNT

details duhet të jetë listë jo bosh. Çdo element përshkruan një llogari bankare të shitësit dhe kërkon të shtatë fushat e paraqitura këtu.

Fragmenti i pagesës
{
  "payment": [
    {
      "type": "ACCOUNT",
      "amount": 10000,
      "details": [
        {
          "idNumber": "AL47212110090000000235698741",
          "name": "Shitësi SHPK",
          "bankName": "Banka XYZ",
          "swift_code": "ABCDEFGH",
          "country": "Shqipëri",
          "countryCode": "AL",
          "currency": "ALL"
        }
      ]
    }
  ]
}

Sqarime operacionale

FushaRregullat
buyerIDNum · NUISFormati i pranuar: një shkronjë, tetë shifra, një shkronjë (^[A-Za-z][0-9]{8}[A-Za-z]$). Normalizojeni në shkronja të mëdha. Kontrata nuk përfshin format tjetër të vjetër NIPT-i.
get-taxpayersCountry përdor ISO 3166-1 alpha-3 (ALB për Shqipërinë). Përgjigjja nuk ka fushë për statusin aktiv, pasiv ose të çregjistruar; përdoreni endpoint-in për kërkim dhe plotësim të të dhënave të blerësit, jo si verifikim përfundimtar të statusit tatimor.
Kufizimi i kërkesaveAktualisht nuk është publikuar një kufi numerik. Përdorni debounce gjatë kërkimit dhe mos dërgoni kërkesë për çdo tast të shtypur.
balance/initiateDërgoni një hapje gjendjeje të suksesshme për çdo ditë pune dhe pajisje fiskale/TCR të autentikuar, para faturës së parë me para në dorë. Turni i aplikacionit nuk është kufiri fiskal dhe nuk ka endpoint për mbylljen e gjendjes.
docId e gjendjesVlerat SHIFT-… janë vetëm shembuj. Përdorni çdo identifikues të qëndrueshëm unik me 5–200 karaktere dhe ripërdoreni vetëm për të rikuperuar të njëjtin veprim gjendjeje.
Kodet e njësive matëseShkarkoni listën e njësive matëse të mbështetura dhe përdorni vlerën e kodit si soldIn, p.sh. XPP, KGM, LTR ose HUR.Shkarko listën e njësive (.xlsx)
Vlerat enum të lejuara
soldIn
XPP · KGM · LTR · HUR · other UN/CEFACT unit codes
vatCode
A · B · C · D · E · F · G · H · I · J · K · L
payment.type
CASH · BANKNOTE · CARD · CHECK · SVOUCHER · COMPANY · ORDER · ACCOUNT · FACTORING · COMPENSATION · TRANSFER · WAIVER · KIND · OTHER
buyerIDType
NUIS · ID · PASS · VAT · TAX · SOC · POINTS
selectedProcess
P1 · P2 · P3 · P4 · P5 · P6 · P7 · P8 · P9 · P10 · P11
selectedInvoiceType
82 · 84 · 325 · 326 · 380 · 383 · 386 · 393 · 394 · 395 · 575 · 623 · 780
selfIssueType
AGREEMENT · DOMESTIC · ABROAD · SELF · OTHER
pdfType
A4 · receipt · eInvoice

07 · Kriteret e përfundimit

Kontrolloni identifikuesit para se ta konsideroni operacionin të përfunduar

Një përgjigje HTTP e suksesshme mund të përshkruajë një operacion ende të papërfunduar. Ruani përgjigjen dhe vendosni sipas identifikuesve të kthyer.

OperacioniPërfundon kurKur nuk ka përfunduar
Faturë normale / anulimekziston ficRikuperoni me të njëjtin docId.
Faturë elektronike / anulimekzistojnë fic dhe eicKontrolloni statusin me të njëjtin docId.
Transaksion arkeekziston fcdcRiprovoni të njëjtin operacion dhe docId.
PDFekziston base64Riprovoni pasi fatura burim të përfundojë.

Tabela e vendimit për gabimet

ErrorMund të riprovohetVeprimi
400 validim / fushëJoKorrigjoni kërkesën; fushat e panjohura refuzohen.
401 UnauthorizedPas kredencialeveRinovoni token-in e mjedisit dhe ruani docId.
cisError env:CLIENTJoKorrigjoni së pari të dhënat fiskale ose kërkesën.
cisError env:SERVER / otherErrorPoPritni dhe rikuperoni me të njëjtin docId.
Timeout / lidhje / 502 / 503PoKontrolloni fillimisht statusin; ridërgoni vetëm kur dokumenti nuk gjendet.
Po përpunohet kërkesë tjetërPo, më vonëNdalni kërkesat paralele, prisni dhe kontrolloni statusin.

08 · Skedarët burim

E njëjta kontratë në mjetet tuaja

Faqja është referenca e lexueshme. Skedarët shkarkohen drejtpërdrejt për gjeneratorë, klientë API dhe agjentë programimi.

Ju duhet kredencial integrimi ose sqarim i kontratës?

easyPos Cloud API