Hi Adity
Please refer to the design guidelines TMF630 (
here) for a full explanation of the @ fields.
The idea of the @type field is to indicate the data/entity type of the entity, it is
not intended to convey an applicative type (e.g. for customer, an applicative type might be residential, business, government, etc.). Thus if you had (for instance) extended Customer to add a value attribute, thus creating (say) CSGCustomer, you would populate @type with "CSGCustomer" and @baseType with "Customer".
Hope it helps
------------------------------
Jonathan Goldberg
Amdocs Management Limited
Any opinions and statements made by me on this forum are purely personal, and do not necessarily reflect the position of the TM Forum or my employer.
------------------------------
Original Message:
Sent: Aug 31, 2020 14:25
From: Adity Mukherjee
Subject: Using @type in json response
Hi
@ type is used in the Specs, and also in the json examples given in TMF Specs.
But is it supposed to be used in actual Server side API implementations? or we should interpret it as type and accordingly populate the response?
{ "@type": "Customer", "href": "https://host:port/tmf-api/customerManagement/v4/customer/1140", "id": "1140", "name": "Moon Football Club", "status": "Approved"}
Thanks
------------------------------
Adity Mukherjee
CSG International
------------------------------