SCIM Host examples
Operations
List all
List all Hosts.
Request
GET http://<your-domain>/soffid/webservice/scim2/v1/Host
Response 200 OK
{
"schemas": [
"urn:ietf:params:scim:api:messages:2.0:ListResponse"
],
"totalResults": 12,
"startIndex": 1,
"Resources": [
{
"serialNumber": "soffid.bubu.lab:192.168.133.1",
"os": "ALT",
"mail": false,
"ip": "192.168.133.1",
"dynamicIp": true,
"description": "Autocreated on 12/13/20 6:49:34 PM",
"office": false,
"lastSeen": "2020-12-13 18:49:34",
"meta": {
"location": "http://soffid.pat.lab:8080/webservice/scim2/v1/Host/1039055",
"resourceType": "Host"
},
"networkCode": "internal",
"schemas": [
"urn:soffid:com.soffid.iam.api.Host"
],
"name": "soffid.bubu.lab",
"id": 1039055,
"hostAlias": [],
"printersServer": false
},
{
"os": "ALT",
"mail": false,
"ip": "10.129.120.4",
"dynamicIp": false,
"description": "Discovered host iam.soffid.com",
"office": false,
"lastSeen": "2021-04-05 20:06:19",
"meta": {
"location": "http://soffid.pat.lab:8080/webservice/scim2/v1/Host/1793093",
"resourceType": "Host"
},
"networkCode": "lab1",
"schemas": [
"urn:soffid:com.soffid.iam.api.Host"
],
"name": "iam.soffid.com",
"id": 1793093,
"hostAlias": [],
"printersServer": false
},
........
]
}
List by filter
List all Hosts with a filter expression.
It is allowed to use pagination and sort the information, for more information visit the Sorting and Pagination information.
Request
List all Hosts with a filter expression.
GET http://<your-domain>/soffid/webservice/scim2/v1/Host?filter=os eq LIN and name co archiva
Response 200 OK
{
"schemas": [
"urn:ietf:params:scim:api:messages:2.0:ListResponse"
],
"totalResults": 1,
"startIndex": 1,
"Resources": [
{
"os": "LIN",
"mail": false,
"ip": "10.129.120.2",
"dynamicIp": false,
"description": "Discovered host archiva.dev.lab",
"office": false,
"lastSeen": "2021-04-05 20:04:49",
"meta": {
"location": "http://soffid.pat.lab:8080/webservice/scim2/v1/Host/1793026",
"resourceType": "Host"
},
"networkCode": "lab1",
"schemas": [
"urn:soffid:com.soffid.iam.api.Host"
],
"name": "archiva.dev.lab",
"id": 1793026,
"hostAlias": [],
"printersServer": false
}
]
}
Query by id
Query a Host by its id (primary key).
Request
GET http://<your-domain>/soffid/webservice/scim2/v1/Host/1793093
Response 200 OK
{
"os": "ALT",
"mail": false,
"ip": "10.129.120.4",
"dynamicIp": false,
"description": "Discovered host iam.soffid.com",
"office": false,
"lastSeen": "2021-04-05 20:06:19",
"meta": {
"location": "http://soffid.pat.lab:8080/webservice/scim2/v1/Host/1793093",
"resourceType": "Host"
},
"networkCode": "lab1",
"schemas": [
"urn:soffid:com.soffid.iam.api.Host"
],
"name": "iam.soffid.com",
"id": 1793093,
"hostAlias": [],
"printersServer": false
}
Create
To create a Host.
Request
POST http://<your-domain>/soffid/webservice/scim2/v1/Host
JSON
{
"schemas": [
"urn:soffid:com.soffid.iam.api.Host"
],
"name": "billing.dev.lab",
"description": "Host billing.dev.lab",
"os": "LIN",
"mail": false,
"dynamicIp": false,
"networkCode": "internal",
"hostAlias": [
"aliasHost_1",
"aliasHost_2"
],
"serialNumber": "123456789",
"printersServer": false
}
Response 201 Created
{
"serialNumber": "123456789",
"os": "LIN",
"mail": false,
"dynamicIp": false,
"description": "Host billing.dev.lab",
"office": false,
"meta": {
"location": "http://soffid.pat.lab:8080/webservice/scim2/v1/Host/1976899",
"resourceType": "Host"
},
"networkCode": "internal",
"schemas": [
"urn:soffid:com.soffid.iam.api.Host"
],
"name": "billing.dev.lab",
"id": 1976899,
"hostAlias": [],
"printersServer": false
}
Update partial
Update only of the attributes with changes, only these atrributes will be updated, the rest will maintain the same value.
Request
PATCH http://<your-domain>/soffid/webservice/scim2/v1/GroupUser/1976741
JSON
{
"Operations": [
{
"op": "replace",
"path": "groupDescription",
"value": "Enterprise engineering team"
},
{
"op": "replace",
"path": "group",
"value": "EngineeringTeam"
}
]
}
Response 200 OK
{
"groupDescription": "Enterprise engineering team",
"meta": {
"location": "http://soffid.pat.lab:8080/webservice/scim2/v1/GroupUser/1976741",
"resourceType": "GroupUser"
},
"schemas": [
"urn:soffid:com.soffid.iam.api.GroupUser"
],
"start": "2021-05-11 10:39:23",
"fullName": "Casey Kelp",
"disabled": false,
"attributes": {},
"id": 1976741,
"user": "ckelp",
"primaryGroup": true,
"group": "EngineeringTeam"
}
Update all
This operation replace all values in the GroupUser.
- Note that the attribute id is required to confirm that the resource "...GroupUser/<id>" is the same that the JSON GroupUser.
- Note that all the attributes not included in the request will be cleared in the GroupUser type and their data will be lost.
- Note that not all the attributes are updatable, for example tag meta, avoid these tags. For more information see Resource data model page
Request
PUT http://<your-domain>/soffid/webservice/scim2/v1/GroupUser/1976741
JSON
{
"schemas": [
"urn:soffid:com.soffid.iam.api.GroupUser"
],
"id": 1976741,
"group": "it",
"groupDescription": "Help desk support team",
"user": "ckelp",
"fullName": "Casey Kelp",
"primaryGroup": true,
"attributes": {}
}
Response 200 OK
{
"groupDescription": "Help desk support team",
"meta": {
"location": "http://soffid.pat.lab:8080/webservice/scim2/v1/GroupUser/1976741",
"resourceType": "GroupUser"
},
"schemas": [
"urn:soffid:com.soffid.iam.api.GroupUser"
],
"fullName": "Casey Kelp",
"disabled": false,
"attributes": {},
"id": 1976741,
"user": "ckelp",
"primaryGroup": true,
"group": "it"
}
Delete
Delete a role.
Please note after this delete, the account has to be created again to use it in the next examples.
Request
DELETE http://<your-omain>/soffid/webservice/scim2/v1/GroupUser/1976741
Response 204 No Content
204 No Content
Error response
For more infomation about error response visit https://bookstack.soffid.com/link/116#bkmrk-error-response