The roles of a relation's addresses: one row per address and address type (AddressTypes). One address can play several roles and one role can be on several addresses. Which address type is the invoice, delivery, quotation or confirmation address is configured per administration: read_setting ADDRESSES_PEOPLE_ROLES_INITIAL.
Label in Fledge: Relatie adres rollen
| URL | https://odata-api.fledge.nl/v2-8/RelationAddressTypes |
|---|---|
| Key | address_type_idrelation_address_idrelation_idsequence |
| Administration | Shared by all administrations. |
| Operations | GET listGET onePOSTPATCHDELETE |
| Read licenses | BASIS |
| Write licenses | BASIS |
| 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/RelationAddressTypes" \
--data-urlencode '$select=address_type_id,relation_address_id,relation_id,sequence,is_primary' \
--data-urlencode '$top=50' \
-H "Authorization: Bearer $TOKEN"const url = new URL('https://odata-api.fledge.nl/v2-8/RelationAddressTypes');
url.searchParams.set('$select', 'address_type_id,relation_address_id,relation_id,sequence,is_primary');
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/RelationAddressTypes" + "?" + string.Join("&",
"$select=" + Uri.EscapeDataString("address_type_id,relation_address_id,relation_id,sequence,is_primary"),
"$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/RelationAddressTypes(address_type_id={address_type_id},relation_address_id={relation_address_id},relation_id={relation_id},sequence={sequence})Fields
| Field | Type | Description |
|---|---|---|
sequencekey | Int32 | Volgorde The order within the role, used after is_primary. |
address_type_idkey | Int32 | Rol aders: Rol van het adres (verwijzing naar arol) The role (AddressTypes). 1 is always visit (bezoek), 2 post; the other ids are configured. |
relation_address_idkey | Int32 | Adresnummer |
relation_idkey | Int32 | Relatie |
is_primary | Boolean | Primaire adres The address to use for this role. Setting one primary clears the others of the relation and type. |
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 | |
|---|---|---|
AddressType | AddressTypes | one |
Relation | Relations | one |
RelationAddress | RelationAddresses | one |