Job details onto php website

Forum for users and developers of Bullhorn's Webservices API suite

Moderators: StaffingSupport, s.emmons, BullhornSupport

Post Reply
scdk
User
Posts: 6
Joined: Wed Dec 12, 2012 6:39 am

Job details onto php website

Post by scdk » Wed Dec 12, 2012 6:42 am

I am building a website and have been asked to integrate it into Bullhorn so that we can display job details onto the website.

I found a page within the doc to set up bullhorn api with php http://developer.bullhorn.com/Getting_S ... es_and_PHP but this requires Eclipse. Is there sample code without Eclipse using just php to conect to bullhorn and grab the job details?

Thanks

ml_nws
User
Posts: 3
Joined: Thu Nov 15, 2012 10:39 am

Re: Job details onto php website

Post by ml_nws » Thu Dec 13, 2012 11:24 am

From my experience, not really. I'm afraid that you might have a bit of work ahead of you. You will need to have invested some time and energy in learning XML-SOAP concepts and mastering the quirks of the PHP SOAP implementation (http://php.net/manual/en/book.soap.php).

If you're already comfortable with both, then you should be able to piece together what you need quite readily the Web API documentation. (http://developer.bullhorn.com/doc/version_2-0/)

If not, then there's not much that you're going to be able to accomplish without putting in some time studying and experimenting. You'll be working with very object oriented code -- these are inherently OO concepts -- and you'll need to approach your task from an object oriented perspective.

Once you're comfortable with XML-SOAP, the operation/object level of the transaction will be (or at least seem) relatively effortless.

c.choy
User
Posts: 49
Joined: Wed Dec 31, 1969 8:00 pm

Re: Job details onto php website

Post by c.choy » Thu Dec 13, 2012 12:14 pm

Hey,

Provided you have your credentials, you can make use of the following snippet.

Code: Select all

$params = array( 'trace' => 1, 'soap_version' => SOAP_1_1);
$BHClient = new SoapClient("https://api.bullhornstaffing.com/webservices-2.0/?wsdl",$params);

$username = "UserName";
$password = "Password";
$apiKey = "xxxxxx";

$session_request = new stdClass();
$session_request->username = $username;
$session_request->password = $password;
$session_request->apiKey = $apiKey;
$API_start = $BHClient->startSession($session_request);
$API_return= $API_start->return;
$API_session = $API_return->session;
The $API_session will be the session string that you'll need to pass for the other operations.

Post Reply