thousandeyes-sdk-python/thousandeyes-sdk-agents/test/mock_manifest.py
Kevin 5441f44f1f CP-2453 Add generated integration tests for all SDK packages
Sync OAS-driven integration test artifacts (mock manifest, test base, conftest, and per-operation integration tests) across 21 packages for CP-2453 full rollout evaluation.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-28 12:07:00 +01:00

2460 lines
86 KiB
Python

# coding: utf-8
"""
Agents API
## Overview Manage Cloud and Enterprise Agents available to your account in ThousandEyes.
Generated by OpenAPI Generator (https://openapi-generator.tech)
Do not edit the class manually.
""" # noqa: E501
import json
from sdk_test_support.mock_server_types import ErrorResponseExpectation, OperationExpectation
OPERATION_MANIFEST = {
"get_agents_proxies": OperationExpectation(
operation_id="get_agents_proxies",
method="GET",
path="/agents/proxies",
path_param_examples={
},
success_status=200,
success_body=json.loads("""
{
"_links" : {
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"agentProxies" : [ {
"password" : "**********",
"isLocalConfigured" : true,
"name" : "Test Proxy - Auth Type - BASIC",
"location" : "proxy.thousandeyes.com:3128",
"lastModified" : "2022-07-17T22:00:54Z",
"authType" : "basic",
"type" : "static",
"aid" : "1234",
"bypassList" : [ "10.0.0.0/16", "*.thousandeyes.com" ],
"user" : "user1",
"proxyId" : "281474976710706"
}, {
"password" : "**********",
"isLocalConfigured" : true,
"name" : "Test Proxy - Auth Type - BASIC",
"location" : "proxy.thousandeyes.com:3128",
"lastModified" : "2022-07-17T22:00:54Z",
"authType" : "basic",
"type" : "static",
"aid" : "1234",
"bypassList" : [ "10.0.0.0/16", "*.thousandeyes.com" ],
"user" : "user1",
"proxyId" : "281474976710706"
} ]
}
"""),
success_content_type="application/json",
request_body_example=None,
error_responses={
"401": ErrorResponseExpectation(
status=401,
body=json.loads("""
{
"error_description" : "Invalid access token",
"error" : "invalid_token"
}"""),
content_type="application/json",
),
"403": ErrorResponseExpectation(
status=403,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"404": ErrorResponseExpectation(
status=404,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"429": ErrorResponseExpectation(
status=429,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"500": ErrorResponseExpectation(
status=500,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"502": ErrorResponseExpectation(
status=502,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
},
),
"get_agents_notification_rule": OperationExpectation(
operation_id="get_agents_notification_rule",
method="GET",
path="/agents/notification-rules/{notificationRuleId}",
path_param_examples={
"notificationRuleId": '281474976710706',
},
success_status=200,
success_body=json.loads("""
{
"isDefault" : false,
"expression" : "((lastContact >= 30 min))",
"_links" : {
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"ruleName" : "Default Agent Offline Notification",
"ruleId" : "281474976710706",
"notifications" : {
"thirdParty" : [ {
"integrationType" : "slack",
"integrationName" : "integrationSlack1",
"authToken" : "0VqDYEpidpHVAK397x8PBsmZ",
"channel" : "#slackChannel",
"integrationId" : "wb-78",
"authMethod" : "Basic",
"authUser" : "user123",
"target" : "https://hooks.slack.com/services/asd/0VqDYEpidpHVAK397x8PBsmZ"
}, {
"integrationType" : "slack",
"integrationName" : "integrationSlack1",
"authToken" : "0VqDYEpidpHVAK397x8PBsmZ",
"channel" : "#slackChannel",
"integrationId" : "wb-78",
"authMethod" : "Basic",
"authUser" : "user123",
"target" : "https://hooks.slack.com/services/asd/0VqDYEpidpHVAK397x8PBsmZ"
} ],
"webhook" : [ {
"integrationType" : "slack",
"integrationName" : "integrationSlack1",
"authToken" : "0VqDYEpidpHVAK397x8PBsmZ",
"channel" : "#slackChannel",
"integrationId" : "wb-78",
"authMethod" : "Basic",
"authUser" : "user123",
"target" : "https://hooks.slack.com/services/asd/0VqDYEpidpHVAK397x8PBsmZ"
}, {
"integrationType" : "slack",
"integrationName" : "integrationSlack1",
"authToken" : "0VqDYEpidpHVAK397x8PBsmZ",
"channel" : "#slackChannel",
"integrationId" : "wb-78",
"authMethod" : "Basic",
"authUser" : "user123",
"target" : "https://hooks.slack.com/services/asd/0VqDYEpidpHVAK397x8PBsmZ"
} ],
"email" : {
"recipients" : [ "user1@thousandeyes.com", "user2@cisco.com" ],
"message" : "This test is failing, check as soon as possible."
}
},
"notifyOnClear" : true,
"agents" : [ {
"agentId" : "281474976710706",
"agentType" : "enterprise-cluster",
"prefix" : "99.128.0.0/11",
"coordinates" : {
"latitude" : 37.77493,
"longitude" : -122.41942
},
"agentName" : "thousandeyes-stg-va-254",
"networkProviderInfo" : {
"asn" : 7018,
"name" : "AT&T Services, Inc.",
"type" : "isp"
},
"countryId" : "US",
"enabled" : true,
"network" : "AT&T Services, Inc. (AS 7018)",
"publicIpAddresses" : [ "192.168.1.78", "f9b2:3a21:f25c:d300:03f4:586d:f8d6:4e1c" ],
"ipAddresses" : [ "99.139.65.220", "9bbd:8a0a:a257:5876:288b:6cb2:3f36:64ce" ],
"location" : "San Francisco Bay Area",
"verifySslCertificates" : true
}, {
"agentId" : "281474976710706",
"agentType" : "enterprise-cluster",
"prefix" : "99.128.0.0/11",
"coordinates" : {
"latitude" : 37.77493,
"longitude" : -122.41942
},
"agentName" : "thousandeyes-stg-va-254",
"networkProviderInfo" : {
"asn" : 7018,
"name" : "AT&T Services, Inc.",
"type" : "isp"
},
"countryId" : "US",
"enabled" : true,
"network" : "AT&T Services, Inc. (AS 7018)",
"publicIpAddresses" : [ "192.168.1.78", "f9b2:3a21:f25c:d300:03f4:586d:f8d6:4e1c" ],
"ipAddresses" : [ "99.139.65.220", "9bbd:8a0a:a257:5876:288b:6cb2:3f36:64ce" ],
"location" : "San Francisco Bay Area",
"verifySslCertificates" : true
} ]
}
"""),
success_content_type="application/json",
request_body_example=None,
error_responses={
"401": ErrorResponseExpectation(
status=401,
body=json.loads("""
{
"error_description" : "Invalid access token",
"error" : "invalid_token"
}"""),
content_type="application/json",
),
"403": ErrorResponseExpectation(
status=403,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"404": ErrorResponseExpectation(
status=404,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"429": ErrorResponseExpectation(
status=429,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"500": ErrorResponseExpectation(
status=500,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"502": ErrorResponseExpectation(
status=502,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
},
),
"get_agents_notification_rules": OperationExpectation(
operation_id="get_agents_notification_rules",
method="GET",
path="/agents/notification-rules",
path_param_examples={
},
success_status=200,
success_body=json.loads("""
{
"agentAlertRules" : [ {
"ruleId" : "281474976710706",
"ruleName" : "Default Agent Offline Notification",
"expression" : "((lastContact >= 30 min))",
"notifyOnClear" : true,
"isDefault" : false
}, {
"ruleId" : "281474976710709",
"ruleName" : "Test Rule",
"expression" : "((lastContact >= 40 min))",
"notifyOnClear" : true,
"isDefault" : true
} ],
"_links" : {
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
}
}
"""),
success_content_type="application/json",
request_body_example=None,
error_responses={
"401": ErrorResponseExpectation(
status=401,
body=json.loads("""
{
"error_description" : "Invalid access token",
"error" : "invalid_token"
}"""),
content_type="application/json",
),
"403": ErrorResponseExpectation(
status=403,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"404": ErrorResponseExpectation(
status=404,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"429": ErrorResponseExpectation(
status=429,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"500": ErrorResponseExpectation(
status=500,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"502": ErrorResponseExpectation(
status=502,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
},
),
"delete_agent": OperationExpectation(
operation_id="delete_agent",
method="DELETE",
path="/agents/{agentId}",
path_param_examples={
"agentId": '281474976710706',
},
success_status=204,
success_body=None,
success_content_type="application/json",
request_body_example=None,
error_responses={
"401": ErrorResponseExpectation(
status=401,
body=json.loads("""
{
"error_description" : "Invalid access token",
"error" : "invalid_token"
}"""),
content_type="application/json",
),
"403": ErrorResponseExpectation(
status=403,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"404": ErrorResponseExpectation(
status=404,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"429": ErrorResponseExpectation(
status=429,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"500": ErrorResponseExpectation(
status=500,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"502": ErrorResponseExpectation(
status=502,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
},
),
"get_agent": OperationExpectation(
operation_id="get_agent",
method="GET",
path="/agents/{agentId}",
path_param_examples={
"agentId": '281474976710706',
},
success_status=200,
success_body=json.loads("""
{
"agentId" : "281474976710706",
"agentType" : "cloud",
"_links" : {
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"prefix" : "99.128.0.0/11",
"coordinates" : {
"latitude" : 37.77493,
"longitude" : -122.41942
},
"agentName" : "thousandeyes-stg-va-254",
"networkProviderInfo" : {
"asn" : 7018,
"name" : "AT&T Services, Inc.",
"type" : "isp"
},
"countryId" : "US",
"enabled" : true,
"network" : "AT&T Services, Inc. (AS 7018)",
"labels" : [ {
"labelId" : "11",
"name" : "Label name"
}, {
"labelId" : "11",
"name" : "Label name"
} ],
"tags" : [ {
"id" : "5aeab5d5-0d34-4d44-a7ac-fb440185295c",
"value" : "San Francisco",
"key" : "Location"
}, {
"id" : "5aeab5d5-0d34-4d44-a7ac-fb440185295c",
"value" : "San Francisco",
"key" : "Location"
} ],
"tests" : [ {
"_links" : {
"testResults" : [ {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/network"
}, {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/path-vis"
} ],
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"liveShare" : false,
"savedEvent" : true,
"description" : "ThousandEyes Test",
"type" : "agent-to-server",
"enabled" : true,
"createdDate" : "2022-07-17T22:00:54Z",
"createdBy" : "user@user.com",
"modifiedDate" : "2022-07-17T22:00:54Z",
"interval" : 60,
"modifiedBy" : "user@user.com",
"testId" : "281474976710706",
"alertsEnabled" : true,
"testName" : "ThousandEyes Test"
}, {
"_links" : {
"testResults" : [ {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/network"
}, {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/path-vis"
} ],
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"liveShare" : false,
"savedEvent" : true,
"description" : "ThousandEyes Test",
"type" : "agent-to-server",
"enabled" : true,
"createdDate" : "2022-07-17T22:00:54Z",
"createdBy" : "user@user.com",
"modifiedDate" : "2022-07-17T22:00:54Z",
"interval" : 60,
"modifiedBy" : "user@user.com",
"testId" : "281474976710706",
"alertsEnabled" : true,
"testName" : "ThousandEyes Test"
} ],
"publicIpAddresses" : [ "192.168.1.78", "f9b2:3a21:f25c:d300:03f4:586d:f8d6:4e1c" ],
"ipAddresses" : [ "99.139.65.220", "9bbd:8a0a:a257:5876:288b:6cb2:3f36:64ce" ],
"location" : "San Francisco Bay Area",
"verifySslCertificates" : true
}
"""),
success_content_type="application/json",
request_body_example=None,
error_responses={
"401": ErrorResponseExpectation(
status=401,
body=json.loads("""
{
"error_description" : "Invalid access token",
"error" : "invalid_token"
}"""),
content_type="application/json",
),
"403": ErrorResponseExpectation(
status=403,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"404": ErrorResponseExpectation(
status=404,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"429": ErrorResponseExpectation(
status=429,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"500": ErrorResponseExpectation(
status=500,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"502": ErrorResponseExpectation(
status=502,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
},
),
"get_agents": OperationExpectation(
operation_id="get_agents",
method="GET",
path="/agents",
path_param_examples={
},
success_status=200,
success_body=json.loads("""
{
"_links" : {
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"agents" : [ {
"agentId" : "281474976710706",
"agentType" : "enterprise-cluster",
"prefix" : "99.128.0.0/11",
"coordinates" : {
"latitude" : 37.77493,
"longitude" : -122.41942
},
"agentName" : "thousandeyes-stg-va-254",
"networkProviderInfo" : {
"asn" : 7018,
"name" : "AT&T Services, Inc.",
"type" : "isp"
},
"countryId" : "US",
"enabled" : true,
"network" : "AT&T Services, Inc. (AS 7018)",
"publicIpAddresses" : [ "192.168.1.78", "f9b2:3a21:f25c:d300:03f4:586d:f8d6:4e1c" ],
"ipAddresses" : [ "99.139.65.220", "9bbd:8a0a:a257:5876:288b:6cb2:3f36:64ce" ],
"location" : "San Francisco Bay Area",
"verifySslCertificates" : true
}, {
"agentId" : "281474976710706",
"agentType" : "enterprise-cluster",
"prefix" : "99.128.0.0/11",
"coordinates" : {
"latitude" : 37.77493,
"longitude" : -122.41942
},
"agentName" : "thousandeyes-stg-va-254",
"networkProviderInfo" : {
"asn" : 7018,
"name" : "AT&T Services, Inc.",
"type" : "isp"
},
"countryId" : "US",
"enabled" : true,
"network" : "AT&T Services, Inc. (AS 7018)",
"publicIpAddresses" : [ "192.168.1.78", "f9b2:3a21:f25c:d300:03f4:586d:f8d6:4e1c" ],
"ipAddresses" : [ "99.139.65.220", "9bbd:8a0a:a257:5876:288b:6cb2:3f36:64ce" ],
"location" : "San Francisco Bay Area",
"verifySslCertificates" : true
} ]
}
"""),
success_content_type="application/json",
request_body_example=None,
error_responses={
"401": ErrorResponseExpectation(
status=401,
body=json.loads("""
{
"error_description" : "Invalid access token",
"error" : "invalid_token"
}"""),
content_type="application/json",
),
"403": ErrorResponseExpectation(
status=403,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"404": ErrorResponseExpectation(
status=404,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"429": ErrorResponseExpectation(
status=429,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"500": ErrorResponseExpectation(
status=500,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"502": ErrorResponseExpectation(
status=502,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
},
),
"update_agent": OperationExpectation(
operation_id="update_agent",
method="PUT",
path="/agents/{agentId}",
path_param_examples={
"agentId": '281474976710706',
},
success_status=200,
success_body=json.loads("""
{
"agentId" : "281474976710706",
"agentType" : "cloud",
"_links" : {
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"prefix" : "99.128.0.0/11",
"coordinates" : {
"latitude" : 37.77493,
"longitude" : -122.41942
},
"agentName" : "thousandeyes-stg-va-254",
"networkProviderInfo" : {
"asn" : 7018,
"name" : "AT&T Services, Inc.",
"type" : "isp"
},
"countryId" : "US",
"enabled" : true,
"network" : "AT&T Services, Inc. (AS 7018)",
"labels" : [ {
"labelId" : "11",
"name" : "Label name"
}, {
"labelId" : "11",
"name" : "Label name"
} ],
"tags" : [ {
"id" : "5aeab5d5-0d34-4d44-a7ac-fb440185295c",
"value" : "San Francisco",
"key" : "Location"
}, {
"id" : "5aeab5d5-0d34-4d44-a7ac-fb440185295c",
"value" : "San Francisco",
"key" : "Location"
} ],
"tests" : [ {
"_links" : {
"testResults" : [ {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/network"
}, {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/path-vis"
} ],
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"liveShare" : false,
"savedEvent" : true,
"description" : "ThousandEyes Test",
"type" : "agent-to-server",
"enabled" : true,
"createdDate" : "2022-07-17T22:00:54Z",
"createdBy" : "user@user.com",
"modifiedDate" : "2022-07-17T22:00:54Z",
"interval" : 60,
"modifiedBy" : "user@user.com",
"testId" : "281474976710706",
"alertsEnabled" : true,
"testName" : "ThousandEyes Test"
}, {
"_links" : {
"testResults" : [ {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/network"
}, {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/path-vis"
} ],
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"liveShare" : false,
"savedEvent" : true,
"description" : "ThousandEyes Test",
"type" : "agent-to-server",
"enabled" : true,
"createdDate" : "2022-07-17T22:00:54Z",
"createdBy" : "user@user.com",
"modifiedDate" : "2022-07-17T22:00:54Z",
"interval" : 60,
"modifiedBy" : "user@user.com",
"testId" : "281474976710706",
"alertsEnabled" : true,
"testName" : "ThousandEyes Test"
} ],
"publicIpAddresses" : [ "192.168.1.78", "f9b2:3a21:f25c:d300:03f4:586d:f8d6:4e1c" ],
"ipAddresses" : [ "99.139.65.220", "9bbd:8a0a:a257:5876:288b:6cb2:3f36:64ce" ],
"location" : "San Francisco Bay Area",
"verifySslCertificates" : true
}
"""),
success_content_type="application/json",
request_body_example=json.loads("""
{
"localResolutionPrefixes" : [ "10.2.3.3/24", "10.2.3.3/25" ],
"tests" : [ "12313145", "12345" ],
"ipv6Policy" : "force-ipv4",
"keepBrowserCache" : true,
"targetForTests" : "1.1.1.1",
"agentName" : "thousandeyes-stg-va-254",
"enabled" : true,
"accountGroups" : [ "1234", "1" ]
}
"""),
error_responses={
"400": ErrorResponseExpectation(
status=400,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"errors" : [ {
"code" : "code",
"field" : "field",
"message" : "message"
}, {
"code" : "code",
"field" : "field",
"message" : "message"
} ],
"status" : 0
}"""),
content_type="application/json",
),
"401": ErrorResponseExpectation(
status=401,
body=json.loads("""
{
"error_description" : "Invalid access token",
"error" : "invalid_token"
}"""),
content_type="application/json",
),
"403": ErrorResponseExpectation(
status=403,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"404": ErrorResponseExpectation(
status=404,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"429": ErrorResponseExpectation(
status=429,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"500": ErrorResponseExpectation(
status=500,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"502": ErrorResponseExpectation(
status=502,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
},
),
"assign_agent_to_cluster": OperationExpectation(
operation_id="assign_agent_to_cluster",
method="POST",
path="/agents/{agentId}/cluster/assign",
path_param_examples={
"agentId": '281474976710706',
},
success_status=200,
success_body=json.loads("""
{
"agentId" : "281474976710706",
"agentType" : "cloud",
"_links" : {
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"prefix" : "99.128.0.0/11",
"coordinates" : {
"latitude" : 37.77493,
"longitude" : -122.41942
},
"agentName" : "thousandeyes-stg-va-254",
"networkProviderInfo" : {
"asn" : 7018,
"name" : "AT&T Services, Inc.",
"type" : "isp"
},
"countryId" : "US",
"enabled" : true,
"network" : "AT&T Services, Inc. (AS 7018)",
"labels" : [ {
"labelId" : "11",
"name" : "Label name"
}, {
"labelId" : "11",
"name" : "Label name"
} ],
"tags" : [ {
"id" : "5aeab5d5-0d34-4d44-a7ac-fb440185295c",
"value" : "San Francisco",
"key" : "Location"
}, {
"id" : "5aeab5d5-0d34-4d44-a7ac-fb440185295c",
"value" : "San Francisco",
"key" : "Location"
} ],
"tests" : [ {
"_links" : {
"testResults" : [ {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/network"
}, {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/path-vis"
} ],
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"liveShare" : false,
"savedEvent" : true,
"description" : "ThousandEyes Test",
"type" : "agent-to-server",
"enabled" : true,
"createdDate" : "2022-07-17T22:00:54Z",
"createdBy" : "user@user.com",
"modifiedDate" : "2022-07-17T22:00:54Z",
"interval" : 60,
"modifiedBy" : "user@user.com",
"testId" : "281474976710706",
"alertsEnabled" : true,
"testName" : "ThousandEyes Test"
}, {
"_links" : {
"testResults" : [ {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/network"
}, {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/path-vis"
} ],
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"liveShare" : false,
"savedEvent" : true,
"description" : "ThousandEyes Test",
"type" : "agent-to-server",
"enabled" : true,
"createdDate" : "2022-07-17T22:00:54Z",
"createdBy" : "user@user.com",
"modifiedDate" : "2022-07-17T22:00:54Z",
"interval" : 60,
"modifiedBy" : "user@user.com",
"testId" : "281474976710706",
"alertsEnabled" : true,
"testName" : "ThousandEyes Test"
} ],
"publicIpAddresses" : [ "192.168.1.78", "f9b2:3a21:f25c:d300:03f4:586d:f8d6:4e1c" ],
"ipAddresses" : [ "99.139.65.220", "9bbd:8a0a:a257:5876:288b:6cb2:3f36:64ce" ],
"location" : "San Francisco Bay Area",
"verifySslCertificates" : true
}
"""),
success_content_type="application/json",
request_body_example=json.loads("""
{
"agents" : [ "281474976710706" ]
}
"""),
error_responses={
"400": ErrorResponseExpectation(
status=400,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"errors" : [ {
"code" : "code",
"field" : "field",
"message" : "message"
}, {
"code" : "code",
"field" : "field",
"message" : "message"
} ],
"status" : 0
}"""),
content_type="application/json",
),
"401": ErrorResponseExpectation(
status=401,
body=json.loads("""
{
"error_description" : "Invalid access token",
"error" : "invalid_token"
}"""),
content_type="application/json",
),
"403": ErrorResponseExpectation(
status=403,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"404": ErrorResponseExpectation(
status=404,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"429": ErrorResponseExpectation(
status=429,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"500": ErrorResponseExpectation(
status=500,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"502": ErrorResponseExpectation(
status=502,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
},
),
"unassign_agent_from_cluster": OperationExpectation(
operation_id="unassign_agent_from_cluster",
method="POST",
path="/agents/{agentId}/cluster/unassign",
path_param_examples={
"agentId": '281474976710706',
},
success_status=200,
success_body=json.loads("""
{
"_links" : {
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"agents" : [ {
"agentId" : "281474976710706",
"agentType" : "enterprise-cluster",
"prefix" : "99.128.0.0/11",
"coordinates" : {
"latitude" : 37.77493,
"longitude" : -122.41942
},
"agentName" : "thousandeyes-stg-va-254",
"networkProviderInfo" : {
"asn" : 7018,
"name" : "AT&T Services, Inc.",
"type" : "isp"
},
"countryId" : "US",
"enabled" : true,
"network" : "AT&T Services, Inc. (AS 7018)",
"publicIpAddresses" : [ "192.168.1.78", "f9b2:3a21:f25c:d300:03f4:586d:f8d6:4e1c" ],
"ipAddresses" : [ "99.139.65.220", "9bbd:8a0a:a257:5876:288b:6cb2:3f36:64ce" ],
"location" : "San Francisco Bay Area",
"verifySslCertificates" : true
}, {
"agentId" : "281474976710706",
"agentType" : "enterprise-cluster",
"prefix" : "99.128.0.0/11",
"coordinates" : {
"latitude" : 37.77493,
"longitude" : -122.41942
},
"agentName" : "thousandeyes-stg-va-254",
"networkProviderInfo" : {
"asn" : 7018,
"name" : "AT&T Services, Inc.",
"type" : "isp"
},
"countryId" : "US",
"enabled" : true,
"network" : "AT&T Services, Inc. (AS 7018)",
"publicIpAddresses" : [ "192.168.1.78", "f9b2:3a21:f25c:d300:03f4:586d:f8d6:4e1c" ],
"ipAddresses" : [ "99.139.65.220", "9bbd:8a0a:a257:5876:288b:6cb2:3f36:64ce" ],
"location" : "San Francisco Bay Area",
"verifySslCertificates" : true
} ]
}
"""),
success_content_type="application/json",
request_body_example=json.loads("""
{
"members" : [ "281474976710706" ]
}
"""),
error_responses={
"400": ErrorResponseExpectation(
status=400,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"errors" : [ {
"code" : "code",
"field" : "field",
"message" : "message"
}, {
"code" : "code",
"field" : "field",
"message" : "message"
} ],
"status" : 0
}"""),
content_type="application/json",
),
"401": ErrorResponseExpectation(
status=401,
body=json.loads("""
{
"error_description" : "Invalid access token",
"error" : "invalid_token"
}"""),
content_type="application/json",
),
"403": ErrorResponseExpectation(
status=403,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"404": ErrorResponseExpectation(
status=404,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"429": ErrorResponseExpectation(
status=429,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"500": ErrorResponseExpectation(
status=500,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"502": ErrorResponseExpectation(
status=502,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
},
),
"get_agents_local_problems": OperationExpectation(
operation_id="get_agents_local_problems",
method="GET",
path="/agents/local-problems",
path_param_examples={
},
success_status=200,
success_body=json.loads("""
{
"endDate" : "2022-07-18T22:00:54Z",
"_links" : {
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"localProblems" : [ {
"duration" : 480,
"agent" : {
"agentId" : "281474976710706",
"agentName" : "thousandeyes-stg-va-254",
"location" : "San Francisco Bay Area",
"countryId" : "US"
},
"endDate" : "2026-05-18T03:22:00Z",
"active" : false,
"startDate" : "2026-05-18T03:14:00Z"
}, {
"duration" : 480,
"agent" : {
"agentId" : "281474976710706",
"agentName" : "thousandeyes-stg-va-254",
"location" : "San Francisco Bay Area",
"countryId" : "US"
},
"endDate" : "2026-05-18T03:22:00Z",
"active" : false,
"startDate" : "2026-05-18T03:14:00Z"
} ],
"startDate" : "2022-07-17T22:00:54Z"
}
"""),
success_content_type="application/json",
request_body_example=None,
error_responses={
"400": ErrorResponseExpectation(
status=400,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"errors" : [ {
"code" : "code",
"field" : "field",
"message" : "message"
}, {
"code" : "code",
"field" : "field",
"message" : "message"
} ],
"status" : 0
}"""),
content_type="application/json",
),
"401": ErrorResponseExpectation(
status=401,
body=json.loads("""
{
"error_description" : "Invalid access token",
"error" : "invalid_token"
}"""),
content_type="application/json",
),
"403": ErrorResponseExpectation(
status=403,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"404": ErrorResponseExpectation(
status=404,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"429": ErrorResponseExpectation(
status=429,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"500": ErrorResponseExpectation(
status=500,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"502": ErrorResponseExpectation(
status=502,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
},
),
"assign_tests": OperationExpectation(
operation_id="assign_tests",
method="POST",
path="/agents/{agentId}/tests/assign",
path_param_examples={
"agentId": '281474976710706',
},
success_status=200,
success_body=json.loads("""
{
"agentId" : "281474976710706",
"agentType" : "cloud",
"_links" : {
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"prefix" : "99.128.0.0/11",
"coordinates" : {
"latitude" : 37.77493,
"longitude" : -122.41942
},
"agentName" : "thousandeyes-stg-va-254",
"networkProviderInfo" : {
"asn" : 7018,
"name" : "AT&T Services, Inc.",
"type" : "isp"
},
"countryId" : "US",
"enabled" : true,
"network" : "AT&T Services, Inc. (AS 7018)",
"labels" : [ {
"labelId" : "11",
"name" : "Label name"
}, {
"labelId" : "11",
"name" : "Label name"
} ],
"tags" : [ {
"id" : "5aeab5d5-0d34-4d44-a7ac-fb440185295c",
"value" : "San Francisco",
"key" : "Location"
}, {
"id" : "5aeab5d5-0d34-4d44-a7ac-fb440185295c",
"value" : "San Francisco",
"key" : "Location"
} ],
"tests" : [ {
"_links" : {
"testResults" : [ {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/network"
}, {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/path-vis"
} ],
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"liveShare" : false,
"savedEvent" : true,
"description" : "ThousandEyes Test",
"type" : "agent-to-server",
"enabled" : true,
"createdDate" : "2022-07-17T22:00:54Z",
"createdBy" : "user@user.com",
"modifiedDate" : "2022-07-17T22:00:54Z",
"interval" : 60,
"modifiedBy" : "user@user.com",
"testId" : "281474976710706",
"alertsEnabled" : true,
"testName" : "ThousandEyes Test"
}, {
"_links" : {
"testResults" : [ {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/network"
}, {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/path-vis"
} ],
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"liveShare" : false,
"savedEvent" : true,
"description" : "ThousandEyes Test",
"type" : "agent-to-server",
"enabled" : true,
"createdDate" : "2022-07-17T22:00:54Z",
"createdBy" : "user@user.com",
"modifiedDate" : "2022-07-17T22:00:54Z",
"interval" : 60,
"modifiedBy" : "user@user.com",
"testId" : "281474976710706",
"alertsEnabled" : true,
"testName" : "ThousandEyes Test"
} ],
"publicIpAddresses" : [ "192.168.1.78", "f9b2:3a21:f25c:d300:03f4:586d:f8d6:4e1c" ],
"ipAddresses" : [ "99.139.65.220", "9bbd:8a0a:a257:5876:288b:6cb2:3f36:64ce" ],
"location" : "San Francisco Bay Area",
"verifySslCertificates" : true
}
"""),
success_content_type="application/json",
request_body_example=json.loads("""
{
"testIds" : [ "281474976710706" ]
}
"""),
error_responses={
"400": ErrorResponseExpectation(
status=400,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"errors" : [ {
"code" : "code",
"field" : "field",
"message" : "message"
}, {
"code" : "code",
"field" : "field",
"message" : "message"
} ],
"status" : 0
}"""),
content_type="application/json",
),
"401": ErrorResponseExpectation(
status=401,
body=json.loads("""
{
"error_description" : "Invalid access token",
"error" : "invalid_token"
}"""),
content_type="application/json",
),
"403": ErrorResponseExpectation(
status=403,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"404": ErrorResponseExpectation(
status=404,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"429": ErrorResponseExpectation(
status=429,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"500": ErrorResponseExpectation(
status=500,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"502": ErrorResponseExpectation(
status=502,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
},
),
"overwrite_tests": OperationExpectation(
operation_id="overwrite_tests",
method="POST",
path="/agents/{agentId}/tests/override",
path_param_examples={
"agentId": '281474976710706',
},
success_status=200,
success_body=json.loads("""
{
"agentId" : "281474976710706",
"agentType" : "cloud",
"_links" : {
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"prefix" : "99.128.0.0/11",
"coordinates" : {
"latitude" : 37.77493,
"longitude" : -122.41942
},
"agentName" : "thousandeyes-stg-va-254",
"networkProviderInfo" : {
"asn" : 7018,
"name" : "AT&T Services, Inc.",
"type" : "isp"
},
"countryId" : "US",
"enabled" : true,
"network" : "AT&T Services, Inc. (AS 7018)",
"labels" : [ {
"labelId" : "11",
"name" : "Label name"
}, {
"labelId" : "11",
"name" : "Label name"
} ],
"tags" : [ {
"id" : "5aeab5d5-0d34-4d44-a7ac-fb440185295c",
"value" : "San Francisco",
"key" : "Location"
}, {
"id" : "5aeab5d5-0d34-4d44-a7ac-fb440185295c",
"value" : "San Francisco",
"key" : "Location"
} ],
"tests" : [ {
"_links" : {
"testResults" : [ {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/network"
}, {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/path-vis"
} ],
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"liveShare" : false,
"savedEvent" : true,
"description" : "ThousandEyes Test",
"type" : "agent-to-server",
"enabled" : true,
"createdDate" : "2022-07-17T22:00:54Z",
"createdBy" : "user@user.com",
"modifiedDate" : "2022-07-17T22:00:54Z",
"interval" : 60,
"modifiedBy" : "user@user.com",
"testId" : "281474976710706",
"alertsEnabled" : true,
"testName" : "ThousandEyes Test"
}, {
"_links" : {
"testResults" : [ {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/network"
}, {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/path-vis"
} ],
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"liveShare" : false,
"savedEvent" : true,
"description" : "ThousandEyes Test",
"type" : "agent-to-server",
"enabled" : true,
"createdDate" : "2022-07-17T22:00:54Z",
"createdBy" : "user@user.com",
"modifiedDate" : "2022-07-17T22:00:54Z",
"interval" : 60,
"modifiedBy" : "user@user.com",
"testId" : "281474976710706",
"alertsEnabled" : true,
"testName" : "ThousandEyes Test"
} ],
"publicIpAddresses" : [ "192.168.1.78", "f9b2:3a21:f25c:d300:03f4:586d:f8d6:4e1c" ],
"ipAddresses" : [ "99.139.65.220", "9bbd:8a0a:a257:5876:288b:6cb2:3f36:64ce" ],
"location" : "San Francisco Bay Area",
"verifySslCertificates" : true
}
"""),
success_content_type="application/json",
request_body_example=json.loads("""
{
"testIds" : [ "281474976710706" ]
}
"""),
error_responses={
"400": ErrorResponseExpectation(
status=400,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"errors" : [ {
"code" : "code",
"field" : "field",
"message" : "message"
}, {
"code" : "code",
"field" : "field",
"message" : "message"
} ],
"status" : 0
}"""),
content_type="application/json",
),
"401": ErrorResponseExpectation(
status=401,
body=json.loads("""
{
"error_description" : "Invalid access token",
"error" : "invalid_token"
}"""),
content_type="application/json",
),
"403": ErrorResponseExpectation(
status=403,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"404": ErrorResponseExpectation(
status=404,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"429": ErrorResponseExpectation(
status=429,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"500": ErrorResponseExpectation(
status=500,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"502": ErrorResponseExpectation(
status=502,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
},
),
"unassign_tests": OperationExpectation(
operation_id="unassign_tests",
method="POST",
path="/agents/{agentId}/tests/unassign",
path_param_examples={
"agentId": '281474976710706',
},
success_status=200,
success_body=json.loads("""
{
"agentId" : "281474976710706",
"agentType" : "cloud",
"_links" : {
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"prefix" : "99.128.0.0/11",
"coordinates" : {
"latitude" : 37.77493,
"longitude" : -122.41942
},
"agentName" : "thousandeyes-stg-va-254",
"networkProviderInfo" : {
"asn" : 7018,
"name" : "AT&T Services, Inc.",
"type" : "isp"
},
"countryId" : "US",
"enabled" : true,
"network" : "AT&T Services, Inc. (AS 7018)",
"labels" : [ {
"labelId" : "11",
"name" : "Label name"
}, {
"labelId" : "11",
"name" : "Label name"
} ],
"tags" : [ {
"id" : "5aeab5d5-0d34-4d44-a7ac-fb440185295c",
"value" : "San Francisco",
"key" : "Location"
}, {
"id" : "5aeab5d5-0d34-4d44-a7ac-fb440185295c",
"value" : "San Francisco",
"key" : "Location"
} ],
"tests" : [ {
"_links" : {
"testResults" : [ {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/network"
}, {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/path-vis"
} ],
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"liveShare" : false,
"savedEvent" : true,
"description" : "ThousandEyes Test",
"type" : "agent-to-server",
"enabled" : true,
"createdDate" : "2022-07-17T22:00:54Z",
"createdBy" : "user@user.com",
"modifiedDate" : "2022-07-17T22:00:54Z",
"interval" : 60,
"modifiedBy" : "user@user.com",
"testId" : "281474976710706",
"alertsEnabled" : true,
"testName" : "ThousandEyes Test"
}, {
"_links" : {
"testResults" : [ {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/network"
}, {
"href" : "https://api.thousandeyes.com/v7/test-results/281474976710706/path-vis"
} ],
"self" : {
"hreflang" : "hreflang",
"templated" : true,
"profile" : "profile",
"name" : "name",
"href" : "https://api.thousandeyes.com/v7/link/to/resource/id",
"type" : "type",
"deprecation" : "deprecation",
"title" : "title"
}
},
"liveShare" : false,
"savedEvent" : true,
"description" : "ThousandEyes Test",
"type" : "agent-to-server",
"enabled" : true,
"createdDate" : "2022-07-17T22:00:54Z",
"createdBy" : "user@user.com",
"modifiedDate" : "2022-07-17T22:00:54Z",
"interval" : 60,
"modifiedBy" : "user@user.com",
"testId" : "281474976710706",
"alertsEnabled" : true,
"testName" : "ThousandEyes Test"
} ],
"publicIpAddresses" : [ "192.168.1.78", "f9b2:3a21:f25c:d300:03f4:586d:f8d6:4e1c" ],
"ipAddresses" : [ "99.139.65.220", "9bbd:8a0a:a257:5876:288b:6cb2:3f36:64ce" ],
"location" : "San Francisco Bay Area",
"verifySslCertificates" : true
}
"""),
success_content_type="application/json",
request_body_example=json.loads("""
{
"testIds" : [ "281474976710706" ]
}
"""),
error_responses={
"400": ErrorResponseExpectation(
status=400,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"errors" : [ {
"code" : "code",
"field" : "field",
"message" : "message"
}, {
"code" : "code",
"field" : "field",
"message" : "message"
} ],
"status" : 0
}"""),
content_type="application/json",
),
"401": ErrorResponseExpectation(
status=401,
body=json.loads("""
{
"error_description" : "Invalid access token",
"error" : "invalid_token"
}"""),
content_type="application/json",
),
"403": ErrorResponseExpectation(
status=403,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"404": ErrorResponseExpectation(
status=404,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"429": ErrorResponseExpectation(
status=429,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"500": ErrorResponseExpectation(
status=500,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
"502": ErrorResponseExpectation(
status=502,
body=json.loads("""
{
"instance" : "instance",
"detail" : "detail",
"type" : "type",
"title" : "title",
"status" : 0
}"""),
content_type="application/json",
),
},
),
}