HostFact API versie 3.1
Groepen
Debiteurgroepen, crediteurgroepen en productgroepen zijn te beheren via de controller 'group'.
list
Middels deze functie kunt u een lijst met groepen ophalen van een specifiek type.
Voorbeeldbestand: /voorbeelden/group/group.list.php
Invoerparameters:
Veldnaam | Waarde | Omschrijving |
---|---|---|
offset | int | Standaard: 0 |
limit | int | Standaard: 1000 |
type | 'debtor', 'creditor' of 'product' | Type groep |
Voorbeeld invoer:
<?php require_once("../hostfact_api.php"); $api = new HostFactAPI(); $groupParams = array( 'type' => 'product' ); $response = $api->sendRequest('group', 'list', $groupParams); print_r_pre($response); ?>
Voorbeeld uitvoer:
Array ( [controller] => group [action] => list [status] => success [date] => 2022-11-24T12:00:00+02:00 [totalresults] => 3 [currentresults] => 3 [offset] => 0 [filters] => Array ( [type] => product ) [groups] => Array ( [0] => Array ( [Identifier] => 1 [GroupName] => Domeinnamen bestelformulier [Type] => product [Items] => Array ( [0] => 2 ) ) [1] => Array ( [Identifier] => 2 [GroupName] => Hosting bestelformulier [Type] => product [Items] => Array ( [0] => 1 ) ) [2] => Array ( [Identifier] => 3 [GroupName] => Opties bestelformulier [Type] => product [Items] => Array ( ) ) ) )