Seitenhierarchie
Zum Ende der Metadaten springen
Zum Anfang der Metadaten


1. Hole einen Benutzer per ID

URL: https://123.123.123.123/users/$ID.json

Methode: GET

Antwort: JSON


Antwort auf erfolgreiche API Abfrage
{
    "user": {
        "User": {
            "id": "1",
            "usergroup_id": "1",
            "status": "1",
            "email": "admin@local.lan",
            "password": "dfe5b29513c31beff314d5bc613cdc9b97dfb317",
            "firstname": "Admin",
            "lastname": "user",
            "position": null,
            "company": null,
            "phone": null,
            "linkedin_id": null,
            "timezone": "Europe\/Berlin",
            "dateformat": "%H:%M:%S - %d.%m.%Y",
            "image": null,
            "onetimetoken": null,
            "samaccountname": null,
            "showstatsinmenu": false,
            "dashboard_tab_rotation": "570",
            "created": null,
            "modified": "2015-09-28 17:54:32",
            "full_name": "Admin user"
        },
        "Usergroup": {
            "id": "1",
            "name": "Administrator",
            "description": "",
            "created": "2015-08-19 14:57:42",
            "modified": "2015-11-26 16:49:20"
        },
        "ContainerUserMembership": [
            {
                "id": "1",
                "user_id": "1",
                "container_id": "1",
                "permission_level": "2"
            }
        ]
    }
}


2. Hole alle Benutzer

URL: https://123.123.123.123/users.json

Methode: GET

Antwort: JSON


Antwort auf erfolgreiche API Abfrage
{
    "all_users": [
        {
            "User": {
                "id": "1",
                "email": "admin@local.lan",
                "company": null,
                "status": "1",
                "samaccountname": null,
                "full_name": "Admin user"
            },
            "Usergroup": {
                "id": "1",
                "name": "Administrator"
            },
            "UsersToContainer": {
                "container_id": "1"
            }
        },
        {
            "User": {
                "id": "7",
                "email": "api@openitcockpit.org",
                "company": "",
                "status": "1",
                "samaccountname": null,
                "full_name": "api api"
            },
            "Usergroup": {
                "id": "1",
                "name": "Administrator"
            },
            "UsersToContainer": {
                "container_id": "1"
            }
        },
        {
            "User": {
                "id": "4",
                "email": "api@localhost.local",
                "company": "",
                "status": "0",
                "samaccountname": "api",
                "full_name": "api api"
            },
            "Usergroup": {
                "id": "1",
                "name": "Administrator"
            },
            "UsersToContainer": {
                "container_id": "4"
            }
        }
    ]
}
  • Keine Stichwörter