Device42 Admin Users-Groups API
The Admin Users-Groups API from Device42 — 4 operation(s) for admin users-groups.
The Admin Users-Groups API from Device42 — 4 operation(s) for admin users-groups.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/device42:device42-admin-users-groups-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Device42 Admin Users-Groups API
version: '2.0'
description: 'API Overview
RESTful APIs are supported in Device42 as one of the primary methods of entering, editing and retrieving data.'
contact:
name: Device42
email: support@device42.com
servers:
- url: https://<host>
security:
- basicAuth: []
- bearerAuth: []
tags:
- name: Admin Users-Groups
paths:
/api/1.0/admingroups/:
get:
operationId: getAdmingroups
summary: Get all admin groups
tags:
- Admin Users-Groups
parameters:
- name: include_cols
in: query
description: Return only specified columns. For example:id,name,members,permissions
schema:
type: string
responses:
'200':
description: 'The above command returns results like this:'
content:
application/json:
schema:
properties:
admingroups:
type: array
items:
type: object
properties:
id:
example: 6
members:
example:
- User1
- User2
name:
example: System Generated Read, Add and Edit
total_count:
example: 1
limit:
example: 1000
offset:
example: 0
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
'503':
$ref: '#/components/responses/ServiceUnavailable'
post:
operationId: postAdminGroups
description: Create/update admin groups - Must be a Super User to create or update admin groups
summary: Create/update admin groups
tags:
- Admin Users-Groups
requestBody:
content:
application/x-www-form-urlencoded:
schema:
type: object
properties:
id:
description: Admin group id - used to update a specific admin group. Required for update if name is not provided
type: integer
name:
description: Admin group name - required if creating a new group or if id parameter is not provided
type: string
members:
description: List of admin users separated by commas to add.
type: string
members_remove:
description: List of admin users separated by commas to remove.
type: string
permissions:
description: List of permissions separated by commas to add.
type: string
permissions_remove:
description: List of permissions separated by commas to remove.
type: string
responses:
'200':
description: 'The above command returns results like this:'
content:
application/json:
schema:
properties:
msg:
example:
- admin group added or updated
- 30
- test
- true
- true
code:
example: 0
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
'503':
$ref: '#/components/responses/ServiceUnavailable'
/api/1.0/admingroups/{id}/:
delete:
operationId: deleteAdminGroups
summary: Delete admin group
description: This API is used to delete an admin group with the admin group id supplied as the required argument - Must be a Super User to delete admin groups
tags:
- Admin Users-Groups
parameters:
- name: id
in: path
description: Admin group ID
required: true
schema:
type: integer
responses:
'200':
description: 'The above command returns results like this:'
content:
application/json:
schema:
properties:
deleted:
example: 'true'
id:
example: '114'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
'503':
$ref: '#/components/responses/ServiceUnavailable'
/api/1.0/adminusers/:
get:
operationId: getAdminusers
description: Get all admin users - Must be a Super User to access list of admin users
summary: Get all admin users
tags:
- Admin Users-Groups
parameters:
- name: username
in: query
description: Filter by username
schema:
type: string
- name: email
in: query
description: Filter by email address
schema:
type: string
- name: include_cols
in: query
description: 'Return only specified columns. For example:auth_type,is_active,is_staff,username,id,email,groups,is_superuser,last_login,date_joined, password_doesnt_expire,last_name,first_name,invalid_login_attempts '
schema:
type: string
responses:
'200':
description: 'The above command returns results like this:'
content:
application/json:
schema:
properties:
adminusers:
type: array
items:
type: object
properties:
id:
example: 125
username:
example: JohnDoe
auth_type:
example: Local
email:
example: JohnDoe@device42.com
groups:
type: array
items:
type: string
example:
- System Generated Read Only
- GroupABC
is_superuser:
example: false
first_name:
example: John
last_name:
example: Doe
is_staff:
example: true
is_active:
example: true
last_login:
example: '2024-01-01T00:00:00.000Z'
date_joined:
example: '2024-01-01T00:00:00.000Z'
last_password_changed:
example: '2024-01-01T00:00:00.000Z'
password_doesnt_expire:
example: false
invalid_login_attempts:
example: 2
total_count:
example: 1
limit:
example: 1000
offset:
example: 0
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
'503':
$ref: '#/components/responses/ServiceUnavailable'
post:
operationId: postAdminUsers
description: Create/update admin users - Must be a Super User to create or update admin users
summary: Create/update admin users
tags:
- Admin Users-Groups
requestBody:
content:
application/x-www-form-urlencoded:
schema:
type: object
properties:
id:
description: Admin user id - used to update a specific admin user. Required for update if username is not provided
type: integer
username:
description: Admin user name - required if creating a new user or if id parameter is not provided<br> This value may contain only letters, numbers and @/./+/-/_/=/,/\\\\ characters
type: string
password:
description: New user password - required if creating a new user
type: string
first_name:
description: First name of admin user
type: string
last_name:
description: Last name of admin user
type: string
email:
description: Email address of admin user
type: string
is_superuser:
description: Is super user
type: boolean
is_staff:
description: Is staff user
type: boolean
is_active:
description: Is admin user active
type: boolean
password_doesnt_expire:
description: Password does not expire for this admin user
type: boolean
groups:
description: 'Admin groups to assign user to. Note: groups with commas need to be wrapped in quotes. ie: “System Generated Read, Add, Edit and Delete”'
type: string
new_username:
description: Change username of an existing admin user. This parameter is ignored when creating a new admin user.<br> This value may contain only letters, numbers and @/./+/-/_/=/,/\\\\ characters
type: string
responses:
'200':
description: 'The above command returns results like this:'
content:
application/json:
schema:
properties:
msg:
example:
- administrator added or updated
- 30
- test
- true
- true
code:
example: 0
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
'503':
$ref: '#/components/responses/ServiceUnavailable'
/api/1.0/adminusers/{id}/:
get:
operationId: getAdminUserByID
description: Get specific Admin User by ID - Must be a Super User to get the Admin User
summary: Get specific admin user by id
tags:
- Admin Users-Groups
parameters:
- name: id
in: path
description: D42 Admin User ID
required: true
schema:
type: integer
responses:
'200':
description: 'The above command returns results like this:'
content:
application/json:
schema:
properties:
id:
example: 125
username:
example: JohnDoe
auth_type:
example: Local
email:
example: JohnDoe@device42.com
groups:
type: array
items:
type: string
example:
- System Generated Read Only
- GroupABC
is_superuser:
example: false
first_name:
example: John
last_name:
example: Doe
is_staff:
example: true
is_active:
example: true
last_login:
example: '2024-01-01T00:00:00.000Z'
date_joined:
example: '2024-01-01T00:00:00.000Z'
last_password_changed:
example: '2024-01-01T00:00:00.000Z'
password_doesnt_expire:
example: false
invalid_login_attempts:
example: 2
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
'503':
$ref: '#/components/responses/ServiceUnavailable'
delete:
operationId: deleteAdminUsers
summary: Delete admin user
description: This API is used to delete an Admin User with the Admin User id supplied as the required argument - Must be a Super User to delete admin users
tags:
- Admin Users-Groups
parameters:
- name: id
in: path
description: D42 Admin User ID
required: true
schema:
type: integer
responses:
'200':
description: 'The above command returns results like this:'
content:
application/json:
schema:
properties:
deleted:
example: 'true'
id:
example: '114'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
'503':
$ref: '#/components/responses/ServiceUnavailable'
components:
responses:
Forbidden:
description: Forbidden (The resource requested is hidden)
content:
application/json:
example:
errors:
- code: 403
reason: Forbidden
title: Forbidden
detail: The resource requested is hidden
BadRequest:
description: Bad Request (A validation exception has occurred.)
content:
application/json:
example:
errors:
- code: 400
reason: BAD_REQUEST
title: The error response code title.
detail: Details of the error response.
Unauthorized:
description: Unauthorized (Invalid credentials.)
content:
application/json:
example:
errors:
- code: 401
reason: Unauthorized
title: Unauthorized
detail: Invalid credentials.
InternalServerError:
description: Internal Server Error (A required parameter is missing or there is an issue with the server. Check the returned 'msg' field from the call.)
content:
application/json:
example:
errors:
- code: 500
reason: Internal Server Error
title: Internal Server Error
detail: A required parameter is missing or there is an issue with the server. Check the returned 'msg' field from the call.
NotFound:
description: Not Found (The specified resource could not be found)
content:
application/json:
example:
errors:
- code: 404
reason: Not Found
title: Not Found
detail: The specified resource could not be found.
ServiceUnavailable:
description: Service Unavailable (Please check if your Device42 instance is working normally.)
content:
application/json:
example:
errors:
- code: 503
reason: Service Unavailable
title: Service Unavailable
detail: Please check if your Device42 instance is working normally.
securitySchemes:
basicAuth:
type: http
scheme: basic
description: Basic authentication using a Device42 user's username and password.
bearerAuth:
type: http
scheme: bearer
description: Bearer token obtained from POST /tauth/1.0/token/ using an API Client's key/secret as Basic auth credentials.