Created
March 14, 2017 14:15
-
-
Save aallan/73609811551147ea77cf07ac1b943f53 to your computer and use it in GitHub Desktop.
Retrieve credit score from noddle.co.uk
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(rvest) | |
library(httr) | |
set_config(config(ssl_verifypeer = 0L)) | |
url <- "https://www.noddle.co.uk/" | |
session <- html_session(url) | |
session <- jump_to(session, "https://www.noddle.co.uk/account/sign-in") | |
#session %>% html_node("form") %>% html_form() | |
login_form <- html_form(session)[[1]] | |
login_form <- set_values(login_form, Username = "XXX", Password = "YYY") | |
submit_form(session, login_form) | |
session <- jump_to(session, "https://www.noddle.co.uk/dashboard") | |
session %>% html_nodes(xpath = '//*[@class="credit-score"]') %>% html_text() | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment