Quantcast
Channel: VBForums - ASP, VB Script
Viewing all articles
Browse latest Browse all 688

call a webpage API and pass credentials issue

$
0
0
Hi,

I am using VB 2010 and want to call an API on a website that allows me to set and get information. The web page requires authentication so I need to pass it a username and password.

The web site is a spam filtering site and in this example it allows you to add a new domain and set the destination for the mail.

https://spamserver.example.com/cgi-b....spambrand.com

If I put this into a browser, it prompts me for the username and password and then executes the api and the domain (in this example spambrand.com) is added to the spam filter and has its destination set to mail.spambrand.com.

So what I would like to do is write a very simple VB script to do exactly this but I can't work out how to send the credentials.

Another simple example is that when I put this in my browser https://spamserver.example.com/cgi-b...e_aliases=True is simply returns a simple text dump in the browser of all the domains on the server. How do I capture that list into a variable or array so I can then do something with it?

Hope this makes sense and isn't too confusing.

Thanks

Viewing all articles
Browse latest Browse all 688

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>