All URIs are relative to http://localhost
Method | HTTP request | Description |
---|---|---|
add_o_auth_client_implicit | POST /api/oauth_add_client_implicit | Add OAUTH client_id with implicit grant type. |
add_o_auth_client_password | POST /api/oauth_add_client_password | Add OAUTH client_id with password grant type. |
issue_o_auth_token | POST /api/oauth_issue_token | Issue an oauth token for the given jid. |
list_o_auth_tokens | POST /api/oauth_list_tokens | List OAuth tokens, their users and scopes, and their time until expiration. |
remove_o_auth_client | POST /api/oauth_remove_client | Remove an OAuth client_id. |
revoke_o_auth_token | POST /api/oauth_revoke_token | Revoke an existing OAuth token. |
add_o_auth_client_implicit(add_o_auth_client_implicit_request)
Add OAUTH client_id with implicit grant type.
require 'time'
require 'ejabberd_http_client'
api_instance = EjabberdHttpClient::OauthApi.new
add_o_auth_client_implicit_request = EjabberdHttpClient::AddOAuthClientImplicitRequest.new # AddOAuthClientImplicitRequest |
begin
# Add OAUTH client_id with implicit grant type.
api_instance.add_o_auth_client_implicit(add_o_auth_client_implicit_request)
rescue EjabberdHttpClient::ApiError => e
puts "Error when calling OauthApi->add_o_auth_client_implicit: #{e}"
end
This returns an Array which contains the response data (nil
in this case), status code and headers.
<Array(nil, Integer, Hash)> add_o_auth_client_implicit_with_http_info(add_o_auth_client_implicit_request)
begin
# Add OAUTH client_id with implicit grant type.
data, status_code, headers = api_instance.add_o_auth_client_implicit_with_http_info(add_o_auth_client_implicit_request)
p status_code # => 2xx
p headers # => { ... }
p data # => nil
rescue EjabberdHttpClient::ApiError => e
puts "Error when calling OauthApi->add_o_auth_client_implicit_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
add_o_auth_client_implicit_request | AddOAuthClientImplicitRequest |
nil (empty response body)
No authorization required
- Content-Type: application/json
- Accept: Not defined
add_o_auth_client_password(add_o_auth_client_password_request)
Add OAUTH client_id with password grant type.
require 'time'
require 'ejabberd_http_client'
api_instance = EjabberdHttpClient::OauthApi.new
add_o_auth_client_password_request = EjabberdHttpClient::AddOAuthClientPasswordRequest.new # AddOAuthClientPasswordRequest |
begin
# Add OAUTH client_id with password grant type.
api_instance.add_o_auth_client_password(add_o_auth_client_password_request)
rescue EjabberdHttpClient::ApiError => e
puts "Error when calling OauthApi->add_o_auth_client_password: #{e}"
end
This returns an Array which contains the response data (nil
in this case), status code and headers.
<Array(nil, Integer, Hash)> add_o_auth_client_password_with_http_info(add_o_auth_client_password_request)
begin
# Add OAUTH client_id with password grant type.
data, status_code, headers = api_instance.add_o_auth_client_password_with_http_info(add_o_auth_client_password_request)
p status_code # => 2xx
p headers # => { ... }
p data # => nil
rescue EjabberdHttpClient::ApiError => e
puts "Error when calling OauthApi->add_o_auth_client_password_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
add_o_auth_client_password_request | AddOAuthClientPasswordRequest |
nil (empty response body)
No authorization required
- Content-Type: application/json
- Accept: Not defined
issue_o_auth_token(issue_o_auth_token_request)
Issue an oauth token for the given jid.
require 'time'
require 'ejabberd_http_client'
api_instance = EjabberdHttpClient::OauthApi.new
issue_o_auth_token_request = EjabberdHttpClient::IssueOAuthTokenRequest.new # IssueOAuthTokenRequest |
begin
# Issue an oauth token for the given jid.
result = api_instance.issue_o_auth_token(issue_o_auth_token_request)
p result
rescue EjabberdHttpClient::ApiError => e
puts "Error when calling OauthApi->issue_o_auth_token: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> issue_o_auth_token_with_http_info(issue_o_auth_token_request)
begin
# Issue an oauth token for the given jid.
data, status_code, headers = api_instance.issue_o_auth_token_with_http_info(issue_o_auth_token_request)
p status_code # => 2xx
p headers # => { ... }
p data # => <IssueOAuthToken200Response>
rescue EjabberdHttpClient::ApiError => e
puts "Error when calling OauthApi->issue_o_auth_token_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
issue_o_auth_token_request | IssueOAuthTokenRequest |
No authorization required
- Content-Type: application/json
- Accept: application/json
<Array> list_o_auth_tokens
List OAuth tokens, their users and scopes, and their time until expiration.
require 'time'
require 'ejabberd_http_client'
api_instance = EjabberdHttpClient::OauthApi.new
begin
# List OAuth tokens, their users and scopes, and their time until expiration.
result = api_instance.list_o_auth_tokens
p result
rescue EjabberdHttpClient::ApiError => e
puts "Error when calling OauthApi->list_o_auth_tokens: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(<Array>, Integer, Hash)> list_o_auth_tokens_with_http_info
begin
# List OAuth tokens, their users and scopes, and their time until expiration.
data, status_code, headers = api_instance.list_o_auth_tokens_with_http_info
p status_code # => 2xx
p headers # => { ... }
p data # => <Array<ListOAuthTokens200ResponseInner>>
rescue EjabberdHttpClient::ApiError => e
puts "Error when calling OauthApi->list_o_auth_tokens_with_http_info: #{e}"
end
This endpoint does not need any parameter.
Array<ListOAuthTokens200ResponseInner>
No authorization required
- Content-Type: Not defined
- Accept: application/json
remove_o_auth_client(remove_o_auth_client_request)
Remove an OAuth client_id.
require 'time'
require 'ejabberd_http_client'
api_instance = EjabberdHttpClient::OauthApi.new
remove_o_auth_client_request = EjabberdHttpClient::RemoveOAuthClientRequest.new # RemoveOAuthClientRequest |
begin
# Remove an OAuth client_id.
api_instance.remove_o_auth_client(remove_o_auth_client_request)
rescue EjabberdHttpClient::ApiError => e
puts "Error when calling OauthApi->remove_o_auth_client: #{e}"
end
This returns an Array which contains the response data (nil
in this case), status code and headers.
<Array(nil, Integer, Hash)> remove_o_auth_client_with_http_info(remove_o_auth_client_request)
begin
# Remove an OAuth client_id.
data, status_code, headers = api_instance.remove_o_auth_client_with_http_info(remove_o_auth_client_request)
p status_code # => 2xx
p headers # => { ... }
p data # => nil
rescue EjabberdHttpClient::ApiError => e
puts "Error when calling OauthApi->remove_o_auth_client_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
remove_o_auth_client_request | RemoveOAuthClientRequest |
nil (empty response body)
No authorization required
- Content-Type: application/json
- Accept: Not defined
revoke_o_auth_token(revoke_o_auth_token_request)
Revoke an existing OAuth token.
require 'time'
require 'ejabberd_http_client'
api_instance = EjabberdHttpClient::OauthApi.new
revoke_o_auth_token_request = EjabberdHttpClient::RevokeOAuthTokenRequest.new # RevokeOAuthTokenRequest |
begin
# Revoke an existing OAuth token.
api_instance.revoke_o_auth_token(revoke_o_auth_token_request)
rescue EjabberdHttpClient::ApiError => e
puts "Error when calling OauthApi->revoke_o_auth_token: #{e}"
end
This returns an Array which contains the response data (nil
in this case), status code and headers.
<Array(nil, Integer, Hash)> revoke_o_auth_token_with_http_info(revoke_o_auth_token_request)
begin
# Revoke an existing OAuth token.
data, status_code, headers = api_instance.revoke_o_auth_token_with_http_info(revoke_o_auth_token_request)
p status_code # => 2xx
p headers # => { ... }
p data # => nil
rescue EjabberdHttpClient::ApiError => e
puts "Error when calling OauthApi->revoke_o_auth_token_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
revoke_o_auth_token_request | RevokeOAuthTokenRequest |
nil (empty response body)
No authorization required
- Content-Type: application/json
- Accept: Not defined