Class: Telnyx::Resources::AuthenticationProviders
- Inherits:
-
Object
- Object
- Telnyx::Resources::AuthenticationProviders
- Defined in:
- lib/telnyx/resources/authentication_providers.rb,
sig/telnyx/resources/authentication_providers.rbs
Instance Method Summary collapse
-
#create(name:, settings:, short_name:, active: nil, settings_url: nil, request_options: {}) ⇒ Telnyx::Models::AuthenticationProviderCreateResponse
Some parameter documentations has been truncated, see Models::AuthenticationProviderCreateParams for more details.
-
#delete(id, request_options: {}) ⇒ Telnyx::Models::AuthenticationProviderDeleteResponse
Deletes an existing authentication provider.
-
#initialize(client:) ⇒ AuthenticationProviders
constructor
private
A new instance of AuthenticationProviders.
-
#list(page_number: nil, page_size: nil, sort: nil, request_options: {}) ⇒ Telnyx::Internal::DefaultFlatPagination<Telnyx::Models::AuthenticationProvider>
Some parameter documentations has been truncated, see Models::AuthenticationProviderListParams for more details.
-
#retrieve(id, request_options: {}) ⇒ Telnyx::Models::AuthenticationProviderRetrieveResponse
Retrieves the details of an existing authentication provider.
-
#update(id, active: nil, name: nil, settings: nil, settings_url: nil, short_name: nil, request_options: {}) ⇒ Telnyx::Models::AuthenticationProviderUpdateResponse
Some parameter documentations has been truncated, see Models::AuthenticationProviderUpdateParams for more details.
Constructor Details
#initialize(client:) ⇒ AuthenticationProviders
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of AuthenticationProviders.
149 150 151 |
# File 'lib/telnyx/resources/authentication_providers.rb', line 149 def initialize(client:) @client = client end |
Instance Method Details
#create(name:, settings:, short_name:, active: nil, settings_url: nil, request_options: {}) ⇒ Telnyx::Models::AuthenticationProviderCreateResponse
Some parameter documentations has been truncated, see Models::AuthenticationProviderCreateParams for more details.
Creates a new authentication provider for single sign-on, configured from the provided identity provider details, and returns the created resource.
29 30 31 32 33 34 35 36 37 38 |
# File 'lib/telnyx/resources/authentication_providers.rb', line 29 def create(params) parsed, = Telnyx::AuthenticationProviderCreateParams.dump_request(params) @client.request( method: :post, path: "authentication_providers", body: parsed, model: Telnyx::Models::AuthenticationProviderCreateResponse, options: ) end |
#delete(id, request_options: {}) ⇒ Telnyx::Models::AuthenticationProviderDeleteResponse
Deletes an existing authentication provider.
137 138 139 140 141 142 143 144 |
# File 'lib/telnyx/resources/authentication_providers.rb', line 137 def delete(id, params = {}) @client.request( method: :delete, path: ["authentication_providers/%1$s", id], model: Telnyx::Models::AuthenticationProviderDeleteResponse, options: params[:request_options] ) end |
#list(page_number: nil, page_size: nil, sort: nil, request_options: {}) ⇒ Telnyx::Internal::DefaultFlatPagination<Telnyx::Models::AuthenticationProvider>
Some parameter documentations has been truncated, see Models::AuthenticationProviderListParams for more details.
Returns a list of your SSO authentication providers.
113 114 115 116 117 118 119 120 121 122 123 124 |
# File 'lib/telnyx/resources/authentication_providers.rb', line 113 def list(params = {}) parsed, = Telnyx::AuthenticationProviderListParams.dump_request(params) query = Telnyx::Internal::Util.encode_query_params(parsed) @client.request( method: :get, path: "authentication_providers", query: query.transform_keys(page_number: "page[number]", page_size: "page[size]"), page: Telnyx::Internal::DefaultFlatPagination, model: Telnyx::AuthenticationProvider, options: ) end |
#retrieve(id, request_options: {}) ⇒ Telnyx::Models::AuthenticationProviderRetrieveResponse
Retrieves the details of an existing authentication provider.
51 52 53 54 55 56 57 58 |
# File 'lib/telnyx/resources/authentication_providers.rb', line 51 def retrieve(id, params = {}) @client.request( method: :get, path: ["authentication_providers/%1$s", id], model: Telnyx::Models::AuthenticationProviderRetrieveResponse, options: params[:request_options] ) end |
#update(id, active: nil, name: nil, settings: nil, settings_url: nil, short_name: nil, request_options: {}) ⇒ Telnyx::Models::AuthenticationProviderUpdateResponse
Some parameter documentations has been truncated, see Models::AuthenticationProviderUpdateParams for more details.
Updates settings of an existing authentication provider.
84 85 86 87 88 89 90 91 92 93 |
# File 'lib/telnyx/resources/authentication_providers.rb', line 84 def update(id, params = {}) parsed, = Telnyx::AuthenticationProviderUpdateParams.dump_request(params) @client.request( method: :patch, path: ["authentication_providers/%1$s", id], body: parsed, model: Telnyx::Models::AuthenticationProviderUpdateResponse, options: ) end |