New product · Beta · Saga API
FROMVeziv IT Services, Bucharest
TOYour company

Saga API: SAGA Web, connected to any program

SAGA Web has no public API, so invoices from the shop, customers from the CRM and stock from the warehouse get typed in by hand a second time. Saga API connects SAGA Web to any program: it reads and writes directly in the accounting, with the SAGA rules kept in place.

Democoming soon

We are preparing a public demo, with the interactive docs connected to a SAGA test company. Until then we show you Saga API live in a meeting.

Saga API demo · coming soon

How it works

What goes into the module, what happens there and where the data goes next.

What comes in

  • Orders and customersthe online shop
  • Partners and quotesCRM or ERP
  • Supplier invoicespurchasing or e-Factura
  • Production ordersthe workshop
Saga API: SAGA Web, connected to any programVZV

What the module does

  1. 01Receives the request, with the company's API key
  2. 02Writes to SAGA Web with the SAGA validation rules
  3. 03Validates the document: stock and journal entries
  4. 04Returns the result calculated by SAGA

What goes out, and where

  • Validated invoices, NIRs, transfersSAGA Web
  • Up-to-date stock and pricesshop and ERP
  • Receivables, due dates, reportsdashboards and BI
  • Synced partnersCRM

Your invoicing program, your online shop and your CRM know about orders, customers and stock. SAGA knows the accounting. Between them sits a person who copies: the invoice from the shop goes into SAGA a second time, the new customer from the CRM is typed in again, and the stock on the website is yesterday's.

Saga API gives the accounting in SAGA Web an API. Your programs ask for and send data through a web address and a key, and SAGA takes them in like documents entered by hand: it checks them, validates them, moves the stock and makes the journal entries.

What you get

  • Over 650 operations on almost 200 tables in SAGA Web: customers, suppliers, items, warehouses, chart of accounts, issued and received invoices in lei and foreign currency, transfers, consumption notes, production, stocktaking, fixed assets, employees.
  • Validation as in SAGA. Validation becomes an API call: the stock moves, the journal entries are made automatically, and unvalidating cancels them.
  • Totals calculated by SAGA. You send the quantity and the price, and SAGA works out the value, the VAT, the total and the partner's analytic account.
  • Reports at hand. VAT journals, D300 (the VAT return), D394 (the domestic sales and purchases return), SAF-T, balance sheet, account sheets, stock and sales reports, due-date schedule.
  • Ready-made lists. About 290 SAGA lists (counties, towns, units of measure, warehouses), so the data you send is correct.
  • Interactive documentation. Swagger with complete examples for every endpoint and a test environment separate from production.

