| CARVIEW |
Select Language
HTTP/2 301
date: Sat, 27 Dec 2025 20:50:48 GMT
content-type: text/html; charset=UTF-8
location: https://docs.gravityforms.com/gform_webapi_key_user_capabilities/
server: cloudflare
strict-transport-security: max-age=604800
strict-transport-security: max-age=31536000; includeSubDomains
x-content-type-options: nosniff
x-content-type-options: nosniff
x-xss-protection: 1; mode=block
x-xss-protection: 1; mode=block
x-frame-options: SAMEORIGIN
x-frame-options: SAMEORIGIN
content-security-policy: frame-ancestors 'self';
referrer-policy: no-referrer
referrer-policy: strict-origin-when-cross-origin
x-redirect-by: WordPress
fastcgi-cache: MISS
cf-cache-status: DYNAMIC
nel: {"report_to":"cf-nel","success_fraction":0.0,"max_age":604800}
report-to: {"group":"cf-nel","max_age":604800,"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v4?s=NbeCkH1wgaGOawltcXhq%2FK0baFI1ujDqmdh7HLKZPBiCBAsxHGTL%2BppKVYGr2DZ2Z3aikvB8g9PDxI3YEYmfTg8y5OnOdALxewHMzb8%2F1Y5X3rHq"}]}
cf-ray: 9b4bb1376ee4ccbb-BLR
HTTP/2 200
date: Sat, 27 Dec 2025 20:50:49 GMT
content-type: text/html; charset=UTF-8
server: cloudflare
vary: Accept-Encoding
strict-transport-security: max-age=604800
strict-transport-security: max-age=31536000; includeSubDomains
x-content-type-options: nosniff
x-content-type-options: nosniff
x-xss-protection: 1; mode=block
x-xss-protection: 1; mode=block
x-frame-options: SAMEORIGIN
x-frame-options: SAMEORIGIN
content-security-policy: frame-ancestors 'self';
referrer-policy: no-referrer
referrer-policy: strict-origin-when-cross-origin
link: ; rel="https://api.w.org/"
link: ; rel="alternate"; title="JSON"; type="application/json"
link: ; rel=shortlink
fastcgi-cache: EXPIRED
report-to: {"group":"cf-nel","max_age":604800,"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v4?s=F1%2BN1eHawCxbGr0vbfmERaOtbpfyoE43zcXapY9inoKAD6WZLP0664E0B2raBCGihQSy%2F2MY5zC0Sy7dofvR5Spofo6LwLeT3PXvjDejEEYqwM72"}]}
cf-cache-status: DYNAMIC
nel: {"report_to":"cf-nel","success_fraction":0.0,"max_age":604800}
content-encoding: gzip
cf-ray: 9b4bb13dca20ccbb-BLR
gform_webapi_key_user_capabilities - Gravity Forms Documentation
gform_webapi_key_user_capabilities
Description
The gform_webapi_key_user_capabilities filter allows the list of capabilities which are used to determine if a user is included in the User drop down menu when creating a new REST API Key to be overridden.
Usage
The filter would be used like so:
add_filter( 'gform_webapi_key_user_capabilities', 'your_function_name' );
Parameters
- $capabilities array
A list of Gravity Forms capabilities used by REST API endpoints.
Examples
1. Add Capability
This example adds a new capability to the list.
add_filter( 'gform_webapi_key_user_capabilities', function ( $capabilities ) {
$capabilities[] = 'create_users';
return $capabilities;
} );
Placement
This code should be placed in the functions.php file of your active theme or a custom functions plugin.
Since
This filter was added in Gravity Forms v2.4.23.2.
Source Code
This filter is located in GFWebAPI::user_can_access_api() in includes/webapi/webapi.php.