Class: Courier::Resources::Providers::Catalog
- Inherits:
-
Object
- Object
- Courier::Resources::Providers::Catalog
- Defined in:
- lib/courier/resources/providers/catalog.rb
Instance Method Summary collapse
-
#initialize(client:) ⇒ Catalog
constructor
private
A new instance of Catalog.
-
#list(channel: nil, keys: nil, name: nil, request_options: {}) ⇒ Courier::Models::Providers::CatalogListResponse
Some parameter documentations has been truncated, see Models::Providers::CatalogListParams for more details.
Constructor Details
#initialize(client:) ⇒ Catalog
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 Catalog.
43 44 45 |
# File 'lib/courier/resources/providers/catalog.rb', line 43 def initialize(client:) @client = client end |
Instance Method Details
#list(channel: nil, keys: nil, name: nil, request_options: {}) ⇒ Courier::Models::Providers::CatalogListResponse
Some parameter documentations has been truncated, see Models::Providers::CatalogListParams for more details.
Returns the catalog of available provider types with their display names, descriptions, and configuration schema fields (snake_case, with ‘type` and `required`). Providers with no configurable schema return only `provider`, `name`, and `description`.
28 29 30 31 32 33 34 35 36 37 38 |
# File 'lib/courier/resources/providers/catalog.rb', line 28 def list(params = {}) parsed, = Courier::Providers::CatalogListParams.dump_request(params) query = Courier::Internal::Util.encode_query_params(parsed) @client.request( method: :get, path: "providers/catalog", query: query, model: Courier::Models::Providers::CatalogListResponse, options: ) end |