mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-03-22 05:18:51 +00:00
The Spree::Variant in OFN corresponds to a DFC SuppliedProduct. But several Spree::Variant can be grouped under one Spree::Product which wasn't exposed on the DFC API. I'm adding a custom property here which can be used internally and shouldn't break any other DFC tools. A gotcha of this first test implementation: The `ofn:` prefix has not been defined in the context. Software needs to know that this is an Open Food Network attribute or ignore it. We could define our own context and ontology and publish it on our website but I don't see any benefit of that at this point.
Data Food Consortium API for the Open Food Network app (OFN DFC API)
This engine implements the Data Food Consortium specifications. It serves and reads semantic data encoded in JSON-LD.
The API is documented with Swagger at /api-docs. You can update these docs
with:
./script/rswag engines/dfc_provider
More documentation by the Data Food Consortium: