A buyer (inkoper) in an administration. A purchase order names one in purchaser_id.
Label in Fledge: Inkopers
| URL | https://odata-api.fledge.nl/v2-8/Purchasers |
|---|---|
| Key | administration_idpurchaser_id |
| Administration | Rows belong to one administration: always filter on administration_id. |
| Operations | GET listGET onePOSTPATCHDELETE |
| Read licenses | BASIS |
| Write licenses | INKOOP |
| Scopes | FLEDGE_PORTAL |
Example requests
A page of rows, with only the fields you need. See Authentication for the token.
curl -G "https://odata-api.fledge.nl/v2-8/Purchasers" \
--data-urlencode '$filter=administration_id eq 1' \
--data-urlencode '$select=purchaser_id,max_order_amount,user_id,name' \
--data-urlencode '$top=50' \
-H "Authorization: Bearer $TOKEN"const url = new URL('https://odata-api.fledge.nl/v2-8/Purchasers');
url.searchParams.set('$filter', 'administration_id eq 1');
url.searchParams.set('$select', 'purchaser_id,max_order_amount,user_id,name');
url.searchParams.set('$top', '50');
const response = await fetch(url, { headers: { Authorization: `Bearer ${token}` } });
const { value } = await response.json();var url = "https://odata-api.fledge.nl/v2-8/Purchasers" + "?" + string.Join("&",
"$filter=" + Uri.EscapeDataString("administration_id eq 1"),
"$select=" + Uri.EscapeDataString("purchaser_id,max_order_amount,user_id,name"),
"$top=" + Uri.EscapeDataString("50"));
http.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token);
var json = await http.GetStringAsync(url);One row by its key:
GET https://odata-api.fledge.nl/v2-8/Purchasers(administration_id=1,purchaser_id={purchaser_id})Fields
| Field | Type | Description |
|---|---|---|
administration_idkey | Int32 | Administratienummer |
purchaser_idkey | Int32 | Inkoper |
change_article_supplier_preference_automatically | Boolean | Wijzigen voorkeurslev.(j/n): Autorisatie voor wijzigen voorkeursleverancier (j/n) |
max_order_amount | Decimal | Max. bestelbedrag: Maximum bestelbedrag inkoper The most this purchaser may order for. Not checked by the Fledge API. |
name | String | Naam |
user_id | Int32 | Gebruikersnummer: Gebruikers nummer, ook een unieke key voor de tabel The Fledge user who is this purchaser. |
Relations
Read a related row or list in the same request with $expand, and give it its own $select; a list also needs a $top.
| Navigation | Entity set | |
|---|---|---|
Administration | Administrations | one |
PurchaseOrderHeaders | PurchaseOrderHeaders | many |