{"type":"api","title":"Create dashboard snapshot","meta":{"id":"/apps/pubhub/media/000-v7-apis/5b3454a4300b838cc17f7b2cdc0690fdd15058d5/0e4c66ca-115a-3769-be5b-c6944add743f","info":{"description":"Manage ThousandEyes Dashboards.","title":"Dashboards API","version":"7.0.34"},"security":[{"BearerAuth":[]}],"tags":[{"description":"Dashboards and Widgets operations","name":"Dashboards"},{"description":"Dashboard Snapshots CRUD operations","name":"Dashboard Snapshots"},{"name":"Dashboards Filters"}],"openapi":"3.0.1","servers":[{"description":"ThousandEyes API production URL","url":"https://api.thousandeyes.com/v7"}],"securitySchemes":{"BearerAuth":{"description":"Bearer authentication token","scheme":"bearer","type":"http"}}},"spec":{"description":"Creates a new dashboard snapshot within your account group. The `Edit Snapshots` permission is required to use this endpoint.\n","operationId":"createDashboardSnapshot","parameters":[{"description":"A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response.","in":"query","name":"aid","required":false,"schema":{"example":"1234","type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"Request to generate a snapshot from a dashboard.","properties":{"startDate":{"description":"Date and time to start aggregating data (ISO date-time format).","example":"2023-05-16T10:14:28Z","format":"date-time","type":"string"},"endDate":{"description":"Date and time to end aggregating data (ISO date-time format).","example":"2023-05-16T10:14:28Z","format":"date-time","type":"string"},"displayName":{"description":"The name of the snapshot, does not have to be unique.","example":"snapshot from API","type":"string"},"dashboardId":{"description":"TheIdentifierof the dashboard to generate a snapshot from","example":"646f4d2ce3c99b0536c3821e","type":"string"},"anonymizeData":{"description":"Set to `true` to anonymize the data in the snapshot.","type":"boolean"},"timezone":{"description":"Specifies the timezone used for date and time fields.","example":"PST","type":"string"},"expirationDate":{"description":"Expiration date of the snapshot. If unspecified, the snapshot expires 1 year from its creation date. The expiration date must be set within 5 years from the current date and adhere to the ISO date-time format.","example":"2023-05-16T10:14:28Z","format":"date-time","type":"string"}},"type":"object","$$ref":"#/components/schemas/GenerateDashboardSnapshotRequest"}}},"description":"Request body schema to create a dashboard snapshot.","required":true},"responses":{"201":{"content":{"application/hal+json":{"schema":{"properties":{"snapshotId":{"description":"Identifier of the dashboard snapshot.","example":"d28bb71f-5a47-4783-8f12-d4b115e61b0c","format":"uuid","type":"string"},"_links":{"description":"A links object containing the self link.","properties":{"self":{"description":"A hyperlink from the containing resource to a URI.","properties":{"href":{"description":"Its value is either a URI [RFC3986] or a URI template [RFC6570].","example":"https://api.thousandeyes.com/v7/link/to/resource/id","type":"string"},"templated":{"description":"Should be true when the link object's \"href\" property is a URI template.","type":"boolean"},"type":{"description":"Used as a hint to indicate the media type expected when dereferencing the target resource.","type":"string"},"deprecation":{"description":"Its presence indicates that the link is to be deprecated at a future date. Its value is a URL that should provide further information about the deprecation.","type":"string"},"name":{"description":"Its value may be used as a secondary key for selecting link objects that share the same relation type.","type":"string"},"profile":{"description":"A URI that hints about the profile of the target resource.","type":"string"},"title":{"description":"Intended for labelling the link with a human-readable identifier","type":"string"},"hreflang":{"description":"Indicates the language of the target resource","type":"string"}},"required":["href"],"type":"object","$$ref":"#/components/schemas/Link"}},"readOnly":true,"type":"object","$$ref":"#/components/schemas/SelfLinks"}},"type":"object","$$ref":"#/components/schemas/DashboardSnapshotResponse"}}},"description":"Created","headers":{"Location":{"description":"The absolute path to created resource.","schema":{"example":"https://api.thousandeyes.com/v7/link/to/resource/id","format":"uri","type":"string"},"$$ref":"#/components/headers/Location"},"X-Dashboard-Snapshot-Rate-Limit-Limit":{"description":"The maximum number of dashboard snapshot requests allowed within a specified time frame. The limit is 100 requests per hour.","explode":false,"schema":{"example":100,"type":"integer"},"style":"simple","$$ref":"#/components/headers/DashboardSnapshotRateLimit"},"X-Dashboard-Snapshot-Rate-Limit-Remaining":{"description":"The number of remaining dashboard snapshot requests that can be made within the current time frame. This value indicates how many of the allowed 100 requests per hour are still available.","explode":false,"schema":{"example":45,"type":"integer"},"style":"simple","$$ref":"#/components/headers/DashboardSnapshotRateLimitRemaining"},"X-Dashboard-Snapshot-Rate-Limit-Reset":{"description":"The amount of time remaining until the rate limit resets and the full quota of requests is available again. If the value is 0, it means the rate limit currently allows access.","explode":false,"schema":{"example":160,"type":"integer"},"style":"simple","$$ref":"#/components/headers/DashboardSnapshotRateLimitReset"}}},"400":{"content":{"application/problem+json":{"example":{"type":"about:blank","title":"Request validation failed. There are invalid or missing fields","status":400,"detail":"Your request object contains invalid fields.","instance":"/v7","errors":[{"code":"AM-5432","field":"firstName","message":"firstName cannot have fancy characters"},{"code":"DASH-5622","field":"password","message":"Password cannot be blank"}]},"schema":{"properties":{"type":{"description":"A URI reference that identifies the problem type. When this member is not present, its value is assumed to be \"about:blank\".","type":"string"},"title":{"description":"A short, human-readable summary of the problem type.","type":"string"},"status":{"description":"The HTTP status code generated by the origin server for this occurrence of the problem.","type":"integer"},"detail":{"description":"A human-readable explanation specific to this occurrence of the problem.","type":"string"},"instance":{"description":"A URI reference that identifies the specific occurrence of the problem.","type":"string"},"errors":{"description":"(Optional) When multiple errors occur, the details for each error are listed.","items":{"properties":{"code":{"description":"(Optional) A unique error type/code that can be referenced in the documentation for further details.","type":"string"},"field":{"description":"Identifies the field that triggered this particular error.","type":"string"},"message":{"description":"A short, human-readable summary of the error.","type":"string"}},"type":"object","$$ref":"#/components/schemas/ValidationErrorItem"},"nullable":true,"type":"array"}},"type":"object","$$ref":"#/components/schemas/ValidationError"}}},"description":"Bad Request"},"401":{"content":{"application/problem+json":{"schema":{"properties":{"error":{"example":"invalid_token","type":"string"},"error_description":{"example":"Invalid access token","type":"string"}},"type":"object","$$ref":"#/components/schemas/UnauthorizedError"}}},"description":"Unauthorized"},"403":{"content":{"application/problem+json":{"schema":{"properties":{"type":{"description":"A URI reference that identifies the problem type. When this member is not present, its value is assumed to be \"about:blank\".","type":"string"},"title":{"description":"A short, human-readable summary of the problem type.","type":"string"},"status":{"description":"The HTTP status code generated by the origin server for this occurrence of the problem.","type":"integer"},"detail":{"description":"A human-readable explanation specific to this occurrence of the problem.","type":"string"},"instance":{"description":"A URI reference that identifies the specific occurrence of the problem.","type":"string"}},"type":"object","$$ref":"#/components/schemas/Error"}}},"description":"Insufficient permissions to query endpoint"},"404":{"content":{"application/problem+json":{"example":{"type":"about:blank","title":"URI Resource Not Found","status":404,"detail":"Details explaining if the 404 error is related to an invalid URI or a wrong ID","instance":"/v7"},"schema":{"properties":{"type":{"description":"A URI reference that identifies the problem type. When this member is not present, its value is assumed to be \"about:blank\".","type":"string"},"title":{"description":"A short, human-readable summary of the problem type.","type":"string"},"status":{"description":"The HTTP status code generated by the origin server for this occurrence of the problem.","type":"integer"},"detail":{"description":"A human-readable explanation specific to this occurrence of the problem.","type":"string"},"instance":{"description":"A URI reference that identifies the specific occurrence of the problem.","type":"string"}},"type":"object","$$ref":"#/components/schemas/Error"}}},"description":"Not found"},"429":{"description":"Exhausted rate limit for snapshot creation","headers":{"X-Dashboard-Snapshot-Rate-Limit-Limit":{"description":"The maximum number of dashboard snapshot requests allowed within a specified time frame. The limit is 100 requests per hour.","explode":false,"schema":{"example":100,"type":"integer"},"style":"simple","$$ref":"#/components/headers/DashboardSnapshotRateLimit"},"X-Dashboard-Snapshot-Rate-Limit-Remaining":{"description":"The number of remaining dashboard snapshot requests that can be made within the current time frame. This value indicates how many of the allowed 100 requests per hour are still available.","explode":false,"schema":{"example":45,"type":"integer"},"style":"simple","$$ref":"#/components/headers/DashboardSnapshotRateLimitRemaining"},"X-Dashboard-Snapshot-Rate-Limit-Reset":{"description":"The amount of time remaining until the rate limit resets and the full quota of requests is available again. If the value is 0, it means the rate limit currently allows access.","explode":false,"schema":{"example":160,"type":"integer"},"style":"simple","$$ref":"#/components/headers/DashboardSnapshotRateLimitReset"}}},"500":{"content":{"application/problem+json":{"example":{"type":"about:blank","title":"Internal server error","status":500,"detail":"Optional detail about the internal error message.","instance":"/v7"},"schema":{"properties":{"type":{"description":"A URI reference that identifies the problem type. When this member is not present, its value is assumed to be \"about:blank\".","type":"string"},"title":{"description":"A short, human-readable summary of the problem type.","type":"string"},"status":{"description":"The HTTP status code generated by the origin server for this occurrence of the problem.","type":"integer"},"detail":{"description":"A human-readable explanation specific to this occurrence of the problem.","type":"string"},"instance":{"description":"A URI reference that identifies the specific occurrence of the problem.","type":"string"}},"type":"object","$$ref":"#/components/schemas/Error"}}},"description":"Internal server error"}},"summary":"Create dashboard snapshot","tags":["Dashboard Snapshots"],"__originalOperationId":"createDashboardSnapshot","security":[{"BearerAuth":[]}],"method":"post","path":"/dashboard-snapshots"}}