Files
neon-api-python/tests/cassettes/test_integration/test_project.yaml
T

263 lines
14 KiB
YAML

interactions:
- request:
body: null
headers:
Accept:
- application/json
Accept-Encoding:
- gzip, deflate
Connection:
- keep-alive
Content-Type:
- application/json
User-Agent:
- neon-client/python version=(0.1.0)
method: GET
uri: https://console.neon.tech/api/v2/projects
response:
body:
string: '{"projects":[{"id":"sweet-haze-98484788","platform_id":"aws","region_id":"aws-us-east-2","name":"pytest-2613","provisioner":"k8s-neonvm","default_endpoint_settings":{"autoscaling_limit_min_cu":0,"autoscaling_limit_max_cu":0,"suspend_timeout_seconds":0},"settings":{"allowed_ips":{"primary_branch_only":false},"enable_logical_replication":false},"pg_version":15,"proxy_host":"us-east-2.aws.neon.tech","branch_logical_size_limit":3072,"branch_logical_size_limit_bytes":3221225472,"store_passwords":true,"active_time":0,"cpu_used_sec":0,"creation_source":"console","created_at":"2024-01-24T13:55:29Z","updated_at":"2024-01-24T13:55:32Z","synthetic_storage_size":0,"quota_reset_at":"2024-02-01T00:00:00Z","owner_id":"838386f6-b5f1-4c3b-89a2-4f5a130ef3de"}],"pagination":{"cursor":"sweet-haze-98484788"}}'
headers:
Connection:
- keep-alive
Content-Length:
- '799'
Content-Type:
- application/json
Date:
- Wed, 24 Jan 2024 13:55:40 GMT
Strict-Transport-Security:
- max-age=15724800; includeSubDomains
Vary:
- Origin
X-Neon-Ret-Request-Id:
- 5f52745db752fe63d81b6fa30592bbf7
status:
code: 200
message: OK
- request:
body: null
headers:
Accept:
- application/json
Accept-Encoding:
- gzip, deflate
Connection:
- keep-alive
Content-Length:
- '0'
Content-Type:
- application/json
User-Agent:
- neon-client/python version=(0.1.0)
method: DELETE
uri: https://console.neon.tech/api/v2/projects/sweet-haze-98484788
response:
body:
string: '{"project":{"data_storage_bytes_hour":0,"data_transfer_bytes":0,"written_data_bytes":0,"compute_time_seconds":0,"active_time_seconds":0,"cpu_used_sec":0,"id":"sweet-haze-98484788","platform_id":"aws","region_id":"aws-us-east-2","name":"pytest-2613","provisioner":"k8s-neonvm","default_endpoint_settings":{"autoscaling_limit_min_cu":0.25,"autoscaling_limit_max_cu":0.25,"suspend_timeout_seconds":0},"settings":{"allowed_ips":{"ips":[],"primary_branch_only":false},"enable_logical_replication":false},"pg_version":15,"proxy_host":"us-east-2.aws.neon.tech","branch_logical_size_limit":3072,"branch_logical_size_limit_bytes":3221225472,"store_passwords":true,"creation_source":"console","history_retention_seconds":604800,"created_at":"2024-01-24T13:55:29Z","updated_at":"2024-01-24T13:55:32Z","synthetic_storage_size":0,"consumption_period_start":"0001-01-01T00:00:00Z","consumption_period_end":"0001-01-01T00:00:00Z","owner_id":"838386f6-b5f1-4c3b-89a2-4f5a130ef3de"}}'
headers:
Connection:
- keep-alive
Content-Length:
- '966'
Content-Type:
- application/json
Date:
- Wed, 24 Jan 2024 13:55:40 GMT
Strict-Transport-Security:
- max-age=15724800; includeSubDomains
Vary:
- Origin
X-Neon-Ret-Request-Id:
- e1c6a5c4ef7e369a08c1dd73b3e9ef23
status:
code: 200
message: OK
- request:
body: '{"project": {"name": "pytest-4374"}}'
headers:
Accept:
- application/json
Accept-Encoding:
- gzip, deflate
Connection:
- keep-alive
Content-Length:
- '36'
Content-Type:
- application/json
User-Agent:
- neon-client/python version=(0.1.0)
method: POST
uri: https://console.neon.tech/api/v2/projects
response:
body:
string: '{"project":{"data_storage_bytes_hour":0,"data_transfer_bytes":0,"written_data_bytes":0,"compute_time_seconds":0,"active_time_seconds":0,"cpu_used_sec":0,"id":"white-sea-87434266","platform_id":"aws","region_id":"aws-us-east-2","name":"pytest-4374","provisioner":"k8s-neonvm","default_endpoint_settings":{"autoscaling_limit_min_cu":0.25,"autoscaling_limit_max_cu":0.25,"suspend_timeout_seconds":0},"settings":{"allowed_ips":{"ips":[],"primary_branch_only":false},"enable_logical_replication":false},"pg_version":15,"proxy_host":"us-east-2.aws.neon.tech","branch_logical_size_limit":3072,"branch_logical_size_limit_bytes":3221225472,"store_passwords":true,"creation_source":"console","history_retention_seconds":604800,"created_at":"2024-01-24T13:55:40Z","updated_at":"2024-01-24T13:55:40Z","consumption_period_start":"0001-01-01T00:00:00Z","consumption_period_end":"0001-01-01T00:00:00Z","owner_id":"838386f6-b5f1-4c3b-89a2-4f5a130ef3de"},"connection_uris":[{"connection_uri":"postgres://kennethreitz:3fP0zFQDMBIw@ep-lively-sound-a5ju8ula.us-east-2.aws.neon.tech/neondb","connection_parameters":{"database":"neondb","password":"3fP0zFQDMBIw","role":"kennethreitz","host":"ep-lively-sound-a5ju8ula.us-east-2.aws.neon.tech","pooler_host":"ep-lively-sound-a5ju8ula-pooler.us-east-2.aws.neon.tech"}}],"roles":[{"branch_id":"br-hidden-hill-a53agcv4","name":"kennethreitz","password":"3fP0zFQDMBIw","protected":false,"created_at":"2024-01-24T13:55:40Z","updated_at":"2024-01-24T13:55:40Z"}],"databases":[{"id":32636970,"branch_id":"br-hidden-hill-a53agcv4","name":"neondb","owner_name":"kennethreitz","created_at":"2024-01-24T13:55:40Z","updated_at":"2024-01-24T13:55:40Z"}],"operations":[{"id":"1e288547-1fbe-4fa6-b759-c11da496214c","project_id":"white-sea-87434266","branch_id":"br-hidden-hill-a53agcv4","action":"create_timeline","status":"running","failures_count":0,"created_at":"2024-01-24T13:55:40Z","updated_at":"2024-01-24T13:55:40Z","total_duration_ms":0},{"id":"97b30201-c34e-49a3-a7d9-fcd51013595e","project_id":"white-sea-87434266","branch_id":"br-hidden-hill-a53agcv4","endpoint_id":"ep-lively-sound-a5ju8ula","action":"start_compute","status":"scheduling","failures_count":0,"created_at":"2024-01-24T13:55:40Z","updated_at":"2024-01-24T13:55:40Z","total_duration_ms":0}],"branch":{"id":"br-hidden-hill-a53agcv4","project_id":"white-sea-87434266","name":"main","current_state":"init","pending_state":"ready","creation_source":"console","primary":true,"cpu_used_sec":0,"compute_time_seconds":0,"active_time_seconds":0,"written_data_bytes":0,"data_transfer_bytes":0,"created_at":"2024-01-24T13:55:40Z","updated_at":"2024-01-24T13:55:40Z"},"endpoints":[{"host":"ep-lively-sound-a5ju8ula.us-east-2.aws.neon.tech","id":"ep-lively-sound-a5ju8ula","project_id":"white-sea-87434266","branch_id":"br-hidden-hill-a53agcv4","autoscaling_limit_min_cu":0.25,"autoscaling_limit_max_cu":0.25,"region_id":"aws-us-east-2","type":"read_write","current_state":"init","pending_state":"active","settings":{},"pooler_enabled":false,"pooler_mode":"transaction","disabled":false,"passwordless_access":true,"creation_source":"console","created_at":"2024-01-24T13:55:40Z","updated_at":"2024-01-24T13:55:40Z","proxy_host":"us-east-2.aws.neon.tech","suspend_timeout_seconds":0,"provisioner":"k8s-neonvm"}]}'
headers:
Connection:
- keep-alive
Content-Type:
- application/json
Date:
- Wed, 24 Jan 2024 13:55:41 GMT
Strict-Transport-Security:
- max-age=15724800; includeSubDomains
Transfer-Encoding:
- chunked
Vary:
- Origin
X-Neon-Ret-Request-Id:
- 2dc7ab47633f1472b645f759c4b3b070
status:
code: 201
message: Created
- request:
body: null
headers:
Accept:
- application/json
Accept-Encoding:
- gzip, deflate
Connection:
- keep-alive
Content-Type:
- application/json
User-Agent:
- neon-client/python version=(0.1.0)
method: GET
uri: https://console.neon.tech/api/v2/projects/white-sea-87434266
response:
body:
string: '{"project":{"data_storage_bytes_hour":0,"data_transfer_bytes":0,"written_data_bytes":0,"compute_time_seconds":0,"active_time_seconds":0,"cpu_used_sec":0,"id":"white-sea-87434266","platform_id":"aws","region_id":"aws-us-east-2","name":"pytest-4374","provisioner":"k8s-neonvm","default_endpoint_settings":{"autoscaling_limit_min_cu":0.25,"autoscaling_limit_max_cu":0.25,"suspend_timeout_seconds":0},"settings":{"allowed_ips":{"ips":[],"primary_branch_only":false},"enable_logical_replication":false},"pg_version":15,"proxy_host":"us-east-2.aws.neon.tech","branch_logical_size_limit":3072,"branch_logical_size_limit_bytes":3221225472,"store_passwords":true,"creation_source":"console","history_retention_seconds":604800,"created_at":"2024-01-24T13:55:40Z","updated_at":"2024-01-24T13:55:40Z","synthetic_storage_size":0,"consumption_period_start":"2024-01-13T02:10:30Z","consumption_period_end":"2024-02-01T00:00:00Z","quota_reset_at":"2024-02-01T00:00:00Z","owner_id":"838386f6-b5f1-4c3b-89a2-4f5a130ef3de","owner":{"email":"me@kennethreitz.org","branches_limit":10,"subscription_type":"free"}}}'
headers:
Connection:
- keep-alive
Content-Length:
- '1092'
Content-Type:
- application/json
Date:
- Wed, 24 Jan 2024 13:55:41 GMT
Strict-Transport-Security:
- max-age=15724800; includeSubDomains
Vary:
- Origin
X-Neon-Ret-Request-Id:
- 9e21226f04691fffb98122626fe07196
status:
code: 200
message: OK
- request:
body: '{"project": {"name": "pytest-2492"}}'
headers:
Accept:
- application/json
Accept-Encoding:
- gzip, deflate
Connection:
- keep-alive
Content-Length:
- '36'
Content-Type:
- application/json
User-Agent:
- neon-client/python version=(0.1.0)
method: PATCH
uri: https://console.neon.tech/api/v2/projects/white-sea-87434266
response:
body:
string: '{"project":{"data_storage_bytes_hour":0,"data_transfer_bytes":0,"written_data_bytes":0,"compute_time_seconds":0,"active_time_seconds":0,"cpu_used_sec":0,"id":"white-sea-87434266","platform_id":"aws","region_id":"aws-us-east-2","name":"pytest-2492","provisioner":"k8s-neonvm","default_endpoint_settings":{"autoscaling_limit_min_cu":0.25,"autoscaling_limit_max_cu":0.25,"suspend_timeout_seconds":0},"settings":{"allowed_ips":{"ips":[],"primary_branch_only":false},"enable_logical_replication":false},"pg_version":15,"proxy_host":"us-east-2.aws.neon.tech","branch_logical_size_limit":3072,"branch_logical_size_limit_bytes":3221225472,"store_passwords":true,"creation_source":"console","history_retention_seconds":604800,"created_at":"2024-01-24T13:55:40Z","updated_at":"2024-01-24T13:55:41Z","synthetic_storage_size":0,"consumption_period_start":"0001-01-01T00:00:00Z","consumption_period_end":"0001-01-01T00:00:00Z","owner_id":"838386f6-b5f1-4c3b-89a2-4f5a130ef3de"},"operations":[]}'
headers:
Connection:
- keep-alive
Content-Length:
- '981'
Content-Type:
- application/json
Date:
- Wed, 24 Jan 2024 13:55:41 GMT
Strict-Transport-Security:
- max-age=15724800; includeSubDomains
Vary:
- Origin
X-Neon-Ret-Request-Id:
- f1eb5bf99fc70e6dd4329b6c2b9fce03
status:
code: 200
message: OK
- request:
body: null
headers:
Accept:
- application/json
Accept-Encoding:
- gzip, deflate
Connection:
- keep-alive
Content-Type:
- application/json
User-Agent:
- neon-client/python version=(0.1.0)
method: GET
uri: https://console.neon.tech/api/v2/projects
response:
body:
string: '{"projects":[{"id":"white-sea-87434266","platform_id":"aws","region_id":"aws-us-east-2","name":"pytest-2492","provisioner":"k8s-neonvm","default_endpoint_settings":{"autoscaling_limit_min_cu":0,"autoscaling_limit_max_cu":0,"suspend_timeout_seconds":0},"settings":{"allowed_ips":{"primary_branch_only":false},"enable_logical_replication":false},"pg_version":15,"proxy_host":"us-east-2.aws.neon.tech","branch_logical_size_limit":3072,"branch_logical_size_limit_bytes":3221225472,"store_passwords":true,"active_time":0,"cpu_used_sec":0,"creation_source":"console","created_at":"2024-01-24T13:55:40Z","updated_at":"2024-01-24T13:55:41Z","synthetic_storage_size":0,"quota_reset_at":"2024-02-01T00:00:00Z","owner_id":"838386f6-b5f1-4c3b-89a2-4f5a130ef3de"}],"pagination":{"cursor":"white-sea-87434266"}}'
headers:
Connection:
- keep-alive
Content-Length:
- '797'
Content-Type:
- application/json
Date:
- Wed, 24 Jan 2024 13:55:41 GMT
Strict-Transport-Security:
- max-age=15724800; includeSubDomains
Vary:
- Origin
X-Neon-Ret-Request-Id:
- c053cb0d9716657cafdb9f8dc4da5578
status:
code: 200
message: OK
- request:
body: null
headers:
Accept:
- application/json
Accept-Encoding:
- gzip, deflate
Connection:
- keep-alive
Content-Length:
- '0'
Content-Type:
- application/json
User-Agent:
- neon-client/python version=(0.1.0)
method: DELETE
uri: https://console.neon.tech/api/v2/projects/white-sea-87434266
response:
body:
string: '{"project":{"data_storage_bytes_hour":0,"data_transfer_bytes":0,"written_data_bytes":0,"compute_time_seconds":0,"active_time_seconds":0,"cpu_used_sec":0,"id":"white-sea-87434266","platform_id":"aws","region_id":"aws-us-east-2","name":"pytest-2492","provisioner":"k8s-neonvm","default_endpoint_settings":{"autoscaling_limit_min_cu":0.25,"autoscaling_limit_max_cu":0.25,"suspend_timeout_seconds":0},"settings":{"allowed_ips":{"ips":[],"primary_branch_only":false},"enable_logical_replication":false},"pg_version":15,"proxy_host":"us-east-2.aws.neon.tech","branch_logical_size_limit":3072,"branch_logical_size_limit_bytes":3221225472,"store_passwords":true,"creation_source":"console","history_retention_seconds":604800,"created_at":"2024-01-24T13:55:40Z","updated_at":"2024-01-24T13:55:41Z","synthetic_storage_size":0,"consumption_period_start":"0001-01-01T00:00:00Z","consumption_period_end":"0001-01-01T00:00:00Z","owner_id":"838386f6-b5f1-4c3b-89a2-4f5a130ef3de"}}'
headers:
Connection:
- keep-alive
Content-Length:
- '965'
Content-Type:
- application/json
Date:
- Wed, 24 Jan 2024 13:55:41 GMT
Strict-Transport-Security:
- max-age=15724800; includeSubDomains
Vary:
- Origin
X-Neon-Ret-Request-Id:
- 6a9cbfb294599c762388953bcbc4769a
status:
code: 200
message: OK
version: 1