Transaction summary (670)
Browse code 670 (BrowseCode::TransactionSummary, “Transactieoverzicht”): the number of transactions and transaction lines per day book and period. Use it to see how much data a period has before you download it, or to check a shadow database.
Twinfield documentation: Browse data.
fin.trs.head.countandfin.trs.line.countare numbers:int().fin.trs.head.inpdateis a criterion only:betweenDateTimes('fin.trs.head.inpdate', $from, $to)counts the transactions entered in that time.- The rows are totals:
$row->transactionLineis null.
Criteria: period and input date. See browse-definitions/670.xml and the browse data guide.
Fields
Section titled “Fields”All fields of the browse definition (browse-definitions/670.xml), with the label for a Dutch user, the data type and the values of a field with a fixed list (browsefields.xml). A field that is not visible is meant as criterion: asking for it as column can give a server error. Twinfield does not apply the proposed values: send every criterion you need.
| Field | Label | Type | Visible | Criterion |
|---|---|---|---|---|
fin.trs.head.office |
Administratie | string | yes | |
fin.trs.head.officename |
Adm.naam | string | yes | |
fin.trs.head.code |
Dagboek | string | yes | |
fin.trs.head.yearperiod |
Jaar/periode (JJJJ/PP) | string | yes | between |
fin.trs.head.count |
Aantal transacties | long | yes | |
fin.trs.head.inpdate |
Invoerdatum | datetime | no | between |
fin.trs.line.count |
Aantal transactie regels | long | yes |
$twinfield = Example::twinfield();
$year = (int) ($argv[1] ?? Example::lastYear($twinfield));
$query = $twinfield->browse(BrowseCode::TransactionSummary) ->columns( 'fin.trs.head.yearperiod', 'fin.trs.head.code', 'fin.trs.head.count', 'fin.trs.line.count', ) ->between('fin.trs.head.yearperiod', sprintf('%d/00', $year), sprintf('%d/55', $year));
$result = $query->get();
echo count($result), ' day book(s) and period(s) in ', $year, PHP_EOL;
$transactions = 0;$lines = 0;
foreach ($result as $index => $row) { $transactions += $row->int('fin.trs.head.count'); $lines += $row->int('fin.trs.line.count');
echo sprintf( '[%d/%d] %s %s: %d transaction(s), %d line(s)', $index + 1, count($result), $row->period('fin.trs.head.yearperiod'), $row->string('fin.trs.head.code'), $row->int('fin.trs.head.count'), $row->int('fin.trs.line.count'), ), PHP_EOL;}
echo 'Total: ', $transactions, ' transaction(s), ', $lines, ' line(s)', PHP_EOL;php examples/browse-data/670-transaction-summary/example.php # the last yearAdd TWINFIELD_DEBUG=1 to see the SOAP requests and responses.
3 day book(s) and period(s) in 2026[1/3] 2026/01 VRK: 12 transaction(s), 36 line(s)[2/3] 2026/01 BNK: 1 transaction(s), 24 line(s)[3/3] 2026/02 VRK: 9 transaction(s), 27 line(s)Total: 22 transaction(s), 87 line(s)What the SDK sends to Twinfield and what Twinfield sends back, for a call like the one in this example. The responses come from the tests, with example data.
Compose the browse request and send it
Section titled “Compose the browse request and send it”Twinfield documentation: Browse data: Compose the browse request and send it.
$twinfield->browse(BrowseCode::TransactionSummary) ->columns( 'fin.trs.head.yearperiod', 'fin.trs.head.code', 'fin.trs.head.count', 'fin.trs.line.count', ) ->between('fin.trs.head.yearperiod', '2026/00', '2026/55') ->get();The SDK sends this XML as xmlRequest of ProcessXmlString to processxml.asmx:
<columns code="670" optimize="true"> <column> <field>fin.trs.head.yearperiod</field> <visible>true</visible> <operator>between</operator> <from>2026/00</from> <to>2026/55</to> </column> <column> <field>fin.trs.head.code</field> <visible>true</visible> </column> <column> <field>fin.trs.head.count</field> <visible>true</visible> </column> <column> <field>fin.trs.line.count</field> <visible>true</visible> </column></columns>Twinfield answers with this XML in ProcessXmlStringResult:
<browse result="1" first="1" last="3" total="3"> <th> <td label="" hideforuser="false" type="String">fin.trs.head.yearperiod</td> <td label="" hideforuser="false" type="String">fin.trs.head.code</td> <td label="" hideforuser="false" type="Number">fin.trs.head.count</td> <td label="" hideforuser="false" type="Number">fin.trs.line.count</td> </th> <tr> <td>2026/01</td> <td>VRK</td> <td>12</td> <td>36</td> <key> <office>1000</office> </key> </tr> <tr> <td>2026/01</td> <td>BNK</td> <td>1</td> <td>24</td> <key> <office>1000</office> </key> </tr> <tr> <td>2026/02</td> <td>VRK</td> <td>9</td> <td>27</td> <key> <office>1000</office> </key> </tr></browse>Source
Section titled “Source”View examples/browse-data/670-transaction-summary/example.php on GitHub.
Twinfield and Wolters Kluwer are trademarks of Wolters Kluwer. Their names and logos are used only to refer to their products.