API tokens are long-lived bearer credentials for programmatic access to Hoody. They support fine-grained permissions, IP whitelisting, realm scoping, optional expiration, and delegated issuance (child tokens clamped to a subset of the parent’s permissions). Use these endpoints to mint, inspect, edit, copy, and revoke tokens belonging to your account.
The token secret is only returned once, on create or copy. After that, only metadata is exposed via the read endpoints.
List all auth tokens owned by the authenticated account. Token secret values are never included; only metadata, permissions, and usage telemetry are returned. The truncated flag, when present, indicates that a delegated-token subtree listing was capped at the fanout limit and the returned list is incomplete.
This endpoint takes no parameters.
curl -X GET " https://api.hoody.com/api/v1/auth/tokens " \
-H " Authorization: Bearer <token> "
import { HoodyClient } from ' hoody-sdk ' ;
const client = new HoodyClient ({ baseURL : ' https://api.hoody.com ' , token : process . env . HOODY_TOKEN });
await client . api . authTokens . listIterator ();
" message " : " Auth tokens retrieved successfully " ,
" id " : " 507f1f77bcf86cd799439011 " ,
" alias " : " Production API Key " ,
" expires_at " : " 2025-12-31T23:59:59.000Z " ,
" last_used_at " : " 2025-10-28T12:00:00.000Z " ,
" last_used_ip " : " 198.51.100.1 " ,
" created_at " : " 2025-01-15T10:30:00.000Z " ,
" updated_at " : " 2025-01-15T14:45:00.000Z "
" id " : " 507f1f77bcf86cd799439022 " ,
" alias " : " Development Token " ,
" 507f1f77bcf86cd799439011 "
" created_at " : " 2025-01-10T08:00:00.000Z " ,
" updated_at " : " 2025-01-10T08:00:00.000Z "
" message " : " Authentication token required "
Error Code Title Description Resolution MISSING_TOKENAuthentication token missing No authentication token was provided in the request Include a valid JWT token in the Authorization header as Bearer <token> INVALID_TOKENInvalid authentication token The provided authentication token is malformed or invalid Obtain a new token by logging in again or using a valid auth token TOKEN_EXPIREDAuthentication token expired The provided authentication token has expired Obtain a new token by logging in again or refreshing your session
Fetch a single auth token by its 24-character hex ID. The response mirrors the list entry shape but scoped to one token; the secret value is never included.
Name In Type Required Description idpath string Yes Unique identifier of the token
curl -X GET " https://api.hoody.com/api/v1/auth/tokens/507f1f77bcf86cd799439011 " \
-H " Authorization: Bearer <token> "
import { HoodyClient } from ' hoody-sdk ' ;
const client = new HoodyClient ({ baseURL : ' https://api.hoody.com ' , token : process . env . HOODY_TOKEN });
await client . api . authTokens . get ( ' 507f1f77bcf86cd799439011 ' );
" message " : " Auth token retrieved successfully " ,
" id " : " 507f1f77bcf86cd799439011 " ,
" alias " : " Production API Key " ,
" expires_at " : " 2025-12-31T23:59:59.000Z " ,
" last_used_at " : " 2025-10-28T12:00:00.000Z " ,
" last_used_ip " : " 198.51.100.1 " ,
" created_at " : " 2025-01-15T10:30:00.000Z " ,
" updated_at " : " 2025-01-15T14:45:00.000Z "
" message " : " Invalid ID format "
Error Code Title Description Resolution INVALID_ID_FORMATInvalid ID format The provided ID must be a 24-character hexadecimal string Ensure the ID is exactly 24 characters long and contains only hexadecimal characters (0-9, a-f)
" message " : " Authentication token required "
Error Code Title Description Resolution MISSING_TOKENAuthentication token missing No authentication token was provided in the request Include a valid JWT token in the Authorization header as Bearer <token> INVALID_TOKENInvalid authentication token The provided authentication token is malformed or invalid Obtain a new token by logging in again or using a valid auth token TOKEN_EXPIREDAuthentication token expired The provided authentication token has expired Obtain a new token by logging in again or refreshing your session
" message " : " Authentication token not found "
Error Code Title Description Resolution TOKEN_NOT_FOUNDAuthentication token not found The requested authentication token does not exist or has been deleted Verify the token ID is correct and that the token still exists
Return metadata, permissions, and realm restrictions for the currently authenticated auth token. This endpoint is intentionally reachable on the base control plane (api.hoody.com) so that realm-scoped tokens can bootstrap realm discovery.
This endpoint takes no parameters.
curl -X GET " https://api.hoody.com/api/v1/auth/tokens/me " \
-H " Authorization: Bearer <token> "
import { HoodyClient } from ' hoody-sdk ' ;
const client = new HoodyClient ({ baseURL : ' https://api.hoody.com ' , token : process . env . HOODY_TOKEN });
await client . api . authTokens . getCurrent ();
" message " : " Current auth token retrieved successfully " ,
" id " : " 507f1f77bcf86cd799439011 " ,
" alias " : " External Customer Token " ,
" 507f1f77bcf86cd799439012 "
" created_at " : " 2025-01-15T10:30:00.000Z " ,
" updated_at " : " 2025-01-15T10:30:00.000Z "
" has_realm_restrictions " : true ,
" requires_realm_scope " : true ,
" 507f1f77bcf86cd799439012 "
" active_realm_id " : " 507f1f77bcf86cd799439012 "
" message " : " Authentication token required "
Error Code Title Description Resolution MISSING_TOKENAuthentication token missing No authentication token was provided in the request Include a valid JWT token in the Authorization header as Bearer <token> INVALID_TOKENInvalid authentication token The provided authentication token is malformed or invalid Obtain a new token by logging in again or using a valid auth token TOKEN_EXPIREDAuthentication token expired The provided authentication token has expired Obtain a new token by logging in again or refreshing your session
" message " : " Insufficient permissions "
Error Code Title Description Resolution INSUFFICIENT_PERMISSIONSInsufficient permissions You do not have the required permissions to perform this action Contact the resource owner or administrator to request access
Resolve an ED25519 public key to its associated auth token public profile storage object. This is the read side of the public-key/profile mechanism used to publish identifying metadata for a token without exposing its secret.
Name In Type Required Description public_keypath string Yes ED25519 public key to resolve
curl -X GET " https://api.hoody.com/api/v1/auth/tokens/public-profiles/a1b2c3d4e5f6789012345678901234567890abcdefabcdefabcdefabcdef1234 " \
-H " Authorization: Bearer <token> "
import { HoodyClient } from ' hoody-sdk ' ;
const client = new HoodyClient ({ baseURL : ' https://api.hoody.com ' , token : process . env . HOODY_TOKEN });
await client . api . authTokens . getPublicProfile ( ' a1b2c3d4e5f6789012345678901234567890abcdefabcdefabcdefabcdef1234 ' );
" message " : " Auth token public profile retrieved successfully " ,
" public_key " : " a1b2c3d4e5f6789012345678901234567890abcdefabcdefabcdefabcdef1234 " ,
" display_name " : " Production Integrations " ,
" message " : " Invalid public key format "
Error Code Title Description Resolution VALIDATION_ERRORInvalid input parameters One or more request parameters failed validation Check the error message for specific field requirements and correct your input INVALID_PUBLIC_KEY_FORMATInvalid public key format Public key must be exactly 64 hexadecimal characters (ED25519 format) Provide a valid 64-character ED25519 public key in hexadecimal format
" message " : " Authentication token required "
Error Code Title Description Resolution MISSING_TOKENAuthentication token missing No authentication token was provided in the request Include a valid JWT token in the Authorization header as Bearer <token> INVALID_TOKENInvalid authentication token The provided authentication token is malformed or invalid Obtain a new token by logging in again or using a valid auth token TOKEN_EXPIREDAuthentication token expired The provided authentication token has expired Obtain a new token by logging in again or refreshing your session
" message " : " Authentication token not found "
Error Code Title Description Resolution TOKEN_NOT_FOUNDAuthentication token not found The requested authentication token does not exist or has been deleted Verify the token ID is correct and that the token still exists
List the server-side permission-template catalog. Each entry contains the template name, description, and its resolved permission tree. Read-only; no secrets are returned. The token-creation UI consumes this endpoint to offer delegation options without mirroring the templates client-side.
This endpoint takes no parameters.
curl -X GET " https://api.hoody.com/api/v1/auth/tokens/templates " \
-H " Authorization: Bearer <token> "
import { HoodyClient } from ' hoody-sdk ' ;
const client = new HoodyClient ({ baseURL : ' https://api.hoody.com ' , token : process . env . HOODY_TOKEN });
await client . api . authTokens . listAuthTokenPermissionTemplates ();
Mint a new long-lived auth token. Returns the secret exactly once in the response body; store it immediately, as it cannot be retrieved later.
This endpoint takes no parameters.
Name Type Required Description aliasstring No User-friendly alias. If omitted, a random animal name is generated (e.g., clever-dolphin) public_keystring | null No ED25519 public key as 64-character hex string, or null to clear public_storageobject | null No Arbitrary public JSON profile (max 64KB serialized), or null to clear ip_whitelistarray | string No IPv4 addresses/CIDR ranges, a comma-separated string, or *. Defaults to * permission_templatestring No One of: full_access, external_customer, dev_team, finance_team, read_only. Takes precedence over permissions when provided permissionsobject No Fine-grained permission tree. Missing paths default to false (deny) realm_idsarray No Realm IDs the token is restricted to. Token can ONLY be used on these realm subdomains allow_no_realmboolean No Whether the token may be used without a realm scope. Defaults to true. Set to false for strict sub-account tokens vault_accessboolean No Whether the token can access user vault endpoints. Defaults to false event_accessboolean No Whether the token can access real-time event streams and history. Defaults to true deny_reauthorizationboolean No Opt-in least-privilege belt. Strips resources.create_tokens and resources.vault, forces vault_access to false, and requires a bounded expiry. Rejected (400) if combined with explicit grants of those leaves expires_atstring | string | number No ISO 8601 timestamp, Unix timestamp (seconds/ms), today, or tomorrow. Omit for non-expiring otp_codestring No TOTP code (6 digits) or backup code (10 alphanumeric). Required if 2FA is enabled and authenticating via JWT
curl -X POST " https://api.hoody.com/api/v1/auth/tokens " \
-H " Authorization: Bearer <token> " \
-H " Content-Type: application/json " \
"alias": "Production API Key",
"public_key": "a1b2c3d4e5f6789012345678901234567890abcdefabcdefabcdefabcdef1234",
"display_name": "Production Integrations",
"ip_whitelist": ["192.168.1.0/24", "10.0.0.1"],
"expires_at": 1767225599000
import { HoodyClient } from ' hoody-sdk ' ;
const client = new HoodyClient ({ baseURL : ' https://api.hoody.com ' , token : process . env . HOODY_TOKEN });
await client . api . authTokens . create ({
alias : ' Production API Key ' ,
public_key : ' a1b2c3d4e5f6789012345678901234567890abcdefabcdefabcdefabcdef1234 ' ,
display_name : ' Production Integrations ' ,
ip_whitelist : [ ' 192.168.1.0/24 ' , ' 10.0.0.1 ' ],
expires_at : 1767225599000
" message " : " Auth token created successfully " ,
" token " : " hdy_a1b2c3d4e5f67890abcdef1234567890 " ,
" id " : " 507f1f77bcf86cd799439011 " ,
" alias " : " Production API Key " ,
" public_key " : " a1b2c3d4e5f6789012345678901234567890abcdefabcdefabcdefabcdef1234 " ,
" expires_at " : " 2025-12-31T23:59:59.000Z " ,
" created_at " : " 2025-01-15T10:30:00.000Z " ,
" updated_at " : " 2025-01-15T10:30:00.000Z "
" message " : " Validation failed "
Error Code Title Description Resolution VALIDATION_ERRORInvalid input parameters One or more request parameters failed validation Check the error message for specific field requirements and correct your input MISSING_REQUIRED_FIELDRequired field missing One or more required fields are missing from the request Include all required fields as specified in the API documentation OTP_REQUIRED2FA verification required This operation requires 2FA verification because your account has 2FA enabled Provide an otp_code field with a valid TOTP code or backup code INVALID_ALIAS_FORMATInvalid alias format Token alias must contain only letters, numbers, spaces, underscores, and hyphens Use only allowed characters: letters (a-z, A-Z), numbers (0-9), spaces, underscores (_), and hyphens (-) INVALID_IP_FORMATInvalid IP address format IP whitelist must contain valid IPv4 addresses or CIDR ranges Provide valid IPv4 addresses (e.g., 192.168.1.1) or CIDR ranges (e.g., 192.168.1.0/24), or use * for all IPs INVALID_REALM_ID_FORMATInvalid realm ID format Realm IDs must be 24-character hexadecimal strings Ensure all realm IDs are valid 24-character hex strings (e.g., 507f1f77bcf86cd799439011) INVALID_EXPIRATION_FORMATInvalid expiration format Expiration must be an ISO 8601 date, Unix timestamp, today, tomorrow, or null Use a valid date format: ISO 8601 string, Unix timestamp (seconds/milliseconds), today, tomorrow, or null for non-expiring INVALID_PUBLIC_KEY_FORMATInvalid public key format Public key must be exactly 64 hexadecimal characters (ED25519 format) Provide a valid 64-character ED25519 public key in hexadecimal format PUBLIC_STORAGE_TOO_LARGEPublic storage exceeds size limit public_storage must not exceed 64KB serialized JSONReduce the size of the public storage payload and retry EXPIRATION_IN_PASTExpiration date in the past The expiration date cannot be in the past Provide a future date for token expiration DUPLICATE_ALIASToken alias already exists You already have an authentication token with this alias Choose a different unique alias for this token
" message " : " Authentication token required "
Error Code Title Description Resolution MISSING_TOKENAuthentication token missing No authentication token was provided in the request Include a valid JWT token in the Authorization header as Bearer <token> INVALID_TOKENInvalid authentication token The provided authentication token is malformed or invalid Obtain a new token by logging in again or using a valid auth token TOKEN_EXPIREDAuthentication token expired The provided authentication token has expired Obtain a new token by logging in again or refreshing your session
Duplicate an existing token’s configuration (permissions, realm restrictions, IP whitelist) into a new token with a freshly generated secret. The new token’s secret is returned exactly once.
Name In Type Required Description idpath string Yes Unique identifier of the token
Name Type Required Description aliasstring No Alias for the copied token. If omitted, a deterministic name like <source> copy is generated expires_atstring | string | number | null No Expiration override. If omitted, source expiration is copied when still in the future. Set to null to make the copy non-expiring otp_codestring No TOTP code (6 digits) or backup code (10 alphanumeric). Required if 2FA is enabled and authenticating via JWT
curl -X POST " https://api.hoody.com/api/v1/auth/tokens/507f1f77bcf86cd799439011/copy " \
-H " Authorization: Bearer <token> " \
-H " Content-Type: application/json " \
"alias": "Production API Key Copy"
import { HoodyClient } from ' hoody-sdk ' ;
const client = new HoodyClient ({ baseURL : ' https://api.hoody.com ' , token : process . env . HOODY_TOKEN });
await client . api . authTokens . copy ( ' 507f1f77bcf86cd799439011 ' , {
alias : ' Production API Key Copy '
" message " : " Auth token copied successfully " ,
" token " : " hdy_f0e1d2c3b4a5968778695a4b3c2d1e0f1234567890abcdef " ,
" id " : " 507f1f77bcf86cd799439099 " ,
" alias " : " Production API Key Copy " ,
" 507f1f77bcf86cd799439011 "
" expires_at " : " 2025-12-31T23:59:59.000Z " ,
" created_at " : " 2025-01-20T08:30:00.000Z " ,
" updated_at " : " 2025-01-20T08:30:00.000Z "
" message " : " Validation failed "
Error Code Title Description Resolution VALIDATION_ERRORInvalid input parameters One or more request parameters failed validation Check the error message for specific field requirements and correct your input INVALID_ID_FORMATInvalid ID format The provided ID must be a 24-character hexadecimal string Ensure the ID is exactly 24 characters long and contains only hexadecimal characters (0-9, a-f) OTP_REQUIRED2FA verification required This operation requires 2FA verification because your account has 2FA enabled Provide an otp_code field with a valid TOTP code or backup code INVALID_ALIAS_FORMATInvalid alias format Token alias must contain only letters, numbers, spaces, underscores, and hyphens Use only allowed characters: letters (a-z, A-Z), numbers (0-9), spaces, underscores (_), and hyphens (-) INVALID_EXPIRATION_FORMATInvalid expiration format Expiration must be an ISO 8601 date, Unix timestamp, today, tomorrow, or null Use a valid date format: ISO 8601 string, Unix timestamp (seconds/milliseconds), today, tomorrow, or null for non-expiring EXPIRATION_IN_PASTExpiration date in the past The expiration date cannot be in the past Provide a future date for token expiration DUPLICATE_ALIASToken alias already exists You already have an authentication token with this alias Choose a different unique alias for this token
" message " : " Authentication token required "
Error Code Title Description Resolution MISSING_TOKENAuthentication token missing No authentication token was provided in the request Include a valid JWT token in the Authorization header as Bearer <token> INVALID_TOKENInvalid authentication token The provided authentication token is malformed or invalid Obtain a new token by logging in again or using a valid auth token TOKEN_EXPIREDAuthentication token expired The provided authentication token has expired Obtain a new token by logging in again or refreshing your session
" message " : " Insufficient permissions "
Error Code Title Description Resolution INSUFFICIENT_PERMISSIONSInsufficient permissions You do not have the required permissions to perform this action Contact the resource owner or administrator to request access ACCOUNT_BANNEDAccount banned Your account has been banned and cannot access this resource Contact support for information about your account status
" message " : " Authentication token not found "
Error Code Title Description Resolution TOKEN_NOT_FOUNDAuthentication token not found The requested authentication token does not exist or has been deleted Verify the token ID is correct and that the token still exists
Update an existing token’s mutable fields: alias, public key/profile storage, IP whitelist, permissions, realm restrictions, vault/event access, expiration, and enabled status. The secret value cannot be rotated through this endpoint; use copy to mint a new secret that inherits the same configuration.
Name In Type Required Description idpath string Yes Unique identifier of the token to update
Name Type Required Description aliasstring No User-friendly alias for the token public_keystring | null No ED25519 public key (64 hex chars), or null to clear public_storageobject | null No Arbitrary public JSON profile (max 64KB), or null to clear ip_whitelistarray | string No IPv4 addresses/CIDR ranges, comma-separated string, or * permissionsobject No Fine-grained permission tree. Missing paths default to false (deny) realm_idsarray No List of realm IDs this token is restricted to allow_no_realmboolean No Whether this token can be used without a realm scope vault_accessboolean No Whether this token can access user vault endpoints event_accessboolean No Whether this token can access real-time event streams and history expires_atstring | string | number | null No ISO 8601 string, Unix timestamp, today, tomorrow, or null for non-expiring is_enabledboolean No Enable or disable the token otp_codestring No TOTP code (6 digits) or backup code (10 alphanumeric). Required if 2FA is enabled and authenticating via JWT
curl -X PUT " https://api.hoody.com/api/v1/auth/tokens/507f1f77bcf86cd799439011 " \
-H " Authorization: Bearer <token> " \
-H " Content-Type: application/json " \
"alias": "Updated Production Key",
"public_key": "a1b2c3d4e5f6789012345678901234567890abcdefabcdefabcdefabcdef1234",
"display_name": "Updated Profile",
"website": "https://example.com"
import { HoodyClient } from ' hoody-sdk ' ;
const client = new HoodyClient ({ baseURL : ' https://api.hoody.com ' , token : process . env . HOODY_TOKEN });
await client . api . authTokens . update ( ' 507f1f77bcf86cd799439011 ' , {
alias : ' Updated Production Key ' ,
public_key : ' a1b2c3d4e5f6789012345678901234567890abcdefabcdefabcdefabcdef1234 ' ,
display_name : ' Updated Profile ' ,
website : ' https://example.com '
" message " : " Auth token updated successfully " ,
" id " : " 507f1f77bcf86cd799439011 " ,
" alias " : " Updated Production Key " ,
" public_key " : " a1b2c3d4e5f6789012345678901234567890abcdefabcdefabcdefabcdef1234 " ,
" last_used_at " : " 2025-10-28T12:00:00.000Z " ,
" last_used_ip " : " 198.51.100.1 " ,
" created_at " : " 2025-01-15T10:30:00.000Z " ,
" updated_at " : " 2025-01-15T14:45:00.000Z "
" message " : " Validation failed "
Error Code Title Description Resolution VALIDATION_ERRORInvalid input parameters One or more request parameters failed validation Check the error message for specific field requirements and correct your input INVALID_ID_FORMATInvalid ID format The provided ID must be a 24-character hexadecimal string Ensure the ID is exactly 24 characters long and contains only hexadecimal characters (0-9, a-f) OTP_REQUIRED2FA verification required This operation requires 2FA verification because your account has 2FA enabled Provide an otp_code field with a valid TOTP code or backup code INVALID_ALIAS_FORMATInvalid alias format Token alias must contain only letters, numbers, spaces, underscores, and hyphens Use only allowed characters: letters (a-z, A-Z), numbers (0-9), spaces, underscores (_), and hyphens (-) INVALID_IP_FORMATInvalid IP address format IP whitelist must contain valid IPv4 addresses or CIDR ranges Provide valid IPv4 addresses (e.g., 192.168.1.1) or CIDR ranges (e.g., 192.168.1.0/24), or use * for all IPs INVALID_REALM_ID_FORMATInvalid realm ID format Realm IDs must be 24-character hexadecimal strings Ensure all realm IDs are valid 24-character hex strings (e.g., 507f1f77bcf86cd799439011) INVALID_EXPIRATION_FORMATInvalid expiration format Expiration must be an ISO 8601 date, Unix timestamp, today, tomorrow, or null Use a valid date format: ISO 8601 string, Unix timestamp (seconds/milliseconds), today, tomorrow, or null for non-expiring INVALID_PUBLIC_KEY_FORMATInvalid public key format Public key must be exactly 64 hexadecimal characters (ED25519 format) Provide a valid 64-character ED25519 public key in hexadecimal format PUBLIC_STORAGE_TOO_LARGEPublic storage exceeds size limit public_storage must not exceed 64KB serialized JSONReduce the size of the public storage payload and retry EXPIRATION_IN_PASTExpiration date in the past The expiration date cannot be in the past Provide a future date for token expiration DUPLICATE_ALIASToken alias already exists You already have an authentication token with this alias Choose a different unique alias for this token
" message " : " Authentication token required "
Error Code Title Description Resolution MISSING_TOKENAuthentication token missing No authentication token was provided in the request Include a valid JWT token in the Authorization header as Bearer <token> INVALID_TOKENInvalid authentication token The provided authentication token is malformed or invalid Obtain a new token by logging in again or using a valid auth token TOKEN_EXPIREDAuthentication token expired The provided authentication token has expired Obtain a new token by logging in again or refreshing your session
" message " : " Authentication token not found "
Error Code Title Description Resolution TOKEN_NOT_FOUNDAuthentication token not found The requested authentication token does not exist or has been deleted Verify the token ID is correct and that the token still exists
Update the public key and public-storage payload attached to the currently authenticated token. Requires the resources.auth_token_public_profile permission on the token itself. The endpoint targets /me — the token acting on its own profile, not a sibling token.
This endpoint takes no parameters.
Name Type Required Description public_keystring | null No ED25519 public key (64 hex chars), or null to clear public_storageobject | null No Arbitrary public JSON profile (max 64KB), or null to clear
curl -X PUT " https://api.hoody.com/api/v1/auth/tokens/me/public-profile " \
-H " Authorization: Bearer <token> " \
-H " Content-Type: application/json " \
"public_key": "a1b2c3d4e5f6789012345678901234567890abcdefabcdefabcdefabcdef1234",
"username_hint": "acme-team",
"avatar": "https://cdn.example.com/avatar.png"
import { HoodyClient } from ' hoody-sdk ' ;
const client = new HoodyClient ({ baseURL : ' https://api.hoody.com ' , token : process . env . HOODY_TOKEN });
await client . api . authTokens . updatePublicProfile ({
public_key : ' a1b2c3d4e5f6789012345678901234567890abcdefabcdefabcdefabcdef1234 ' ,
username_hint : ' acme-team ' ,
avatar : ' https://cdn.example.com/avatar.png '
" message " : " Public profile updated successfully " ,
" id " : " 507f1f77bcf86cd799439011 " ,
" alias " : " External Customer Token " ,
" public_key " : " a1b2c3d4e5f6789012345678901234567890abcdefabcdefabcdefabcdef1234 " ,
" username_hint " : " acme-team " ,
" avatar " : " https://cdn.example.com/avatar.png "
" 507f1f77bcf86cd799439012 "
" created_at " : " 2025-01-15T10:30:00.000Z " ,
" updated_at " : " 2025-01-15T14:45:00.000Z "
" message " : " Validation failed "
Error Code Title Description Resolution VALIDATION_ERRORInvalid input parameters One or more request parameters failed validation Check the error message for specific field requirements and correct your input INVALID_PUBLIC_KEY_FORMATInvalid public key format Public key must be exactly 64 hexadecimal characters (ED25519 format) Provide a valid 64-character ED25519 public key in hexadecimal format PUBLIC_STORAGE_TOO_LARGEPublic storage exceeds size limit public_storage must not exceed 64KB serialized JSONReduce the size of the public storage payload and retry
" message " : " Authentication token required "
Error Code Title Description Resolution MISSING_TOKENAuthentication token missing No authentication token was provided in the request Include a valid JWT token in the Authorization header as Bearer <token> INVALID_TOKENInvalid authentication token The provided authentication token is malformed or invalid Obtain a new token by logging in again or using a valid auth token TOKEN_EXPIREDAuthentication token expired The provided authentication token has expired Obtain a new token by logging in again or refreshing your session
" message " : " Insufficient permissions "
Error Code Title Description Resolution INSUFFICIENT_PERMISSIONSInsufficient permissions You do not have the required permissions to perform this action Contact the resource owner or administrator to request access
Atomically add a realm ID to an auth token’s allowlist. The operation is idempotent: if the realm is already present, the endpoint returns success without modification.
Name In Type Required Description idpath string Yes Auth token ID
Name Type Required Description realm_idstring Yes Realm ID to add to the token otp_codestring No TOTP code (6 digits) or backup code (10 alphanumeric). Required if 2FA is enabled
curl -X POST " https://api.hoody.com/api/v1/auth/tokens/507f1f77bcf86cd799439011/add-realm " \
-H " Authorization: Bearer <token> " \
-H " Content-Type: application/json " \
"realm_id": "507f1f77bcf86cd799439012"
import { HoodyClient } from ' hoody-sdk ' ;
const client = new HoodyClient ({ baseURL : ' https://api.hoody.com ' , token : process . env . HOODY_TOKEN });
await client . api . authTokens . addRealm ( ' 507f1f77bcf86cd799439011 ' , {
realm_id : ' 507f1f77bcf86cd799439012 '
" message " : " Realm added to auth token successfully " ,
" id " : " 507f1f77bcf86cd799439011 " ,
" alias " : " External Customer Token " ,
" 507f1f77bcf86cd799439011 " ,
" 507f1f77bcf86cd799439012 "
" created_at " : " 2025-01-15T10:30:00.000Z " ,
" updated_at " : " 2025-01-15T10:30:00.000Z "
" message " : " Invalid realm ID format "
Error Code Title Description Resolution OTP_REQUIRED2FA verification required This operation requires 2FA verification because your account has 2FA enabled Provide an otp_code field with a valid TOTP code or backup code INVALID_REALM_ID_FORMATInvalid realm ID format Realm IDs must be 24-character hexadecimal strings Ensure all realm IDs are valid 24-character hex strings (e.g., 507f1f77bcf86cd799439011)
" message " : " Authentication token required "
" message " : " Authentication token not found "
Atomically remove a realm ID from an auth token’s allowlist. The operation is idempotent: if the realm is not present, the endpoint returns success without modification.
Name In Type Required Description idpath string Yes Auth token ID
Name Type Required Description realm_idstring Yes Realm ID to remove from the token otp_codestring No TOTP code (6 digits) or backup code (10 alphanumeric). Required if 2FA is enabled
curl -X POST " https://api.hoody.com/api/v1/auth/tokens/507f1f77bcf86cd799439011/remove-realm " \
-H " Authorization: Bearer <token> " \
-H " Content-Type: application/json " \
"realm_id": "507f1f77bcf86cd799439012"
import { HoodyClient } from ' hoody-sdk ' ;
const client = new HoodyClient ({ baseURL : ' https://api.hoody.com ' , token : process . env . HOODY_TOKEN });
await client . api . authTokens . removeRealm ( ' 507f1f77bcf86cd799439011 ' , {
realm_id : ' 507f1f77bcf86cd799439012 '
" message " : " Realm removed from auth token successfully " ,
" id " : " 507f1f77bcf86cd799439011 " ,
" alias " : " External Customer Token " ,
" 507f1f77bcf86cd799439011 "
" created_at " : " 2025-01-15T10:30:00.000Z " ,
" updated_at " : " 2025-01-15T10:30:00.000Z "
" message " : " Invalid realm ID format "
Error Code Title Description Resolution OTP_REQUIRED2FA verification required This operation requires 2FA verification because your account has 2FA enabled Provide an otp_code field with a valid TOTP code or backup code INVALID_REALM_ID_FORMATInvalid realm ID format Realm IDs must be 24-character hexadecimal strings Ensure all realm IDs are valid 24-character hex strings (e.g., 507f1f77bcf86cd799439011)
" message " : " Authentication token required "
" message " : " Authentication token not found "
Permanently delete an auth token. Once deleted, the token cannot be used for authentication and cannot be recovered.
Name In Type Required Description idpath string Yes Unique identifier of the token
curl -X DELETE " https://api.hoody.com/api/v1/auth/tokens/507f1f77bcf86cd799439011 " \
-H " Authorization: Bearer <token> "
import { HoodyClient } from ' hoody-sdk ' ;
const client = new HoodyClient ({ baseURL : ' https://api.hoody.com ' , token : process . env . HOODY_TOKEN });
await client . api . authTokens . delete ( ' 507f1f77bcf86cd799439011 ' );
" message " : " Auth token deleted successfully "
" message " : " Invalid ID format "
Error Code Title Description Resolution INVALID_ID_FORMATInvalid ID format The provided ID must be a 24-character hexadecimal string Ensure the ID is exactly 24 characters long and contains only hexadecimal characters (0-9, a-f)
" message " : " Authentication token required "
Error Code Title Description Resolution MISSING_TOKENAuthentication token missing No authentication token was provided in the request Include a valid JWT token in the Authorization header as Bearer <token> INVALID_TOKENInvalid authentication token The provided authentication token is malformed or invalid Obtain a new token by logging in again or using a valid auth token TOKEN_EXPIREDAuthentication token expired The provided authentication token has expired Obtain a new token by logging in again or refreshing your session
" message " : " Insufficient permissions "
Error Code Title Description Resolution INSUFFICIENT_PERMISSIONSInsufficient permissions You do not have the required permissions to perform this action Contact the resource owner or administrator to request access ACCOUNT_BANNEDAccount banned Your account has been banned and cannot access this resource Contact support for information about your account status
" message " : " Authentication token not found "
Error Code Title Description Resolution TOKEN_NOT_FOUNDAuthentication token not found The requested authentication token does not exist or has been deleted Verify the token ID is correct and that the token still exists