2

Is there a standardized or recommended way of translating the relations between loopback models to the definitions part of the swagger yaml?

Things I'm unsure about:

  • When giving a relation by referencing the other model definition, do circular references (eg. A hasOne B, B belongsTo A) become a problem?
  • Could one instead pass a reference to the id of the related model instance? This could simplify POST requests a lot.
  • How to precisely translate the meaning of the relation
akadirdev
  • 70
  • 7
Aljoscha Meyer
  • 527
  • 2
  • 9
  • 19

0 Answers0