質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.50%
Ruby on Rails 5

Ruby on Rails 5は、オープンソースのWebアプリケーションフレームワークです。「同じことを繰り返さない」というRailsの基本理念のもと、他のフレームワークより少ないコードで簡単に開発できるよう設計されています。

Q&A

0回答

331閲覧

railsでFacebookログインした後に友達リストを取得したいですが

shushiO

総合スコア12

Ruby on Rails 5

Ruby on Rails 5は、オープンソースのWebアプリケーションフレームワークです。「同じことを繰り返さない」というRailsの基本理念のもと、他のフレームワークより少ないコードで簡単に開発できるよう設計されています。

0グッド

0クリップ

投稿2019/07/13 14:11

やりたいこと

Facebookの友達リストを取得したいです。

#試したこと
こちらの記事を参考し、facebookでログインできました。
https://qiita.com/makoto15/items/ad124f611cb8adb2cf1d#%EF%BC%90%E5%89%8D%E6%8F%90

データーベースを参照したら以下のようになっているのですが、これだけだと友達リストの取得の仕方がよくわからなくて、誰が御教授いただけませんか。
User id: 1, email: "xxx", created_at: "2019-07-13 11:36:46", updated_at: "2019-07-13 11:36:46", uid: "xxxxx", provider: "facebook", name: "xxx", image: "xxxxxxx"

環境

Gemfile

1source 'https://rubygems.org' 2git_source(:github) { |repo| "https://github.com/#{repo}.git" } 3 4ruby '2.5.3' 5gem 'devise' 6gem 'omniauth' 7gem 'omniauth-facebook' 8gem 'dotenv-rails' 9 10# Bundle edge Rails instead: gem 'rails', github: 'rails/rails' 11gem 'rails', '~> 5.2.3' 12# Use sqlite3 as the database for Active Record 13gem 'sqlite3' 14# Use Puma as the app server 15gem 'puma', '~> 3.11' 16# Use SCSS for stylesheets 17gem 'sass-rails', '~> 5.0' 18# Use Uglifier as compressor for JavaScript assets 19gem 'uglifier', '>= 1.3.0' 20# See https://github.com/rails/execjs#readme for more supported runtimes 21# gem 'mini_racer', platforms: :ruby 22 23# Use CoffeeScript for .coffee assets and views 24gem 'coffee-rails', '~> 4.2' 25# Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks 26gem 'turbolinks', '~> 5' 27# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder 28gem 'jbuilder', '~> 2.5' 29# Use Redis adapter to run Action Cable in production 30# gem 'redis', '~> 4.0' 31# Use ActiveModel has_secure_password 32# gem 'bcrypt', '~> 3.1.7' 33 34# Use ActiveStorage variant 35# gem 'mini_magick', '~> 4.8' 36 37# Use Capistrano for deployment 38# gem 'capistrano-rails', group: :development 39 40# Reduces boot times through caching; required in config/boot.rb 41gem 'bootsnap', '>= 1.1.0', require: false 42 43group :development, :test do 44 # Call 'byebug' anywhere in the code to stop execution and get a debugger console 45 gem 'byebug', platforms: [:mri, :mingw, :x64_mingw] 46end 47 48group :development do 49 # Access an interactive console on exception pages or by calling 'console' anywhere in the code. 50 gem 'web-console', '>= 3.3.0' 51 gem 'listen', '>= 3.0.5', '< 3.2' 52 # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring 53 gem 'spring' 54 gem 'spring-watcher-listen', '~> 2.0.0' 55end 56 57group :test do 58 # Adds support for Capybara system testing and selenium driver 59 gem 'capybara', '>= 2.15' 60 gem 'selenium-webdriver' 61 # Easy installation and use of chromedriver to run system tests with Chrome 62 gem 'chromedriver-helper' 63end 64 65# Windows does not include zoneinfo files, so bundle the tzinfo-data gem 66gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

guest

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

まだ回答がついていません

会員登録して回答してみよう

アカウントをお持ちの方は

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.50%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問