# Target Variants#ListTargetVariants List a collection of Scan Target Variants Endpoint: GET /sto/api/v2/targets/{targetId}/variants Version: 1.0 Security: ## Query parameters: - `accountId` (string, required) Harness Account ID Example: "abcdef1234567890ghijkl" - `page` (integer) Page number to fetch (starting from 0) Example: 4 - `pageSize` (integer) Number of results per page Example: 50 - `name` (string) Resource name Example: "NodeGoat" ## Path parameters: - `targetId` (string, required) Associated Target ID Example: "abcdef1234567890ghijkl" ## Header parameters: - `X-Api-Key` (string) Harness personal or service access token Example: "Nisi sit reprehenderit." ## Response 200 fields (application/json): - `pagination` (object, required) Example: {"link":"","page":4,"pageSize":20,"totalItems":230,"totalPages":12} - `pagination.link` (string) Link-based paging - `pagination.page` (integer, required) Page number (starting from 0) Example: 4 - `pagination.pageSize` (integer, required) Requested page size Example: 20 - `pagination.totalItems` (integer, required) Total results available Example: 230 - `pagination.totalPages` (integer, required) Total pages available Example: 12 - `results` (array, required) Example: [{"created":1651578240,"hash":"d1998db4b4651a4b9be9ecf320a2dfb8b4710e35","id":"abcdef1234567890ghijkl","lastModified":1651578240,"parameters":{"branch":"main"},"targetId":"abcdef1234567890ghijkl"},{"created":1651578240,"hash":"d1998db4b4651a4b9be9ecf320a2dfb8b4710e35","id":"abcdef1234567890ghijkl","lastModified":1651578240,"parameters":{"branch":"main"},"targetId":"abcdef1234567890ghijkl"},{"created":1651578240,"hash":"d1998db4b4651a4b9be9ecf320a2dfb8b4710e35","id":"abcdef1234567890ghijkl","lastModified":1651578240,"parameters":{"branch":"main"},"targetId":"abcdef1234567890ghijkl"},{"created":1651578240,"hash":"d1998db4b4651a4b9be9ecf320a2dfb8b4710e35","id":"abcdef1234567890ghijkl","lastModified":1651578240,"parameters":{"branch":"main"},"targetId":"abcdef1234567890ghijkl"}] - `results.created` (integer, required) Unix timestamp at which the resource was created Example: 1651578240 - `results.hash` (string) Git Commit or Container Image hash Example: "d1998db4b4651a4b9be9ecf320a2dfb8b4710e35" - `results.id` (string, required) Resource identifier Example: "abcdef1234567890ghijkl" - `results.lastModified` (integer, required) Unix timestamp at which the resource was most recently modified Example: 1651578240 - `results.parameters` (object, required) Parameters for this Variant, as a JSON-encoded string Example: {"branch":"main"} - `results.targetId` (string, required) Associated Target ID Example: "abcdef1234567890ghijkl" ## Response 400 fields (application/json): - `message` (string, required) Example: "Not Found" - `status` (integer) Example: 404 ## Response 401 fields (application/json): - `message` (string, required) Example: "Not Found" - `status` (integer) Example: 404 ## Response 403 fields (application/json): - `message` (string, required) Example: "Not Found" - `status` (integer) Example: 404 ## Response 404 fields (application/json): - `message` (string, required) Example: "Not Found" - `status` (integer) Example: 404 ## Response 429 fields (application/json): - `message` (string, required) Example: "Not Found" - `status` (integer) Example: 404 ## Response 500 fields (application/json): - `message` (string, required) Example: "Not Found" - `status` (integer) Example: 404