findCapabilities
Get capabilities by query
/capabilities
Usage and SDK Samples
curl -X GET \
-H "Accept: application/json" \
"http://localhost:8081/capabilities?query=role&limit=20&offset=2"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.CapabilityApi;
import java.io.File;
import java.util.*;
public class CapabilityApiExample {
public static void main(String[] args) {
// Create an instance of the API class
CapabilityApi apiInstance = new CapabilityApi();
String query = role; // String | A query string to filter users based on matching criteria in fields.
Integer limit = 20; // Integer | Limit the number of elements returned in the response.
Integer offset = 2; // Integer | Skip over a number of elements by specifying an offset value for the query.
try {
capabilities result = apiInstance.findCapabilities(query, limit, offset);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling CapabilityApi#findCapabilities");
e.printStackTrace();
}
}
}
import 'package:openapi/api.dart';
final api_instance = DefaultApi();
final String query = new String(); // String | A query string to filter users based on matching criteria in fields.
final Integer limit = new Integer(); // Integer | Limit the number of elements returned in the response.
final Integer offset = new Integer(); // Integer | Skip over a number of elements by specifying an offset value for the query.
try {
final result = await api_instance.findCapabilities(query, limit, offset);
print(result);
} catch (e) {
print('Exception when calling DefaultApi->findCapabilities: $e\n');
}
import org.openapitools.client.api.CapabilityApi;
public class CapabilityApiExample {
public static void main(String[] args) {
CapabilityApi apiInstance = new CapabilityApi();
String query = role; // String | A query string to filter users based on matching criteria in fields.
Integer limit = 20; // Integer | Limit the number of elements returned in the response.
Integer offset = 2; // Integer | Skip over a number of elements by specifying an offset value for the query.
try {
capabilities result = apiInstance.findCapabilities(query, limit, offset);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling CapabilityApi#findCapabilities");
e.printStackTrace();
}
}
}
// Create an instance of the API class
CapabilityApi *apiInstance = [[CapabilityApi alloc] init];
String *query = role; // A query string to filter users based on matching criteria in fields. (optional) (default to null)
Integer *limit = 20; // Limit the number of elements returned in the response. (optional) (default to 10)
Integer *offset = 2; // Skip over a number of elements by specifying an offset value for the query. (optional) (default to 0)
[apiInstance findCapabilitiesWith:query
limit:limit
offset:offset
completionHandler: ^(capabilities output, NSError* error) {
if (output) {
NSLog(@"%@", output);
}
if (error) {
NSLog(@"Error: %@", error);
}
}];
var ModRolesKeycloakApi = require('mod_roles_keycloak_api');
// Create an instance of the API class
var api = new ModRolesKeycloakApi.CapabilityApi()
var opts = {
'query': role, // {String} A query string to filter users based on matching criteria in fields.
'limit': 20, // {Integer} Limit the number of elements returned in the response.
'offset': 2 // {Integer} Skip over a number of elements by specifying an offset value for the query.
};
var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
};
api.findCapabilities(opts, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class findCapabilitiesExample
{
public void main()
{
// Create an instance of the API class
var apiInstance = new CapabilityApi();
var query = role; // String | A query string to filter users based on matching criteria in fields. (optional) (default to null)
var limit = 20; // Integer | Limit the number of elements returned in the response. (optional) (default to 10)
var offset = 2; // Integer | Skip over a number of elements by specifying an offset value for the query. (optional) (default to 0)
try {
capabilities result = apiInstance.findCapabilities(query, limit, offset);
Debug.WriteLine(result);
} catch (Exception e) {
Debug.Print("Exception when calling CapabilityApi.findCapabilities: " + e.Message );
}
}
}
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\CapabilityApi();
$query = role; // String | A query string to filter users based on matching criteria in fields.
$limit = 20; // Integer | Limit the number of elements returned in the response.
$offset = 2; // Integer | Skip over a number of elements by specifying an offset value for the query.
try {
$result = $api_instance->findCapabilities($query, $limit, $offset);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling CapabilityApi->findCapabilities: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::CapabilityApi;
# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::CapabilityApi->new();
my $query = role; # String | A query string to filter users based on matching criteria in fields.
my $limit = 20; # Integer | Limit the number of elements returned in the response.
my $offset = 2; # Integer | Skip over a number of elements by specifying an offset value for the query.
eval {
my $result = $api_instance->findCapabilities(query => $query, limit => $limit, offset => $offset);
print Dumper($result);
};
if ($@) {
warn "Exception when calling CapabilityApi->findCapabilities: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint
# Create an instance of the API class
api_instance = openapi_client.CapabilityApi()
query = role # String | A query string to filter users based on matching criteria in fields. (optional) (default to null)
limit = 20 # Integer | Limit the number of elements returned in the response. (optional) (default to 10)
offset = 2 # Integer | Skip over a number of elements by specifying an offset value for the query. (optional) (default to 0)
try:
api_response = api_instance.find_capabilities(query=query, limit=limit, offset=offset)
pprint(api_response)
except ApiException as e:
print("Exception when calling CapabilityApi->findCapabilities: %s\n" % e)
extern crate CapabilityApi;
pub fn main() {
let query = role; // String
let limit = 20; // Integer
let offset = 2; // Integer
let mut context = CapabilityApi::Context::default();
let result = client.findCapabilities(query, limit, offset, &context).wait();
println!("{:?}", result);
}
Scopes
Parameters
| Name | Description |
|---|---|
| query |
String
A query string to filter users based on matching criteria in fields.
|
| limit |
Integer
Limit the number of elements returned in the response.
|
| offset |
Integer
Skip over a number of elements by specifying an offset value for the query.
|