From ad58b5344054e17b3479df2d9b326af92bcac09f Mon Sep 17 00:00:00 2001 From: Max Martens Date: Thu, 14 Aug 2025 14:27:46 +0200 Subject: [PATCH 1/7] Ultra major refactor of ABTProductReference Swagger; added new LayerInfo entity --- .../products/productreference-crud.yaml | 1992 ++++++----------- 1 file changed, 697 insertions(+), 1295 deletions(-) diff --git a/src/openapi/products/productreference-crud.yaml b/src/openapi/products/productreference-crud.yaml index 61b5e2b..7428502 100644 --- a/src/openapi/products/productreference-crud.yaml +++ b/src/openapi/products/productreference-crud.yaml @@ -23,7 +23,10 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/clientAttributesGetEntity' + type: object + properties: + Entries: + $ref: '#/components/schemas/clientAttributesGetList' description: A list of client attributes "400": content: @@ -58,14 +61,14 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/clientAttributesPostEntity' + $ref: '#/components/schemas/clientAttributesPostPutEntity' required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' + $ref: '#/components/schemas/postPutSuccessResponse' description: ok "400": content: @@ -126,7 +129,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' + $ref: '#/components/schemas/postPut404Response' description: Not Found "500": content: @@ -153,14 +156,14 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/clientAttributesPutEntity' + $ref: '#/components/schemas/clientAttributesPostPutEntity' required: true responses: "202": content: application/json: schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' + $ref: '#/components/schemas/postPutSuccessResponse' description: ok "400": content: @@ -178,7 +181,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' + $ref: '#/components/schemas/postPut404Response' description: Not Found "409": content: @@ -195,6 +198,188 @@ paths: summary: Modify a client attribute. tags: - ABTProductReference CRUD + /layerInfo: + get: + description: | + This method will get the list of all LayerInfo entries. + responses: + "200": + content: + application/json: + schema: + type: object + properties: + Entries: + $ref: '#/components/schemas/layerInfoGetList' + description: A list of LayerInfo entries + "400": + content: + application/json: + schema: + $ref: '#/components/schemas/400Response' + description: Bad Request + "401": + content: + application/json: + schema: + $ref: '#/components/schemas/401Response' + description: Unauthorized + "404": + content: + application/json: + schema: + $ref: '#/components/schemas/404Response' + description: Not Found + "500": + content: + application/json: + schema: + $ref: '#/components/schemas/500Response' + description: Internal Server Error + summary: Get all LayerInfo entries. + tags: + - ABTProductReference CRUD + post: + description: "This method will create new LayerInfo entry. \n" + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/layerInfoPostPutEntity' + required: true + responses: + "201": + content: + application/json: + schema: + $ref: '#/components/schemas/postPutSuccessResponse' + description: ok + "400": + content: + application/json: + schema: + $ref: '#/components/schemas/400Response' + description: Bad Request + "401": + content: + application/json: + schema: + $ref: '#/components/schemas/401Response' + description: Unauthorized + "404": + content: + application/json: + schema: + $ref: '#/components/schemas/404Response' + description: Not Found + "500": + content: + application/json: + schema: + $ref: '#/components/schemas/500Response' + description: Internal Server Error + summary: Create a client attribute. + tags: + - ABTProductReference CRUD + /layerInfo/{layerInfoId}: + delete: + description: "This method will delete the LayerInfo entry for the given layerInfoId. \n" + parameters: + - explode: false + in: path + name: layerInfoId + required: true + schema: + format: integer + type: integer + style: simple + responses: + "202": + description: Deleted record successfully + "400": + content: + application/json: + schema: + $ref: '#/components/schemas/400Response' + description: Bad Request + "401": + content: + application/json: + schema: + $ref: '#/components/schemas/401Response' + description: Unauthorized + "404": + content: + application/json: + schema: + $ref: '#/components/schemas/postPut404Response' + description: Not Found + "500": + content: + application/json: + schema: + $ref: '#/components/schemas/500Response' + description: Internal Server Error + summary: Delete a LayerInfo entry. + tags: + - ABTProductReference CRUD + put: + description: "This method will update the LayerInfo entry for the given layerInfoId. \n" + parameters: + - explode: false + in: path + name: layerInfoId + required: true + schema: + format: integer + type: integer + style: simple + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/layerInfoPostPutEntity' + required: true + responses: + "202": + content: + application/json: + schema: + $ref: '#/components/schemas/postPutSuccessResponse' + description: ok + "400": + content: + application/json: + schema: + $ref: '#/components/schemas/400Response' + description: Bad Request + "401": + content: + application/json: + schema: + $ref: '#/components/schemas/401Response' + description: Unauthorized + "404": + content: + application/json: + schema: + $ref: '#/components/schemas/postPut404Response' + description: Not Found + "409": + content: + application/json: + schema: + $ref: '#/components/schemas/409Response' + description: Conflict + "500": + content: + application/json: + schema: + $ref: '#/components/schemas/500Response' + description: Internal Server Error + summary: Modify a LayerInfo entry. + tags: + - ABTProductReference CRUD /productowners: get: description: | @@ -204,7 +389,10 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/productOwners' + type: object + properties: + Entries: + $ref: '#/components/schemas/productOwnerGetList' description: A list of users "400": content: @@ -239,14 +427,14 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/productOwner' + $ref: '#/components/schemas/productOwnerPostPutEntity' required: true responses: "201": content: application/json: schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' + $ref: '#/components/schemas/postPutSuccessResponse' description: ok "400": content: @@ -307,7 +495,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' + $ref: '#/components/schemas/postPut404Response' description: Not Found "500": content: @@ -334,14 +522,14 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/productOwner' + $ref: '#/components/schemas/productOwnerPostPutEntity' required: true responses: "202": content: application/json: schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' + $ref: '#/components/schemas/postPutSuccessResponse' description: ok "400": content: @@ -359,7 +547,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' + $ref: '#/components/schemas/postPut404Response' description: Not Found "409": content: @@ -385,7 +573,10 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/productCategories' + type: object + properties: + Entries: + $ref: '#/components/schemas/productCategoryGetList' description: A list of users "400": content: @@ -414,157 +605,6 @@ paths: summary: Get all productcategories. tags: - ABTProductReference CRUD - post: - description: | - This method will create a single product category. - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/productCategory' - responses: - "201": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' - description: ok - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/400Response' - description: Bad Request - "401": - content: - application/json: - schema: - $ref: '#/components/schemas/401Response' - description: Unauthorized - "404": - content: - application/json: - schema: - $ref: '#/components/schemas/404Response' - description: Not Found - "409": - content: - application/json: - schema: - $ref: '#/components/schemas/409Response' - description: Conflict - "500": - content: - application/json: - schema: - $ref: '#/components/schemas/500Response' - description: Internal Server Error - summary: Create a product category. - tags: - - ABTProductReference CRUD - /productcategories/{productCategoryId}: - delete: - description: | - This method will delete the productCategory when provided the - productCategoryId. - parameters: - - explode: false - in: path - name: productCategoryId - required: true - schema: - format: integer - type: integer - style: simple - responses: - "202": - description: Deleted record successfully - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/400Response' - description: Bad Request - "401": - content: - application/json: - schema: - $ref: '#/components/schemas/401Response' - description: Unauthorized - "404": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' - description: Not Found - "500": - content: - application/json: - schema: - $ref: '#/components/schemas/500Response' - description: Internal Server Error - summary: Delete a product category. - tags: - - ABTProductReference CRUD - put: - description: | - This method will update productCategory when provided the - productCategoryId. - parameters: - - explode: false - in: path - name: productCategoryId - required: true - schema: - format: integer - type: integer - style: simple - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/productCategory' - required: true - responses: - "202": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' - description: ok - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/400Response' - description: Bad Request - "401": - content: - application/json: - schema: - $ref: '#/components/schemas/401Response' - description: Unauthorized - "404": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' - description: Not Found - "409": - content: - application/json: - schema: - $ref: '#/components/schemas/409Response' - description: Conflict - "500": - content: - application/json: - schema: - $ref: '#/components/schemas/500Response' - description: Internal Server Error - summary: Modify a product category. - tags: - - ABTProductReference CRUD /customersegments: get: description: This method will get the list of customer segments. @@ -573,7 +613,10 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/customerSegments' + type: object + properties: + Entries: + $ref: '#/components/schemas/customerSegmentGetList' description: A list of users "400": content: @@ -602,154 +645,6 @@ paths: summary: Get all customer segments. tags: - ABTProductReference CRUD - post: - description: This method will create a single customer segment. - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/customerSegment' - responses: - "201": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' - description: ok - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/400Response' - description: Bad Request - "401": - content: - application/json: - schema: - $ref: '#/components/schemas/401Response' - description: Unauthorized - "404": - content: - application/json: - schema: - $ref: '#/components/schemas/404Response' - description: Not Found - "409": - content: - application/json: - schema: - $ref: '#/components/schemas/409Response' - description: Conflict - "500": - content: - application/json: - schema: - $ref: '#/components/schemas/500Response' - description: Internal Server Error - summary: Create a customer segment. - tags: - - ABTProductReference CRUD - /customersegments/{customerSegmentId}: - delete: - description: | - This method will delete a customer segment when provided the customerSegmentId. - parameters: - - explode: false - in: path - name: customerSegmentId - required: true - schema: - format: integer - type: integer - style: simple - responses: - "202": - description: Deleted record successfully - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/400Response' - description: Bad Request - "401": - content: - application/json: - schema: - $ref: '#/components/schemas/401Response' - description: Unauthorized - "404": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' - description: Not Found - "500": - content: - application/json: - schema: - $ref: '#/components/schemas/500Response' - description: Internal Server Error - summary: Delete a customer segment. - tags: - - ABTProductReference CRUD - put: - description: | - This method will update a customer segment when provided the customerSegmentId. - parameters: - - explode: false - in: path - name: customerSegmentId - required: true - schema: - format: integer - type: integer - style: simple - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/customerSegment' - required: true - responses: - "202": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' - description: ok - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/400Response' - description: Bad Request - "401": - content: - application/json: - schema: - $ref: '#/components/schemas/401Response' - description: Unauthorized - "404": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' - description: Not Found - "409": - content: - application/json: - schema: - $ref: '#/components/schemas/409Response' - description: Conflict - "500": - content: - application/json: - schema: - $ref: '#/components/schemas/500Response' - description: Internal Server Error - summary: Modify a customer segment. - tags: - - ABTProductReference CRUD /marketsegments: get: description: This method will get the list of market segments. @@ -758,7 +653,10 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/marketSegments' + type: object + properties: + Entries: + $ref: '#/components/schemas/marketSegmentGetList' description: A list of users "400": content: @@ -787,154 +685,6 @@ paths: summary: Get all market segments. tags: - ABTProductReference CRUD - post: - description: This method will create a single market segment. - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/marketSegment' - responses: - "201": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' - description: ok - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/400Response' - description: Bad Request - "401": - content: - application/json: - schema: - $ref: '#/components/schemas/401Response' - description: Unauthorized - "404": - content: - application/json: - schema: - $ref: '#/components/schemas/404Response' - description: Not Found - "409": - content: - application/json: - schema: - $ref: '#/components/schemas/409Response' - description: Conflict - "500": - content: - application/json: - schema: - $ref: '#/components/schemas/500Response' - description: Internal Server Error - summary: Create a market segment. - tags: - - ABTProductReference CRUD - /marketsegments/{marketSegmentId}: - delete: - description: | - This method will delete a market segment when provided the marketSegmentId. - parameters: - - explode: false - in: path - name: marketSegmentId - required: true - schema: - format: integer - type: integer - style: simple - responses: - "202": - description: Deleted record successfully - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/400Response' - description: Bad Request - "401": - content: - application/json: - schema: - $ref: '#/components/schemas/401Response' - description: Unauthorized - "404": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' - description: Not Found - "500": - content: - application/json: - schema: - $ref: '#/components/schemas/500Response' - description: Internal Server Error - summary: Delete a market segment. - tags: - - ABTProductReference CRUD - put: - description: | - This method will update a market segment when provided the marketSegmentId. - parameters: - - explode: false - in: path - name: marketSegmentId - required: true - schema: - format: integer - type: integer - style: simple - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/marketSegment' - required: true - responses: - "202": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' - description: ok - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/400Response' - description: Bad Request - "401": - content: - application/json: - schema: - $ref: '#/components/schemas/401Response' - description: Unauthorized - "404": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' - description: Not Found - "409": - content: - application/json: - schema: - $ref: '#/components/schemas/409Response' - description: Conflict - "500": - content: - application/json: - schema: - $ref: '#/components/schemas/500Response' - description: Internal Server Error - summary: Modify a market segment. - tags: - - ABTProductReference CRUD /paymentmoments: get: description: | @@ -944,7 +694,10 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/paymentMoments' + type: object + properties: + Entries: + $ref: '#/components/schemas/paymentMomentGetList' description: A list of payment moments "400": content: @@ -982,7 +735,10 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/retailers' + type: object + properties: + Entries: + $ref: '#/components/schemas/retailerGetList' description: A list of retailers "400": content: @@ -1018,13 +774,13 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/retailer' + $ref: '#/components/schemas/retailerPostPutEntity' responses: "201": content: application/json: schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' + $ref: '#/components/schemas/postPutSuccessResponse' description: ok "400": content: @@ -1091,7 +847,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' + $ref: '#/components/schemas/postPut404Response' description: Not Found "500": content: @@ -1118,14 +874,14 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/retailer' + $ref: '#/components/schemas/retailerPostPutEntity' required: true responses: "202": content: application/json: schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' + $ref: '#/components/schemas/postPutSuccessResponse' description: ok "400": content: @@ -1143,7 +899,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' + $ref: '#/components/schemas/postPut404Response' description: Not Found "409": content: @@ -1180,7 +936,10 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/salesTouchpoints' + type: object + properties: + Entries: + $ref: '#/components/schemas/salesTouchpointGetList' description: A list of users "400": content: @@ -1217,13 +976,13 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/salesTouchpoint' + $ref: '#/components/schemas/salesTouchpointPostPutEntity' responses: "201": content: application/json: schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' + $ref: '#/components/schemas/postPutSuccessResponse' description: ok "400": content: @@ -1285,7 +1044,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' + $ref: '#/components/schemas/postPut404Response' description: Not Found "500": content: @@ -1313,14 +1072,14 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/salesTouchpoint' + $ref: '#/components/schemas/salesTouchpointPostPutEntity' required: true responses: "202": content: application/json: schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' + $ref: '#/components/schemas/postPutSuccessResponse' description: ok "400": content: @@ -1338,7 +1097,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' + $ref: '#/components/schemas/postPut404Response' description: Not Found "409": content: @@ -1364,7 +1123,10 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/serviceOptions' + type: object + properties: + Entries: + $ref: '#/components/schemas/serviceOptionGetList' description: A list of users "400": content: @@ -1393,156 +1155,6 @@ paths: summary: Get the list of serviceoptions. tags: - ABTProductReference CRUD - post: - description: | - This method will create a new serviceoptions. - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/serviceOption' - responses: - "201": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' - description: ok - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/400Response' - description: Bad Request - "401": - content: - application/json: - schema: - $ref: '#/components/schemas/401Response' - description: Unauthorized - "404": - content: - application/json: - schema: - $ref: '#/components/schemas/404Response' - description: Not Found - "409": - content: - application/json: - schema: - $ref: '#/components/schemas/409Response' - description: Conflict - "500": - content: - application/json: - schema: - $ref: '#/components/schemas/500Response' - description: Internal Server Error - summary: Create a serviceoptions. - tags: - - ABTProductReference CRUD - /serviceoptions/{serviceOptionId}: - delete: - description: | - This method will delete serviceoptions when provided the - serviceoptionsId. - parameters: - - explode: false - in: path - name: serviceOptionId - required: true - schema: - format: integer - type: integer - style: simple - responses: - "202": - description: Deleted record successfully - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/400Response' - description: Bad Request - "401": - content: - application/json: - schema: - $ref: '#/components/schemas/401Response' - description: Unauthorized - "404": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' - description: Not Found - "500": - content: - application/json: - schema: - $ref: '#/components/schemas/500Response' - description: Internal Server Error - summary: Delete a serviceoptions. - tags: - - ABTProductReference CRUD - put: - description: | - This method will create a new serviceoption. - parameters: - - explode: false - in: path - name: serviceOptionId - required: true - schema: - format: integer - type: integer - style: simple - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/serviceOption' - required: true - responses: - "202": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes_post_201_response' - description: ok - "400": - content: - application/json: - schema: - $ref: '#/components/schemas/400Response' - description: Bad Request - "401": - content: - application/json: - schema: - $ref: '#/components/schemas/401Response' - description: Unauthorized - "404": - content: - application/json: - schema: - $ref: '#/components/schemas/_clientattributes__clientAttributeId__put_404_response' - description: Not Found - "409": - content: - application/json: - schema: - $ref: '#/components/schemas/409Response' - description: Conflict - "500": - content: - application/json: - schema: - $ref: '#/components/schemas/500Response' - description: Internal Server Error - summary: Create a serviceoption. - tags: - - ABTProductReference CRUD /mandatorycustomerdataitems: get: description: | @@ -1551,30 +1163,11 @@ paths: "200": content: application/json: - example: - Entries: - - mandatoryCustomerDataItemId: 1 - customerDataItem: birthname - - mandatoryCustomerDataItemId: 2 - customerDataItem: surname - - mandatoryCustomerDataItemId: 3 - customerDataItem: dateOfBirth - - mandatoryCustomerDataItemId: 4 - customerDataItem: emailAddress - - mandatoryCustomerDataItemId: 5 - customerDataItem: address - - mandatoryCustomerDataItemId: 6 - customerDataItem: phone - - mandatoryCustomerDataItemId: 7 - customerDataItem: ovPayToken - - mandatoryCustomerDataItemId: 8 - customerDataItem: padBirthDate - - mandatoryCustomerDataItemId: 9 - customerDataItem: shippingAddress - - mandatoryCustomerDataItemId: 10 - customerDataItem: billingAddress schema: - $ref: '#/components/schemas/mandatoryCustomerDataItems' + type: object + properties: + Entries: + $ref: '#/components/schemas/mandatoryCustomerDataItemGetList' description: A list of users "400": content: @@ -1611,17 +1204,12 @@ paths: "200": content: application/json: - example: - Entries: - - requiredCustomerLevelId: 1 - name: guest - - requiredCustomerLevelId: 2 - name: contact - - requiredCustomerLevelId: 3 - name: profile schema: - $ref: '#/components/schemas/requiredCustomerLevels' - description: A list of users + type: object + properties: + Entries: + $ref: '#/components/schemas/requiredCustomerLevelGetList' + description: The list possible requiredcustomerlevels "400": content: application/json: @@ -1657,7 +1245,10 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/getforbiddenPaymentMethodList' + type: object + properties: + Entries: + $ref: '#/components/schemas/forbiddenPaymentMethodGetList' description: A list of forbidden payment methods "400": content: @@ -1696,7 +1287,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/requiredGboPersonalAttributes' + $ref: '#/components/schemas/requiredGboPersonalAttributeGetList' description: A list of Required GBO personal attributes "400": content: @@ -1735,7 +1326,10 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/GboAgeProfileList' + type: object + properties: + Entries: + $ref: '#/components/schemas/gboAgeProfileGetList' description: A list of GBO age profiles "400": content: @@ -1772,73 +1366,8 @@ paths: "200": content: application/json: - example: - Entries: - clientAttributes: - type: array - items: - type: object - properties: - - clientAttributeId: 1 - clientId: htm - description: description - isActive: "true" - retailerId: 1 - salesTouchpointId: 2 - productOwners: - - productOwnerId: 123 - name: name - organization: org - productCategories: - - isTravelProduct: true - name: name - productCategoryId: 21 - customerSegments: - - name: name - customerSegmentId: 123 - marketSegments: - - name: name - marketSegmentId: 123 - paymentMoments: - - paymentMomentId: 123 - name: name - retailers: - - name: name - street: StreetName - number: "12" - numberAddition: E - postalCode: 2222 BV - city: Amsterdam - country: NL - emailAddress: sample@email.com - phoneNumber: "6123456789" - taxId: taxId - imageReference: imageReference - retailerId: 123 - salesTouchpoints: - - isActive: true - name: name - retailerId: 21 - salesTouchPointId: 123 - serviceOptions: - - action: action - description: description - serviceOptionId: 123 - mandatoryCustomerDataItems: - - mandatoryCustomerDataItemId: 123 - customerDataItem: customerDataItem - requiredCustomerLevels: - - requiredCustomerLevelId: 123 - name: requiredCustomerLevel - forbiddenPaymentMethods: - - forbiddenPaymentMethodId: 123 - name: requiredCustomerLevel - issuer: Kane - requiredGboPersonalAttributes: - - requiredGboPersonalAttributeId: 123 - name: requiredCustomerLevel schema: - $ref: '#/components/schemas/_productreferences_get_200_response' + $ref: '#/components/schemas/productReferencesGetList' description: Successful retrieved list of all possible product reference values "400": @@ -1870,8 +1399,28 @@ paths: - ABTProductReference CRUD components: schemas: - clientAttribute: + clientAttributesGetList: + example: + - clientAttributesId: 1 + clientId: 34r0QSQfr46rKmNezXpAteSymkLe + description: description1 + isActive: "true" + retailerId: 1001 + salesTouchpointId: 3 + - clientAttributesId: 2 + clientId: 65TkBRk5DyQkKmNezXpAteKlRzE6 + description: description2 + isActive: "false" + retailerId: 1000 + salesTouchpointId: 2 + type: array + items: + $ref: '#/components/schemas/clientAttributesGetEntity' + clientAttributesGetEntity: properties: + clientAttributesId: + example: 1 + type: integer clientId: example: htm type: string @@ -1888,190 +1437,267 @@ components: example: 2 type: integer type: object - clientAttributesGetList: - items: - $ref: '#/components/schemas/clientAttributesGetList_inner' - type: array - clientAttributesGetEntity: + clientAttributesPostPutEntity: + properties: + clientId: + example: 34r0QSQfr46rKmNezXpAteSymkLe + type: string + description: + example: description + type: string + isActive: + example: true + type: boolean + retailerId: + example: 1001 + type: integer + salesTouchpointId: + example: 3 + type: integer + type: object + layerInfoGetList: + example: + - layerInfoId: 1 + choiceKey: isRenewable + choiceLabel: Kies voor een doorlopend abonnement of een enkele termijn + isCustomChoice: false + - layerInfoId: 2 + choiceKey: regio + choiceLabel: Kies een regio + isCustomChoice: true + type: array + items: + $ref: '#/components/schemas/layerInfoGetEntity' + layerInfoGetEntity: + properties: + layerInfoId: + example: 1 + type: integer + choiceKey: + example: isRenewable + type: string + choiceLabel: + example: Kies voor een doorlopend abonnement of een enkele termijn + type: string + isCustomChoice: + example: false + type: boolean + type: object + layerInfoPostPutEntity: + properties: + choiceKey: + example: isRenewable + type: string + choiceLabel: + example: Kies voor een doorlopend abonnement of een enkele termijn + type: string + isCustomChoice: + example: false + type: boolean + type: object + productOwnerGetList: example: - Entries: - - clientId: htm - description: description - clientAttributeId: 1 - isActive: "true" - retailerId: 1 - salesTouchpointId: 2 - - clientId: htm - description: description - clientAttributeId: 1 - isActive: "true" - retailerId: 1 - salesTouchpointId: 2 + - productOwnerId: 1 + organization: HTM + name: Corneel Verstoep + - productOwnerId: 2 + organization: ABC + name: Pietje Puk + items: + $ref: '#/components/schemas/productOwnerGetEntity' + type: array + productOwnerGetEntity: properties: - Entries: - items: - $ref: '#/components/schemas/clientAttributesGetList_inner' - type: array - type: object - clientAttributesPostEntity: - properties: - clientId: - example: htm - type: string - description: - example: description - type: string - isActive: - example: true - type: boolean - retailerId: + productOwnerId: example: 1 type: integer - salesTouchpointId: - example: 2 - type: integer - type: object - clientAttributesPutEntity: - properties: - description: - example: description - type: string - isActive: - example: true - type: boolean - retailerId: - example: 1 - type: integer - clientId: - example: retailer001 - type: string - salesTouchpointId: - example: 1 - type: integer - type: object - productOwner: - properties: organization: - example: org + example: HTM type: string name: - example: name + example: Corneel Verstoep type: string type: object - productOwnerIdList: - items: - $ref: '#/components/schemas/productOwnerIdList_inner' - type: array - productOwners: - example: - Entries: - - productOwnerId: 123 - organization: org - name: name - - productOwnerId: 123 - organization: org - name: name + productOwnerPostPutEntity: properties: - Entries: - items: - $ref: '#/components/schemas/productOwnerIdList_inner' - type: array + organization: + example: HTM + type: string + name: + example: Corneel Verstoep + type: string type: object - productCategory: + productCategoryGetList: + example: + - productCategoryId: 1 + name: Kortingsabonnement + isTravelProduct: true + - productCategoryId: 2 + name: Afgekocht reisrecht + isTravelProduct: true + - productCategoryId: 3 + name: Supplement + isTravelProduct: true + - productCategoryId: 4 + name: Productdrager + isTravelProduct: false + - productCategoryId: 5 + name: Barcode + isTravelProduct: false + - productCategoryId: 6 + name: Merchandise + isTravelProduct: false + - productCategoryId: 7 + name: Functioneel product + isTravelProduct: false + type: array + items: + $ref: '#/components/schemas/productCategoryGetEntity' + productCategoryGetEntity: properties: + productCategoryId: + example: 1 + type: integer + name: + example: Kortingsabonnement + type: string isTravelProduct: example: true type: boolean + type: object + customerSegmentGetList: + example: + - customerSegmentId: 1 + name: Kind (4-11) + - customerSegmentId: 2 + name: Jongere (12-17) + - customerSegmentId: 3 + name: Volwassene (18-64) + - customerSegmentId: 4 + name: Oudere (65+) + - customerSegmentId: 5 + name: Student + - customerSegmentId: 6 + name: Ooievaarspas-gerechtigde + items: + $ref: '#/components/schemas/customerSegmentGetEntity' + type: array + customerSegmentGetEntity: + properties: + customerSegmentId: + example: 1 + type: integer + name: + example: Kind (4-11) + type: string + type: object + marketSegmentGetList: + example: + Entries: + - marketSegmentId: 1 + name: B2C + - marketSegmentId: 2 + name: B2B2C + - marketSegmentId: 3 + name: B2B + items: + $ref: '#/components/schemas/marketSegmentGetEntity' + type: array + marketSegmentGetEntity: + properties: + marketSegmentId: + example: 1 + type: integer + name: + example: name + type: string + paymentMomentGetList: + example: + - paymentMomentId: 1 + name: prepaid + - paymentMomentId: 2 + name: postpaid + - paymentMomentId: 3 + name: prepaid and postpaid + items: + $ref: '#/components/schemas/paymentMomentGetEntity' + type: array + paymentMomentGetEntity: + properties: + paymentMomentId: + example: 1 + type: integer + name: + example: prepaid + type: string + retailerGetList: + example: + - retailerId: 1000 + name: HTM interne touchpoints + street: Koningin Julianaplein + number: "10" + numberAddition: + postalCode: 2595 AA + city: Den Haag + country: NL + emailAddress: info@htm.nl + phoneNumber: "070 374 9002" + taxId: "572309345923" + imageReference: https://www.htm.nl/media/leif2leu/htm-logo-mobile.svg + - retailerId: 1001 + name: HTM externe touchpoints + street: Koningin Julianaplein + number: "10" + numberAddition: + postalCode: 2595 AA + city: Den Haag + country: NL + emailAddress: info@htm.nl + phoneNumber: "070 374 9002" + taxId: "572309345923" + imageReference: https://www.htm.nl/media/leif2leu/htm-logo-mobile.svg + items: + $ref: '#/components/schemas/retailerGetEntity' + type: array + retailerGetEntity: + properties: + retailerId: + example: 1 + type: integer name: example: name type: string - type: object - productCategoryIdList: - items: - $ref: '#/components/schemas/productCategoryIdList_inner' - type: array - productCategories: - example: - Entries: - - productCategoryId: 21 - name: name - isTravelProduct: true - - productCategoryId: 21 - name: name - isTravelProduct: true - properties: - Entries: - items: - $ref: '#/components/schemas/productCategoryIdList_inner' - type: array - type: object - customerSegment: - properties: - name: - example: name + street: + example: StreetName type: string - type: object - customerSegmentIdList: - items: - $ref: '#/components/schemas/customerSegmentIdList_inner' - type: array - customerSegments: - example: - Entries: - - name: name - customerSegmentId: 123 - - name: name - customerSegmentId: 123 - properties: - Entries: - items: - $ref: '#/components/schemas/customerSegmentIdList_inner' - type: array - type: object - paymentMoment: - properties: - results: - $ref: '#/components/schemas/paymentMoment_results' - paymentMomentIdList: - items: - $ref: '#/components/schemas/paymentMoment_results' - type: array - paymentMoments: - example: - Entries: - - paymentMomentId: 123 - name: name - - paymentMomentId: 123 - name: name - properties: - Entries: - items: - $ref: '#/components/schemas/paymentMoment_results' - type: array - type: object - marketSegment: - properties: - name: - example: name + number: + example: "12" type: string - marketSegmentIdList: - items: - $ref: '#/components/schemas/marketSegmentIdList_inner' - type: array - marketSegments: - example: - Entries: - - name: name - marketSegmentId: 123 - - name: name - marketSegmentId: 123 - properties: - Entries: - items: - $ref: '#/components/schemas/marketSegmentIdList_inner' - type: array - type: object - retailer: + numberAddition: + example: E + type: string + postalCode: + example: 2222 BV + type: string + city: + example: Amsterdam + type: string + country: + example: NL + type: string + emailAddress: + example: sample@email.com + type: string + phoneNumber: + example: "6123456789" + type: string + taxId: + example: taxId + type: string + imageReference: + example: imageReference + type: string + retailerPostPutEntity: properties: name: example: name @@ -2106,78 +1732,62 @@ components: imageReference: example: imageReference type: string - retailerIdList: - items: - $ref: '#/components/schemas/retailerIdList_inner' - type: array - retailers: + salesTouchpointGetList: example: - Entries: - - number: "12" - country: NL - emailAddress: sample@email.com - phoneNumber: "6123456789" - city: Amsterdam - street: StreetName - taxId: taxId - postalCode: 2222 BV - name: name - numberAddition: E - imageReference: imageReference - retailerId: 123 - - number: "12" - country: NL - emailAddress: sample@email.com - phoneNumber: "6123456789" - city: Amsterdam - street: StreetName - taxId: taxId - postalCode: 2222 BV - name: name - numberAddition: E - imageReference: imageReference - retailerId: 123 + - salesTouchpointId: 1 + name: SMP (Service Medewerker Portaal) + isActive: true + retailerId: 1000 + - salesTouchpointId: 2 + name: Website (Perplex) + isActive: true + retailerId: 1001 + items: + $ref: '#/components/schemas/salesTouchpointGetEntity' + type: array + salesTouchpointGetEntity: properties: - Entries: - items: - $ref: '#/components/schemas/retailerIdList_inner' - type: array - type: object - salesTouchpoint: - properties: - isActive: - example: true - type: boolean + salesTouchpointId: + example: 1 + type: integer name: example: name type: string + isActive: + example: true + type: boolean retailerId: - example: 21 + example: 1 type: integer type: object - salesTouchpointIdList: - items: - $ref: '#/components/schemas/salesTouchpointIdList_inner' - type: array - salesTouchpoints: - example: - Entries: - - name: name - isActive: true - retailerId: 21 - salesTouchpointId: 123 - - name: name - isActive: true - retailerId: 21 - salesTouchpointId: 123 + salesTouchpointPostPutEntity: properties: - Entries: - items: - $ref: '#/components/schemas/salesTouchpointIdList_inner' - type: array + name: + example: name + type: string + isActive: + example: true + type: boolean + retailerId: + example: 1 + type: integer type: object - serviceOption: + serviceOptionGetList: + example: + - serviceOptionId: 1 + action: refundablePerDay + description: Per dag opzegbaar met geldteruggave naar rato + - serviceOptionId: 2 + action: cancellableTermAhead + description: Per termijn vooruit opzegbaar, dus géén terugwerkende geldteruggave + items: + $ref: '#/components/schemas/serviceOptionGetEntity' + type: array + serviceOptionGetEntity: properties: + serviceOptionId: + example: 1 + type: integer action: example: action type: string @@ -2185,106 +1795,109 @@ components: example: description type: string type: object - serviceOptionIdList: - items: - $ref: '#/components/schemas/serviceOptionIdList_inner' - type: array - serviceOptions: + mandatoryCustomerDataItemGetList: example: - Entries: - - serviceOptionId: 123 - action: action - description: description - - serviceOptionId: 123 - action: action - description: description - properties: - Entries: - items: - $ref: '#/components/schemas/serviceOptionIdList_inner' - type: array - type: object - mandatoryCustomerDataItem: + - mandatoryCustomerDataItemId: 1 + customerDataItem: birthname + - mandatoryCustomerDataItemId: 2 + customerDataItem: surname + - mandatoryCustomerDataItemId: 3 + customerDataItem: dateOfBirth + - mandatoryCustomerDataItemId: 4 + customerDataItem: emailAddress + - mandatoryCustomerDataItemId: 5 + customerDataItem: address + - mandatoryCustomerDataItemId: 6 + customerDataItem: phone + - mandatoryCustomerDataItemId: 7 + customerDataItem: ovPayToken + - mandatoryCustomerDataItemId: 8 + customerDataItem: padBirthDate + - mandatoryCustomerDataItemId: 9 + customerDataItem: shippingAddress + - mandatoryCustomerDataItemId: 10 + customerDataItem: billingAddress + items: + $ref: '#/components/schemas/mandatoryCustomerDataItemGetEntity' + type: array + mandatoryCustomerDataItemGetEntity: properties: + mandatoryCustomerDataItemId: + example: 1 + type: integer customerDataItem: example: customerDataItem type: string type: object - mandatoryCustomerDataItemIdList: - items: - $ref: '#/components/schemas/mandatoryCustomerDataItemIdList_inner' - type: array - mandatoryCustomerDataItems: + requiredCustomerLevelGetList: example: - Entries: - - mandatoryCustomerDataItemId: 1 - customerDataItem: birthname - - mandatoryCustomerDataItemId: 1 - customerDataItem: birthname - properties: - Entries: - items: - $ref: '#/components/schemas/mandatoryCustomerDataItemIdList_inner' - type: array + - requiredCustomerLevelId: 1 + name: guest + - requiredCustomerLevelId: 2 + name: contact + - requiredCustomerLevelId: 3 + name: profile + items: + $ref: '#/components/schemas/requiredCustomerLevelGetEntity' + type: array + requiredCustomerLevelGetEntity: type: object - requiredCustomerLevelIdList: - items: - $ref: '#/components/schemas/requiredCustomerLevelIdList_inner' - type: array - requiredCustomerLevels: - example: - Entries: - - requiredCustomerLevelId: 123 - name: requiredCustomerLevel - - requiredCustomerLevelId: 123 - name: requiredCustomerLevel properties: - Entries: - items: - $ref: '#/components/schemas/requiredCustomerLevelIdList_inner' - type: array - type: object - forbiddenPaymentMethodList: - items: - $ref: '#/components/schemas/forbiddenPaymentMethodList_inner' - type: array - getforbiddenPaymentMethodList: + requiredCustomerLevelId: + example: 1 + type: integer + name: + example: guest + type: string + forbiddenPaymentMethodGetList: example: - Entries: - - forbiddenPaymentMethodId: 123 - name: requiredCustomerLevel - issuer: Kane - - forbiddenPaymentMethodId: 123 - name: requiredCustomerLevel - issuer: Kane + - forbiddenPaymentMethodId: 1 + name: creditcard + issuer: Mastercard + - forbiddenPaymentMethodId: 2 + name: creditcard + issuer: Visa + - forbiddenPaymentMethodId: 3 + name: creditcard + issuer: American Express + items: + $ref: '#/components/schemas/forbiddenPaymentMethodGetEntity' + type: array + forbiddenPaymentMethodGetEntity: properties: - Entries: - items: - $ref: '#/components/schemas/forbiddenPaymentMethodList_inner' - type: array + forbiddenPaymentMethodId: + example: 3 + type: integer + name: + example: creditcard + type: string + issuer: + example: American Express + type: string type: object - GetRequiredGboPersonalAttribute: - items: - $ref: '#/components/schemas/GetRequiredGboPersonalAttribute_inner' - type: array - requiredGboPersonalAttributes: + requiredGboPersonalAttributeGetList: example: - Entries: - name: NAME requiredGboPersonalAttributeId: 1 - name: BIRTHDATE requiredGboPersonalAttributeId: 2 - name: PHOTO requiredGboPersonalAttributeId: 3 - properties: - Entries: - items: - $ref: '#/components/schemas/GetRequiredGboPersonalAttribute_inner' - type: array - type: object - GboAgeProfileList: items: - $ref: '#/components/schemas/GboAgeProfile' + $ref: '#/components/schemas/requiredGboPersonalAttributeGetEntity' + type: array + requiredGboPersonalAttributeGetEntity: + properties: + requiredGboPersonalAttributeId: + example: 1 + type: integer + name: + example: NAME + type: string + type: object + gboAgeProfileGetList: + items: + $ref: '#/components/schemas/gboAgeProfileGetEntity' type: array example: Entries: @@ -2308,7 +1921,7 @@ components: name: Oudere (65 jaar of ouder) ageFromInclusive: 65 ageToInclusive: 999 - GboAgeProfile: + gboAgeProfileGetEntity: type: object required: - gboAgeProfileId @@ -2329,13 +1942,46 @@ components: ageToInclusive: type: integer description: The maximum age that the GBO age profile applies to - example: 11 - GetproductReferences: + example: 11 + productReferencesGetList: + type: object + required: + - Entries properties: Entries: - $ref: '#/components/schemas/GetproductReferences_Entries' - type: object - "400Response": + type: object + properties: + clientAttributes: + $ref: '#/components/schemas/clientAttributesGetList' + layerInfos: + $ref: '#/components/schemas/layerInfoGetList' + productOwners: + $ref: '#/components/schemas/productOwnerGetList' + productCategories: + $ref: '#/components/schemas/productCategoryGetList' + customerSegments: + $ref: '#/components/schemas/customerSegmentGetList' + marketSegments: + $ref: '#/components/schemas/marketSegmentGetList' + paymentMoments: + $ref: '#/components/schemas/paymentMomentGetList' + retailers: + $ref: '#/components/schemas/retailerGetList' + salesTouchpoints: + $ref: '#/components/schemas/salesTouchpointGetList' + serviceOptions: + $ref: '#/components/schemas/serviceOptionGetList' + mandatoryCustomerDataItems: + $ref: '#/components/schemas/mandatoryCustomerDataItemGetList' + requiredCustomerLevels: + $ref: '#/components/schemas/requiredCustomerLevelGetList' + forbiddenPaymentMethods: + $ref: '#/components/schemas/forbiddenPaymentMethodGetList' + requiredGboPersonalAttributes: + $ref: '#/components/schemas/requiredGboPersonalAttributeGetList' + gboAgeProfiles: + $ref: '#/components/schemas/gboAgeProfileGetList' + 400Response: properties: code: example: "400" @@ -2349,7 +1995,7 @@ components: example: '''2023-02-01 00:00:00'' is not a valid Datetime' type: string type: object - "401Response": + 401Response: properties: code: example: "900901" @@ -2364,7 +2010,7 @@ components: credentials type: string type: object - "404Response": + 404Response: properties: code: example: "404" @@ -2379,19 +2025,19 @@ components: example: The requested resource is not available. type: string type: object - "404ResponseId": + 404ResponseId: properties: error: example: "No record found for id: 5" type: string type: object - "409Response": + 409Response: properties: error: example: Entry already exists type: string type: object - "500Response": + 500Response: properties: code: example: "500" @@ -2404,7 +2050,7 @@ components: description: type: string type: object - _clientattributes_post_201_response: + postPutSuccessResponse: example: id: 1 properties: @@ -2412,251 +2058,7 @@ components: example: 1 type: integer type: object - _clientattributes__clientAttributeId__put_404_response: + postPut404Response: oneOf: - $ref: '#/components/schemas/404ResponseId' - $ref: '#/components/schemas/404Response' - _productreferences_get_200_response: - allOf: - - $ref: '#/components/schemas/GetproductReferences' - clientAttributesGetList_inner: - example: - clientId: htm - description: description - clientAttributeId: 1 - isActive: "true" - retailerId: 1 - salesTouchpointId: 2 - properties: - clientAttributeId: - example: 1 - type: integer - clientId: - example: htm - type: string - description: - example: description - type: string - isActive: - example: "true" - type: string - retailerId: - example: 1 - type: integer - salesTouchpointId: - example: 2 - type: integer - productOwnerIdList_inner: - example: - productOwnerId: 123 - organization: org - name: name - properties: - productOwnerId: - example: 123 - type: integer - name: - example: name - type: string - organization: - example: org - type: string - productCategoryIdList_inner: - example: - productCategoryId: 21 - name: name - isTravelProduct: true - properties: - isTravelProduct: - example: true - type: boolean - name: - example: name - type: string - productCategoryId: - example: 21 - type: integer - customerSegmentIdList_inner: - example: - name: name - customerSegmentId: 123 - properties: - name: - example: name - type: string - customerSegmentId: - example: 123 - type: integer - paymentMoment_results: - example: - paymentMomentId: 123 - name: name - properties: - paymentMomentId: - example: 123 - type: integer - name: - example: name - type: string - marketSegmentIdList_inner: - example: - name: name - marketSegmentId: 123 - properties: - name: - example: name - type: string - marketSegmentId: - example: 123 - type: integer - retailerIdList_inner: - example: - number: "12" - country: NL - emailAddress: sample@email.com - phoneNumber: "6123456789" - city: Amsterdam - street: StreetName - taxId: taxId - postalCode: 2222 BV - name: name - numberAddition: E - imageReference: imageReference - retailerId: 123 - properties: - name: - example: name - type: string - street: - example: StreetName - type: string - number: - example: "12" - type: string - numberAddition: - example: E - type: string - postalCode: - example: 2222 BV - type: string - city: - example: Amsterdam - type: string - country: - example: NL - type: string - emailAddress: - example: sample@email.com - type: string - phoneNumber: - example: "6123456789" - type: string - taxId: - example: taxId - type: string - imageReference: - example: imageReference - type: string - retailerId: - example: 123 - type: integer - salesTouchpointIdList_inner: - example: - name: name - isActive: true - retailerId: 21 - salesTouchpointId: 123 - properties: - isActive: - example: true - type: boolean - name: - example: name - type: string - retailerId: - example: 21 - type: integer - salesTouchpointId: - example: 123 - type: integer - serviceOptionIdList_inner: - example: - serviceOptionId: 123 - action: action - description: description - properties: - action: - example: action - type: string - description: - example: description - type: string - serviceOptionId: - example: 123 - type: integer - mandatoryCustomerDataItemIdList_inner: - example: - mandatoryCustomerDataItemId: 1 - customerDataItem: birthname - properties: - mandatoryCustomerDataItemId: - example: 1 - type: integer - customerDataItem: - example: birthname - type: string - requiredCustomerLevelIdList_inner: - example: - requiredCustomerLevelId: 123 - name: requiredCustomerLevel - properties: - requiredCustomerLevelId: - example: 123 - type: integer - name: - example: requiredCustomerLevel - type: string - forbiddenPaymentMethodList_inner: - example: - forbiddenPaymentMethodId: 123 - name: requiredCustomerLevel - issuer: Kane - properties: - forbiddenPaymentMethodId: - example: 123 - type: integer - name: - example: CreditCard - type: string - issuer: - example: American Express - type: string - type: object - GetRequiredGboPersonalAttribute_inner: - example: - requiredGboPersonalAttributeId: 1 - name: NAME - properties: - requiredGboPersonalAttributeId: - example: 1 - type: integer - name: - example: NAME - type: string - type: object - GetproductReferences_Entries: - oneOf: - - $ref: '#/components/schemas/clientAttributesGetEntity' - - $ref: '#/components/schemas/productOwners' - - $ref: '#/components/schemas/productCategories' - - $ref: '#/components/schemas/customerSegments' - - $ref: '#/components/schemas/marketSegments' - - $ref: '#/components/schemas/paymentMoments' - - $ref: '#/components/schemas/retailers' - - $ref: '#/components/schemas/salesTouchpoints' - - $ref: '#/components/schemas/serviceOptions' - - $ref: '#/components/schemas/mandatoryCustomerDataItems' - - $ref: '#/components/schemas/requiredCustomerLevels' - - $ref: '#/components/schemas/getforbiddenPaymentMethodList' - - $ref: '#/components/schemas/requiredGboPersonalAttributes' - - $ref: '#/components/schemas/GboAgeProfileList' \ No newline at end of file From 7de54cbd86f52bb8fb0cfd64d9a4201cb868727a Mon Sep 17 00:00:00 2001 From: Max Martens Date: Sun, 17 Aug 2025 19:53:29 +0200 Subject: [PATCH 2/7] WIP, still need to fix some very legacy incorrect confusing stuff in this OAI-spec (thanks Greg for pointing that out!) --- src/openapi/products/products-crud.yaml | 319 ++++++++++++++++++++++-- 1 file changed, 301 insertions(+), 18 deletions(-) diff --git a/src/openapi/products/products-crud.yaml b/src/openapi/products/products-crud.yaml index f0a72ce..d86e7f6 100644 --- a/src/openapi/products/products-crud.yaml +++ b/src/openapi/products/products-crud.yaml @@ -778,6 +778,7 @@ paths: { "productId": 1, "parentProductId": null, + "layerInfo": null, "fikoArticleNumber": "1234", "isValid": true, "isArchived": false, @@ -839,7 +840,7 @@ paths: }, "requiredCustomerLevel": { "requiredCustomerLevelId": 1, - "name": "anonymous" + "name": "guest" }, "requiredProducts": null, "incompatibleProducts": [ @@ -952,6 +953,7 @@ paths: { "productId": 2, "parentProductId": null, + "layerInfo": null, "fikoArticleNumber": "1234", "isValid": true, "isArchived": false, @@ -1013,7 +1015,7 @@ paths: }, "requiredCustomerLevel": { "requiredCustomerLevelId": 1, - "name": "anonymous" + "name": "guest" }, "requiredProducts": null, "incompatibleProducts": [ @@ -1176,17 +1178,18 @@ paths: "timestamp": "2024-09-03T08:38:24.000+00:00" } ] - } + } getDetailsGboPadProduct: summary: GBO product (PAD required, renewable, serviceOptions, forbiddenPaymentMethods) value: { "productId": 3, "parentProductId": null, + "layerInfo": null, "fikoArticleNumber": "1234", "isValid": true, "isArchived": false, - "gboPackageTemplateId": "35301", + "gboPackageTemplateId": "33610", "tapConnectProductCode": null, "productName": "HTM Regio Vrij DH73", "productDescription": "Voor een vast bedrag onbeperkt reizen met EBS, HTM en RET in het gekozen gebied in de regio Rotterdam Den Haag.", @@ -1223,6 +1226,237 @@ paths: "name": "Ooievaarspas-gerechtigde" } ], + "allowedGboAgeProfiles": [ + { + "gboAgeProfileId": 2, + "name": "Kind (4 t/m 11 jaar)", + "ageFromInclusive": 4, + "ageToInclusive": 11 + }, + { + "gboAgeProfileId": 3, + "name": "Jongere (12 t/m 18 jaar)", + "ageFromInclusive": 12, + "ageToInclusive": 18 + }, + { + "gboAgeProfileId": 4, + "name": "Volwassene (19 t/m 64 jaar)", + "ageFromInclusive": 19, + "ageToInclusive": 64 + }, + { + "gboAgeProfileId": 5, + "name": "Oudere (65 jaar of ouder)", + "ageFromInclusive": 65, + "ageToInclusive": 999 + } + ], + "productCategory": { + "productCategoryId": 3, + "isTravelProduct": true, + "name": "Afgekocht reisrecht" + }, + "requiredCustomerLevel": { + "requiredCustomerLevelId": 3, + "name": "profile" + }, + "requiredProducts": null, + "incompatibleProducts": [ + { + "incompatibleProductId": 3, + "productName": "HTM Regio Vrij DH73", + "description": "Kan niet combineren met zichzelf" + } + ], + "mandatoryCustomerDataItems": [ + { + "mandatoryCustomerDataItemId": 4, + "customerDataItem": "emailAddress" + }, + { + "mandatoryCustomerDataItemId": 8, + "customerDataItem": "padBirthDate" + } + ], + "requiredGboPersonalAttributes": [ + { + "requiredGboPersonalAttributeId": 1, + "name": "NAME" + }, + { + "requiredGboPersonalAttributeId": 2, + "name": "BIRTHDATE" + }, + { + "requiredGboPersonalAttributeId": 3, + "name": "PHOTO" + } + ], + "tokenTypes": [ + { + "tokenTypeId": 1, + "name": "EMV" + }, + { + "tokenTypeId": 2, + "name": "OVpas physical" + }, + { + "tokenTypeId": 3, + "name": "OVpas digital" + } + ], + "paymentMoment": { + "paymentMomentId": 1, + "name": "prepaid" + }, + "serviceOptions": [ + { + "serviceOptionId": 1, + "action": "cancellableTermAhead", + "description": "Per termijn vooruit opzegbaar" + } + ], + "validityDuration": "P1M", + "maxStartInFutureDuration": "P6W", + "isRenewable": true, + "sendInvoice": true, + "imageReference": "https://www.htm.nl/media/leif2leu/htm-logo-mobile.svg", + "productPageUrl": "https://www.htm.nl/nog-onbekende-product-pagina", + "termsUrl": "https://www.htm.nl/nog-onbekende-productvoorwaarden-pagina", + "isSellableAtHtm": true, + "needsSolvencyCheckConsumer": false, + "needsSolvencyCheckBusiness": false, + "sellingPeriods": [ + { + "sellingPeriodId": 5, + "fromInclusive": "2024-09-01T00:00:00.000+00:00", + "toInclusive": "2024-12-31T23:59:59.999+00:00", + "salesTouchpoint": { + "salesTouchpointId": 3, + "name": "Website (Perplex)", + "isActive": true, + "retailer": { + "retailerId": 1001, + "name": "HTM externe touchpoints", + "street": "Koningin Julianaplein", + "number": "10", + "numberAddition": null, + "postalCode": "2595 AA", + "city": "Den Haag", + "country": "Nederland", + "emailAddress": "info@htm.nl", + "phoneNumber": "070 374 9002", + "taxId": "572309345923", + "imageReference": "https://www.htm.nl/media/leif2leu/htm-logo-mobile.svg" + } + }, + "forbiddenPaymentMethods": [ + { + "forbiddenPaymentMethodId": 1, + "name": "Credit Card", + "issuer": "American Express" + } + ], + "sellingPrices": [ + { + "sellingPriceId": 5, + "amountExclTax": 5413, + "amountInclTax": 5900, + "taxCode": "V09", + "taxPercentage": 9.0000, + "fromInclusive": "2024-09-01T00:00:00.000+00:00", + "toInclusive": "2024-12-31T23:59:59.999+00:00", + "internalPrice": 5413.0000 + } + ] + } + ], + "purchasePrices": [ + { + "purchasePriceId": 1, + "amountExclTax": 0, + "taxCode": "V09", + "taxPercentage": 9.0000, + "amountInclTax": 0, + "fromInclusive": "2024-09-01T00:00:00.000+00:00", + "toInclusive": "2024-12-31T23:59:59.999+00:00" + } + ], + "auditTrail": [ + { + "auditTrailId": 2, + "action": "update", + "user": "api", + "timestamp": "2024-09-03T08:39:38.000+00:00" + }, + { + "auditTrailId": 1, + "action": "insert", + "user": "api", + "timestamp": "2024-09-03T08:38:24.000+00:00" + } + ] + } + getDetailsProductVariantWithParent: + summary: GBO product-variant, meaning that parentProductId and layerInfo are present + description: >- + This product is not a top-level parent, but a product-variant that refers to another product (via `parentProductId`). + This means that the `layerInfo` should be present for this product-variant. The parent product references is `productId 3`, + so the product in this example is an extension of that product-definition. MOre specifically: in this product-variant, we + removed some `allowedGboAgeProfiles` from the definition - this means that the customer has to provide the birthdate of + the token-owner (padBirthdate) in order to be able to buy this product-variant. + value: + { + "productId": 4, + "parentProductId": 3, + "layerInfoId": { + "layerInfoId": 1, + "choiceKey": "allowedGboAgeProfiles", + "choiceLabel": "Wat is uw geboortedatum?", + "isCustomChoice": false + }, + "fikoArticleNumber": "1234", + "isValid": true, + "isArchived": false, + "gboPackageTemplateId": "33610", + "tapConnectProductCode": null, + "productName": "HTM Regio Vrij DH73 Reductietarief", + "productDescription": "Voor een vast bedrag onbeperkt reizen met EBS, HTM en RET in het gekozen gebied in de regio Rotterdam Den Haag.", + "validityPeriod": { + "validityPeriodId": 3, + "fromInclusive": "2024-09-01T00:00:00.000+00:00", + "toInclusive": "2024-12-31T23:59:59.999+00:00" + }, + "productTranslations": [ + { + "language": "en", + "name": "HTM Regio Free DH73", + "description": "For a fixed amount unlimited travel with EBS, HTM and RET in the chosen area in the Rotterdam The Hague region." + } + ], + "productOwner": { + "productOwnerId": 1, + "name": "Corneel Verstoep", + "organization": "HTM" + }, + "marketSegments": [ + { + "marketSegmentId": 1, + "name": "B2C" + } + ], + "customerSegments": [ + { + "customerSegmentId": 6, + "name": "Student" + }, + { + "customerSegmentId": 7, + "name": "Ooievaarspas-gerechtigde" + } + ], "allowedGboAgeProfiles": [ { "gboAgeProfileId": 2, @@ -1244,33 +1478,25 @@ paths: }, "requiredCustomerLevel": { "requiredCustomerLevelId": 3, - "name": "account" + "name": "profile" }, "requiredProducts": null, "incompatibleProducts": [ { - "incompatibleProductId": 3, - "productName": "HTM Regio Vrij DH73", + "incompatibleProductId": 4, + "productName": "HTM Regio Vrij DH73 Reductietarief", "description": "Kan niet combineren met zichzelf" } ], "mandatoryCustomerDataItems": [ - { - "mandatoryCustomerDataItemId": 3, - "customerDataItem": "dateOfBirth" - }, { "mandatoryCustomerDataItemId": 4, "customerDataItem": "emailAddress" }, { - "mandatoryCustomerDataItemId": 5, - "customerDataItem": "ovPayToken" + "mandatoryCustomerDataItemId": 8, + "customerDataItem": "padBirthDate" }, - { - "mandatoryCustomerDataItemId": 6, - "customerDataItem": "directDebitMandate" - } ], "requiredGboPersonalAttributes": [ { @@ -1981,6 +2207,53 @@ paths: $ref: '#/components/schemas/500Response' components: schemas: + LayerInfoResponse: + type: object + description: >- + Gives information on the choice that the customer has to make, to enable the touchpoint + to proceed further "down the product-tree" by selecting (PATCH-ing) the correct product-variant. + LayerInfo is not a mandatory product-attribute, but it should always be present on all product for which + `parentProductId != null`. (LayerInfo makes no sense for top-level parents as there is always a single starting point). \ + + **PMT should ensure that all products in the same "product-branch" (same `parentProductId`) have the same `layerInfoId` + referenced. If a product is found to be in violation of this rule, its attribtue `isValid` should be set to `false`.** + required: + - layerInfoId + - choiceKey + - choiceLabel + - isCustomChoice + properties: + layerInfoId: + example: 1 + type: integer + choiceKey: + example: isRenewable + type: string + description: >- + Contains the JSON Key of the product-attribute that the customer has to make some + choice on (determined by PMT), so that te correct product-variant can be selected by the touchpoint. For some + decisions (like region), there is no product attribute, and thus `isCustomChoice` will be set + to `true`, and `choiceKey` can then be set to any string on which touchpoints can also trigger + behaviour if desired (think "region picker tool"). Therefore, reuse of choiceKeys should be + the goal, so touchoints can keep their triggers simple and prevent duplication of + similar choiceKeys to trigger the same behaviour. + choiceLabel: + example: Kies voor een doorlopend abonnement of een enkele termijn + type: string + description: >- + Contains a human-readable label for the choice that the customer has to make - this label + should be something that is easy to understand for the customer. Only one label (and thus, one language) + is supported; label translations should be handled by the touchpoint. + isCustomChoice: + example: false + type: boolean + description: >- + Indicates if the choice is a custom choice. If `false`, the PMT should fill `choiceKey` with the + "differing attribute for this product-layer" and the user should not be able to override this. When + no single attribute can be pinpointed by PMT, the product will become invalid (`isValid == false`) until either + a situation with a single differing attribute is created, or if `isCustomChoice` is set to `true` - this would, + however, also mean that touchpoints should be notified of this, especially if the configured LayerInfo contains + a new, not previously used, `choiceKey`. GboAgeProfileResponse: type: object required: @@ -2246,6 +2519,8 @@ components: parentProductId: type: integer example: 1 + layerInfo: + $ref: '#/components/schemas/LayerInfoResponse' fikoArticleNumber: type: string description: The article number of the product in FIKO @@ -2367,7 +2642,7 @@ components: example: 1 name: type: string - example: anonymous + example: guest requiredProducts: type: array items: @@ -2599,6 +2874,10 @@ components: type: integer description: The ID of the parent product (if any) example: 1 + layerInfoId: + type: integer + description: Only relevant when `parentProductId != null`; the ID of the layerInfo reference, giving information on why this layer of product-variants exists (PMT should enforce that this is filled for all products for which `parentProductId != null`) + example: 1 fikoArticleNumber: type: string description: The article number of the product in FIKO @@ -2972,6 +3251,10 @@ components: type: integer description: The ID of the parent product (if any) example: 1 + layerInfoId: + type: integer + description: Only relevant when `parentProductId != null`; the ID of the layerInfo reference, giving information on why this layer of product-variants exists (PMT should enforce that this is filled for all products for which `parentProductId != null`) + example: 1 fikoArticleNumber: type: string description: The article number of the product in FIKO From d4c5165b395919c627692b802b78db2109a816f3 Mon Sep 17 00:00:00 2001 From: Max Martens Date: Sun, 17 Aug 2025 22:25:49 +0200 Subject: [PATCH 3/7] Fixed --- .../products/productreference-crud.yaml | 2 +- src/openapi/products/products-crud.yaml | 204 +++++++----------- 2 files changed, 75 insertions(+), 131 deletions(-) diff --git a/src/openapi/products/productreference-crud.yaml b/src/openapi/products/productreference-crud.yaml index 7428502..b96bd70 100644 --- a/src/openapi/products/productreference-crud.yaml +++ b/src/openapi/products/productreference-crud.yaml @@ -2,7 +2,7 @@ openapi: 3.0.1 info: title: ABTProductReference description: >- - CRUD APIs for HTM product reference tables (based on the new domainmodel v2.4). + CRUD APIs for HTM product reference tables (based on the new domainmodel v2.6). Internal use only; external touchpoints can get (some)) access via the HTM Service Engine, using a different endpoint. version: '1.0' diff --git a/src/openapi/products/products-crud.yaml b/src/openapi/products/products-crud.yaml index d86e7f6..b236c3a 100644 --- a/src/openapi/products/products-crud.yaml +++ b/src/openapi/products/products-crud.yaml @@ -2,7 +2,7 @@ openapi: 3.0.1 info: title: ABTProducts description: >- - CRUD APIs for HTM products (based on the new domainmodel v2.5). Internal use + CRUD APIs for HTM products (based on the new domainmodel v2.6). Internal use only; external touchpoints can get read-only, filtered access via the HTM Service Engine, using a different endpoint. version: '1.0' @@ -126,7 +126,7 @@ paths: "productName": "HTM dagkaart", "productDescription": "Reis een dag met het openbaar vervoer bij HTM", "productCategory": { - "productCategoryId": 6, + "productCategoryId": 5, "isTravelProduct": false, "name": "Barcode" }, @@ -154,7 +154,7 @@ paths: "productName": "HTM dagkaart", "productDescription": "Reis een dag met het openbaar vervoer bij HTM", "productCategory": { - "productCategoryId": 6, + "productCategoryId": 5, "isTravelProduct": false, "name": "Barcode" }, @@ -204,7 +204,7 @@ paths: "productName": "HTM dagkaart", "productDescription": "Reis een dag met het openbaar vervoer bij HTM", "productCategory": { - "productCategoryId": 6, + "productCategoryId": 5, "isTravelProduct": false, "name": "Barcode" }, @@ -282,7 +282,7 @@ paths: "productName": "HTM dagkaart", "productDescription": "Reis een dag met het openbaar vervoer bij HTM", "productCategory": { - "productCategoryId": 6, + "productCategoryId": 5, "isTravelProduct": false, "name": "Barcode" }, @@ -398,13 +398,10 @@ paths: 1 ], "customerSegmentIds": [ - 6, - 7 - ], - "allowedGboAgeProfileIds": [ - 1, - 2 + 5, + 6 ], + "allowedGboAgeProfileIds": [], "productCategoryId": 1, "requiredCustomerLevelId": 1, "incompatibleProducts": [ @@ -415,7 +412,7 @@ paths: ], "mandatoryCustomerDataItemIds": [ 4, - 5 + 7 ], "tokenTypeIds": [ 1 @@ -462,8 +459,7 @@ paths: } postGboProductMultiplePeriods: summary: >- - Add new GBO product (non-renewable, multiple - sellingPeriods/prices per period) + Add new GBO product (non-renewable, multiple sellingPeriods/prices per period) value: { "fikoArticleNumber": "1234", @@ -488,13 +484,10 @@ paths: 1 ], "customerSegmentIds": [ - 6, - 7 - ], - "allowedGboAgeProfileIds": [ - 1, - 2 + 5, + 6 ], + "allowedGboAgeProfileIds": [], "productCategoryId": 1, "requiredCustomerLevelId": 1, "incompatibleProducts": [ @@ -505,7 +498,7 @@ paths: ], "mandatoryCustomerDataItemIds": [ 4, - 5 + 7 ], "tokenTypeIds": [ 1 @@ -586,14 +579,13 @@ paths: } postGboPadProduct: summary: >- - Add new GBO product (PAD required, renewable, serviceOptions, - forbiddenPaymentMethods) + Add new GBO product (PAD required, renewable, allowedGboAgeProfiles, padBirthDate) value: { "fikoArticleNumber": "1234", "isValid": true, "isArchived": false, - "gboPackageTemplateId": "35301", + "gboPackageTemplateId": "33610", "productName": "HTM Regio Vrij DH73", "productDescription": "Voor een vast bedrag onbeperkt reizen met EBS, HTM en RET in het gekozen gebied in de regio Rotterdam Den Haag.", "validityPeriod": { @@ -612,14 +604,16 @@ paths: 1 ], "customerSegmentIds": [ - 6, - 7 + 5, + 6 ], - "allowedGboAgeProfileIds": [ - 1, - 2 + "allowedGboAgeProfileIds": [ + 2, + 3, + 4, + 5 ], - "productCategoryId": 3, + "productCategoryId": 2, "requiredCustomerLevelId": 3, "requiredProducts": [ { @@ -634,10 +628,8 @@ paths: } ], "mandatoryCustomerDataItemIds": [ - 3, 4, - 5, - 6 + 8 ], "requiredGboPersonalAttributeIds": [ 1, @@ -650,10 +642,7 @@ paths: 3 ], "paymentMomentId": 1, - "serviceOptionIds": [ - 1, - 2 - ], + "serviceOptionIds": [], "validityDuration": "P1M", "maxStartInFutureDuration": "P6W", "isRenewable": true, @@ -670,7 +659,7 @@ paths: "toInclusive": "2024-12-31T23:59:59.999", "salesTouchpointId": 3, "forbiddenPaymentMethodIds": [ - 1 + 3 ], "sellingPrices": [ { @@ -811,28 +800,15 @@ paths: ], "customerSegments": [ { - "customerSegmentId": 6, + "customerSegmentId": 5, "name": "Student" }, { - "customerSegmentId": 7, + "customerSegmentId": 6, "name": "Ooievaarspas-gerechtigde" } ], - "allowedGboAgeProfiles": [ - { - "gboAgeProfileId": 2, - "name": "Kind (4 t/m 11 jaar)", - "ageFromInclusive": 4, - "ageUntilInclusive": 11 - }, - { - "gboAgeProfileId": 3, - "name": "Jongere (12 t/m 18 jaar)", - "ageFromInclusive": 12, - "ageUntilInclusive": 18 - } - ], + "allowedGboAgeProfiles": null, "productCategory": { "productCategoryId": 1, "isTravelProduct": true, @@ -856,7 +832,7 @@ paths: "customerDataItem": "emailAddress" }, { - "mandatoryCustomerDataItemId": 5, + "mandatoryCustomerDataItemId": 7, "customerDataItem": "ovPayToken" } ], @@ -986,11 +962,11 @@ paths: ], "customerSegments": [ { - "customerSegmentId": 6, + "customerSegmentId": 5, "name": "Student" }, { - "customerSegmentId": 7, + "customerSegmentId": 6, "name": "Ooievaarspas-gerechtigde" } ], @@ -1031,7 +1007,7 @@ paths: "customerDataItem": "emailAddress" }, { - "mandatoryCustomerDataItemId": 5, + "mandatoryCustomerDataItemId": 7, "customerDataItem": "ovPayToken" } ], @@ -1180,7 +1156,7 @@ paths: ] } getDetailsGboPadProduct: - summary: GBO product (PAD required, renewable, serviceOptions, forbiddenPaymentMethods) + summary: GBO product (PAD required, renewable, allowedGboAgeProfiles, padBirthDate) value: { "productId": 3, @@ -1218,11 +1194,11 @@ paths: ], "customerSegments": [ { - "customerSegmentId": 6, + "customerSegmentId": 5, "name": "Student" }, { - "customerSegmentId": 7, + "customerSegmentId": 6, "name": "Ooievaarspas-gerechtigde" } ], @@ -1253,7 +1229,7 @@ paths: } ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht" }, @@ -1311,13 +1287,7 @@ paths: "paymentMomentId": 1, "name": "prepaid" }, - "serviceOptions": [ - { - "serviceOptionId": 1, - "action": "cancellableTermAhead", - "description": "Per termijn vooruit opzegbaar" - } - ], + "serviceOptions": [], "validityDuration": "P1M", "maxStartInFutureDuration": "P6W", "isRenewable": true, @@ -1354,8 +1324,8 @@ paths: }, "forbiddenPaymentMethods": [ { - "forbiddenPaymentMethodId": 1, - "name": "Credit Card", + "forbiddenPaymentMethodId": 3, + "name": "creditcard", "issuer": "American Express" } ], @@ -1449,11 +1419,11 @@ paths: ], "customerSegments": [ { - "customerSegmentId": 6, + "customerSegmentId": 5, "name": "Student" }, { - "customerSegmentId": 7, + "customerSegmentId": 6, "name": "Ooievaarspas-gerechtigde" } ], @@ -1472,7 +1442,7 @@ paths: } ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht" }, @@ -1530,18 +1500,7 @@ paths: "paymentMomentId": 1, "name": "prepaid" }, - "serviceOptions": [ - { - "serviceOptionId": 1, - "action": "cancellableTermAhead", - "description": "Per termijn vooruit opzegbaar" - }, - { - "serviceOptionId": 2, - "action": "cancellableWithin14Days", - "description": "Binnen 14 dagen na aanschaf opzegbaar, met restitutie en herberekening ritten met product" - } - ], + "serviceOptions": null, "validityDuration": "P1M", "maxStartInFutureDuration": "P6W", "isRenewable": true, @@ -1578,8 +1537,8 @@ paths: }, "forbiddenPaymentMethods": [ { - "forbiddenPaymentMethodId": 1, - "name": "Credit Card", + "forbiddenPaymentMethodId": 3, + "name": "creditcard", "issuer": "American Express" } ], @@ -1727,13 +1686,10 @@ paths: 1 ], "customerSegmentIds": [ - 6, - 7 - ], - "allowedGboAgeProfileIds": [ - 1, - 2 + 5, + 6 ], + "allowedGboAgeProfileIds": [], "productCategoryId": 1, "requiredCustomerLevelId": 1, "incompatibleProducts": [ @@ -1744,7 +1700,7 @@ paths: ], "mandatoryCustomerDataItemIds": [ 4, - 5 + 7 ], "tokenTypeIds": [ 1 @@ -1794,8 +1750,7 @@ paths: } advancedUpdateGboProduct: summary: >- - Advanced update (remove mandatoryCustomerDataItem references, - add new second sellingPeriod) + Advanced update (remove mandatoryCustomerDataItem references, add new second sellingPeriod) value: { "fikoArticleNumber": "1234", @@ -1821,13 +1776,10 @@ paths: 1 ], "customerSegmentIds": [ - 6, - 7 - ], - "allowedGboAgeProfileIds": [ - 1, - 2 + 5, + 6 ], + "allowedGboAgeProfileIds": [], "productCategoryId": 1, "requiredCustomerLevelId": 1, "incompatibleProducts": [ @@ -1910,8 +1862,7 @@ paths: } updateGboProductMultiplePeriods: summary: >- - Update existing GBO product (non-renewable, multiple - sellingPeriods/prices per period) + Update existing GBO product (non-renewable, multiple sellingPeriods/prices per period) value: { "fikoArticleNumber": "1234", @@ -1937,13 +1888,10 @@ paths: 1 ], "customerSegmentIds": [ - 6, - 7 - ], - "allowedGboAgeProfileIds": [ - 1, - 2 + 5, + 6 ], + "allowedGboAgeProfileIds": [], "productCategoryId": 1, "requiredCustomerLevelId": 1, "incompatibleProducts": [ @@ -1954,7 +1902,7 @@ paths: ], "mandatoryCustomerDataItemIds": [ 4, - 5 + 7 ], "tokenTypeIds": [ 1 @@ -2042,14 +1990,13 @@ paths: } updateGboPadProduct: summary: >- - Update existing GBO product (PAD required, renewable, - serviceOptions, forbiddenPaymentMethods) + Update existing GBO product (PAD required, renewable, allowedGboAgeProfiles, padBirthDate) value: { "fikoArticleNumber": "1234", "isValid": true, "isArchived": false, - "gboPackageTemplateId": "35301", + "gboPackageTemplateId": "33610", "productName": "HTM Regio Vrij DH73", "productDescription": "Voor een vast bedrag onbeperkt reizen met EBS, HTM en RET in het gekozen gebied in de regio Rotterdam Den Haag.", "validityPeriod": { @@ -2069,14 +2016,16 @@ paths: 1 ], "customerSegmentIds": [ - 6, - 7 + 5, + 6 ], "allowedGboAgeProfileIds": [ - 1, - 2 + 2, + 3, + 4, + 5 ], - "productCategoryId": 3, + "productCategoryId": 2, "requiredCustomerLevelId": 3, "requiredProducts": [ { @@ -2091,10 +2040,8 @@ paths: } ], "mandatoryCustomerDataItemIds": [ - 3, 4, - 5, - 6 + 8 ], "requiredGboPersonalAttributeIds": [ 1, @@ -2107,10 +2054,7 @@ paths: 3 ], "paymentMomentId": 1, - "serviceOptionIds": [ - 1, - 2 - ], + "serviceOptionIds": [], "validityDuration": "P1M", "maxStartInFutureDuration": "P6W", "isRenewable": true, @@ -2128,7 +2072,7 @@ paths: "toInclusive": "2024-12-31T23:59:59.999", "salesTouchpointId": 3, "forbiddenPaymentMethodIds": [ - 1 + 3 ], "sellingPrices": [ { @@ -2824,10 +2768,10 @@ components: properties: forbiddenPaymentMethodId: type: integer - example: 1 + example: 3 name: type: string - example: Credit Card + example: creditcard issuer: type: string example: American Express From 3ecf55b6ec1e3930ffc4da70776bcc9e851e628f Mon Sep 17 00:00:00 2001 From: Max Martens Date: Sun, 17 Aug 2025 23:30:57 +0200 Subject: [PATCH 4/7] SE and TP OAI now also fixed, including multi-layer example for LayerInfo --- src/openapi/products/SE-products-SE.yaml | 265 ++++++++++------------ src/openapi/products/SE-products-TP.yaml | 267 ++++++++++------------- 2 files changed, 231 insertions(+), 301 deletions(-) diff --git a/src/openapi/products/SE-products-SE.yaml b/src/openapi/products/SE-products-SE.yaml index 943c2ee..eb40747 100644 --- a/src/openapi/products/SE-products-SE.yaml +++ b/src/openapi/products/SE-products-SE.yaml @@ -6,7 +6,7 @@ info: To be used by touchpoints to get information about HTM products they are allowed to see and/or sell. version: "1.0" servers: - - url: https://services.acc.api.htm.nl/abt/touchpoint/1.0 + - url: https://services.acc.api.htm.nl/abt/abtserviceengine/1.0 tags: - name: ServiceEngine Products description: |- @@ -90,7 +90,7 @@ paths: "productDescription": "Reis een dag met het openbaar vervoer bij HTM", "productCategory": { - "productCategoryId": 6, + "productCategoryId": 5, "isTravelProduct": false, "name": "Barcode", }, @@ -123,7 +123,7 @@ paths: "productDescription": "Reis een dag met het openbaar vervoer bij HTM", "productCategory": { - "productCategoryId": 6, + "productCategoryId": 5, "isTravelProduct": false, "name": "Barcode", }, @@ -156,7 +156,7 @@ paths: "productDescription": "Voor een vast bedrag onbeperkt reizen met EBS, HTM en RET in het gekozen gebied in de regio Rotterdam Den Haag.", "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -222,7 +222,7 @@ paths: "productDescription": "Reis een dag met het openbaar vervoer bij HTM", "productCategory": { - "productCategoryId": 6, + "productCategoryId": 5, "isTravelProduct": false, "name": "Barcode", }, @@ -313,6 +313,7 @@ paths: { "productId": 24, "parentProductId": null, + "layerInfo": null, "fikoArticleNumber": "1234", "gboPackageTemplateId": "30901", "tapConnectProductCode": null, @@ -425,6 +426,7 @@ paths: { "productId": 126, "parentProductId": null, + "layerInfo": null, "fikoArticleNumber": "1234", "gboPackageTemplateId": "30001", "tapConnectProductCode": null, @@ -527,6 +529,12 @@ paths: { "productId": 119, "parentProductId": 126, + "layerInfo": { + "layerInfoId": 1, + "choiceKey": "isRenewable", + "choiceLabel": "Kies voor een doorlopend abonnement of een enkele termijn", + "isCustomChoice": false, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "30001", "tapConnectProductCode": null, @@ -641,6 +649,12 @@ paths: { "productId": 120, "parentProductId": 126, + "layerInfo": { + "layerInfoId": 1, + "choiceKey": "isRenewable", + "choiceLabel": "Kies voor een doorlopend abonnement of een enkele termijn", + "isCustomChoice": false, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "30001", "tapConnectProductCode": null, @@ -765,6 +779,7 @@ paths: { "productId": 49, "parentProductId": null, + "layerInfo": null, "fikoArticleNumber": "1234", "gboPackageTemplateId": null, "tapConnectProductCode": null, @@ -794,12 +809,6 @@ paths: "customerSegments": [], "allowedGboAgeProfiles": [ - { - "gboAgeProfileId": 1, - "name": "Baby/peuter (0 t/m 3 jaar)", - "ageFromInclusive": 0, - "ageToInclusive": 3, - }, { "gboAgeProfileId": 2, "name": "Kind (4 t/m 11 jaar)", @@ -827,7 +836,7 @@ paths: ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -837,26 +846,10 @@ paths: "incompatibleProducts": [], "mandatoryCustomerDataItems": [ - { - "mandatoryCustomerDataItemId": 1, - "customerDataItem": "birthname", - }, - { - "mandatoryCustomerDataItemId": 2, - "customerDataItem": "surname", - }, - { - "mandatoryCustomerDataItemId": 3, - "customerDataItem": "dateOfBirth", - }, { "mandatoryCustomerDataItemId": 4, "customerDataItem": "emailAddress", }, - { - "mandatoryCustomerDataItemId": 7, - "customerDataItem": "ovPayToken", - }, { "mandatoryCustomerDataItemId": 8, "customerDataItem": "padBirthDate", @@ -928,6 +921,12 @@ paths: { "productId": 109, "parentProductId": 49, + "layerInfo": { + "layerInfoId": 2, + "choiceKey": "regio", + "choiceLabel": "Kies de gewenste regio", + "isCustomChoice": true, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "33615", "tapConnectProductCode": null, @@ -957,12 +956,6 @@ paths: "customerSegments": [], "allowedGboAgeProfiles": [ - { - "gboAgeProfileId": 1, - "name": "Baby/peuter (0 t/m 3 jaar)", - "ageFromInclusive": 0, - "ageToInclusive": 3, - }, { "gboAgeProfileId": 2, "name": "Kind (4 t/m 11 jaar)", @@ -990,7 +983,7 @@ paths: ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -1003,26 +996,10 @@ paths: "incompatibleProducts": [], "mandatoryCustomerDataItems": [ - { - "mandatoryCustomerDataItemId": 1, - "customerDataItem": "birthname", - }, - { - "mandatoryCustomerDataItemId": 2, - "customerDataItem": "surname", - }, - { - "mandatoryCustomerDataItemId": 3, - "customerDataItem": "dateOfBirth", - }, { "mandatoryCustomerDataItemId": 4, "customerDataItem": "emailAddress", }, - { - "mandatoryCustomerDataItemId": 7, - "customerDataItem": "ovPayToken", - }, { "mandatoryCustomerDataItemId": 8, "customerDataItem": "padBirthDate", @@ -1094,6 +1071,12 @@ paths: { "productId": 114, "parentProductId": 109, + "layerInfo": { + "layerInfoId": 3, + "choiceKey": "allowedGboAgeProfiles", + "choiceLabel": "Wat is uw geboortedatum?", + "isCustomChoice": false, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "33615", "tapConnectProductCode": null, @@ -1123,12 +1106,6 @@ paths: "customerSegments": [], "allowedGboAgeProfiles": [ - { - "gboAgeProfileId": 1, - "name": "Baby/peuter (0 t/m 3 jaar)", - "ageFromInclusive": 0, - "ageToInclusive": 3, - }, { "gboAgeProfileId": 4, "name": "Volwassene (19 t/m 64 jaar)", @@ -1144,7 +1121,7 @@ paths: ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -1156,27 +1133,11 @@ paths: "requiredProducts": [], "incompatibleProducts": [], "mandatoryCustomerDataItems": - [ - { - "mandatoryCustomerDataItemId": 1, - "customerDataItem": "birthname", - }, - { - "mandatoryCustomerDataItemId": 2, - "customerDataItem": "surname", - }, - { - "mandatoryCustomerDataItemId": 3, - "customerDataItem": "dateOfBirth", - }, + [ { "mandatoryCustomerDataItemId": 4, "customerDataItem": "emailAddress", }, - { - "mandatoryCustomerDataItemId": 7, - "customerDataItem": "ovPayToken", - }, { "mandatoryCustomerDataItemId": 8, "customerDataItem": "padBirthDate", @@ -1260,6 +1221,12 @@ paths: { "productId": 115, "parentProductId": 109, + "layerInfo": { + "layerInfoId": 3, + "choiceKey": "allowedGboAgeProfiles", + "choiceLabel": "Wat is uw geboortedatum?", + "isCustomChoice": false, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "33615", "tapConnectProductCode": null, @@ -1304,7 +1271,7 @@ paths: ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -1316,27 +1283,11 @@ paths: "requiredProducts": [], "incompatibleProducts": [], "mandatoryCustomerDataItems": - [ - { - "mandatoryCustomerDataItemId": 1, - "customerDataItem": "birthname", - }, - { - "mandatoryCustomerDataItemId": 2, - "customerDataItem": "surname", - }, - { - "mandatoryCustomerDataItemId": 3, - "customerDataItem": "dateOfBirth", - }, + [ { "mandatoryCustomerDataItemId": 4, "customerDataItem": "emailAddress", }, - { - "mandatoryCustomerDataItemId": 7, - "customerDataItem": "ovPayToken", - }, { "mandatoryCustomerDataItemId": 8, "customerDataItem": "padBirthDate", @@ -1421,6 +1372,12 @@ paths: { "productId": 116, "parentProductId": 115, + "layerInfo": { + "layerInfoId": 1, + "choiceKey": "isRenewable", + "choiceLabel": "Kies voor een doorlopend abonnement of een enkele termijn", + "isCustomChoice": false, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "33615", "tapConnectProductCode": null, @@ -1465,7 +1422,7 @@ paths: ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -1478,26 +1435,10 @@ paths: "incompatibleProducts": [], "mandatoryCustomerDataItems": [ - { - "mandatoryCustomerDataItemId": 1, - "customerDataItem": "birthname", - }, - { - "mandatoryCustomerDataItemId": 2, - "customerDataItem": "surname", - }, - { - "mandatoryCustomerDataItemId": 3, - "customerDataItem": "dateOfBirth", - }, { "mandatoryCustomerDataItemId": 4, "customerDataItem": "emailAddress", }, - { - "mandatoryCustomerDataItemId": 7, - "customerDataItem": "ovPayToken", - }, { "mandatoryCustomerDataItemId": 8, "customerDataItem": "padBirthDate", @@ -1585,6 +1526,12 @@ paths: { "productId": 117, "parentProductId": 115, + "layerInfo": { + "layerInfoId": 1, + "choiceKey": "isRenewable", + "choiceLabel": "Kies voor een doorlopend abonnement of een enkele termijn", + "isCustomChoice": false, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "33615", "tapConnectProductCode": null, @@ -1629,7 +1576,7 @@ paths: ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -1642,26 +1589,10 @@ paths: "incompatibleProducts": [], "mandatoryCustomerDataItems": [ - { - "mandatoryCustomerDataItemId": 1, - "customerDataItem": "birthname", - }, - { - "mandatoryCustomerDataItemId": 2, - "customerDataItem": "surname", - }, - { - "mandatoryCustomerDataItemId": 3, - "customerDataItem": "dateOfBirth", - }, { "mandatoryCustomerDataItemId": 4, "customerDataItem": "emailAddress", }, - { - "mandatoryCustomerDataItemId": 7, - "customerDataItem": "ovPayToken", - }, { "mandatoryCustomerDataItemId": 8, "customerDataItem": "padBirthDate", @@ -1753,6 +1684,12 @@ paths: { "productId": 112, "parentProductId": 49, + "layerInfo": { + "layerInfoId": 2, + "choiceKey": "regio", + "choiceLabel": "Kies de gewenste regio", + "isCustomChoice": true, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "33618", "tapConnectProductCode": null, @@ -1782,12 +1719,6 @@ paths: "customerSegments": [], "allowedGboAgeProfiles": [ - { - "gboAgeProfileId": 1, - "name": "Baby/peuter (0 t/m 3 jaar)", - "ageFromInclusive": 0, - "ageToInclusive": 3, - }, { "gboAgeProfileId": 2, "name": "Kind (4 t/m 11 jaar)", @@ -1815,7 +1746,7 @@ paths: ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -1828,26 +1759,11 @@ paths: "incompatibleProducts": [], "mandatoryCustomerDataItems": [ - { - "mandatoryCustomerDataItemId": 1, - "customerDataItem": "birthname", - }, - { - "mandatoryCustomerDataItemId": 2, - "customerDataItem": "surname", - }, - { - "mandatoryCustomerDataItemId": 3, - "customerDataItem": "dateOfBirth", - }, + { "mandatoryCustomerDataItemId": 4, "customerDataItem": "emailAddress", }, - { - "mandatoryCustomerDataItemId": 7, - "customerDataItem": "ovPayToken", - }, { "mandatoryCustomerDataItemId": 8, "customerDataItem": "padBirthDate", @@ -1937,6 +1853,53 @@ paths: } components: schemas: + LayerInfoResponse: + type: object + description: >- + Gives information on the choice that the customer has to make, to enable the touchpoint + to proceed further "down the product-tree" by selecting (PATCH-ing) the correct product-variant. + LayerInfo is not a mandatory product-attribute, but it should always be present on all product for which + `parentProductId != null`. (LayerInfo makes no sense for top-level parents as there is always a single starting point). \ + + **PMT should ensure that all products in the same "product-branch" (same `parentProductId`) have the same `layerInfoId` + referenced. If a product is found to be in violation of this rule, its attribtue `isValid` should be set to `false`.** + required: + - layerInfoId + - choiceKey + - choiceLabel + - isCustomChoice + properties: + layerInfoId: + example: 1 + type: integer + choiceKey: + example: isRenewable + type: string + description: >- + Contains the JSON Key of the product-attribute that the customer has to make some + choice on (determined by PMT), so that te correct product-variant can be selected by the touchpoint. For some + decisions (like region), there is no product attribute, and thus `isCustomChoice` will be set + to `true`, and `choiceKey` can then be set to any string on which touchpoints can also trigger + behaviour if desired (think "region picker tool"). Therefore, reuse of choiceKeys should be + the goal, so touchoints can keep their triggers simple and prevent duplication of + similar choiceKeys to trigger the same behaviour. + choiceLabel: + example: Kies voor een doorlopend abonnement of een enkele termijn + type: string + description: >- + Contains a human-readable label for the choice that the customer has to make - this label + should be something that is easy to understand for the customer. Only one label (and thus, one language) + is supported; label translations should be handled by the touchpoint. + isCustomChoice: + example: false + type: boolean + description: >- + Indicates if the choice is a custom choice. If `false`, the PMT should fill `choiceKey` with the + "differing attribute for this product-layer" and the user should not be able to override this. When + no single attribute can be pinpointed by PMT, the product will become invalid (`isValid == false`) until either + a situation with a single differing attribute is created, or if `isCustomChoice` is set to `true` - this would, + however, also mean that touchpoints should be notified of this, especially if the configured LayerInfo contains + a new, not previously used, `choiceKey`. GboAgeProfileResponse: type: object required: @@ -2199,6 +2162,8 @@ components: parentProductId: type: integer example: 1 + layerInfo: + $ref: '#/components/schemas/LayerInfoResponse' fikoArticleNumber: type: string description: The article number of the product in FIKO diff --git a/src/openapi/products/SE-products-TP.yaml b/src/openapi/products/SE-products-TP.yaml index a8bf64b..7be3d25 100644 --- a/src/openapi/products/SE-products-TP.yaml +++ b/src/openapi/products/SE-products-TP.yaml @@ -90,7 +90,7 @@ paths: "productDescription": "Reis een dag met het openbaar vervoer bij HTM", "productCategory": { - "productCategoryId": 6, + "productCategoryId": 5, "isTravelProduct": false, "name": "Barcode", }, @@ -123,7 +123,7 @@ paths: "productDescription": "Reis een dag met het openbaar vervoer bij HTM", "productCategory": { - "productCategoryId": 6, + "productCategoryId": 5, "isTravelProduct": false, "name": "Barcode", }, @@ -156,7 +156,7 @@ paths: "productDescription": "Voor een vast bedrag onbeperkt reizen met EBS, HTM en RET in het gekozen gebied in de regio Rotterdam Den Haag.", "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -222,7 +222,7 @@ paths: "productDescription": "Reis een dag met het openbaar vervoer bij HTM", "productCategory": { - "productCategoryId": 6, + "productCategoryId": 5, "isTravelProduct": false, "name": "Barcode", }, @@ -313,6 +313,7 @@ paths: { "productId": 24, "parentProductId": null, + "layerInfo": null, "fikoArticleNumber": "1234", "gboPackageTemplateId": "30901", "tapConnectProductCode": null, @@ -425,6 +426,7 @@ paths: { "productId": 126, "parentProductId": null, + "layerInfo": null, "fikoArticleNumber": "1234", "gboPackageTemplateId": "30001", "tapConnectProductCode": null, @@ -527,6 +529,12 @@ paths: { "productId": 119, "parentProductId": 126, + "layerInfo": { + "layerInfoId": 1, + "choiceKey": "isRenewable", + "choiceLabel": "Kies voor een doorlopend abonnement of een enkele termijn", + "isCustomChoice": false, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "30001", "tapConnectProductCode": null, @@ -641,6 +649,12 @@ paths: { "productId": 120, "parentProductId": 126, + "layerInfo": { + "layerInfoId": 1, + "choiceKey": "isRenewable", + "choiceLabel": "Kies voor een doorlopend abonnement of een enkele termijn", + "isCustomChoice": false, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "30001", "tapConnectProductCode": null, @@ -765,6 +779,7 @@ paths: { "productId": 49, "parentProductId": null, + "layerInfo": null, "fikoArticleNumber": "1234", "gboPackageTemplateId": null, "tapConnectProductCode": null, @@ -794,12 +809,6 @@ paths: "customerSegments": [], "allowedGboAgeProfiles": [ - { - "gboAgeProfileId": 1, - "name": "Baby/peuter (0 t/m 3 jaar)", - "ageFromInclusive": 0, - "ageToInclusive": 3, - }, { "gboAgeProfileId": 2, "name": "Kind (4 t/m 11 jaar)", @@ -827,7 +836,7 @@ paths: ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -837,26 +846,10 @@ paths: "incompatibleProducts": [], "mandatoryCustomerDataItems": [ - { - "mandatoryCustomerDataItemId": 1, - "customerDataItem": "birthname", - }, - { - "mandatoryCustomerDataItemId": 2, - "customerDataItem": "surname", - }, - { - "mandatoryCustomerDataItemId": 3, - "customerDataItem": "dateOfBirth", - }, { "mandatoryCustomerDataItemId": 4, "customerDataItem": "emailAddress", }, - { - "mandatoryCustomerDataItemId": 7, - "customerDataItem": "ovPayToken", - }, { "mandatoryCustomerDataItemId": 8, "customerDataItem": "padBirthDate", @@ -928,6 +921,12 @@ paths: { "productId": 109, "parentProductId": 49, + "layerInfo": { + "layerInfoId": 2, + "choiceKey": "regio", + "choiceLabel": "Kies de gewenste regio", + "isCustomChoice": true, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "33615", "tapConnectProductCode": null, @@ -957,12 +956,6 @@ paths: "customerSegments": [], "allowedGboAgeProfiles": [ - { - "gboAgeProfileId": 1, - "name": "Baby/peuter (0 t/m 3 jaar)", - "ageFromInclusive": 0, - "ageToInclusive": 3, - }, { "gboAgeProfileId": 2, "name": "Kind (4 t/m 11 jaar)", @@ -990,7 +983,7 @@ paths: ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -1003,26 +996,10 @@ paths: "incompatibleProducts": [], "mandatoryCustomerDataItems": [ - { - "mandatoryCustomerDataItemId": 1, - "customerDataItem": "birthname", - }, - { - "mandatoryCustomerDataItemId": 2, - "customerDataItem": "surname", - }, - { - "mandatoryCustomerDataItemId": 3, - "customerDataItem": "dateOfBirth", - }, { "mandatoryCustomerDataItemId": 4, "customerDataItem": "emailAddress", }, - { - "mandatoryCustomerDataItemId": 7, - "customerDataItem": "ovPayToken", - }, { "mandatoryCustomerDataItemId": 8, "customerDataItem": "padBirthDate", @@ -1094,6 +1071,12 @@ paths: { "productId": 114, "parentProductId": 109, + "layerInfo": { + "layerInfoId": 3, + "choiceKey": "allowedGboAgeProfiles", + "choiceLabel": "Wat is uw geboortedatum?", + "isCustomChoice": false, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "33615", "tapConnectProductCode": null, @@ -1123,12 +1106,6 @@ paths: "customerSegments": [], "allowedGboAgeProfiles": [ - { - "gboAgeProfileId": 1, - "name": "Baby/peuter (0 t/m 3 jaar)", - "ageFromInclusive": 0, - "ageToInclusive": 3, - }, { "gboAgeProfileId": 4, "name": "Volwassene (19 t/m 64 jaar)", @@ -1144,7 +1121,7 @@ paths: ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -1156,27 +1133,11 @@ paths: "requiredProducts": [], "incompatibleProducts": [], "mandatoryCustomerDataItems": - [ - { - "mandatoryCustomerDataItemId": 1, - "customerDataItem": "birthname", - }, - { - "mandatoryCustomerDataItemId": 2, - "customerDataItem": "surname", - }, - { - "mandatoryCustomerDataItemId": 3, - "customerDataItem": "dateOfBirth", - }, + [ { "mandatoryCustomerDataItemId": 4, "customerDataItem": "emailAddress", }, - { - "mandatoryCustomerDataItemId": 7, - "customerDataItem": "ovPayToken", - }, { "mandatoryCustomerDataItemId": 8, "customerDataItem": "padBirthDate", @@ -1260,6 +1221,12 @@ paths: { "productId": 115, "parentProductId": 109, + "layerInfo": { + "layerInfoId": 3, + "choiceKey": "allowedGboAgeProfiles", + "choiceLabel": "Wat is uw geboortedatum?", + "isCustomChoice": false, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "33615", "tapConnectProductCode": null, @@ -1304,7 +1271,7 @@ paths: ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -1316,27 +1283,11 @@ paths: "requiredProducts": [], "incompatibleProducts": [], "mandatoryCustomerDataItems": - [ - { - "mandatoryCustomerDataItemId": 1, - "customerDataItem": "birthname", - }, - { - "mandatoryCustomerDataItemId": 2, - "customerDataItem": "surname", - }, - { - "mandatoryCustomerDataItemId": 3, - "customerDataItem": "dateOfBirth", - }, + [ { "mandatoryCustomerDataItemId": 4, "customerDataItem": "emailAddress", }, - { - "mandatoryCustomerDataItemId": 7, - "customerDataItem": "ovPayToken", - }, { "mandatoryCustomerDataItemId": 8, "customerDataItem": "padBirthDate", @@ -1421,6 +1372,12 @@ paths: { "productId": 116, "parentProductId": 115, + "layerInfo": { + "layerInfoId": 1, + "choiceKey": "isRenewable", + "choiceLabel": "Kies voor een doorlopend abonnement of een enkele termijn", + "isCustomChoice": false, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "33615", "tapConnectProductCode": null, @@ -1465,7 +1422,7 @@ paths: ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -1478,26 +1435,10 @@ paths: "incompatibleProducts": [], "mandatoryCustomerDataItems": [ - { - "mandatoryCustomerDataItemId": 1, - "customerDataItem": "birthname", - }, - { - "mandatoryCustomerDataItemId": 2, - "customerDataItem": "surname", - }, - { - "mandatoryCustomerDataItemId": 3, - "customerDataItem": "dateOfBirth", - }, { "mandatoryCustomerDataItemId": 4, "customerDataItem": "emailAddress", }, - { - "mandatoryCustomerDataItemId": 7, - "customerDataItem": "ovPayToken", - }, { "mandatoryCustomerDataItemId": 8, "customerDataItem": "padBirthDate", @@ -1585,6 +1526,12 @@ paths: { "productId": 117, "parentProductId": 115, + "layerInfo": { + "layerInfoId": 1, + "choiceKey": "isRenewable", + "choiceLabel": "Kies voor een doorlopend abonnement of een enkele termijn", + "isCustomChoice": false, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "33615", "tapConnectProductCode": null, @@ -1629,7 +1576,7 @@ paths: ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -1642,26 +1589,10 @@ paths: "incompatibleProducts": [], "mandatoryCustomerDataItems": [ - { - "mandatoryCustomerDataItemId": 1, - "customerDataItem": "birthname", - }, - { - "mandatoryCustomerDataItemId": 2, - "customerDataItem": "surname", - }, - { - "mandatoryCustomerDataItemId": 3, - "customerDataItem": "dateOfBirth", - }, { "mandatoryCustomerDataItemId": 4, "customerDataItem": "emailAddress", }, - { - "mandatoryCustomerDataItemId": 7, - "customerDataItem": "ovPayToken", - }, { "mandatoryCustomerDataItemId": 8, "customerDataItem": "padBirthDate", @@ -1723,7 +1654,7 @@ paths: "country": "Nederland", "emailAddress": "info@htm.nl", "phoneNumber": "070 374 9002", - "taxId": "572309345923", + "taxId": 572309345923, "imageReference": "https://www.htm.nl/media/leif2leu/htm-logo-mobile.svg", }, }, @@ -1753,6 +1684,12 @@ paths: { "productId": 112, "parentProductId": 49, + "layerInfo": { + "layerInfoId": 2, + "choiceKey": "regio", + "choiceLabel": "Kies de gewenste regio", + "isCustomChoice": true, + }, "fikoArticleNumber": "1234", "gboPackageTemplateId": "33618", "tapConnectProductCode": null, @@ -1782,12 +1719,6 @@ paths: "customerSegments": [], "allowedGboAgeProfiles": [ - { - "gboAgeProfileId": 1, - "name": "Baby/peuter (0 t/m 3 jaar)", - "ageFromInclusive": 0, - "ageToInclusive": 3, - }, { "gboAgeProfileId": 2, "name": "Kind (4 t/m 11 jaar)", @@ -1815,7 +1746,7 @@ paths: ], "productCategory": { - "productCategoryId": 3, + "productCategoryId": 2, "isTravelProduct": true, "name": "Afgekocht reisrecht", }, @@ -1828,26 +1759,11 @@ paths: "incompatibleProducts": [], "mandatoryCustomerDataItems": [ - { - "mandatoryCustomerDataItemId": 1, - "customerDataItem": "birthname", - }, - { - "mandatoryCustomerDataItemId": 2, - "customerDataItem": "surname", - }, - { - "mandatoryCustomerDataItemId": 3, - "customerDataItem": "dateOfBirth", - }, + { "mandatoryCustomerDataItemId": 4, "customerDataItem": "emailAddress", }, - { - "mandatoryCustomerDataItemId": 7, - "customerDataItem": "ovPayToken", - }, { "mandatoryCustomerDataItemId": 8, "customerDataItem": "padBirthDate", @@ -1905,7 +1821,7 @@ paths: "country": "Nederland", "emailAddress": "info@htm.nl", "phoneNumber": "070 374 9002", - "taxId": "572309345923", + "taxId": 572309345923, "imageReference": "https://www.htm.nl/media/leif2leu/htm-logo-mobile.svg", }, }, @@ -1937,6 +1853,53 @@ paths: } components: schemas: + LayerInfoResponse: + type: object + description: >- + Gives information on the choice that the customer has to make, to enable the touchpoint + to proceed further "down the product-tree" by selecting (PATCH-ing) the correct product-variant. + LayerInfo is not a mandatory product-attribute, but it should always be present on all product for which + `parentProductId != null`. (LayerInfo makes no sense for top-level parents as there is always a single starting point). \ + + **PMT should ensure that all products in the same "product-branch" (same `parentProductId`) have the same `layerInfoId` + referenced. If a product is found to be in violation of this rule, its attribtue `isValid` should be set to `false`.** + required: + - layerInfoId + - choiceKey + - choiceLabel + - isCustomChoice + properties: + layerInfoId: + example: 1 + type: integer + choiceKey: + example: isRenewable + type: string + description: >- + Contains the JSON Key of the product-attribute that the customer has to make some + choice on (determined by PMT), so that te correct product-variant can be selected by the touchpoint. For some + decisions (like region), there is no product attribute, and thus `isCustomChoice` will be set + to `true`, and `choiceKey` can then be set to any string on which touchpoints can also trigger + behaviour if desired (think "region picker tool"). Therefore, reuse of choiceKeys should be + the goal, so touchoints can keep their triggers simple and prevent duplication of + similar choiceKeys to trigger the same behaviour. + choiceLabel: + example: Kies voor een doorlopend abonnement of een enkele termijn + type: string + description: >- + Contains a human-readable label for the choice that the customer has to make - this label + should be something that is easy to understand for the customer. Only one label (and thus, one language) + is supported; label translations should be handled by the touchpoint. + isCustomChoice: + example: false + type: boolean + description: >- + Indicates if the choice is a custom choice. If `false`, the PMT should fill `choiceKey` with the + "differing attribute for this product-layer" and the user should not be able to override this. When + no single attribute can be pinpointed by PMT, the product will become invalid (`isValid == false`) until either + a situation with a single differing attribute is created, or if `isCustomChoice` is set to `true` - this would, + however, also mean that touchpoints should be notified of this, especially if the configured LayerInfo contains + a new, not previously used, `choiceKey`. GboAgeProfileResponse: type: object required: @@ -2199,6 +2162,8 @@ components: parentProductId: type: integer example: 1 + layerInfo: + $ref: '#/components/schemas/LayerInfoResponse' fikoArticleNumber: type: string description: The article number of the product in FIKO From 227fa07da03ba5e8598e0e17de8e4f52da50f05e Mon Sep 17 00:00:00 2001 From: Max Martens Date: Thu, 28 Aug 2025 10:36:22 +0200 Subject: [PATCH 5/7] Added CRUD POST/PUT examples with layerInfo --- src/openapi/products/products-crud.yaml | 178 ++++++++++++++++++++++++ 1 file changed, 178 insertions(+) diff --git a/src/openapi/products/products-crud.yaml b/src/openapi/products/products-crud.yaml index b236c3a..dd73366 100644 --- a/src/openapi/products/products-crud.yaml +++ b/src/openapi/products/products-crud.yaml @@ -457,6 +457,93 @@ paths: } ] } + postGboProductWithParent: + summary: Add new GBO product with parent and layerInfo (non-renewable) + value: + { + "parentProductId": 1, + "layerInfoId": 1, + "fikoArticleNumber": "1234", + "isValid": true, + "isArchived": false, + "gboPackageTemplateId": "30901", + "productName": "HTM pilot 90% korting", + "productDescription": "Reis met 90% korting gedurende de eerste F&F pilot!", + "validityPeriod": { + "fromInclusive": "2024-09-01T00:00:00.000", + "toInclusive": "2024-12-31T23:59:59.999" + }, + "productTranslations": [ + { + "language": "en", + "name": "HTM pilot 90% discount", + "description": "Travel with 90% discount during the first F&F pilot!" + } + ], + "productOwnerId": 1, + "marketSegmentIds": [ + 1 + ], + "customerSegmentIds": [ + 5, + 6 + ], + "allowedGboAgeProfileIds": [], + "productCategoryId": 1, + "requiredCustomerLevelId": 1, + "incompatibleProducts": [ + { + "incompatibleProductId": 2, + "description": "Kan niet combineren met zichzelf" + } + ], + "mandatoryCustomerDataItemIds": [ + 4, + 7 + ], + "tokenTypeIds": [ + 1 + ], + "paymentMomentId": 1, + "validityDuration": "P7D", + "maxStartInFutureDuration": "P6W", + "isRenewable": false, + "sendInvoice": false, + "imageReference": "https://www.htm.nl/media/leif2leu/htm-logo-mobile.svg", + "productPageUrl": "https://www.htm.nl/nog-onbekende-product-pagina", + "termsUrl": "https://www.htm.nl/nog-onbekende-productvoorwaarden-pagina", + "isSellableAtHtm": true, + "needsSolvencyCheckConsumer": false, + "needsSolvencyCheckBusiness": false, + "sellingPeriods": [ + { + "fromInclusive": "2024-09-01T00:00:00.000", + "toInclusive": "2024-12-31T23:59:59.999", + "salesTouchpointId": 3, + "sellingPrices": [ + { + "amountExclTax": 92, + "amountInclTax": 100, + "taxCode": "V09", + "taxPercentage": 9.0000, + "fromInclusive": "2024-09-01T00:00:00.000", + "toInclusive": "2024-12-31T23:59:59.999", + "internalPrice": 92.0000 + } + ] + } + ], + "purchasePrices": [ + { + "amountExclTax": 0, + "amountInclTax": 0, + "taxCode": "V09", + "taxPercentage": 9.0000, + "fromInclusive": "2024-09-01T00:00:00.000", + "toInclusive": "2024-12-31T23:59:59.999" + } + ] + } postGboProductMultiplePeriods: summary: >- Add new GBO product (non-renewable, multiple sellingPeriods/prices per period) @@ -1748,6 +1835,97 @@ paths: } ] } + updateGboProductWithParent: + summary: Update existing GBO product with parent and layerInfo (non-renewable) + value: + { + "parentProductId": 1, + "layerInfoId": 1, + "fikoArticleNumber": "1234", + "isValid": true, + "isArchived": false, + "gboPackageTemplateId": "30901", + "productName": "HTM pilot 90% korting", + "productDescription": "Reis met 90% korting gedurende de eerste F&F pilot!", + "validityPeriod": { + "validityPeriodId": 1, + "fromInclusive": "2024-09-01T00:00:00.000", + "toInclusive": "2024-12-31T23:59:59.999" + }, + "productTranslations": [ + { + "language": "en", + "name": "HTM pilot 90% discount", + "description": "Travel with 90% discount during the first F&F pilot!" + } + ], + "productOwnerId": 1, + "marketSegmentIds": [ + 1 + ], + "customerSegmentIds": [ + 5, + 6 + ], + "allowedGboAgeProfileIds": [], + "productCategoryId": 1, + "requiredCustomerLevelId": 1, + "incompatibleProducts": [ + { + "incompatibleProductId": 2, + "description": "Kan niet combineren met zichzelf" + } + ], + "mandatoryCustomerDataItemIds": [ + 4, + 7 + ], + "tokenTypeIds": [ + 1 + ], + "paymentMomentId": 1, + "validityDuration": "P7D", + "maxStartInFutureDuration": "P6W", + "isRenewable": false, + "sendInvoice": false, + "imageReference": "https://www.htm.nl/media/leif2leu/htm-logo-mobile.svg", + "productPageUrl": "https://www.htm.nl/nog-onbekende-product-pagina", + "termsUrl": "https://www.htm.nl/nog-onbekende-productvoorwaarden-pagina", + "isSellableAtHtm": true, + "needsSolvencyCheckConsumer": false, + "needsSolvencyCheckBusiness": false, + "sellingPeriods": [ + { + "sellingPeriodId": 1, + "fromInclusive": "2024-09-01T00:00:00.000", + "toInclusive": "2024-12-31T23:59:59.999", + "salesTouchpointId": 3, + "sellingPrices": [ + { + "sellingPriceId": 1, + "amountExclTax": 92, + "amountInclTax": 100, + "taxCode": "V09", + "taxPercentage": 9.0000, + "fromInclusive": "2024-09-01T00:00:00.000", + "toInclusive": "2024-12-31T23:59:59.999", + "internalPrice": 92.0000 + } + ] + } + ], + "purchasePrices": [ + { + "purchasePriceId": 1, + "amountExclTax": 0, + "amountInclTax": 0, + "taxCode": "V09", + "taxPercentage": 9.0000, + "fromInclusive": "2024-09-01T00:00:00.000", + "toInclusive": "2024-12-31T23:59:59.999" + } + ] + } advancedUpdateGboProduct: summary: >- Advanced update (remove mandatoryCustomerDataItem references, add new second sellingPeriod) From d9d82eae6618dccfbe11c1083855ae4db0f8f621 Mon Sep 17 00:00:00 2001 From: Max Martens Date: Thu, 28 Aug 2025 11:22:04 +0200 Subject: [PATCH 6/7] fixxxxxxxxxxxxx --- src/openapi/products/productreference-crud.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/openapi/products/productreference-crud.yaml b/src/openapi/products/productreference-crud.yaml index b96bd70..545929f 100644 --- a/src/openapi/products/productreference-crud.yaml +++ b/src/openapi/products/productreference-crud.yaml @@ -278,7 +278,7 @@ paths: schema: $ref: '#/components/schemas/500Response' description: Internal Server Error - summary: Create a client attribute. + summary: Create a new LayerInfo entry. tags: - ABTProductReference CRUD /layerInfo/{layerInfoId}: From 0515529551302d8ecad21fd57a53759735045080 Mon Sep 17 00:00:00 2001 From: Max Martens Date: Thu, 28 Aug 2025 11:24:22 +0200 Subject: [PATCH 7/7] fixxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx --- src/openapi/products/productreference-crud.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/openapi/products/productreference-crud.yaml b/src/openapi/products/productreference-crud.yaml index 545929f..48948f7 100644 --- a/src/openapi/products/productreference-crud.yaml +++ b/src/openapi/products/productreference-crud.yaml @@ -460,7 +460,7 @@ paths: schema: $ref: '#/components/schemas/500Response' description: Internal Server Error - summary: Create a productowners. + summary: Create a new productowner. tags: - ABTProductReference CRUD /productowners/{productOwnerId}: