Skip to content

Commit 144f0ed

Browse files
authored
Statistics: Allow to override receiver ID (#14)
1 parent a4d0d88 commit 144f0ed

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/peppol_py/statistics.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,8 @@ def send_peppol_statistics(
221221
keyfile: str,
222222
password: str,
223223
certfile: str,
224-
test_environment: bool
224+
test_environment: bool,
225+
receiver_id: str='9925:BE0848934496'
225226
) -> List[dict]:
226227
"""
227228
Send peppol statistics to the required reporting endpoint.
@@ -258,13 +259,14 @@ def send_peppol_statistics(
258259
``certfile`` (str): the path to the public key of the sender.
259260
260261
``test_environment`` (bool): use test SML servers?
262+
263+
``receiver_id`` (str): Receiver participant, defaults to the OpenPeppol organization
261264
"""
262265
end_user_xml = render_peppol_end_user_statistics_xml(aggr_stats, certfile)
263266
transaction_xml = render_peppol_transaction_statistics_xml(aggr_stats, certfile)
264267

265268
sender_id_element = generate_organization_id(ElementMaker(), lambda shorthand, tag: tag, "EndpointID", our_endpoint['id'], our_endpoint['type'])
266269
sender_id = sender_id_element.get('schemeID') + ':' + sender_id_element.text
267-
receiver_id = '9925:BE0848934496'
268270

269271
results = []
270272
failure = None

0 commit comments

Comments
 (0)