Skip to content

Commit 702d96c

Browse files
authored
doc: update initialization with sap-client example
1 parent 16cc46b commit 702d96c

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

docs/usage/initialization.rst

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,23 @@ Basic initialization which is going to work for everybody:
2121
2222
northwind = pyodata.Client(SERVICE_URL, requests.Session())
2323
24+
Get the service proxy client for an OData service requiring sap-client parameter
25+
--------------------------------------------------------------------------------
26+
27+
This is a sample when it is necessary to specify sap-client:
28+
29+
.. code-block:: python
30+
31+
import pyodata
32+
import requests
33+
34+
SERVICE_URL = 'http://services.odata.org/V2/Northwind/Northwind.svc/'
35+
36+
session = requests.Session()
37+
param = {'sap-client': '510'}
38+
session.params = param
39+
northwind = pyodata.Client(SERVICE_URL, session)
40+
2441
Get the service proxy client for an OData service requiring authentication
2542
--------------------------------------------------------------------------
2643

0 commit comments

Comments
 (0)