ontoloji.orgOpen Reference Hub
ERP Write-Safety12 min read·Updated: 2026-12-03·Türkçe sürüm →

Logo Objects REST, Nebim V3 Integrator & GİB UBL-TR e-Document Write-Safety for AI Agents

Why direct SQL writes corrupt Logo Tiger/GO and Nebim V3 ledgers and Turkish e-Invoice locks—and how to architect safe kinetic AI actions over official business-object APIs and UBL-TR 1.2.1 Schematron gates.

Executive Summary — Key Takeaways
  • 01Never execute direct SQL INSERT or UPDATE statements against Logo Tiger (INVOICE, STFICHE) or Nebim V3 tables; bypassing business-object layers corrupts stock allocations, AR/AP totals, and GİB e-document locks (ESTATUS, EDESPSTATUS).
  • 02Nebim V3 Integrator’s Connect endpoint can return HTTP 200 ("Connection Created Successfully") even on bad credentials—always verify sessions immediately with GetUserInfo and account for NebimPassport.pass (19.10.1+) and .NET 9 IIS hosting (25.10.1).
  • 03Every kinetic AI action that creates an invoice or dispatch note in Turkey must pass a deterministic UBL-TR 1.2.1 XSD + GİB Schematron pre-flight gate and human approval before calling the ERP API.

1. Why Direct SQL Corrupts Logo Tiger/GO: Logo Objects REST (:32001) & e-Logo Status Locks

In Logo Tiger 3, Tiger Enterprise, and GO 3 databases, informal "lock-opening" SQL scripts such as UPDATE LG_001_01_INVOICE SET ESTATUS = 0 or UPDATE LG_001_01_STFICHE SET EDESPSTATUS = 0 sever the state link between ERP slips and envelopes already transmitted to Turkey’s Revenue Administration (GİB) via e-Logo or Logo Connect. Mutating EARCHIVEDET.EARCHIVESTATUS in SQL creates the same reconciliation drift.

Even read-side attachment helpers fail without ontology constraints: querying INVOICE.GUID by LOGICALREF to pull an e-Logo PostBoxService.svc PDF without filtering TRCODE = 8 (wholesale sales invoice) can silently retrieve a purchase invoice (TRCODE = 1) sharing the same integer key. AI agents must read through typed ontology views and route all mutations through official business-object interfaces.

  • Logo Objects REST Service (:32001/api/v1): Stateless HTTP/JSON interface authenticated via POST /api/v1/token with Firmno; enforces slip numbering, VAT calculation, and ledger posting rules.
  • Unity Objects COM (LObjects.exe / UnityApplication): 32-bit in-process Windows COM engine; isolate behind a serialized single-worker queue rather than invoking COM apartments concurrently from async agent loops.
  • e-Logo Polling Hygiene: Respect the recommended <=60 requests/minute ceiling (500 ms pacing) when reconciling GİB status codes (1200 Processing, 1210 Completed, 1220 Approved, 1230 Rejected, 1240 Cancelled).

2. Nebim V3 Integrator API: False-200 Connect, ModelType 0–234 & Runtime Licensing

For Nebim V3, the sanctioned external write and procedural read surface is the IIS-hosted Nebim V3 Integrator (IntegratorService) REST/JSON API—using RunQuery (ModelType = 32) and RunProc (ModelType = 33) for registered reads, and POST with a numeric ModelType for creating cards and slips.

While official Integrator manuals document 10 core models (1 Connect, 2–3 Customers, 4 Product, 5–6 Orders, 7–8 Invoices, 32 Query, 33 Procedure), production runtimes expose enum values 0 through 234 (including 59 StoreTransfer, 84 DispatchOrderWS, 109 InnerWT, and 208 OnlineInstallmentPayment). Production agent connectors must handle four operational gotchas:

  • False-Positive Connect Reply: IntegratorService/Connect returns "Status": "Connection Created Successfully" even when credentials fail. Always call GetUserInfo immediately afterwards to confirm CompanyCode, OfficeCode, StoreCode, and WarehouseCode.
  • IIS Session (InProc) vs. Token (Off) Mode: Session URLs embed /(S(<session-id>))/ in the path and fail with "Attempting to deserialize an empty stream." after idle timeouts; token mode passes a Token header instead.
  • Concurrent User & Per-Movement License Checks: Connections consume Office User or Store User seats, and since release 18.4.1, every POST validates module-specific licenses (such as multi-currency offices) before committing.
  • Platform Milestones (19.10.1 & 25.10.1): SQL Server connections require the NebimPassport.pass certificate from 19.10.1 onward, while 25.10.1 migrates IIS web apps to .NET 9 and sunsets SOVOS (FIT) e-document integration in favor of active partners such as eFinans, Edoksis, Doğan e-Dönüşüm, and Uni-Dox.

