Public Interfaces¶
These are the interfaces (REST APIs) that are used for B2G interactions.
They map to the description on https://edi3.org/specs/edi3-icl/master/#architecture-overview
Note there is also a generic (general purpose) events subscription API that is also public. It is documented in the chapter following this one, as part of the event subsystem.
General Message API¶
This component provides the main API used by members of the regulated community to send messages to the Government, which may or may not be forwarded to other Governments (depending on intergovernment channels, and the policy of the regulator, etc).
It is also used to check the status of messages (e.g. have they been delivered to foreign governments yet?), and to update the status of messages.
The implementation is /intergov/apis/message_api/
The specific business logic is in these classes:
GetMessageBySenderRefUseCase (in /intergov/use_cases/get_message_by_sender_ref.py)
PatchMessageMettadataUseCase (in /intergov/use_cases/patch_message_metadata.py)
EnqueueMessageUseCase (in /intergov/use_cases/enqueue_message.py), which is the same business logic as in the Message Receiving API.
Document API¶
This is how people save and access documents, which are the subject of G2G messages.
The implementation is /intergov/apis/document_api.py and the logic is in the AuthenticatedObjectAccessUseCase (in /intergov/use_cases/authenticated_object_access.py) and StoreObjectUseCase (in /intergov/use_cases/store_object.py)