Untitled
unknown
plain_text
2 years ago
10 kB
8
Indexable
{
"openapi": "3.0.1",
"info": {
"title": "HOBS Analytics API's",
"description": "Analytics API Operations ",
"termsOfService": "",
"contact": {
"name": "TCS HOBS Analytics",
"url": "https://www.tcs.com/hobs",
"email": "abc@abc.com"
},
"license": {
"name": "TCS HOBS License",
"url": "https://www.tcs.com/hobs"
},
"version": "8.1.6"
},
"servers": [
{
"url": "172.16.177.58"
},
{
"url": "10.16.16.89"
}
],
"paths": {
"/loyaltyManagement/loyaltyProgramProductSpec": {
"get": {
"description": "This operation is used to retrieve the loyalty program product specifications. A loyalty program product specification contains loyalty rules.",
"tags": [
"Loyalty Program Product Spec"
],
"operationId": "List Product Specs",
"produces": [
"application/json"
],
"parameters": [],
"responses": {
"200": {
"description": "Success",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"$ref": "#/components/schemas/ProgramProductSpec"
}
}
}
}
}
},
"security": [],
"x-unitTests": [
{
"request": {
"method": "GET",
"uri": "/loyaltyProgramProductSpec"
},
"expectedResponse": {
"x-allowExtraHeaders": true,
"x-bodyMatchMode": "NONE",
"x-arrayOrderedMatching": false,
"x-arrayCheckCount": false,
"x-matchResponseSchema": true,
"headers": {}
},
"x-testShouldPass": true,
"x-testEnabled": true,
"x-testName": "List Product Specs",
"x-testDescription": ""
}
],
"x-operation-settings": {
"CollectParameters": false,
"AllowDynamicQueryParameters": false,
"AllowDynamicFormParameters": false,
"IsMultiContentStreaming": false
}
},
"post": {
"description": "This operation is used to create a new loyalty program product specification.",
"tags": [
"Loyalty Program Product Spec"
],
"operationId": "Create Product Spec",
"produces": [
"application/json"
],
"requestBody": {
"description": "Product specification to be created",
"required": true,
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ProgramProductSpec"
}
}
}
},
"responses": {
"201": {
"description": "Created",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"$ref": "#/components/schemas/ProgramProductSpec"
}
}
}
}
},
"409": {
"description": "Conflict - Resource already exists.",
"content": {
"application/json": {
```json
"schema": {
"$ref": "#/components/schemas/Error"
}
}
}
},
"422": {
"description": "Unprocessable Entity - Field rule violation or missing required attribute.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/Error"
}
}
}
}
},
"security": [],
"x-unitTests": [
{
"request": {
"method": "POST",
"uri": "/loyaltyProgramProductSpec",
"headers": {
"Content-Type": "application/json"
},
"body": "{\r\n \"id\" : \"121\",\r\n \"name\":\"UpComingProfessionalsProgram\",\r\n \"productNumber\":\"121\",\r\n \"description\": \"Loyalty Program to ensure that prepaid youth market is retained\",\r\n \"needsLoyaltyAccount\": true,\r\n \"lifeCycleStatus\": \"active\",\r\n \"brand\" : \"Globetom\",\r\n \"validFor\" : {\r\n \"startDateTime\" : \"2016-01-01T00:00:00Z\",\r\n \"endDateTime\" : \"2016-12-31T23:59:59Z\"\r\n }\r\n}"
},
"expectedResponse": {
"x-allowExtraHeaders": true,
"x-bodyMatchMode": "NONE",
"x-arrayOrderedMatching": false,
"x-arrayCheckCount": false,
"x-matchResponseSchema": true,
"headers": {}
},
"x-testShouldPass": true,
"x-testEnabled": true,
"x-testName": "Create Product Spec",
"x-testDescription": ""
}
],
"x-operation-settings": {
"CollectParameters": false,
"AllowDynamicQueryParameters": false,
"AllowDynamicFormParameters": false,
"IsMultiContentStreaming": false
}
}
},
"/cartDetails": {
"get": {
"summary": "Get cart details",
"parameters": [
{
"name": "businessid",
"in": "query",
"description": "Filter by business ID",
"schema": {
"type": "string"
}
},
{
"name": "createdtime",
"in": "query",
"description": "Filter by created time (yyyy-mm-dd)",
"schema": {
"type": "string",
"format": "date"
}
},
{
"name": "username",
"in": "query",
"description": "Filter by username(s)",
"schema": {
"type": "array",
"items": {
"type": "string"
}
}
},
{
"name": "startDate",
"in": "query",
"description": "Filter by start date (yyyy-mm-dd)",
"schema": {
"type": "string",
"format": "date"
}
},
{
"name": "endDate",
"in": "query",
"description": "Filter by end date (yyyy-mm-dd)",
"schema": {
"type": "string",
"format": "date"
}
},
{
"name": "status",
"in": "query",
"description": "Filter by status",
"schema": {
"type": "string"
}
},
Continued...
```json
{
"name": "page",
"in": "query",
"description": "Page number for pagination",
"schema": {
"type": "integer",
"format": "int32",
"default": 1
}
},
{
"name": "limit",
"in": "query",
"description": "Number of items per page",
"schema": {
"type": "integer",
"format": "int32",
"default": 20
}
}
],
"responses": {
"200": {
"description": "Successful response",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"type": "object",
"properties": {
"businessid": {
"type": "string"
},
"valuetype": {
"type": "string"
},
"key": {
"type": "string"
},
"buid": {
"type": "string"
},
"createdtime": {
"type": "string",
"format": "date-time"
},
"opid": {
"type": "string"
},
"status": {
"type": "string"
},
"updatedtime": {
"type": "string",
"format": "date-time"
},
"username": {
"type": "string"
},
"value": {
"type": "string"
}
}
}
}
}
}
}
}
}
}
},
"components": {
"schemas": {
"ProgramProductSpec": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
},
"productNumber": {
"type": "string"
},
"description": {
"type": "string"
},
"needsLoyaltyAccount": {
"type": "boolean"
},
"lifeCycleStatus": {
"type": "string"
},
"brand": {
"type": "string"
},
"validFor": {
"type": "object",
"properties": {
"startDateTime": {
"type": "string",
"format": "date-time"
},
"endDateTime": {
"type": "string",
"format": "date-time"
}
}
}
}
},
"Error": {
"type": "object",
"properties": {
"message": {
"type": "string"
}
}
}
}
}
}
Editor is loading...