3. GİB UBL-TR 1.2.1 Schematron Pre-Flight Gates & Human-in-the-Loop Execution

Posting an invoice or dispatch note in a Turkish ERP triggers legally binding OASIS UBL 2.1 (CustomizationID = TR1.2) envelopes (Invoice, DespatchAdvice, ReceiptAdvice, ApplicationResponse). Before an AI agent hands a payload to Logo Objects REST or Nebim V3 Integrator, a deterministic pre-flight gate must validate regulatory invariants.

Deterministic UBL-TR + ERP API pre-flight pipeline for kinetic ontology actions
Agent Action Request: create_return_invoice(draft_payload)
  │
  ├─ 1. Scenario & Type Rule : ProfileID == "TICARIFATURA" && InvoiceTypeCode == "IADE"
  │                            -> REJECT (IADE invoice type is forbidden under TICARIFATURA!)
  ├─ 2. Mandatory Extensions : Purchase return requires BillingReference/InvoiceDocumentReference
  │                            (ID, IssueDate, DocumentTypeCode — Nebim V3 25.4.1+ rule)
  ├─ 3. Inventory Integrity  : Verify OrderLineID chain & sp_ValidateItemInventory* checks
  └─ 4. Human Approval Gate  : Present structured diff to finance/ops reviewer -> On sign-off,
                               dispatch via Logo Objects REST (:32001) or Nebim Integrator POST.
Golden Rule: Query via Read-Only Views, Mutate Only via Approved Business Objects

Use governed read-only SQL views for sub-second analytics, and route every order, dispatch, invoice, or ledger write through human sign-off + UBL-TR validation + official ERP business-object APIs.

Glossary Concepts Referenced in This Guide

Open License (CC BY 4.0) · Cite This Page

Free to reference in engineering docs, ADRs, articles, and course syllabi with attribution.

[Logo Objects REST, Nebim V3 Integrator & GİB UBL-TR e-Document Write-Safety for AI Agents — Ontoloji.org](https://ontoloji.org/en/guides/logo-objects-rest-nebim-v3-integrator-ubl-tr-ai-write-safety)

More Guides in This Series

Core Architecture
How AI Uses an Ontology
9 min read
Agent Engineering
Agent Harness vs. Ontology
8 min read
Data Engineering
ERP, CRM & MES Patterns
10 min read
Strategy & Governance
30-Day Ontology Strategy
7 min read
ERP Integration
ERP Ontology Integration Guide
11 min read
ERP Data Engineering
Logo Tiger, Nebim V3 & Turkish Unicode Traps
14 min read
Agent Governance
Adversarial Verification, Permissions & Compaction
13 min read
Verification Engineering
Absence-Aware Gates & Ratio Reconstruction
13 min read
Provenance & Governance
Draft vs. Normative Provenance Hygiene
12 min read
SAP & Protocol Architecture
SAP BTP, Cloud Connector & ORD Ontology
11 min read
Platform Architecture Comparison
Cortex, Genie, dbt & Cube vs. Ontology
12 min read
Systems Engineering & Forensics
ERP Integrator Anti-Patterns & Forensics
13 min read
Platform Architecture Comparison
Fabric IQ, D365 MCP & SAP Joule vs. Ontology
12 min read
Retrieval & RAG Architecture
PageIndex Vectorless Tree RAG vs. Vector DBs
11 min read
Platform Architecture Comparison
Atlan, Stardog & Neo4j vs. Ontology
12 min read
Statutory & Financial Governance
GİB UBL-TR, VUK/TMS 29 & KVKK Ontology
13 min read
Agent Memory & Ontology Architecture
Cognee & Zep Graphiti vs. Ontology
11 min read
Protocol & Multi-Agent Architecture
MCP vs. OpenAPI & Specialist Agents
12 min read
Protocols & Standards
MCP 2026-07-28: Tasks, Events & Apps
13 min read
Agent Architecture & Governance
Agent Harness Engineering Rubric
12 min read
Agent Architecture & Governance
Multi-Agent Task Boards & Mailboxes
12 min read
Verification & Security
Generate-Evaluate-Repair & Observers
12 min read
Verification & Security
NSA MCP Security & CIMD vs. DCR
13 min read
Agent Architecture & Governance
OpenTelemetry for AI Agents & MCP
11 min read