Relation & Partner
The Relation & Partner services consist of the endpoints to define relations between PIPs and ANOs. This data is available for ISPs to access.
Create Infra Relation
The "Create Infra Relation"
endpoint builds a relation between the PIP and ANO using a PUT HTTP method. The relation_name
is
defined in the URL path.
About the Fields
PIP and ANO
There are two required fields to define within the request body: "pip"
and "ano"
. The relation is defined by entering business details about each of the two parties.
The data to be submitted for the PIP and ANO should be general business contact information for the following key-value pairs:
"company_name"
- the complete company name"rtr_agg_id"
- the operator code (additional information is below)"phone"
- general business line"email_to"
- general company email address<"pip"/"ano">_code"
- for pip resp. ano
The "rtr_agg_id"
is the operator code for a business and can be found on the RTR website.
An ISP can utilize this number to better identify those responsible. Providing this number is optional.
Reference URL
Another (optional) field worth mentioning is the "reference_url"
. This field enables you to specify a dynamically generated URL for retrieving OAID related data within your own web portal.
Data fields with any combination of the following information may be added as path parameters and/or query parameters to the URL:
{oaid}
- the Open Access ID{center}
- the coordinates{customer_reference}
- the reference for a tenant's OAID on the customer site{pip_code}
- the PIP synonym
For example, the dynamic fields could be specified in the URL such as:
https://link-to-me.at/{pip_code}/?ref={customer_reference}
or
https://link-to-me.at/{oaid}/{center}/{pip_code}/?ref={customer_reference}
Example
The following example creates a new relation named "wholesale212":
$ curl --request PUT "https://api.oaid.at/v2/pip/relations/wholesale212/" \
$ --header "Authorization: Bearer <access_token>" \
$ --header "Accept: application/json" \
$ --header "Content-Type: application/json" \
$ --data '{
"pip": {
"company_name": "fiberpark gmbh",
"phone": "+43-1-987654321",
"email_to": "support@my-own-domain.at",
"pip_code": "fiber.pip"
},
"ano": {
"company_name": "fiberpark gmbh",
"rtr_agg_id": 413,
"phone": "+43-1-987654321",
"email_to": "support@my-own-domain.at",
"ano_code": "fiber.ano"
},
"reference_url": "https://link-to-me.at/{oaid}/?ref={customer_reference}",
}'
---> 100%
{
"relation_name": "wholesale212",
"tenant": "fiberpark",
"status": "active",
"pip": {
"company_name": "fiberpark gmbh",
"phone": "+43-1-987654321",
"email_to": "support@my-own-domain.at",
"pip_code": "fiber.pip"
},
"ano": {
"company_name": "fiberpark gmbh",
"rtr_agg_id": 413,
"phone": "+43-1-987654321",
"email_to": "support@my-own-domain.at",
"ano_code": "fiber.ano"
},
"reference_url": "https://link-to-me.at/{oaid}/?ref={customer_reference}",
"created_at": "2019-05-29T17:11:14.206+00:00",
"modified_at": "2021-04-12T13:03:07.566+00:00"
}
Read Infra Relation
Relation information can be retrieved in two different methods: either by looking up a single relation, or a list of relations.
Specific Relation
One specific relation can be read by calling the GET method "Read Infra Relation" endpoint. Put the relation to be read as a path parameter.
$ curl --request GET "https://api.oaid.at/v2/pip/relations/wholesale212/" \
$ --header "Authorization: Bearer <access_token>" \
$ --header "Accept: application/json"
---> 100%
{
"relation_name": "wholesale212",
"tenant": "fiberpark",
"status": "active",
"label": "Team Yellow",
"description": "Consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et.",
"pip": {
"company_name": "fiberpark gmbh",
"rtr_agg_id": 413,
"phone": "+43-1-987654321",
"email_to": "support@my-own-domain.at",
"pip_code": "fiber.pip"
},
"ano": {
"company_name": "fiberpark gmbh",
"rtr_agg_id": 413,
"phone": "+43-1-987654321",
"email_to": "support@my-own-domain.at",
"ano_code": "fiber.ano"
},
"reference_url": "https://link-to-me.at/{pip_code}/?ref={customer_reference}",
"created_at": "2019-05-29T17:11:14.206+00:00",
"modified_at": "2021-04-12T13:03:07.566+00:00"
}
All Relations
The "List Infra Relations" endpoint
enables a list of relations between PIPs and ANOs to be read. The search may be filtered by adding the optional pip_code
and/or ano_code
as query parameters.
$ curl --request GET "https://api.oaid.at/v2/pip/relations/?pip_code=fiber.pip" \
$ --header "Authorization: Bearer <access_token>" \
$ --header "Accept: application/json"
---> 100%
[
{
"relation_name": "con_moorland",
"tenant": "fiberpark",
"status": "active",
"label": "Team Yellow",
"description": "Consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et.",
"pip": {
"company_name": "fiberpark gmbh",
"rtr_agg_id": 413,
"phone": "+43-1-987654321",
"email_to": "support@my-own-domain.at",
"pip_code": "fiber.pip"
},
"ano": {
"company_name": "fiberpark gmbh",
"rtr_agg_id": 413,
"phone": "+43-1-987654321",
"email_to": "support@my-own-domain.at",
"ano_code": "fiber.ano"
},
"reference_url": "https://link-to-me.at/{pip_code}/?ref={customer_reference}",
"created_at": "2019-05-29T17:11:14.206+00:00",
"modified_at": "2021-04-12T13:03:07.566+00:00"
}
]
Update Infra Relation
Relations may be updated by making a PATCH request at the "Update Infra Relation" endpoint.
Update attributes for a particular relation_name
by providing it in the URL path, and the attributes in the request body. A complete list of attributes are located at the endpoint description.
$ curl --request PATCH "https://api.oaid.at/v2/pip/relations/wholesale212/" \
$ --header "Authorization: Bearer <access_token>" \
$ --header "Accept: application/json" \
$ --header "Content-Type: application/json" \
$ --data '{"reference_url": "https://link-to-me.at/{center}/{oaid}/?ref={customer_reference}"}'
---> 100%
{
"relation_name": "wholesale212",
"tenant": "fiberpark",
"status": "active",
"label": "Team Yellow",
"description": "Consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et.",
"pip": {
"company_name": "fiberpark gmbh",
"rtr_agg_id": 413,
"phone": "+43-1-987654321",
"email_to": "support@my-own-domain.at",
"pip_code": "fiber.pip"
},
"ano": {
"company_name": "fiberpark gmbh",
"rtr_agg_id": 413,
"phone": "+43-1-987654321",
"email_to": "support@my-own-domain.at",
"ano_code": "fiber.ano"
},
"reference_url": "https://link-to-me.at/{center}/{oaid}/?ref={customer_reference}",
"created_at": "2019-05-29T17:11:14.206+00:00",
"modified_at": "2021-04-12T13:03:07.566+00:00"
}
Delete Infra Relation
A relation can be removed with this DELETE method by specifying the relation_name
as a path parameter.
$ curl --request DELETE "https://api.oaid.at/v2/pip/relations/wholesale212/" \
$ --header "Authorization: Bearer <access_token>" \
$ --header "Accept: application/json"
---> 100%
HTTP/1.1 204 No Content
Content-Type: application/json
Date: Sun, 12 Apr 2021 17:32:16 GMT
Server: uvicorn
<Response body is empty>Response code: 204 (No Content); Time: 122ms (122 ms); Content length: 0 bytes (0 B)