Skip to main content
Connector guides

Connect Okta

Okta is a workforce identity platform: it holds your people's accounts, their groups and the applications they sign in to. StackJack connects an AI assistant to the Okta API of one Okta organization,…

Written By Christopher Scaminaci

Last updated About 1 hour ago

Okta is a workforce identity platform: it holds your people's accounts, their groups and the applications they sign in to. StackJack connects an AI assistant to the Okta API of one Okta organization, for user administration.

Connecting Okta to StackJack gives your AI assistant a family of okta_ MCP tools. MCP (Model Context Protocol) tools are the standardized commands an AI assistant can call through StackJack. With them, your AI can:

  • Read users - list and search users, read one user, their groups, their application links, their devices, their factors and their admin roles
  • Read groups and applications - list groups, their members, owners and rules, list applications and who is assigned to each one
  • Read the System Log - search the events of your organization
  • Onboard (on Pro plans) - create a user, activate them, add them to groups, assign them to applications and give them an admin role
  • Offboard (on Pro plans) - suspend or deactivate a user, end their sessions and OAuth tokens, remove their groups and applications, and delete them
  • Help a user (on Pro plans) - unlock a user, expire or reset a password, reset or remove a factor
  • Run groups (on Pro plans) - create, change and delete groups, add and remove members and owners, and run group rules

How StackJack authenticates to Okta

Okta takes an API token and the address of your Okta organization. StackJack sends the token in the Authorization header (the SSWS scheme) to your Okta domain only. There is no sign-in exchange: the token is used as it is.

The token acts with the permissions of the administrator who creates it. For user administration, create it as an administrator whose role can manage users, groups and application assignments. A super administrator can do every call.

Getting the token

  1. Sign in to the Okta Admin Console as the administrator the token should act as.
  2. Open Security, then API, then the Tokens tab.
  3. Click Create token, give it a name, and copy the token value. Okta shows it only once. For where calls may come from, choose Any IP: StackJack calls Okta from its own addresses, not from your network. To allow only StackJack's addresses instead, open a StackJack support ticket to get them.

Okta expires a token that is not used for 30 days, and revokes it when the administrator who made it is deactivated. If the connection stops working, create a new token and save it on the connection.

One connection is one Okta organization

A connection reads and changes one Okta organization. If you work with several organizations, add one named connection for each.

Connect it in StackJack

  1. Open Connectors, then Okta.
  2. Enter your Okta domain, the address your people sign in at, for example https://acme.okta.com. A preview organization ends in oktapreview.com. Leave out -admin: the Admin Console address is refused, because the API answers on the organization's own domain.
  3. Paste the API token.
  4. Click Save. StackJack stores the connection and then checks it: it reads the user the token acts as, which changes nothing.

To check a saved connection again later, use Test on its row. The test uses the token that is saved, so save a new token before you test it.

Enter the domain and the token again whenever you save this form. To rename a connection, use Rename in the connections list: a rename needs no token.

What is worth knowing before you start

Long lists come in pages

A list answers one page of results and a next value. To read the next page, ask for the same list again with after set to that value. When next is empty, the list is complete. The System Log can keep offering a next page while you search without an end time, so stop when a page comes back empty.

Changes that are marked destructive

Every change is Pro and is marked destructive, because each one changes who can sign in to what:

  • User lifecycle - create, activate, reactivate, suspend, unsuspend, unlock, deactivate and delete a user. Activating or reactivating a user emails them unless sendEmail is false. Deleting a user is permanent and cannot be recovered. The first delete of a user who is not yet deactivated deactivates them; a second delete removes them.
  • Passwords and factors - expire a password, set a temporary password, send or make a password reset link, reset every factor, and remove one factor.
  • Sessions and grants - end a user's sessions, and revoke their OAuth tokens and grants.
  • Groups - create, replace and delete a group, add and remove members and owners, and create, replace, activate, deactivate and delete group rules. A group rule adds people to groups by itself while it is active.
  • Applications - assign and unassign users and groups, and change an application user.
  • Admin roles - assign and unassign an admin role.

