checkProductConfigrationItem.ProductConfiguration is mandatory in the conformance profile although in the OAS it has 0..* cardinality. CTK aims to test if the API response is somehow meaningful and a result of some configurator computation.
Both bundledGroupProductOffering and bundledGroupProductOfferingOption are optional (indicated by "if present"). These objects are used to model use cases where you can choose among several (bundled) offerings in a group (e.g. select a set-top box from an STB group) and perhaps you wish to enforce a cardinality on the group (e.g. select exactly one set-top box from the STB group). In case budnledGroupProductOffering and bundledGroupproductOfferingOption are present, they have certain mandatory attributes as described in the conformance profile on page 3.
Original Message:
Sent: Jun 11, 2024 09:27
From: Chetan Hirpara
Subject: TMF760 - Object field Information
@Bostjan Keber
Can you please guide us about "CheckProductConfiguration" resource mandatory response information?
"TMF760_Product_Configuration_conformance.pdf" is not giving clear information.
Conformance is holding below response fields as mandatory but when you reach to individual mandatory object then not getting clear information.<Refer second screen shot>
Each fields description is not giving mandatory or optional clarity. It suggesting to check other object condition while referred object<alternateProductConfigurationProposal> is already optional.
Do we have any other document or place where we can get clear information about mandatory response field informaiton?
------------------------------
Chetan Hirpara
Tech Mahindra Limited
Original Message:
Sent: Apr 24, 2024 02:32
From: Bostjan Keber
Subject: TMF760 - Object field Information
Hi Chetan,
TMF760 is a version 5 Open API and uses Swagger / Open API 3.0 meaning the schemas may use inheritance (allof keyword).
Characteristic class is abstract and extended with subclasses of a specific type, e.g. string characteristic, number characteristic, etc. See diagram below:
Also, have a look at the Swagger definition:
Characteristic:
allOf:
- $ref: '#/components/schemas/Extensible'
- type: object
description: Describes a given characteristic of an object or entity through a name/value pair.
properties:
id:
type: string
description: Unique identifier of the characteristic
name:
type: string
description: Name of the characteristic
valueType:
type: string
description: Data type of the value of the characteristic
characteristicRelationship:
type: array
items:
$ref: '#/components/schemas/CharacteristicRelationship'
discriminator:
propertyName: '@type'
mapping:
Characteristic: '#/components/schemas/Characteristic'
StringCharacteristic: '#/components/schemas/StringCharacteristic'
StringArrayCharacteristic: '#/components/schemas/StringArrayCharacteristic'
ObjectCharacteristic: '#/components/schemas/ObjectCharacteristic'
ObjectArrayCharacteristic: '#/components/schemas/ObjectArrayCharacteristic'
NumberCharacteristic: '#/components/schemas/NumberCharacteristic'
NumberArrayCharacteristic: '#/components/schemas/NumberArrayCharacteristic'
IntegerCharacteristic: '#/components/schemas/IntegerCharacteristic'
IntegerArrayCharacteristic: '#/components/schemas/IntegerArrayCharacteristic'
FloatCharacteristic: '#/components/schemas/FloatCharacteristic'
FloatArrayCharacteristic: '#/components/schemas/FloatArrayCharacteristic'
@type attribute is used as a discriminator to determine the characteristic type.
The actual value is stored in the value attribute of each subclass, e.g. StringCharacteristic.value.
StringCharacteristic:
allOf:
- $ref: '#/components/schemas/Characteristic'
- type: object
description: A characteristic which value is a String.
properties:
value:
type: string
description: Value of the characteristic
Hope it helps.
Bostjan
------------------------------
Bostjan Keber
Marand, software ltd
Original Message:
Sent: Apr 23, 2024 11:19
From: Chetan Patel
Subject: TMF760 - Object field Information
Hi Team,
@Bostjan Keber @Jonathan Goldberg
We are getting characteristic object without "value" field so does it correct or mistake in swagger? Why each object have @type is mandatory?
Regards
Chetan Hirpara
#General
------------------------------
Chetan Patel
Tech Mahindra Limited
------------------------------