{"metadata":{"image":[],"title":"","description":""},"api":{"url":"/variations/schema.json","auth":"optional","results":{"codes":[{"status":200,"language":"json","code":"[\n {\n \"field\": \"identifier\",\n \"name\": \"Variation Unique ID (SKU)\",\n \"required\": true,\n \"readonly\": false,\n \"description\": \"The unique identifier or SKU that your system uses to recognize this product variation.\"\n },\n ...\n]","name":""}]},"settings":"","examples":{"codes":[{"code":"curl https://tophatter.com/merchant_api/v1/variations/schema.json","language":"curl"},{"language":"ruby","code":"TophatterMerchant::Variation.schema"},{"code":"VariationApi::getSchema();","language":"php"},{"language":"java","code":"List<Schema> schema = VariationApi.getSchema();"}]},"method":"get","params":[]},"next":{"description":"","pages":[]},"title":"Variation Definition","type":"basic","slug":"variation-schema","excerpt":"","body":"Product variations returned by the Tophatter Merchant API have the following fields:\n[block:parameters]\n{\n \"data\": {\n \"h-0\": \"Field\",\n \"h-1\": \"Name\",\n \"h-2\": \"Description\",\n \"0-1\": \"The unique identifier of the product this variation belongs to.\",\n \"4-1\": \"The size of the variation. Example: `Large`. Optional. Once a variation has been created it's size cannot be changed.\",\n \"5-1\": \"The color of the variation. Example: `Red`. Optional. Once a variation has been created it's color cannot be changed.\",\n \"6-1\": \"The quantity available to sell for this variation.\",\n \"0-0\": \"`product_identifier `\",\n \"4-0\": \"`size`\",\n \"5-0\": \"`color`\",\n \"6-0\": \"`quantity`\",\n \"0-2\": \"The unique identifier of the product this variation belongs to.\",\n \"4-2\": \"The size of the variation. You can specify any size you'd like, but we recommend you use a size from our standardized list of sizes [here](doc:sizes).\",\n \"5-2\": \"You can specify any color you'd like, but we recommend you use a size from our standardized list of colors [here](doc:colors).\",\n \"6-2\": \"The quantity available to sell for this variation.\",\n \"2-0\": \"`identifier`\",\n \"2-1\": \"The unique identifier or SKU that your system uses to recognize this product variation. Only letters, numbers, spaces, dashes and underscores are allowed.\",\n \"2-2\": \"The unique identifier or SKU that your system uses to recognize this product variation. Only letters, numbers, spaces, dashes and underscores are allowed.\",\n \"7-0\": \"`created_at`\",\n \"8-0\": \"`disabled_at`\",\n \"9-0\": \"`deleted_at`\",\n \"7-1\": \"The date and time the variation was created in PDT (UTC -7).\",\n \"8-1\": \"The date and time the variation was disabled in PDT (UTC -7).\",\n \"9-1\": \"The date and time the variation was deleted in PDT (UTC -7).\",\n \"7-2\": \"The date and time the variation was created.\",\n \"8-2\": \"The date and time the variation was disabled.\",\n \"9-2\": \"The date and time the variation was deleted.\",\n \"1-0\": \"`product_internal_id`\",\n \"3-0\": \"`internal_id`\",\n \"1-1\": \"Tophatter's internal identifier for the product that this variation belongs to.\",\n \"3-1\": \"Tophatter's internal identifier for this variation.\",\n \"1-2\": \"Tophatter's internal identifier for the product that this variation belongs to.\",\n \"3-2\": \"Tophatter's internal identifier for this variation.\"\n },\n \"cols\": 2,\n \"rows\": 10\n}\n[/block]\n\n[block:api-header]\n{\n \"title\": \"Examples\"\n}\n[/block]\n\n[block:code]\n{\n \"codes\": [\n {\n \"code\": \"{ \\n \\\"product_identifier\\\": \\\"amazon-fire-7\\\",\\n \\\"product_internal_id\\\": 5472398,\\n \\\"identifier\\\": \\\"B01GEW27DA\\\",\\n \\\"internal_id\\\": 26054992,\\n \\\"size\\\": null,\\n \\\"color\\\": \\\"Black\\\",\\n \\\"quantity\\\": 69,\\n \\\"created_at\\\": \\\"2018-04-03T11:33:10-07:00\\\",\\n \\\"disabled_at\\\": null,\\n \\\"deleted_at\\\": null\\n}\",\n \"language\": \"json\"\n }\n ]\n}\n[/block]","updates":[],"order":0,"isReference":false,"hidden":false,"sync_unique":"","link_url":"","link_external":false,"_id":"56a9923e13a69a0d00a778dc","project":"567f0c06143cc60d00c1fdbe","createdAt":"2016-01-28T03:59:58.665Z","githubsync":"","parentDoc":null,"user":"567f0baca74a1c0d003e1fba","version":{"version":"1","version_clean":"1.0.0","codename":"","is_stable":true,"is_beta":false,"is_hidden":false,"is_deprecated":false,"categories":["567f0c07143cc60d00c1fdc2","56a9783109cb9c0d00f0c7d3","56a97837f834950d0037b363","56a9783b2d8fd90d0036eed6","56a979912d8fd90d0036eed8","5834b5691a80690f00d31faf","5834b5e4f775120f00c45f9d","5bf1a1473031e4005075ae14","5c64c200244bda003204b97f","6036b3ce32fcbe02eb8d7011"],"_id":"567f0c06143cc60d00c1fdc1","__v":10,"createdAt":"2015-12-26T21:52:06.734Z","releaseDate":"2015-12-26T21:52:06.734Z","project":"567f0c06143cc60d00c1fdbe"},"__v":11,"category":{"sync":{"isSync":false,"url":""},"pages":["56a98ff62d8fd90d0036eee9","56a98ffc1801ac0d00881b8b","56a99013257fbc0d00d47633","56a99029257fbc0d00d47635","56a990541801ac0d00881b8e","56a99094f834950d0037b37e","56a9923e13a69a0d00a778dc","56a9a7161801ac0d00881ba5"],"title":"Variations","slug":"variations","order":2,"from_sync":false,"reference":false,"_id":"56a97837f834950d0037b363","__v":8,"createdAt":"2016-01-28T02:08:55.258Z","project":"567f0c06143cc60d00c1fdbe","version":"567f0c06143cc60d00c1fdc1"}}