Skip to main content

captcha_instances

Creates, updates, deletes, gets or lists a captcha_instances resource.

Overview

Namecaptcha_instances
TypeResource
Idokta.captchas.captcha_instances

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringThe unique key for the CAPTCHA instance
namestringThe name of the CAPTCHA instance
_linksobjectSpecifies link relations (see Web Linking) available using the JSON Hypertext Application Language specification. This object is used for dynamic discovery of related resources and lifecycle operations.
secretKeystringThe secret key issued from the CAPTCHA provider to perform server-side validation for a CAPTCHA token
siteKeystringThe site key issued from the CAPTCHA provider to render a CAPTCHA on a page
typestringThe type of CAPTCHA provider

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
list_captcha_instancesselectsubdomainLists all CAPTCHA instances with pagination support. A subset of CAPTCHA instances can be returned that match a supported filter expression or query.
get_captcha_instanceselectsubdomainRetrieves the properties of a specified CAPTCHA instance
create_captcha_instanceinsertsubdomainCreates a new CAPTCHA instance. Currently, an org can only configure a single CAPTCHA instance.
update_captcha_instanceupdatesubdomainPartially updates the properties of a specified CAPTCHA instance
replace_captcha_instancereplacesubdomainReplaces the properties for a specified CAPTCHA instance
delete_captcha_instancedeletesubdomainDeletes a specified CAPTCHA instance
> Note: If your CAPTCHA instance is still associated with your org, the request fails. You must first update your Org-wide CAPTCHA settings to remove the CAPTCHA instance.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
subdomainstringThe domain of your organization. This can be a provided subdomain of an official okta domain (okta.com, oktapreview.com, etc) or one of your configured custom domains. (default: my-org)

SELECT examples

Lists all CAPTCHA instances with pagination support. A subset of CAPTCHA instances can be returned that match a supported filter expression or query.

SELECT
id,
name,
_links,
secretKey,
siteKey,
type
FROM okta.captchas.captcha_instances
WHERE subdomain = '{{ subdomain }}' -- required;

INSERT examples

Creates a new CAPTCHA instance. Currently, an org can only configure a single CAPTCHA instance.

INSERT INTO okta.captchas.captcha_instances (
data__name,
data__secretKey,
data__siteKey,
data__type,
subdomain
)
SELECT
'{{ name }}',
'{{ secretKey }}',
'{{ siteKey }}',
'{{ type }}',
'{{ subdomain }}'
RETURNING
id,
name,
_links,
secretKey,
siteKey,
type
;

UPDATE examples

Partially updates the properties of a specified CAPTCHA instance

UPDATE okta.captchas.captcha_instances
SET
data__name = '{{ name }}',
data__secretKey = '{{ secretKey }}',
data__siteKey = '{{ siteKey }}',
data__type = '{{ type }}'
WHERE
subdomain = '{{ subdomain }}' --required
RETURNING
id,
name,
_links,
secretKey,
siteKey,
type;

REPLACE examples

Replaces the properties for a specified CAPTCHA instance

REPLACE okta.captchas.captcha_instances
SET
data__name = '{{ name }}',
data__secretKey = '{{ secretKey }}',
data__siteKey = '{{ siteKey }}',
data__type = '{{ type }}'
WHERE
subdomain = '{{ subdomain }}' --required
RETURNING
id,
name,
_links,
secretKey,
siteKey,
type;

DELETE examples

Deletes a specified CAPTCHA instance
> Note: If your CAPTCHA instance is still associated with your org, the request fails. You must first update your Org-wide CAPTCHA settings to remove the CAPTCHA instance.

DELETE FROM okta.captchas.captcha_instances
WHERE subdomain = '{{ subdomain }}' --required;