name, new_opts =
          case type
          when :basic then ['Authorization', opts.merge(type: type)]
          when :apiKey then [opts[:name], opts.merge(type: type, in: :header)]
          else raise 'Not supported type for authentication'