What is still in beta

  • Receipts and payments, payment orders, cheques, compound journal entries, payroll sheets, orders and contracts can be read through the API; writing them comes in the next versions.
  • e-Factura and e-Transport submission stays in SAGA; through the API you read the status and the replies from SPV (ANAF's online portal).
Demo requestVZV-NOU

Real flows, end to end

What a real integration looks like, step by step, with the exact calls. Each flow starts in another program and ends up in SAGA Web.

An order from the online shop becomes an invoice in SAGA01
  1. paid order
  2. x-api-key
  3. stock reduced, journal entries made
  1. 1Is the customer already in SAGA? You look them up by tax ID (CUI).GET /api/clienti?cauta=RO123&mod=exact
  2. 2If not, you add them. The analytic account is created automatically.POST /api/clienti
  3. 3You find each product by code or barcode.GET /api/articole?cauta=SKU
  4. 4You create the invoice: number, customer, date, due date.POST /api/iesiri
  5. 5You add the lines: product, warehouse, quantity, price, VAT.POST /api/iesiri/detalii?masterId={id}
  6. 6You check the totals calculated by SAGA.GET /api/iesiri/{id}
  7. 7You validate: stock goes down and the journal entries are made.POST /api/iesiri/{id}/validare
  8. 8You send the new stock level back to the shop.GET /api/articole/{cod}
The catalogue and stock from SAGA reach the shop or the ERP02
  1. items, prices, stock
  2. x-api-key
  3. up-to-date catalogue
  1. 1You read all the items: code, name, price, VAT, barcode, stock.GET /api/articole?toate=true
  2. 2You get the warehouses and groups, to match them with your own categories.GET /api/gestiuni · GET /api/grupe/articole
  3. 3You repeat this every few minutes: only stock and prices change.GET /api/articole?coloane=Cod,Stoc,PretVanzare
Partners from the CRM or ERP, kept in sync with SAGA03
  1. new or changed customer
  2. x-api-key
  3. with analytic account
  1. 1You read the customers and suppliers already in SAGA.GET /api/clienti?toate=true
  2. 2You get the correct values for county and town.GET /api/liste/Judet · GET /api/liste/Localitate
  3. 3You add the new customer; the code is assigned automatically if you don't give one.POST /api/clienti
  4. 4When the address or bank account changes, you send only the changed field.PATCH /api/clienti/{cod}
The supplier invoice becomes a NIR in SAGA04
  1. from e-Factura or purchasing
  2. x-api-key
  3. stock increased, 371 = 401
  1. 1You look up the supplier by tax ID; if it is missing, you add it.GET /api/furnizori?cauta=RO456 · POST /api/furnizori
  2. 2You find or add the items on the invoice.GET /api/articole · POST /api/articole
  3. 3You create the purchase invoice.POST /api/intrari
  4. 4You add the lines: goods on account 371 or services on 628.POST /api/intrari/detalii?masterId={id}
  5. 5You validate: stock goes up and the journal entries are made.POST /api/intrari/{id}/validare
Production: from raw materials to finished product05
  1. from the workshop or the ERP
  2. x-api-key
  3. materials consumed
  1. 1You move the raw materials to the production warehouse.POST /api/transferuri · /detalii · /validare
  2. 2You read the product recipe.GET /api/articole/retete?masterId={produs}
  3. 3You record the production and the materials consumed according to the recipe.POST /api/productie · POST /api/productie/detalii
  4. 4You validate: the materials go out, the finished product goes into stock.POST /api/productie/{id}/validare
Who owes you money: receivables, on one dashboard06
  1. unpaid invoices
  2. x-api-key
  3. due dates and overdue amounts
  1. 1You read the issued invoices, with the unpaid amount and the due date.GET /api/iesiri?toate=true
  2. 2You see which receipts are already matched to each invoice.GET /api/iesiri/incasari
  3. 3You do the same for suppliers: what you have to pay.GET /api/intrari · GET /api/intrari/plati

Everything you can do through Saga API

Over 650 operations, on almost 200 tables in SAGA Web. We grouped them by what you do in the company, each one explained in plain words.

read and writereadread · writing is coming

Customers and suppliersPartner records, with the analytic account created automatically6
  • GET POST PATCH DELETE/api/clientiread and write

    Customers: name, tax ID (CUI), address, county, bank account, phone, e-mail, group. When you add one, the 4111 analytic account is created automatically.

  • GET POST PATCH DELETE/api/furnizoriread and write

    Suppliers, with the same data. When you add one, the 401 analytic account is created automatically.

  • GET/api/clienti/urmatorul-codread

    The next free code, so you don't have to guess codes.

  • GET POST PATCH DELETE/api/agentiread and write

    Sales agents.

  • GET POST PATCH DELETE/api/grupe/clienti · /api/grupe/furnizoriread and write

    Partner groups.

  • GET/api/situatii-terti/…read

    Reports by partner: opening and closing balance, invoices, due-date schedule with days overdue, uninvoiced delivery notes, advances.

Items, warehouses and chart of accountsThe company's item list, with current stock7
  • GET POST PATCH DELETE/api/articoleread and write

    Items: name, unit of measure, VAT, type, group, sale price with and without VAT, barcode, NC (customs) and CPV codes. When you read them you also get the current stock.

  • GET/api/articole/oferta · /api/articole/eticheteread

    The price list for quotes and the barcode labels.

  • GET POST PATCH DELETE/api/articole/reteteread and write

    Production recipes: which components go in and in what quantity.

  • GET POST PATCH DELETE/api/tipuri-articoleread and write

    Item types and their stock, expense and income accounts.

  • GET POST PATCH DELETE/api/gestiuniread and write

    Warehouses: name, type, storekeeper, valuation method.

  • GET POST PATCH DELETE/api/grupe/articole · /activitati · /proiecteread and write

    Item groups, activities (with their CAEN activity code) and projects.

  • GET POST PATCH DELETE/api/plan-conturiread and write

    Chart of accounts: account, name, type, closing account, blocked or not.

Received invoices (purchases, NIR)In lei and in foreign currency, with validation5
  • GET POST PATCH DELETE/api/intrariread and write

    The supplier invoice header: number, supplier, date, due date, cash-basis VAT. You get back the value, the VAT, the total and how much is still unpaid.

  • GET POST PATCH DELETE/api/intrari/detaliiread and write

    Invoice lines: item or service, warehouse, quantity, price, VAT, account, batch. The values are calculated automatically.

  • POST/api/intrari/{id}/validare · /devalidareread and write

    Validating the document in SAGA: stock goes up and the journal entries are made. Unvalidating cancels them.

  • GET/api/intrari/platiread

    Payments already matched to the invoice.

  • GET POST PATCH DELETE/api/intrari-valuta (+ /detalii, /validare)read and write

    Invoices in foreign currency: currency, exchange rate, customs duties, fees, excise duties.

Issued invoices (sales)In lei and in foreign currency, with validation5
  • GET POST PATCH DELETE/api/iesiriread and write

    The customer invoice header: number, customer, date, due date, e-Factura flag. You get back the value, the VAT, the total, what is still unpaid and the markup.

  • GET POST PATCH DELETE/api/iesiri/detaliiread and write

    Invoice lines: item, warehouse, quantity, price, VAT, account.

  • POST/api/iesiri/{id}/validare · /devalidareread and write

    Validation: stock goes down and the journal entries are made.

  • GET/api/iesiri/incasariread

    Receipts already matched to the invoice.

  • GET POST PATCH DELETE/api/iesiri-valuta (+ /detalii, /validare)read and write

    Invoices in foreign currency, with currency and exchange rate.

e-FacturaWhat was sent and what came back from SPV3
  • GET/api/e-factura/e-fact-generare-si-transmitereread

    Invoices with their e-Factura status.

  • GET/api/e-factura/e-fact-raspunsuriread

    Replies from SPV: the receipt and the message type.

  • GET/api/e-factura/e-fact-import…read

    Issued and received invoices downloaded from SPV, with their lines.

Stock and productionThe documents that move goods, with validation7
  • GET POST PATCH DELETE/api/transferuri (+ /detalii, /validare)read and write

    Transfers between warehouses.

  • GET POST PATCH DELETE/api/bonuri (+ /detalii, /validare)read and write

    Consumption notes.

  • GET POST PATCH DELETE/api/productie (+ /detalii, /comenzi, /validare)read and write

    Production: the finished product, the materials consumed and the production orders.

  • GET POST PATCH DELETE/api/inventariereread and write

    Stocktaking: surpluses, shortages and differences.

  • GET POST PATCH DELETE/api/bonuri-oi/…read and write

    Small inventory items put into use and written off.

  • GET POST PATCH DELETE/api/operatii-speciale · /api/reglari-descarcareread and write

    Special operations and stock release adjustments.

  • GET/api/fise-articole · /api/situatii-stocuri · /api/situatii-vanzari · …read

    Item record, stock by warehouse, purchases, sales with markup, consumption, production, SGR packaging (deposit-return), the warehouse report.

Cash, bank and paymentsBalances, receipts, payments, cheques5
  • GET POST PATCH DELETE/api/registru-casa/solduriread and write

    Daily cash and bank balances.

  • GET/api/registru-casa/casaread · writing is coming

    Cash, bank and expense report entries, with amount, currency, exchange rate, description.

  • GET/api/registru-casa/casa-detaliiread

    Which invoices each receipt or payment settled.

  • GET/api/jurnal-de-banca/opread · writing is coming

    Payment orders: payer, beneficiary, IBAN, amount.

  • GET/api/cecuri · /api/situatii-cecuri/…read · writing is coming

    Cheques and promissory notes, received and issued.

Journal entries, registers and month-end closeEverything that comes out of the accounting6
  • GET/api/registruread · writing is coming

    Journal entries: date, debit account, credit account, amount, description.

  • GET POST PATCH DELETE/api/inregistrare-cheltuieli-venituriread and write

    Prepaid expenses and deferred income.

  • GET/api/fise-conturi/… · /api/carte-mare/…read

    Account sheets and the general ledger.

  • GET/api/registru-jurnal · /api/registru-inventarread

    The journal register and the inventory register.

  • GET/api/inchidere-luna/…read

    Month-end close: profit tax or micro-company income tax, D100, D101, exchange differences.

  • GET/api/situatii-managerialeread

    Costs, income and profit for each activity.

VAT, tax returns and balance sheetData from the journals, SAF-T and the financial statements6
  • GET/api/jurnal-cumparari-vanzari/…read

    Purchase and sales journals, D300, D301, D394, D390 and OSS.

  • GET/api/saft/…read

    The SAF-T (D406) sections: chart of accounts, partners, products, stock, assets, journal, payments.

  • GET/api/bilant/…read

    The balance sheet: profit and loss account, informative data, explanatory notes, fixed assets.

  • GET/api/declaratia-intrastat/…read

    Intrastat, for arrivals and dispatches.

  • GET POST PATCH DELETE/api/declaratia205 (+ /detalii, /salariati)read and write

    The data for D205.

  • GET POST PATCH DELETE/api/e-transport (+ /detalii)read and write

    The data for e-Transport, with the UIT code and the status.

Employees and payrollStaff records and payroll sheets4
  • GET POST PATCH DELETE/api/salariati (+ /intretinuti, /zilieri)read and write

    Employees: name, COR occupation code, job title, hire date, working hours, dependants and day labourers.

  • GET/api/state-salarii/…read · writing is coming

    Payroll sheets: gross, net, contributions, for permanent staff and day labourers.

  • GET POST PATCH DELETE/api/configurare-salarii/…read and write

    Overtime, bonuses and allowances.

  • GET POST PATCH DELETE/api/diurne · /api/actionariread and write

    Per diems and shareholders.

Orders and contractsWhat was ordered and what is invoiced regularly3
  • GET/api/comenzi/… · /api/situatii-comenziread · writing is coming

    Orders, with deliveries, days late and the invoice.

  • GET/api/contracte/… · /api/contracte/rateread · writing is coming

    Contracts, with the instalments and the invoices to generate.

  • GET POST PATCH DELETE/api/contracte/tipuri-contracteread and write

    Contract types.

Fixed assets and vehiclesFixed assets, depreciation, vehicle fleet3
  • GET POST PATCH DELETE/api/imobilizari (+ /operatiuni-imobilizari)read and write

    Fixed assets: inventory number, class, value, useful life, depreciation method, accounts and the operations on them.

  • GET/api/imobilizari/plan-de-amortizare · /registrul-imobilizarilorread

    The depreciation schedule and the fixed asset register.

  • GET POST PATCH DELETE/api/masini (+ /foi-parcurs, /asigurari-revizii)read and write

    Vehicles, trip logs, insurance and servicing.

UtilitiesWhat you need to work comfortably2
  • GET/api/liste/{lista}read

    Values from the SAGA lists (about 290): counties, towns, units of measure, warehouses, items.

  • POST/api/fluxuri/aprovizionare · /vanzare · /transfer · /productieread and write

    Complete scenarios in a single call, with full rollback (/api/fluxuri/anulare). Good for tests and demos.

How it connects to SAGA

You install nothing. We connect your company to Saga API once, and your applications get an API key.

  1. 01We connect the company

    We link your company in SAGA Web to Saga API, with your consent. We do it once, and Saga API lets you know in good time if the connection needs renewing.

  2. 02You get the API key

    Your applications send the key with every request. Without the key, Saga API does not answer, and the only websites that can call it from the browser are the ones you approve.

  3. 03Test and production

    You can connect a test company and the real company in parallel and choose on each request where you write. Production asks for an extra confirmation.

  4. 04Interactive documentation

    Every endpoint has complete examples in Swagger (OpenAPI): you try it from the browser before you write a line of code.

  5. 05Several companies

    Each company has its own connection, separate from the others. An accounting firm or a group connects as many companies as it needs.

  • The SAGA validation rules stay active: if SAGA refuses an operation, the response tells you why.
  • SAGA calculates the totals, the VAT and the analytic accounts, not your application.
  • Validated documents can also be unvalidated and deleted through the API, so you can correct a mistake.

Frequently asked questions

Does SAGA have an API?

SAGA Web does not offer a public API for your programs. Saga API gives you one: documented REST endpoints, with over 650 operations on almost 200 tables in SAGA Web.

Does it work with SAGA installed on a computer?

No. Saga API works with SAGA Web, the online version. If you use SAGA on a computer, ask us how to move to SAGA Web.

What do I need to install in SAGA?

Nothing. We connect your company in SAGA Web to Saga API once, with your consent, and your applications get an API key. We set up the rest.

Can the accounting data get damaged?

The SAGA validation rules stay active: SAGA checks every document just as when you work on screen and refuses anything that is not correct. You can connect a test company in parallel, and validated documents can be unvalidated and deleted through the API.

What can it not do yet?

In beta, receipts and payments, payment orders, compound journal entries, payroll sheets, orders and contracts can be read through the API, but not written yet. e-Factura submission stays in SAGA.

How much does it cost?

It depends on how many companies you connect and on the integration you need (shop, ERP, CRM, reports). Ask for a demo and we will show you Saga API on the SAGA test company.