The sipmessage project provides a set of Python helpers and structures for parsing and serialising SIP messages. It can be used to manipulate either entire requests and responses or individual header values.
To learn more about sipmessage please read the documentation.
Example
from sipmessage import Message, Parameters, Request, Via
request = Message.parse(
b"REGISTER sip:atlanta.com SIP/2.0\r\n"
b"Via: SIP/2.0/WSS mYn6S3lQaKjo.invalid;branch=z9hG4bKgD24yaj\r\n"
b"Max-Forwards: 70\r\n"
b"To: <sip:alice@atlanta.com>\r\n"
b"From: <sip:alice@atlanta.com>;tag=69piINLbAb\r\n"
b"Call-ID: t87Br1RHAoBz2FsrKKk6hV\r\n"
b"CSeq: 1 REGISTER\r\n"
b"Contact: <sip:Mk9sZp5Z@mYn6S3lQaKjo.invalid;transport=ws>;expires=300\r\n"
b"User-Agent: Tester/0.1.0\r\n"
b"Content-Length: 0\r\n\r\n"
)
assert isinstance(request, Request)
assert request.via == [
Via(
transport="WSS",
host="mYn6S3lQaKjo.invalid",
port=None,
parameters=Parameters(branch="z9hG4bKgD24yaj"),
)
]
License
sipmessage is released under the BSD license.
Metadata
Release files for sipmessage 0.7.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| sipmessage-0.7.1.tar.gz | 26.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| sipmessage-0.7.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 44.0 kB
Release files / sipmessage-0.7.1.tar.gz
| Download URL | sipmessage-0.7.1.tar.gz |
|---|---|
| Size | 26.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9d2584f15a6d3ad0c1a3025d8ada0258a1cb2fc122ff5f47457ef6bf7636e985
|
|
BLAKE2b-256 checksum How to use checksums |
b0220a5f2b1acd59bc8291237aa04471ce7c7e078bf8c65f4c0042b3348e63b9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / sipmessage-0.7.1-py3-none-any.whl
| Download URL | sipmessage-0.7.1-py3-none-any.whl |
|---|---|
| Size | 17.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
39e8d6f9fc114141e7ce371cd53e9172de264ecb331d38ed8a14cdbb939b4fa8
|
|
BLAKE2b-256 checksum How to use checksums |
3ec0fe7c3ade59bf813e3b93945e0a719660c5fdaac2a0bca5d71895fd02e84e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|