Irurueta Auth Server API

Account

changePassword

Changes the password of the authenticated account

Requires a bearer token issued by this server.


/api/account/password

Usage and SDK Samples

curl -X POST \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/problem+json" \
 -H "Content-Type: application/json" \
 "http://localhost:9000/api/account/password" \
 -d '{
  "currentPassword" : "currentPassword",
  "newPassword" : "newPassword"
}'
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.AccountApi;

import java.io.File;
import java.util.*;

public class AccountApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        AccountApi apiInstance = new AccountApi();
        ChangePasswordRequest changePasswordRequest = ; // ChangePasswordRequest | 

        try {
            apiInstance.changePassword(changePasswordRequest);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountApi#changePassword");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final ChangePasswordRequest changePasswordRequest = new ChangePasswordRequest(); // ChangePasswordRequest | 

try {
    final result = await api_instance.changePassword(changePasswordRequest);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->changePassword: $e\n');
}

import org.openapitools.client.api.AccountApi;

public class AccountApiExample {
    public static void main(String[] args) {
        AccountApi apiInstance = new AccountApi();
        ChangePasswordRequest changePasswordRequest = ; // ChangePasswordRequest | 

        try {
            apiInstance.changePassword(changePasswordRequest);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountApi#changePassword");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
AccountApi *apiInstance = [[AccountApi alloc] init];
ChangePasswordRequest *changePasswordRequest = ; // 

// Changes the password of the authenticated account
[apiInstance changePasswordWith:changePasswordRequest
              completionHandler: ^(NSError* error) {
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.AccountApi()
var changePasswordRequest = ; // {ChangePasswordRequest} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.changePassword(changePasswordRequest, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class changePasswordExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new AccountApi();
            var changePasswordRequest = new ChangePasswordRequest(); // ChangePasswordRequest | 

            try {
                // Changes the password of the authenticated account
                apiInstance.changePassword(changePasswordRequest);
            } catch (Exception e) {
                Debug.Print("Exception when calling AccountApi.changePassword: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AccountApi();
$changePasswordRequest = ; // ChangePasswordRequest | 

try {
    $api_instance->changePassword($changePasswordRequest);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->changePassword: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::AccountApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::AccountApi->new();
my $changePasswordRequest = WWW::OPenAPIClient::Object::ChangePasswordRequest->new(); # ChangePasswordRequest | 

eval {
    $api_instance->changePassword(changePasswordRequest => $changePasswordRequest);
};
if ($@) {
    warn "Exception when calling AccountApi->changePassword: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.AccountApi()
changePasswordRequest =  # ChangePasswordRequest | 

try:
    # Changes the password of the authenticated account
    api_instance.change_password(changePasswordRequest)
except ApiException as e:
    print("Exception when calling AccountApi->changePassword: %s\n" % e)
extern crate AccountApi;

pub fn main() {
    let changePasswordRequest = ; // ChangePasswordRequest

    let mut context = AccountApi::Context::default();
    let result = client.changePassword(changePasswordRequest, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Body parameters
Name Description
changePasswordRequest *

Responses

Name Type Format Description
WWW-Authenticate String

register

Registers an account

The answer is the same whether or not the e-mail address or the username is already taken. Rate limited per client address and per e-mail address.


/api/account/register

Usage and SDK Samples

curl -X POST \
 -H "Accept: application/problem+json" \
 -H "Content-Type: application/json" \
 "http://localhost:9000/api/account/register" \
 -d '{
  "username" : "username",
  "email" : "email",
  "password" : "password"
}'
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.AccountApi;

import java.io.File;
import java.util.*;

public class AccountApiExample {
    public static void main(String[] args) {

        // Create an instance of the API class
        AccountApi apiInstance = new AccountApi();
        RegisterRequest registerRequest = ; // RegisterRequest | 

        try {
            apiInstance.register(registerRequest);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountApi#register");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final RegisterRequest registerRequest = new RegisterRequest(); // RegisterRequest | 

try {
    final result = await api_instance.register(registerRequest);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->register: $e\n');
}

import org.openapitools.client.api.AccountApi;

public class AccountApiExample {
    public static void main(String[] args) {
        AccountApi apiInstance = new AccountApi();
        RegisterRequest registerRequest = ; // RegisterRequest | 

        try {
            apiInstance.register(registerRequest);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountApi#register");
            e.printStackTrace();
        }
    }
}


// Create an instance of the API class
AccountApi *apiInstance = [[AccountApi alloc] init];
RegisterRequest *registerRequest = ; // 

// Registers an account
[apiInstance registerWith:registerRequest
              completionHandler: ^(NSError* error) {
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');

// Create an instance of the API class
var api = new IruruetaAuthServerApi.AccountApi()
var registerRequest = ; // {RegisterRequest} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.register(registerRequest, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class registerExample
    {
        public void main()
        {

            // Create an instance of the API class
            var apiInstance = new AccountApi();
            var registerRequest = new RegisterRequest(); // RegisterRequest | 

            try {
                // Registers an account
                apiInstance.register(registerRequest);
            } catch (Exception e) {
                Debug.Print("Exception when calling AccountApi.register: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AccountApi();
$registerRequest = ; // RegisterRequest | 

try {
    $api_instance->register($registerRequest);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->register: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::AccountApi;

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::AccountApi->new();
my $registerRequest = WWW::OPenAPIClient::Object::RegisterRequest->new(); # RegisterRequest | 

eval {
    $api_instance->register(registerRequest => $registerRequest);
};
if ($@) {
    warn "Exception when calling AccountApi->register: $@\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.AccountApi()
registerRequest =  # RegisterRequest | 

try:
    # Registers an account
    api_instance.register(registerRequest)
except ApiException as e:
    print("Exception when calling AccountApi->register: %s\n" % e)
extern crate AccountApi;

pub fn main() {
    let registerRequest = ; // RegisterRequest

    let mut context = AccountApi::Context::default();
    let result = client.register(registerRequest, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Body parameters
Name Description
registerRequest *

Responses

Name Type Format Description
Retry-After Long int64


requestPasswordReset

Requests a password reset link

The answer is the same whether or not the e-mail address belongs to an account; only a registered address receives a message. Rate limited per client address and per e-mail address.


/api/account/password/reset-request

Usage and SDK Samples

curl -X POST \
 -H "Accept: application/problem+json" \
 -H "Content-Type: application/json" \
 "http://localhost:9000/api/account/password/reset-request" \
 -d '{
  "email" : "email"
}'
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.AccountApi;

import java.io.File;
import java.util.*;

public class AccountApiExample {
    public static void main(String[] args) {

        // Create an instance of the API class
        AccountApi apiInstance = new AccountApi();
        PasswordResetRequest passwordResetRequest = ; // PasswordResetRequest | 

        try {
            apiInstance.requestPasswordReset(passwordResetRequest);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountApi#requestPasswordReset");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final PasswordResetRequest passwordResetRequest = new PasswordResetRequest(); // PasswordResetRequest | 

try {
    final result = await api_instance.requestPasswordReset(passwordResetRequest);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->requestPasswordReset: $e\n');
}

import org.openapitools.client.api.AccountApi;

public class AccountApiExample {
    public static void main(String[] args) {
        AccountApi apiInstance = new AccountApi();
        PasswordResetRequest passwordResetRequest = ; // PasswordResetRequest | 

        try {
            apiInstance.requestPasswordReset(passwordResetRequest);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountApi#requestPasswordReset");
            e.printStackTrace();
        }
    }
}


// Create an instance of the API class
AccountApi *apiInstance = [[AccountApi alloc] init];
PasswordResetRequest *passwordResetRequest = ; // 

// Requests a password reset link
[apiInstance requestPasswordResetWith:passwordResetRequest
              completionHandler: ^(NSError* error) {
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');

// Create an instance of the API class
var api = new IruruetaAuthServerApi.AccountApi()
var passwordResetRequest = ; // {PasswordResetRequest} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.requestPasswordReset(passwordResetRequest, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class requestPasswordResetExample
    {
        public void main()
        {

            // Create an instance of the API class
            var apiInstance = new AccountApi();
            var passwordResetRequest = new PasswordResetRequest(); // PasswordResetRequest | 

            try {
                // Requests a password reset link
                apiInstance.requestPasswordReset(passwordResetRequest);
            } catch (Exception e) {
                Debug.Print("Exception when calling AccountApi.requestPasswordReset: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AccountApi();
$passwordResetRequest = ; // PasswordResetRequest | 

try {
    $api_instance->requestPasswordReset($passwordResetRequest);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->requestPasswordReset: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::AccountApi;

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::AccountApi->new();
my $passwordResetRequest = WWW::OPenAPIClient::Object::PasswordResetRequest->new(); # PasswordResetRequest | 

eval {
    $api_instance->requestPasswordReset(passwordResetRequest => $passwordResetRequest);
};
if ($@) {
    warn "Exception when calling AccountApi->requestPasswordReset: $@\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.AccountApi()
passwordResetRequest =  # PasswordResetRequest | 

try:
    # Requests a password reset link
    api_instance.request_password_reset(passwordResetRequest)
except ApiException as e:
    print("Exception when calling AccountApi->requestPasswordReset: %s\n" % e)
extern crate AccountApi;

pub fn main() {
    let passwordResetRequest = ; // PasswordResetRequest

    let mut context = AccountApi::Context::default();
    let result = client.requestPasswordReset(passwordResetRequest, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Body parameters
Name Description
passwordResetRequest *

Responses

Name Type Format Description
Retry-After Long int64

resetPassword

Resets a forgotten password

A rejected password does not use up the token. Rate limited per client address.


/api/account/password/reset

Usage and SDK Samples

curl -X POST \
 -H "Accept: application/problem+json" \
 -H "Content-Type: application/json" \
 "http://localhost:9000/api/account/password/reset" \
 -d '{
  "token" : "token",
  "newPassword" : "newPassword"
}'
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.AccountApi;

import java.io.File;
import java.util.*;

public class AccountApiExample {
    public static void main(String[] args) {

        // Create an instance of the API class
        AccountApi apiInstance = new AccountApi();
        ResetPasswordRequest resetPasswordRequest = ; // ResetPasswordRequest | 

        try {
            apiInstance.resetPassword(resetPasswordRequest);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountApi#resetPassword");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final ResetPasswordRequest resetPasswordRequest = new ResetPasswordRequest(); // ResetPasswordRequest | 

try {
    final result = await api_instance.resetPassword(resetPasswordRequest);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->resetPassword: $e\n');
}

import org.openapitools.client.api.AccountApi;

public class AccountApiExample {
    public static void main(String[] args) {
        AccountApi apiInstance = new AccountApi();
        ResetPasswordRequest resetPasswordRequest = ; // ResetPasswordRequest | 

        try {
            apiInstance.resetPassword(resetPasswordRequest);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountApi#resetPassword");
            e.printStackTrace();
        }
    }
}


// Create an instance of the API class
AccountApi *apiInstance = [[AccountApi alloc] init];
ResetPasswordRequest *resetPasswordRequest = ; // 

// Resets a forgotten password
[apiInstance resetPasswordWith:resetPasswordRequest
              completionHandler: ^(NSError* error) {
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');

// Create an instance of the API class
var api = new IruruetaAuthServerApi.AccountApi()
var resetPasswordRequest = ; // {ResetPasswordRequest} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.resetPassword(resetPasswordRequest, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class resetPasswordExample
    {
        public void main()
        {

            // Create an instance of the API class
            var apiInstance = new AccountApi();
            var resetPasswordRequest = new ResetPasswordRequest(); // ResetPasswordRequest | 

            try {
                // Resets a forgotten password
                apiInstance.resetPassword(resetPasswordRequest);
            } catch (Exception e) {
                Debug.Print("Exception when calling AccountApi.resetPassword: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AccountApi();
$resetPasswordRequest = ; // ResetPasswordRequest | 

try {
    $api_instance->resetPassword($resetPasswordRequest);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->resetPassword: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::AccountApi;

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::AccountApi->new();
my $resetPasswordRequest = WWW::OPenAPIClient::Object::ResetPasswordRequest->new(); # ResetPasswordRequest | 

eval {
    $api_instance->resetPassword(resetPasswordRequest => $resetPasswordRequest);
};
if ($@) {
    warn "Exception when calling AccountApi->resetPassword: $@\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.AccountApi()
resetPasswordRequest =  # ResetPasswordRequest | 

try:
    # Resets a forgotten password
    api_instance.reset_password(resetPasswordRequest)
except ApiException as e:
    print("Exception when calling AccountApi->resetPassword: %s\n" % e)
extern crate AccountApi;

pub fn main() {
    let resetPasswordRequest = ; // ResetPasswordRequest

    let mut context = AccountApi::Context::default();
    let result = client.resetPassword(resetPasswordRequest, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Body parameters
Name Description
resetPasswordRequest *

Responses

Name Type Format Description
Retry-After Long int64

verify

Verifies an e-mail address

A verification link works once. Rate limited per client address.


/api/account/verify

Usage and SDK Samples

curl -X GET \
 -H "Accept: application/problem+json" \
 "http://localhost:9000/api/account/verify?token=token_example"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.AccountApi;

import java.io.File;
import java.util.*;

public class AccountApiExample {
    public static void main(String[] args) {

        // Create an instance of the API class
        AccountApi apiInstance = new AccountApi();
        String token = token_example; // String | Verification token received by e-mail.

        try {
            apiInstance.verify(token);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountApi#verify");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final String token = new String(); // String | Verification token received by e-mail.

try {
    final result = await api_instance.verify(token);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->verify: $e\n');
}

import org.openapitools.client.api.AccountApi;

public class AccountApiExample {
    public static void main(String[] args) {
        AccountApi apiInstance = new AccountApi();
        String token = token_example; // String | Verification token received by e-mail.

        try {
            apiInstance.verify(token);
        } catch (ApiException e) {
            System.err.println("Exception when calling AccountApi#verify");
            e.printStackTrace();
        }
    }
}


// Create an instance of the API class
AccountApi *apiInstance = [[AccountApi alloc] init];
String *token = token_example; // Verification token received by e-mail. (default to null)

// Verifies an e-mail address
[apiInstance verifyWith:token
              completionHandler: ^(NSError* error) {
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');

// Create an instance of the API class
var api = new IruruetaAuthServerApi.AccountApi()
var token = token_example; // {String} Verification token received by e-mail.

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.verify(token, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class verifyExample
    {
        public void main()
        {

            // Create an instance of the API class
            var apiInstance = new AccountApi();
            var token = token_example;  // String | Verification token received by e-mail. (default to null)

            try {
                // Verifies an e-mail address
                apiInstance.verify(token);
            } catch (Exception e) {
                Debug.Print("Exception when calling AccountApi.verify: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AccountApi();
$token = token_example; // String | Verification token received by e-mail.

try {
    $api_instance->verify($token);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->verify: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::AccountApi;

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::AccountApi->new();
my $token = token_example; # String | Verification token received by e-mail.

eval {
    $api_instance->verify(token => $token);
};
if ($@) {
    warn "Exception when calling AccountApi->verify: $@\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.AccountApi()
token = token_example # String | Verification token received by e-mail. (default to null)

try:
    # Verifies an e-mail address
    api_instance.verify(token)
except ApiException as e:
    print("Exception when calling AccountApi->verify: %s\n" % e)
extern crate AccountApi;

pub fn main() {
    let token = token_example; // String

    let mut context = AccountApi::Context::default();
    let result = client.verify(token, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Query parameters
Name Description
token*
String
Verification token received by e-mail.
Required

Responses

Name Type Format Description
Retry-After Long int64

Certificates

bindCertificate

Binds a certificate

Binds the X.509 certificate of the request, in PEM form, to the authenticated account, so it can sign in with it. Only the public certificate is sent, never its private key. The certificate is recognised by the SHA-256 fingerprint of its DER form, never by its subject; it must be within its validity period. Binding a certificate the account already has answers the existing binding. While the account has a confirmed second factor, the bearer token must show a recent multi-factor sign-in (step-up, RFC 9470).


/api/account/certificates

Usage and SDK Samples

curl -X POST \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json,application/problem+json" \
 -H "Content-Type: application/json" \
 "http://localhost:9000/api/account/certificates" \
 -d '{
  "certificate" : "certificate"
}'
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.CertificatesApi;

import java.io.File;
import java.util.*;

public class CertificatesApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        CertificatesApi apiInstance = new CertificatesApi();
        BindCertificateRequest bindCertificateRequest = ; // BindCertificateRequest | 

        try {
            Certificate result = apiInstance.bindCertificate(bindCertificateRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CertificatesApi#bindCertificate");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final BindCertificateRequest bindCertificateRequest = new BindCertificateRequest(); // BindCertificateRequest | 

try {
    final result = await api_instance.bindCertificate(bindCertificateRequest);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->bindCertificate: $e\n');
}

import org.openapitools.client.api.CertificatesApi;

public class CertificatesApiExample {
    public static void main(String[] args) {
        CertificatesApi apiInstance = new CertificatesApi();
        BindCertificateRequest bindCertificateRequest = ; // BindCertificateRequest | 

        try {
            Certificate result = apiInstance.bindCertificate(bindCertificateRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CertificatesApi#bindCertificate");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
CertificatesApi *apiInstance = [[CertificatesApi alloc] init];
BindCertificateRequest *bindCertificateRequest = ; // 

// Binds a certificate
[apiInstance bindCertificateWith:bindCertificateRequest
              completionHandler: ^(Certificate output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.CertificatesApi()
var bindCertificateRequest = ; // {BindCertificateRequest} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.bindCertificate(bindCertificateRequest, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class bindCertificateExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new CertificatesApi();
            var bindCertificateRequest = new BindCertificateRequest(); // BindCertificateRequest | 

            try {
                // Binds a certificate
                Certificate result = apiInstance.bindCertificate(bindCertificateRequest);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling CertificatesApi.bindCertificate: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\CertificatesApi();
$bindCertificateRequest = ; // BindCertificateRequest | 

try {
    $result = $api_instance->bindCertificate($bindCertificateRequest);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling CertificatesApi->bindCertificate: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::CertificatesApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::CertificatesApi->new();
my $bindCertificateRequest = WWW::OPenAPIClient::Object::BindCertificateRequest->new(); # BindCertificateRequest | 

eval {
    my $result = $api_instance->bindCertificate(bindCertificateRequest => $bindCertificateRequest);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling CertificatesApi->bindCertificate: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.CertificatesApi()
bindCertificateRequest =  # BindCertificateRequest | 

try:
    # Binds a certificate
    api_response = api_instance.bind_certificate(bindCertificateRequest)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling CertificatesApi->bindCertificate: %s\n" % e)
extern crate CertificatesApi;

pub fn main() {
    let bindCertificateRequest = ; // BindCertificateRequest

    let mut context = CertificatesApi::Context::default();
    let result = client.bindCertificate(bindCertificateRequest, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Body parameters
Name Description
bindCertificateRequest *

Responses

Name Type Format Description
WWW-Authenticate String


listCertificates

Lists the bound certificates

Lists the X.509 client certificates bound to the authenticated account, oldest first, never anything of another account. A bound certificate signs the account in on POST /login/x509 when authserver.x509.enabled is true.


/api/account/certificates

Usage and SDK Samples

curl -X GET \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json" \
 "http://localhost:9000/api/account/certificates"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.CertificatesApi;

import java.io.File;
import java.util.*;

public class CertificatesApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        CertificatesApi apiInstance = new CertificatesApi();

        try {
            array[Certificate] result = apiInstance.listCertificates();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CertificatesApi#listCertificates");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();


try {
    final result = await api_instance.listCertificates();
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->listCertificates: $e\n');
}

import org.openapitools.client.api.CertificatesApi;

public class CertificatesApiExample {
    public static void main(String[] args) {
        CertificatesApi apiInstance = new CertificatesApi();

        try {
            array[Certificate] result = apiInstance.listCertificates();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CertificatesApi#listCertificates");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
CertificatesApi *apiInstance = [[CertificatesApi alloc] init];

// Lists the bound certificates
[apiInstance listCertificatesWithCompletionHandler: 
              ^(array[Certificate] output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.CertificatesApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.listCertificates(callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class listCertificatesExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new CertificatesApi();

            try {
                // Lists the bound certificates
                array[Certificate] result = apiInstance.listCertificates();
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling CertificatesApi.listCertificates: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\CertificatesApi();

try {
    $result = $api_instance->listCertificates();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling CertificatesApi->listCertificates: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::CertificatesApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::CertificatesApi->new();

eval {
    my $result = $api_instance->listCertificates();
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling CertificatesApi->listCertificates: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.CertificatesApi()

try:
    # Lists the bound certificates
    api_response = api_instance.list_certificates()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling CertificatesApi->listCertificates: %s\n" % e)
extern crate CertificatesApi;

pub fn main() {

    let mut context = CertificatesApi::Context::default();
    let result = client.listCertificates(&context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Responses

Name Type Format Description
WWW-Authenticate String

unbindCertificate

Unbinds a certificate

The certificate can no longer be used to sign in. A certificate of another account is never touched and is answered as not found. While the account has a confirmed second factor, the bearer token must show a recent multi-factor sign-in (step-up, RFC 9470). The last way to sign in to the account is never removed: a certificate is refused while the account has neither a password nor a linked identity, a passkey or another certificate.


/api/account/certificates/{id}

Usage and SDK Samples

curl -X DELETE \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/problem+json" \
 "http://localhost:9000/api/account/certificates/{id}"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.CertificatesApi;

import java.io.File;
import java.util.*;

public class CertificatesApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        CertificatesApi apiInstance = new CertificatesApi();
        UUID id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // UUID | Identifier of the binding.

        try {
            apiInstance.unbindCertificate(id);
        } catch (ApiException e) {
            System.err.println("Exception when calling CertificatesApi#unbindCertificate");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final UUID id = new UUID(); // UUID | Identifier of the binding.

try {
    final result = await api_instance.unbindCertificate(id);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->unbindCertificate: $e\n');
}

import org.openapitools.client.api.CertificatesApi;

public class CertificatesApiExample {
    public static void main(String[] args) {
        CertificatesApi apiInstance = new CertificatesApi();
        UUID id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // UUID | Identifier of the binding.

        try {
            apiInstance.unbindCertificate(id);
        } catch (ApiException e) {
            System.err.println("Exception when calling CertificatesApi#unbindCertificate");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
CertificatesApi *apiInstance = [[CertificatesApi alloc] init];
UUID *id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // Identifier of the binding. (default to null)

// Unbinds a certificate
[apiInstance unbindCertificateWith:id
              completionHandler: ^(NSError* error) {
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.CertificatesApi()
var id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // {UUID} Identifier of the binding.

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.unbindCertificate(id, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class unbindCertificateExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new CertificatesApi();
            var id = 38400000-8cf0-11bd-b23e-10b96e4ef00d;  // UUID | Identifier of the binding. (default to null)

            try {
                // Unbinds a certificate
                apiInstance.unbindCertificate(id);
            } catch (Exception e) {
                Debug.Print("Exception when calling CertificatesApi.unbindCertificate: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\CertificatesApi();
$id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // UUID | Identifier of the binding.

try {
    $api_instance->unbindCertificate($id);
} catch (Exception $e) {
    echo 'Exception when calling CertificatesApi->unbindCertificate: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::CertificatesApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::CertificatesApi->new();
my $id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; # UUID | Identifier of the binding.

eval {
    $api_instance->unbindCertificate(id => $id);
};
if ($@) {
    warn "Exception when calling CertificatesApi->unbindCertificate: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.CertificatesApi()
id = 38400000-8cf0-11bd-b23e-10b96e4ef00d # UUID | Identifier of the binding. (default to null)

try:
    # Unbinds a certificate
    api_instance.unbind_certificate(id)
except ApiException as e:
    print("Exception when calling CertificatesApi->unbindCertificate: %s\n" % e)
extern crate CertificatesApi;

pub fn main() {
    let id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // UUID

    let mut context = CertificatesApi::Context::default();
    let result = client.unbindCertificate(id, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Path parameters
Name Description
id*
UUID (uuid)
Identifier of the binding.
Required

Responses

Name Type Format Description
WWW-Authenticate String


Clients

createClient

Creates a client

The generated secret of a confidential client is returned only in this answer. Needs scope admin.


/api/admin/clients

Usage and SDK Samples

curl -X POST \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json,application/problem+json" \
 -H "Content-Type: application/json" \
 "http://localhost:9000/api/admin/clients" \
 -d '{
  "clientId" : "clientId",
  "name" : "name",
  "confidential" : false,
  "authMethods" : [ "authMethods", "authMethods" ],
  "grantTypes" : [ "grantTypes", "grantTypes" ],
  "redirectUris" : [ "redirectUris", "redirectUris" ],
  "scopes" : [ "scopes", "scopes" ],
  "requireProofKey" : false,
  "audiences" : [ "audiences", "audiences" ],
  "accessTokenTtl" : "accessTokenTtl",
  "refreshTokenTtl" : "refreshTokenTtl",
  "accessTokenFormat" : "accessTokenFormat",
  "reuseRefreshTokens" : false,
  "postLogoutRedirectUris" : [ "postLogoutRedirectUris", "postLogoutRedirectUris" ],
  "requireConsent" : false,
  "mfaRequired" : false,
  "jwkSetUrl" : "https://openapi-generator.tech",
  "jwks" : {
    "key" : ""
  },
  "tokenEndpointAuthSigningAlgorithm" : "RS256",
  "tlsClientAuthSubjectDn" : "tlsClientAuthSubjectDn",
  "certificateBoundAccessTokens" : false
}'
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.ClientsApi;

import java.io.File;
import java.util.*;

public class ClientsApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        ClientsApi apiInstance = new ClientsApi();
        ClientRequest clientRequest = ; // ClientRequest | 

        try {
            CreatedClientResponse result = apiInstance.createClient(clientRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling ClientsApi#createClient");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final ClientRequest clientRequest = new ClientRequest(); // ClientRequest | 

try {
    final result = await api_instance.createClient(clientRequest);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->createClient: $e\n');
}

import org.openapitools.client.api.ClientsApi;

public class ClientsApiExample {
    public static void main(String[] args) {
        ClientsApi apiInstance = new ClientsApi();
        ClientRequest clientRequest = ; // ClientRequest | 

        try {
            CreatedClientResponse result = apiInstance.createClient(clientRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling ClientsApi#createClient");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
ClientsApi *apiInstance = [[ClientsApi alloc] init];
ClientRequest *clientRequest = ; // 

// Creates a client
[apiInstance createClientWith:clientRequest
              completionHandler: ^(CreatedClientResponse output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.ClientsApi()
var clientRequest = ; // {ClientRequest} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.createClient(clientRequest, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class createClientExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new ClientsApi();
            var clientRequest = new ClientRequest(); // ClientRequest | 

            try {
                // Creates a client
                CreatedClientResponse result = apiInstance.createClient(clientRequest);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling ClientsApi.createClient: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\ClientsApi();
$clientRequest = ; // ClientRequest | 

try {
    $result = $api_instance->createClient($clientRequest);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ClientsApi->createClient: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::ClientsApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::ClientsApi->new();
my $clientRequest = WWW::OPenAPIClient::Object::ClientRequest->new(); # ClientRequest | 

eval {
    my $result = $api_instance->createClient(clientRequest => $clientRequest);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling ClientsApi->createClient: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.ClientsApi()
clientRequest =  # ClientRequest | 

try:
    # Creates a client
    api_response = api_instance.create_client(clientRequest)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling ClientsApi->createClient: %s\n" % e)
extern crate ClientsApi;

pub fn main() {
    let clientRequest = ; // ClientRequest

    let mut context = ClientsApi::Context::default();
    let result = client.createClient(clientRequest, &context).wait();

    println!("{:?}", result);
}

Scopes

admin Access token issued by this server for the audience authserver.api.audience (default auth-server). The /api/admin/** operations also need the admin scope, listed as the role of their security requirement. Failures are answered with an RFC 6750 WWW-Authenticate challenge and no body.

Parameters

Body parameters
Name Description
clientRequest *

Responses

Name Type Format Description
WWW-Authenticate String

Name Type Format Description
WWW-Authenticate String


deleteClient

Deletes a client

Needs scope admin.


/api/admin/clients/{clientId}

Usage and SDK Samples

curl -X DELETE \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/problem+json" \
 "http://localhost:9000/api/admin/clients/{clientId}"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.ClientsApi;

import java.io.File;
import java.util.*;

public class ClientsApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        ClientsApi apiInstance = new ClientsApi();
        String clientId = clientId_example; // String | Public identifier of the client.

        try {
            apiInstance.deleteClient(clientId);
        } catch (ApiException e) {
            System.err.println("Exception when calling ClientsApi#deleteClient");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final String clientId = new String(); // String | Public identifier of the client.

try {
    final result = await api_instance.deleteClient(clientId);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->deleteClient: $e\n');
}

import org.openapitools.client.api.ClientsApi;

public class ClientsApiExample {
    public static void main(String[] args) {
        ClientsApi apiInstance = new ClientsApi();
        String clientId = clientId_example; // String | Public identifier of the client.

        try {
            apiInstance.deleteClient(clientId);
        } catch (ApiException e) {
            System.err.println("Exception when calling ClientsApi#deleteClient");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
ClientsApi *apiInstance = [[ClientsApi alloc] init];
String *clientId = clientId_example; // Public identifier of the client. (default to null)

// Deletes a client
[apiInstance deleteClientWith:clientId
              completionHandler: ^(NSError* error) {
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.ClientsApi()
var clientId = clientId_example; // {String} Public identifier of the client.

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.deleteClient(clientId, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class deleteClientExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new ClientsApi();
            var clientId = clientId_example;  // String | Public identifier of the client. (default to null)

            try {
                // Deletes a client
                apiInstance.deleteClient(clientId);
            } catch (Exception e) {
                Debug.Print("Exception when calling ClientsApi.deleteClient: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\ClientsApi();
$clientId = clientId_example; // String | Public identifier of the client.

try {
    $api_instance->deleteClient($clientId);
} catch (Exception $e) {
    echo 'Exception when calling ClientsApi->deleteClient: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::ClientsApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::ClientsApi->new();
my $clientId = clientId_example; # String | Public identifier of the client.

eval {
    $api_instance->deleteClient(clientId => $clientId);
};
if ($@) {
    warn "Exception when calling ClientsApi->deleteClient: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.ClientsApi()
clientId = clientId_example # String | Public identifier of the client. (default to null)

try:
    # Deletes a client
    api_instance.delete_client(clientId)
except ApiException as e:
    print("Exception when calling ClientsApi->deleteClient: %s\n" % e)
extern crate ClientsApi;

pub fn main() {
    let clientId = clientId_example; // String

    let mut context = ClientsApi::Context::default();
    let result = client.deleteClient(clientId, &context).wait();

    println!("{:?}", result);
}

Scopes

admin Access token issued by this server for the audience authserver.api.audience (default auth-server). The /api/admin/** operations also need the admin scope, listed as the role of their security requirement. Failures are answered with an RFC 6750 WWW-Authenticate challenge and no body.

Parameters

Path parameters
Name Description
clientId*
String
Public identifier of the client.
Required

Responses

Name Type Format Description
WWW-Authenticate String

Name Type Format Description
WWW-Authenticate String


getClient

Gets a registered client

Never returns the client secret. Needs scope admin.


/api/admin/clients/{clientId}

Usage and SDK Samples

curl -X GET \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json,application/problem+json" \
 "http://localhost:9000/api/admin/clients/{clientId}"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.ClientsApi;

import java.io.File;
import java.util.*;

public class ClientsApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        ClientsApi apiInstance = new ClientsApi();
        String clientId = clientId_example; // String | Public identifier of the client.

        try {
            ClientResponse result = apiInstance.getClient(clientId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling ClientsApi#getClient");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final String clientId = new String(); // String | Public identifier of the client.

try {
    final result = await api_instance.getClient(clientId);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->getClient: $e\n');
}

import org.openapitools.client.api.ClientsApi;

public class ClientsApiExample {
    public static void main(String[] args) {
        ClientsApi apiInstance = new ClientsApi();
        String clientId = clientId_example; // String | Public identifier of the client.

        try {
            ClientResponse result = apiInstance.getClient(clientId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling ClientsApi#getClient");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
ClientsApi *apiInstance = [[ClientsApi alloc] init];
String *clientId = clientId_example; // Public identifier of the client. (default to null)

// Gets a registered client
[apiInstance getClientWith:clientId
              completionHandler: ^(ClientResponse output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.ClientsApi()
var clientId = clientId_example; // {String} Public identifier of the client.

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getClient(clientId, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class getClientExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new ClientsApi();
            var clientId = clientId_example;  // String | Public identifier of the client. (default to null)

            try {
                // Gets a registered client
                ClientResponse result = apiInstance.getClient(clientId);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling ClientsApi.getClient: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\ClientsApi();
$clientId = clientId_example; // String | Public identifier of the client.

try {
    $result = $api_instance->getClient($clientId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ClientsApi->getClient: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::ClientsApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::ClientsApi->new();
my $clientId = clientId_example; # String | Public identifier of the client.

eval {
    my $result = $api_instance->getClient(clientId => $clientId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling ClientsApi->getClient: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.ClientsApi()
clientId = clientId_example # String | Public identifier of the client. (default to null)

try:
    # Gets a registered client
    api_response = api_instance.get_client(clientId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling ClientsApi->getClient: %s\n" % e)
extern crate ClientsApi;

pub fn main() {
    let clientId = clientId_example; // String

    let mut context = ClientsApi::Context::default();
    let result = client.getClient(clientId, &context).wait();

    println!("{:?}", result);
}

Scopes

admin Access token issued by this server for the audience authserver.api.audience (default auth-server). The /api/admin/** operations also need the admin scope, listed as the role of their security requirement. Failures are answered with an RFC 6750 WWW-Authenticate challenge and no body.

Parameters

Path parameters
Name Description
clientId*
String
Public identifier of the client.
Required

Responses

Name Type Format Description
WWW-Authenticate String

Name Type Format Description
WWW-Authenticate String


listClients

Lists the registered clients

Never returns a client secret. Needs scope admin.


/api/admin/clients

Usage and SDK Samples

curl -X GET \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json" \
 "http://localhost:9000/api/admin/clients"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.ClientsApi;

import java.io.File;
import java.util.*;

public class ClientsApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        ClientsApi apiInstance = new ClientsApi();

        try {
            array[ClientResponse] result = apiInstance.listClients();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling ClientsApi#listClients");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();


try {
    final result = await api_instance.listClients();
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->listClients: $e\n');
}

import org.openapitools.client.api.ClientsApi;

public class ClientsApiExample {
    public static void main(String[] args) {
        ClientsApi apiInstance = new ClientsApi();

        try {
            array[ClientResponse] result = apiInstance.listClients();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling ClientsApi#listClients");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
ClientsApi *apiInstance = [[ClientsApi alloc] init];

// Lists the registered clients
[apiInstance listClientsWithCompletionHandler: 
              ^(array[ClientResponse] output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.ClientsApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.listClients(callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class listClientsExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new ClientsApi();

            try {
                // Lists the registered clients
                array[ClientResponse] result = apiInstance.listClients();
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling ClientsApi.listClients: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\ClientsApi();

try {
    $result = $api_instance->listClients();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ClientsApi->listClients: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::ClientsApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::ClientsApi->new();

eval {
    my $result = $api_instance->listClients();
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling ClientsApi->listClients: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.ClientsApi()

try:
    # Lists the registered clients
    api_response = api_instance.list_clients()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling ClientsApi->listClients: %s\n" % e)
extern crate ClientsApi;

pub fn main() {

    let mut context = ClientsApi::Context::default();
    let result = client.listClients(&context).wait();

    println!("{:?}", result);
}

Scopes

admin Access token issued by this server for the audience authserver.api.audience (default auth-server). The /api/admin/** operations also need the admin scope, listed as the role of their security requirement. Failures are answered with an RFC 6750 WWW-Authenticate challenge and no body.

Parameters

Responses

Name Type Format Description
WWW-Authenticate String

Name Type Format Description
WWW-Authenticate String

rotateClientSecret

Rotates the secret of a confidential client

The new secret is returned only in this answer. Needs scope admin.


/api/admin/clients/{clientId}/secret

Usage and SDK Samples

curl -X POST \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json,application/problem+json" \
 "http://localhost:9000/api/admin/clients/{clientId}/secret"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.ClientsApi;

import java.io.File;
import java.util.*;

public class ClientsApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        ClientsApi apiInstance = new ClientsApi();
        String clientId = clientId_example; // String | Public identifier of the client.

        try {
            ClientSecretResponse result = apiInstance.rotateClientSecret(clientId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling ClientsApi#rotateClientSecret");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final String clientId = new String(); // String | Public identifier of the client.

try {
    final result = await api_instance.rotateClientSecret(clientId);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->rotateClientSecret: $e\n');
}

import org.openapitools.client.api.ClientsApi;

public class ClientsApiExample {
    public static void main(String[] args) {
        ClientsApi apiInstance = new ClientsApi();
        String clientId = clientId_example; // String | Public identifier of the client.

        try {
            ClientSecretResponse result = apiInstance.rotateClientSecret(clientId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling ClientsApi#rotateClientSecret");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
ClientsApi *apiInstance = [[ClientsApi alloc] init];
String *clientId = clientId_example; // Public identifier of the client. (default to null)

// Rotates the secret of a confidential client
[apiInstance rotateClientSecretWith:clientId
              completionHandler: ^(ClientSecretResponse output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.ClientsApi()
var clientId = clientId_example; // {String} Public identifier of the client.

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.rotateClientSecret(clientId, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class rotateClientSecretExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new ClientsApi();
            var clientId = clientId_example;  // String | Public identifier of the client. (default to null)

            try {
                // Rotates the secret of a confidential client
                ClientSecretResponse result = apiInstance.rotateClientSecret(clientId);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling ClientsApi.rotateClientSecret: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\ClientsApi();
$clientId = clientId_example; // String | Public identifier of the client.

try {
    $result = $api_instance->rotateClientSecret($clientId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ClientsApi->rotateClientSecret: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::ClientsApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::ClientsApi->new();
my $clientId = clientId_example; # String | Public identifier of the client.

eval {
    my $result = $api_instance->rotateClientSecret(clientId => $clientId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling ClientsApi->rotateClientSecret: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.ClientsApi()
clientId = clientId_example # String | Public identifier of the client. (default to null)

try:
    # Rotates the secret of a confidential client
    api_response = api_instance.rotate_client_secret(clientId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling ClientsApi->rotateClientSecret: %s\n" % e)
extern crate ClientsApi;

pub fn main() {
    let clientId = clientId_example; // String

    let mut context = ClientsApi::Context::default();
    let result = client.rotateClientSecret(clientId, &context).wait();

    println!("{:?}", result);
}

Scopes

admin Access token issued by this server for the audience authserver.api.audience (default auth-server). The /api/admin/** operations also need the admin scope, listed as the role of their security requirement. Failures are answered with an RFC 6750 WWW-Authenticate challenge and no body.

Parameters

Path parameters
Name Description
clientId*
String
Public identifier of the client.
Required

Responses

Name Type Format Description
WWW-Authenticate String

Name Type Format Description
WWW-Authenticate String


updateClient

Updates a client

Replaces the definition of the client; the clientId of the body must match the path. The secret of the client is not changed. Needs scope admin.


/api/admin/clients/{clientId}

Usage and SDK Samples

curl -X PUT \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json,application/problem+json" \
 -H "Content-Type: application/json" \
 "http://localhost:9000/api/admin/clients/{clientId}" \
 -d '{
  "clientId" : "clientId",
  "name" : "name",
  "confidential" : false,
  "authMethods" : [ "authMethods", "authMethods" ],
  "grantTypes" : [ "grantTypes", "grantTypes" ],
  "redirectUris" : [ "redirectUris", "redirectUris" ],
  "scopes" : [ "scopes", "scopes" ],
  "requireProofKey" : false,
  "audiences" : [ "audiences", "audiences" ],
  "accessTokenTtl" : "accessTokenTtl",
  "refreshTokenTtl" : "refreshTokenTtl",
  "accessTokenFormat" : "accessTokenFormat",
  "reuseRefreshTokens" : false,
  "postLogoutRedirectUris" : [ "postLogoutRedirectUris", "postLogoutRedirectUris" ],
  "requireConsent" : false,
  "mfaRequired" : false,
  "jwkSetUrl" : "https://openapi-generator.tech",
  "jwks" : {
    "key" : ""
  },
  "tokenEndpointAuthSigningAlgorithm" : "RS256",
  "tlsClientAuthSubjectDn" : "tlsClientAuthSubjectDn",
  "certificateBoundAccessTokens" : false
}'
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.ClientsApi;

import java.io.File;
import java.util.*;

public class ClientsApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        ClientsApi apiInstance = new ClientsApi();
        String clientId = clientId_example; // String | Public identifier of the client.
        ClientRequest clientRequest = ; // ClientRequest | 

        try {
            ClientResponse result = apiInstance.updateClient(clientId, clientRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling ClientsApi#updateClient");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final String clientId = new String(); // String | Public identifier of the client.
final ClientRequest clientRequest = new ClientRequest(); // ClientRequest | 

try {
    final result = await api_instance.updateClient(clientId, clientRequest);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->updateClient: $e\n');
}

import org.openapitools.client.api.ClientsApi;

public class ClientsApiExample {
    public static void main(String[] args) {
        ClientsApi apiInstance = new ClientsApi();
        String clientId = clientId_example; // String | Public identifier of the client.
        ClientRequest clientRequest = ; // ClientRequest | 

        try {
            ClientResponse result = apiInstance.updateClient(clientId, clientRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling ClientsApi#updateClient");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
ClientsApi *apiInstance = [[ClientsApi alloc] init];
String *clientId = clientId_example; // Public identifier of the client. (default to null)
ClientRequest *clientRequest = ; // 

// Updates a client
[apiInstance updateClientWith:clientId
    clientRequest:clientRequest
              completionHandler: ^(ClientResponse output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.ClientsApi()
var clientId = clientId_example; // {String} Public identifier of the client.
var clientRequest = ; // {ClientRequest} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.updateClient(clientId, clientRequest, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class updateClientExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new ClientsApi();
            var clientId = clientId_example;  // String | Public identifier of the client. (default to null)
            var clientRequest = new ClientRequest(); // ClientRequest | 

            try {
                // Updates a client
                ClientResponse result = apiInstance.updateClient(clientId, clientRequest);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling ClientsApi.updateClient: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\ClientsApi();
$clientId = clientId_example; // String | Public identifier of the client.
$clientRequest = ; // ClientRequest | 

try {
    $result = $api_instance->updateClient($clientId, $clientRequest);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ClientsApi->updateClient: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::ClientsApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::ClientsApi->new();
my $clientId = clientId_example; # String | Public identifier of the client.
my $clientRequest = WWW::OPenAPIClient::Object::ClientRequest->new(); # ClientRequest | 

eval {
    my $result = $api_instance->updateClient(clientId => $clientId, clientRequest => $clientRequest);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling ClientsApi->updateClient: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.ClientsApi()
clientId = clientId_example # String | Public identifier of the client. (default to null)
clientRequest =  # ClientRequest | 

try:
    # Updates a client
    api_response = api_instance.update_client(clientId, clientRequest)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling ClientsApi->updateClient: %s\n" % e)
extern crate ClientsApi;

pub fn main() {
    let clientId = clientId_example; // String
    let clientRequest = ; // ClientRequest

    let mut context = ClientsApi::Context::default();
    let result = client.updateClient(clientId, clientRequest, &context).wait();

    println!("{:?}", result);
}

Scopes

admin Access token issued by this server for the audience authserver.api.audience (default auth-server). The /api/admin/** operations also need the admin scope, listed as the role of their security requirement. Failures are answered with an RFC 6750 WWW-Authenticate challenge and no body.

Parameters

Path parameters
Name Description
clientId*
String
Public identifier of the client.
Required
Body parameters
Name Description
clientRequest *

Responses

Name Type Format Description
WWW-Authenticate String

Name Type Format Description
WWW-Authenticate String


Identities

listIdentities

Lists the linked identities

Lists the identities of external providers linked to the authenticated account, never anything of another account. The subject the provider assigned to the user is not disclosed.


/api/account/identities

Usage and SDK Samples

curl -X GET \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json" \
 "http://localhost:9000/api/account/identities"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.IdentitiesApi;

import java.io.File;
import java.util.*;

public class IdentitiesApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        IdentitiesApi apiInstance = new IdentitiesApi();

        try {
            array[Identity] result = apiInstance.listIdentities();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling IdentitiesApi#listIdentities");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();


try {
    final result = await api_instance.listIdentities();
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->listIdentities: $e\n');
}

import org.openapitools.client.api.IdentitiesApi;

public class IdentitiesApiExample {
    public static void main(String[] args) {
        IdentitiesApi apiInstance = new IdentitiesApi();

        try {
            array[Identity] result = apiInstance.listIdentities();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling IdentitiesApi#listIdentities");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
IdentitiesApi *apiInstance = [[IdentitiesApi alloc] init];

// Lists the linked identities
[apiInstance listIdentitiesWithCompletionHandler: 
              ^(array[Identity] output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.IdentitiesApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.listIdentities(callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class listIdentitiesExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new IdentitiesApi();

            try {
                // Lists the linked identities
                array[Identity] result = apiInstance.listIdentities();
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling IdentitiesApi.listIdentities: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\IdentitiesApi();

try {
    $result = $api_instance->listIdentities();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling IdentitiesApi->listIdentities: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::IdentitiesApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::IdentitiesApi->new();

eval {
    my $result = $api_instance->listIdentities();
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling IdentitiesApi->listIdentities: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.IdentitiesApi()

try:
    # Lists the linked identities
    api_response = api_instance.list_identities()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling IdentitiesApi->listIdentities: %s\n" % e)
extern crate IdentitiesApi;

pub fn main() {

    let mut context = IdentitiesApi::Context::default();
    let result = client.listIdentities(&context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Responses

Name Type Format Description
WWW-Authenticate String

unlinkIdentity

Unlinks an identity

The identity can no longer be used to sign in. An identity of another account is never touched and is answered as not found. While the account has a confirmed second factor, the bearer token must show a recent multi-factor sign-in (step-up, RFC 9470). The last way to sign in to the account is never removed: an identity is refused while the account has neither a password nor another linked identity or credential.


/api/account/identities/{id}

Usage and SDK Samples

curl -X DELETE \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/problem+json" \
 "http://localhost:9000/api/account/identities/{id}"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.IdentitiesApi;

import java.io.File;
import java.util.*;

public class IdentitiesApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        IdentitiesApi apiInstance = new IdentitiesApi();
        UUID id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // UUID | Identifier of the linked identity.

        try {
            apiInstance.unlinkIdentity(id);
        } catch (ApiException e) {
            System.err.println("Exception when calling IdentitiesApi#unlinkIdentity");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final UUID id = new UUID(); // UUID | Identifier of the linked identity.

try {
    final result = await api_instance.unlinkIdentity(id);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->unlinkIdentity: $e\n');
}

import org.openapitools.client.api.IdentitiesApi;

public class IdentitiesApiExample {
    public static void main(String[] args) {
        IdentitiesApi apiInstance = new IdentitiesApi();
        UUID id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // UUID | Identifier of the linked identity.

        try {
            apiInstance.unlinkIdentity(id);
        } catch (ApiException e) {
            System.err.println("Exception when calling IdentitiesApi#unlinkIdentity");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
IdentitiesApi *apiInstance = [[IdentitiesApi alloc] init];
UUID *id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // Identifier of the linked identity. (default to null)

// Unlinks an identity
[apiInstance unlinkIdentityWith:id
              completionHandler: ^(NSError* error) {
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.IdentitiesApi()
var id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // {UUID} Identifier of the linked identity.

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.unlinkIdentity(id, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class unlinkIdentityExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new IdentitiesApi();
            var id = 38400000-8cf0-11bd-b23e-10b96e4ef00d;  // UUID | Identifier of the linked identity. (default to null)

            try {
                // Unlinks an identity
                apiInstance.unlinkIdentity(id);
            } catch (Exception e) {
                Debug.Print("Exception when calling IdentitiesApi.unlinkIdentity: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\IdentitiesApi();
$id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // UUID | Identifier of the linked identity.

try {
    $api_instance->unlinkIdentity($id);
} catch (Exception $e) {
    echo 'Exception when calling IdentitiesApi->unlinkIdentity: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::IdentitiesApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::IdentitiesApi->new();
my $id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; # UUID | Identifier of the linked identity.

eval {
    $api_instance->unlinkIdentity(id => $id);
};
if ($@) {
    warn "Exception when calling IdentitiesApi->unlinkIdentity: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.IdentitiesApi()
id = 38400000-8cf0-11bd-b23e-10b96e4ef00d # UUID | Identifier of the linked identity. (default to null)

try:
    # Unlinks an identity
    api_instance.unlink_identity(id)
except ApiException as e:
    print("Exception when calling IdentitiesApi->unlinkIdentity: %s\n" % e)
extern crate IdentitiesApi;

pub fn main() {
    let id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // UUID

    let mut context = IdentitiesApi::Context::default();
    let result = client.unlinkIdentity(id, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Path parameters
Name Description
id*
UUID (uuid)
Identifier of the linked identity.
Required

Responses

Name Type Format Description
WWW-Authenticate String


Passkeys

deletePasskey

Deletes a passkey

The passkey can no longer be used to sign in. A passkey of another account is never touched and is answered as not found. While the account has a confirmed second factor, the bearer token must show a recent multi-factor sign-in (step-up, RFC 9470). When the deletion leaves the account without any confirmed second factor, every trusted device of the account is revoked too.


/api/account/passkeys/{id}

Usage and SDK Samples

curl -X DELETE \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/problem+json" \
 "http://localhost:9000/api/account/passkeys/{id}"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.PasskeysApi;

import java.io.File;
import java.util.*;

public class PasskeysApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        PasskeysApi apiInstance = new PasskeysApi();
        String id = id_example; // String | Credential identifier of the passkey, as unpadded base64url.

        try {
            apiInstance.deletePasskey(id);
        } catch (ApiException e) {
            System.err.println("Exception when calling PasskeysApi#deletePasskey");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final String id = new String(); // String | Credential identifier of the passkey, as unpadded base64url.

try {
    final result = await api_instance.deletePasskey(id);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->deletePasskey: $e\n');
}

import org.openapitools.client.api.PasskeysApi;

public class PasskeysApiExample {
    public static void main(String[] args) {
        PasskeysApi apiInstance = new PasskeysApi();
        String id = id_example; // String | Credential identifier of the passkey, as unpadded base64url.

        try {
            apiInstance.deletePasskey(id);
        } catch (ApiException e) {
            System.err.println("Exception when calling PasskeysApi#deletePasskey");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
PasskeysApi *apiInstance = [[PasskeysApi alloc] init];
String *id = id_example; // Credential identifier of the passkey, as unpadded base64url. (default to null)

// Deletes a passkey
[apiInstance deletePasskeyWith:id
              completionHandler: ^(NSError* error) {
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.PasskeysApi()
var id = id_example; // {String} Credential identifier of the passkey, as unpadded base64url.

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.deletePasskey(id, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class deletePasskeyExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new PasskeysApi();
            var id = id_example;  // String | Credential identifier of the passkey, as unpadded base64url. (default to null)

            try {
                // Deletes a passkey
                apiInstance.deletePasskey(id);
            } catch (Exception e) {
                Debug.Print("Exception when calling PasskeysApi.deletePasskey: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\PasskeysApi();
$id = id_example; // String | Credential identifier of the passkey, as unpadded base64url.

try {
    $api_instance->deletePasskey($id);
} catch (Exception $e) {
    echo 'Exception when calling PasskeysApi->deletePasskey: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::PasskeysApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::PasskeysApi->new();
my $id = id_example; # String | Credential identifier of the passkey, as unpadded base64url.

eval {
    $api_instance->deletePasskey(id => $id);
};
if ($@) {
    warn "Exception when calling PasskeysApi->deletePasskey: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.PasskeysApi()
id = id_example # String | Credential identifier of the passkey, as unpadded base64url. (default to null)

try:
    # Deletes a passkey
    api_instance.delete_passkey(id)
except ApiException as e:
    print("Exception when calling PasskeysApi->deletePasskey: %s\n" % e)
extern crate PasskeysApi;

pub fn main() {
    let id = id_example; // String

    let mut context = PasskeysApi::Context::default();
    let result = client.deletePasskey(id, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Path parameters
Name Description
id*
String
Credential identifier of the passkey, as unpadded base64url.
Required

Responses

Name Type Format Description
WWW-Authenticate String


listPasskeys

Lists the passkeys

Lists the passkeys registered by the authenticated account, never anything of another account.


/api/account/passkeys

Usage and SDK Samples

curl -X GET \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json" \
 "http://localhost:9000/api/account/passkeys"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.PasskeysApi;

import java.io.File;
import java.util.*;

public class PasskeysApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        PasskeysApi apiInstance = new PasskeysApi();

        try {
            array[Passkey] result = apiInstance.listPasskeys();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling PasskeysApi#listPasskeys");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();


try {
    final result = await api_instance.listPasskeys();
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->listPasskeys: $e\n');
}

import org.openapitools.client.api.PasskeysApi;

public class PasskeysApiExample {
    public static void main(String[] args) {
        PasskeysApi apiInstance = new PasskeysApi();

        try {
            array[Passkey] result = apiInstance.listPasskeys();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling PasskeysApi#listPasskeys");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
PasskeysApi *apiInstance = [[PasskeysApi alloc] init];

// Lists the passkeys
[apiInstance listPasskeysWithCompletionHandler: 
              ^(array[Passkey] output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.PasskeysApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.listPasskeys(callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class listPasskeysExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new PasskeysApi();

            try {
                // Lists the passkeys
                array[Passkey] result = apiInstance.listPasskeys();
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling PasskeysApi.listPasskeys: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\PasskeysApi();

try {
    $result = $api_instance->listPasskeys();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling PasskeysApi->listPasskeys: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::PasskeysApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::PasskeysApi->new();

eval {
    my $result = $api_instance->listPasskeys();
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling PasskeysApi->listPasskeys: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.PasskeysApi()

try:
    # Lists the passkeys
    api_response = api_instance.list_passkeys()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling PasskeysApi->listPasskeys: %s\n" % e)
extern crate PasskeysApi;

pub fn main() {

    let mut context = PasskeysApi::Context::default();
    let result = client.listPasskeys(&context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Responses

Name Type Format Description
WWW-Authenticate String

renamePasskey

Renames a passkey

Changes the label that identifies the passkey in the list. A passkey of another account is never touched and is answered as not found.


/api/account/passkeys/{id}

Usage and SDK Samples

curl -X PATCH \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json,application/problem+json" \
 -H "Content-Type: application/json" \
 "http://localhost:9000/api/account/passkeys/{id}" \
 -d '{
  "label" : "label"
}'
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.PasskeysApi;

import java.io.File;
import java.util.*;

public class PasskeysApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        PasskeysApi apiInstance = new PasskeysApi();
        String id = id_example; // String | Credential identifier of the passkey, as unpadded base64url.
        RenamePasskeyRequest renamePasskeyRequest = ; // RenamePasskeyRequest | 

        try {
            Passkey result = apiInstance.renamePasskey(id, renamePasskeyRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling PasskeysApi#renamePasskey");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final String id = new String(); // String | Credential identifier of the passkey, as unpadded base64url.
final RenamePasskeyRequest renamePasskeyRequest = new RenamePasskeyRequest(); // RenamePasskeyRequest | 

try {
    final result = await api_instance.renamePasskey(id, renamePasskeyRequest);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->renamePasskey: $e\n');
}

import org.openapitools.client.api.PasskeysApi;

public class PasskeysApiExample {
    public static void main(String[] args) {
        PasskeysApi apiInstance = new PasskeysApi();
        String id = id_example; // String | Credential identifier of the passkey, as unpadded base64url.
        RenamePasskeyRequest renamePasskeyRequest = ; // RenamePasskeyRequest | 

        try {
            Passkey result = apiInstance.renamePasskey(id, renamePasskeyRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling PasskeysApi#renamePasskey");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
PasskeysApi *apiInstance = [[PasskeysApi alloc] init];
String *id = id_example; // Credential identifier of the passkey, as unpadded base64url. (default to null)
RenamePasskeyRequest *renamePasskeyRequest = ; // 

// Renames a passkey
[apiInstance renamePasskeyWith:id
    renamePasskeyRequest:renamePasskeyRequest
              completionHandler: ^(Passkey output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.PasskeysApi()
var id = id_example; // {String} Credential identifier of the passkey, as unpadded base64url.
var renamePasskeyRequest = ; // {RenamePasskeyRequest} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.renamePasskey(id, renamePasskeyRequest, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class renamePasskeyExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new PasskeysApi();
            var id = id_example;  // String | Credential identifier of the passkey, as unpadded base64url. (default to null)
            var renamePasskeyRequest = new RenamePasskeyRequest(); // RenamePasskeyRequest | 

            try {
                // Renames a passkey
                Passkey result = apiInstance.renamePasskey(id, renamePasskeyRequest);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling PasskeysApi.renamePasskey: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\PasskeysApi();
$id = id_example; // String | Credential identifier of the passkey, as unpadded base64url.
$renamePasskeyRequest = ; // RenamePasskeyRequest | 

try {
    $result = $api_instance->renamePasskey($id, $renamePasskeyRequest);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling PasskeysApi->renamePasskey: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::PasskeysApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::PasskeysApi->new();
my $id = id_example; # String | Credential identifier of the passkey, as unpadded base64url.
my $renamePasskeyRequest = WWW::OPenAPIClient::Object::RenamePasskeyRequest->new(); # RenamePasskeyRequest | 

eval {
    my $result = $api_instance->renamePasskey(id => $id, renamePasskeyRequest => $renamePasskeyRequest);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling PasskeysApi->renamePasskey: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.PasskeysApi()
id = id_example # String | Credential identifier of the passkey, as unpadded base64url. (default to null)
renamePasskeyRequest =  # RenamePasskeyRequest | 

try:
    # Renames a passkey
    api_response = api_instance.rename_passkey(id, renamePasskeyRequest)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling PasskeysApi->renamePasskey: %s\n" % e)
extern crate PasskeysApi;

pub fn main() {
    let id = id_example; // String
    let renamePasskeyRequest = ; // RenamePasskeyRequest

    let mut context = PasskeysApi::Context::default();
    let result = client.renamePasskey(id, renamePasskeyRequest, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Path parameters
Name Description
id*
String
Credential identifier of the passkey, as unpadded base64url.
Required
Body parameters
Name Description
renamePasskeyRequest *

Responses

Name Type Format Description
WWW-Authenticate String


Phone

getPhone

Gets the verified phone number

Answers the verified phone number of the authenticated account, masked so that only its last digits are shown. A number whose verification is still pending is not reported, and neither is any number of another account.


/api/account/phone

Usage and SDK Samples

curl -X GET \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json,application/problem+json" \
 "http://localhost:9000/api/account/phone"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.PhoneApi;

import java.io.File;
import java.util.*;

public class PhoneApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        PhoneApi apiInstance = new PhoneApi();

        try {
            PhoneResponse result = apiInstance.getPhone();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling PhoneApi#getPhone");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();


try {
    final result = await api_instance.getPhone();
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->getPhone: $e\n');
}

import org.openapitools.client.api.PhoneApi;

public class PhoneApiExample {
    public static void main(String[] args) {
        PhoneApi apiInstance = new PhoneApi();

        try {
            PhoneResponse result = apiInstance.getPhone();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling PhoneApi#getPhone");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
PhoneApi *apiInstance = [[PhoneApi alloc] init];

// Gets the verified phone number
[apiInstance getPhoneWithCompletionHandler: 
              ^(PhoneResponse output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.PhoneApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getPhone(callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class getPhoneExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new PhoneApi();

            try {
                // Gets the verified phone number
                PhoneResponse result = apiInstance.getPhone();
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling PhoneApi.getPhone: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\PhoneApi();

try {
    $result = $api_instance->getPhone();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling PhoneApi->getPhone: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::PhoneApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::PhoneApi->new();

eval {
    my $result = $api_instance->getPhone();
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling PhoneApi->getPhone: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.PhoneApi()

try:
    # Gets the verified phone number
    api_response = api_instance.get_phone()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling PhoneApi->getPhone: %s\n" % e)
extern crate PhoneApi;

pub fn main() {

    let mut context = PhoneApi::Context::default();
    let result = client.getPhone(&context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Responses

Name Type Format Description
WWW-Authenticate String


removePhone

Removes the phone number

Removes the verified phone number and any pending verification of the authenticated account, so SMS codes can no longer be used, and audits the removal; when the account is then left without any confirmed second factor, every trusted device of the account is revoked. Removing a phone that is not set succeeds as well. While the account has a confirmed second factor, the bearer token must show a recent multi-factor sign-in (step-up, RFC 9470).


/api/account/phone

Usage and SDK Samples

curl -X DELETE \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/problem+json" \
 "http://localhost:9000/api/account/phone"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.PhoneApi;

import java.io.File;
import java.util.*;

public class PhoneApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        PhoneApi apiInstance = new PhoneApi();

        try {
            apiInstance.removePhone();
        } catch (ApiException e) {
            System.err.println("Exception when calling PhoneApi#removePhone");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();


try {
    final result = await api_instance.removePhone();
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->removePhone: $e\n');
}

import org.openapitools.client.api.PhoneApi;

public class PhoneApiExample {
    public static void main(String[] args) {
        PhoneApi apiInstance = new PhoneApi();

        try {
            apiInstance.removePhone();
        } catch (ApiException e) {
            System.err.println("Exception when calling PhoneApi#removePhone");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
PhoneApi *apiInstance = [[PhoneApi alloc] init];

// Removes the phone number
[apiInstance removePhoneWithCompletionHandler: 
              ^(NSError* error) {
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.PhoneApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.removePhone(callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class removePhoneExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new PhoneApi();

            try {
                // Removes the phone number
                apiInstance.removePhone();
            } catch (Exception e) {
                Debug.Print("Exception when calling PhoneApi.removePhone: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\PhoneApi();

try {
    $api_instance->removePhone();
} catch (Exception $e) {
    echo 'Exception when calling PhoneApi->removePhone: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::PhoneApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::PhoneApi->new();

eval {
    $api_instance->removePhone();
};
if ($@) {
    warn "Exception when calling PhoneApi->removePhone: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.PhoneApi()

try:
    # Removes the phone number
    api_instance.remove_phone()
except ApiException as e:
    print("Exception when calling PhoneApi->removePhone: %s\n" % e)
extern crate PhoneApi;

pub fn main() {

    let mut context = PhoneApi::Context::default();
    let result = client.removePhone(&context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Responses

Name Type Format Description
WWW-Authenticate String

startPhoneEnrolment

Starts the enrolment of a phone number

Normalises the number to E.164 (a number without a country prefix is read in the default region of the server), checks that SMS messages may be sent to its country and sends a verification code by SMS. The enrolment is pending until it is confirmed with the code on POST /api/account/phone/verify; starting it again replaces the pending one. The answer is the same whether or not the number already belongs to another account, and in that case no message is sent, so the endpoint never reveals which numbers are registered. The message is sent after the answer, so a slow or failing SMS gateway never shows in it. Limited per client address and per account. While the account has a confirmed second factor (the new number would replace the verified one), the bearer token must show a recent multi-factor sign-in (step-up, RFC 9470).


/api/account/phone

Usage and SDK Samples

curl -X PUT \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json,application/problem+json" \
 -H "Content-Type: application/json" \
 "http://localhost:9000/api/account/phone" \
 -d '{
  "phone" : "phone"
}'
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.PhoneApi;

import java.io.File;
import java.util.*;

public class PhoneApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        PhoneApi apiInstance = new PhoneApi();
        StartPhoneEnrolmentRequest startPhoneEnrolmentRequest = ; // StartPhoneEnrolmentRequest | 

        try {
            PhoneEnrolmentResponse result = apiInstance.startPhoneEnrolment(startPhoneEnrolmentRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling PhoneApi#startPhoneEnrolment");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final StartPhoneEnrolmentRequest startPhoneEnrolmentRequest = new StartPhoneEnrolmentRequest(); // StartPhoneEnrolmentRequest | 

try {
    final result = await api_instance.startPhoneEnrolment(startPhoneEnrolmentRequest);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->startPhoneEnrolment: $e\n');
}

import org.openapitools.client.api.PhoneApi;

public class PhoneApiExample {
    public static void main(String[] args) {
        PhoneApi apiInstance = new PhoneApi();
        StartPhoneEnrolmentRequest startPhoneEnrolmentRequest = ; // StartPhoneEnrolmentRequest | 

        try {
            PhoneEnrolmentResponse result = apiInstance.startPhoneEnrolment(startPhoneEnrolmentRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling PhoneApi#startPhoneEnrolment");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
PhoneApi *apiInstance = [[PhoneApi alloc] init];
StartPhoneEnrolmentRequest *startPhoneEnrolmentRequest = ; // 

// Starts the enrolment of a phone number
[apiInstance startPhoneEnrolmentWith:startPhoneEnrolmentRequest
              completionHandler: ^(PhoneEnrolmentResponse output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.PhoneApi()
var startPhoneEnrolmentRequest = ; // {StartPhoneEnrolmentRequest} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.startPhoneEnrolment(startPhoneEnrolmentRequest, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class startPhoneEnrolmentExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new PhoneApi();
            var startPhoneEnrolmentRequest = new StartPhoneEnrolmentRequest(); // StartPhoneEnrolmentRequest | 

            try {
                // Starts the enrolment of a phone number
                PhoneEnrolmentResponse result = apiInstance.startPhoneEnrolment(startPhoneEnrolmentRequest);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling PhoneApi.startPhoneEnrolment: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\PhoneApi();
$startPhoneEnrolmentRequest = ; // StartPhoneEnrolmentRequest | 

try {
    $result = $api_instance->startPhoneEnrolment($startPhoneEnrolmentRequest);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling PhoneApi->startPhoneEnrolment: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::PhoneApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::PhoneApi->new();
my $startPhoneEnrolmentRequest = WWW::OPenAPIClient::Object::StartPhoneEnrolmentRequest->new(); # StartPhoneEnrolmentRequest | 

eval {
    my $result = $api_instance->startPhoneEnrolment(startPhoneEnrolmentRequest => $startPhoneEnrolmentRequest);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling PhoneApi->startPhoneEnrolment: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.PhoneApi()
startPhoneEnrolmentRequest =  # StartPhoneEnrolmentRequest | 

try:
    # Starts the enrolment of a phone number
    api_response = api_instance.start_phone_enrolment(startPhoneEnrolmentRequest)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling PhoneApi->startPhoneEnrolment: %s\n" % e)
extern crate PhoneApi;

pub fn main() {
    let startPhoneEnrolmentRequest = ; // StartPhoneEnrolmentRequest

    let mut context = PhoneApi::Context::default();
    let result = client.startPhoneEnrolment(startPhoneEnrolmentRequest, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Body parameters
Name Description
startPhoneEnrolmentRequest *

Responses

Name Type Format Description
WWW-Authenticate String

Name Type Format Description
Retry-After Long int64

verifyPhone

Confirms the phone number with the code sent by SMS

Checks the code against the pending verification of the authenticated account. A correct code makes the number the verified phone of the account; a wrong one counts as an attempt, and the verification is discarded after too many. A number that replaces another verified one is audited as the removal of a second factor and revokes every trusted device of the account. Limited per client address and per account.


/api/account/phone/verify

Usage and SDK Samples

curl -X POST \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json,application/problem+json" \
 -H "Content-Type: application/json" \
 "http://localhost:9000/api/account/phone/verify" \
 -d '{
  "code" : "code"
}'
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.PhoneApi;

import java.io.File;
import java.util.*;

public class PhoneApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        PhoneApi apiInstance = new PhoneApi();
        VerifyPhoneRequest verifyPhoneRequest = ; // VerifyPhoneRequest | 

        try {
            PhoneResponse result = apiInstance.verifyPhone(verifyPhoneRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling PhoneApi#verifyPhone");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final VerifyPhoneRequest verifyPhoneRequest = new VerifyPhoneRequest(); // VerifyPhoneRequest | 

try {
    final result = await api_instance.verifyPhone(verifyPhoneRequest);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->verifyPhone: $e\n');
}

import org.openapitools.client.api.PhoneApi;

public class PhoneApiExample {
    public static void main(String[] args) {
        PhoneApi apiInstance = new PhoneApi();
        VerifyPhoneRequest verifyPhoneRequest = ; // VerifyPhoneRequest | 

        try {
            PhoneResponse result = apiInstance.verifyPhone(verifyPhoneRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling PhoneApi#verifyPhone");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
PhoneApi *apiInstance = [[PhoneApi alloc] init];
VerifyPhoneRequest *verifyPhoneRequest = ; // 

// Confirms the phone number with the code sent by SMS
[apiInstance verifyPhoneWith:verifyPhoneRequest
              completionHandler: ^(PhoneResponse output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.PhoneApi()
var verifyPhoneRequest = ; // {VerifyPhoneRequest} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.verifyPhone(verifyPhoneRequest, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class verifyPhoneExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new PhoneApi();
            var verifyPhoneRequest = new VerifyPhoneRequest(); // VerifyPhoneRequest | 

            try {
                // Confirms the phone number with the code sent by SMS
                PhoneResponse result = apiInstance.verifyPhone(verifyPhoneRequest);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling PhoneApi.verifyPhone: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\PhoneApi();
$verifyPhoneRequest = ; // VerifyPhoneRequest | 

try {
    $result = $api_instance->verifyPhone($verifyPhoneRequest);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling PhoneApi->verifyPhone: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::PhoneApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::PhoneApi->new();
my $verifyPhoneRequest = WWW::OPenAPIClient::Object::VerifyPhoneRequest->new(); # VerifyPhoneRequest | 

eval {
    my $result = $api_instance->verifyPhone(verifyPhoneRequest => $verifyPhoneRequest);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling PhoneApi->verifyPhone: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.PhoneApi()
verifyPhoneRequest =  # VerifyPhoneRequest | 

try:
    # Confirms the phone number with the code sent by SMS
    api_response = api_instance.verify_phone(verifyPhoneRequest)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling PhoneApi->verifyPhone: %s\n" % e)
extern crate PhoneApi;

pub fn main() {
    let verifyPhoneRequest = ; // VerifyPhoneRequest

    let mut context = PhoneApi::Context::default();
    let result = client.verifyPhone(verifyPhoneRequest, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Body parameters
Name Description
verifyPhoneRequest *

Responses

Name Type Format Description
WWW-Authenticate String

Name Type Format Description
Retry-After Long int64

RecoveryCodes

generateRecoveryCodes

Generates a new set of recovery codes

Replaces every existing recovery code of the authenticated account with a new set, shown only in this answer. Recovery codes only stand in for a second factor, so the account must have a confirmed authenticator app; the bearer token must also show a recent multi-factor sign-in (step-up, RFC 9470).


/api/account/recovery-codes

Usage and SDK Samples

curl -X POST \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json,application/problem+json" \
 "http://localhost:9000/api/account/recovery-codes"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.RecoveryCodesApi;

import java.io.File;
import java.util.*;

public class RecoveryCodesApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        RecoveryCodesApi apiInstance = new RecoveryCodesApi();

        try {
            RecoveryCodesResponse result = apiInstance.generateRecoveryCodes();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling RecoveryCodesApi#generateRecoveryCodes");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();


try {
    final result = await api_instance.generateRecoveryCodes();
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->generateRecoveryCodes: $e\n');
}

import org.openapitools.client.api.RecoveryCodesApi;

public class RecoveryCodesApiExample {
    public static void main(String[] args) {
        RecoveryCodesApi apiInstance = new RecoveryCodesApi();

        try {
            RecoveryCodesResponse result = apiInstance.generateRecoveryCodes();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling RecoveryCodesApi#generateRecoveryCodes");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
RecoveryCodesApi *apiInstance = [[RecoveryCodesApi alloc] init];

// Generates a new set of recovery codes
[apiInstance generateRecoveryCodesWithCompletionHandler: 
              ^(RecoveryCodesResponse output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.RecoveryCodesApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.generateRecoveryCodes(callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class generateRecoveryCodesExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new RecoveryCodesApi();

            try {
                // Generates a new set of recovery codes
                RecoveryCodesResponse result = apiInstance.generateRecoveryCodes();
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling RecoveryCodesApi.generateRecoveryCodes: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\RecoveryCodesApi();

try {
    $result = $api_instance->generateRecoveryCodes();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling RecoveryCodesApi->generateRecoveryCodes: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::RecoveryCodesApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::RecoveryCodesApi->new();

eval {
    my $result = $api_instance->generateRecoveryCodes();
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling RecoveryCodesApi->generateRecoveryCodes: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.RecoveryCodesApi()

try:
    # Generates a new set of recovery codes
    api_response = api_instance.generate_recovery_codes()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling RecoveryCodesApi->generateRecoveryCodes: %s\n" % e)
extern crate RecoveryCodesApi;

pub fn main() {

    let mut context = RecoveryCodesApi::Context::default();
    let result = client.generateRecoveryCodes(&context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Responses

Name Type Format Description
WWW-Authenticate String

SigningKeys

listSigningKeys

Lists the signing keys

Never exposes private key material. Needs scope admin.


/api/admin/keys

Usage and SDK Samples

curl -X GET \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json" \
 "http://localhost:9000/api/admin/keys"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.SigningKeysApi;

import java.io.File;
import java.util.*;

public class SigningKeysApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        SigningKeysApi apiInstance = new SigningKeysApi();

        try {
            array[SigningKeyResponse] result = apiInstance.listSigningKeys();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling SigningKeysApi#listSigningKeys");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();


try {
    final result = await api_instance.listSigningKeys();
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->listSigningKeys: $e\n');
}

import org.openapitools.client.api.SigningKeysApi;

public class SigningKeysApiExample {
    public static void main(String[] args) {
        SigningKeysApi apiInstance = new SigningKeysApi();

        try {
            array[SigningKeyResponse] result = apiInstance.listSigningKeys();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling SigningKeysApi#listSigningKeys");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
SigningKeysApi *apiInstance = [[SigningKeysApi alloc] init];

// Lists the signing keys
[apiInstance listSigningKeysWithCompletionHandler: 
              ^(array[SigningKeyResponse] output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.SigningKeysApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.listSigningKeys(callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class listSigningKeysExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new SigningKeysApi();

            try {
                // Lists the signing keys
                array[SigningKeyResponse] result = apiInstance.listSigningKeys();
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling SigningKeysApi.listSigningKeys: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\SigningKeysApi();

try {
    $result = $api_instance->listSigningKeys();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling SigningKeysApi->listSigningKeys: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::SigningKeysApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::SigningKeysApi->new();

eval {
    my $result = $api_instance->listSigningKeys();
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling SigningKeysApi->listSigningKeys: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.SigningKeysApi()

try:
    # Lists the signing keys
    api_response = api_instance.list_signing_keys()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling SigningKeysApi->listSigningKeys: %s\n" % e)
extern crate SigningKeysApi;

pub fn main() {

    let mut context = SigningKeysApi::Context::default();
    let result = client.listSigningKeys(&context).wait();

    println!("{:?}", result);
}

Scopes

admin Access token issued by this server for the audience authserver.api.audience (default auth-server). The /api/admin/** operations also need the admin scope, listed as the role of their security requirement. Failures are answered with an RFC 6750 WWW-Authenticate challenge and no body.

Parameters

Responses

Name Type Format Description
WWW-Authenticate String

Name Type Format Description
WWW-Authenticate String

rotateSigningKeys

Rotates the signing keys now

Forces a rotation whatever the age of the active key: the active key is retired (it stays published until the tokens it signed expire), the next key becomes active and a new next key is generated. Keys retired for longer than the retention are deleted, and the published keys are refreshed. The scheduled rotation, in contrast, only rotates a key that is due. Needs scope admin.


/api/admin/keys/rotate

Usage and SDK Samples

curl -X POST \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json" \
 "http://localhost:9000/api/admin/keys/rotate"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.SigningKeysApi;

import java.io.File;
import java.util.*;

public class SigningKeysApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        SigningKeysApi apiInstance = new SigningKeysApi();

        try {
            array[SigningKeyResponse] result = apiInstance.rotateSigningKeys();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling SigningKeysApi#rotateSigningKeys");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();


try {
    final result = await api_instance.rotateSigningKeys();
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->rotateSigningKeys: $e\n');
}

import org.openapitools.client.api.SigningKeysApi;

public class SigningKeysApiExample {
    public static void main(String[] args) {
        SigningKeysApi apiInstance = new SigningKeysApi();

        try {
            array[SigningKeyResponse] result = apiInstance.rotateSigningKeys();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling SigningKeysApi#rotateSigningKeys");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
SigningKeysApi *apiInstance = [[SigningKeysApi alloc] init];

// Rotates the signing keys now
[apiInstance rotateSigningKeysWithCompletionHandler: 
              ^(array[SigningKeyResponse] output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.SigningKeysApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.rotateSigningKeys(callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class rotateSigningKeysExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new SigningKeysApi();

            try {
                // Rotates the signing keys now
                array[SigningKeyResponse] result = apiInstance.rotateSigningKeys();
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling SigningKeysApi.rotateSigningKeys: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\SigningKeysApi();

try {
    $result = $api_instance->rotateSigningKeys();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling SigningKeysApi->rotateSigningKeys: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::SigningKeysApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::SigningKeysApi->new();

eval {
    my $result = $api_instance->rotateSigningKeys();
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling SigningKeysApi->rotateSigningKeys: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.SigningKeysApi()

try:
    # Rotates the signing keys now
    api_response = api_instance.rotate_signing_keys()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling SigningKeysApi->rotateSigningKeys: %s\n" % e)
extern crate SigningKeysApi;

pub fn main() {

    let mut context = SigningKeysApi::Context::default();
    let result = client.rotateSigningKeys(&context).wait();

    println!("{:?}", result);
}

Scopes

admin Access token issued by this server for the audience authserver.api.audience (default auth-server). The /api/admin/** operations also need the admin scope, listed as the role of their security requirement. Failures are answered with an RFC 6750 WWW-Authenticate challenge and no body.

Parameters

Responses

Name Type Format Description
WWW-Authenticate String

Name Type Format Description
WWW-Authenticate String

Totp

confirmTotp

Confirms the enrolment of the authenticator app

Checks a code produced by the authenticator app against the pending secret, enables the factor and generates a fresh set of recovery codes, shown only in this answer.


/api/account/totp/confirm

Usage and SDK Samples

curl -X POST \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json,application/problem+json" \
 -H "Content-Type: application/json" \
 "http://localhost:9000/api/account/totp/confirm" \
 -d '{
  "code" : "code"
}'
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.TotpApi;

import java.io.File;
import java.util.*;

public class TotpApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        TotpApi apiInstance = new TotpApi();
        ConfirmTotpRequest confirmTotpRequest = ; // ConfirmTotpRequest | 

        try {
            RecoveryCodesResponse result = apiInstance.confirmTotp(confirmTotpRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TotpApi#confirmTotp");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final ConfirmTotpRequest confirmTotpRequest = new ConfirmTotpRequest(); // ConfirmTotpRequest | 

try {
    final result = await api_instance.confirmTotp(confirmTotpRequest);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->confirmTotp: $e\n');
}

import org.openapitools.client.api.TotpApi;

public class TotpApiExample {
    public static void main(String[] args) {
        TotpApi apiInstance = new TotpApi();
        ConfirmTotpRequest confirmTotpRequest = ; // ConfirmTotpRequest | 

        try {
            RecoveryCodesResponse result = apiInstance.confirmTotp(confirmTotpRequest);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TotpApi#confirmTotp");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
TotpApi *apiInstance = [[TotpApi alloc] init];
ConfirmTotpRequest *confirmTotpRequest = ; // 

// Confirms the enrolment of the authenticator app
[apiInstance confirmTotpWith:confirmTotpRequest
              completionHandler: ^(RecoveryCodesResponse output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.TotpApi()
var confirmTotpRequest = ; // {ConfirmTotpRequest} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.confirmTotp(confirmTotpRequest, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class confirmTotpExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new TotpApi();
            var confirmTotpRequest = new ConfirmTotpRequest(); // ConfirmTotpRequest | 

            try {
                // Confirms the enrolment of the authenticator app
                RecoveryCodesResponse result = apiInstance.confirmTotp(confirmTotpRequest);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling TotpApi.confirmTotp: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\TotpApi();
$confirmTotpRequest = ; // ConfirmTotpRequest | 

try {
    $result = $api_instance->confirmTotp($confirmTotpRequest);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling TotpApi->confirmTotp: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::TotpApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::TotpApi->new();
my $confirmTotpRequest = WWW::OPenAPIClient::Object::ConfirmTotpRequest->new(); # ConfirmTotpRequest | 

eval {
    my $result = $api_instance->confirmTotp(confirmTotpRequest => $confirmTotpRequest);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling TotpApi->confirmTotp: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.TotpApi()
confirmTotpRequest =  # ConfirmTotpRequest | 

try:
    # Confirms the enrolment of the authenticator app
    api_response = api_instance.confirm_totp(confirmTotpRequest)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TotpApi->confirmTotp: %s\n" % e)
extern crate TotpApi;

pub fn main() {
    let confirmTotpRequest = ; // ConfirmTotpRequest

    let mut context = TotpApi::Context::default();
    let result = client.confirmTotp(confirmTotpRequest, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Body parameters
Name Description
confirmTotpRequest *

Responses

Name Type Format Description
WWW-Authenticate String


disableTotp

Disables the authenticator app

Removes the authenticator app and the recovery codes of the authenticated account and revokes every trusted device of the account. Disabling a factor that is not enabled succeeds as well. While the account has a confirmed second factor, the bearer token must show a recent multi-factor sign-in (step-up, RFC 9470).


/api/account/totp

Usage and SDK Samples

curl -X DELETE \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/problem+json" \
 "http://localhost:9000/api/account/totp"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.TotpApi;

import java.io.File;
import java.util.*;

public class TotpApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        TotpApi apiInstance = new TotpApi();

        try {
            apiInstance.disableTotp();
        } catch (ApiException e) {
            System.err.println("Exception when calling TotpApi#disableTotp");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();


try {
    final result = await api_instance.disableTotp();
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->disableTotp: $e\n');
}

import org.openapitools.client.api.TotpApi;

public class TotpApiExample {
    public static void main(String[] args) {
        TotpApi apiInstance = new TotpApi();

        try {
            apiInstance.disableTotp();
        } catch (ApiException e) {
            System.err.println("Exception when calling TotpApi#disableTotp");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
TotpApi *apiInstance = [[TotpApi alloc] init];

// Disables the authenticator app
[apiInstance disableTotpWithCompletionHandler: 
              ^(NSError* error) {
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.TotpApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.disableTotp(callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class disableTotpExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new TotpApi();

            try {
                // Disables the authenticator app
                apiInstance.disableTotp();
            } catch (Exception e) {
                Debug.Print("Exception when calling TotpApi.disableTotp: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\TotpApi();

try {
    $api_instance->disableTotp();
} catch (Exception $e) {
    echo 'Exception when calling TotpApi->disableTotp: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::TotpApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::TotpApi->new();

eval {
    $api_instance->disableTotp();
};
if ($@) {
    warn "Exception when calling TotpApi->disableTotp: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.TotpApi()

try:
    # Disables the authenticator app
    api_instance.disable_totp()
except ApiException as e:
    print("Exception when calling TotpApi->disableTotp: %s\n" % e)
extern crate TotpApi;

pub fn main() {

    let mut context = TotpApi::Context::default();
    let result = client.disableTotp(&context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Responses

Name Type Format Description
WWW-Authenticate String

enrollTotp

Starts the enrolment of an authenticator app

Generates a new shared secret for the authenticated account and answers the otpauth URI and its QR code. The enrolment is pending until it is confirmed with a code; starting it again replaces a pending secret. Requires a bearer token issued by this server.


/api/account/totp

Usage and SDK Samples

curl -X POST \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json,application/problem+json" \
 "http://localhost:9000/api/account/totp"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.TotpApi;

import java.io.File;
import java.util.*;

public class TotpApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        TotpApi apiInstance = new TotpApi();

        try {
            TotpEnrollmentResponse result = apiInstance.enrollTotp();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TotpApi#enrollTotp");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();


try {
    final result = await api_instance.enrollTotp();
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->enrollTotp: $e\n');
}

import org.openapitools.client.api.TotpApi;

public class TotpApiExample {
    public static void main(String[] args) {
        TotpApi apiInstance = new TotpApi();

        try {
            TotpEnrollmentResponse result = apiInstance.enrollTotp();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TotpApi#enrollTotp");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
TotpApi *apiInstance = [[TotpApi alloc] init];

// Starts the enrolment of an authenticator app
[apiInstance enrollTotpWithCompletionHandler: 
              ^(TotpEnrollmentResponse output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.TotpApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.enrollTotp(callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class enrollTotpExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new TotpApi();

            try {
                // Starts the enrolment of an authenticator app
                TotpEnrollmentResponse result = apiInstance.enrollTotp();
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling TotpApi.enrollTotp: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\TotpApi();

try {
    $result = $api_instance->enrollTotp();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling TotpApi->enrollTotp: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::TotpApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::TotpApi->new();

eval {
    my $result = $api_instance->enrollTotp();
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling TotpApi->enrollTotp: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.TotpApi()

try:
    # Starts the enrolment of an authenticator app
    api_response = api_instance.enroll_totp()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TotpApi->enrollTotp: %s\n" % e)
extern crate TotpApi;

pub fn main() {

    let mut context = TotpApi::Context::default();
    let result = client.enrollTotp(&context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Responses

Name Type Format Description
WWW-Authenticate String


TrustedDevices

listTrustedDevices

Lists the trusted devices

Lists the devices of the authenticated account that are still trusted, never anything of another account.


/api/account/trusted-devices

Usage and SDK Samples

curl -X GET \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/json" \
 "http://localhost:9000/api/account/trusted-devices"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.TrustedDevicesApi;

import java.io.File;
import java.util.*;

public class TrustedDevicesApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        TrustedDevicesApi apiInstance = new TrustedDevicesApi();

        try {
            array[TrustedDeviceResponse] result = apiInstance.listTrustedDevices();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TrustedDevicesApi#listTrustedDevices");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();


try {
    final result = await api_instance.listTrustedDevices();
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->listTrustedDevices: $e\n');
}

import org.openapitools.client.api.TrustedDevicesApi;

public class TrustedDevicesApiExample {
    public static void main(String[] args) {
        TrustedDevicesApi apiInstance = new TrustedDevicesApi();

        try {
            array[TrustedDeviceResponse] result = apiInstance.listTrustedDevices();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TrustedDevicesApi#listTrustedDevices");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
TrustedDevicesApi *apiInstance = [[TrustedDevicesApi alloc] init];

// Lists the trusted devices
[apiInstance listTrustedDevicesWithCompletionHandler: 
              ^(array[TrustedDeviceResponse] output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.TrustedDevicesApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.listTrustedDevices(callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class listTrustedDevicesExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new TrustedDevicesApi();

            try {
                // Lists the trusted devices
                array[TrustedDeviceResponse] result = apiInstance.listTrustedDevices();
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling TrustedDevicesApi.listTrustedDevices: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\TrustedDevicesApi();

try {
    $result = $api_instance->listTrustedDevices();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling TrustedDevicesApi->listTrustedDevices: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::TrustedDevicesApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::TrustedDevicesApi->new();

eval {
    my $result = $api_instance->listTrustedDevices();
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling TrustedDevicesApi->listTrustedDevices: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.TrustedDevicesApi()

try:
    # Lists the trusted devices
    api_response = api_instance.list_trusted_devices()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TrustedDevicesApi->listTrustedDevices: %s\n" % e)
extern crate TrustedDevicesApi;

pub fn main() {

    let mut context = TrustedDevicesApi::Context::default();
    let result = client.listTrustedDevices(&context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Responses

Name Type Format Description
WWW-Authenticate String

revokeTrustedDevice

Revokes a trusted device

The device is asked for the second factor again. A device of another account is never touched and is answered as not found. While the account has a confirmed second factor, the bearer token must show a recent multi-factor sign-in (step-up, RFC 9470).


/api/account/trusted-devices/{id}

Usage and SDK Samples

curl -X DELETE \
 -H "Authorization: Bearer [[accessToken]]" \
 -H "Accept: application/problem+json" \
 "http://localhost:9000/api/account/trusted-devices/{id}"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.TrustedDevicesApi;

import java.io.File;
import java.util.*;

public class TrustedDevicesApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();

        // Configure Bearer (JWT) access token for authorization: bearer
        HttpBearerAuth bearer = (HttpBearerAuth) defaultClient.getAuthentication("bearer");
        bearer.setBearerToken("BEARER TOKEN");

        // Create an instance of the API class
        TrustedDevicesApi apiInstance = new TrustedDevicesApi();
        UUID id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // UUID | Identifier of the trusted device.

        try {
            apiInstance.revokeTrustedDevice(id);
        } catch (ApiException e) {
            System.err.println("Exception when calling TrustedDevicesApi#revokeTrustedDevice");
            e.printStackTrace();
        }
    }
}
import 'package:openapi/api.dart';

final api_instance = DefaultApi();

final UUID id = new UUID(); // UUID | Identifier of the trusted device.

try {
    final result = await api_instance.revokeTrustedDevice(id);
    print(result);
} catch (e) {
    print('Exception when calling DefaultApi->revokeTrustedDevice: $e\n');
}

import org.openapitools.client.api.TrustedDevicesApi;

public class TrustedDevicesApiExample {
    public static void main(String[] args) {
        TrustedDevicesApi apiInstance = new TrustedDevicesApi();
        UUID id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // UUID | Identifier of the trusted device.

        try {
            apiInstance.revokeTrustedDevice(id);
        } catch (ApiException e) {
            System.err.println("Exception when calling TrustedDevicesApi#revokeTrustedDevice");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure Bearer (JWT) access token for authorization: bearer
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Create an instance of the API class
TrustedDevicesApi *apiInstance = [[TrustedDevicesApi alloc] init];
UUID *id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // Identifier of the trusted device. (default to null)

// Revokes a trusted device
[apiInstance revokeTrustedDeviceWith:id
              completionHandler: ^(NSError* error) {
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var IruruetaAuthServerApi = require('irurueta_auth_server_api');
var defaultClient = IruruetaAuthServerApi.ApiClient.instance;

// Configure Bearer (JWT) access token for authorization: bearer
var bearer = defaultClient.authentications['bearer'];
bearer.accessToken = "YOUR ACCESS TOKEN";

// Create an instance of the API class
var api = new IruruetaAuthServerApi.TrustedDevicesApi()
var id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // {UUID} Identifier of the trusted device.

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.revokeTrustedDevice(id, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class revokeTrustedDeviceExample
    {
        public void main()
        {
            // Configure Bearer (JWT) access token for authorization: bearer
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            // Create an instance of the API class
            var apiInstance = new TrustedDevicesApi();
            var id = 38400000-8cf0-11bd-b23e-10b96e4ef00d;  // UUID | Identifier of the trusted device. (default to null)

            try {
                // Revokes a trusted device
                apiInstance.revokeTrustedDevice(id);
            } catch (Exception e) {
                Debug.Print("Exception when calling TrustedDevicesApi.revokeTrustedDevice: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer (JWT) access token for authorization: bearer
OpenAPITools\Client\Configuration::getDefaultConfiguration()->setAccessToken('', 'YOUR_ACCESS_TOKEN');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\TrustedDevicesApi();
$id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // UUID | Identifier of the trusted device.

try {
    $api_instance->revokeTrustedDevice($id);
} catch (Exception $e) {
    echo 'Exception when calling TrustedDevicesApi->revokeTrustedDevice: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::TrustedDevicesApi;

# Configure Bearer (JWT) access token for authorization: bearer
$WWW::OPenAPIClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::TrustedDevicesApi->new();
my $id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; # UUID | Identifier of the trusted device.

eval {
    $api_instance->revokeTrustedDevice(id => $id);
};
if ($@) {
    warn "Exception when calling TrustedDevicesApi->revokeTrustedDevice: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint

# Configure Bearer (JWT) access token for authorization: bearer
openapi_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# Create an instance of the API class
api_instance = openapi_client.TrustedDevicesApi()
id = 38400000-8cf0-11bd-b23e-10b96e4ef00d # UUID | Identifier of the trusted device. (default to null)

try:
    # Revokes a trusted device
    api_instance.revoke_trusted_device(id)
except ApiException as e:
    print("Exception when calling TrustedDevicesApi->revokeTrustedDevice: %s\n" % e)
extern crate TrustedDevicesApi;

pub fn main() {
    let id = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // UUID

    let mut context = TrustedDevicesApi::Context::default();
    let result = client.revokeTrustedDevice(id, &context).wait();

    println!("{:?}", result);
}

Scopes

Parameters

Path parameters
Name Description
id*
UUID (uuid)
Identifier of the trusted device.
Required

Responses

Name Type Format Description
WWW-Authenticate String