Duo Security Users API

User account management

GitHub OpenAPI
Pull this API's OpenAPI, operations, scores and pricing into your own code or AI agent with a free APIs.io key — sign in with GitHub, Google or LinkedIn. No form to fill in; signing in shares your email address with us (Privacy).
Business capability
Identity & Access Management BC-620.20

Operations 24

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

GET /admin/v1/users List Duo users · List users #
Ask an LLM
“Which users are in my Duo account?”
“Can I find a user by username?”
Tell an agent
List all users.
Find the user named {username}.
POST /admin/v1/users Create a Duo user · Create user #
Ask an LLM
“How do I add a new user to Duo?”
“Can I set a full name and email when creating a user?”
Tell an agent
Create a user named {username}.
Add user {username} with full name {realname} and email {email}.
POST /admin/v1/users/bulk_create Create many users at once · Bulk create users #
Ask an LLM
“Can I add a batch of users in one request?”
“What is the maximum number of users I can create in one bulk request?”
Tell an agent
Bulk create these users.
Add this batch of new users to Duo.
POST /admin/v1/users/bulk_restore Restore users from the Trash · Bulk restore users #
Ask an LLM
“How do I bring back users I deleted?”
“Can I restore several users from the Trash at once?”
Tell an agent
Restore the users I sent to the Trash.
Bring these deleted users back from the Trash.
POST /admin/v1/users/bulk_send_to_trash Delete users and send them to the Trash · Bulk send users to Trash #
Ask an LLM
“How do I delete users and move them to the Trash?”
“Can I send several users to the Trash in one request?”
Tell an agent destructive · confirm first
Send these users to the Trash.
Delete the users I listed and put them in the Trash.
GET /admin/v1/users/{user_id} Get a user · Get user #
Ask an LLM
“How do I look up one user's details?”
“What status is a particular user in?”
Tell an agent
Get user {user_id}.
Show the details of user {user_id}.
POST /admin/v1/users/{user_id} Update a user's attributes · Update user #
Ask an LLM
“How do I change a user's status or aliases?”
“Can I rename a user or change their full name?”
Tell an agent
Update user {user_id}.
Change the status of user {user_id}.
DELETE /admin/v1/users/{user_id} Delete a user · Delete user #
Ask an LLM
“How do I permanently remove a user?”
“Can I delete a user by their user ID?”
Tell an agent destructive · confirm first
Delete user {user_id}.
Permanently remove user {user_id}.
POST /admin/v1/users/enroll Enroll a user and send an email · Enroll user #
Ask an LLM
“How do I enroll a new user and send them the enrollment email?”
“Can I start the enrollment process for a user remotely?”
Tell an agent
Enroll a new user and send the enrollment email.
Start enrollment for a user and email them the link.
GET /admin/v1/users/{user_id}/groups List groups a user belongs to · List user groups #
Ask an LLM
“Which groups is a user a member of?”
“What group memberships does a user have?”
Tell an agent
List the groups user {user_id} belongs to.
Show which groups user {user_id} is in.
POST /admin/v1/users/{user_id}/groups Add a user to a group · Associate group with user #
Ask an LLM
“How do I put a user into a group?”
“Can I add a user to several groups at once?”
Tell an agent
Add user {user_id} to a group.
Put user {user_id} into a group.
DELETE /admin/v1/users/{user_id}/groups/{group_id} Remove a user from a group · Disassociate group from user #
Ask an LLM
“How do I take a user out of a group?”
“Can I remove a user from one specific group?”
Tell an agent destructive · confirm first
Remove user {user_id} from group {group_id}.
Take user {user_id} out of group {group_id}.
GET /admin/v1/users/{user_id}/phones List phones enrolled for a user · List user phones #
Ask an LLM
“Which phones has a user enrolled?”
“What phone numbers are registered for a user?”
Tell an agent
List the phones enrolled for user {user_id}.
Show the phone numbers user {user_id} has enrolled.
POST /admin/v1/users/{user_id}/phones Enroll a phone for a user · Associate phone with user #
Ask an LLM
“How do I add a phone number to a user's account?”
“Can I enroll a new phone for a user?”
Tell an agent
Enroll a phone for user {user_id}.
Add a new phone number to user {user_id}.
DELETE /admin/v1/users/{user_id}/phones/{phone_id} Remove a phone from a user · Disassociate phone from user #
Ask an LLM
“How do I take a phone off a user's account?”
“Can I disassociate one specific phone from a user?”
Tell an agent destructive · confirm first
Remove phone {phone_id} from user {user_id}.
Take phone {phone_id} off user {user_id}.
GET /admin/v1/users/{user_id}/tokens List hardware tokens for a user · List user hardware tokens #
Ask an LLM
“Which hardware tokens has a user enrolled?”
“What token serial numbers are tied to a user?”
Tell an agent
List the hardware tokens for user {user_id}.
Show the token serial numbers user {user_id} has enrolled.
POST /admin/v1/users/{user_id}/tokens Enroll a hardware token for a user · Associate hardware token with user #
Ask an LLM
“How do I add a hardware token to a user?”
“Can I enroll a token serial number for a user?”
Tell an agent
Enroll a hardware token for user {user_id}.
Add a token serial number to user {user_id}.
DELETE /admin/v1/users/{user_id}/tokens/{token_id} Remove a hardware token from a user · Disassociate hardware token from user #
Ask an LLM
“How do I take a hardware token off a user?”
“Can I disassociate one token serial number from a user?”
Tell an agent destructive · confirm first
Remove token {token_id} from user {user_id}.
Take token {token_id} off user {user_id}.
GET /admin/v1/users/{user_id}/webauthncredentials List WebAuthn credentials for a user · List WebAuthn credentials for user #
Ask an LLM
“Which WebAuthn security keys has a user enrolled?”
“What WebAuthn credentials are registered for a user?”
Tell an agent
List the WebAuthn credentials for user {user_id}.
Show the WebAuthn keys user {user_id} has enrolled.
GET /admin/v1/users/{user_id}/desktopauthenticators List desktop authenticators for a user · List desktop authenticators for user #
Ask an LLM
“Which desktop authenticators has a user enrolled?”
“What desktop authenticator apps are registered for a user?”
Tell an agent
List the desktop authenticators for user {user_id}.
Show the desktop authenticator apps user {user_id} has enrolled.
GET /admin/v1/users/directorysync List directory sync jobs · List user directory syncs #
Ask an LLM
“Which user directory sync jobs have run on my account?”
“Can I see the history of directory syncs?”
Tell an agent
List all user directory sync jobs.
Show the directory sync history.
POST /admin/v1/users/directorysync/{directory_key}/syncuser Sync a single directory user · Sync directory user #
Ask an LLM
“How do I force a sync for one user from my directory?”
“Can I sync a single user instead of the whole directory?”
Tell an agent
Sync directory user for directory {directory_key}.
Force a one-user sync from directory {directory_key}.
POST /admin/v1/users/{user_id}/send_verification_push Send a verification push to a user · Send verification Duo Push #
Ask an LLM
“How do I send a Duo Push verification to a user?”
“Can I trigger a verification push for a specific user?”
Tell an agent
Send a verification push to user {user_id}.
Trigger a Duo Push for user {user_id}.
GET /admin/v1/users/{user_id}/verification_push_response Check a user's verification push result · Retrieve verification push result #
Ask an LLM
“Did a user accept or decline the verification push I sent?”
“Where do I check the result of a verification push?”
Tell an agent
Get the verification push result for user {user_id}.
Check whether user {user_id} accepted the verification push.

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • 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.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/duo-security:duo-security-users-api"
All apis
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.

