Solved

How to pass username/password to REST API (WS) using JBossRestEasy client (2.3.6 jar)?

Posted on 2014-01-02
2
582 Views
Last Modified: 2014-01-22
Hi,

I have a REST API site requiring id/pw to connect.

I am using JBoss RestEasy 2.3.6 to consume above APIs.
It's clear to me what I need to do pass my id/pw for the authentication.
Can you help?

I thought I could pass id/pw through headers or something.
Do I need to create interceptor or filter?
Can you direct me to a example or something?
Thank you
0
Comment
Question by:dkim18
2 Comments
 
LVL 35

Accepted Solution

by:
mccarl earned 250 total points
ID: 39752688
I have a REST API site requiring id/pw to connect
We would need more info about the above. How exactly does the remote site expect the id/pw to be presented to it? ie. is it expecting HTTP "Authentication" headers, or do you need to post the id/pw to a page and then use cookies to maintain a session, etc.
0
 
LVL 11

Assisted Solution

by:Manish
Manish earned 250 total points
ID: 39753274
Do you have format of input required to call rest api? Is it JSON or something else?
Also you can send useid/password in header depends on  backend implementation.
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
HSSFWorkbook cannot be resolved error 10 69
Should localization be done inside spring controller 5 26
Reseller Hosting 2 90
jsp insert to database example 2 24
New Relic recently released its Synthetics product that allows for the creation of performance monitors that periodically test a site's performance. If you wish to test an interactive workflow New Relic employs Selenium WebDriverJS to run those test…
In order to have all security and back ups taken care of, WordPress users can sign up for services with WP Engine.
The purpose of this video is to demonstrate how to set up the WordPress backend so that each page automatically generates a Mailchimp signup form in the sidebar. This will be demonstrated using a Windows 8 PC. Tools Used are Photoshop, Awesome…
The viewer will learn how to implement Singleton Design Pattern in Java.

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question