StackJack marks these tools as destructive. Whether your AI application asks for confirmation depends on its settings: some clients prompt before every tool call, some prompt only for tools the server marked destructive, some remember an earlier "always allow", and some never prompt. Review those settings, and leave out the tools a connection does not need. How tools work has the details.

StackJack never sends a change twice. When Okta does not confirm a change, the tool says so: read the user or the group before you try again, so that a second user is not created and a second activation email is not sent.

Secrets in answers

An activation link, an activation token, a password reset link and a temporary password are secrets. A tool that answers one returns it only in its answer, never behind a download link. Okta never returns a password value or a recovery answer in a user record; if one ever appears, StackJack removes it unless you ask for secrets on that call.

Rate limit

Okta limits each organization's calls per endpoint and per minute. StackJack paces one connection at about one call a second and waits when Okta answers that there are too many requests.

When Okta refuses a call

  • The token was refused (401): the token is missing, not valid, revoked or expired. Create a new token and save it on the connection.
  • Something else answered: a proxy or a firewall replied instead of Okta. The token was not judged. Check the Okta domain and try again later.
  • Not allowed (403): the administrator who made the token does not have a role that allows the call.
  • Not found (404): check the user, group, application or rule id. Ask your AI to list them first.
  • A refused request (400): a value was missing or not accepted. Okta's answer names the problem.
  • Too many requests (429): wait before you try again.
  • An outage (5xx): wait and try again.

Tool reference

See the generated Okta tool reference for the current inventory, plan assignment, input schemas and destructive-action labels.

Okta tools

okta_ · 74 tools · Free 33 · Pro 41

Users

ToolWhat it does
okta_create_user
Pro · Destructive
DESTRUCTIVE.
okta_delete_user
Pro · Destructive
DESTRUCTIVE.
okta_get_user
Free · Read-only
Retrieves a user from your Okta org.
okta_list_user_blocks
Free · Read-only
Lists information about how the user is blocked from accessing their account.
okta_list_users
Free · Read-only
Lists users in your org, with pagination in most cases.
okta_update_user
Pro · Destructive
DESTRUCTIVE.

User lifecycle

ToolWhat it does
okta_activate_user
Pro · Destructive
DESTRUCTIVE.
okta_deactivate_user
Pro · Destructive
DESTRUCTIVE.
okta_reactivate_user
Pro · Destructive
DESTRUCTIVE.
okta_reset_user_factors
Pro · Destructive
DESTRUCTIVE.
okta_suspend_user
Pro · Destructive
DESTRUCTIVE.
okta_unlock_user
Pro · Destructive
DESTRUCTIVE.
okta_unsuspend_user
Pro · Destructive
DESTRUCTIVE.

Passwords

ToolWhat it does
okta_expire_password
Pro · Destructive
DESTRUCTIVE.
okta_expire_password_with_temp_password
Pro · Destructive
DESTRUCTIVE.
okta_reset_password
Pro · Destructive
DESTRUCTIVE.

Factors

ToolWhat it does
okta_get_user_factor
Free · Read-only
Retrieves an existing factor for the specified user.
okta_list_supported_factors
Free · Read-only
Lists all the supported factors that can be enrolled for the specified user that are included in the highest priority authenticator enrollment policy that applies to the user.
okta_list_user_factors
Free · Read-only
Lists all enrolled factors for the specified user that are included in the highest priority authenticator enrollment policy that applies to the user.
okta_unenroll_user_factor
Pro · Destructive
DESTRUCTIVE.

Sessions and grants

ToolWhat it does
okta_get_user_client_refresh_token
Free · Read-only
Retrieves a refresh token issued for the specified user and client.
okta_get_user_grant
Free · Read-only
Retrieves a grant for the specified user.
okta_list_user_client_grants
Free · Read-only
Lists all grants for a specified user and client.
okta_list_user_client_refresh_tokens
Free · Read-only
Lists all refresh tokens issued for the specified user and client.
okta_list_user_grants
Free · Read-only
Lists all grants for the specified user.
okta_revoke_user_client_grants
Pro · Destructive
DESTRUCTIVE.
okta_revoke_user_client_token
Pro · Destructive
DESTRUCTIVE.
okta_revoke_user_client_tokens
Pro · Destructive
DESTRUCTIVE.
okta_revoke_user_grant
Pro · Destructive
DESTRUCTIVE.
okta_revoke_user_grants
Pro · Destructive
DESTRUCTIVE.
okta_revoke_user_sessions
Pro · Destructive
DESTRUCTIVE.

