Open jerome-laforge opened 7 months ago
Your XML specs require RFC3339? We found with TCH that they don't support RFC3339.
Yes, all dates in the provided examples are in RFC3339Milli layout : 2006-01-02T15:04:05.000Z07:00
When we've gone through testing for RTP with TCH we found the sub-second precision and timezone format was not accepted. We had to format timestamps as ISO 8601 in order to be accepted.
Ok, that makes sens, but I don't want to change the default timestamp format. Is it possible for you that define a global public variable with default format as ISO8601? With this variable, I will be able to define the format (RFC3339 or something else) in order to marshall/unmarshall the ISODateTime.
For now, I just fork and add the global variable (https://github.com/jerome-laforge/rtp20022/commit/ac6fa8700c64570bc8c2e0866f2fc66affd78e50).
It is enough for me for now at this stage. I will be back later in order to known if he format in example are OK or not (need to manage it more properly with the upstream driver).
Is it suitable for you?
Sounds good. Are you using this for RTP or FedNow? We're planning a separate fednow20022 repo with generated code since the two protocols use different ISO 20022 messages.
I'm fine adding that variable if it's needed.
I use it for BCEAO zone (https://en.wikipedia.org/wiki/Central_Bank_of_West_African_States)
FYI, I regenerate the model/validate with specific xsd and modified template.
I'm fine adding that variable if it's needed.
Thx a lot :pray:
Okay, I understand better now. I found some information to help understand how ISO 20022 is being used for BCEAO.
https://gfrid.org/wp-content/uploads/2023/08/Senegal-CoP-September-2023_ISO-20022_EN__final.pdf https://www.bceao.int/sites/default/files/2023-07/BCEAO%20-%20Rapport%20sur%20les%20IMF%2C%20Moyens%20et%20Services%20de%20Paiement_2020-2021.pdf
ISO 20022 is a very large set of XML specifications and different usages (countries, businesses, etc) adopt different parts of it. I would recommend you fork rtp20022 and adapt the templates/generators to your needs for BCEAO. I'm not sure how far we can stretch this repository to support both RTP and BCEAO. I will help you fork and setup the repo for your needs.
Do you have more details on the exact ISO 20022 messages used and how they're to be formatted?
Currently, I have just some example & xsd. Nothing official yet. When, I have the official data, forward you all xsd.
For now, I 've just :
Did you figure out if you needed more changes? Or if a fork of rtp20022 would be your solution?
Thank again for your support :pray: For now based on the provided examples, the fork works fine with the modifications on:
I would have preferred that those 2 modifications were merged in the upstream (with the default values that allow keep current behavior for TCH). If those 2 modifications have been merged then I will be able to remove replace github.com/moov-io/rtp20022 v0.9.4 => github.com/jerome-laforge/rtp20022 v0.0.0-20231208075226-8e7a6baf36f9
directive from our go.mod.
I'm not sure we want to maintain extensible support for ISO 20022 and all of its various implementations. TCH makes a lot of changes to the ISO 20022 spec which are not compatible with BCEAO. We will help you stay updated with the generated code.
Hello, When I marshal rtp.ISODateTime type, I have something like
2006-01-02T15:04:05
. But it seems that we need to export with RFC3339 layout.Do you think that it is possible do to define somewhere the time format that we want to use for marshaling?
Thx in adv for you support.