Accessing website data without opening it

Hi All,

How can I access the values of a website in R shiny without opening it.

Like, I have an otp module. Where after clicking on submit button it redirects to a link and an otp is sent.

I want to bypass this, and just after clicking an otp is generated without opening of the website.

How can I do it?

can you please share the chunks of code ?


ui <- fluidPage(
textInput("mobile", "Mobile", value = "", placeholder = "Enter your number"),
actionButton("send", "Preview")

server <- function(input, output, session) {
a<- reactive({


output$try<- renderUI({
rndno <-floor(runif(1, min=1000, max= 9999))
smsmessage<-paste0('Your verification code is ',rndno)
HTML(paste0(tags$a(href= paste0("http://www.username=&password=*******&to=",a(),"&from=***&text=Your verification code is"," ",rndno,"),
"Click here")))



shinyApp(ui, server)

I think it happens HTML tag

Try this


# create your example dataset
df <- data.frame(url = c(paste0("http://www.username=&password=*******&to=",a(),
"&from=***&text=Your verification code is"," ",rndno,")"))

# Concatenate URLs
string <- paste(df$url, collapse=" ")

It's not working.

It should be like, when I enter the mobile number and click send, then it should give me the random number as an OTP without opening the link.

This topic was automatically closed 54 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.