Skip to content

Commit ce4f1e8

Browse files
authored
Update README.md
1 parent 767e123 commit ce4f1e8

File tree

1 file changed

+55
-0
lines changed

1 file changed

+55
-0
lines changed

README.md

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,58 @@ This library started out as a way of enabling the use of Zeep within Robot Frame
2323
Furthermore, my knowledge of SOAP is not anywhere near expert-level. Also, I'm sure I could've used a lot more functionality provided by Zeep if I had familiarized myself with the code more. Due to time limitations and commercially driven goals I did not study as much as I wanted to, which probably has resulted in several implementations to be of poor quality.
2424

2525
However, I'm fairly certain the code can still be useful to people and I'm willing to improve it. Its readability is really good I guess, so contributing should not be too hard :).
26+
27+
# ZeepLibrary
28+
Robot Framework library for using [Zeep](https://python-zeep.readthedocs.io/en/master).
29+
30+
## Compatibility
31+
- _Python 2.7.15_
32+
- _Zeep 2.5.0_
33+
The code might work with other versions of Zeep; I simply haven't tested this. Also, it _probably_ takes only minor tweaking to get it to work with Python 3. Currently I don't have the time nor intention to refactor the code to be compatible with both Python 2 and 3.
34+
35+
## Features
36+
Currently supported features include:
37+
- Creating SOAP client instances from WSDL files/locations.
38+
- Switching between several simultaneously opened clients by alias
39+
- Calling SOAP operations with named parameters for easy building
40+
- Optionally the SOAP message can be obtained as string instead
41+
- Adding attachments
42+
- This will result in multipart HTTP requests being built and sent
43+
- XOP serialization is also allowed (somewhat similar to how SOAP UI handles it)
44+
- Logging of raw requests/responses
45+
46+
## Disclaimer
47+
This library started out as a way of enabling the use of Zeep within Robot Framework for very specific problems I encountered, and slowly it is turning into something more mature. It's definitely not there yet though, and as I don't intend to put a lot of time into this project due to time limitations, contributions are highly appreciated.
48+
49+
Furthermore, my knowledge of SOAP is not anywhere near expert-level. Also, I'm sure I could've used a lot more functionality provided by Zeep if I had familiarized myself with the code more. Due to time limitations and commercially driven goals I did not study as much as I wanted to, which probably has resulted in several implementations to be of poor quality.
50+
51+
However, I'm fairly certain the code can still be useful to people and I'm willing to improve it. Its readability is really good I guess, so contributing should not be too hard :).
52+
53+
## Example
54+
```robot
55+
*** Variables ***
56+
${SIGNATURE IMAGE} ..${/}Images${/}Signature.jpg
57+
${BANK WSDL} ..${/}WSDLs${/}Bank.wsdl
58+
${SSL CERT FILE} ..${/}SSL Certs${/}Some certificate.cert
59+
&{PROXIES}
60+
... http=http://someproxy.local:8080
61+
... https=https://someproxy.local:8080
62+
63+
*** Test Cases ***
64+
Example SOAP call
65+
Create client ${BANK WSDL} verify=${SSL CERT FILE} proxies=${PROXIES}
66+
67+
${today}= Get current date result_format=datetime
68+
69+
Add attachment ${SIGNATURE IMAGE}
70+
71+
${attachment}= Create object ns1:AttachmentType
72+
... Nr=1
73+
... Filename=Signature.jpg
74+
... Type=Signature
75+
@{attachments}= Create list ${attachment} # In this example, the attachments don't have some grouping `Attachments' parent, but the `AttachmentType' is a list.
76+
77+
${response}= Call operation GetAccountDetails xop=${TRUE}
78+
... BankNr=1234
79+
... Attachments=${attachments}
80+
```

0 commit comments

Comments
 (0)