View Source Plaid.Institutions (elixir_plaid v1.2.1)

Plaid Institutions API calls and schema.

Link to this section Summary

Functions

Get information about Plaid institutions.

Get information about a Plaid institution.

Get information about all Plaid institutions matching the search params.

Link to this section Functions

Link to this function

get(params, options \\ %{}, config)

View Source

Specs

get(params, options, Plaid.config()) ::
  {:ok, Plaid.Institutions.GetResponse.t()} | {:error, Plaid.Error.t()}
when params: %{count: integer(), offset: integer(), country_codes: [String.t()]},
     options: %{
       optional(:products) => [String.t()],
       optional(:routing_numbers) => [String.t()],
       optional(:oauth) => boolean(),
       optional(:include_optional_metadata) => boolean()
     }

Get information about Plaid institutions.

Does a POST /institutions/get call to list the supported Plaid institutions with their details.

params

Params

  • :count - The total number of Institutions to return.
  • :offset - The number of Institutions to skip.
  • :country_codes - Array of country codes the institution supports.

options

Options

  • :products - Filter based on which products they support.
  • :routing_numbers - Filter based on routing numbers.
  • :oauth - Filter institutions with or without OAuth login flows.
  • :include_optional_metadata - When true, return the institution's homepage URL, logo and primary brand color.

examples

Examples

Institutions.get(%{count: 25, offset: 0, country_codes: ["CA", "GB]}, client_id: "123", secret: "abc")
{:ok, %Institutions.GetResponse{}}
Link to this function

get_by_id(institution_id, country_codes, options \\ %{}, config)

View Source

Specs

get_by_id(String.t(), [String.t()], options, Plaid.config()) ::
  {:ok, Plaid.Institutions.GetByIdResponse.t()} | {:error, Plaid.Error.t()}
when options: %{
       optional(:products) => [String.t()],
       optional(:routing_numbers) => [String.t()],
       optional(:oauth) => boolean(),
       optional(:include_optional_metadata) => boolean()
     }

Get information about a Plaid institution.

Does a POST /institutions/get_by_id call to retrieve a Plaid institution by it's ID.

params

Params

  • institution_id - The ID of the institution to get details about.
  • country_codes - Array of country codes the institution supports.

options

Options

  • :include_optional_metadata - When true, return the institution's homepage URL, logo and primary brand color.
  • :include_status - When true, the response will include status information about the institution.

examples

Examples

Institutions.get_by_id("ins_1", ["CA", "GB], client_id: "123", secret: "abc")
{:ok, %Institutions.GetByIdResponse{}}
Link to this function

search(params, options \\ %{}, config)

View Source

Specs

search(params, options, Plaid.config()) ::
  {:ok, Plaid.Institutions.SearchResponse.t()} | {:error, Plaid.Error.t()}
when params: %{
       query: String.t(),
       products: [String.t()],
       country_codes: [String.t()]
     },
     options: %{
       optional(:include_optional_metadata) => boolean(),
       optional(:oauth) => boolean(),
       optional(:account_filter) => map()
     }

Get information about all Plaid institutions matching the search params.

Does a POST /institutions/search call to list the supported Plaid institutions with their details based on your search query.

params

Params

  • :query - The search query. Institutions with names matching the query are returned
  • :products - Filter the Institutions based on whether they support listed products.
  • :country_codes - Array of country codes the institution supports.

options

Options

  • :include_optional_metadata - When true, return the institution's homepage URL, logo and primary brand color.
  • :oauth - Filter institutions with or without OAuth login flows.
  • :account_filter - Object allowing account type -> sub-type filtering.

See Account Type Schema for more details on the account_filter option.

examples

Examples

Institutions.search(%{query: "Ally", products: ["auth"], country_codes: ["US"]}, client_id: "123", secret: "abc")
{:ok, %Institutions.SearchResponse{}}