User resources

ToolWhat it does
okta_assign_user_linked_object
Pro · Destructive
DESTRUCTIVE.
okta_delete_user_linked_object
Pro · Destructive
DESTRUCTIVE.
okta_list_user_app_links
Free · Read-only
Lists all app links for all direct or indirect (through group membership) assigned apps.
okta_list_user_clients
Free · Read-only
Lists all client resources for which the specified user has grants or tokens.
okta_list_user_devices
Free · Read-only
Lists all devices enrolled by a user.
okta_list_user_groups
Free · Read-only
Lists all groups of which the user is a member Note: To list all groups in your org, use the List all groups endpoints in the Groups API.
okta_list_user_linked_objects
Free · Read-only
Lists either the self link for the primary user or all associated users in the relationship specified by relationshipName.

Groups

ToolWhat it does
okta_add_group_owner
Pro · Destructive
DESTRUCTIVE.
okta_add_user_to_group
Pro · Destructive
DESTRUCTIVE.
okta_create_group
Pro · Destructive
DESTRUCTIVE.
okta_delete_group
Pro · Destructive
DESTRUCTIVE.
okta_get_group
Free · Read-only
Retrieves a specific group by id from your org.
okta_list_group_apps
Free · Read-only
Lists all apps that are assigned to a group.
okta_list_group_owners
Free · Read-only
Lists all owners for a specific group.
okta_list_group_users
Free · Read-only
Lists all users that are a member of a group.
okta_list_groups
Free · Read-only
Lists all groups with pagination support.
okta_remove_group_owner
Pro · Destructive
DESTRUCTIVE.
okta_remove_user_from_group
Pro · Destructive
DESTRUCTIVE.
okta_replace_group
Pro · Destructive
DESTRUCTIVE.

Group rules

ToolWhat it does
okta_activate_group_rule
Pro · Destructive
DESTRUCTIVE.
okta_create_group_rule
Pro · Destructive
DESTRUCTIVE.
okta_deactivate_group_rule
Pro · Destructive
DESTRUCTIVE.
okta_delete_group_rule
Pro · Destructive
DESTRUCTIVE.
okta_get_group_rule
Free · Read-only
Retrieves a specific group rule by ID from your org.
okta_list_group_rules
Free · Read-only
Lists all group rules for your org.
okta_replace_group_rule
Pro · Destructive
DESTRUCTIVE.

Applications

ToolWhat it does
okta_assign_group_to_app
Pro · Destructive
DESTRUCTIVE.
okta_assign_user_to_app
Pro · Destructive
DESTRUCTIVE.
okta_get_app
Free · Read-only
Retrieves an application from your Okta organization by id.
okta_get_app_group
Free · Read-only
Retrieves an app group assignment.
okta_get_app_user
Free · Read-only
Retrieves a specific user assignment for a specific app.
okta_list_app_groups
Free · Read-only
Lists all app group assignments.
okta_list_app_users
Free · Read-only
Lists all assigned users for an app.
okta_list_apps
Free · Read-only
Lists all apps in the org with pagination.
okta_unassign_group_from_app
Pro · Destructive
DESTRUCTIVE.
okta_unassign_user_from_app
Pro · Destructive
DESTRUCTIVE.
okta_update_app_user
Pro · Destructive
DESTRUCTIVE.

Admin roles

ToolWhat it does
okta_assign_admin_role_to_user
Pro · Destructive
DESTRUCTIVE.
okta_get_user_admin_role
Free · Read-only
Retrieves a role assigned to a user (identified by userId).
okta_list_user_admin_roles
Free · Read-only
Lists all roles assigned to a user (identified by userId).
okta_list_users_with_admin_roles
Free · Read-only
Lists all users with role assignments.
okta_unassign_admin_role_from_user
Pro · Destructive
DESTRUCTIVE.

System Log

ToolWhat it does
okta_list_system_log_events
Free · Read-only
Lists all System Log events.