List all sites for an organization
|
Method |
URL |
Description |
Arguments |
Outputs |
|---|---|---|---|---|
|
GET |
device/site/list/customer/{Organization ID}/ |
List all sites for this organization |
Organization ID |
JSON array |
Arguments (URL)
|
Parameter |
Type |
Description |
|---|---|---|
|
Organization ID |
int |
The organization ID. |
Arguments (JSON payload)
None
Outputs
|
Parameter |
Type |
Description |
|---|---|---|
|
results |
JSON array |
Array of site records. One entry per site, each record contains a unique ID. |
Example request
curl -k -X GET -H "Authorization: Token 7f89ef48dc5bca218a8ac0268653ffafa74ce6a6ed7a8a703e113b13219b18a6" https://<ip_address>/fpc/v1/api/device/site/list/customer/10/
Example response
{
"data": {
"totalResultsCount": 1,
"results": [
{
"id": 6,
"vdoms": [
{
"id": 16,
"fortimanager": {
"id": 4,
"name": "FMG-7.2-11",
"host": "10.5.1.11",
"username": "fpc",
"status": true,
"last_poll_time": "2023-06-30T01:30:00.932838Z",
"port": 443,
"xmlPort": 8080,
"sn": "FMG-VMTMXXXXXXXX",
"version": "v7.2.3-build1405 230606 (GA)",
"numericVersion": "7.2.3",
"ha": false,
"polling": 51
},
"fortianalyzer": {
"id": 4,
"numericVersion": "7.2.3",
"name": "FAZ-7.2-31",
"host": "10.5.1.31",
"username": "fpc",
"status": true,
"last_poll_time": "2023-06-30T01:30:02.022982Z",
"port": 443,
"sn": "FAZ-VMTMXXXXXXXX",
"version": "v7.2.3-build1405 230606 (GA)",
"polling": 51
},
"adom": {
"id": 17,
"fortimanager": {
"id": 4,
"name": "FMG-7.2-11",
"host": "10.5.1.11",
"username": "fpc",
"status": true,
"last_poll_time": "2023-06-30T01:30:00.932838Z",
"port": 443,
"xmlPort": 8080,
"sn": "FMG-VMTMXXXXXXXX",
"version": "v7.2.3-build1405 230606 (GA)",
"numericVersion": "7.2.3",
"ha": false,
"polling": 51
},
"name": "root",
"oid": 3,
"version": "7.2",
"flags": "no_vpn_console",
"customer": [
10
]
},
"policypackage": {
"id": 20,
"name": "FGT-41",
"status": "imported",
"isEnable": true
},
"aps": [],
"switches": [],
"extenders": [],
"name": "root",
"sn": "FGVM08TMXXXXXXXX",
"devid": "FGT-41",
"alias": "",
"vdom_oid": 3,
"device_oid": 197,
"version": "7.2.5",
"platform": "FortiGate-VM64",
"status": "synchronized",
"device_ha": false,
"device_ha_info": "",
"latitude": 49.28273,
"longitude": -123.120743,
"fortigate_name": "FGT-41",
"display_name": "root/FGT-41/root",
"site": 6
}
],
"aps": [],
"switches": [],
"extenders: [],
"name": "test-site-7.2",
"contactName": "",
"email": "",
"phone": "",
"sandbox": false,
"customer": 10,
"user": [
12
]
}
]
},
"status": {
"code": 0,
"message": "success"
}
}