All URIs are relative to https://api.affixapi.com
Method | HTTP request | Description |
---|---|---|
client | GET /2023-03-01/management/client | Client |
disconnect | POST /2023-03-01/management/disconnect | Disconnect token |
introspect | GET /2023-03-01/management/introspect | Inspect token |
token | POST /2023-03-01/management/token | Create token |
tokens | GET /2023-03-01/management/tokens | Tokens |
update_client | POST /2023-03-01/management/client | Update client |
client
Client
View client attributes
require 'time'
require 'openapi_client'
# setup authorization
OpenapiClient.configure do |config|
# Configure API key authorization: basic
config.api_key['basic'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
# config.api_key_prefix['basic'] = 'Bearer'
end
api_instance = OpenapiClient::ManagementApi.new
begin
# Client
result = api_instance.client
p result
rescue OpenapiClient::ApiError => e
puts "Error when calling ManagementApi->client: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> client_with_http_info
begin
# Client
data, status_code, headers = api_instance.client_with_http_info
p status_code # => 2xx
p headers # => { ... }
p data # => <ClientResponse>
rescue OpenapiClient::ApiError => e
puts "Error when calling ManagementApi->client_with_http_info: #{e}"
end
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
disconnect
Disconnect token
Disconnect the token. A disconnected token will no longer return data. Data requests with a disconnected token will return a 403 Forbidden
require 'time'
require 'openapi_client'
# setup authorization
OpenapiClient.configure do |config|
# Configure API key authorization: access-token
config.api_key['access-token'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
# config.api_key_prefix['access-token'] = 'Bearer'
end
api_instance = OpenapiClient::ManagementApi.new
begin
# Disconnect token
result = api_instance.disconnect
p result
rescue OpenapiClient::ApiError => e
puts "Error when calling ManagementApi->disconnect: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> disconnect_with_http_info
begin
# Disconnect token
data, status_code, headers = api_instance.disconnect_with_http_info
p status_code # => 2xx
p headers # => { ... }
p data # => <DisconnectResponse>
rescue OpenapiClient::ApiError => e
puts "Error when calling ManagementApi->disconnect_with_http_info: #{e}"
end
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
introspect
Inspect token
Retrieve data about the token, such as scopes
, mode
, provider
, and if it is active
require 'time'
require 'openapi_client'
# setup authorization
OpenapiClient.configure do |config|
# Configure API key authorization: access-token
config.api_key['access-token'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
# config.api_key_prefix['access-token'] = 'Bearer'
end
api_instance = OpenapiClient::ManagementApi.new
begin
# Inspect token
result = api_instance.introspect
p result
rescue OpenapiClient::ApiError => e
puts "Error when calling ManagementApi->introspect: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> introspect_with_http_info
begin
# Inspect token
data, status_code, headers = api_instance.introspect_with_http_info
p status_code # => 2xx
p headers # => { ... }
p data # => <IntrospectResponse>
rescue OpenapiClient::ApiError => e
puts "Error when calling ManagementApi->introspect_with_http_info: #{e}"
end
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
token(token_request)
Create token
Exchange an authorization_code
for an access_token
after receiving on from the redirect_uri
you specifiy after a successful user connection
require 'time'
require 'openapi_client'
api_instance = OpenapiClient::ManagementApi.new
token_request = OpenapiClient::TokenRequest.new({client_id: '00000000-00000000-00000000-00000000', client_secret: 'ffffffff-ffffffff-ffffffff-ffffffff', grant_type: 'authorization_code', code: 'Y2xpZW50IzkzMTU4MGQwLWYwYjctNGJiOC1iYmZmLWI4MTNlYzMxNTVjYXxjb2RlIzE1MmIwYjk3LTg2ZWMtNDZlNC1hZDUyLWY5ZTAxNzE2MDIwNAo=', redirect_uri: 'https://example.com'}) # TokenRequest |
begin
# Create token
result = api_instance.token(token_request)
p result
rescue OpenapiClient::ApiError => e
puts "Error when calling ManagementApi->token: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> token_with_http_info(token_request)
begin
# Create token
data, status_code, headers = api_instance.token_with_http_info(token_request)
p status_code # => 2xx
p headers # => { ... }
p data # => <TokenResponse>
rescue OpenapiClient::ApiError => e
puts "Error when calling ManagementApi->token_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
token_request | TokenRequest |
No authorization required
- Content-Type: application/json
- Accept: application/json
Array<Object> tokens
Tokens
View tokens and token status for respective client
require 'time'
require 'openapi_client'
# setup authorization
OpenapiClient.configure do |config|
# Configure API key authorization: basic
config.api_key['basic'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
# config.api_key_prefix['basic'] = 'Bearer'
end
api_instance = OpenapiClient::ManagementApi.new
begin
# Tokens
result = api_instance.tokens
p result
rescue OpenapiClient::ApiError => e
puts "Error when calling ManagementApi->tokens: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(Array<Object>, Integer, Hash)> tokens_with_http_info
begin
# Tokens
data, status_code, headers = api_instance.tokens_with_http_info
p status_code # => 2xx
p headers # => { ... }
p data # => Array<Object>
rescue OpenapiClient::ApiError => e
puts "Error when calling ManagementApi->tokens_with_http_info: #{e}"
end
This endpoint does not need any parameter.
Array<Object>
- Content-Type: Not defined
- Accept: application/json
update_client(client_request)
Update client
Update attributes of the client. Update the name
, client_secret
, or webhook_uri
of the client
require 'time'
require 'openapi_client'
# setup authorization
OpenapiClient.configure do |config|
# Configure API key authorization: basic
config.api_key['basic'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
# config.api_key_prefix['basic'] = 'Bearer'
end
api_instance = OpenapiClient::ManagementApi.new
client_request = OpenapiClient::ClientRequest.new({client_secret: ['client_secret_example'], redirect_uris: ['redirect_uris_example'], name: 'Your App'}) # ClientRequest |
begin
# Update client
result = api_instance.update_client(client_request)
p result
rescue OpenapiClient::ApiError => e
puts "Error when calling ManagementApi->update_client: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> update_client_with_http_info(client_request)
begin
# Update client
data, status_code, headers = api_instance.update_client_with_http_info(client_request)
p status_code # => 2xx
p headers # => { ... }
p data # => <ClientResponse>
rescue OpenapiClient::ApiError => e
puts "Error when calling ManagementApi->update_client_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
client_request | ClientRequest |
- Content-Type: application/json
- Accept: application/json