User Tools

Site Tools


ors-soap-api:public:soap_header

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
ors-soap-api:public:soap_header [2019/05/17 16:35]
admin
ors-soap-api:public:soap_header [2023/03/08 12:39]
admin
Line 17: Line 17:
   * ''​xpass''​ : user password for data export credentials   * ''​xpass''​ : user password for data export credentials
  
-**Usage:**+===== Usage: ​=====
  
 Here is an example for setting ''​$header''​ array with [[demo_licence|demo licence]] information. Here is an example for setting ''​$header''​ array with [[demo_licence|demo licence]] information.
Line 31: Line 31:
 ); );
 </​code>​ </​code>​
 +
 +===== Using API-KEY: =====
 +
 +If you have received apikey for your API licence, then you need to put api-key attribute in header array:
 +
 +<code php>
 +// ORSXML header information (using api-key
 +$header = array(
 +    '​lang' ​ => '​en', ​           // a return language
 +    '​api-key'​=>​ '​your-apikey-here' ​
 +    '​usr' ​  => '', ​             // no longer needed
 +    '​pass' ​ => '', ​             // no longer needed
 +    '​agid' ​ => '', ​             // no longer needed
 +    '​sid' ​  => session_id(), ​   // this is required so that filtering and sorting works correctly!
 +    '​limits'​ => '​p:​6,​t:​50', ​    // set limits (6 offers per page and 50 trips per page)
 +);
 +</​code>​
 +
ors-soap-api/public/soap_header.txt ยท Last modified: 2023/03/08 12:39 by admin