Get an API 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 Specification

duo-security-users-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Duo Admin Users API
  description: The Duo Admin API provides programmatic access to the administrative functionality of Duo Security for managing users, groups, phones, hardware tokens, WebAuthn credentials, integrations, and bypass codes. Requests are authenticated using HMAC-SHA1 signed HTTP Basic credentials derived from your integration key and secret key.
  version: v1
  contact:
    name: Duo Security
    url: https://duo.com/docs/adminapi
servers:
- url: https://api-XXXXXXXX.duosecurity.com
  description: Duo Admin API host (replace XXXXXXXX with your tenant identifier)
security:
- basicAuth: []
tags:
- name: Users
  description: User account management
paths:
  /admin/v1/users:
    get:
      operationId: listUsers
      summary: List users
      description: Returns a paged list of users.
      tags:
      - Users
      parameters:
      - name: username
        in: query
        schema:
          type: string
      - name: limit
        in: query
        schema:
          type: integer
      - name: offset
        in: query
        schema:
          type: integer
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UserListResponse'
    post:
      operationId: createUser
      summary: Create user
      description: Create a new user with the specified username.
      tags:
      - Users
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              $ref: '#/components/schemas/UserCreate'
      responses:
        '200':
          description: User created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UserResponse'
  /admin/v1/users/bulk_create:
    post:
      operationId: bulkCreateUsers
      summary: Bulk create users
      description: Create multiple users in a single request (max 100).
      tags:
      - Users
      responses:
        '200':
          description: Bulk create result
  /admin/v1/users/bulk_restore:
    post:
      operationId: bulkRestoreUsers
      summary: Bulk restore users
      description: Restore multiple users from the Trash.
      tags:
      - Users
      responses:
        '200':
          description: Bulk restore result
  /admin/v1/users/bulk_send_to_trash:
    post:
      operationId: bulkSendUsersToTrash
      summary: Bulk send users to Trash
      description: Send multiple users to the Trash.
      tags:
      - Users
      responses:
        '200':
          description: Bulk trash result
  /admin/v1/users/{user_id}:
    parameters:
    - name: user_id
      in: path
      required: true
      schema:
        type: string
    get:
      operationId: getUser
      summary: Get user
      description: Return the single user with the specified user_id.
      tags:
      - Users
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UserResponse'
    post:
      operationId: updateUser
      summary: Update user
      description: Change the username, aliases, full name, status, or other attributes.
      tags:
      - Users
      responses:
        '200':
          description: User updated
    delete:
      operationId: deleteUser
      summary: Delete user
      description: Delete the user with the specified user_id.
      tags:
      - Users
      responses:
        '200':
          description: User deleted
  /admin/v1/users/enroll:
    post:
      operationId: enrollUser
      summary: Enroll user
      description: Enroll a user and send an enrollment email.
      tags:
      - Users
      responses:
        '200':
          description: Enrollment initiated
  /admin/v1/users/{user_id}/groups:
    parameters:
    - name: user_id
      in: path
      required: true
      schema:
        type: string
    get:
      operationId: listUserGroups
      summary: List user groups
      description: Returns paged list of groups associated with a user.
      tags:
      - Users
      responses:
        '200':
          description: Successful response
    post:
      operationId: associateUserGroup
      summary: Associate group with user
      tags:
      - Users
      responses:
        '200':
          description: Group associated
  /admin/v1/users/{user_id}/groups/{group_id}:
    parameters:
    - name: user_id
      in: path
      required: true
      schema:
        type: string
    - name: group_id
      in: path
      required: true
      schema:
        type: string
    delete:
      operationId: disassociateUserGroup
      summary: Disassociate group from user
      tags:
      - Users
      responses:
        '200':
          description: Group disassociated
  /admin/v1/users/{user_id}/phones:
    parameters:
    - name: user_id
      in: path
      required: true
      schema:
        type: string
    get:
      operationId: listUserPhones
      summary: List user phones
      tags:
      - Users
      responses:
        '200':
          description: Successful response
    post:
      operationId: associateUserPhone
      summary: Associate phone with user
      tags:
      - Users
      responses:
        '200':
          description: Phone associated
  /admin/v1/users/{user_id}/phones/{phone_id}:
    parameters:
    - name: user_id
      in: path
      required: true
      schema:
        type: string
    - name: phone_id
      in: path
      required: true
      schema:
        type: string
    delete:
      operationId: disassociateUserPhone
      summary: Disassociate phone from user
      tags:
      - Users
      responses:
        '200':
          description: Phone disassociated
  /admin/v1/users/{user_id}/tokens:
    parameters:
    - name: user_id
      in: path
      required: true
      schema:
        type: string
    get:
      operationId: listUserTokens
      summary: List user hardware tokens
      tags:
      - Users
      responses:
        '200':
          description: Successful response
    post:
      operationId: associateUserToken
      summary: Associate hardware token with user
      tags:
      - Users
      responses:
        '200':
          description: Token associated
  /admin/v1/users/{user_id}/tokens/{token_id}:
    parameters:
    - name: user_id
      in: path
      required: true
      schema:
        type: string
    - name: token_id
      in: path
      required: true
      schema:
        type: string
    delete:
      operationId: disassociateUserToken
      summary: Disassociate hardware token from user
      tags:
      - Users
      responses:
        '200':
          description: Token disassociated
  /admin/v1/users/{user_id}/webauthncredentials:
    parameters:
    - name: user_id
      in: path
      required: true
      schema:
        type: string
    get:
      operationId: listUserWebAuthnCredentials
      summary: List WebAuthn credentials for user
      tags:
      - Users
      responses:
        '200':
          description: Successful response
  /admin/v1/users/{user_id}/desktopauthenticators:
    parameters:
    - name: user_id
      in: path
      required: true
      schema:
        type: string
    get:
      operationId: listUserDesktopAuthenticators
      summary: List desktop authenticators for user
      tags:
      - Users
      responses:
        '200':
          description: Successful response
  /admin/v1/users/directorysync:
    get:
      operationId: listUserDirectorySyncs
      summary: List user directory syncs
      tags:
      - Users
      responses:
        '200':
          description: Successful response
  /admin/v1/users/directorysync/{directory_key}/syncuser:
    parameters:
    - name: directory_key
      in: path
      required: true
      schema:
        type: string
    post:
      operationId: syncDirectoryUser
      summary: Sync directory user
      description: Initiate sync for a specific user.
      tags:
      - Users
      responses:
        '200':
          description: Sync initiated
  /admin/v1/users/{user_id}/send_verification_push:
    parameters:
    - name: user_id
      in: path
      required: true
      schema:
        type: string
    post:
      operationId: sendVerificationPush
      summary: Send verification Duo Push
      tags:
      - Users
      responses:
        '200':
          description: Push sent
  /admin/v1/users/{user_id}/verification_push_response:
    parameters:
    - name: user_id
      in: path
      required: true
      schema:
        type: string
    get:
      operationId: getVerificationPushResponse
      summary: Retrieve verification push result
      tags:
      - Users
      responses:
        '200':
          description: Successful response
components:
  schemas:
    UserResponse:
      type: object
      properties:
        stat:
          type: string
        response:
          $ref: '#/components/schemas/User'
    User:
      type: object
      properties:
        user_id:
          type: string
        username:
          type: string
        realname:
          type: string
        email:
          type: string
        status:
          type: string
        created:
          type: integer
        last_login:
          type: integer
    UserCreate:
      type: object
      properties:
        username:
          type: string
        realname:
          type: string
        email:
          type: string
        status:
          type: string
          enum:
          - active
          - bypass
          - disabled
          - locked out
          - pending deletion
    UserListResponse:
      type: object
      properties:
        stat:
          type: string
        response:
          type: array
          items:
            $ref: '#/components/schemas/User'
  securitySchemes:
    basicAuth:
      type: http
      scheme: basic
      description: HTTP Basic with HMAC-SHA1 signed credentials (integration key as user, signed signature as password).
externalDocs:
  description: Duo Admin API Documentation
  url: https://duo.com/docs/adminapi