{ "parameters": { "productSettingID": { "name": "productSettingID", "in": "query", "description": "Unique ID for the record. This by itself, or productCode/productID plus code, is required.", "required": false, "type": "integer" }, "productCode": { "name": "productCode", "in": "query", "description": "Unique code for the parent Product of the ProductSetting. This or the productID plus the code, or the productSettingID by itself, is required.", "required": false, "type": "string" }, "productIDViewEditOrAdd": { "name": "productID", "in": "query", "description": "The parent productID. This or the productCode plus the code, or the productSettingID by itself, is required.", "required": false, "type": "integer" }, "code": { "name": "code", "in": "query", "description": "Code for the ProductSetting. Since multiple ProductSettings can share the same code, the productCode or the productID must also be submitted. This plus the productCode or productID, or the productSettingID by itself, is required.", "required": false, "type": "string" }, "productIDList": { "name": "productID", "in": "query", "description": "The parent productID. The resulting list is retricted to ProductSettings assigned to this Product.", "required": false, "type": "integer" } }, "paths": { "/productSetting": { "get": { "summary": "ProductSetting View", "description": "View the details of a ProductSetting record.", "tags": [ "Administrative Operations" ], "parameters": [ { "$ref": "#/parameters/productSettingID" }, { "$ref": "#/parameters/productIDViewEditOrAdd" }, { "$ref": "#/parameters/productCode" }, { "$ref": "#/parameters/code" }, { "$ref": "../swagger-spec.json#/parameters/apiLoginIDParam" }, { "$ref": "../swagger-spec.json#/parameters/apiAuthenticationTokenParam" } ], "responses": { "200": { "description": "ProductSetting object", "schema": { "$ref": "#/definitions/WrappedProductSetting" } }, "default": { "description": "Error", "schema": { "$ref": "../swagger-spec.json#/definitions/Error" } } } }, "delete": { "summary": "ProductSetting Delete", "description": "Delete a ProductSetting record.", "tags": [ "Administrative Operations" ], "parameters": [ { "$ref": "#/parameters/productSettingID" }, { "$ref": "#/parameters/productCode" }, { "$ref": "#/parameters/productIDViewEditOrAdd" }, { "$ref": "#/parameters/code" }, { "$ref": "../swagger-spec.json#/parameters/apiLoginIDParam" }, { "$ref": "../swagger-spec.json#/parameters/apiAuthenticationTokenParam" } ], "responses": { "200": { "description": "Success", "schema": { "$ref": "#/definitions/WrappedProductSetting" } }, "default": { "description": "Error", "schema": { "$ref": "../swagger-spec.json#/definitions/Error" } } } }, "patch": { "summary": "ProductSetting Edit", "description": "Edits a ProductSetting record.", "tags": [ "Administrative Operations" ], "parameters": [ { "name": "productSetting", "in": "body", "description": "The productSetting to be edited. Either the productCode or productID, plus the code, or the productSettingID by itself, must be provided.", "required": true, "schema": { "$ref": "#/definitions/ProductSetting" } }, { "$ref": "../swagger-spec.json#/parameters/apiLoginIDParam" }, { "$ref": "../swagger-spec.json#/parameters/apiAuthenticationTokenParam" } ], "responses": { "200": { "description": "ProductSetting object", "schema": { "$ref": "#/definitions/WrappedProductSetting" } }, "default": { "description": "Error", "schema": { "$ref": "../swagger-spec.json#/definitions/Error" } } } }, "post": { "summary": "ProductSetting Add", "description": "Adds a ProductSetting record.", "tags": [ "Administrative Operations" ], "parameters": [ { "name": "productSetting", "in": "body", "description": "The productSetting to be added.", "required": true, "schema": { "$ref": "#/definitions/NewProductSetting" } }, { "$ref": "../swagger-spec.json#/parameters/apiLoginIDParam" }, { "$ref": "../swagger-spec.json#/parameters/apiAuthenticationTokenParam" } ], "responses": { "200": { "description": "ProductSetting object", "schema": { "$ref": "#/definitions/WrappedProductSetting" } }, "default": { "description": "Error", "schema": { "$ref": "../swagger-spec.json#/definitions/Error" } } } } }, "/productSetting/list": { "get": { "summary": "ProductSetting List", "description": "View a list of ProductSettings.", "tags": [ "Administrative Operations" ], "parameters": [ { "$ref": "../swagger-spec.json#/parameters/itemsPerPage" }, { "$ref": "../swagger-spec.json#/parameters/firstRow" }, { "$ref": "../swagger-spec.json#/parameters/sortByString" }, { "$ref": "../swagger-spec.json#/parameters/sortAscOrDesc" }, { "$ref": "../swagger-spec.json#/parameters/searchString" }, { "$ref": "#/parameters/productIDList" }, { "$ref": "../swagger-spec.json#/parameters/apiLoginIDParam" }, { "$ref": "../swagger-spec.json#/parameters/apiAuthenticationTokenParam" } ], "responses": { "200": { "description": "ProductSetting List", "schema": { "$ref": "#/definitions/WrappedProductSettingList" } }, "default": { "description": "Error", "schema": { "$ref": "../swagger-spec.json#/definitions/Error" } } } } } }, "definitions": { "BaseProductSetting": { "type": "object", "properties": { "name": { "description": "The name of this productSetting.", "type": "string", "maxLength": 255 }, "code": { "description": "A unique code for this productSetting under the product, used by the system to identify it along with the productID. (No spaces, commas, or pipe characters.)", "type": "string", "maxLength": 100 }, "description": { "description": "The description for this productSetting.", "type": "string" }, "type": { "description": "The productSetting type, used to categorize the product settings in the application logic.", "type": "string", "maxLength": 255 }, "valueType": { "description": "The productSetting valueType. Valid values are 'integerValue', 'smallValue', 'mediumValue', and 'textValue'", "type": "string", "maxLength": 255 } } }, "NewProductSetting": { "type": "object", "allOf": [ { "required": [ "name", "code" ], "properties": { "code": { "type": "string", "description": "Unique code for the productSetting. (No spaces, commas, or pipe characters.)" }, "name": { "type": "string", "description": "The name of this productSetting." }, "value": { "type": "string", "description": "The value of the new productSetting. The field represented by the valueType parameter (integerValue, smallValue, etc.) gets populated with this value." }, "productCode": { "type": "string", "description": "Unique code for the parent product of the productSetting. This or the productID is required." }, "productID": { "type": "string", "description": "Unique identifier for the parent product of the productSetting. This or the productCode is required." } } }, { "$ref": "#/definitions/BaseProductSetting" } ] }, "ProductSetting": { "type": "object", "allOf": [ { "properties": { "productSettingID": { "type": "integer", "description": "Unique identifier representing a specific productSetting. This by itself, or the productCode plus code, is required." }, "productCode": { "type": "string", "description": "Unique code for the parent product of the productSetting. This and the code, or the productSettingID by itself, is required." }, "code": { "type": "string", "description": "Unique code for the productSetting under the parent product. This and the productCode, or the productSettingID by itself, is required." }, "name": { "type": "string", "description": "Name of the productSetting." }, "integerValue": { "description": "The product setting integer value, if the valueType is 'integerValue'.", "type": "integer", "default": 0 }, "smallValue": { "description": "The product setting small value, if the valueType is 'smallValue'. The number of characters must be 64 or fewer.", "type": "string", "maxLength": 64 }, "mediumValue": { "description": "The product setting medium value, if the valueType is 'mediumValue'. The number of characters must be 255 or fewer.", "type": "string", "maxLength": 255 }, "textValue": { "description": "The product setting text value, if the valueType is 'textValue'.", "type": "string" } } }, { "$ref": "#/definitions/BaseProductSetting" } ] }, "WrappedProductSetting": { "type": "object", "properties": { "success": { "type": "boolean" }, "errors": { "type": "array", "items": { "type": "string" } }, "messages": { "type": "array", "items": { "type": "string" } }, "jsonResult": { "type": "object", "$ref": "#/definitions/ProductSetting" } } }, "WrappedProductSettingList": { "type": "object", "properties": { "success": { "type": "boolean" }, "errors": { "type": "array", "items": { "type": "string" } }, "messages": { "type": "array", "items": { "type": "string" } }, "jsonResult": { "type": "object", "properties": { "itemCollection": { "type": "array", "description": "The list of items being requested that match the criteria, limited to the number of itemsPerPage.", "items": { "$ref": "#/definitions/ProductSetting" } }, "itemCount": { "description": "The total number of items matching the criteria. This value may used to compose paging parameters.", "type": "integer" } } } } } } }