From 65e4a4c9c451d14d2db086273a1cfca179e1eeac Mon Sep 17 00:00:00 2001 From: Vernon Keenan Date: Thu, 5 Aug 2021 12:37:53 -0700 Subject: [PATCH] tidy new version --- Makefile | 81 +- README.md | 2 +- api/auth/auth_client/auth_client.go | 4 +- .../auth_client/user/get_users_parameters.go | 2 +- .../auth_client/user/get_users_responses.go | 4 +- api/auth/auth_client/user/user_client.go | 2 +- api/auth/auth_models/address.go | 2 +- api/auth/auth_models/error.go | 2 +- api/auth/auth_models/response_meta.go | 6 +- api/auth/auth_models/tenant_user.go | 6 +- api/auth/auth_models/user.go | 8 +- api/auth/auth_models/user_response.go | 4 +- api/auth/auth_models/user_role.go | 6 +- .../auth0_client/auth/auth_client.go} | 44 +- .../auth/post_credentials_parameters.go | 142 + .../auth/post_credentials_responses.go | 268 + .../auth0_client/auth0_client.go} | 50 +- .../auth0_client/role/get_roles_parameters.go | 136 + .../auth0_client/role/get_roles_responses.go | 266 + .../role/post_role_users_parameters.go | 181 + .../role/post_role_users_responses.go | 217 + .../auth0_client/role/role_client.go} | 75 +- ...e_api_v2_users_user_id_roles_parameters.go | 181 + ...te_api_v2_users_user_id_roles_responses.go | 217 + .../user/get_user_by_email_parameters.go | 158 + .../user/get_user_by_email_responses.go | 227 + .../user/get_user_roles_parameters.go | 157 + .../user/get_user_roles_responses.go | 229 + .../auth0_client/user/get_users_parameters.go | 136 + .../auth0_client/user/get_users_responses.go | 227 + .../user/post_users_parameters.go | 160 + .../auth0_client/user/post_users_responses.go | 244 + api/auth0/auth0_client/user/user_client.go | 228 + api/auth0/auth0_models/credentials_request.go | 56 + .../auth0_models/credentials_response.go | 56 + .../auth0_models}/error.go | 11 +- api/auth0/auth0_models/new_user.go | 89 + api/auth0/auth0_models/role.go | 53 + api/auth0/auth0_models/role_response.go | 84 + api/auth0/auth0_models/role_users_request.go | 47 + api/auth0/auth0_models/user.go | 305 + api/auth0/auth0_models/user_request.go | 84 + api/auth0/auth0_models/user_roles_request.go | 47 + .../cors/account_options_parameters.go | 130 - .../cors/account_options_responses.go | 113 - .../cloud_client/hub/delete_hub_parameters.go | 165 - .../cloud_client/hub/delete_hub_responses.go | 270 - .../cloud_client/hub/get_hubs_parameters.go | 340 - .../cloud_client/hub/get_hubs_responses.go | 278 - .../cloud_client/hub/post_hubs_parameters.go | 155 - .../cloud_client/hub/post_hubs_responses.go | 278 - .../cloud_client/hub/put_hub_parameters.go | 155 - .../cloud_client/hub/put_hub_responses.go | 278 - api/cloud/cloud_models/error.go | 60 - api/cloud/cloud_models/hub.go | 93 - api/cloud/cloud_models/hub_request.go | 116 - api/cloud/cloud_models/response_meta.go | 84 - api/cloud/cloud_models/user.go | 376 - .../crm_client/accounts/accounts_client.go | 8 +- .../accounts/delete_account_parameters.go | 4 +- .../accounts/delete_account_responses.go | 4 +- .../get_accounts_observable_parameters.go | 4 +- .../get_accounts_observable_responses.go | 4 +- .../accounts/get_accounts_parameters.go | 4 +- .../accounts/get_accounts_responses.go | 4 +- .../accounts/post_accounts_parameters.go | 2 +- .../accounts/post_accounts_responses.go | 4 +- .../accounts/put_account_parameters.go | 2 +- .../accounts/put_account_responses.go | 4 +- .../crm_client/companies/companies_client.go | 4 +- .../get_companies_observable_parameters.go | 4 +- .../get_companies_observable_responses.go | 4 +- .../companies/get_companies_parameters.go | 4 +- .../companies/get_companies_responses.go | 4 +- .../companies/post_companies_parameters.go | 2 +- .../companies/post_companies_responses.go | 4 +- .../crm_client/contacts/contacts_client.go | 6 +- .../contacts/delete_contact_parameters.go | 4 +- .../contacts/delete_contact_responses.go | 4 +- .../get_contacts_observable_parameters.go | 4 +- .../get_contacts_observable_responses.go | 4 +- .../contacts/get_contacts_parameters.go | 4 +- .../contacts/get_contacts_responses.go | 4 +- .../contacts/post_contacts_parameters.go | 2 +- .../contacts/post_contacts_responses.go | 4 +- .../contacts/put_contacts_parameters.go | 2 +- .../contacts/put_contacts_responses.go | 4 +- .../account_options_observable_parameters.go | 2 +- .../account_options_observable_responses.go | 2 +- .../cors/account_options_parameters.go | 2 +- .../cors/account_options_responses.go | 2 +- .../company_observable_options_parameters.go | 2 +- .../company_observable_options_responses.go | 2 +- .../cors/company_options_parameters.go | 2 +- .../cors/company_options_responses.go | 2 +- .../contact_options_observable_parameters.go | 2 +- .../contact_options_observable_responses.go | 2 +- .../cors/contact_options_parameters.go | 2 +- .../cors/contact_options_responses.go | 2 +- api/crm/crm_client/cors/cors_client.go | 2 +- .../lead_options_observable_parameters.go | 2 +- .../cors/lead_options_observable_responses.go | 2 +- .../cors/lead_options_parameters.go | 2 +- .../crm_client/cors/lead_options_responses.go | 2 +- api/crm/crm_client/crm_client.go | 4 +- .../leads/delete_lead_parameters.go | 4 +- .../crm_client/leads/delete_lead_responses.go | 4 +- .../leads/get_leads_observable_parameters.go | 4 +- .../leads/get_leads_observable_responses.go | 4 +- .../crm_client/leads/get_leads_parameters.go | 4 +- .../crm_client/leads/get_leads_responses.go | 4 +- api/crm/crm_client/leads/leads_client.go | 6 +- .../crm_client/leads/post_leads_parameters.go | 2 +- .../crm_client/leads/post_leads_responses.go | 4 +- .../crm_client/leads/put_leads_parameters.go | 2 +- .../crm_client/leads/put_leads_responses.go | 4 +- api/crm/crm_models/account.go | 4 +- api/crm/crm_models/account_basic.go | 6 +- api/crm/crm_models/account_basic_response.go | 2 +- api/crm/crm_models/account_request.go | 2 +- api/crm/crm_models/account_response.go | 2 +- api/crm/crm_models/address.go | 2 +- api/crm/crm_models/company.go | 6 +- api/crm/crm_models/company_request.go | 2 +- api/crm/crm_models/company_response.go | 2 +- api/crm/crm_models/contact.go | 6 +- api/crm/crm_models/contact_request.go | 2 +- api/crm/crm_models/contact_response.go | 2 +- api/crm/crm_models/delete_response.go | 2 +- api/crm/crm_models/error.go | 2 +- api/crm/crm_models/invalid_error.go | 2 +- api/crm/crm_models/lead.go | 4 +- api/crm/crm_models/lead_request.go | 2 +- api/crm/crm_models/lead_response.go | 2 +- api/crm/crm_models/message.go | 2 +- api/crm/crm_models/pagination.go | 2 +- api/crm/crm_models/request_meta.go | 12 +- api/crm/crm_models/response_meta.go | 6 +- .../devops_client/cluster/cluster_client.go | 6 +- .../cluster/get_cluster_parameters.go | 4 +- .../cluster/get_cluster_responses.go | 2 +- .../get_clusters_observable_parameters.go | 2 +- .../get_clusters_observable_responses.go | 2 +- .../cluster/get_clusters_parameters.go | 6 +- .../cluster/get_clusters_responses.go | 4 +- .../cluster/post_clusters_parameters.go | 2 +- .../cluster/post_clusters_responses.go | 4 +- .../cluster/put_clusters_parameters.go | 2 +- .../cluster/put_clusters_responses.go | 4 +- .../cors/cluster_options_parameters.go | 2 +- .../cors/cluster_options_responses.go | 2 +- .../cors/clusters_options_parameters.go | 2 +- .../cors/clusters_options_responses.go | 2 +- api/devops/devops_client/cors/cors_client.go | 2 +- .../cors/database_options_parameters.go | 2 +- .../cors/database_options_responses.go | 2 +- .../cors/databases_options_parameters.go | 2 +- .../cors/databases_options_responses.go | 2 +- .../cors/ingest_options_parameters.go | 2 +- .../cors/ingest_options_responses.go | 2 +- .../cors/ingests_options_parameters.go | 2 +- .../cors/ingests_options_responses.go | 2 +- .../cors/job_options_parameters.go | 2 +- .../cors/job_options_responses.go | 2 +- .../cors/jobs_options_parameters.go | 2 +- .../cors/jobs_options_responses.go | 2 +- .../cors/service_options_parameters.go | 2 +- .../cors/service_options_responses.go | 2 +- .../cors/services_options_parameters.go | 2 +- .../cors/services_options_responses.go | 2 +- .../cors/template_options_parameters.go | 2 +- .../cors/template_options_responses.go | 2 +- .../cors/templates_options_parameters.go | 2 +- .../cors/templates_options_responses.go | 2 +- .../cors/tenant_options_parameters.go | 2 +- .../cors/tenant_options_responses.go | 2 +- .../cors/tenants_options_parameters.go | 2 +- .../cors/tenants_options_responses.go | 2 +- .../cors/user_options_parameters.go | 2 +- .../cors/user_options_responses.go | 2 +- .../cors/users_options_parameters.go | 2 +- .../cors/users_options_responses.go | 2 +- .../devops_client/database/database_client.go | 6 +- .../database/get_database_parameters.go | 4 +- .../database/get_database_responses.go | 2 +- .../get_databases_observable_parameters.go | 2 +- .../get_databases_observable_responses.go | 2 +- .../database/get_databases_parameters.go | 6 +- .../database/get_databases_responses.go | 4 +- .../database/post_databases_parameters.go | 2 +- .../database/post_databases_responses.go | 4 +- .../database/put_databases_parameters.go | 2 +- .../database/put_databases_responses.go | 4 +- api/devops/devops_client/devops_client.go | 2 +- .../ingest/get_ingest_parameters.go | 4 +- .../ingest/get_ingest_responses.go | 2 +- .../get_ingests_observable_parameters.go | 2 +- .../get_ingests_observable_responses.go | 2 +- .../ingest/get_ingests_parameters.go | 8 +- .../ingest/get_ingests_responses.go | 4 +- .../devops_client/ingest/ingest_client.go | 2 +- .../ingest/post_ingests_parameters.go | 2 +- .../ingest/post_ingests_responses.go | 4 +- .../ingest/put_ingests_parameters.go | 2 +- .../ingest/put_ingests_responses.go | 4 +- .../devops_client/job/get_job_parameters.go | 4 +- .../devops_client/job/get_job_responses.go | 2 +- .../job/get_jobs_observable_parameters.go | 2 +- .../job/get_jobs_observable_responses.go | 2 +- .../devops_client/job/get_jobs_parameters.go | 8 +- .../devops_client/job/get_jobs_responses.go | 4 +- api/devops/devops_client/job/job_client.go | 6 +- .../devops_client/job/post_jobs_parameters.go | 2 +- .../devops_client/job/post_jobs_responses.go | 4 +- .../devops_client/job/put_jobs_parameters.go | 2 +- .../devops_client/job/put_jobs_responses.go | 4 +- .../service/get_service_parameters.go | 4 +- .../service/get_service_responses.go | 2 +- .../get_services_observable_parameters.go | 2 +- .../get_services_observable_responses.go | 2 +- .../service/get_services_parameters.go | 2 +- .../service/get_services_responses.go | 4 +- .../service/post_services_parameters.go | 2 +- .../service/post_services_responses.go | 4 +- .../service/put_services_parameters.go | 2 +- .../service/put_services_responses.go | 4 +- .../devops_client/service/service_client.go | 6 +- .../template/get_template_parameters.go | 4 +- .../template/get_template_responses.go | 2 +- .../get_templates_observable_parameters.go | 2 +- .../get_templates_observable_responses.go | 2 +- .../template/get_templates_parameters.go | 2 +- .../template/get_templates_responses.go | 4 +- .../template/post_templates_parameters.go | 2 +- .../template/post_templates_responses.go | 4 +- .../devops_client/template/template_client.go | 2 +- .../tenant/get_tenant_parameters.go | 4 +- .../tenant/get_tenant_responses.go | 2 +- .../get_tenants_observable_parameters.go | 2 +- .../get_tenants_observable_responses.go | 2 +- .../tenant/get_tenants_parameters.go | 74 +- .../tenant/get_tenants_responses.go | 4 +- .../tenant/post_tenants_parameters.go | 2 +- .../tenant/post_tenants_responses.go | 4 +- .../tenant/put_tenants_parameters.go | 2 +- .../tenant/put_tenants_responses.go | 4 +- .../devops_client/tenant/tenant_client.go | 6 +- .../devops_client/user/get_user_parameters.go | 4 +- .../devops_client/user/get_user_responses.go | 2 +- .../user/get_users_observable_parameters.go | 2 +- .../user/get_users_observable_responses.go | 2 +- .../user/get_users_parameters.go | 8 +- .../devops_client/user/get_users_responses.go | 4 +- .../user/post_users_parameters.go | 2 +- .../user/post_users_responses.go | 4 +- .../user/put_users_parameters.go | 2 +- .../devops_client/user/put_users_responses.go | 4 +- api/devops/devops_client/user/user_client.go | 2 +- api/devops/devops_models/address.go | 2 +- api/devops/devops_models/cluster.go | 4 +- api/devops/devops_models/cluster_request.go | 2 +- api/devops/devops_models/cluster_response.go | 2 +- api/devops/devops_models/database.go | 4 +- api/devops/devops_models/database_request.go | 2 +- api/devops/devops_models/database_response.go | 2 +- api/devops/devops_models/delete_response.go | 2 +- api/devops/devops_models/error.go | 2 +- api/devops/devops_models/ingest.go | 8 +- api/devops/devops_models/ingest_request.go | 2 +- api/devops/devops_models/ingest_response.go | 2 +- api/devops/devops_models/job.go | 14 +- api/devops/devops_models/job_request.go | 2 +- api/devops/devops_models/job_response.go | 2 +- api/devops/devops_models/message.go | 2 +- api/devops/devops_models/pagination.go | 2 +- api/devops/devops_models/request_meta.go | 12 +- api/devops/devops_models/response_meta.go | 6 +- api/devops/devops_models/role.go | 2 +- api/devops/devops_models/role_request.go | 2 +- api/devops/devops_models/role_response.go | 2 +- api/devops/devops_models/service.go | 4 +- api/devops/devops_models/service_request.go | 2 +- api/devops/devops_models/service_response.go | 2 +- api/devops/devops_models/template.go | 4 +- api/devops/devops_models/template_request.go | 2 +- api/devops/devops_models/template_response.go | 2 +- api/devops/devops_models/tenant.go | 4 +- api/devops/devops_models/tenant_request.go | 2 +- api/devops/devops_models/tenant_response.go | 2 +- api/devops/devops_models/tenant_user.go | 6 +- api/devops/devops_models/user.go | 8 +- api/devops/devops_models/user_request.go | 2 +- api/devops/devops_models/user_response.go | 2 +- api/devops/devops_models/user_role.go | 6 +- api/isp/isp_client/isp_client.go | 116 - .../isp_client/zone/get_zones_parameters.go | 253 - .../isp_client/zone/get_zones_responses.go | 363 - api/isp/isp_models/registrar.go | 87 - api/isp/isp_models/response_meta.go | 84 - api/isp/isp_models/zone.go | 102 - .../kazoo_client/account/account_client.go | 125 - .../get_account_descendents_parameters.go | 150 - .../get_account_descendents_responses.go | 147 - .../account/get_accounts_responses.go | 147 - .../call_flow/call_flow_client.go | 84 - .../get_account_callflows_parameters.go | 150 - .../get_account_callflows_responses.go | 147 - .../cdr/get_account_c_d_rs_parameters.go | 203 - .../cdr/get_account_c_d_rs_responses.go | 147 - .../kazoo_client/device/device_client.go | 125 - .../device/get_account_devices_parameters.go | 150 - .../device/get_account_devices_responses.go | 147 - .../device/get_user_devices_parameters.go | 169 - .../device/get_user_devices_responses.go | 147 - .../group/get_account_groups_parameters.go | 150 - .../group/get_account_groups_responses.go | 147 - api/kazoo/kazoo_client/group/group_client.go | 84 - api/kazoo/kazoo_client/kazoo_client.go | 161 - .../media/get_account_media_parameters.go | 150 - .../media/get_account_media_responses.go | 147 - api/kazoo/kazoo_client/media/media_client.go | 84 - .../menu/get_account_menus_parameters.go | 150 - .../menu/get_account_menus_responses.go | 147 - .../get_account_numbers_parameters.go | 150 - .../get_account_numbers_responses.go | 147 - .../get_kazoo_numbers_parameters.go | 198 - .../get_kazoo_numbers_responses.go | 147 - .../phone_number/phone_number_client.go | 125 - .../get_account_time_rules_parameters.go | 150 - .../get_account_time_rules_responses.go | 147 - .../user/get_account_users_parameters.go | 150 - .../user/get_account_users_responses.go | 147 - .../user/get_account_vm_boxes_parameters.go | 150 - .../user/get_account_vm_boxes_responses.go | 147 - .../get_account_callflow_response.go | 296 - .../kazoo_models/get_account_cdr_response.go | 309 - .../get_account_descendent_response.go | 202 - .../get_account_group_response.go | 193 - .../get_account_media_response.go | 201 - .../get_account_menus_response.go | 189 - .../kazoo_models/get_account_response.go | 3070 ------ .../get_account_time_rule_response.go | 189 - .../kazoo_models/get_account_user_response.go | 213 - .../get_account_vm_box_response.go | 201 - api/kazoo/kazoo_models/get_device_response.go | 209 - .../kazoo_models/get_kazoo_number_response.go | 181 - api/kazoo/kazoo_models/get_number_response.go | 369 - .../accounts/accounts_client.go} | 132 +- .../accounts}/get_accounts_parameters.go | 140 +- .../accounts/get_accounts_responses.go | 261 + .../accounts/post_accounts_parameters.go | 155 + .../accounts/post_accounts_responses.go | 223 + .../accounts/put_account_parameters.go | 155 + .../accounts/put_account_responses.go | 223 + .../companies/companies_client.go} | 30 +- .../companies/get_companies_parameters.go | 238 + .../companies/get_companies_responses.go | 261 + .../contacts/contacts_client.go} | 88 +- .../contacts/delete_contact_parameters.go | 165 + .../contacts/delete_contact_responses.go | 366 + .../contacts/get_contacts_parameters.go | 340 + .../contacts/get_contacts_responses.go | 261 + .../contacts/post_contacts_parameters.go | 155 + .../contacts/post_contacts_responses.go | 223 + .../contacts/put_contacts_parameters.go | 155 + .../contacts/put_contacts_responses.go | 223 + .../notebooks/get_notebooks_parameters.go | 238 + .../notebooks/get_notebooks_responses.go | 261 + .../notebooks/notebooks_client.go} | 68 +- .../notebooks/post_notebooks_parameters.go | 155 + .../notebooks/post_notebooks_responses.go | 261 + .../notebooks/put_notebooks_parameters.go | 155 + .../notebooks/put_notebooks_responses.go | 261 + .../products/get_products_parameters.go | 272 + .../products/get_products_responses.go | 261 + .../products/products_client.go} | 30 +- .../roles/get_roles_parameters.go | 238 + .../roles/get_roles_responses.go | 261 + .../sfgate_client/roles/roles_client.go} | 28 +- .../sfgate_client/sfgate_client.go} | 94 +- .../templates/get_templates_parameters.go | 238 + .../templates/get_templates_responses.go | 261 + .../templates/templates_client.go} | 30 +- .../tenants/get_tenants_parameters.go | 272 + .../tenants/get_tenants_responses.go | 261 + .../tenants/put_tenants_parameters.go | 155 + .../tenants/put_tenants_responses.go | 261 + .../sfgate_client/tenants/tenants_client.go} | 134 +- .../tenants/tenants_parameters.go | 155 + .../tenants/tenants_responses.go | 261 + .../users}/get_users_parameters.go | 147 +- .../users}/get_users_responses.go | 44 +- .../sfgate_client/users/users_client.go} | 12 +- api/sfgate/sfgate_models/account.go | 482 + .../sfgate_models/account_request.go} | 44 +- api/sfgate/sfgate_models/account_response.go | 158 + .../sfgate_models}/address.go | 53 +- api/sfgate/sfgate_models/authority.go | 138 + .../sfgate_models}/authority_request.go | 52 +- .../sfgate_models}/authority_response.go | 18 +- api/sfgate/sfgate_models/company.go | 260 + api/sfgate/sfgate_models/company_response.go | 158 + api/sfgate/sfgate_models/contact.go | 275 + api/sfgate/sfgate_models/contact_request.go | 163 + .../sfgate_models/contact_response.go} | 44 +- api/sfgate/sfgate_models/contract_basic.go | 93 + .../sfgate_models}/error.go | 4 +- api/sfgate/sfgate_models/ids.go | 31 + api/sfgate/sfgate_models/ids_request.go | 151 + api/sfgate/sfgate_models/invalid_error.go | 121 + .../sfgate_models}/message.go | 7 +- api/sfgate/sfgate_models/notebook.go | 164 + api/sfgate/sfgate_models/notebook_item.go | 66 + api/sfgate/sfgate_models/notebook_request.go | 158 + .../sfgate_models/notebook_response.go} | 44 +- api/sfgate/sfgate_models/pagination.go | 66 + api/sfgate/sfgate_models/product.go | 168 + .../sfgate_models/product_request.go} | 44 +- .../sfgate_models/product_response.go} | 44 +- api/sfgate/sfgate_models/request_meta.go | 75 + api/sfgate/sfgate_models/response_meta.go | 143 + api/sfgate/sfgate_models/role.go | 78 + .../sfgate_models/role_request.go} | 44 +- .../sfgate_models/role_response.go} | 34 +- api/sfgate/sfgate_models/template.go | 100 + api/sfgate/sfgate_models/template_response.go | 158 + api/sfgate/sfgate_models/tenant.go | 202 + .../sfgate_models/tenant_request.go} | 44 +- api/sfgate/sfgate_models/tenant_response.go | 158 + .../sfgate_models}/tenant_user.go | 51 +- api/sfgate/sfgate_models/user.go | 376 + .../sfgate_models}/user_response.go | 18 +- .../sfgate_models}/user_role.go | 40 +- api/stash/stash_client/stash_client.go | 4 +- .../stash_pdf/post_pdfs_parameters.go | 2 +- .../stash_pdf/post_pdfs_responses.go | 2 +- .../stash_pdf/stash_pdf_client.go | 2 +- api/stash/stash_models/document.go | 2 +- api/stash/stash_models/document_response.go | 2 +- api/stash/stash_models/error.go | 2 +- api/stash/stash_models/new_p_d_f.go | 2 +- api/stash/stash_models/p_d_f_request.go | 2 +- api/stash/stash_models/request_meta.go | 12 +- api/stash/stash_models/response_meta.go | 6 +- .../voip_client/authority/authority_client.go | 172 - .../authority/get_authorities_parameters.go | 253 - .../authority/get_authorities_responses.go | 261 - .../authority/post_authorities_parameters.go | 155 - .../authority/post_authorities_responses.go | 261 - .../authority/put_authorities_parameters.go | 155 - .../authority/put_authorities_responses.go | 261 - .../endpoint/get_endpoints_parameters.go | 253 - .../endpoint/get_endpoints_responses.go | 261 - .../endpoint/post_endpoints_parameters.go | 155 - .../endpoint/post_endpoints_responses.go | 261 - .../endpoint/put_endpoints_parameters.go | 155 - .../endpoint/put_endpoints_responses.go | 261 - .../voip_client/pbx/get_p_b_xes_parameters.go | 253 - .../voip_client/pbx/get_p_b_xes_responses.go | 261 - api/voip/voip_client/pbx/pbx_client.go | 172 - .../pbx/post_p_b_xes_parameters.go | 155 - .../voip_client/pbx/post_p_b_xes_responses.go | 261 - .../voip_client/pbx/put_p_b_xes_parameters.go | 155 - .../voip_client/pbx/put_p_b_xes_responses.go | 261 - .../pbx_user/get_p_b_x_users_parameters.go | 253 - .../pbx_user/get_p_b_x_users_responses.go | 261 - .../pbx_user/p_b_x_users_parameters.go | 155 - .../pbx_user/p_b_x_users_responses.go | 261 - .../pbx_user/post_p_b_x_users_parameters.go | 155 - .../pbx_user/post_p_b_x_users_responses.go | 261 - .../get_phone_numbers_parameters.go | 253 - .../get_phone_numbers_responses.go | 261 - .../phone_number/phone_number_client.go | 172 - .../post_phone_numbers_parameters.go | 155 - .../post_phone_numbers_responses.go | 261 - .../put_phone_numbers_parameters.go | 155 - .../put_phone_numbers_responses.go | 261 - .../queue/get_queues_parameters.go | 253 - .../voip_client/queue/get_queues_responses.go | 261 - .../queue/post_queues_parameters.go | 155 - .../queue/post_queues_responses.go | 261 - .../queue/put_queues_parameters.go | 155 - .../voip_client/queue/put_queues_responses.go | 261 - api/voip/voip_client/queue/queue_client.go | 172 - .../vm_box/get_vm_boxes_parameters.go | 253 - .../vm_box/get_vm_boxes_responses.go | 261 - .../vm_box/post_vm_boxes_parameters.go | 155 - .../vm_box/post_vm_boxes_responses.go | 261 - .../vm_box/put_vm_boxes_parameters.go | 155 - .../vm_box/put_vm_boxes_responses.go | 261 - api/voip/voip_models/authority.go | 141 - api/voip/voip_models/call_flow_action.go | 92 - api/voip/voip_models/callflow.go | 249 - api/voip/voip_models/endpoint.go | 141 - api/voip/voip_models/endpoint_request.go | 116 - api/voip/voip_models/error.go | 60 - api/voip/voip_models/pbx.go | 120 - api/voip/voip_models/pbx_request.go | 116 - api/voip/voip_models/pbx_user.go | 108 - api/voip/voip_models/pbx_user_request.go | 116 - api/voip/voip_models/phone_number.go | 132 - api/voip/voip_models/phone_number_request.go | 116 - api/voip/voip_models/phone_number_response.go | 158 - api/voip/voip_models/queue.go | 90 - api/voip/voip_models/queue_request.go | 116 - api/voip/voip_models/recipient.go | 134 - api/voip/voip_models/recipient_request.go | 116 - api/voip/voip_models/recipient_response.go | 158 - api/voip/voip_models/recipient_stats.go | 72 - api/voip/voip_models/response_meta.go | 84 - api/voip/voip_models/vm_box.go | 93 - api/voip/voip_models/vm_box_request.go | 116 - .../workflow_client/app_log/app_log_client.go | 2 +- .../app_log/post_app_logs_parameters.go | 2 +- .../app_log/post_app_logs_responses.go | 2 +- .../cors/app_log_options_parameters.go | 2 +- .../cors/app_log_options_responses.go | 2 +- .../workflow_client/cors/cors_client.go | 2 +- .../cors/email_message_options_parameters.go | 2 +- .../cors/email_message_options_responses.go | 2 +- ...tgoing_email_message_options_parameters.go | 2 +- ...utgoing_email_message_options_responses.go | 2 +- .../email_message/email_message_client.go | 2 +- .../get_email_messages_parameters.go | 2 +- .../get_email_messages_responses.go | 2 +- .../outgoing_email_message_client.go | 2 +- ...post_outgoing_email_messages_parameters.go | 2 +- .../post_outgoing_email_messages_responses.go | 2 +- .../workflow_client/workflow_client.go | 4 +- api/workflow/workflow_models/app_log.go | 2 +- .../workflow_models/app_log_request.go | 4 +- .../workflow_models/app_log_response.go | 4 +- api/workflow/workflow_models/document.go | 4 +- api/workflow/workflow_models/email_message.go | 2 +- .../workflow_models/email_message_request.go | 4 +- .../email_messages_response.go | 4 +- api/workflow/workflow_models/error.go | 2 +- api/workflow/workflow_models/headers.go | 2 +- .../workflow_models/outgoing_email_message.go | 2 +- .../outgoing_email_message_request.go | 4 +- api/workflow/workflow_models/request_meta.go | 12 +- api/workflow/workflow_models/response_meta.go | 6 +- app/address.go | 20 - app/auth.go | 39 - app/config.go | 217 - app/force.go | 26 - app/logger/logger.go | 43 - app/mysql.go | 29 - app/prometheus.go | 67 - app/root.go | 50 - app/tenantuser.go | 31 - app/user-helpers.go | 134 - app/user.go | 78 - app/userrole.go | 28 - build/COPYRIGHT | 2 +- go.mod | 8 +- go.sum | 486 - .../{auth-telnexus.yaml => auth-kvision.yaml} | 32 +- swagger/auth0.yaml | 494 + swagger/board-kvision.yaml | 1434 +++ swagger/cloud-telnexus.yaml | 699 -- .../{crm-telnexus.yaml => crm-kvision.yaml} | 80 +- ...vops-telnexus.yaml => devops-kvision.yaml} | 142 +- swagger/isp-telnexus.yaml | 286 - swagger/kazoo-telnexus.yaml | 1343 --- swagger/sf-gate-kvision.yaml | 2427 +++++ swagger/sf-gate-telnexus.yaml | 9169 ----------------- ...stash-telnexus.yaml => stash-kvision.yaml} | 22 +- swagger/voip-telnexus.yaml | 1507 --- ...ow-telnexus.yaml => workflow-kvision.yaml} | 32 +- 570 files changed, 21803 insertions(+), 43089 deletions(-) rename api/{kazoo/kazoo_client/menu/menu_client.go => auth0/auth0_client/auth/auth_client.go} (57%) create mode 100644 api/auth0/auth0_client/auth/post_credentials_parameters.go create mode 100644 api/auth0/auth0_client/auth/post_credentials_responses.go rename api/{cloud/cloud_client/cloud_client.go => auth0/auth0_client/auth0_client.go} (73%) create mode 100644 api/auth0/auth0_client/role/get_roles_parameters.go create mode 100644 api/auth0/auth0_client/role/get_roles_responses.go create mode 100644 api/auth0/auth0_client/role/post_role_users_parameters.go create mode 100644 api/auth0/auth0_client/role/post_role_users_responses.go rename api/{kazoo/kazoo_client/user/user_client.go => auth0/auth0_client/role/role_client.go} (50%) create mode 100644 api/auth0/auth0_client/user/delete_api_v2_users_user_id_roles_parameters.go create mode 100644 api/auth0/auth0_client/user/delete_api_v2_users_user_id_roles_responses.go create mode 100644 api/auth0/auth0_client/user/get_user_by_email_parameters.go create mode 100644 api/auth0/auth0_client/user/get_user_by_email_responses.go create mode 100644 api/auth0/auth0_client/user/get_user_roles_parameters.go create mode 100644 api/auth0/auth0_client/user/get_user_roles_responses.go create mode 100644 api/auth0/auth0_client/user/get_users_parameters.go create mode 100644 api/auth0/auth0_client/user/get_users_responses.go create mode 100644 api/auth0/auth0_client/user/post_users_parameters.go create mode 100644 api/auth0/auth0_client/user/post_users_responses.go create mode 100644 api/auth0/auth0_client/user/user_client.go create mode 100644 api/auth0/auth0_models/credentials_request.go create mode 100644 api/auth0/auth0_models/credentials_response.go rename api/{kazoo/kazoo_models => auth0/auth0_models}/error.go (81%) create mode 100644 api/auth0/auth0_models/new_user.go create mode 100644 api/auth0/auth0_models/role.go create mode 100644 api/auth0/auth0_models/role_response.go create mode 100644 api/auth0/auth0_models/role_users_request.go create mode 100644 api/auth0/auth0_models/user.go create mode 100644 api/auth0/auth0_models/user_request.go create mode 100644 api/auth0/auth0_models/user_roles_request.go delete mode 100644 api/cloud/cloud_client/cors/account_options_parameters.go delete mode 100644 api/cloud/cloud_client/cors/account_options_responses.go delete mode 100644 api/cloud/cloud_client/hub/delete_hub_parameters.go delete mode 100644 api/cloud/cloud_client/hub/delete_hub_responses.go delete mode 100644 api/cloud/cloud_client/hub/get_hubs_parameters.go delete mode 100644 api/cloud/cloud_client/hub/get_hubs_responses.go delete mode 100644 api/cloud/cloud_client/hub/post_hubs_parameters.go delete mode 100644 api/cloud/cloud_client/hub/post_hubs_responses.go delete mode 100644 api/cloud/cloud_client/hub/put_hub_parameters.go delete mode 100644 api/cloud/cloud_client/hub/put_hub_responses.go delete mode 100644 api/cloud/cloud_models/error.go delete mode 100644 api/cloud/cloud_models/hub.go delete mode 100644 api/cloud/cloud_models/hub_request.go delete mode 100644 api/cloud/cloud_models/response_meta.go delete mode 100644 api/cloud/cloud_models/user.go delete mode 100644 api/isp/isp_client/isp_client.go delete mode 100644 api/isp/isp_client/zone/get_zones_parameters.go delete mode 100644 api/isp/isp_client/zone/get_zones_responses.go delete mode 100644 api/isp/isp_models/registrar.go delete mode 100644 api/isp/isp_models/response_meta.go delete mode 100644 api/isp/isp_models/zone.go delete mode 100644 api/kazoo/kazoo_client/account/account_client.go delete mode 100644 api/kazoo/kazoo_client/account/get_account_descendents_parameters.go delete mode 100644 api/kazoo/kazoo_client/account/get_account_descendents_responses.go delete mode 100644 api/kazoo/kazoo_client/account/get_accounts_responses.go delete mode 100644 api/kazoo/kazoo_client/call_flow/call_flow_client.go delete mode 100644 api/kazoo/kazoo_client/call_flow/get_account_callflows_parameters.go delete mode 100644 api/kazoo/kazoo_client/call_flow/get_account_callflows_responses.go delete mode 100644 api/kazoo/kazoo_client/cdr/get_account_c_d_rs_parameters.go delete mode 100644 api/kazoo/kazoo_client/cdr/get_account_c_d_rs_responses.go delete mode 100644 api/kazoo/kazoo_client/device/device_client.go delete mode 100644 api/kazoo/kazoo_client/device/get_account_devices_parameters.go delete mode 100644 api/kazoo/kazoo_client/device/get_account_devices_responses.go delete mode 100644 api/kazoo/kazoo_client/device/get_user_devices_parameters.go delete mode 100644 api/kazoo/kazoo_client/device/get_user_devices_responses.go delete mode 100644 api/kazoo/kazoo_client/group/get_account_groups_parameters.go delete mode 100644 api/kazoo/kazoo_client/group/get_account_groups_responses.go delete mode 100644 api/kazoo/kazoo_client/group/group_client.go delete mode 100644 api/kazoo/kazoo_client/kazoo_client.go delete mode 100644 api/kazoo/kazoo_client/media/get_account_media_parameters.go delete mode 100644 api/kazoo/kazoo_client/media/get_account_media_responses.go delete mode 100644 api/kazoo/kazoo_client/media/media_client.go delete mode 100644 api/kazoo/kazoo_client/menu/get_account_menus_parameters.go delete mode 100644 api/kazoo/kazoo_client/menu/get_account_menus_responses.go delete mode 100644 api/kazoo/kazoo_client/phone_number/get_account_numbers_parameters.go delete mode 100644 api/kazoo/kazoo_client/phone_number/get_account_numbers_responses.go delete mode 100644 api/kazoo/kazoo_client/phone_number/get_kazoo_numbers_parameters.go delete mode 100644 api/kazoo/kazoo_client/phone_number/get_kazoo_numbers_responses.go delete mode 100644 api/kazoo/kazoo_client/phone_number/phone_number_client.go delete mode 100644 api/kazoo/kazoo_client/time_rule/get_account_time_rules_parameters.go delete mode 100644 api/kazoo/kazoo_client/time_rule/get_account_time_rules_responses.go delete mode 100644 api/kazoo/kazoo_client/user/get_account_users_parameters.go delete mode 100644 api/kazoo/kazoo_client/user/get_account_users_responses.go delete mode 100644 api/kazoo/kazoo_client/user/get_account_vm_boxes_parameters.go delete mode 100644 api/kazoo/kazoo_client/user/get_account_vm_boxes_responses.go delete mode 100644 api/kazoo/kazoo_models/get_account_callflow_response.go delete mode 100644 api/kazoo/kazoo_models/get_account_cdr_response.go delete mode 100644 api/kazoo/kazoo_models/get_account_descendent_response.go delete mode 100644 api/kazoo/kazoo_models/get_account_group_response.go delete mode 100644 api/kazoo/kazoo_models/get_account_media_response.go delete mode 100644 api/kazoo/kazoo_models/get_account_menus_response.go delete mode 100644 api/kazoo/kazoo_models/get_account_response.go delete mode 100644 api/kazoo/kazoo_models/get_account_time_rule_response.go delete mode 100644 api/kazoo/kazoo_models/get_account_user_response.go delete mode 100644 api/kazoo/kazoo_models/get_account_vm_box_response.go delete mode 100644 api/kazoo/kazoo_models/get_device_response.go delete mode 100644 api/kazoo/kazoo_models/get_kazoo_number_response.go delete mode 100644 api/kazoo/kazoo_models/get_number_response.go rename api/{voip/voip_client/pbx_user/pbx_user_client.go => sfgate/sfgate_client/accounts/accounts_client.go} (62%) rename api/{kazoo/kazoo_client/account => sfgate/sfgate_client/accounts}/get_accounts_parameters.go (60%) create mode 100644 api/sfgate/sfgate_client/accounts/get_accounts_responses.go create mode 100644 api/sfgate/sfgate_client/accounts/post_accounts_parameters.go create mode 100644 api/sfgate/sfgate_client/accounts/post_accounts_responses.go create mode 100644 api/sfgate/sfgate_client/accounts/put_account_parameters.go create mode 100644 api/sfgate/sfgate_client/accounts/put_account_responses.go rename api/{kazoo/kazoo_client/cdr/cdr_client.go => sfgate/sfgate_client/companies/companies_client.go} (65%) create mode 100644 api/sfgate/sfgate_client/companies/get_companies_parameters.go create mode 100644 api/sfgate/sfgate_client/companies/get_companies_responses.go rename api/{cloud/cloud_client/hub/hub_client.go => sfgate/sfgate_client/contacts/contacts_client.go} (57%) create mode 100644 api/sfgate/sfgate_client/contacts/delete_contact_parameters.go create mode 100644 api/sfgate/sfgate_client/contacts/delete_contact_responses.go create mode 100644 api/sfgate/sfgate_client/contacts/get_contacts_parameters.go create mode 100644 api/sfgate/sfgate_client/contacts/get_contacts_responses.go create mode 100644 api/sfgate/sfgate_client/contacts/post_contacts_parameters.go create mode 100644 api/sfgate/sfgate_client/contacts/post_contacts_responses.go create mode 100644 api/sfgate/sfgate_client/contacts/put_contacts_parameters.go create mode 100644 api/sfgate/sfgate_client/contacts/put_contacts_responses.go create mode 100644 api/sfgate/sfgate_client/notebooks/get_notebooks_parameters.go create mode 100644 api/sfgate/sfgate_client/notebooks/get_notebooks_responses.go rename api/{voip/voip_client/endpoint/endpoint_client.go => sfgate/sfgate_client/notebooks/notebooks_client.go} (62%) create mode 100644 api/sfgate/sfgate_client/notebooks/post_notebooks_parameters.go create mode 100644 api/sfgate/sfgate_client/notebooks/post_notebooks_responses.go create mode 100644 api/sfgate/sfgate_client/notebooks/put_notebooks_parameters.go create mode 100644 api/sfgate/sfgate_client/notebooks/put_notebooks_responses.go create mode 100644 api/sfgate/sfgate_client/products/get_products_parameters.go create mode 100644 api/sfgate/sfgate_client/products/get_products_responses.go rename api/{cloud/cloud_client/cors/cors_client.go => sfgate/sfgate_client/products/products_client.go} (66%) create mode 100644 api/sfgate/sfgate_client/roles/get_roles_parameters.go create mode 100644 api/sfgate/sfgate_client/roles/get_roles_responses.go rename api/{isp/isp_client/zone/zone_client.go => sfgate/sfgate_client/roles/roles_client.go} (73%) rename api/{voip/voip_client/voip_client.go => sfgate/sfgate_client/sfgate_client.go} (54%) create mode 100644 api/sfgate/sfgate_client/templates/get_templates_parameters.go create mode 100644 api/sfgate/sfgate_client/templates/get_templates_responses.go rename api/{kazoo/kazoo_client/time_rule/time_rule_client.go => sfgate/sfgate_client/templates/templates_client.go} (65%) create mode 100644 api/sfgate/sfgate_client/tenants/get_tenants_parameters.go create mode 100644 api/sfgate/sfgate_client/tenants/get_tenants_responses.go create mode 100644 api/sfgate/sfgate_client/tenants/put_tenants_parameters.go create mode 100644 api/sfgate/sfgate_client/tenants/put_tenants_responses.go rename api/{voip/voip_client/vm_box/vm_box_client.go => sfgate/sfgate_client/tenants/tenants_client.go} (62%) create mode 100644 api/sfgate/sfgate_client/tenants/tenants_parameters.go create mode 100644 api/sfgate/sfgate_client/tenants/tenants_responses.go rename api/{cloud/cloud_client/user => sfgate/sfgate_client/users}/get_users_parameters.go (61%) rename api/{cloud/cloud_client/user => sfgate/sfgate_client/users}/get_users_responses.go (86%) rename api/{cloud/cloud_client/user/user_client.go => sfgate/sfgate_client/users/users_client.go} (92%) create mode 100644 api/sfgate/sfgate_models/account.go rename api/{cloud/cloud_models/delete_response.go => sfgate/sfgate_models/account_request.go} (68%) create mode 100644 api/sfgate/sfgate_models/account_response.go rename api/{cloud/cloud_models => sfgate/sfgate_models}/address.go (53%) create mode 100644 api/sfgate/sfgate_models/authority.go rename api/{voip/voip_models => sfgate/sfgate_models}/authority_request.go (68%) rename api/{voip/voip_models => sfgate/sfgate_models}/authority_response.go (89%) create mode 100644 api/sfgate/sfgate_models/company.go create mode 100644 api/sfgate/sfgate_models/company_response.go create mode 100644 api/sfgate/sfgate_models/contact.go create mode 100644 api/sfgate/sfgate_models/contact_request.go rename api/{voip/voip_models/pbx_user_response.go => sfgate/sfgate_models/contact_response.go} (67%) create mode 100644 api/sfgate/sfgate_models/contract_basic.go rename api/{isp/isp_models => sfgate/sfgate_models}/error.go (95%) create mode 100644 api/sfgate/sfgate_models/ids.go create mode 100644 api/sfgate/sfgate_models/ids_request.go create mode 100644 api/sfgate/sfgate_models/invalid_error.go rename api/{cloud/cloud_models => sfgate/sfgate_models}/message.go (91%) create mode 100644 api/sfgate/sfgate_models/notebook.go create mode 100644 api/sfgate/sfgate_models/notebook_item.go create mode 100644 api/sfgate/sfgate_models/notebook_request.go rename api/{voip/voip_models/endpoint_response.go => sfgate/sfgate_models/notebook_response.go} (67%) create mode 100644 api/sfgate/sfgate_models/pagination.go create mode 100644 api/sfgate/sfgate_models/product.go rename api/{voip/voip_models/vm_box_response.go => sfgate/sfgate_models/product_request.go} (65%) rename api/{voip/voip_models/pbx_response.go => sfgate/sfgate_models/product_response.go} (65%) create mode 100644 api/sfgate/sfgate_models/request_meta.go create mode 100644 api/sfgate/sfgate_models/response_meta.go create mode 100644 api/sfgate/sfgate_models/role.go rename api/{cloud/cloud_models/hub_response.go => sfgate/sfgate_models/role_request.go} (68%) rename api/{isp/isp_models/zone_response.go => sfgate/sfgate_models/role_response.go} (75%) create mode 100644 api/sfgate/sfgate_models/template.go create mode 100644 api/sfgate/sfgate_models/template_response.go create mode 100644 api/sfgate/sfgate_models/tenant.go rename api/{voip/voip_models/queue_response.go => sfgate/sfgate_models/tenant_request.go} (68%) create mode 100644 api/sfgate/sfgate_models/tenant_response.go rename api/{cloud/cloud_models => sfgate/sfgate_models}/tenant_user.go (50%) create mode 100644 api/sfgate/sfgate_models/user.go rename api/{cloud/cloud_models => sfgate/sfgate_models}/user_response.go (88%) rename api/{cloud/cloud_models => sfgate/sfgate_models}/user_role.go (58%) delete mode 100644 api/voip/voip_client/authority/authority_client.go delete mode 100644 api/voip/voip_client/authority/get_authorities_parameters.go delete mode 100644 api/voip/voip_client/authority/get_authorities_responses.go delete mode 100644 api/voip/voip_client/authority/post_authorities_parameters.go delete mode 100644 api/voip/voip_client/authority/post_authorities_responses.go delete mode 100644 api/voip/voip_client/authority/put_authorities_parameters.go delete mode 100644 api/voip/voip_client/authority/put_authorities_responses.go delete mode 100644 api/voip/voip_client/endpoint/get_endpoints_parameters.go delete mode 100644 api/voip/voip_client/endpoint/get_endpoints_responses.go delete mode 100644 api/voip/voip_client/endpoint/post_endpoints_parameters.go delete mode 100644 api/voip/voip_client/endpoint/post_endpoints_responses.go delete mode 100644 api/voip/voip_client/endpoint/put_endpoints_parameters.go delete mode 100644 api/voip/voip_client/endpoint/put_endpoints_responses.go delete mode 100644 api/voip/voip_client/pbx/get_p_b_xes_parameters.go delete mode 100644 api/voip/voip_client/pbx/get_p_b_xes_responses.go delete mode 100644 api/voip/voip_client/pbx/pbx_client.go delete mode 100644 api/voip/voip_client/pbx/post_p_b_xes_parameters.go delete mode 100644 api/voip/voip_client/pbx/post_p_b_xes_responses.go delete mode 100644 api/voip/voip_client/pbx/put_p_b_xes_parameters.go delete mode 100644 api/voip/voip_client/pbx/put_p_b_xes_responses.go delete mode 100644 api/voip/voip_client/pbx_user/get_p_b_x_users_parameters.go delete mode 100644 api/voip/voip_client/pbx_user/get_p_b_x_users_responses.go delete mode 100644 api/voip/voip_client/pbx_user/p_b_x_users_parameters.go delete mode 100644 api/voip/voip_client/pbx_user/p_b_x_users_responses.go delete mode 100644 api/voip/voip_client/pbx_user/post_p_b_x_users_parameters.go delete mode 100644 api/voip/voip_client/pbx_user/post_p_b_x_users_responses.go delete mode 100644 api/voip/voip_client/phone_number/get_phone_numbers_parameters.go delete mode 100644 api/voip/voip_client/phone_number/get_phone_numbers_responses.go delete mode 100644 api/voip/voip_client/phone_number/phone_number_client.go delete mode 100644 api/voip/voip_client/phone_number/post_phone_numbers_parameters.go delete mode 100644 api/voip/voip_client/phone_number/post_phone_numbers_responses.go delete mode 100644 api/voip/voip_client/phone_number/put_phone_numbers_parameters.go delete mode 100644 api/voip/voip_client/phone_number/put_phone_numbers_responses.go delete mode 100644 api/voip/voip_client/queue/get_queues_parameters.go delete mode 100644 api/voip/voip_client/queue/get_queues_responses.go delete mode 100644 api/voip/voip_client/queue/post_queues_parameters.go delete mode 100644 api/voip/voip_client/queue/post_queues_responses.go delete mode 100644 api/voip/voip_client/queue/put_queues_parameters.go delete mode 100644 api/voip/voip_client/queue/put_queues_responses.go delete mode 100644 api/voip/voip_client/queue/queue_client.go delete mode 100644 api/voip/voip_client/vm_box/get_vm_boxes_parameters.go delete mode 100644 api/voip/voip_client/vm_box/get_vm_boxes_responses.go delete mode 100644 api/voip/voip_client/vm_box/post_vm_boxes_parameters.go delete mode 100644 api/voip/voip_client/vm_box/post_vm_boxes_responses.go delete mode 100644 api/voip/voip_client/vm_box/put_vm_boxes_parameters.go delete mode 100644 api/voip/voip_client/vm_box/put_vm_boxes_responses.go delete mode 100644 api/voip/voip_models/authority.go delete mode 100644 api/voip/voip_models/call_flow_action.go delete mode 100644 api/voip/voip_models/callflow.go delete mode 100644 api/voip/voip_models/endpoint.go delete mode 100644 api/voip/voip_models/endpoint_request.go delete mode 100644 api/voip/voip_models/error.go delete mode 100644 api/voip/voip_models/pbx.go delete mode 100644 api/voip/voip_models/pbx_request.go delete mode 100644 api/voip/voip_models/pbx_user.go delete mode 100644 api/voip/voip_models/pbx_user_request.go delete mode 100644 api/voip/voip_models/phone_number.go delete mode 100644 api/voip/voip_models/phone_number_request.go delete mode 100644 api/voip/voip_models/phone_number_response.go delete mode 100644 api/voip/voip_models/queue.go delete mode 100644 api/voip/voip_models/queue_request.go delete mode 100644 api/voip/voip_models/recipient.go delete mode 100644 api/voip/voip_models/recipient_request.go delete mode 100644 api/voip/voip_models/recipient_response.go delete mode 100644 api/voip/voip_models/recipient_stats.go delete mode 100644 api/voip/voip_models/response_meta.go delete mode 100644 api/voip/voip_models/vm_box.go delete mode 100644 api/voip/voip_models/vm_box_request.go delete mode 100644 app/address.go delete mode 100644 app/auth.go delete mode 100644 app/config.go delete mode 100644 app/force.go delete mode 100644 app/logger/logger.go delete mode 100644 app/mysql.go delete mode 100644 app/prometheus.go delete mode 100644 app/root.go delete mode 100644 app/tenantuser.go delete mode 100644 app/user-helpers.go delete mode 100644 app/user.go delete mode 100644 app/userrole.go rename swagger/{auth-telnexus.yaml => auth-kvision.yaml} (94%) create mode 100644 swagger/auth0.yaml create mode 100644 swagger/board-kvision.yaml delete mode 100644 swagger/cloud-telnexus.yaml rename swagger/{crm-telnexus.yaml => crm-kvision.yaml} (95%) rename swagger/{devops-telnexus.yaml => devops-kvision.yaml} (95%) delete mode 100644 swagger/isp-telnexus.yaml delete mode 100644 swagger/kazoo-telnexus.yaml create mode 100644 swagger/sf-gate-kvision.yaml delete mode 100644 swagger/sf-gate-telnexus.yaml rename swagger/{stash-telnexus.yaml => stash-kvision.yaml} (91%) delete mode 100644 swagger/voip-telnexus.yaml rename swagger/{workflow-telnexus.yaml => workflow-kvision.yaml} (94%) diff --git a/Makefile b/Makefile index 87ffe4d..ba4aff0 100644 --- a/Makefile +++ b/Makefile @@ -1,9 +1,9 @@ -TELNEXUS_BUILD_ENV ?= dev -TELNEXUS_GELF_URI ?= udp://packrat.noc.tnxs.net:12201 -TELNEXUS_REGISTRY_PRIV ?= hub.tnxs.net -TELNEXUS_REGISTRY_PUB ?= docker.io -TELNEXUS_REPO_NAME = lib -TELNEXUS_VERSION ?= 0.0.1 +VERNONKEENAN_BUILD_ENV ?= dev +VERNONKEENAN_GELF_URI ?= udp://packrat.noc.tnxs.net:12201 +VERNONKEENAN_REGISTRY_PRIV ?= hub.tnxs.net +VERNONKEENAN_REGISTRY_PUB ?= docker.io +VERNONKEENAN_REPO_NAME = lib +VERNONKEENAN_VERSION ?= 0.0.1 .PHONY: swagger @@ -12,13 +12,13 @@ swagger: # # generate auth0 client # - mkdir -p lib/auth0 + mkdir -p api/auth0 swagger generate client \ --log-output=./swagger/logs/generate-auth0-client.log \ --copyright-file=./build/COPYRIGHT \ --name=auth0 \ --spec=./swagger/auth0.yaml \ - --target=./lib/auth0 \ + --target=./api/auth0 \ --client-package=auth0-client \ --model-package=auth0-models # @@ -29,25 +29,12 @@ swagger: --log-output=./swagger/logs/generate-auth-client.log \ --copyright-file=./build/COPYRIGHT \ --name=auth \ - --spec=./swagger/auth-telnexus.yaml \ + --spec=./swagger/auth-kvision.yaml \ --target=./api/auth \ --client-package=auth-client \ --model-package=auth-models \ --principal=app.User # - # generate cloud client - # - mkdir api/cloud - swagger-new generate client \ - --log-output=./swagger/logs/generate-cloud-client.log \ - --copyright-file=./build/COPYRIGHT \ - --name=cloud \ - --spec=./swagger/cloud-telnexus.yaml \ - --target=./api/cloud \ - --client-package=cloud-client \ - --model-package=cloud-models \ - --principal=app.User - # # generate crm client # mkdir api/crm @@ -55,7 +42,7 @@ swagger: --log-output=./swagger/logs/generate-crm-client.log \ --copyright-file=./build/COPYRIGHT \ --name=crm \ - --spec=./swagger/crm-telnexus.yaml \ + --spec=./swagger/crm-kvision.yaml \ --target=./api/crm \ --client-package=crm-client \ --model-package=crm-models \ @@ -68,38 +55,12 @@ swagger: --log-output=./swagger/logs/generate-devops-client.log \ --copyright-file=./build/COPYRIGHT \ --name=devops \ - --spec=./swagger/devops-telnexus.yaml \ + --spec=./swagger/devops-kvision.yaml \ --target=./api/devops \ --client-package=devops-client \ --model-package=devops-models \ --principal=app.User # - # generate isp client - # - mkdir api/isp - swagger-new generate client \ - --log-output=./swagger/logs/generate-isp-client.log \ - --copyright-file=./build/COPYRIGHT \ - --name=isp \ - --spec=./swagger/isp-telnexus.yaml \ - --target=./api/isp \ - --client-package=isp-client \ - --model-package=isp-models \ - --principal=app.User - # - # generate kazoo client - # - mkdir api/kazoo - swagger-new generate client \ - --log-output=./swagger/logs/generate-kazoo-client.log \ - --copyright-file=./build/COPYRIGHT \ - --name=kazoo \ - --spec=./swagger/kazoo-telnexus.yaml \ - --target=./api/kazoo \ - --client-package=kazoo-client \ - --model-package=kazoo-models \ - --principal=app.User - # # generate stash client # mkdir api/stash @@ -107,23 +68,23 @@ swagger: --log-output=./swagger/logs/generate-stash-client.log \ --copyright-file=./build/COPYRIGHT \ --name=stash \ - --spec=./swagger/stash-telnexus.yaml \ + --spec=./swagger/stash-kvision.yaml \ --target=./api/stash \ --client-package=stash-client \ --model-package=stash-models \ --principal=app.User # - # generate voip client + # generate sfgate client # - mkdir api/voip + mkdir api/sfgate swagger-new generate client \ - --log-output=./swagger/logs/generate-voip-client.log \ + --log-output=./swagger/logs/generate-sfgate-client.log \ --copyright-file=./build/COPYRIGHT \ - --name=voip \ - --spec=./swagger/voip-telnexus.yaml \ - --target=./api/voip \ - --client-package=voip-client \ - --model-package=voip-models \ + --name=sfgate \ + --spec=./swagger/sf-gate-kvision.yaml \ + --target=./api/sfgate \ + --client-package=sfgate-client \ + --model-package=sfgate-models \ --principal=app.User # # generate workflow client @@ -133,7 +94,7 @@ swagger: --log-output=./swagger/logs/generate-workflow-client.log \ --copyright-file=./build/COPYRIGHT \ --name=workflow \ - --spec=./swagger/workflow-telnexus.yaml \ + --spec=./swagger/workflow-kvision.yaml \ --target=./api/workflow \ --client-package=workflow-client \ --model-package=workflow-models \ diff --git a/README.md b/README.md index 4222f40..aeb8463 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,3 @@ # lib -Telnexus Shared Libraries (go) +VernonKeenan/KVision Shared Libraries (go) diff --git a/api/auth/auth_client/auth_client.go b/api/auth/auth_client/auth_client.go index ab821e7..c0577d1 100644 --- a/api/auth/auth_client/auth_client.go +++ b/api/auth/auth_client/auth_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -23,7 +23,7 @@ var Default = NewHTTPClient(nil) const ( // DefaultHost is the default Host // found in Meta (info) section of spec file - DefaultHost string = "auth.infra.tnxs.net:8080" + DefaultHost string = "auth.vernonkeenan.com:8080" // DefaultBasePath is the default BasePath // found in Meta (info) section of spec file DefaultBasePath string = "/v1" diff --git a/api/auth/auth_client/user/get_users_parameters.go b/api/auth/auth_client/user/get_users_parameters.go index b24a54c..f52e4c1 100644 --- a/api/auth/auth_client/user/get_users_parameters.go +++ b/api/auth/auth_client/user/get_users_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/auth/auth_client/user/get_users_responses.go b/api/auth/auth_client/user/get_users_responses.go index 81b564a..f614810 100644 --- a/api/auth/auth_client/user/get_users_responses.go +++ b/api/auth/auth_client/user/get_users_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetUsersOK() *GetUsersOK { /* GetUsersOK describes a response with status code 200, with default header values. -Telnexus Response with User objects +Taxnexus Response with User objects */ type GetUsersOK struct { Payload *auth_models.UserResponse diff --git a/api/auth/auth_client/user/user_client.go b/api/auth/auth_client/user/user_client.go index 3d1a6e1..11d1983 100644 --- a/api/auth/auth_client/user/user_client.go +++ b/api/auth/auth_client/user/user_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/auth/auth_models/address.go b/api/auth/auth_models/address.go index 0d3985b..aef6b16 100644 --- a/api/auth/auth_models/address.go +++ b/api/auth/auth_models/address.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/auth/auth_models/error.go b/api/auth/auth_models/error.go index d293386..7f83fe8 100644 --- a/api/auth/auth_models/error.go +++ b/api/auth/auth_models/error.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/auth/auth_models/response_meta.go b/api/auth/auth_models/response_meta.go index 81ed986..0cee8ef 100644 --- a/api/auth/auth_models/response_meta.go +++ b/api/auth/auth_models/response_meta.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -51,8 +51,8 @@ type ResponseMeta struct { // Backend Server Timestamp ServerTimestamp string `json:"ServerTimestamp,omitempty"` - // Telnexus Account Number used for recording transactions - TelnexusAccount string `json:"TelnexusAccount,omitempty"` + // Taxnexus Account Number used for recording transactions + TaxnexusAccount string `json:"TaxnexusAccount,omitempty"` } // Validate validates this response meta diff --git a/api/auth/auth_models/tenant_user.go b/api/auth/auth_models/tenant_user.go index a6348ea..a5088d6 100644 --- a/api/auth/auth_models/tenant_user.go +++ b/api/auth/auth_models/tenant_user.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -36,8 +36,8 @@ type TenantUser struct { // Contact ID ContactID string `json:"ContactID,omitempty"` - // Telnexus Account - TelnexusAccount string `json:"TelnexusAccount,omitempty"` + // Taxnexus Account + TaxnexusAccount string `json:"TaxnexusAccount,omitempty"` // Tenant active? TenantActive bool `json:"TenantActive,omitempty"` diff --git a/api/auth/auth_models/user.go b/api/auth/auth_models/user.go index 75a1585..fe7592e 100644 --- a/api/auth/auth_models/user.go +++ b/api/auth/auth_models/user.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -95,7 +95,7 @@ type User struct { // Full Photo URL FullPhotoURL string `json:"FullPhotoURL,omitempty"` - // Telnexus ID + // Taxnexus ID ID string `json:"ID,omitempty"` // Active @@ -170,8 +170,8 @@ type User struct { // The time day starts StartOfDay string `json:"StartOfDay,omitempty"` - // Telnexus Account - TelnexusAccount string `json:"TelnexusAccount,omitempty"` + // Taxnexus Account + TaxnexusAccount string `json:"TaxnexusAccount,omitempty"` // Tenant ID associated with this user TenantID string `json:"TenantID,omitempty"` diff --git a/api/auth/auth_models/user_response.go b/api/auth/auth_models/user_response.go index 57bbcc5..1f1d527 100644 --- a/api/auth/auth_models/user_response.go +++ b/api/auth/auth_models/user_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -18,7 +18,7 @@ import ( "github.com/go-openapi/swag" ) -// UserResponse An array Telnexus user objects +// UserResponse An array Taxnexus user objects // // swagger:model UserResponse type UserResponse struct { diff --git a/api/auth/auth_models/user_role.go b/api/auth/auth_models/user_role.go index bdc196b..a4a3eeb 100644 --- a/api/auth/auth_models/user_role.go +++ b/api/auth/auth_models/user_role.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -45,8 +45,8 @@ type UserRole struct { // Role Name RoleName string `json:"RoleName,omitempty"` - // Telnexus Account Number - TelnexusAccount string `json:"TelnexusAccount,omitempty"` + // Taxnexus Account Number + TaxnexusAccount string `json:"TaxnexusAccount,omitempty"` // User Email Address UserEmail string `json:"UserEmail,omitempty"` diff --git a/api/kazoo/kazoo_client/menu/menu_client.go b/api/auth0/auth0_client/auth/auth_client.go similarity index 57% rename from api/kazoo/kazoo_client/menu/menu_client.go rename to api/auth0/auth0_client/auth/auth_client.go index db78ebe..c5ac8a8 100644 --- a/api/kazoo/kazoo_client/menu/menu_client.go +++ b/api/auth0/auth0_client/auth/auth_client.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package menu +package auth // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -16,65 +16,59 @@ import ( "github.com/go-openapi/strfmt" ) -// New creates a new menu API client. +// New creates a new auth API client. func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { return &Client{transport: transport, formats: formats} } /* -Client for menu API +Client for auth API */ type Client struct { transport runtime.ClientTransport formats strfmt.Registry } -// ClientOption is the option for Client methods -type ClientOption func(*runtime.ClientOperation) - // ClientService is the interface for Client methods type ClientService interface { - GetAccountMenus(params *GetAccountMenusParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountMenusOK, error) + PostCredentials(params *PostCredentialsParams) (*PostCredentialsOK, error) SetTransport(transport runtime.ClientTransport) } /* - GetAccountMenus get account menus API + PostCredentials posts to oauth token + + Get credential token */ -func (a *Client) GetAccountMenus(params *GetAccountMenusParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountMenusOK, error) { +func (a *Client) PostCredentials(params *PostCredentialsParams) (*PostCredentialsOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewGetAccountMenusParams() + params = NewPostCredentialsParams() } - op := &runtime.ClientOperation{ - ID: "getAccountMenus", - Method: "GET", - PathPattern: "/accounts/{accountId}/menus", + + result, err := a.transport.Submit(&runtime.ClientOperation{ + ID: "postCredentials", + Method: "POST", + PathPattern: "/oauth/token", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"https"}, Params: params, - Reader: &GetAccountMenusReader{formats: a.formats}, - AuthInfo: authInfo, + Reader: &PostCredentialsReader{formats: a.formats}, Context: params.Context, Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) + }) if err != nil { return nil, err } - success, ok := result.(*GetAccountMenusOK) + success, ok := result.(*PostCredentialsOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getAccountMenus: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for postCredentials: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } diff --git a/api/auth0/auth0_client/auth/post_credentials_parameters.go b/api/auth0/auth0_client/auth/post_credentials_parameters.go new file mode 100644 index 0000000..1c00403 --- /dev/null +++ b/api/auth0/auth0_client/auth/post_credentials_parameters.go @@ -0,0 +1,142 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package auth + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/auth0/auth0_models" +) + +// NewPostCredentialsParams creates a new PostCredentialsParams object +// with the default values initialized. +func NewPostCredentialsParams() *PostCredentialsParams { + var () + return &PostCredentialsParams{ + + timeout: cr.DefaultTimeout, + } +} + +// NewPostCredentialsParamsWithTimeout creates a new PostCredentialsParams object +// with the default values initialized, and the ability to set a timeout on a request +func NewPostCredentialsParamsWithTimeout(timeout time.Duration) *PostCredentialsParams { + var () + return &PostCredentialsParams{ + + timeout: timeout, + } +} + +// NewPostCredentialsParamsWithContext creates a new PostCredentialsParams object +// with the default values initialized, and the ability to set a context for a request +func NewPostCredentialsParamsWithContext(ctx context.Context) *PostCredentialsParams { + var () + return &PostCredentialsParams{ + + Context: ctx, + } +} + +// NewPostCredentialsParamsWithHTTPClient creates a new PostCredentialsParams object +// with the default values initialized, and the ability to set a custom HTTPClient for a request +func NewPostCredentialsParamsWithHTTPClient(client *http.Client) *PostCredentialsParams { + var () + return &PostCredentialsParams{ + HTTPClient: client, + } +} + +/*PostCredentialsParams contains all the parameters to send to the API endpoint +for the post credentials operation typically these are written to a http.Request +*/ +type PostCredentialsParams struct { + + /*CredentialsRequest + Get Authentation Token + + */ + CredentialsRequest *auth0_models.CredentialsRequest + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithTimeout adds the timeout to the post credentials params +func (o *PostCredentialsParams) WithTimeout(timeout time.Duration) *PostCredentialsParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the post credentials params +func (o *PostCredentialsParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the post credentials params +func (o *PostCredentialsParams) WithContext(ctx context.Context) *PostCredentialsParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the post credentials params +func (o *PostCredentialsParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the post credentials params +func (o *PostCredentialsParams) WithHTTPClient(client *http.Client) *PostCredentialsParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the post credentials params +func (o *PostCredentialsParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithCredentialsRequest adds the credentialsRequest to the post credentials params +func (o *PostCredentialsParams) WithCredentialsRequest(credentialsRequest *auth0_models.CredentialsRequest) *PostCredentialsParams { + o.SetCredentialsRequest(credentialsRequest) + return o +} + +// SetCredentialsRequest adds the credentialsRequest to the post credentials params +func (o *PostCredentialsParams) SetCredentialsRequest(credentialsRequest *auth0_models.CredentialsRequest) { + o.CredentialsRequest = credentialsRequest +} + +// WriteToRequest writes these params to a swagger request +func (o *PostCredentialsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.CredentialsRequest != nil { + if err := r.SetBodyParam(o.CredentialsRequest); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/auth0/auth0_client/auth/post_credentials_responses.go b/api/auth0/auth0_client/auth/post_credentials_responses.go new file mode 100644 index 0000000..a8b5500 --- /dev/null +++ b/api/auth0/auth0_client/auth/post_credentials_responses.go @@ -0,0 +1,268 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package auth + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/auth0/auth0_models" +) + +// PostCredentialsReader is a Reader for the PostCredentials structure. +type PostCredentialsReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *PostCredentialsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewPostCredentialsOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewPostCredentialsUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewPostCredentialsForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewPostCredentialsNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 422: + result := NewPostCredentialsUnprocessableEntity() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewPostCredentialsInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + + default: + return nil, runtime.NewAPIError("unknown error", response, response.Code()) + } +} + +// NewPostCredentialsOK creates a PostCredentialsOK with default headers values +func NewPostCredentialsOK() *PostCredentialsOK { + return &PostCredentialsOK{} +} + +/*PostCredentialsOK handles this case with default header values. + +Credentials response from Auth0 +*/ +type PostCredentialsOK struct { + Payload *auth0_models.CredentialsResponse +} + +func (o *PostCredentialsOK) Error() string { + return fmt.Sprintf("[POST /oauth/token][%d] postCredentialsOK %+v", 200, o.Payload) +} + +func (o *PostCredentialsOK) GetPayload() *auth0_models.CredentialsResponse { + return o.Payload +} + +func (o *PostCredentialsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.CredentialsResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostCredentialsUnauthorized creates a PostCredentialsUnauthorized with default headers values +func NewPostCredentialsUnauthorized() *PostCredentialsUnauthorized { + return &PostCredentialsUnauthorized{} +} + +/*PostCredentialsUnauthorized handles this case with default header values. + +Access Unauthorized, invalid API-KEY was used +*/ +type PostCredentialsUnauthorized struct { + Payload *auth0_models.Error +} + +func (o *PostCredentialsUnauthorized) Error() string { + return fmt.Sprintf("[POST /oauth/token][%d] postCredentialsUnauthorized %+v", 401, o.Payload) +} + +func (o *PostCredentialsUnauthorized) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *PostCredentialsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostCredentialsForbidden creates a PostCredentialsForbidden with default headers values +func NewPostCredentialsForbidden() *PostCredentialsForbidden { + return &PostCredentialsForbidden{} +} + +/*PostCredentialsForbidden handles this case with default header values. + +Access forbidden, account lacks access +*/ +type PostCredentialsForbidden struct { + Payload *auth0_models.Error +} + +func (o *PostCredentialsForbidden) Error() string { + return fmt.Sprintf("[POST /oauth/token][%d] postCredentialsForbidden %+v", 403, o.Payload) +} + +func (o *PostCredentialsForbidden) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *PostCredentialsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostCredentialsNotFound creates a PostCredentialsNotFound with default headers values +func NewPostCredentialsNotFound() *PostCredentialsNotFound { + return &PostCredentialsNotFound{} +} + +/*PostCredentialsNotFound handles this case with default header values. + +Resource was not found +*/ +type PostCredentialsNotFound struct { + Payload *auth0_models.Error +} + +func (o *PostCredentialsNotFound) Error() string { + return fmt.Sprintf("[POST /oauth/token][%d] postCredentialsNotFound %+v", 404, o.Payload) +} + +func (o *PostCredentialsNotFound) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *PostCredentialsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostCredentialsUnprocessableEntity creates a PostCredentialsUnprocessableEntity with default headers values +func NewPostCredentialsUnprocessableEntity() *PostCredentialsUnprocessableEntity { + return &PostCredentialsUnprocessableEntity{} +} + +/*PostCredentialsUnprocessableEntity handles this case with default header values. + +Unprocessable Entity, likely a bad parameter +*/ +type PostCredentialsUnprocessableEntity struct { + Payload *auth0_models.Error +} + +func (o *PostCredentialsUnprocessableEntity) Error() string { + return fmt.Sprintf("[POST /oauth/token][%d] postCredentialsUnprocessableEntity %+v", 422, o.Payload) +} + +func (o *PostCredentialsUnprocessableEntity) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *PostCredentialsUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostCredentialsInternalServerError creates a PostCredentialsInternalServerError with default headers values +func NewPostCredentialsInternalServerError() *PostCredentialsInternalServerError { + return &PostCredentialsInternalServerError{} +} + +/*PostCredentialsInternalServerError handles this case with default header values. + +Server Internal Error +*/ +type PostCredentialsInternalServerError struct { + Payload *auth0_models.Error +} + +func (o *PostCredentialsInternalServerError) Error() string { + return fmt.Sprintf("[POST /oauth/token][%d] postCredentialsInternalServerError %+v", 500, o.Payload) +} + +func (o *PostCredentialsInternalServerError) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *PostCredentialsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/cloud/cloud_client/cloud_client.go b/api/auth0/auth0_client/auth0_client.go similarity index 73% rename from api/cloud/cloud_client/cloud_client.go rename to api/auth0/auth0_client/auth0_client.go index 6e8a7a4..605eab5 100644 --- a/api/cloud/cloud_client/cloud_client.go +++ b/api/auth0/auth0_client/auth0_client.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package cloud_client +package auth0_client // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -14,34 +14,34 @@ import ( httptransport "github.com/go-openapi/runtime/client" "github.com/go-openapi/strfmt" - "code.tnxs.net/vernonkeenan/lib/api/cloud/cloud_client/cors" - "code.tnxs.net/vernonkeenan/lib/api/cloud/cloud_client/hub" - "code.tnxs.net/vernonkeenan/lib/api/cloud/cloud_client/user" + "code.tnxs.net/vernonkeenan/lib/api/auth0/auth0_client/auth" + "code.tnxs.net/vernonkeenan/lib/api/auth0/auth0_client/role" + "code.tnxs.net/vernonkeenan/lib/api/auth0/auth0_client/user" ) -// Default cloud HTTP client. +// Default auth0 HTTP client. var Default = NewHTTPClient(nil) const ( // DefaultHost is the default Host // found in Meta (info) section of spec file - DefaultHost string = "cloud.infra.tnxs.net:8080" + DefaultHost string = "taxnexus.auth0.com" // DefaultBasePath is the default BasePath // found in Meta (info) section of spec file - DefaultBasePath string = "/v1" + DefaultBasePath string = "/" ) // DefaultSchemes are the default schemes found in Meta (info) section of spec file -var DefaultSchemes = []string{"http"} +var DefaultSchemes = []string{"https"} -// NewHTTPClient creates a new cloud HTTP client. -func NewHTTPClient(formats strfmt.Registry) *Cloud { +// NewHTTPClient creates a new auth0 HTTP client. +func NewHTTPClient(formats strfmt.Registry) *Auth0 { return NewHTTPClientWithConfig(formats, nil) } -// NewHTTPClientWithConfig creates a new cloud HTTP client, +// NewHTTPClientWithConfig creates a new auth0 HTTP client, // using a customizable transport config. -func NewHTTPClientWithConfig(formats strfmt.Registry, cfg *TransportConfig) *Cloud { +func NewHTTPClientWithConfig(formats strfmt.Registry, cfg *TransportConfig) *Auth0 { // ensure nullable parameters have default if cfg == nil { cfg = DefaultTransportConfig() @@ -52,17 +52,17 @@ func NewHTTPClientWithConfig(formats strfmt.Registry, cfg *TransportConfig) *Clo return New(transport, formats) } -// New creates a new cloud client -func New(transport runtime.ClientTransport, formats strfmt.Registry) *Cloud { +// New creates a new auth0 client +func New(transport runtime.ClientTransport, formats strfmt.Registry) *Auth0 { // ensure nullable parameters have default if formats == nil { formats = strfmt.Default } - cli := new(Cloud) + cli := new(Auth0) cli.Transport = transport - cli.Cors = cors.New(transport, formats) - cli.Hub = hub.New(transport, formats) + cli.Auth = auth.New(transport, formats) + cli.Role = role.New(transport, formats) cli.User = user.New(transport, formats) return cli } @@ -106,11 +106,11 @@ func (cfg *TransportConfig) WithSchemes(schemes []string) *TransportConfig { return cfg } -// Cloud is a client for cloud -type Cloud struct { - Cors cors.ClientService +// Auth0 is a client for auth0 +type Auth0 struct { + Auth auth.ClientService - Hub hub.ClientService + Role role.ClientService User user.ClientService @@ -118,9 +118,9 @@ type Cloud struct { } // SetTransport changes the transport on the client and all its subresources -func (c *Cloud) SetTransport(transport runtime.ClientTransport) { +func (c *Auth0) SetTransport(transport runtime.ClientTransport) { c.Transport = transport - c.Cors.SetTransport(transport) - c.Hub.SetTransport(transport) + c.Auth.SetTransport(transport) + c.Role.SetTransport(transport) c.User.SetTransport(transport) } diff --git a/api/auth0/auth0_client/role/get_roles_parameters.go b/api/auth0/auth0_client/role/get_roles_parameters.go new file mode 100644 index 0000000..40328c9 --- /dev/null +++ b/api/auth0/auth0_client/role/get_roles_parameters.go @@ -0,0 +1,136 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package role + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewGetRolesParams creates a new GetRolesParams object +// with the default values initialized. +func NewGetRolesParams() *GetRolesParams { + var () + return &GetRolesParams{ + + timeout: cr.DefaultTimeout, + } +} + +// NewGetRolesParamsWithTimeout creates a new GetRolesParams object +// with the default values initialized, and the ability to set a timeout on a request +func NewGetRolesParamsWithTimeout(timeout time.Duration) *GetRolesParams { + var () + return &GetRolesParams{ + + timeout: timeout, + } +} + +// NewGetRolesParamsWithContext creates a new GetRolesParams object +// with the default values initialized, and the ability to set a context for a request +func NewGetRolesParamsWithContext(ctx context.Context) *GetRolesParams { + var () + return &GetRolesParams{ + + Context: ctx, + } +} + +// NewGetRolesParamsWithHTTPClient creates a new GetRolesParams object +// with the default values initialized, and the ability to set a custom HTTPClient for a request +func NewGetRolesParamsWithHTTPClient(client *http.Client) *GetRolesParams { + var () + return &GetRolesParams{ + HTTPClient: client, + } +} + +/*GetRolesParams contains all the parameters to send to the API endpoint +for the get roles operation typically these are written to a http.Request +*/ +type GetRolesParams struct { + + /*Authorization*/ + Authorization string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithTimeout adds the timeout to the get roles params +func (o *GetRolesParams) WithTimeout(timeout time.Duration) *GetRolesParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the get roles params +func (o *GetRolesParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the get roles params +func (o *GetRolesParams) WithContext(ctx context.Context) *GetRolesParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the get roles params +func (o *GetRolesParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the get roles params +func (o *GetRolesParams) WithHTTPClient(client *http.Client) *GetRolesParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the get roles params +func (o *GetRolesParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithAuthorization adds the authorization to the get roles params +func (o *GetRolesParams) WithAuthorization(authorization string) *GetRolesParams { + o.SetAuthorization(authorization) + return o +} + +// SetAuthorization adds the authorization to the get roles params +func (o *GetRolesParams) SetAuthorization(authorization string) { + o.Authorization = authorization +} + +// WriteToRequest writes these params to a swagger request +func (o *GetRolesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // header param Authorization + if err := r.SetHeaderParam("Authorization", o.Authorization); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/auth0/auth0_client/role/get_roles_responses.go b/api/auth0/auth0_client/role/get_roles_responses.go new file mode 100644 index 0000000..db2ff7d --- /dev/null +++ b/api/auth0/auth0_client/role/get_roles_responses.go @@ -0,0 +1,266 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package role + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/auth0/auth0_models" +) + +// GetRolesReader is a Reader for the GetRoles structure. +type GetRolesReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *GetRolesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewGetRolesOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewGetRolesUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewGetRolesForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewGetRolesNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 422: + result := NewGetRolesUnprocessableEntity() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewGetRolesInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + + default: + return nil, runtime.NewAPIError("unknown error", response, response.Code()) + } +} + +// NewGetRolesOK creates a GetRolesOK with default headers values +func NewGetRolesOK() *GetRolesOK { + return &GetRolesOK{} +} + +/*GetRolesOK handles this case with default header values. + +Taxnexus Response with User objects +*/ +type GetRolesOK struct { + Payload []*auth0_models.User +} + +func (o *GetRolesOK) Error() string { + return fmt.Sprintf("[GET /api/v2/roles][%d] getRolesOK %+v", 200, o.Payload) +} + +func (o *GetRolesOK) GetPayload() []*auth0_models.User { + return o.Payload +} + +func (o *GetRolesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + // response payload + if err := consumer.Consume(response.Body(), &o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetRolesUnauthorized creates a GetRolesUnauthorized with default headers values +func NewGetRolesUnauthorized() *GetRolesUnauthorized { + return &GetRolesUnauthorized{} +} + +/*GetRolesUnauthorized handles this case with default header values. + +Access Unauthorized, invalid API-KEY was used +*/ +type GetRolesUnauthorized struct { + Payload *auth0_models.Error +} + +func (o *GetRolesUnauthorized) Error() string { + return fmt.Sprintf("[GET /api/v2/roles][%d] getRolesUnauthorized %+v", 401, o.Payload) +} + +func (o *GetRolesUnauthorized) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetRolesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetRolesForbidden creates a GetRolesForbidden with default headers values +func NewGetRolesForbidden() *GetRolesForbidden { + return &GetRolesForbidden{} +} + +/*GetRolesForbidden handles this case with default header values. + +Access forbidden, account lacks access +*/ +type GetRolesForbidden struct { + Payload *auth0_models.Error +} + +func (o *GetRolesForbidden) Error() string { + return fmt.Sprintf("[GET /api/v2/roles][%d] getRolesForbidden %+v", 403, o.Payload) +} + +func (o *GetRolesForbidden) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetRolesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetRolesNotFound creates a GetRolesNotFound with default headers values +func NewGetRolesNotFound() *GetRolesNotFound { + return &GetRolesNotFound{} +} + +/*GetRolesNotFound handles this case with default header values. + +Resource was not found +*/ +type GetRolesNotFound struct { + Payload *auth0_models.Error +} + +func (o *GetRolesNotFound) Error() string { + return fmt.Sprintf("[GET /api/v2/roles][%d] getRolesNotFound %+v", 404, o.Payload) +} + +func (o *GetRolesNotFound) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetRolesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetRolesUnprocessableEntity creates a GetRolesUnprocessableEntity with default headers values +func NewGetRolesUnprocessableEntity() *GetRolesUnprocessableEntity { + return &GetRolesUnprocessableEntity{} +} + +/*GetRolesUnprocessableEntity handles this case with default header values. + +Unprocessable Entity, likely a bad parameter +*/ +type GetRolesUnprocessableEntity struct { + Payload *auth0_models.Error +} + +func (o *GetRolesUnprocessableEntity) Error() string { + return fmt.Sprintf("[GET /api/v2/roles][%d] getRolesUnprocessableEntity %+v", 422, o.Payload) +} + +func (o *GetRolesUnprocessableEntity) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetRolesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetRolesInternalServerError creates a GetRolesInternalServerError with default headers values +func NewGetRolesInternalServerError() *GetRolesInternalServerError { + return &GetRolesInternalServerError{} +} + +/*GetRolesInternalServerError handles this case with default header values. + +Server Internal Error +*/ +type GetRolesInternalServerError struct { + Payload *auth0_models.Error +} + +func (o *GetRolesInternalServerError) Error() string { + return fmt.Sprintf("[GET /api/v2/roles][%d] getRolesInternalServerError %+v", 500, o.Payload) +} + +func (o *GetRolesInternalServerError) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetRolesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/auth0/auth0_client/role/post_role_users_parameters.go b/api/auth0/auth0_client/role/post_role_users_parameters.go new file mode 100644 index 0000000..50694f0 --- /dev/null +++ b/api/auth0/auth0_client/role/post_role_users_parameters.go @@ -0,0 +1,181 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package role + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/auth0/auth0_models" +) + +// NewPostRoleUsersParams creates a new PostRoleUsersParams object +// with the default values initialized. +func NewPostRoleUsersParams() *PostRoleUsersParams { + var () + return &PostRoleUsersParams{ + + timeout: cr.DefaultTimeout, + } +} + +// NewPostRoleUsersParamsWithTimeout creates a new PostRoleUsersParams object +// with the default values initialized, and the ability to set a timeout on a request +func NewPostRoleUsersParamsWithTimeout(timeout time.Duration) *PostRoleUsersParams { + var () + return &PostRoleUsersParams{ + + timeout: timeout, + } +} + +// NewPostRoleUsersParamsWithContext creates a new PostRoleUsersParams object +// with the default values initialized, and the ability to set a context for a request +func NewPostRoleUsersParamsWithContext(ctx context.Context) *PostRoleUsersParams { + var () + return &PostRoleUsersParams{ + + Context: ctx, + } +} + +// NewPostRoleUsersParamsWithHTTPClient creates a new PostRoleUsersParams object +// with the default values initialized, and the ability to set a custom HTTPClient for a request +func NewPostRoleUsersParamsWithHTTPClient(client *http.Client) *PostRoleUsersParams { + var () + return &PostRoleUsersParams{ + HTTPClient: client, + } +} + +/*PostRoleUsersParams contains all the parameters to send to the API endpoint +for the post role users operation typically these are written to a http.Request +*/ +type PostRoleUsersParams struct { + + /*Authorization*/ + Authorization string + /*RoleUsersRequest + An array of User IDs to add to a Role + + */ + RoleUsersRequest *auth0_models.RoleUsersRequest + /*RoleID + An Auth0 Role ID + + */ + RoleID string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithTimeout adds the timeout to the post role users params +func (o *PostRoleUsersParams) WithTimeout(timeout time.Duration) *PostRoleUsersParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the post role users params +func (o *PostRoleUsersParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the post role users params +func (o *PostRoleUsersParams) WithContext(ctx context.Context) *PostRoleUsersParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the post role users params +func (o *PostRoleUsersParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the post role users params +func (o *PostRoleUsersParams) WithHTTPClient(client *http.Client) *PostRoleUsersParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the post role users params +func (o *PostRoleUsersParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithAuthorization adds the authorization to the post role users params +func (o *PostRoleUsersParams) WithAuthorization(authorization string) *PostRoleUsersParams { + o.SetAuthorization(authorization) + return o +} + +// SetAuthorization adds the authorization to the post role users params +func (o *PostRoleUsersParams) SetAuthorization(authorization string) { + o.Authorization = authorization +} + +// WithRoleUsersRequest adds the roleUsersRequest to the post role users params +func (o *PostRoleUsersParams) WithRoleUsersRequest(roleUsersRequest *auth0_models.RoleUsersRequest) *PostRoleUsersParams { + o.SetRoleUsersRequest(roleUsersRequest) + return o +} + +// SetRoleUsersRequest adds the roleUsersRequest to the post role users params +func (o *PostRoleUsersParams) SetRoleUsersRequest(roleUsersRequest *auth0_models.RoleUsersRequest) { + o.RoleUsersRequest = roleUsersRequest +} + +// WithRoleID adds the roleID to the post role users params +func (o *PostRoleUsersParams) WithRoleID(roleID string) *PostRoleUsersParams { + o.SetRoleID(roleID) + return o +} + +// SetRoleID adds the roleId to the post role users params +func (o *PostRoleUsersParams) SetRoleID(roleID string) { + o.RoleID = roleID +} + +// WriteToRequest writes these params to a swagger request +func (o *PostRoleUsersParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // header param Authorization + if err := r.SetHeaderParam("Authorization", o.Authorization); err != nil { + return err + } + + if o.RoleUsersRequest != nil { + if err := r.SetBodyParam(o.RoleUsersRequest); err != nil { + return err + } + } + + // path param roleId + if err := r.SetPathParam("roleId", o.RoleID); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/auth0/auth0_client/role/post_role_users_responses.go b/api/auth0/auth0_client/role/post_role_users_responses.go new file mode 100644 index 0000000..d52523a --- /dev/null +++ b/api/auth0/auth0_client/role/post_role_users_responses.go @@ -0,0 +1,217 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package role + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/auth0/auth0_models" +) + +// PostRoleUsersReader is a Reader for the PostRoleUsers structure. +type PostRoleUsersReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *PostRoleUsersReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewPostRoleUsersOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewPostRoleUsersUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewPostRoleUsersForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewPostRoleUsersNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewPostRoleUsersInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + + default: + return nil, runtime.NewAPIError("unknown error", response, response.Code()) + } +} + +// NewPostRoleUsersOK creates a PostRoleUsersOK with default headers values +func NewPostRoleUsersOK() *PostRoleUsersOK { + return &PostRoleUsersOK{} +} + +/*PostRoleUsersOK handles this case with default header values. + +Role users successfully updated +*/ +type PostRoleUsersOK struct { +} + +func (o *PostRoleUsersOK) Error() string { + return fmt.Sprintf("[POST /api/v2/roles/{roleId}/users][%d] postRoleUsersOK ", 200) +} + +func (o *PostRoleUsersOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} + +// NewPostRoleUsersUnauthorized creates a PostRoleUsersUnauthorized with default headers values +func NewPostRoleUsersUnauthorized() *PostRoleUsersUnauthorized { + return &PostRoleUsersUnauthorized{} +} + +/*PostRoleUsersUnauthorized handles this case with default header values. + +Access Unauthorized, invalid API-KEY was used +*/ +type PostRoleUsersUnauthorized struct { + Payload *auth0_models.Error +} + +func (o *PostRoleUsersUnauthorized) Error() string { + return fmt.Sprintf("[POST /api/v2/roles/{roleId}/users][%d] postRoleUsersUnauthorized %+v", 401, o.Payload) +} + +func (o *PostRoleUsersUnauthorized) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *PostRoleUsersUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostRoleUsersForbidden creates a PostRoleUsersForbidden with default headers values +func NewPostRoleUsersForbidden() *PostRoleUsersForbidden { + return &PostRoleUsersForbidden{} +} + +/*PostRoleUsersForbidden handles this case with default header values. + +Access forbidden, account lacks access +*/ +type PostRoleUsersForbidden struct { + Payload *auth0_models.Error +} + +func (o *PostRoleUsersForbidden) Error() string { + return fmt.Sprintf("[POST /api/v2/roles/{roleId}/users][%d] postRoleUsersForbidden %+v", 403, o.Payload) +} + +func (o *PostRoleUsersForbidden) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *PostRoleUsersForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostRoleUsersNotFound creates a PostRoleUsersNotFound with default headers values +func NewPostRoleUsersNotFound() *PostRoleUsersNotFound { + return &PostRoleUsersNotFound{} +} + +/*PostRoleUsersNotFound handles this case with default header values. + +Resource was not found +*/ +type PostRoleUsersNotFound struct { + Payload *auth0_models.Error +} + +func (o *PostRoleUsersNotFound) Error() string { + return fmt.Sprintf("[POST /api/v2/roles/{roleId}/users][%d] postRoleUsersNotFound %+v", 404, o.Payload) +} + +func (o *PostRoleUsersNotFound) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *PostRoleUsersNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostRoleUsersInternalServerError creates a PostRoleUsersInternalServerError with default headers values +func NewPostRoleUsersInternalServerError() *PostRoleUsersInternalServerError { + return &PostRoleUsersInternalServerError{} +} + +/*PostRoleUsersInternalServerError handles this case with default header values. + +Server Internal Error +*/ +type PostRoleUsersInternalServerError struct { + Payload *auth0_models.Error +} + +func (o *PostRoleUsersInternalServerError) Error() string { + return fmt.Sprintf("[POST /api/v2/roles/{roleId}/users][%d] postRoleUsersInternalServerError %+v", 500, o.Payload) +} + +func (o *PostRoleUsersInternalServerError) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *PostRoleUsersInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/kazoo/kazoo_client/user/user_client.go b/api/auth0/auth0_client/role/role_client.go similarity index 50% rename from api/kazoo/kazoo_client/user/user_client.go rename to api/auth0/auth0_client/role/role_client.go index e3c8fab..248fa93 100644 --- a/api/kazoo/kazoo_client/user/user_client.go +++ b/api/auth0/auth0_client/role/role_client.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package user +package role // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -16,106 +16,97 @@ import ( "github.com/go-openapi/strfmt" ) -// New creates a new user API client. +// New creates a new role API client. func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { return &Client{transport: transport, formats: formats} } /* -Client for user API +Client for role API */ type Client struct { transport runtime.ClientTransport formats strfmt.Registry } -// ClientOption is the option for Client methods -type ClientOption func(*runtime.ClientOperation) - // ClientService is the interface for Client methods type ClientService interface { - GetAccountUsers(params *GetAccountUsersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountUsersOK, error) + GetRoles(params *GetRolesParams) (*GetRolesOK, error) - GetAccountVMBoxes(params *GetAccountVMBoxesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountVMBoxesOK, error) + PostRoleUsers(params *PostRoleUsersParams) (*PostRoleUsersOK, error) SetTransport(transport runtime.ClientTransport) } /* - GetAccountUsers get account users API + GetRoles gets roles from auth0 + + Get Roles from Auth0 */ -func (a *Client) GetAccountUsers(params *GetAccountUsersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountUsersOK, error) { +func (a *Client) GetRoles(params *GetRolesParams) (*GetRolesOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewGetAccountUsersParams() + params = NewGetRolesParams() } - op := &runtime.ClientOperation{ - ID: "getAccountUsers", + + result, err := a.transport.Submit(&runtime.ClientOperation{ + ID: "getRoles", Method: "GET", - PathPattern: "/accounts/{accountId}/users", + PathPattern: "/api/v2/roles", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"https"}, Params: params, - Reader: &GetAccountUsersReader{formats: a.formats}, - AuthInfo: authInfo, + Reader: &GetRolesReader{formats: a.formats}, Context: params.Context, Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) + }) if err != nil { return nil, err } - success, ok := result.(*GetAccountUsersOK) + success, ok := result.(*GetRolesOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getAccountUsers: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for getRoles: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - GetAccountVMBoxes get account Vm boxes API + PostRoleUsers adds users to role + + Add users to role */ -func (a *Client) GetAccountVMBoxes(params *GetAccountVMBoxesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountVMBoxesOK, error) { +func (a *Client) PostRoleUsers(params *PostRoleUsersParams) (*PostRoleUsersOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewGetAccountVMBoxesParams() + params = NewPostRoleUsersParams() } - op := &runtime.ClientOperation{ - ID: "getAccountVmBoxes", - Method: "GET", - PathPattern: "/accounts/{accountId}/vmboxes", + + result, err := a.transport.Submit(&runtime.ClientOperation{ + ID: "postRoleUsers", + Method: "POST", + PathPattern: "/api/v2/roles/{roleId}/users", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"https"}, Params: params, - Reader: &GetAccountVMBoxesReader{formats: a.formats}, - AuthInfo: authInfo, + Reader: &PostRoleUsersReader{formats: a.formats}, Context: params.Context, Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) + }) if err != nil { return nil, err } - success, ok := result.(*GetAccountVMBoxesOK) + success, ok := result.(*PostRoleUsersOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getAccountVmBoxes: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for postRoleUsers: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } diff --git a/api/auth0/auth0_client/user/delete_api_v2_users_user_id_roles_parameters.go b/api/auth0/auth0_client/user/delete_api_v2_users_user_id_roles_parameters.go new file mode 100644 index 0000000..9738c91 --- /dev/null +++ b/api/auth0/auth0_client/user/delete_api_v2_users_user_id_roles_parameters.go @@ -0,0 +1,181 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package user + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/auth0/auth0_models" +) + +// NewDeleteAPIV2UsersUserIDRolesParams creates a new DeleteAPIV2UsersUserIDRolesParams object +// with the default values initialized. +func NewDeleteAPIV2UsersUserIDRolesParams() *DeleteAPIV2UsersUserIDRolesParams { + var () + return &DeleteAPIV2UsersUserIDRolesParams{ + + timeout: cr.DefaultTimeout, + } +} + +// NewDeleteAPIV2UsersUserIDRolesParamsWithTimeout creates a new DeleteAPIV2UsersUserIDRolesParams object +// with the default values initialized, and the ability to set a timeout on a request +func NewDeleteAPIV2UsersUserIDRolesParamsWithTimeout(timeout time.Duration) *DeleteAPIV2UsersUserIDRolesParams { + var () + return &DeleteAPIV2UsersUserIDRolesParams{ + + timeout: timeout, + } +} + +// NewDeleteAPIV2UsersUserIDRolesParamsWithContext creates a new DeleteAPIV2UsersUserIDRolesParams object +// with the default values initialized, and the ability to set a context for a request +func NewDeleteAPIV2UsersUserIDRolesParamsWithContext(ctx context.Context) *DeleteAPIV2UsersUserIDRolesParams { + var () + return &DeleteAPIV2UsersUserIDRolesParams{ + + Context: ctx, + } +} + +// NewDeleteAPIV2UsersUserIDRolesParamsWithHTTPClient creates a new DeleteAPIV2UsersUserIDRolesParams object +// with the default values initialized, and the ability to set a custom HTTPClient for a request +func NewDeleteAPIV2UsersUserIDRolesParamsWithHTTPClient(client *http.Client) *DeleteAPIV2UsersUserIDRolesParams { + var () + return &DeleteAPIV2UsersUserIDRolesParams{ + HTTPClient: client, + } +} + +/*DeleteAPIV2UsersUserIDRolesParams contains all the parameters to send to the API endpoint +for the delete API v2 users user ID roles operation typically these are written to a http.Request +*/ +type DeleteAPIV2UsersUserIDRolesParams struct { + + /*Authorization*/ + Authorization string + /*UserRolesRequest + An array of User IDs to add to a Role + + */ + UserRolesRequest *auth0_models.UserRolesRequest + /*UserID + An Auth0 User ID + + */ + UserID string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithTimeout adds the timeout to the delete API v2 users user ID roles params +func (o *DeleteAPIV2UsersUserIDRolesParams) WithTimeout(timeout time.Duration) *DeleteAPIV2UsersUserIDRolesParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the delete API v2 users user ID roles params +func (o *DeleteAPIV2UsersUserIDRolesParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the delete API v2 users user ID roles params +func (o *DeleteAPIV2UsersUserIDRolesParams) WithContext(ctx context.Context) *DeleteAPIV2UsersUserIDRolesParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the delete API v2 users user ID roles params +func (o *DeleteAPIV2UsersUserIDRolesParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the delete API v2 users user ID roles params +func (o *DeleteAPIV2UsersUserIDRolesParams) WithHTTPClient(client *http.Client) *DeleteAPIV2UsersUserIDRolesParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the delete API v2 users user ID roles params +func (o *DeleteAPIV2UsersUserIDRolesParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithAuthorization adds the authorization to the delete API v2 users user ID roles params +func (o *DeleteAPIV2UsersUserIDRolesParams) WithAuthorization(authorization string) *DeleteAPIV2UsersUserIDRolesParams { + o.SetAuthorization(authorization) + return o +} + +// SetAuthorization adds the authorization to the delete API v2 users user ID roles params +func (o *DeleteAPIV2UsersUserIDRolesParams) SetAuthorization(authorization string) { + o.Authorization = authorization +} + +// WithUserRolesRequest adds the userRolesRequest to the delete API v2 users user ID roles params +func (o *DeleteAPIV2UsersUserIDRolesParams) WithUserRolesRequest(userRolesRequest *auth0_models.UserRolesRequest) *DeleteAPIV2UsersUserIDRolesParams { + o.SetUserRolesRequest(userRolesRequest) + return o +} + +// SetUserRolesRequest adds the userRolesRequest to the delete API v2 users user ID roles params +func (o *DeleteAPIV2UsersUserIDRolesParams) SetUserRolesRequest(userRolesRequest *auth0_models.UserRolesRequest) { + o.UserRolesRequest = userRolesRequest +} + +// WithUserID adds the userID to the delete API v2 users user ID roles params +func (o *DeleteAPIV2UsersUserIDRolesParams) WithUserID(userID string) *DeleteAPIV2UsersUserIDRolesParams { + o.SetUserID(userID) + return o +} + +// SetUserID adds the userId to the delete API v2 users user ID roles params +func (o *DeleteAPIV2UsersUserIDRolesParams) SetUserID(userID string) { + o.UserID = userID +} + +// WriteToRequest writes these params to a swagger request +func (o *DeleteAPIV2UsersUserIDRolesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // header param Authorization + if err := r.SetHeaderParam("Authorization", o.Authorization); err != nil { + return err + } + + if o.UserRolesRequest != nil { + if err := r.SetBodyParam(o.UserRolesRequest); err != nil { + return err + } + } + + // path param userId + if err := r.SetPathParam("userId", o.UserID); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/auth0/auth0_client/user/delete_api_v2_users_user_id_roles_responses.go b/api/auth0/auth0_client/user/delete_api_v2_users_user_id_roles_responses.go new file mode 100644 index 0000000..ad3f9ed --- /dev/null +++ b/api/auth0/auth0_client/user/delete_api_v2_users_user_id_roles_responses.go @@ -0,0 +1,217 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package user + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/auth0/auth0_models" +) + +// DeleteAPIV2UsersUserIDRolesReader is a Reader for the DeleteAPIV2UsersUserIDRoles structure. +type DeleteAPIV2UsersUserIDRolesReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *DeleteAPIV2UsersUserIDRolesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewDeleteAPIV2UsersUserIDRolesNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewDeleteAPIV2UsersUserIDRolesUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewDeleteAPIV2UsersUserIDRolesForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewDeleteAPIV2UsersUserIDRolesNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewDeleteAPIV2UsersUserIDRolesInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + + default: + return nil, runtime.NewAPIError("unknown error", response, response.Code()) + } +} + +// NewDeleteAPIV2UsersUserIDRolesNoContent creates a DeleteAPIV2UsersUserIDRolesNoContent with default headers values +func NewDeleteAPIV2UsersUserIDRolesNoContent() *DeleteAPIV2UsersUserIDRolesNoContent { + return &DeleteAPIV2UsersUserIDRolesNoContent{} +} + +/*DeleteAPIV2UsersUserIDRolesNoContent handles this case with default header values. + +User roles successfully removed +*/ +type DeleteAPIV2UsersUserIDRolesNoContent struct { +} + +func (o *DeleteAPIV2UsersUserIDRolesNoContent) Error() string { + return fmt.Sprintf("[DELETE /api/v2/users/{userId}/roles][%d] deleteApiV2UsersUserIdRolesNoContent ", 204) +} + +func (o *DeleteAPIV2UsersUserIDRolesNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} + +// NewDeleteAPIV2UsersUserIDRolesUnauthorized creates a DeleteAPIV2UsersUserIDRolesUnauthorized with default headers values +func NewDeleteAPIV2UsersUserIDRolesUnauthorized() *DeleteAPIV2UsersUserIDRolesUnauthorized { + return &DeleteAPIV2UsersUserIDRolesUnauthorized{} +} + +/*DeleteAPIV2UsersUserIDRolesUnauthorized handles this case with default header values. + +Access Unauthorized, invalid API-KEY was used +*/ +type DeleteAPIV2UsersUserIDRolesUnauthorized struct { + Payload *auth0_models.Error +} + +func (o *DeleteAPIV2UsersUserIDRolesUnauthorized) Error() string { + return fmt.Sprintf("[DELETE /api/v2/users/{userId}/roles][%d] deleteApiV2UsersUserIdRolesUnauthorized %+v", 401, o.Payload) +} + +func (o *DeleteAPIV2UsersUserIDRolesUnauthorized) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *DeleteAPIV2UsersUserIDRolesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewDeleteAPIV2UsersUserIDRolesForbidden creates a DeleteAPIV2UsersUserIDRolesForbidden with default headers values +func NewDeleteAPIV2UsersUserIDRolesForbidden() *DeleteAPIV2UsersUserIDRolesForbidden { + return &DeleteAPIV2UsersUserIDRolesForbidden{} +} + +/*DeleteAPIV2UsersUserIDRolesForbidden handles this case with default header values. + +Access forbidden, account lacks access +*/ +type DeleteAPIV2UsersUserIDRolesForbidden struct { + Payload *auth0_models.Error +} + +func (o *DeleteAPIV2UsersUserIDRolesForbidden) Error() string { + return fmt.Sprintf("[DELETE /api/v2/users/{userId}/roles][%d] deleteApiV2UsersUserIdRolesForbidden %+v", 403, o.Payload) +} + +func (o *DeleteAPIV2UsersUserIDRolesForbidden) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *DeleteAPIV2UsersUserIDRolesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewDeleteAPIV2UsersUserIDRolesNotFound creates a DeleteAPIV2UsersUserIDRolesNotFound with default headers values +func NewDeleteAPIV2UsersUserIDRolesNotFound() *DeleteAPIV2UsersUserIDRolesNotFound { + return &DeleteAPIV2UsersUserIDRolesNotFound{} +} + +/*DeleteAPIV2UsersUserIDRolesNotFound handles this case with default header values. + +Resource was not found +*/ +type DeleteAPIV2UsersUserIDRolesNotFound struct { + Payload *auth0_models.Error +} + +func (o *DeleteAPIV2UsersUserIDRolesNotFound) Error() string { + return fmt.Sprintf("[DELETE /api/v2/users/{userId}/roles][%d] deleteApiV2UsersUserIdRolesNotFound %+v", 404, o.Payload) +} + +func (o *DeleteAPIV2UsersUserIDRolesNotFound) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *DeleteAPIV2UsersUserIDRolesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewDeleteAPIV2UsersUserIDRolesInternalServerError creates a DeleteAPIV2UsersUserIDRolesInternalServerError with default headers values +func NewDeleteAPIV2UsersUserIDRolesInternalServerError() *DeleteAPIV2UsersUserIDRolesInternalServerError { + return &DeleteAPIV2UsersUserIDRolesInternalServerError{} +} + +/*DeleteAPIV2UsersUserIDRolesInternalServerError handles this case with default header values. + +Server Internal Error +*/ +type DeleteAPIV2UsersUserIDRolesInternalServerError struct { + Payload *auth0_models.Error +} + +func (o *DeleteAPIV2UsersUserIDRolesInternalServerError) Error() string { + return fmt.Sprintf("[DELETE /api/v2/users/{userId}/roles][%d] deleteApiV2UsersUserIdRolesInternalServerError %+v", 500, o.Payload) +} + +func (o *DeleteAPIV2UsersUserIDRolesInternalServerError) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *DeleteAPIV2UsersUserIDRolesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/auth0/auth0_client/user/get_user_by_email_parameters.go b/api/auth0/auth0_client/user/get_user_by_email_parameters.go new file mode 100644 index 0000000..75d5338 --- /dev/null +++ b/api/auth0/auth0_client/user/get_user_by_email_parameters.go @@ -0,0 +1,158 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package user + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewGetUserByEmailParams creates a new GetUserByEmailParams object +// with the default values initialized. +func NewGetUserByEmailParams() *GetUserByEmailParams { + var () + return &GetUserByEmailParams{ + + timeout: cr.DefaultTimeout, + } +} + +// NewGetUserByEmailParamsWithTimeout creates a new GetUserByEmailParams object +// with the default values initialized, and the ability to set a timeout on a request +func NewGetUserByEmailParamsWithTimeout(timeout time.Duration) *GetUserByEmailParams { + var () + return &GetUserByEmailParams{ + + timeout: timeout, + } +} + +// NewGetUserByEmailParamsWithContext creates a new GetUserByEmailParams object +// with the default values initialized, and the ability to set a context for a request +func NewGetUserByEmailParamsWithContext(ctx context.Context) *GetUserByEmailParams { + var () + return &GetUserByEmailParams{ + + Context: ctx, + } +} + +// NewGetUserByEmailParamsWithHTTPClient creates a new GetUserByEmailParams object +// with the default values initialized, and the ability to set a custom HTTPClient for a request +func NewGetUserByEmailParamsWithHTTPClient(client *http.Client) *GetUserByEmailParams { + var () + return &GetUserByEmailParams{ + HTTPClient: client, + } +} + +/*GetUserByEmailParams contains all the parameters to send to the API endpoint +for the get user by email operation typically these are written to a http.Request +*/ +type GetUserByEmailParams struct { + + /*Authorization*/ + Authorization string + /*Email*/ + Email string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithTimeout adds the timeout to the get user by email params +func (o *GetUserByEmailParams) WithTimeout(timeout time.Duration) *GetUserByEmailParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the get user by email params +func (o *GetUserByEmailParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the get user by email params +func (o *GetUserByEmailParams) WithContext(ctx context.Context) *GetUserByEmailParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the get user by email params +func (o *GetUserByEmailParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the get user by email params +func (o *GetUserByEmailParams) WithHTTPClient(client *http.Client) *GetUserByEmailParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the get user by email params +func (o *GetUserByEmailParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithAuthorization adds the authorization to the get user by email params +func (o *GetUserByEmailParams) WithAuthorization(authorization string) *GetUserByEmailParams { + o.SetAuthorization(authorization) + return o +} + +// SetAuthorization adds the authorization to the get user by email params +func (o *GetUserByEmailParams) SetAuthorization(authorization string) { + o.Authorization = authorization +} + +// WithEmail adds the email to the get user by email params +func (o *GetUserByEmailParams) WithEmail(email string) *GetUserByEmailParams { + o.SetEmail(email) + return o +} + +// SetEmail adds the email to the get user by email params +func (o *GetUserByEmailParams) SetEmail(email string) { + o.Email = email +} + +// WriteToRequest writes these params to a swagger request +func (o *GetUserByEmailParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // header param Authorization + if err := r.SetHeaderParam("Authorization", o.Authorization); err != nil { + return err + } + + // query param email + qrEmail := o.Email + qEmail := qrEmail + if qEmail != "" { + if err := r.SetQueryParam("email", qEmail); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/auth0/auth0_client/user/get_user_by_email_responses.go b/api/auth0/auth0_client/user/get_user_by_email_responses.go new file mode 100644 index 0000000..9156166 --- /dev/null +++ b/api/auth0/auth0_client/user/get_user_by_email_responses.go @@ -0,0 +1,227 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package user + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/auth0/auth0_models" +) + +// GetUserByEmailReader is a Reader for the GetUserByEmail structure. +type GetUserByEmailReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *GetUserByEmailReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewGetUserByEmailOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewGetUserByEmailUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewGetUserByEmailForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewGetUserByEmailNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewGetUserByEmailInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + + default: + return nil, runtime.NewAPIError("unknown error", response, response.Code()) + } +} + +// NewGetUserByEmailOK creates a GetUserByEmailOK with default headers values +func NewGetUserByEmailOK() *GetUserByEmailOK { + return &GetUserByEmailOK{} +} + +/*GetUserByEmailOK handles this case with default header values. + +Taxnexus Response with User objects +*/ +type GetUserByEmailOK struct { + Payload []*auth0_models.User +} + +func (o *GetUserByEmailOK) Error() string { + return fmt.Sprintf("[GET /api/v2/users-by-email][%d] getUserByEmailOK %+v", 200, o.Payload) +} + +func (o *GetUserByEmailOK) GetPayload() []*auth0_models.User { + return o.Payload +} + +func (o *GetUserByEmailOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + // response payload + if err := consumer.Consume(response.Body(), &o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetUserByEmailUnauthorized creates a GetUserByEmailUnauthorized with default headers values +func NewGetUserByEmailUnauthorized() *GetUserByEmailUnauthorized { + return &GetUserByEmailUnauthorized{} +} + +/*GetUserByEmailUnauthorized handles this case with default header values. + +Access Unauthorized, invalid API-KEY was used +*/ +type GetUserByEmailUnauthorized struct { + Payload *auth0_models.Error +} + +func (o *GetUserByEmailUnauthorized) Error() string { + return fmt.Sprintf("[GET /api/v2/users-by-email][%d] getUserByEmailUnauthorized %+v", 401, o.Payload) +} + +func (o *GetUserByEmailUnauthorized) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetUserByEmailUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetUserByEmailForbidden creates a GetUserByEmailForbidden with default headers values +func NewGetUserByEmailForbidden() *GetUserByEmailForbidden { + return &GetUserByEmailForbidden{} +} + +/*GetUserByEmailForbidden handles this case with default header values. + +Access forbidden, account lacks access +*/ +type GetUserByEmailForbidden struct { + Payload *auth0_models.Error +} + +func (o *GetUserByEmailForbidden) Error() string { + return fmt.Sprintf("[GET /api/v2/users-by-email][%d] getUserByEmailForbidden %+v", 403, o.Payload) +} + +func (o *GetUserByEmailForbidden) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetUserByEmailForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetUserByEmailNotFound creates a GetUserByEmailNotFound with default headers values +func NewGetUserByEmailNotFound() *GetUserByEmailNotFound { + return &GetUserByEmailNotFound{} +} + +/*GetUserByEmailNotFound handles this case with default header values. + +Resource was not found +*/ +type GetUserByEmailNotFound struct { + Payload *auth0_models.Error +} + +func (o *GetUserByEmailNotFound) Error() string { + return fmt.Sprintf("[GET /api/v2/users-by-email][%d] getUserByEmailNotFound %+v", 404, o.Payload) +} + +func (o *GetUserByEmailNotFound) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetUserByEmailNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetUserByEmailInternalServerError creates a GetUserByEmailInternalServerError with default headers values +func NewGetUserByEmailInternalServerError() *GetUserByEmailInternalServerError { + return &GetUserByEmailInternalServerError{} +} + +/*GetUserByEmailInternalServerError handles this case with default header values. + +Server Internal Error +*/ +type GetUserByEmailInternalServerError struct { + Payload *auth0_models.Error +} + +func (o *GetUserByEmailInternalServerError) Error() string { + return fmt.Sprintf("[GET /api/v2/users-by-email][%d] getUserByEmailInternalServerError %+v", 500, o.Payload) +} + +func (o *GetUserByEmailInternalServerError) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetUserByEmailInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/auth0/auth0_client/user/get_user_roles_parameters.go b/api/auth0/auth0_client/user/get_user_roles_parameters.go new file mode 100644 index 0000000..38dd7c5 --- /dev/null +++ b/api/auth0/auth0_client/user/get_user_roles_parameters.go @@ -0,0 +1,157 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package user + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewGetUserRolesParams creates a new GetUserRolesParams object +// with the default values initialized. +func NewGetUserRolesParams() *GetUserRolesParams { + var () + return &GetUserRolesParams{ + + timeout: cr.DefaultTimeout, + } +} + +// NewGetUserRolesParamsWithTimeout creates a new GetUserRolesParams object +// with the default values initialized, and the ability to set a timeout on a request +func NewGetUserRolesParamsWithTimeout(timeout time.Duration) *GetUserRolesParams { + var () + return &GetUserRolesParams{ + + timeout: timeout, + } +} + +// NewGetUserRolesParamsWithContext creates a new GetUserRolesParams object +// with the default values initialized, and the ability to set a context for a request +func NewGetUserRolesParamsWithContext(ctx context.Context) *GetUserRolesParams { + var () + return &GetUserRolesParams{ + + Context: ctx, + } +} + +// NewGetUserRolesParamsWithHTTPClient creates a new GetUserRolesParams object +// with the default values initialized, and the ability to set a custom HTTPClient for a request +func NewGetUserRolesParamsWithHTTPClient(client *http.Client) *GetUserRolesParams { + var () + return &GetUserRolesParams{ + HTTPClient: client, + } +} + +/*GetUserRolesParams contains all the parameters to send to the API endpoint +for the get user roles operation typically these are written to a http.Request +*/ +type GetUserRolesParams struct { + + /*Authorization*/ + Authorization string + /*UserID + An Auth0 User ID + + */ + UserID string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithTimeout adds the timeout to the get user roles params +func (o *GetUserRolesParams) WithTimeout(timeout time.Duration) *GetUserRolesParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the get user roles params +func (o *GetUserRolesParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the get user roles params +func (o *GetUserRolesParams) WithContext(ctx context.Context) *GetUserRolesParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the get user roles params +func (o *GetUserRolesParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the get user roles params +func (o *GetUserRolesParams) WithHTTPClient(client *http.Client) *GetUserRolesParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the get user roles params +func (o *GetUserRolesParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithAuthorization adds the authorization to the get user roles params +func (o *GetUserRolesParams) WithAuthorization(authorization string) *GetUserRolesParams { + o.SetAuthorization(authorization) + return o +} + +// SetAuthorization adds the authorization to the get user roles params +func (o *GetUserRolesParams) SetAuthorization(authorization string) { + o.Authorization = authorization +} + +// WithUserID adds the userID to the get user roles params +func (o *GetUserRolesParams) WithUserID(userID string) *GetUserRolesParams { + o.SetUserID(userID) + return o +} + +// SetUserID adds the userId to the get user roles params +func (o *GetUserRolesParams) SetUserID(userID string) { + o.UserID = userID +} + +// WriteToRequest writes these params to a swagger request +func (o *GetUserRolesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // header param Authorization + if err := r.SetHeaderParam("Authorization", o.Authorization); err != nil { + return err + } + + // path param userId + if err := r.SetPathParam("userId", o.UserID); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/auth0/auth0_client/user/get_user_roles_responses.go b/api/auth0/auth0_client/user/get_user_roles_responses.go new file mode 100644 index 0000000..4e69b2a --- /dev/null +++ b/api/auth0/auth0_client/user/get_user_roles_responses.go @@ -0,0 +1,229 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package user + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/auth0/auth0_models" +) + +// GetUserRolesReader is a Reader for the GetUserRoles structure. +type GetUserRolesReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *GetUserRolesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewGetUserRolesOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewGetUserRolesUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewGetUserRolesForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewGetUserRolesNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewGetUserRolesInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + + default: + return nil, runtime.NewAPIError("unknown error", response, response.Code()) + } +} + +// NewGetUserRolesOK creates a GetUserRolesOK with default headers values +func NewGetUserRolesOK() *GetUserRolesOK { + return &GetUserRolesOK{} +} + +/*GetUserRolesOK handles this case with default header values. + +Taxnexus Response with User objects +*/ +type GetUserRolesOK struct { + Payload *auth0_models.RoleResponse +} + +func (o *GetUserRolesOK) Error() string { + return fmt.Sprintf("[GET /api/v2/users/{userId}/roles][%d] getUserRolesOK %+v", 200, o.Payload) +} + +func (o *GetUserRolesOK) GetPayload() *auth0_models.RoleResponse { + return o.Payload +} + +func (o *GetUserRolesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.RoleResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetUserRolesUnauthorized creates a GetUserRolesUnauthorized with default headers values +func NewGetUserRolesUnauthorized() *GetUserRolesUnauthorized { + return &GetUserRolesUnauthorized{} +} + +/*GetUserRolesUnauthorized handles this case with default header values. + +Access Unauthorized, invalid API-KEY was used +*/ +type GetUserRolesUnauthorized struct { + Payload *auth0_models.Error +} + +func (o *GetUserRolesUnauthorized) Error() string { + return fmt.Sprintf("[GET /api/v2/users/{userId}/roles][%d] getUserRolesUnauthorized %+v", 401, o.Payload) +} + +func (o *GetUserRolesUnauthorized) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetUserRolesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetUserRolesForbidden creates a GetUserRolesForbidden with default headers values +func NewGetUserRolesForbidden() *GetUserRolesForbidden { + return &GetUserRolesForbidden{} +} + +/*GetUserRolesForbidden handles this case with default header values. + +Access forbidden, account lacks access +*/ +type GetUserRolesForbidden struct { + Payload *auth0_models.Error +} + +func (o *GetUserRolesForbidden) Error() string { + return fmt.Sprintf("[GET /api/v2/users/{userId}/roles][%d] getUserRolesForbidden %+v", 403, o.Payload) +} + +func (o *GetUserRolesForbidden) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetUserRolesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetUserRolesNotFound creates a GetUserRolesNotFound with default headers values +func NewGetUserRolesNotFound() *GetUserRolesNotFound { + return &GetUserRolesNotFound{} +} + +/*GetUserRolesNotFound handles this case with default header values. + +Resource was not found +*/ +type GetUserRolesNotFound struct { + Payload *auth0_models.Error +} + +func (o *GetUserRolesNotFound) Error() string { + return fmt.Sprintf("[GET /api/v2/users/{userId}/roles][%d] getUserRolesNotFound %+v", 404, o.Payload) +} + +func (o *GetUserRolesNotFound) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetUserRolesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetUserRolesInternalServerError creates a GetUserRolesInternalServerError with default headers values +func NewGetUserRolesInternalServerError() *GetUserRolesInternalServerError { + return &GetUserRolesInternalServerError{} +} + +/*GetUserRolesInternalServerError handles this case with default header values. + +Server Internal Error +*/ +type GetUserRolesInternalServerError struct { + Payload *auth0_models.Error +} + +func (o *GetUserRolesInternalServerError) Error() string { + return fmt.Sprintf("[GET /api/v2/users/{userId}/roles][%d] getUserRolesInternalServerError %+v", 500, o.Payload) +} + +func (o *GetUserRolesInternalServerError) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetUserRolesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/auth0/auth0_client/user/get_users_parameters.go b/api/auth0/auth0_client/user/get_users_parameters.go new file mode 100644 index 0000000..9f0ddab --- /dev/null +++ b/api/auth0/auth0_client/user/get_users_parameters.go @@ -0,0 +1,136 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package user + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewGetUsersParams creates a new GetUsersParams object +// with the default values initialized. +func NewGetUsersParams() *GetUsersParams { + var () + return &GetUsersParams{ + + timeout: cr.DefaultTimeout, + } +} + +// NewGetUsersParamsWithTimeout creates a new GetUsersParams object +// with the default values initialized, and the ability to set a timeout on a request +func NewGetUsersParamsWithTimeout(timeout time.Duration) *GetUsersParams { + var () + return &GetUsersParams{ + + timeout: timeout, + } +} + +// NewGetUsersParamsWithContext creates a new GetUsersParams object +// with the default values initialized, and the ability to set a context for a request +func NewGetUsersParamsWithContext(ctx context.Context) *GetUsersParams { + var () + return &GetUsersParams{ + + Context: ctx, + } +} + +// NewGetUsersParamsWithHTTPClient creates a new GetUsersParams object +// with the default values initialized, and the ability to set a custom HTTPClient for a request +func NewGetUsersParamsWithHTTPClient(client *http.Client) *GetUsersParams { + var () + return &GetUsersParams{ + HTTPClient: client, + } +} + +/*GetUsersParams contains all the parameters to send to the API endpoint +for the get users operation typically these are written to a http.Request +*/ +type GetUsersParams struct { + + /*Authorization*/ + Authorization string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithTimeout adds the timeout to the get users params +func (o *GetUsersParams) WithTimeout(timeout time.Duration) *GetUsersParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the get users params +func (o *GetUsersParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the get users params +func (o *GetUsersParams) WithContext(ctx context.Context) *GetUsersParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the get users params +func (o *GetUsersParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the get users params +func (o *GetUsersParams) WithHTTPClient(client *http.Client) *GetUsersParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the get users params +func (o *GetUsersParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithAuthorization adds the authorization to the get users params +func (o *GetUsersParams) WithAuthorization(authorization string) *GetUsersParams { + o.SetAuthorization(authorization) + return o +} + +// SetAuthorization adds the authorization to the get users params +func (o *GetUsersParams) SetAuthorization(authorization string) { + o.Authorization = authorization +} + +// WriteToRequest writes these params to a swagger request +func (o *GetUsersParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // header param Authorization + if err := r.SetHeaderParam("Authorization", o.Authorization); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/auth0/auth0_client/user/get_users_responses.go b/api/auth0/auth0_client/user/get_users_responses.go new file mode 100644 index 0000000..45fd811 --- /dev/null +++ b/api/auth0/auth0_client/user/get_users_responses.go @@ -0,0 +1,227 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package user + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/auth0/auth0_models" +) + +// GetUsersReader is a Reader for the GetUsers structure. +type GetUsersReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *GetUsersReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewGetUsersOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewGetUsersUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewGetUsersForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewGetUsersNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewGetUsersInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + + default: + return nil, runtime.NewAPIError("unknown error", response, response.Code()) + } +} + +// NewGetUsersOK creates a GetUsersOK with default headers values +func NewGetUsersOK() *GetUsersOK { + return &GetUsersOK{} +} + +/*GetUsersOK handles this case with default header values. + +Taxnexus Response with User objects +*/ +type GetUsersOK struct { + Payload []*auth0_models.User +} + +func (o *GetUsersOK) Error() string { + return fmt.Sprintf("[GET /api/v2/users][%d] getUsersOK %+v", 200, o.Payload) +} + +func (o *GetUsersOK) GetPayload() []*auth0_models.User { + return o.Payload +} + +func (o *GetUsersOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + // response payload + if err := consumer.Consume(response.Body(), &o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetUsersUnauthorized creates a GetUsersUnauthorized with default headers values +func NewGetUsersUnauthorized() *GetUsersUnauthorized { + return &GetUsersUnauthorized{} +} + +/*GetUsersUnauthorized handles this case with default header values. + +Access Unauthorized, invalid API-KEY was used +*/ +type GetUsersUnauthorized struct { + Payload *auth0_models.Error +} + +func (o *GetUsersUnauthorized) Error() string { + return fmt.Sprintf("[GET /api/v2/users][%d] getUsersUnauthorized %+v", 401, o.Payload) +} + +func (o *GetUsersUnauthorized) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetUsersUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetUsersForbidden creates a GetUsersForbidden with default headers values +func NewGetUsersForbidden() *GetUsersForbidden { + return &GetUsersForbidden{} +} + +/*GetUsersForbidden handles this case with default header values. + +Access forbidden, account lacks access +*/ +type GetUsersForbidden struct { + Payload *auth0_models.Error +} + +func (o *GetUsersForbidden) Error() string { + return fmt.Sprintf("[GET /api/v2/users][%d] getUsersForbidden %+v", 403, o.Payload) +} + +func (o *GetUsersForbidden) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetUsersForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetUsersNotFound creates a GetUsersNotFound with default headers values +func NewGetUsersNotFound() *GetUsersNotFound { + return &GetUsersNotFound{} +} + +/*GetUsersNotFound handles this case with default header values. + +Resource was not found +*/ +type GetUsersNotFound struct { + Payload *auth0_models.Error +} + +func (o *GetUsersNotFound) Error() string { + return fmt.Sprintf("[GET /api/v2/users][%d] getUsersNotFound %+v", 404, o.Payload) +} + +func (o *GetUsersNotFound) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetUsersNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetUsersInternalServerError creates a GetUsersInternalServerError with default headers values +func NewGetUsersInternalServerError() *GetUsersInternalServerError { + return &GetUsersInternalServerError{} +} + +/*GetUsersInternalServerError handles this case with default header values. + +Server Internal Error +*/ +type GetUsersInternalServerError struct { + Payload *auth0_models.Error +} + +func (o *GetUsersInternalServerError) Error() string { + return fmt.Sprintf("[GET /api/v2/users][%d] getUsersInternalServerError %+v", 500, o.Payload) +} + +func (o *GetUsersInternalServerError) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *GetUsersInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/auth0/auth0_client/user/post_users_parameters.go b/api/auth0/auth0_client/user/post_users_parameters.go new file mode 100644 index 0000000..c16cf2f --- /dev/null +++ b/api/auth0/auth0_client/user/post_users_parameters.go @@ -0,0 +1,160 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package user + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/auth0/auth0_models" +) + +// NewPostUsersParams creates a new PostUsersParams object +// with the default values initialized. +func NewPostUsersParams() *PostUsersParams { + var () + return &PostUsersParams{ + + timeout: cr.DefaultTimeout, + } +} + +// NewPostUsersParamsWithTimeout creates a new PostUsersParams object +// with the default values initialized, and the ability to set a timeout on a request +func NewPostUsersParamsWithTimeout(timeout time.Duration) *PostUsersParams { + var () + return &PostUsersParams{ + + timeout: timeout, + } +} + +// NewPostUsersParamsWithContext creates a new PostUsersParams object +// with the default values initialized, and the ability to set a context for a request +func NewPostUsersParamsWithContext(ctx context.Context) *PostUsersParams { + var () + return &PostUsersParams{ + + Context: ctx, + } +} + +// NewPostUsersParamsWithHTTPClient creates a new PostUsersParams object +// with the default values initialized, and the ability to set a custom HTTPClient for a request +func NewPostUsersParamsWithHTTPClient(client *http.Client) *PostUsersParams { + var () + return &PostUsersParams{ + HTTPClient: client, + } +} + +/*PostUsersParams contains all the parameters to send to the API endpoint +for the post users operation typically these are written to a http.Request +*/ +type PostUsersParams struct { + + /*Authorization*/ + Authorization string + /*UserRequest + An array of User records + + */ + UserRequest *auth0_models.UserRequest + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithTimeout adds the timeout to the post users params +func (o *PostUsersParams) WithTimeout(timeout time.Duration) *PostUsersParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the post users params +func (o *PostUsersParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the post users params +func (o *PostUsersParams) WithContext(ctx context.Context) *PostUsersParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the post users params +func (o *PostUsersParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the post users params +func (o *PostUsersParams) WithHTTPClient(client *http.Client) *PostUsersParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the post users params +func (o *PostUsersParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithAuthorization adds the authorization to the post users params +func (o *PostUsersParams) WithAuthorization(authorization string) *PostUsersParams { + o.SetAuthorization(authorization) + return o +} + +// SetAuthorization adds the authorization to the post users params +func (o *PostUsersParams) SetAuthorization(authorization string) { + o.Authorization = authorization +} + +// WithUserRequest adds the userRequest to the post users params +func (o *PostUsersParams) WithUserRequest(userRequest *auth0_models.UserRequest) *PostUsersParams { + o.SetUserRequest(userRequest) + return o +} + +// SetUserRequest adds the userRequest to the post users params +func (o *PostUsersParams) SetUserRequest(userRequest *auth0_models.UserRequest) { + o.UserRequest = userRequest +} + +// WriteToRequest writes these params to a swagger request +func (o *PostUsersParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // header param Authorization + if err := r.SetHeaderParam("Authorization", o.Authorization); err != nil { + return err + } + + if o.UserRequest != nil { + if err := r.SetBodyParam(o.UserRequest); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/auth0/auth0_client/user/post_users_responses.go b/api/auth0/auth0_client/user/post_users_responses.go new file mode 100644 index 0000000..19dd515 --- /dev/null +++ b/api/auth0/auth0_client/user/post_users_responses.go @@ -0,0 +1,244 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package user + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/auth0/auth0_models" +) + +// PostUsersReader is a Reader for the PostUsers structure. +type PostUsersReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *PostUsersReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 201: + result := NewPostUsersCreated() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewPostUsersUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewPostUsersForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewPostUsersNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 409: + result := NewPostUsersConflict() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewPostUsersInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + + default: + return nil, runtime.NewAPIError("unknown error", response, response.Code()) + } +} + +// NewPostUsersCreated creates a PostUsersCreated with default headers values +func NewPostUsersCreated() *PostUsersCreated { + return &PostUsersCreated{} +} + +/*PostUsersCreated handles this case with default header values. + +New user created +*/ +type PostUsersCreated struct { +} + +func (o *PostUsersCreated) Error() string { + return fmt.Sprintf("[POST /api/v2/users-by-email][%d] postUsersCreated ", 201) +} + +func (o *PostUsersCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} + +// NewPostUsersUnauthorized creates a PostUsersUnauthorized with default headers values +func NewPostUsersUnauthorized() *PostUsersUnauthorized { + return &PostUsersUnauthorized{} +} + +/*PostUsersUnauthorized handles this case with default header values. + +Access Unauthorized, invalid API-KEY was used +*/ +type PostUsersUnauthorized struct { + Payload *auth0_models.Error +} + +func (o *PostUsersUnauthorized) Error() string { + return fmt.Sprintf("[POST /api/v2/users-by-email][%d] postUsersUnauthorized %+v", 401, o.Payload) +} + +func (o *PostUsersUnauthorized) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *PostUsersUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostUsersForbidden creates a PostUsersForbidden with default headers values +func NewPostUsersForbidden() *PostUsersForbidden { + return &PostUsersForbidden{} +} + +/*PostUsersForbidden handles this case with default header values. + +Access forbidden, account lacks access +*/ +type PostUsersForbidden struct { + Payload *auth0_models.Error +} + +func (o *PostUsersForbidden) Error() string { + return fmt.Sprintf("[POST /api/v2/users-by-email][%d] postUsersForbidden %+v", 403, o.Payload) +} + +func (o *PostUsersForbidden) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *PostUsersForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostUsersNotFound creates a PostUsersNotFound with default headers values +func NewPostUsersNotFound() *PostUsersNotFound { + return &PostUsersNotFound{} +} + +/*PostUsersNotFound handles this case with default header values. + +Resource was not found +*/ +type PostUsersNotFound struct { + Payload *auth0_models.Error +} + +func (o *PostUsersNotFound) Error() string { + return fmt.Sprintf("[POST /api/v2/users-by-email][%d] postUsersNotFound %+v", 404, o.Payload) +} + +func (o *PostUsersNotFound) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *PostUsersNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostUsersConflict creates a PostUsersConflict with default headers values +func NewPostUsersConflict() *PostUsersConflict { + return &PostUsersConflict{} +} + +/*PostUsersConflict handles this case with default header values. + +User already exists +*/ +type PostUsersConflict struct { +} + +func (o *PostUsersConflict) Error() string { + return fmt.Sprintf("[POST /api/v2/users-by-email][%d] postUsersConflict ", 409) +} + +func (o *PostUsersConflict) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} + +// NewPostUsersInternalServerError creates a PostUsersInternalServerError with default headers values +func NewPostUsersInternalServerError() *PostUsersInternalServerError { + return &PostUsersInternalServerError{} +} + +/*PostUsersInternalServerError handles this case with default header values. + +Server Internal Error +*/ +type PostUsersInternalServerError struct { + Payload *auth0_models.Error +} + +func (o *PostUsersInternalServerError) Error() string { + return fmt.Sprintf("[POST /api/v2/users-by-email][%d] postUsersInternalServerError %+v", 500, o.Payload) +} + +func (o *PostUsersInternalServerError) GetPayload() *auth0_models.Error { + return o.Payload +} + +func (o *PostUsersInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(auth0_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/auth0/auth0_client/user/user_client.go b/api/auth0/auth0_client/user/user_client.go new file mode 100644 index 0000000..4330279 --- /dev/null +++ b/api/auth0/auth0_client/user/user_client.go @@ -0,0 +1,228 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package user + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// New creates a new user API client. +func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { + return &Client{transport: transport, formats: formats} +} + +/* +Client for user API +*/ +type Client struct { + transport runtime.ClientTransport + formats strfmt.Registry +} + +// ClientService is the interface for Client methods +type ClientService interface { + DeleteAPIV2UsersUserIDRoles(params *DeleteAPIV2UsersUserIDRolesParams) (*DeleteAPIV2UsersUserIDRolesNoContent, error) + + GetUserByEmail(params *GetUserByEmailParams) (*GetUserByEmailOK, error) + + GetUserRoles(params *GetUserRolesParams) (*GetUserRolesOK, error) + + GetUsers(params *GetUsersParams) (*GetUsersOK, error) + + PostUsers(params *PostUsersParams) (*PostUsersCreated, error) + + SetTransport(transport runtime.ClientTransport) +} + +/* + DeleteAPIV2UsersUserIDRoles delete API v2 users user ID roles API +*/ +func (a *Client) DeleteAPIV2UsersUserIDRoles(params *DeleteAPIV2UsersUserIDRolesParams) (*DeleteAPIV2UsersUserIDRolesNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewDeleteAPIV2UsersUserIDRolesParams() + } + + result, err := a.transport.Submit(&runtime.ClientOperation{ + ID: "DeleteAPIV2UsersUserIDRoles", + Method: "DELETE", + PathPattern: "/api/v2/users/{userId}/roles", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"https"}, + Params: params, + Reader: &DeleteAPIV2UsersUserIDRolesReader{formats: a.formats}, + Context: params.Context, + Client: params.HTTPClient, + }) + if err != nil { + return nil, err + } + success, ok := result.(*DeleteAPIV2UsersUserIDRolesNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for DeleteAPIV2UsersUserIDRoles: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + GetUserByEmail gets a single user from auth0 by email address + + Get a single user from Auth0 by Email Address +*/ +func (a *Client) GetUserByEmail(params *GetUserByEmailParams) (*GetUserByEmailOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewGetUserByEmailParams() + } + + result, err := a.transport.Submit(&runtime.ClientOperation{ + ID: "getUserByEmail", + Method: "GET", + PathPattern: "/api/v2/users-by-email", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"https"}, + Params: params, + Reader: &GetUserByEmailReader{formats: a.formats}, + Context: params.Context, + Client: params.HTTPClient, + }) + if err != nil { + return nil, err + } + success, ok := result.(*GetUserByEmailOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for getUserByEmail: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + GetUserRoles gets a user s roles + + Get a User's Roles +*/ +func (a *Client) GetUserRoles(params *GetUserRolesParams) (*GetUserRolesOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewGetUserRolesParams() + } + + result, err := a.transport.Submit(&runtime.ClientOperation{ + ID: "getUserRoles", + Method: "GET", + PathPattern: "/api/v2/users/{userId}/roles", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"https"}, + Params: params, + Reader: &GetUserRolesReader{formats: a.formats}, + Context: params.Context, + Client: params.HTTPClient, + }) + if err != nil { + return nil, err + } + success, ok := result.(*GetUserRolesOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for getUserRoles: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + GetUsers gets all users from auth0 + + Get all users from Auth0 +*/ +func (a *Client) GetUsers(params *GetUsersParams) (*GetUsersOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewGetUsersParams() + } + + result, err := a.transport.Submit(&runtime.ClientOperation{ + ID: "getUsers", + Method: "GET", + PathPattern: "/api/v2/users", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"https"}, + Params: params, + Reader: &GetUsersReader{formats: a.formats}, + Context: params.Context, + Client: params.HTTPClient, + }) + if err != nil { + return nil, err + } + success, ok := result.(*GetUsersOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for getUsers: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + PostUsers creates new auth0 user + + create new Auth0 user +*/ +func (a *Client) PostUsers(params *PostUsersParams) (*PostUsersCreated, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewPostUsersParams() + } + + result, err := a.transport.Submit(&runtime.ClientOperation{ + ID: "postUsers", + Method: "POST", + PathPattern: "/api/v2/users-by-email", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"https"}, + Params: params, + Reader: &PostUsersReader{formats: a.formats}, + Context: params.Context, + Client: params.HTTPClient, + }) + if err != nil { + return nil, err + } + success, ok := result.(*PostUsersCreated) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for postUsers: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +// SetTransport changes the transport on the client +func (a *Client) SetTransport(transport runtime.ClientTransport) { + a.transport = transport +} diff --git a/api/auth0/auth0_models/credentials_request.go b/api/auth0/auth0_models/credentials_request.go new file mode 100644 index 0000000..ad8d8b2 --- /dev/null +++ b/api/auth0/auth0_models/credentials_request.go @@ -0,0 +1,56 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package auth0_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// CredentialsRequest credentials request +// +// swagger:model CredentialsRequest +type CredentialsRequest struct { + + // audience + Audience string `json:"audience,omitempty"` + + // client id + ClientID string `json:"client_id,omitempty"` + + // client secret + ClientSecret string `json:"client_secret,omitempty"` + + // grant type + GrantType string `json:"grant_type,omitempty"` +} + +// Validate validates this credentials request +func (m *CredentialsRequest) Validate(formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *CredentialsRequest) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *CredentialsRequest) UnmarshalBinary(b []byte) error { + var res CredentialsRequest + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/auth0/auth0_models/credentials_response.go b/api/auth0/auth0_models/credentials_response.go new file mode 100644 index 0000000..57ac7a6 --- /dev/null +++ b/api/auth0/auth0_models/credentials_response.go @@ -0,0 +1,56 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package auth0_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// CredentialsResponse credentials response +// +// swagger:model CredentialsResponse +type CredentialsResponse struct { + + // access token + AccessToken string `json:"access_token,omitempty"` + + // expires in + ExpiresIn int64 `json:"expires_in,omitempty"` + + // scope + Scope string `json:"scope,omitempty"` + + // token type + TokenType string `json:"token_type,omitempty"` +} + +// Validate validates this credentials response +func (m *CredentialsResponse) Validate(formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *CredentialsResponse) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *CredentialsResponse) UnmarshalBinary(b []byte) error { + var res CredentialsResponse + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/kazoo/kazoo_models/error.go b/api/auth0/auth0_models/error.go similarity index 81% rename from api/kazoo/kazoo_models/error.go rename to api/auth0/auth0_models/error.go index 304b57a..8f2db18 100644 --- a/api/kazoo/kazoo_models/error.go +++ b/api/auth0/auth0_models/error.go @@ -1,17 +1,15 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package kazoo_models +package auth0_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command import ( - "context" - "github.com/go-openapi/strfmt" "github.com/go-openapi/swag" ) @@ -36,11 +34,6 @@ func (m *Error) Validate(formats strfmt.Registry) error { return nil } -// ContextValidate validates this error based on context it is used -func (m *Error) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - // MarshalBinary interface implementation func (m *Error) MarshalBinary() ([]byte, error) { if m == nil { diff --git a/api/auth0/auth0_models/new_user.go b/api/auth0/auth0_models/new_user.go new file mode 100644 index 0000000..09408c7 --- /dev/null +++ b/api/auth0/auth0_models/new_user.go @@ -0,0 +1,89 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package auth0_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewUser new user +// +// swagger:model NewUser +type NewUser struct { + + // blocked + Blocked bool `json:"blocked,omitempty"` + + // connection + Connection string `json:"connection,omitempty"` + + // email + Email string `json:"email,omitempty"` + + // email verified + EmailVerified bool `json:"email_verified,omitempty"` + + // family name + FamilyName string `json:"family_name,omitempty"` + + // given name + GivenName string `json:"given_name,omitempty"` + + // name + Name string `json:"name,omitempty"` + + // nickname + Nickname string `json:"nickname,omitempty"` + + // password + Password string `json:"password,omitempty"` + + // phone number + PhoneNumber string `json:"phone_number,omitempty"` + + // phone verified + PhoneVerified bool `json:"phone_verified,omitempty"` + + // picture + Picture string `json:"picture,omitempty"` + + // user id + UserID string `json:"user_id,omitempty"` + + // username + Username string `json:"username,omitempty"` + + // verify email + VerifyEmail bool `json:"verify_email,omitempty"` +} + +// Validate validates this new user +func (m *NewUser) Validate(formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *NewUser) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *NewUser) UnmarshalBinary(b []byte) error { + var res NewUser + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/auth0/auth0_models/role.go b/api/auth0/auth0_models/role.go new file mode 100644 index 0000000..62507be --- /dev/null +++ b/api/auth0/auth0_models/role.go @@ -0,0 +1,53 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package auth0_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// Role role +// +// swagger:model Role +type Role struct { + + // description + Description string `json:"description,omitempty"` + + // id + ID string `json:"id,omitempty"` + + // name + Name string `json:"name,omitempty"` +} + +// Validate validates this role +func (m *Role) Validate(formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *Role) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *Role) UnmarshalBinary(b []byte) error { + var res Role + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/auth0/auth0_models/role_response.go b/api/auth0/auth0_models/role_response.go new file mode 100644 index 0000000..8b5a2aa --- /dev/null +++ b/api/auth0/auth0_models/role_response.go @@ -0,0 +1,84 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package auth0_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// RoleResponse role response +// +// swagger:model RoleResponse +type RoleResponse struct { + + // roles + Roles []*Role `json:"roles"` +} + +// Validate validates this role response +func (m *RoleResponse) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateRoles(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *RoleResponse) validateRoles(formats strfmt.Registry) error { + + if swag.IsZero(m.Roles) { // not required + return nil + } + + for i := 0; i < len(m.Roles); i++ { + if swag.IsZero(m.Roles[i]) { // not required + continue + } + + if m.Roles[i] != nil { + if err := m.Roles[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("roles" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (m *RoleResponse) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *RoleResponse) UnmarshalBinary(b []byte) error { + var res RoleResponse + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/auth0/auth0_models/role_users_request.go b/api/auth0/auth0_models/role_users_request.go new file mode 100644 index 0000000..48ddc63 --- /dev/null +++ b/api/auth0/auth0_models/role_users_request.go @@ -0,0 +1,47 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package auth0_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// RoleUsersRequest role users request +// +// swagger:model RoleUsersRequest +type RoleUsersRequest struct { + + // users + Users []string `json:"users"` +} + +// Validate validates this role users request +func (m *RoleUsersRequest) Validate(formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *RoleUsersRequest) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *RoleUsersRequest) UnmarshalBinary(b []byte) error { + var res RoleUsersRequest + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/auth0/auth0_models/user.go b/api/auth0/auth0_models/user.go new file mode 100644 index 0000000..2fdb7c5 --- /dev/null +++ b/api/auth0/auth0_models/user.go @@ -0,0 +1,305 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package auth0_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// User user +// +// swagger:model User +type User struct { + + // app metadata + AppMetadata *UserAppMetadata `json:"app_metadata,omitempty"` + + // created at + CreatedAt string `json:"created_at,omitempty"` + + // email + Email string `json:"email,omitempty"` + + // email verified + EmailVerified bool `json:"email_verified,omitempty"` + + // family name + FamilyName string `json:"family_name,omitempty"` + + // given name + GivenName string `json:"given_name,omitempty"` + + // identities + Identities []*UserIdentitiesItems0 `json:"identities"` + + // last ip + LastIP string `json:"last_ip,omitempty"` + + // last login + LastLogin string `json:"last_login,omitempty"` + + // last password reset + LastPasswordReset string `json:"last_password_reset,omitempty"` + + // logins count + LoginsCount int64 `json:"logins_count,omitempty"` + + // multifactor last modified + MultifactorLastModified string `json:"multifactor_last_modified,omitempty"` + + // name + Name string `json:"name,omitempty"` + + // nickname + Nickname string `json:"nickname,omitempty"` + + // picture + Picture string `json:"picture,omitempty"` + + // updated at + UpdatedAt string `json:"updated_at,omitempty"` + + // user id + UserID string `json:"user_id,omitempty"` + + // user metadata + UserMetadata *UserUserMetadata `json:"user_metadata,omitempty"` +} + +// Validate validates this user +func (m *User) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateAppMetadata(formats); err != nil { + res = append(res, err) + } + + if err := m.validateIdentities(formats); err != nil { + res = append(res, err) + } + + if err := m.validateUserMetadata(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *User) validateAppMetadata(formats strfmt.Registry) error { + + if swag.IsZero(m.AppMetadata) { // not required + return nil + } + + if m.AppMetadata != nil { + if err := m.AppMetadata.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("app_metadata") + } + return err + } + } + + return nil +} + +func (m *User) validateIdentities(formats strfmt.Registry) error { + + if swag.IsZero(m.Identities) { // not required + return nil + } + + for i := 0; i < len(m.Identities); i++ { + if swag.IsZero(m.Identities[i]) { // not required + continue + } + + if m.Identities[i] != nil { + if err := m.Identities[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("identities" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *User) validateUserMetadata(formats strfmt.Registry) error { + + if swag.IsZero(m.UserMetadata) { // not required + return nil + } + + if m.UserMetadata != nil { + if err := m.UserMetadata.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("user_metadata") + } + return err + } + } + + return nil +} + +// MarshalBinary interface implementation +func (m *User) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *User) UnmarshalBinary(b []byte) error { + var res User + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} + +// UserAppMetadata user app metadata +// +// swagger:model UserAppMetadata +type UserAppMetadata struct { + + // roles + Roles []string `json:"roles"` + + // taxnexus account id + TaxnexusAccountID string `json:"taxnexus_account_id,omitempty"` + + // taxnexus contact id + TaxnexusContactID string `json:"taxnexus_contact_id,omitempty"` + + // taxnexus user id + TaxnexusUserID string `json:"taxnexus_user_id,omitempty"` +} + +// Validate validates this user app metadata +func (m *UserAppMetadata) Validate(formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *UserAppMetadata) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *UserAppMetadata) UnmarshalBinary(b []byte) error { + var res UserAppMetadata + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} + +// UserIdentitiesItems0 user identities items0 +// +// swagger:model UserIdentitiesItems0 +type UserIdentitiesItems0 struct { + + // connection + Connection string `json:"connection,omitempty"` + + // is social + IsSocial bool `json:"isSocial,omitempty"` + + // provider + Provider string `json:"provider,omitempty"` + + // user id + UserID string `json:"user_id,omitempty"` +} + +// Validate validates this user identities items0 +func (m *UserIdentitiesItems0) Validate(formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *UserIdentitiesItems0) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *UserIdentitiesItems0) UnmarshalBinary(b []byte) error { + var res UserIdentitiesItems0 + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} + +// UserUserMetadata user user metadata +// +// swagger:model UserUserMetadata +type UserUserMetadata struct { + + // taxnexus email + TaxnexusEmail string `json:"taxnexus_email,omitempty"` + + // taxnexus firstname + TaxnexusFirstname string `json:"taxnexus_firstname,omitempty"` + + // taxnexus fullname + TaxnexusFullname string `json:"taxnexus_fullname,omitempty"` + + // taxnexus lastname + TaxnexusLastname string `json:"taxnexus_lastname,omitempty"` + + // taxnexus phone + TaxnexusPhone string `json:"taxnexus_phone,omitempty"` +} + +// Validate validates this user user metadata +func (m *UserUserMetadata) Validate(formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *UserUserMetadata) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *UserUserMetadata) UnmarshalBinary(b []byte) error { + var res UserUserMetadata + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/auth0/auth0_models/user_request.go b/api/auth0/auth0_models/user_request.go new file mode 100644 index 0000000..d81d54e --- /dev/null +++ b/api/auth0/auth0_models/user_request.go @@ -0,0 +1,84 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package auth0_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// UserRequest An array Auth0 new user objects +// +// swagger:model UserRequest +type UserRequest struct { + + // users + Users []*NewUser `json:"users"` +} + +// Validate validates this user request +func (m *UserRequest) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateUsers(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *UserRequest) validateUsers(formats strfmt.Registry) error { + + if swag.IsZero(m.Users) { // not required + return nil + } + + for i := 0; i < len(m.Users); i++ { + if swag.IsZero(m.Users[i]) { // not required + continue + } + + if m.Users[i] != nil { + if err := m.Users[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("users" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (m *UserRequest) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *UserRequest) UnmarshalBinary(b []byte) error { + var res UserRequest + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/auth0/auth0_models/user_roles_request.go b/api/auth0/auth0_models/user_roles_request.go new file mode 100644 index 0000000..81bf41c --- /dev/null +++ b/api/auth0/auth0_models/user_roles_request.go @@ -0,0 +1,47 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package auth0_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// UserRolesRequest user roles request +// +// swagger:model UserRolesRequest +type UserRolesRequest struct { + + // roles + Roles []string `json:"roles"` +} + +// Validate validates this user roles request +func (m *UserRolesRequest) Validate(formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *UserRolesRequest) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *UserRolesRequest) UnmarshalBinary(b []byte) error { + var res UserRolesRequest + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/cloud/cloud_client/cors/account_options_parameters.go b/api/cloud/cloud_client/cors/account_options_parameters.go deleted file mode 100644 index 435c1b6..0000000 --- a/api/cloud/cloud_client/cors/account_options_parameters.go +++ /dev/null @@ -1,130 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package cors - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" -) - -// NewAccountOptionsParams creates a new AccountOptionsParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewAccountOptionsParams() *AccountOptionsParams { - return &AccountOptionsParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewAccountOptionsParamsWithTimeout creates a new AccountOptionsParams object -// with the ability to set a timeout on a request. -func NewAccountOptionsParamsWithTimeout(timeout time.Duration) *AccountOptionsParams { - return &AccountOptionsParams{ - timeout: timeout, - } -} - -// NewAccountOptionsParamsWithContext creates a new AccountOptionsParams object -// with the ability to set a context for a request. -func NewAccountOptionsParamsWithContext(ctx context.Context) *AccountOptionsParams { - return &AccountOptionsParams{ - Context: ctx, - } -} - -// NewAccountOptionsParamsWithHTTPClient creates a new AccountOptionsParams object -// with the ability to set a custom HTTPClient for a request. -func NewAccountOptionsParamsWithHTTPClient(client *http.Client) *AccountOptionsParams { - return &AccountOptionsParams{ - HTTPClient: client, - } -} - -/* AccountOptionsParams contains all the parameters to send to the API endpoint - for the account options operation. - - Typically these are written to a http.Request. -*/ -type AccountOptionsParams struct { - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the account options params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *AccountOptionsParams) WithDefaults() *AccountOptionsParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the account options params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *AccountOptionsParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the account options params -func (o *AccountOptionsParams) WithTimeout(timeout time.Duration) *AccountOptionsParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the account options params -func (o *AccountOptionsParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the account options params -func (o *AccountOptionsParams) WithContext(ctx context.Context) *AccountOptionsParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the account options params -func (o *AccountOptionsParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the account options params -func (o *AccountOptionsParams) WithHTTPClient(client *http.Client) *AccountOptionsParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the account options params -func (o *AccountOptionsParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WriteToRequest writes these params to a swagger request -func (o *AccountOptionsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/cloud/cloud_client/cors/account_options_responses.go b/api/cloud/cloud_client/cors/account_options_responses.go deleted file mode 100644 index 6ee4203..0000000 --- a/api/cloud/cloud_client/cors/account_options_responses.go +++ /dev/null @@ -1,113 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package cors - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" -) - -// AccountOptionsReader is a Reader for the AccountOptions structure. -type AccountOptionsReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *AccountOptionsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewAccountOptionsOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewAccountOptionsOK creates a AccountOptionsOK with default headers values -func NewAccountOptionsOK() *AccountOptionsOK { - return &AccountOptionsOK{} -} - -/* AccountOptionsOK describes a response with status code 200, with default header values. - -CORS OPTIONS response -*/ -type AccountOptionsOK struct { - AccessControlAllowCredentials string - AccessControlAllowHeaders string - AccessControlAllowMethods string - AccessControlAllowOrigin string - AccessControlExposeHeaders string - AccessControlMaxAge string - CacheControl string -} - -func (o *AccountOptionsOK) Error() string { - return fmt.Sprintf("[OPTIONS /hubs][%d] accountOptionsOK ", 200) -} - -func (o *AccountOptionsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - // hydrates response header Access-Control-Allow-Credentials - hdrAccessControlAllowCredentials := response.GetHeader("Access-Control-Allow-Credentials") - - if hdrAccessControlAllowCredentials != "" { - o.AccessControlAllowCredentials = hdrAccessControlAllowCredentials - } - - // hydrates response header Access-Control-Allow-Headers - hdrAccessControlAllowHeaders := response.GetHeader("Access-Control-Allow-Headers") - - if hdrAccessControlAllowHeaders != "" { - o.AccessControlAllowHeaders = hdrAccessControlAllowHeaders - } - - // hydrates response header Access-Control-Allow-Methods - hdrAccessControlAllowMethods := response.GetHeader("Access-Control-Allow-Methods") - - if hdrAccessControlAllowMethods != "" { - o.AccessControlAllowMethods = hdrAccessControlAllowMethods - } - - // hydrates response header Access-Control-Allow-Origin - hdrAccessControlAllowOrigin := response.GetHeader("Access-Control-Allow-Origin") - - if hdrAccessControlAllowOrigin != "" { - o.AccessControlAllowOrigin = hdrAccessControlAllowOrigin - } - - // hydrates response header Access-Control-Expose-Headers - hdrAccessControlExposeHeaders := response.GetHeader("Access-Control-Expose-Headers") - - if hdrAccessControlExposeHeaders != "" { - o.AccessControlExposeHeaders = hdrAccessControlExposeHeaders - } - - // hydrates response header Access-Control-Max-Age - hdrAccessControlMaxAge := response.GetHeader("Access-Control-Max-Age") - - if hdrAccessControlMaxAge != "" { - o.AccessControlMaxAge = hdrAccessControlMaxAge - } - - // hydrates response header Cache-Control - hdrCacheControl := response.GetHeader("Cache-Control") - - if hdrCacheControl != "" { - o.CacheControl = hdrCacheControl - } - - return nil -} diff --git a/api/cloud/cloud_client/hub/delete_hub_parameters.go b/api/cloud/cloud_client/hub/delete_hub_parameters.go deleted file mode 100644 index 1ac706a..0000000 --- a/api/cloud/cloud_client/hub/delete_hub_parameters.go +++ /dev/null @@ -1,165 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package hub - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" -) - -// NewDeleteHubParams creates a new DeleteHubParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewDeleteHubParams() *DeleteHubParams { - return &DeleteHubParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewDeleteHubParamsWithTimeout creates a new DeleteHubParams object -// with the ability to set a timeout on a request. -func NewDeleteHubParamsWithTimeout(timeout time.Duration) *DeleteHubParams { - return &DeleteHubParams{ - timeout: timeout, - } -} - -// NewDeleteHubParamsWithContext creates a new DeleteHubParams object -// with the ability to set a context for a request. -func NewDeleteHubParamsWithContext(ctx context.Context) *DeleteHubParams { - return &DeleteHubParams{ - Context: ctx, - } -} - -// NewDeleteHubParamsWithHTTPClient creates a new DeleteHubParams object -// with the ability to set a custom HTTPClient for a request. -func NewDeleteHubParamsWithHTTPClient(client *http.Client) *DeleteHubParams { - return &DeleteHubParams{ - HTTPClient: client, - } -} - -/* DeleteHubParams contains all the parameters to send to the API endpoint - for the delete hub operation. - - Typically these are written to a http.Request. -*/ -type DeleteHubParams struct { - - /* AccountID. - - Taxnexus Record Id of an Account - */ - AccountID *string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the delete hub params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *DeleteHubParams) WithDefaults() *DeleteHubParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the delete hub params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *DeleteHubParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the delete hub params -func (o *DeleteHubParams) WithTimeout(timeout time.Duration) *DeleteHubParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the delete hub params -func (o *DeleteHubParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the delete hub params -func (o *DeleteHubParams) WithContext(ctx context.Context) *DeleteHubParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the delete hub params -func (o *DeleteHubParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the delete hub params -func (o *DeleteHubParams) WithHTTPClient(client *http.Client) *DeleteHubParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the delete hub params -func (o *DeleteHubParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAccountID adds the accountID to the delete hub params -func (o *DeleteHubParams) WithAccountID(accountID *string) *DeleteHubParams { - o.SetAccountID(accountID) - return o -} - -// SetAccountID adds the accountId to the delete hub params -func (o *DeleteHubParams) SetAccountID(accountID *string) { - o.AccountID = accountID -} - -// WriteToRequest writes these params to a swagger request -func (o *DeleteHubParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - if o.AccountID != nil { - - // query param accountId - var qrAccountID string - - if o.AccountID != nil { - qrAccountID = *o.AccountID - } - qAccountID := qrAccountID - if qAccountID != "" { - - if err := r.SetQueryParam("accountId", qAccountID); err != nil { - return err - } - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/cloud/cloud_client/hub/delete_hub_responses.go b/api/cloud/cloud_client/hub/delete_hub_responses.go deleted file mode 100644 index 00be32e..0000000 --- a/api/cloud/cloud_client/hub/delete_hub_responses.go +++ /dev/null @@ -1,270 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package hub - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/cloud/cloud_models" -) - -// DeleteHubReader is a Reader for the DeleteHub structure. -type DeleteHubReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *DeleteHubReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewDeleteHubOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewDeleteHubUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewDeleteHubForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewDeleteHubNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewDeleteHubUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewDeleteHubInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewDeleteHubOK creates a DeleteHubOK with default headers values -func NewDeleteHubOK() *DeleteHubOK { - return &DeleteHubOK{} -} - -/* DeleteHubOK describes a response with status code 200, with default header values. - -Taxnexus Response with Message Objects with Delete Status -*/ -type DeleteHubOK struct { - AccessControlAllowOrigin string - - Payload *cloud_models.DeleteResponse -} - -func (o *DeleteHubOK) Error() string { - return fmt.Sprintf("[DELETE /hubs][%d] deleteHubOK %+v", 200, o.Payload) -} -func (o *DeleteHubOK) GetPayload() *cloud_models.DeleteResponse { - return o.Payload -} - -func (o *DeleteHubOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - // hydrates response header Access-Control-Allow-Origin - hdrAccessControlAllowOrigin := response.GetHeader("Access-Control-Allow-Origin") - - if hdrAccessControlAllowOrigin != "" { - o.AccessControlAllowOrigin = hdrAccessControlAllowOrigin - } - - o.Payload = new(cloud_models.DeleteResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewDeleteHubUnauthorized creates a DeleteHubUnauthorized with default headers values -func NewDeleteHubUnauthorized() *DeleteHubUnauthorized { - return &DeleteHubUnauthorized{} -} - -/* DeleteHubUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type DeleteHubUnauthorized struct { - Payload *cloud_models.Error -} - -func (o *DeleteHubUnauthorized) Error() string { - return fmt.Sprintf("[DELETE /hubs][%d] deleteHubUnauthorized %+v", 401, o.Payload) -} -func (o *DeleteHubUnauthorized) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *DeleteHubUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewDeleteHubForbidden creates a DeleteHubForbidden with default headers values -func NewDeleteHubForbidden() *DeleteHubForbidden { - return &DeleteHubForbidden{} -} - -/* DeleteHubForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type DeleteHubForbidden struct { - Payload *cloud_models.Error -} - -func (o *DeleteHubForbidden) Error() string { - return fmt.Sprintf("[DELETE /hubs][%d] deleteHubForbidden %+v", 403, o.Payload) -} -func (o *DeleteHubForbidden) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *DeleteHubForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewDeleteHubNotFound creates a DeleteHubNotFound with default headers values -func NewDeleteHubNotFound() *DeleteHubNotFound { - return &DeleteHubNotFound{} -} - -/* DeleteHubNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type DeleteHubNotFound struct { - Payload *cloud_models.Error -} - -func (o *DeleteHubNotFound) Error() string { - return fmt.Sprintf("[DELETE /hubs][%d] deleteHubNotFound %+v", 404, o.Payload) -} -func (o *DeleteHubNotFound) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *DeleteHubNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewDeleteHubUnprocessableEntity creates a DeleteHubUnprocessableEntity with default headers values -func NewDeleteHubUnprocessableEntity() *DeleteHubUnprocessableEntity { - return &DeleteHubUnprocessableEntity{} -} - -/* DeleteHubUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type DeleteHubUnprocessableEntity struct { - Payload *cloud_models.Error -} - -func (o *DeleteHubUnprocessableEntity) Error() string { - return fmt.Sprintf("[DELETE /hubs][%d] deleteHubUnprocessableEntity %+v", 422, o.Payload) -} -func (o *DeleteHubUnprocessableEntity) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *DeleteHubUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewDeleteHubInternalServerError creates a DeleteHubInternalServerError with default headers values -func NewDeleteHubInternalServerError() *DeleteHubInternalServerError { - return &DeleteHubInternalServerError{} -} - -/* DeleteHubInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type DeleteHubInternalServerError struct { - Payload *cloud_models.Error -} - -func (o *DeleteHubInternalServerError) Error() string { - return fmt.Sprintf("[DELETE /hubs][%d] deleteHubInternalServerError %+v", 500, o.Payload) -} -func (o *DeleteHubInternalServerError) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *DeleteHubInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/cloud/cloud_client/hub/get_hubs_parameters.go b/api/cloud/cloud_client/hub/get_hubs_parameters.go deleted file mode 100644 index ecaf548..0000000 --- a/api/cloud/cloud_client/hub/get_hubs_parameters.go +++ /dev/null @@ -1,340 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package hub - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// NewGetHubsParams creates a new GetHubsParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetHubsParams() *GetHubsParams { - return &GetHubsParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetHubsParamsWithTimeout creates a new GetHubsParams object -// with the ability to set a timeout on a request. -func NewGetHubsParamsWithTimeout(timeout time.Duration) *GetHubsParams { - return &GetHubsParams{ - timeout: timeout, - } -} - -// NewGetHubsParamsWithContext creates a new GetHubsParams object -// with the ability to set a context for a request. -func NewGetHubsParamsWithContext(ctx context.Context) *GetHubsParams { - return &GetHubsParams{ - Context: ctx, - } -} - -// NewGetHubsParamsWithHTTPClient creates a new GetHubsParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetHubsParamsWithHTTPClient(client *http.Client) *GetHubsParams { - return &GetHubsParams{ - HTTPClient: client, - } -} - -/* GetHubsParams contains all the parameters to send to the API endpoint - for the get hubs operation. - - Typically these are written to a http.Request. -*/ -type GetHubsParams struct { - - /* AccountID. - - Taxnexus Record Id of an Account - */ - AccountID *string - - /* Active. - - Retrieve active records? - */ - Active *bool - - /* Email. - - Email address? - */ - Email *string - - /* Limit. - - How many objects to return at one time - - Format: int64 - */ - Limit *int64 - - /* Name. - - The Name of this Object - */ - Name *string - - /* Offset. - - How many objects to skip? (default 0) - - Format: int64 - */ - Offset *int64 - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get hubs params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetHubsParams) WithDefaults() *GetHubsParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get hubs params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetHubsParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the get hubs params -func (o *GetHubsParams) WithTimeout(timeout time.Duration) *GetHubsParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get hubs params -func (o *GetHubsParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get hubs params -func (o *GetHubsParams) WithContext(ctx context.Context) *GetHubsParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get hubs params -func (o *GetHubsParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get hubs params -func (o *GetHubsParams) WithHTTPClient(client *http.Client) *GetHubsParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get hubs params -func (o *GetHubsParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAccountID adds the accountID to the get hubs params -func (o *GetHubsParams) WithAccountID(accountID *string) *GetHubsParams { - o.SetAccountID(accountID) - return o -} - -// SetAccountID adds the accountId to the get hubs params -func (o *GetHubsParams) SetAccountID(accountID *string) { - o.AccountID = accountID -} - -// WithActive adds the active to the get hubs params -func (o *GetHubsParams) WithActive(active *bool) *GetHubsParams { - o.SetActive(active) - return o -} - -// SetActive adds the active to the get hubs params -func (o *GetHubsParams) SetActive(active *bool) { - o.Active = active -} - -// WithEmail adds the email to the get hubs params -func (o *GetHubsParams) WithEmail(email *string) *GetHubsParams { - o.SetEmail(email) - return o -} - -// SetEmail adds the email to the get hubs params -func (o *GetHubsParams) SetEmail(email *string) { - o.Email = email -} - -// WithLimit adds the limit to the get hubs params -func (o *GetHubsParams) WithLimit(limit *int64) *GetHubsParams { - o.SetLimit(limit) - return o -} - -// SetLimit adds the limit to the get hubs params -func (o *GetHubsParams) SetLimit(limit *int64) { - o.Limit = limit -} - -// WithName adds the name to the get hubs params -func (o *GetHubsParams) WithName(name *string) *GetHubsParams { - o.SetName(name) - return o -} - -// SetName adds the name to the get hubs params -func (o *GetHubsParams) SetName(name *string) { - o.Name = name -} - -// WithOffset adds the offset to the get hubs params -func (o *GetHubsParams) WithOffset(offset *int64) *GetHubsParams { - o.SetOffset(offset) - return o -} - -// SetOffset adds the offset to the get hubs params -func (o *GetHubsParams) SetOffset(offset *int64) { - o.Offset = offset -} - -// WriteToRequest writes these params to a swagger request -func (o *GetHubsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - if o.AccountID != nil { - - // query param accountId - var qrAccountID string - - if o.AccountID != nil { - qrAccountID = *o.AccountID - } - qAccountID := qrAccountID - if qAccountID != "" { - - if err := r.SetQueryParam("accountId", qAccountID); err != nil { - return err - } - } - } - - if o.Active != nil { - - // query param active - var qrActive bool - - if o.Active != nil { - qrActive = *o.Active - } - qActive := swag.FormatBool(qrActive) - if qActive != "" { - - if err := r.SetQueryParam("active", qActive); err != nil { - return err - } - } - } - - if o.Email != nil { - - // query param email - var qrEmail string - - if o.Email != nil { - qrEmail = *o.Email - } - qEmail := qrEmail - if qEmail != "" { - - if err := r.SetQueryParam("email", qEmail); err != nil { - return err - } - } - } - - if o.Limit != nil { - - // query param limit - var qrLimit int64 - - if o.Limit != nil { - qrLimit = *o.Limit - } - qLimit := swag.FormatInt64(qrLimit) - if qLimit != "" { - - if err := r.SetQueryParam("limit", qLimit); err != nil { - return err - } - } - } - - if o.Name != nil { - - // query param name - var qrName string - - if o.Name != nil { - qrName = *o.Name - } - qName := qrName - if qName != "" { - - if err := r.SetQueryParam("name", qName); err != nil { - return err - } - } - } - - if o.Offset != nil { - - // query param offset - var qrOffset int64 - - if o.Offset != nil { - qrOffset = *o.Offset - } - qOffset := swag.FormatInt64(qrOffset) - if qOffset != "" { - - if err := r.SetQueryParam("offset", qOffset); err != nil { - return err - } - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/cloud/cloud_client/hub/get_hubs_responses.go b/api/cloud/cloud_client/hub/get_hubs_responses.go deleted file mode 100644 index 20a418b..0000000 --- a/api/cloud/cloud_client/hub/get_hubs_responses.go +++ /dev/null @@ -1,278 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package hub - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/cloud/cloud_models" -) - -// GetHubsReader is a Reader for the GetHubs structure. -type GetHubsReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetHubsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetHubsOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetHubsUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewGetHubsForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetHubsNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewGetHubsUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewGetHubsInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetHubsOK creates a GetHubsOK with default headers values -func NewGetHubsOK() *GetHubsOK { - return &GetHubsOK{} -} - -/* GetHubsOK describes a response with status code 200, with default header values. - -Telnexus Response with Hub objects -*/ -type GetHubsOK struct { - AccessControlAllowOrigin string - CacheControl string - - Payload *cloud_models.HubResponse -} - -func (o *GetHubsOK) Error() string { - return fmt.Sprintf("[GET /hubs][%d] getHubsOK %+v", 200, o.Payload) -} -func (o *GetHubsOK) GetPayload() *cloud_models.HubResponse { - return o.Payload -} - -func (o *GetHubsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - // hydrates response header Access-Control-Allow-Origin - hdrAccessControlAllowOrigin := response.GetHeader("Access-Control-Allow-Origin") - - if hdrAccessControlAllowOrigin != "" { - o.AccessControlAllowOrigin = hdrAccessControlAllowOrigin - } - - // hydrates response header Cache-Control - hdrCacheControl := response.GetHeader("Cache-Control") - - if hdrCacheControl != "" { - o.CacheControl = hdrCacheControl - } - - o.Payload = new(cloud_models.HubResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetHubsUnauthorized creates a GetHubsUnauthorized with default headers values -func NewGetHubsUnauthorized() *GetHubsUnauthorized { - return &GetHubsUnauthorized{} -} - -/* GetHubsUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetHubsUnauthorized struct { - Payload *cloud_models.Error -} - -func (o *GetHubsUnauthorized) Error() string { - return fmt.Sprintf("[GET /hubs][%d] getHubsUnauthorized %+v", 401, o.Payload) -} -func (o *GetHubsUnauthorized) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *GetHubsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetHubsForbidden creates a GetHubsForbidden with default headers values -func NewGetHubsForbidden() *GetHubsForbidden { - return &GetHubsForbidden{} -} - -/* GetHubsForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type GetHubsForbidden struct { - Payload *cloud_models.Error -} - -func (o *GetHubsForbidden) Error() string { - return fmt.Sprintf("[GET /hubs][%d] getHubsForbidden %+v", 403, o.Payload) -} -func (o *GetHubsForbidden) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *GetHubsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetHubsNotFound creates a GetHubsNotFound with default headers values -func NewGetHubsNotFound() *GetHubsNotFound { - return &GetHubsNotFound{} -} - -/* GetHubsNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetHubsNotFound struct { - Payload *cloud_models.Error -} - -func (o *GetHubsNotFound) Error() string { - return fmt.Sprintf("[GET /hubs][%d] getHubsNotFound %+v", 404, o.Payload) -} -func (o *GetHubsNotFound) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *GetHubsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetHubsUnprocessableEntity creates a GetHubsUnprocessableEntity with default headers values -func NewGetHubsUnprocessableEntity() *GetHubsUnprocessableEntity { - return &GetHubsUnprocessableEntity{} -} - -/* GetHubsUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type GetHubsUnprocessableEntity struct { - Payload *cloud_models.Error -} - -func (o *GetHubsUnprocessableEntity) Error() string { - return fmt.Sprintf("[GET /hubs][%d] getHubsUnprocessableEntity %+v", 422, o.Payload) -} -func (o *GetHubsUnprocessableEntity) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *GetHubsUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetHubsInternalServerError creates a GetHubsInternalServerError with default headers values -func NewGetHubsInternalServerError() *GetHubsInternalServerError { - return &GetHubsInternalServerError{} -} - -/* GetHubsInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type GetHubsInternalServerError struct { - Payload *cloud_models.Error -} - -func (o *GetHubsInternalServerError) Error() string { - return fmt.Sprintf("[GET /hubs][%d] getHubsInternalServerError %+v", 500, o.Payload) -} -func (o *GetHubsInternalServerError) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *GetHubsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/cloud/cloud_client/hub/post_hubs_parameters.go b/api/cloud/cloud_client/hub/post_hubs_parameters.go deleted file mode 100644 index 700a6bd..0000000 --- a/api/cloud/cloud_client/hub/post_hubs_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package hub - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/cloud/cloud_models" -) - -// NewPostHubsParams creates a new PostHubsParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPostHubsParams() *PostHubsParams { - return &PostHubsParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPostHubsParamsWithTimeout creates a new PostHubsParams object -// with the ability to set a timeout on a request. -func NewPostHubsParamsWithTimeout(timeout time.Duration) *PostHubsParams { - return &PostHubsParams{ - timeout: timeout, - } -} - -// NewPostHubsParamsWithContext creates a new PostHubsParams object -// with the ability to set a context for a request. -func NewPostHubsParamsWithContext(ctx context.Context) *PostHubsParams { - return &PostHubsParams{ - Context: ctx, - } -} - -// NewPostHubsParamsWithHTTPClient creates a new PostHubsParams object -// with the ability to set a custom HTTPClient for a request. -func NewPostHubsParamsWithHTTPClient(client *http.Client) *PostHubsParams { - return &PostHubsParams{ - HTTPClient: client, - } -} - -/* PostHubsParams contains all the parameters to send to the API endpoint - for the post hubs operation. - - Typically these are written to a http.Request. -*/ -type PostHubsParams struct { - - /* HubRequest. - - An array of new Hub records - */ - HubRequest *cloud_models.HubRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the post hubs params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostHubsParams) WithDefaults() *PostHubsParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the post hubs params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostHubsParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the post hubs params -func (o *PostHubsParams) WithTimeout(timeout time.Duration) *PostHubsParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the post hubs params -func (o *PostHubsParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the post hubs params -func (o *PostHubsParams) WithContext(ctx context.Context) *PostHubsParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the post hubs params -func (o *PostHubsParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the post hubs params -func (o *PostHubsParams) WithHTTPClient(client *http.Client) *PostHubsParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the post hubs params -func (o *PostHubsParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithHubRequest adds the hubRequest to the post hubs params -func (o *PostHubsParams) WithHubRequest(hubRequest *cloud_models.HubRequest) *PostHubsParams { - o.SetHubRequest(hubRequest) - return o -} - -// SetHubRequest adds the hubRequest to the post hubs params -func (o *PostHubsParams) SetHubRequest(hubRequest *cloud_models.HubRequest) { - o.HubRequest = hubRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PostHubsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.HubRequest != nil { - if err := r.SetBodyParam(o.HubRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/cloud/cloud_client/hub/post_hubs_responses.go b/api/cloud/cloud_client/hub/post_hubs_responses.go deleted file mode 100644 index 797c2db..0000000 --- a/api/cloud/cloud_client/hub/post_hubs_responses.go +++ /dev/null @@ -1,278 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package hub - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/cloud/cloud_models" -) - -// PostHubsReader is a Reader for the PostHubs structure. -type PostHubsReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PostHubsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPostHubsOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPostHubsUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPostHubsForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPostHubsNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPostHubsUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPostHubsInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPostHubsOK creates a PostHubsOK with default headers values -func NewPostHubsOK() *PostHubsOK { - return &PostHubsOK{} -} - -/* PostHubsOK describes a response with status code 200, with default header values. - -Telnexus Response with Hub objects -*/ -type PostHubsOK struct { - AccessControlAllowOrigin string - CacheControl string - - Payload *cloud_models.HubResponse -} - -func (o *PostHubsOK) Error() string { - return fmt.Sprintf("[POST /hubs][%d] postHubsOK %+v", 200, o.Payload) -} -func (o *PostHubsOK) GetPayload() *cloud_models.HubResponse { - return o.Payload -} - -func (o *PostHubsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - // hydrates response header Access-Control-Allow-Origin - hdrAccessControlAllowOrigin := response.GetHeader("Access-Control-Allow-Origin") - - if hdrAccessControlAllowOrigin != "" { - o.AccessControlAllowOrigin = hdrAccessControlAllowOrigin - } - - // hydrates response header Cache-Control - hdrCacheControl := response.GetHeader("Cache-Control") - - if hdrCacheControl != "" { - o.CacheControl = hdrCacheControl - } - - o.Payload = new(cloud_models.HubResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostHubsUnauthorized creates a PostHubsUnauthorized with default headers values -func NewPostHubsUnauthorized() *PostHubsUnauthorized { - return &PostHubsUnauthorized{} -} - -/* PostHubsUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PostHubsUnauthorized struct { - Payload *cloud_models.Error -} - -func (o *PostHubsUnauthorized) Error() string { - return fmt.Sprintf("[POST /hubs][%d] postHubsUnauthorized %+v", 401, o.Payload) -} -func (o *PostHubsUnauthorized) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *PostHubsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostHubsForbidden creates a PostHubsForbidden with default headers values -func NewPostHubsForbidden() *PostHubsForbidden { - return &PostHubsForbidden{} -} - -/* PostHubsForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PostHubsForbidden struct { - Payload *cloud_models.Error -} - -func (o *PostHubsForbidden) Error() string { - return fmt.Sprintf("[POST /hubs][%d] postHubsForbidden %+v", 403, o.Payload) -} -func (o *PostHubsForbidden) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *PostHubsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostHubsNotFound creates a PostHubsNotFound with default headers values -func NewPostHubsNotFound() *PostHubsNotFound { - return &PostHubsNotFound{} -} - -/* PostHubsNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PostHubsNotFound struct { - Payload *cloud_models.Error -} - -func (o *PostHubsNotFound) Error() string { - return fmt.Sprintf("[POST /hubs][%d] postHubsNotFound %+v", 404, o.Payload) -} -func (o *PostHubsNotFound) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *PostHubsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostHubsUnprocessableEntity creates a PostHubsUnprocessableEntity with default headers values -func NewPostHubsUnprocessableEntity() *PostHubsUnprocessableEntity { - return &PostHubsUnprocessableEntity{} -} - -/* PostHubsUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PostHubsUnprocessableEntity struct { - Payload *cloud_models.Error -} - -func (o *PostHubsUnprocessableEntity) Error() string { - return fmt.Sprintf("[POST /hubs][%d] postHubsUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PostHubsUnprocessableEntity) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *PostHubsUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostHubsInternalServerError creates a PostHubsInternalServerError with default headers values -func NewPostHubsInternalServerError() *PostHubsInternalServerError { - return &PostHubsInternalServerError{} -} - -/* PostHubsInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PostHubsInternalServerError struct { - Payload *cloud_models.Error -} - -func (o *PostHubsInternalServerError) Error() string { - return fmt.Sprintf("[POST /hubs][%d] postHubsInternalServerError %+v", 500, o.Payload) -} -func (o *PostHubsInternalServerError) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *PostHubsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/cloud/cloud_client/hub/put_hub_parameters.go b/api/cloud/cloud_client/hub/put_hub_parameters.go deleted file mode 100644 index e89d490..0000000 --- a/api/cloud/cloud_client/hub/put_hub_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package hub - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/cloud/cloud_models" -) - -// NewPutHubParams creates a new PutHubParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPutHubParams() *PutHubParams { - return &PutHubParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPutHubParamsWithTimeout creates a new PutHubParams object -// with the ability to set a timeout on a request. -func NewPutHubParamsWithTimeout(timeout time.Duration) *PutHubParams { - return &PutHubParams{ - timeout: timeout, - } -} - -// NewPutHubParamsWithContext creates a new PutHubParams object -// with the ability to set a context for a request. -func NewPutHubParamsWithContext(ctx context.Context) *PutHubParams { - return &PutHubParams{ - Context: ctx, - } -} - -// NewPutHubParamsWithHTTPClient creates a new PutHubParams object -// with the ability to set a custom HTTPClient for a request. -func NewPutHubParamsWithHTTPClient(client *http.Client) *PutHubParams { - return &PutHubParams{ - HTTPClient: client, - } -} - -/* PutHubParams contains all the parameters to send to the API endpoint - for the put hub operation. - - Typically these are written to a http.Request. -*/ -type PutHubParams struct { - - /* HubRequest. - - An array of new Hub records - */ - HubRequest *cloud_models.HubRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the put hub params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PutHubParams) WithDefaults() *PutHubParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the put hub params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PutHubParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the put hub params -func (o *PutHubParams) WithTimeout(timeout time.Duration) *PutHubParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the put hub params -func (o *PutHubParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the put hub params -func (o *PutHubParams) WithContext(ctx context.Context) *PutHubParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the put hub params -func (o *PutHubParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the put hub params -func (o *PutHubParams) WithHTTPClient(client *http.Client) *PutHubParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the put hub params -func (o *PutHubParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithHubRequest adds the hubRequest to the put hub params -func (o *PutHubParams) WithHubRequest(hubRequest *cloud_models.HubRequest) *PutHubParams { - o.SetHubRequest(hubRequest) - return o -} - -// SetHubRequest adds the hubRequest to the put hub params -func (o *PutHubParams) SetHubRequest(hubRequest *cloud_models.HubRequest) { - o.HubRequest = hubRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PutHubParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.HubRequest != nil { - if err := r.SetBodyParam(o.HubRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/cloud/cloud_client/hub/put_hub_responses.go b/api/cloud/cloud_client/hub/put_hub_responses.go deleted file mode 100644 index 71ff1c4..0000000 --- a/api/cloud/cloud_client/hub/put_hub_responses.go +++ /dev/null @@ -1,278 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package hub - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/cloud/cloud_models" -) - -// PutHubReader is a Reader for the PutHub structure. -type PutHubReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PutHubReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPutHubOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPutHubUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPutHubForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPutHubNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPutHubUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPutHubInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPutHubOK creates a PutHubOK with default headers values -func NewPutHubOK() *PutHubOK { - return &PutHubOK{} -} - -/* PutHubOK describes a response with status code 200, with default header values. - -Telnexus Response with Hub objects -*/ -type PutHubOK struct { - AccessControlAllowOrigin string - CacheControl string - - Payload *cloud_models.HubResponse -} - -func (o *PutHubOK) Error() string { - return fmt.Sprintf("[PUT /hubs][%d] putHubOK %+v", 200, o.Payload) -} -func (o *PutHubOK) GetPayload() *cloud_models.HubResponse { - return o.Payload -} - -func (o *PutHubOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - // hydrates response header Access-Control-Allow-Origin - hdrAccessControlAllowOrigin := response.GetHeader("Access-Control-Allow-Origin") - - if hdrAccessControlAllowOrigin != "" { - o.AccessControlAllowOrigin = hdrAccessControlAllowOrigin - } - - // hydrates response header Cache-Control - hdrCacheControl := response.GetHeader("Cache-Control") - - if hdrCacheControl != "" { - o.CacheControl = hdrCacheControl - } - - o.Payload = new(cloud_models.HubResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutHubUnauthorized creates a PutHubUnauthorized with default headers values -func NewPutHubUnauthorized() *PutHubUnauthorized { - return &PutHubUnauthorized{} -} - -/* PutHubUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PutHubUnauthorized struct { - Payload *cloud_models.Error -} - -func (o *PutHubUnauthorized) Error() string { - return fmt.Sprintf("[PUT /hubs][%d] putHubUnauthorized %+v", 401, o.Payload) -} -func (o *PutHubUnauthorized) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *PutHubUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutHubForbidden creates a PutHubForbidden with default headers values -func NewPutHubForbidden() *PutHubForbidden { - return &PutHubForbidden{} -} - -/* PutHubForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PutHubForbidden struct { - Payload *cloud_models.Error -} - -func (o *PutHubForbidden) Error() string { - return fmt.Sprintf("[PUT /hubs][%d] putHubForbidden %+v", 403, o.Payload) -} -func (o *PutHubForbidden) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *PutHubForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutHubNotFound creates a PutHubNotFound with default headers values -func NewPutHubNotFound() *PutHubNotFound { - return &PutHubNotFound{} -} - -/* PutHubNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PutHubNotFound struct { - Payload *cloud_models.Error -} - -func (o *PutHubNotFound) Error() string { - return fmt.Sprintf("[PUT /hubs][%d] putHubNotFound %+v", 404, o.Payload) -} -func (o *PutHubNotFound) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *PutHubNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutHubUnprocessableEntity creates a PutHubUnprocessableEntity with default headers values -func NewPutHubUnprocessableEntity() *PutHubUnprocessableEntity { - return &PutHubUnprocessableEntity{} -} - -/* PutHubUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PutHubUnprocessableEntity struct { - Payload *cloud_models.Error -} - -func (o *PutHubUnprocessableEntity) Error() string { - return fmt.Sprintf("[PUT /hubs][%d] putHubUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PutHubUnprocessableEntity) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *PutHubUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutHubInternalServerError creates a PutHubInternalServerError with default headers values -func NewPutHubInternalServerError() *PutHubInternalServerError { - return &PutHubInternalServerError{} -} - -/* PutHubInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PutHubInternalServerError struct { - Payload *cloud_models.Error -} - -func (o *PutHubInternalServerError) Error() string { - return fmt.Sprintf("[PUT /hubs][%d] putHubInternalServerError %+v", 500, o.Payload) -} -func (o *PutHubInternalServerError) GetPayload() *cloud_models.Error { - return o.Payload -} - -func (o *PutHubInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(cloud_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/cloud/cloud_models/error.go b/api/cloud/cloud_models/error.go deleted file mode 100644 index a3c1f5d..0000000 --- a/api/cloud/cloud_models/error.go +++ /dev/null @@ -1,60 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package cloud_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// Error error -// -// swagger:model Error -type Error struct { - - // code - Code int32 `json:"Code,omitempty"` - - // fields - Fields string `json:"Fields,omitempty"` - - // message - Message string `json:"Message,omitempty"` -} - -// Validate validates this error -func (m *Error) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this error based on context it is used -func (m *Error) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *Error) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *Error) UnmarshalBinary(b []byte) error { - var res Error - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/cloud/cloud_models/hub.go b/api/cloud/cloud_models/hub.go deleted file mode 100644 index defe9c8..0000000 --- a/api/cloud/cloud_models/hub.go +++ /dev/null @@ -1,93 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package cloud_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// Hub hub -// -// swagger:model Hub -type Hub struct { - - // Account - AccountID string `json:"AccountID,omitempty"` - - // Billing Contact - BillingContactID string `json:"BillingContactID,omitempty"` - - // Contact - ContactID string `json:"ContactID,omitempty"` - - // Created By - CreatedByID string `json:"CreatedById,omitempty"` - - // Created Date - CreatedDate string `json:"CreatedDate,omitempty"` - - // Current Users - CurrentUsers float64 `json:"CurrentUsers,omitempty"` - - // Record Id - ID string `json:"ID,omitempty"` - - // Last Modified By - LastModifiedByID string `json:"LastModifiedByID,omitempty"` - - // Last Modifed Date - LastModifiedDate string `json:"LastModifiedDate,omitempty"` - - // Max Users - MaxUsers float64 `json:"MaxUsers,omitempty"` - - // Hub Name - Name string `json:"Name,omitempty"` - - // Order Item - OrderItem string `json:"OrderItem,omitempty"` - - // Vendor - VendorID string `json:"VendorID,omitempty"` - - // Vendor Tenant ID - VendorTenantID string `json:"VendorTenantID,omitempty"` -} - -// Validate validates this hub -func (m *Hub) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this hub based on context it is used -func (m *Hub) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *Hub) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *Hub) UnmarshalBinary(b []byte) error { - var res Hub - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/cloud/cloud_models/hub_request.go b/api/cloud/cloud_models/hub_request.go deleted file mode 100644 index e8fd135..0000000 --- a/api/cloud/cloud_models/hub_request.go +++ /dev/null @@ -1,116 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package cloud_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// HubRequest An array of Hub objects -// -// swagger:model HubRequest -type HubRequest struct { - - // data - Data []*Hub `json:"Data"` -} - -// Validate validates this hub request -func (m *HubRequest) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *HubRequest) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this hub request based on the context it is used -func (m *HubRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *HubRequest) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *HubRequest) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *HubRequest) UnmarshalBinary(b []byte) error { - var res HubRequest - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/cloud/cloud_models/response_meta.go b/api/cloud/cloud_models/response_meta.go deleted file mode 100644 index a428617..0000000 --- a/api/cloud/cloud_models/response_meta.go +++ /dev/null @@ -1,84 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package cloud_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// ResponseMeta response meta -// -// swagger:model ResponseMeta -type ResponseMeta struct { - - // Microservice Contact Info - Contact string `json:"Contact,omitempty"` - - // Copyright Info - Copyright string `json:"Copyright,omitempty"` - - // License Information and Restrictions - License string `json:"License,omitempty"` - - // Operation ID - OperationID string `json:"OperationID,omitempty"` - - // Request IP Address - RequestIP string `json:"RequestIP,omitempty"` - - // Request Type - RequestType string `json:"RequestType,omitempty"` - - // Request URL - RequestURL string `json:"RequestURL,omitempty"` - - // Data Server Info - ServerInfo string `json:"ServerInfo,omitempty"` - - // Data Server Response Time (ms) - ServerResponseTime string `json:"ServerResponseTime,omitempty"` - - // Backend Server Timestamp - ServerTimestamp string `json:"ServerTimestamp,omitempty"` - - // Taxnexus Account Number used for recording transactions - TelnexusAccount string `json:"TelnexusAccount,omitempty"` -} - -// Validate validates this response meta -func (m *ResponseMeta) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this response meta based on context it is used -func (m *ResponseMeta) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *ResponseMeta) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *ResponseMeta) UnmarshalBinary(b []byte) error { - var res ResponseMeta - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/cloud/cloud_models/user.go b/api/cloud/cloud_models/user.go deleted file mode 100644 index 2a67318..0000000 --- a/api/cloud/cloud_models/user.go +++ /dev/null @@ -1,376 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package cloud_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// User user -// -// swagger:model User -type User struct { - - // API Key - APIKey string `json:"APIKey,omitempty"` - - // About Me - AboutMe string `json:"AboutMe,omitempty"` - - // Account ID - AccountID string `json:"AccountID,omitempty"` - - // address - Address *Address `json:"Address,omitempty"` - - // Alias - Alias string `json:"Alias,omitempty"` - - // Auth0 User Id - Auth0UserID string `json:"Auth0UserID,omitempty"` - - // Nickname - CommunityNickname string `json:"CommunityNickname,omitempty"` - - // Company Name - CompanyName string `json:"CompanyName,omitempty"` - - // Contact - ContactID string `json:"ContactID,omitempty"` - - // Created User ID - CreatedByID string `json:"CreatedByID,omitempty"` - - // Date Created - CreatedDate string `json:"CreatedDate,omitempty"` - - // Delegated Approver - DelegatedApproverID string `json:"DelegatedApproverID,omitempty"` - - // Department - Department string `json:"Department,omitempty"` - - // Division - Division string `json:"Division,omitempty"` - - // Email address - Email string `json:"Email,omitempty"` - - // Employee Number - EmployeeNumber string `json:"EmployeeNumber,omitempty"` - - // Time day ends - EndOfDay string `json:"EndOfDay,omitempty"` - - // Environment - Environment string `json:"Environment,omitempty"` - - // Extension - Extension string `json:"Extension,omitempty"` - - // Fabric API Key - FabricAPIKey string `json:"FabricAPIKey,omitempty"` - - // Fax - Fax string `json:"Fax,omitempty"` - - // The first name - FirstName string `json:"FirstName,omitempty"` - - // Allow Forecasting - ForecastEnabled bool `json:"ForecastEnabled,omitempty"` - - // Full Photo URL - FullPhotoURL string `json:"FullPhotoURL,omitempty"` - - // Taxnexus ID - ID string `json:"ID,omitempty"` - - // Active - IsActive bool `json:"IsActive,omitempty"` - - // Is the user enabled for Communities? - IsPortalEnabled bool `json:"IsPortalEnabled,omitempty"` - - // Has Profile Photo - IsProphilePhotoActive bool `json:"IsProphilePhotoActive,omitempty"` - - // is system controlled - IsSystemControlled bool `json:"IsSystemControlled,omitempty"` - - // IP address of last login - LastIP string `json:"LastIP,omitempty"` - - // Last login time - LastLogin string `json:"LastLogin,omitempty"` - - // Last Modified User ID - LastModifiedByID string `json:"LastModifiedByID,omitempty"` - - // Last Modified Date - LastModifiedDate string `json:"LastModifiedDate,omitempty"` - - // The Last Name - LastName string `json:"LastName,omitempty"` - - // Number of times user has logged in - LoginCount int64 `json:"LoginCount,omitempty"` - - // Manager - ManagerID string `json:"ManagerID,omitempty"` - - // Mobile - MobilePhone string `json:"MobilePhone,omitempty"` - - // Name - Name string `json:"Name,omitempty"` - - // Out of office message - OutOfOfficeMessage string `json:"OutOfOfficeMessage,omitempty"` - - // Phone - Phone string `json:"Phone,omitempty"` - - // Portal Role Level - PortalRole string `json:"PortalRole,omitempty"` - - // Profile - ProfileID string `json:"ProfileID,omitempty"` - - // Info Emails - ReceivesAdminEmails bool `json:"ReceivesAdminEmails,omitempty"` - - // Admin Info Emails - ReceivesAdminInfoEmails bool `json:"ReceivesAdminInfoEmails,omitempty"` - - // Email Sender Address - SenderEmail string `json:"SenderEmail,omitempty"` - - // Email Sender Name - SenderName string `json:"SenderName,omitempty"` - - // Email Signature - Signature string `json:"Signature,omitempty"` - - // Small Photo URL - SmallPhotoURL string `json:"SmallPhotoURL,omitempty"` - - // The time day starts - StartOfDay string `json:"StartOfDay,omitempty"` - - // Taxnexus Account - TelnexusAccount string `json:"TelnexusAccount,omitempty"` - - // Tenant ID associated with this user - TenantID string `json:"TenantID,omitempty"` - - // tenant users - TenantUsers []*TenantUser `json:"TenantUsers"` - - // Time Zone - TimeZone string `json:"TimeZone,omitempty"` - - // Title - Title string `json:"Title,omitempty"` - - // Role - UserRoleID string `json:"UserRoleID,omitempty"` - - // user roles - UserRoles []*UserRole `json:"UserRoles"` - - // User Type - UserType string `json:"UserType,omitempty"` - - // Username - Username string `json:"Username,omitempty"` -} - -// Validate validates this user -func (m *User) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateAddress(formats); err != nil { - res = append(res, err) - } - - if err := m.validateTenantUsers(formats); err != nil { - res = append(res, err) - } - - if err := m.validateUserRoles(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *User) validateAddress(formats strfmt.Registry) error { - if swag.IsZero(m.Address) { // not required - return nil - } - - if m.Address != nil { - if err := m.Address.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Address") - } - return err - } - } - - return nil -} - -func (m *User) validateTenantUsers(formats strfmt.Registry) error { - if swag.IsZero(m.TenantUsers) { // not required - return nil - } - - for i := 0; i < len(m.TenantUsers); i++ { - if swag.IsZero(m.TenantUsers[i]) { // not required - continue - } - - if m.TenantUsers[i] != nil { - if err := m.TenantUsers[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("TenantUsers" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -func (m *User) validateUserRoles(formats strfmt.Registry) error { - if swag.IsZero(m.UserRoles) { // not required - return nil - } - - for i := 0; i < len(m.UserRoles); i++ { - if swag.IsZero(m.UserRoles[i]) { // not required - continue - } - - if m.UserRoles[i] != nil { - if err := m.UserRoles[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("UserRoles" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this user based on the context it is used -func (m *User) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateAddress(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateTenantUsers(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateUserRoles(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *User) contextValidateAddress(ctx context.Context, formats strfmt.Registry) error { - - if m.Address != nil { - if err := m.Address.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Address") - } - return err - } - } - - return nil -} - -func (m *User) contextValidateTenantUsers(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.TenantUsers); i++ { - - if m.TenantUsers[i] != nil { - if err := m.TenantUsers[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("TenantUsers" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -func (m *User) contextValidateUserRoles(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.UserRoles); i++ { - - if m.UserRoles[i] != nil { - if err := m.UserRoles[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("UserRoles" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *User) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *User) UnmarshalBinary(b []byte) error { - var res User - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/crm/crm_client/accounts/accounts_client.go b/api/crm/crm_client/accounts/accounts_client.go index ae62d6c..b0e887d 100644 --- a/api/crm/crm_client/accounts/accounts_client.go +++ b/api/crm/crm_client/accounts/accounts_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -50,7 +50,7 @@ type ClientService interface { /* DeleteAccount deletes an account - Delete Telnexus Account record + Delete Taxnexus Account record */ func (a *Client) DeleteAccount(params *DeleteAccountParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*DeleteAccountOK, error) { // TODO: Validate the params before sending @@ -130,7 +130,7 @@ func (a *Client) GetAccounts(params *GetAccountsParams, authInfo runtime.ClientA } /* - GetAccountsObservable gets telnexus accounts in an observable array + GetAccountsObservable gets taxnexus accounts in an observable array A list of accounts in a simple JSON array */ @@ -171,7 +171,7 @@ func (a *Client) GetAccountsObservable(params *GetAccountsObservableParams, auth } /* - PostAccounts adds a new account to telnexus + PostAccounts adds a new account to taxnexus Account record to be added */ diff --git a/api/crm/crm_client/accounts/delete_account_parameters.go b/api/crm/crm_client/accounts/delete_account_parameters.go index 820808f..b255af9 100644 --- a/api/crm/crm_client/accounts/delete_account_parameters.go +++ b/api/crm/crm_client/accounts/delete_account_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -65,7 +65,7 @@ type DeleteAccountParams struct { /* AccountID. - Telnexus Record Id of an Account + Taxnexus Record Id of an Account */ AccountID *string diff --git a/api/crm/crm_client/accounts/delete_account_responses.go b/api/crm/crm_client/accounts/delete_account_responses.go index 380575a..df9de05 100644 --- a/api/crm/crm_client/accounts/delete_account_responses.go +++ b/api/crm/crm_client/accounts/delete_account_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewDeleteAccountOK() *DeleteAccountOK { /* DeleteAccountOK describes a response with status code 200, with default header values. -Telnexus Response with Message Objects with Delete Status +Taxnexus Response with Message Objects with Delete Status */ type DeleteAccountOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/accounts/get_accounts_observable_parameters.go b/api/crm/crm_client/accounts/get_accounts_observable_parameters.go index efd7ad7..736e0c4 100644 --- a/api/crm/crm_client/accounts/get_accounts_observable_parameters.go +++ b/api/crm/crm_client/accounts/get_accounts_observable_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -66,7 +66,7 @@ type GetAccountsObservableParams struct { /* AccountID. - Telnexus Record Id of an Account + Taxnexus Record Id of an Account */ AccountID *string diff --git a/api/crm/crm_client/accounts/get_accounts_observable_responses.go b/api/crm/crm_client/accounts/get_accounts_observable_responses.go index d37e4ee..27d9fdf 100644 --- a/api/crm/crm_client/accounts/get_accounts_observable_responses.go +++ b/api/crm/crm_client/accounts/get_accounts_observable_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetAccountsObservableOK() *GetAccountsObservableOK { /* GetAccountsObservableOK describes a response with status code 200, with default header values. -Telnexus Response with an array of Account objects +Taxnexus Response with an array of Account objects */ type GetAccountsObservableOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/accounts/get_accounts_parameters.go b/api/crm/crm_client/accounts/get_accounts_parameters.go index 0de9c4f..a6b261e 100644 --- a/api/crm/crm_client/accounts/get_accounts_parameters.go +++ b/api/crm/crm_client/accounts/get_accounts_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -66,7 +66,7 @@ type GetAccountsParams struct { /* AccountID. - Telnexus Record Id of an Account + Taxnexus Record Id of an Account */ AccountID *string diff --git a/api/crm/crm_client/accounts/get_accounts_responses.go b/api/crm/crm_client/accounts/get_accounts_responses.go index ab13215..c0f1a0d 100644 --- a/api/crm/crm_client/accounts/get_accounts_responses.go +++ b/api/crm/crm_client/accounts/get_accounts_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetAccountsOK() *GetAccountsOK { /* GetAccountsOK describes a response with status code 200, with default header values. -Telnexus Response with Account objects with Contacts +Taxnexus Response with Account objects with Contacts */ type GetAccountsOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/accounts/post_accounts_parameters.go b/api/crm/crm_client/accounts/post_accounts_parameters.go index 40bdad8..75700fd 100644 --- a/api/crm/crm_client/accounts/post_accounts_parameters.go +++ b/api/crm/crm_client/accounts/post_accounts_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/accounts/post_accounts_responses.go b/api/crm/crm_client/accounts/post_accounts_responses.go index 0349ce5..dc20c33 100644 --- a/api/crm/crm_client/accounts/post_accounts_responses.go +++ b/api/crm/crm_client/accounts/post_accounts_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPostAccountsOK() *PostAccountsOK { /* PostAccountsOK describes a response with status code 200, with default header values. -Telnexus Response with Account objects with Contacts +Taxnexus Response with Account objects with Contacts */ type PostAccountsOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/accounts/put_account_parameters.go b/api/crm/crm_client/accounts/put_account_parameters.go index eabb60c..de63218 100644 --- a/api/crm/crm_client/accounts/put_account_parameters.go +++ b/api/crm/crm_client/accounts/put_account_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/accounts/put_account_responses.go b/api/crm/crm_client/accounts/put_account_responses.go index 595e5c5..2b1da0d 100644 --- a/api/crm/crm_client/accounts/put_account_responses.go +++ b/api/crm/crm_client/accounts/put_account_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPutAccountOK() *PutAccountOK { /* PutAccountOK describes a response with status code 200, with default header values. -Telnexus Response with Account objects with Contacts +Taxnexus Response with Account objects with Contacts */ type PutAccountOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/companies/companies_client.go b/api/crm/crm_client/companies/companies_client.go index f7e52e1..2fef709 100644 --- a/api/crm/crm_client/companies/companies_client.go +++ b/api/crm/crm_client/companies/companies_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -85,7 +85,7 @@ func (a *Client) GetCompanies(params *GetCompaniesParams, authInfo runtime.Clien } /* - GetCompaniesObservable gets telnexus companies in an observable array + GetCompaniesObservable gets taxnexus companies in an observable array A list of companies in a simple JSON array */ diff --git a/api/crm/crm_client/companies/get_companies_observable_parameters.go b/api/crm/crm_client/companies/get_companies_observable_parameters.go index 1e663ee..a197efb 100644 --- a/api/crm/crm_client/companies/get_companies_observable_parameters.go +++ b/api/crm/crm_client/companies/get_companies_observable_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -65,7 +65,7 @@ type GetCompaniesObservableParams struct { /* CompanyID. - Telnexus Company record ID + Taxnexus Company record ID */ CompanyID *string diff --git a/api/crm/crm_client/companies/get_companies_observable_responses.go b/api/crm/crm_client/companies/get_companies_observable_responses.go index 11067ba..4f12931 100644 --- a/api/crm/crm_client/companies/get_companies_observable_responses.go +++ b/api/crm/crm_client/companies/get_companies_observable_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetCompaniesObservableOK() *GetCompaniesObservableOK { /* GetCompaniesObservableOK describes a response with status code 200, with default header values. -Telnexus Response with an array of Company objects +Taxnexus Response with an array of Company objects */ type GetCompaniesObservableOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/companies/get_companies_parameters.go b/api/crm/crm_client/companies/get_companies_parameters.go index f712ec6..a4e18fd 100644 --- a/api/crm/crm_client/companies/get_companies_parameters.go +++ b/api/crm/crm_client/companies/get_companies_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -65,7 +65,7 @@ type GetCompaniesParams struct { /* CompanyID. - Telnexus Company record ID + Taxnexus Company record ID */ CompanyID *string diff --git a/api/crm/crm_client/companies/get_companies_responses.go b/api/crm/crm_client/companies/get_companies_responses.go index 4b305f9..fdc8394 100644 --- a/api/crm/crm_client/companies/get_companies_responses.go +++ b/api/crm/crm_client/companies/get_companies_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetCompaniesOK() *GetCompaniesOK { /* GetCompaniesOK describes a response with status code 200, with default header values. -Telnexus Response with Company objects +Taxnexus Response with Company objects */ type GetCompaniesOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/companies/post_companies_parameters.go b/api/crm/crm_client/companies/post_companies_parameters.go index d485041..a43c3c8 100644 --- a/api/crm/crm_client/companies/post_companies_parameters.go +++ b/api/crm/crm_client/companies/post_companies_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/companies/post_companies_responses.go b/api/crm/crm_client/companies/post_companies_responses.go index 882b55f..142d384 100644 --- a/api/crm/crm_client/companies/post_companies_responses.go +++ b/api/crm/crm_client/companies/post_companies_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPostCompaniesOK() *PostCompaniesOK { /* PostCompaniesOK describes a response with status code 200, with default header values. -Telnexus Response with Company objects +Taxnexus Response with Company objects */ type PostCompaniesOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/contacts/contacts_client.go b/api/crm/crm_client/contacts/contacts_client.go index 3d0b011..22a2387 100644 --- a/api/crm/crm_client/contacts/contacts_client.go +++ b/api/crm/crm_client/contacts/contacts_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -50,7 +50,7 @@ type ClientService interface { /* DeleteContact deletes a contact - Delete Telnexus Contact record + Delete Taxnexus Contact record */ func (a *Client) DeleteContact(params *DeleteContactParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*DeleteContactOK, error) { // TODO: Validate the params before sending @@ -130,7 +130,7 @@ func (a *Client) GetContacts(params *GetContactsParams, authInfo runtime.ClientA } /* - GetContactsObservable gets telnexus contacts in an observable array + GetContactsObservable gets taxnexus contacts in an observable array A list of contacts in a simple JSON array */ diff --git a/api/crm/crm_client/contacts/delete_contact_parameters.go b/api/crm/crm_client/contacts/delete_contact_parameters.go index 4648399..9b5b48e 100644 --- a/api/crm/crm_client/contacts/delete_contact_parameters.go +++ b/api/crm/crm_client/contacts/delete_contact_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -65,7 +65,7 @@ type DeleteContactParams struct { /* ContactID. - Telnexus Contact record ID + Taxnexus Contact record ID */ ContactID *string diff --git a/api/crm/crm_client/contacts/delete_contact_responses.go b/api/crm/crm_client/contacts/delete_contact_responses.go index 13c2ba5..0964c75 100644 --- a/api/crm/crm_client/contacts/delete_contact_responses.go +++ b/api/crm/crm_client/contacts/delete_contact_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewDeleteContactOK() *DeleteContactOK { /* DeleteContactOK describes a response with status code 200, with default header values. -Telnexus Response with Message Objects with Delete Status +Taxnexus Response with Message Objects with Delete Status */ type DeleteContactOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/contacts/get_contacts_observable_parameters.go b/api/crm/crm_client/contacts/get_contacts_observable_parameters.go index 56d0408..676df33 100644 --- a/api/crm/crm_client/contacts/get_contacts_observable_parameters.go +++ b/api/crm/crm_client/contacts/get_contacts_observable_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -72,7 +72,7 @@ type GetContactsObservableParams struct { /* ContactID. - Telnexus Contact record ID + Taxnexus Contact record ID */ ContactID *string diff --git a/api/crm/crm_client/contacts/get_contacts_observable_responses.go b/api/crm/crm_client/contacts/get_contacts_observable_responses.go index daa65e1..2bc5014 100644 --- a/api/crm/crm_client/contacts/get_contacts_observable_responses.go +++ b/api/crm/crm_client/contacts/get_contacts_observable_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetContactsObservableOK() *GetContactsObservableOK { /* GetContactsObservableOK describes a response with status code 200, with default header values. -Telnexus Response with an array of Contact objects +Taxnexus Response with an array of Contact objects */ type GetContactsObservableOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/contacts/get_contacts_parameters.go b/api/crm/crm_client/contacts/get_contacts_parameters.go index 19b41a6..d1c7e7b 100644 --- a/api/crm/crm_client/contacts/get_contacts_parameters.go +++ b/api/crm/crm_client/contacts/get_contacts_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -72,7 +72,7 @@ type GetContactsParams struct { /* ContactID. - Telnexus Contact record ID + Taxnexus Contact record ID */ ContactID *string diff --git a/api/crm/crm_client/contacts/get_contacts_responses.go b/api/crm/crm_client/contacts/get_contacts_responses.go index e6dadd0..b645017 100644 --- a/api/crm/crm_client/contacts/get_contacts_responses.go +++ b/api/crm/crm_client/contacts/get_contacts_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetContactsOK() *GetContactsOK { /* GetContactsOK describes a response with status code 200, with default header values. -Telnexus Response with an array of Contact objects +Taxnexus Response with an array of Contact objects */ type GetContactsOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/contacts/post_contacts_parameters.go b/api/crm/crm_client/contacts/post_contacts_parameters.go index be16a1b..6729fbf 100644 --- a/api/crm/crm_client/contacts/post_contacts_parameters.go +++ b/api/crm/crm_client/contacts/post_contacts_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/contacts/post_contacts_responses.go b/api/crm/crm_client/contacts/post_contacts_responses.go index 33e8fe4..3f7d1cf 100644 --- a/api/crm/crm_client/contacts/post_contacts_responses.go +++ b/api/crm/crm_client/contacts/post_contacts_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPostContactsOK() *PostContactsOK { /* PostContactsOK describes a response with status code 200, with default header values. -Telnexus Response with an array of Contact objects +Taxnexus Response with an array of Contact objects */ type PostContactsOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/contacts/put_contacts_parameters.go b/api/crm/crm_client/contacts/put_contacts_parameters.go index 758a610..51fa9d2 100644 --- a/api/crm/crm_client/contacts/put_contacts_parameters.go +++ b/api/crm/crm_client/contacts/put_contacts_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/contacts/put_contacts_responses.go b/api/crm/crm_client/contacts/put_contacts_responses.go index 36d4f8f..c345ae3 100644 --- a/api/crm/crm_client/contacts/put_contacts_responses.go +++ b/api/crm/crm_client/contacts/put_contacts_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPutContactsOK() *PutContactsOK { /* PutContactsOK describes a response with status code 200, with default header values. -Telnexus Response with an array of Contact objects +Taxnexus Response with an array of Contact objects */ type PutContactsOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/cors/account_options_observable_parameters.go b/api/crm/crm_client/cors/account_options_observable_parameters.go index 1b1cbe9..9f8cdd6 100644 --- a/api/crm/crm_client/cors/account_options_observable_parameters.go +++ b/api/crm/crm_client/cors/account_options_observable_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/account_options_observable_responses.go b/api/crm/crm_client/cors/account_options_observable_responses.go index b3edd58..790409f 100644 --- a/api/crm/crm_client/cors/account_options_observable_responses.go +++ b/api/crm/crm_client/cors/account_options_observable_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/account_options_parameters.go b/api/crm/crm_client/cors/account_options_parameters.go index 435c1b6..0e79a11 100644 --- a/api/crm/crm_client/cors/account_options_parameters.go +++ b/api/crm/crm_client/cors/account_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/account_options_responses.go b/api/crm/crm_client/cors/account_options_responses.go index 9c6bc13..b69295c 100644 --- a/api/crm/crm_client/cors/account_options_responses.go +++ b/api/crm/crm_client/cors/account_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/company_observable_options_parameters.go b/api/crm/crm_client/cors/company_observable_options_parameters.go index 8b76a65..09f9d5d 100644 --- a/api/crm/crm_client/cors/company_observable_options_parameters.go +++ b/api/crm/crm_client/cors/company_observable_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/company_observable_options_responses.go b/api/crm/crm_client/cors/company_observable_options_responses.go index 9d8a91c..1c9fe60 100644 --- a/api/crm/crm_client/cors/company_observable_options_responses.go +++ b/api/crm/crm_client/cors/company_observable_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/company_options_parameters.go b/api/crm/crm_client/cors/company_options_parameters.go index 79b54cb..37f542f 100644 --- a/api/crm/crm_client/cors/company_options_parameters.go +++ b/api/crm/crm_client/cors/company_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/company_options_responses.go b/api/crm/crm_client/cors/company_options_responses.go index 40be5c9..71b8e3a 100644 --- a/api/crm/crm_client/cors/company_options_responses.go +++ b/api/crm/crm_client/cors/company_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/contact_options_observable_parameters.go b/api/crm/crm_client/cors/contact_options_observable_parameters.go index 4fe0eae..b9a7b8c 100644 --- a/api/crm/crm_client/cors/contact_options_observable_parameters.go +++ b/api/crm/crm_client/cors/contact_options_observable_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/contact_options_observable_responses.go b/api/crm/crm_client/cors/contact_options_observable_responses.go index 40349bc..295bdd3 100644 --- a/api/crm/crm_client/cors/contact_options_observable_responses.go +++ b/api/crm/crm_client/cors/contact_options_observable_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/contact_options_parameters.go b/api/crm/crm_client/cors/contact_options_parameters.go index c74f6b7..d47c986 100644 --- a/api/crm/crm_client/cors/contact_options_parameters.go +++ b/api/crm/crm_client/cors/contact_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/contact_options_responses.go b/api/crm/crm_client/cors/contact_options_responses.go index 6d32456..26f4fdf 100644 --- a/api/crm/crm_client/cors/contact_options_responses.go +++ b/api/crm/crm_client/cors/contact_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/cors_client.go b/api/crm/crm_client/cors/cors_client.go index 81d9a1c..f77552c 100644 --- a/api/crm/crm_client/cors/cors_client.go +++ b/api/crm/crm_client/cors/cors_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/lead_options_observable_parameters.go b/api/crm/crm_client/cors/lead_options_observable_parameters.go index 16cbded..a11de15 100644 --- a/api/crm/crm_client/cors/lead_options_observable_parameters.go +++ b/api/crm/crm_client/cors/lead_options_observable_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/lead_options_observable_responses.go b/api/crm/crm_client/cors/lead_options_observable_responses.go index 6655720..09cb15e 100644 --- a/api/crm/crm_client/cors/lead_options_observable_responses.go +++ b/api/crm/crm_client/cors/lead_options_observable_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/lead_options_parameters.go b/api/crm/crm_client/cors/lead_options_parameters.go index 1ad925a..3f9d614 100644 --- a/api/crm/crm_client/cors/lead_options_parameters.go +++ b/api/crm/crm_client/cors/lead_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/cors/lead_options_responses.go b/api/crm/crm_client/cors/lead_options_responses.go index b6f4aa6..f69fbde 100644 --- a/api/crm/crm_client/cors/lead_options_responses.go +++ b/api/crm/crm_client/cors/lead_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/crm_client.go b/api/crm/crm_client/crm_client.go index 6b37c22..2ad6afa 100644 --- a/api/crm/crm_client/crm_client.go +++ b/api/crm/crm_client/crm_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -27,7 +27,7 @@ var Default = NewHTTPClient(nil) const ( // DefaultHost is the default Host // found in Meta (info) section of spec file - DefaultHost string = "crm.infra.tnxs.net:8080" + DefaultHost string = "crm.vernonkeenan.com:8080" // DefaultBasePath is the default BasePath // found in Meta (info) section of spec file DefaultBasePath string = "/v1" diff --git a/api/crm/crm_client/leads/delete_lead_parameters.go b/api/crm/crm_client/leads/delete_lead_parameters.go index b2f2723..0c51db6 100644 --- a/api/crm/crm_client/leads/delete_lead_parameters.go +++ b/api/crm/crm_client/leads/delete_lead_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -65,7 +65,7 @@ type DeleteLeadParams struct { /* LeadID. - Telnexus Lead record ID + Taxnexus Lead record ID */ LeadID *string diff --git a/api/crm/crm_client/leads/delete_lead_responses.go b/api/crm/crm_client/leads/delete_lead_responses.go index 8216585..5388963 100644 --- a/api/crm/crm_client/leads/delete_lead_responses.go +++ b/api/crm/crm_client/leads/delete_lead_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewDeleteLeadOK() *DeleteLeadOK { /* DeleteLeadOK describes a response with status code 200, with default header values. -Telnexus Response with Message Objects with Delete Status +Taxnexus Response with Message Objects with Delete Status */ type DeleteLeadOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/leads/get_leads_observable_parameters.go b/api/crm/crm_client/leads/get_leads_observable_parameters.go index 0bff9c6..61fe828 100644 --- a/api/crm/crm_client/leads/get_leads_observable_parameters.go +++ b/api/crm/crm_client/leads/get_leads_observable_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -71,7 +71,7 @@ type GetLeadsObservableParams struct { /* LeadID. - Telnexus Lead record ID + Taxnexus Lead record ID */ LeadID *string diff --git a/api/crm/crm_client/leads/get_leads_observable_responses.go b/api/crm/crm_client/leads/get_leads_observable_responses.go index 34f1e5d..3068eec 100644 --- a/api/crm/crm_client/leads/get_leads_observable_responses.go +++ b/api/crm/crm_client/leads/get_leads_observable_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetLeadsObservableOK() *GetLeadsObservableOK { /* GetLeadsObservableOK describes a response with status code 200, with default header values. -Telnexus Response with an array of Lead objects +Taxnexus Response with an array of Lead objects */ type GetLeadsObservableOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/leads/get_leads_parameters.go b/api/crm/crm_client/leads/get_leads_parameters.go index 3ade243..3912b20 100644 --- a/api/crm/crm_client/leads/get_leads_parameters.go +++ b/api/crm/crm_client/leads/get_leads_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -72,7 +72,7 @@ type GetLeadsParams struct { /* LeadID. - Telnexus Lead record ID + Taxnexus Lead record ID */ LeadID *string diff --git a/api/crm/crm_client/leads/get_leads_responses.go b/api/crm/crm_client/leads/get_leads_responses.go index 6eeb38a..c705ee6 100644 --- a/api/crm/crm_client/leads/get_leads_responses.go +++ b/api/crm/crm_client/leads/get_leads_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetLeadsOK() *GetLeadsOK { /* GetLeadsOK describes a response with status code 200, with default header values. -Telnexus Response with an array of Lead objects +Taxnexus Response with an array of Lead objects */ type GetLeadsOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/leads/leads_client.go b/api/crm/crm_client/leads/leads_client.go index bb15861..804f0d7 100644 --- a/api/crm/crm_client/leads/leads_client.go +++ b/api/crm/crm_client/leads/leads_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -50,7 +50,7 @@ type ClientService interface { /* DeleteLead deletes a contact - Delete Telnexus Lead record + Delete Taxnexus Lead record */ func (a *Client) DeleteLead(params *DeleteLeadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*DeleteLeadOK, error) { // TODO: Validate the params before sending @@ -130,7 +130,7 @@ func (a *Client) GetLeads(params *GetLeadsParams, authInfo runtime.ClientAuthInf } /* - GetLeadsObservable gets telnexus leads in an observable array + GetLeadsObservable gets taxnexus leads in an observable array A list of leads in a simple JSON array */ diff --git a/api/crm/crm_client/leads/post_leads_parameters.go b/api/crm/crm_client/leads/post_leads_parameters.go index 7789e99..4efc13a 100644 --- a/api/crm/crm_client/leads/post_leads_parameters.go +++ b/api/crm/crm_client/leads/post_leads_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/leads/post_leads_responses.go b/api/crm/crm_client/leads/post_leads_responses.go index 6bf6dad..5a1948b 100644 --- a/api/crm/crm_client/leads/post_leads_responses.go +++ b/api/crm/crm_client/leads/post_leads_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPostLeadsOK() *PostLeadsOK { /* PostLeadsOK describes a response with status code 200, with default header values. -Telnexus Response with an array of Lead objects +Taxnexus Response with an array of Lead objects */ type PostLeadsOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_client/leads/put_leads_parameters.go b/api/crm/crm_client/leads/put_leads_parameters.go index 574bee9..480a119 100644 --- a/api/crm/crm_client/leads/put_leads_parameters.go +++ b/api/crm/crm_client/leads/put_leads_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_client/leads/put_leads_responses.go b/api/crm/crm_client/leads/put_leads_responses.go index 5a803c0..cef148d 100644 --- a/api/crm/crm_client/leads/put_leads_responses.go +++ b/api/crm/crm_client/leads/put_leads_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPutLeadsOK() *PutLeadsOK { /* PutLeadsOK describes a response with status code 200, with default header values. -Telnexus Response with an array of Lead objects +Taxnexus Response with an array of Lead objects */ type PutLeadsOK struct { AccessControlAllowOrigin string diff --git a/api/crm/crm_models/account.go b/api/crm/crm_models/account.go index b8958ec..08fa0c0 100644 --- a/api/crm/crm_models/account.go +++ b/api/crm/crm_models/account.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -130,7 +130,7 @@ type Account struct { // Fax Fax string `json:"Fax,omitempty"` - // Telnexus Account Id + // Taxnexus Account Id ID string `json:"ID,omitempty"` // ISP Customer? diff --git a/api/crm/crm_models/account_basic.go b/api/crm/crm_models/account_basic.go index 7ba126d..3d83649 100644 --- a/api/crm/crm_models/account_basic.go +++ b/api/crm/crm_models/account_basic.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -22,7 +22,7 @@ import ( // swagger:model AccountBasic type AccountBasic struct { - // Telnexus Account Number of the OEM/Reseller + // Taxnexus Account Number of the OEM/Reseller AccountNumber string `json:"AccountNumber,omitempty"` // billing address @@ -31,7 +31,7 @@ type AccountBasic struct { // Contact ID BillingContactID string `json:"BillingContactID,omitempty"` - // Telnexus OEM/Reseller Record Id + // Taxnexus OEM/Reseller Record Id CompanyID string `json:"CompanyID,omitempty"` // The id of the Coordinate of the business establishment diff --git a/api/crm/crm_models/account_basic_response.go b/api/crm/crm_models/account_basic_response.go index f00d75d..0e9ee7a 100644 --- a/api/crm/crm_models/account_basic_response.go +++ b/api/crm/crm_models/account_basic_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_models/account_request.go b/api/crm/crm_models/account_request.go index 0ef1142..e4efec4 100644 --- a/api/crm/crm_models/account_request.go +++ b/api/crm/crm_models/account_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_models/account_response.go b/api/crm/crm_models/account_response.go index 9bfe78c..aed5696 100644 --- a/api/crm/crm_models/account_response.go +++ b/api/crm/crm_models/account_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_models/address.go b/api/crm/crm_models/address.go index 9dff52a..93e01eb 100644 --- a/api/crm/crm_models/address.go +++ b/api/crm/crm_models/address.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_models/company.go b/api/crm/crm_models/company.go index 0d2f27c..08e74ff 100644 --- a/api/crm/crm_models/company.go +++ b/api/crm/crm_models/company.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -22,7 +22,7 @@ import ( // swagger:model Company type Company struct { - // Telnexus ID of the Account that owns this Company + // Taxnexus ID of the Account that owns this Company AccountID string `json:"AccountID,omitempty"` // Account Number Prefix @@ -91,7 +91,7 @@ type Company struct { // Font Name for Monospace FontMono string `json:"FontMono,omitempty"` - // Telnexus Record Id + // Taxnexus Record Id ID string `json:"ID,omitempty"` // International Customers? diff --git a/api/crm/crm_models/company_request.go b/api/crm/crm_models/company_request.go index 9fe8b6f..b40b7fd 100644 --- a/api/crm/crm_models/company_request.go +++ b/api/crm/crm_models/company_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_models/company_response.go b/api/crm/crm_models/company_response.go index 2cbd2df..8cb3408 100644 --- a/api/crm/crm_models/company_response.go +++ b/api/crm/crm_models/company_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_models/contact.go b/api/crm/crm_models/contact.go index f3ece63..a7c7f02 100644 --- a/api/crm/crm_models/contact.go +++ b/api/crm/crm_models/contact.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -58,7 +58,7 @@ type Contact struct { // Email Bounce Reason EmailBouncedReason string `json:"EmailBouncedReason,omitempty"` - // Telnexus Enrollment Status + // Taxnexus Enrollment Status EnrollmentStatus string `json:"EnrollmentStatus,omitempty"` // Fax Number @@ -76,7 +76,7 @@ type Contact struct { // Home Phone HomePhone string `json:"HomePhone,omitempty"` - // Telnexus Record Id + // Taxnexus Record Id ID string `json:"ID,omitempty"` // Does this contact have bounced emails? diff --git a/api/crm/crm_models/contact_request.go b/api/crm/crm_models/contact_request.go index 51f2618..084f593 100644 --- a/api/crm/crm_models/contact_request.go +++ b/api/crm/crm_models/contact_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_models/contact_response.go b/api/crm/crm_models/contact_response.go index a9344f6..c49de6e 100644 --- a/api/crm/crm_models/contact_response.go +++ b/api/crm/crm_models/contact_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_models/delete_response.go b/api/crm/crm_models/delete_response.go index 1a2fe07..e86114a 100644 --- a/api/crm/crm_models/delete_response.go +++ b/api/crm/crm_models/delete_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_models/error.go b/api/crm/crm_models/error.go index 8374e31..9facb57 100644 --- a/api/crm/crm_models/error.go +++ b/api/crm/crm_models/error.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_models/invalid_error.go b/api/crm/crm_models/invalid_error.go index 17a77c2..fdc5049 100644 --- a/api/crm/crm_models/invalid_error.go +++ b/api/crm/crm_models/invalid_error.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_models/lead.go b/api/crm/crm_models/lead.go index 80c8916..7001ae0 100644 --- a/api/crm/crm_models/lead.go +++ b/api/crm/crm_models/lead.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -43,7 +43,7 @@ type Lead struct { // First Name FirstName string `json:"FirstName,omitempty"` - // Telnexus Record Id + // Taxnexus Record Id ID string `json:"ID,omitempty"` // Last Modified By User ID diff --git a/api/crm/crm_models/lead_request.go b/api/crm/crm_models/lead_request.go index 052cbf6..539ed81 100644 --- a/api/crm/crm_models/lead_request.go +++ b/api/crm/crm_models/lead_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_models/lead_response.go b/api/crm/crm_models/lead_response.go index 26467bb..1c10133 100644 --- a/api/crm/crm_models/lead_response.go +++ b/api/crm/crm_models/lead_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_models/message.go b/api/crm/crm_models/message.go index 1c9aac5..7471643 100644 --- a/api/crm/crm_models/message.go +++ b/api/crm/crm_models/message.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_models/pagination.go b/api/crm/crm_models/pagination.go index 3a7c567..0b20908 100644 --- a/api/crm/crm_models/pagination.go +++ b/api/crm/crm_models/pagination.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/crm/crm_models/request_meta.go b/api/crm/crm_models/request_meta.go index e0d98b0..8ead7f8 100644 --- a/api/crm/crm_models/request_meta.go +++ b/api/crm/crm_models/request_meta.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -23,16 +23,16 @@ import ( // swagger:model RequestMeta type RequestMeta struct { - // Telnexus Account Number of the Reseller or OEM + // Taxnexus Account Number of the Reseller or OEM // Required: true - TelnexusAccount *string `json:"TelnexusAccount"` + TaxnexusAccount *string `json:"TaxnexusAccount"` } // Validate validates this request meta func (m *RequestMeta) Validate(formats strfmt.Registry) error { var res []error - if err := m.validateTelnexusAccount(formats); err != nil { + if err := m.validateTaxnexusAccount(formats); err != nil { res = append(res, err) } @@ -42,9 +42,9 @@ func (m *RequestMeta) Validate(formats strfmt.Registry) error { return nil } -func (m *RequestMeta) validateTelnexusAccount(formats strfmt.Registry) error { +func (m *RequestMeta) validateTaxnexusAccount(formats strfmt.Registry) error { - if err := validate.Required("TelnexusAccount", "body", m.TelnexusAccount); err != nil { + if err := validate.Required("TaxnexusAccount", "body", m.TaxnexusAccount); err != nil { return err } diff --git a/api/crm/crm_models/response_meta.go b/api/crm/crm_models/response_meta.go index d63fc08..bd5788c 100644 --- a/api/crm/crm_models/response_meta.go +++ b/api/crm/crm_models/response_meta.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -55,8 +55,8 @@ type ResponseMeta struct { // Backend Server Timestamp ServerTimestamp string `json:"ServerTimestamp,omitempty"` - // Telnexus Account Number used for recording transactions - TelnexusAccount string `json:"TelnexusAccount,omitempty"` + // Taxnexus Account Number used for recording transactions + TaxnexusAccount string `json:"TaxnexusAccount,omitempty"` } // Validate validates this response meta diff --git a/api/devops/devops_client/cluster/cluster_client.go b/api/devops/devops_client/cluster/cluster_client.go index bd906c5..623e20a 100644 --- a/api/devops/devops_client/cluster/cluster_client.go +++ b/api/devops/devops_client/cluster/cluster_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -173,7 +173,7 @@ func (a *Client) GetClustersObservable(params *GetClustersObservableParams, auth /* PostClusters creates new clusters - Create Clusters in Telnexus + Create Clusters in Taxnexus */ func (a *Client) PostClusters(params *PostClustersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostClustersOK, error) { // TODO: Validate the params before sending @@ -214,7 +214,7 @@ func (a *Client) PostClusters(params *PostClustersParams, authInfo runtime.Clien /* PutClusters updates clustera - Update Cluster in Telnexus + Update Cluster in Taxnexus */ func (a *Client) PutClusters(params *PutClustersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutClustersOK, error) { // TODO: Validate the params before sending diff --git a/api/devops/devops_client/cluster/get_cluster_parameters.go b/api/devops/devops_client/cluster/get_cluster_parameters.go index 4aa7863..aeb5e1b 100644 --- a/api/devops/devops_client/cluster/get_cluster_parameters.go +++ b/api/devops/devops_client/cluster/get_cluster_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -65,7 +65,7 @@ type GetClusterParams struct { /* ClusterIDPath. - Telnexus Record Id of a Cluster + Taxnexus Record Id of a Cluster */ ClusterIDPath string diff --git a/api/devops/devops_client/cluster/get_cluster_responses.go b/api/devops/devops_client/cluster/get_cluster_responses.go index 7885414..58335dd 100644 --- a/api/devops/devops_client/cluster/get_cluster_responses.go +++ b/api/devops/devops_client/cluster/get_cluster_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cluster/get_clusters_observable_parameters.go b/api/devops/devops_client/cluster/get_clusters_observable_parameters.go index 1b3f62a..8c9867d 100644 --- a/api/devops/devops_client/cluster/get_clusters_observable_parameters.go +++ b/api/devops/devops_client/cluster/get_clusters_observable_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cluster/get_clusters_observable_responses.go b/api/devops/devops_client/cluster/get_clusters_observable_responses.go index db7e36d..573af19 100644 --- a/api/devops/devops_client/cluster/get_clusters_observable_responses.go +++ b/api/devops/devops_client/cluster/get_clusters_observable_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cluster/get_clusters_parameters.go b/api/devops/devops_client/cluster/get_clusters_parameters.go index 2e6f4c3..5403e72 100644 --- a/api/devops/devops_client/cluster/get_clusters_parameters.go +++ b/api/devops/devops_client/cluster/get_clusters_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -66,13 +66,13 @@ type GetClustersParams struct { /* ClusterID. - Telnexus Record Id of a Cluster + Taxnexus Record Id of a Cluster */ ClusterID *string /* CompanyID. - Telnexus Record Id of a Company + Taxnexus Record Id of a Company */ CompanyID *string diff --git a/api/devops/devops_client/cluster/get_clusters_responses.go b/api/devops/devops_client/cluster/get_clusters_responses.go index 4bdd242..657d35a 100644 --- a/api/devops/devops_client/cluster/get_clusters_responses.go +++ b/api/devops/devops_client/cluster/get_clusters_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetClustersOK() *GetClustersOK { /* GetClustersOK describes a response with status code 200, with default header values. -Telnexus Response with Cluster objects +Taxnexus Response with Cluster objects */ type GetClustersOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/cluster/post_clusters_parameters.go b/api/devops/devops_client/cluster/post_clusters_parameters.go index 3fae550..b4f8a61 100644 --- a/api/devops/devops_client/cluster/post_clusters_parameters.go +++ b/api/devops/devops_client/cluster/post_clusters_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cluster/post_clusters_responses.go b/api/devops/devops_client/cluster/post_clusters_responses.go index d1facc8..b2e248c 100644 --- a/api/devops/devops_client/cluster/post_clusters_responses.go +++ b/api/devops/devops_client/cluster/post_clusters_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPostClustersOK() *PostClustersOK { /* PostClustersOK describes a response with status code 200, with default header values. -Telnexus Response with Cluster objects +Taxnexus Response with Cluster objects */ type PostClustersOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/cluster/put_clusters_parameters.go b/api/devops/devops_client/cluster/put_clusters_parameters.go index a053246..50fa3a2 100644 --- a/api/devops/devops_client/cluster/put_clusters_parameters.go +++ b/api/devops/devops_client/cluster/put_clusters_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cluster/put_clusters_responses.go b/api/devops/devops_client/cluster/put_clusters_responses.go index 31c60c1..7f3cdb0 100644 --- a/api/devops/devops_client/cluster/put_clusters_responses.go +++ b/api/devops/devops_client/cluster/put_clusters_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPutClustersOK() *PutClustersOK { /* PutClustersOK describes a response with status code 200, with default header values. -Telnexus Response with Cluster objects +Taxnexus Response with Cluster objects */ type PutClustersOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/cors/cluster_options_parameters.go b/api/devops/devops_client/cors/cluster_options_parameters.go index 50d99f3..223a95b 100644 --- a/api/devops/devops_client/cors/cluster_options_parameters.go +++ b/api/devops/devops_client/cors/cluster_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/cluster_options_responses.go b/api/devops/devops_client/cors/cluster_options_responses.go index 3adafee..a363eaf 100644 --- a/api/devops/devops_client/cors/cluster_options_responses.go +++ b/api/devops/devops_client/cors/cluster_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/clusters_options_parameters.go b/api/devops/devops_client/cors/clusters_options_parameters.go index ab8227e..ab50aac 100644 --- a/api/devops/devops_client/cors/clusters_options_parameters.go +++ b/api/devops/devops_client/cors/clusters_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/clusters_options_responses.go b/api/devops/devops_client/cors/clusters_options_responses.go index 6a2bac9..8c36f72 100644 --- a/api/devops/devops_client/cors/clusters_options_responses.go +++ b/api/devops/devops_client/cors/clusters_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/cors_client.go b/api/devops/devops_client/cors/cors_client.go index 72fa82a..e15e7d8 100644 --- a/api/devops/devops_client/cors/cors_client.go +++ b/api/devops/devops_client/cors/cors_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/database_options_parameters.go b/api/devops/devops_client/cors/database_options_parameters.go index 9b6c45d..144b197 100644 --- a/api/devops/devops_client/cors/database_options_parameters.go +++ b/api/devops/devops_client/cors/database_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/database_options_responses.go b/api/devops/devops_client/cors/database_options_responses.go index a76ee10..4ba21d1 100644 --- a/api/devops/devops_client/cors/database_options_responses.go +++ b/api/devops/devops_client/cors/database_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/databases_options_parameters.go b/api/devops/devops_client/cors/databases_options_parameters.go index aa0f171..9b63c86 100644 --- a/api/devops/devops_client/cors/databases_options_parameters.go +++ b/api/devops/devops_client/cors/databases_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/databases_options_responses.go b/api/devops/devops_client/cors/databases_options_responses.go index a003d64..d7e4dcf 100644 --- a/api/devops/devops_client/cors/databases_options_responses.go +++ b/api/devops/devops_client/cors/databases_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/ingest_options_parameters.go b/api/devops/devops_client/cors/ingest_options_parameters.go index 6ba9bef..f011206 100644 --- a/api/devops/devops_client/cors/ingest_options_parameters.go +++ b/api/devops/devops_client/cors/ingest_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/ingest_options_responses.go b/api/devops/devops_client/cors/ingest_options_responses.go index 1854701..588bde4 100644 --- a/api/devops/devops_client/cors/ingest_options_responses.go +++ b/api/devops/devops_client/cors/ingest_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/ingests_options_parameters.go b/api/devops/devops_client/cors/ingests_options_parameters.go index a4a19e9..8166718 100644 --- a/api/devops/devops_client/cors/ingests_options_parameters.go +++ b/api/devops/devops_client/cors/ingests_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/ingests_options_responses.go b/api/devops/devops_client/cors/ingests_options_responses.go index d9f807c..5afb04d 100644 --- a/api/devops/devops_client/cors/ingests_options_responses.go +++ b/api/devops/devops_client/cors/ingests_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/job_options_parameters.go b/api/devops/devops_client/cors/job_options_parameters.go index fca0424..1b49b04 100644 --- a/api/devops/devops_client/cors/job_options_parameters.go +++ b/api/devops/devops_client/cors/job_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/job_options_responses.go b/api/devops/devops_client/cors/job_options_responses.go index 87e6391..bc5f1eb 100644 --- a/api/devops/devops_client/cors/job_options_responses.go +++ b/api/devops/devops_client/cors/job_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/jobs_options_parameters.go b/api/devops/devops_client/cors/jobs_options_parameters.go index f0b4b1b..91564ad 100644 --- a/api/devops/devops_client/cors/jobs_options_parameters.go +++ b/api/devops/devops_client/cors/jobs_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/jobs_options_responses.go b/api/devops/devops_client/cors/jobs_options_responses.go index 40c6a02..694ee49 100644 --- a/api/devops/devops_client/cors/jobs_options_responses.go +++ b/api/devops/devops_client/cors/jobs_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/service_options_parameters.go b/api/devops/devops_client/cors/service_options_parameters.go index d36479b..d49fbcc 100644 --- a/api/devops/devops_client/cors/service_options_parameters.go +++ b/api/devops/devops_client/cors/service_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/service_options_responses.go b/api/devops/devops_client/cors/service_options_responses.go index 4656ca4..8c53e67 100644 --- a/api/devops/devops_client/cors/service_options_responses.go +++ b/api/devops/devops_client/cors/service_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/services_options_parameters.go b/api/devops/devops_client/cors/services_options_parameters.go index caf8cbe..9541dc8 100644 --- a/api/devops/devops_client/cors/services_options_parameters.go +++ b/api/devops/devops_client/cors/services_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/services_options_responses.go b/api/devops/devops_client/cors/services_options_responses.go index f4138ea..9e7119f 100644 --- a/api/devops/devops_client/cors/services_options_responses.go +++ b/api/devops/devops_client/cors/services_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/template_options_parameters.go b/api/devops/devops_client/cors/template_options_parameters.go index 9bbbe81..d4c5967 100644 --- a/api/devops/devops_client/cors/template_options_parameters.go +++ b/api/devops/devops_client/cors/template_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/template_options_responses.go b/api/devops/devops_client/cors/template_options_responses.go index 9f79089..81162ff 100644 --- a/api/devops/devops_client/cors/template_options_responses.go +++ b/api/devops/devops_client/cors/template_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/templates_options_parameters.go b/api/devops/devops_client/cors/templates_options_parameters.go index 03b0412..aebe1b2 100644 --- a/api/devops/devops_client/cors/templates_options_parameters.go +++ b/api/devops/devops_client/cors/templates_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/templates_options_responses.go b/api/devops/devops_client/cors/templates_options_responses.go index 6719161..2573bd5 100644 --- a/api/devops/devops_client/cors/templates_options_responses.go +++ b/api/devops/devops_client/cors/templates_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/tenant_options_parameters.go b/api/devops/devops_client/cors/tenant_options_parameters.go index 3379962..ebe9343 100644 --- a/api/devops/devops_client/cors/tenant_options_parameters.go +++ b/api/devops/devops_client/cors/tenant_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/tenant_options_responses.go b/api/devops/devops_client/cors/tenant_options_responses.go index 7e89f92..83d2e1d 100644 --- a/api/devops/devops_client/cors/tenant_options_responses.go +++ b/api/devops/devops_client/cors/tenant_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/tenants_options_parameters.go b/api/devops/devops_client/cors/tenants_options_parameters.go index 85e4bc0..24d6512 100644 --- a/api/devops/devops_client/cors/tenants_options_parameters.go +++ b/api/devops/devops_client/cors/tenants_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/tenants_options_responses.go b/api/devops/devops_client/cors/tenants_options_responses.go index 5d1bef2..4fc5053 100644 --- a/api/devops/devops_client/cors/tenants_options_responses.go +++ b/api/devops/devops_client/cors/tenants_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/user_options_parameters.go b/api/devops/devops_client/cors/user_options_parameters.go index 7730414..b00ca64 100644 --- a/api/devops/devops_client/cors/user_options_parameters.go +++ b/api/devops/devops_client/cors/user_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/user_options_responses.go b/api/devops/devops_client/cors/user_options_responses.go index 9ce5281..d96db0a 100644 --- a/api/devops/devops_client/cors/user_options_responses.go +++ b/api/devops/devops_client/cors/user_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/users_options_parameters.go b/api/devops/devops_client/cors/users_options_parameters.go index 887e647..526a31e 100644 --- a/api/devops/devops_client/cors/users_options_parameters.go +++ b/api/devops/devops_client/cors/users_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/cors/users_options_responses.go b/api/devops/devops_client/cors/users_options_responses.go index fdbcefe..5440e78 100644 --- a/api/devops/devops_client/cors/users_options_responses.go +++ b/api/devops/devops_client/cors/users_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/database/database_client.go b/api/devops/devops_client/database/database_client.go index 6674472..0d451c1 100644 --- a/api/devops/devops_client/database/database_client.go +++ b/api/devops/devops_client/database/database_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -173,7 +173,7 @@ func (a *Client) GetDatabasesObservable(params *GetDatabasesObservableParams, au /* PostDatabases creates new databases - Create Databases in Telnexus + Create Databases in Taxnexus */ func (a *Client) PostDatabases(params *PostDatabasesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostDatabasesOK, error) { // TODO: Validate the params before sending @@ -214,7 +214,7 @@ func (a *Client) PostDatabases(params *PostDatabasesParams, authInfo runtime.Cli /* PutDatabases updates databases - Update Database in Telnexus + Update Database in Taxnexus */ func (a *Client) PutDatabases(params *PutDatabasesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutDatabasesOK, error) { // TODO: Validate the params before sending diff --git a/api/devops/devops_client/database/get_database_parameters.go b/api/devops/devops_client/database/get_database_parameters.go index e8d3b77..e82f300 100644 --- a/api/devops/devops_client/database/get_database_parameters.go +++ b/api/devops/devops_client/database/get_database_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -65,7 +65,7 @@ type GetDatabaseParams struct { /* DatabaseIDPath. - Telnexus Record Id of a Database + Taxnexus Record Id of a Database */ DatabaseIDPath string diff --git a/api/devops/devops_client/database/get_database_responses.go b/api/devops/devops_client/database/get_database_responses.go index ee38563..4d47b8f 100644 --- a/api/devops/devops_client/database/get_database_responses.go +++ b/api/devops/devops_client/database/get_database_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/database/get_databases_observable_parameters.go b/api/devops/devops_client/database/get_databases_observable_parameters.go index 4fe44d6..587fa63 100644 --- a/api/devops/devops_client/database/get_databases_observable_parameters.go +++ b/api/devops/devops_client/database/get_databases_observable_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/database/get_databases_observable_responses.go b/api/devops/devops_client/database/get_databases_observable_responses.go index ebc2d7e..6110640 100644 --- a/api/devops/devops_client/database/get_databases_observable_responses.go +++ b/api/devops/devops_client/database/get_databases_observable_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/database/get_databases_parameters.go b/api/devops/devops_client/database/get_databases_parameters.go index fe2f734..cc45a6f 100644 --- a/api/devops/devops_client/database/get_databases_parameters.go +++ b/api/devops/devops_client/database/get_databases_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -66,13 +66,13 @@ type GetDatabasesParams struct { /* CompanyID. - Telnexus Record Id of a Company + Taxnexus Record Id of a Company */ CompanyID *string /* DatabaseID. - Telnexus Record Id of a Database + Taxnexus Record Id of a Database */ DatabaseID *string diff --git a/api/devops/devops_client/database/get_databases_responses.go b/api/devops/devops_client/database/get_databases_responses.go index 5cec049..cc9966f 100644 --- a/api/devops/devops_client/database/get_databases_responses.go +++ b/api/devops/devops_client/database/get_databases_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetDatabasesOK() *GetDatabasesOK { /* GetDatabasesOK describes a response with status code 200, with default header values. -Telnexus Response with Database objects +Taxnexus Response with Database objects */ type GetDatabasesOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/database/post_databases_parameters.go b/api/devops/devops_client/database/post_databases_parameters.go index 5352119..a37b9a2 100644 --- a/api/devops/devops_client/database/post_databases_parameters.go +++ b/api/devops/devops_client/database/post_databases_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/database/post_databases_responses.go b/api/devops/devops_client/database/post_databases_responses.go index cb75b58..a48813a 100644 --- a/api/devops/devops_client/database/post_databases_responses.go +++ b/api/devops/devops_client/database/post_databases_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPostDatabasesOK() *PostDatabasesOK { /* PostDatabasesOK describes a response with status code 200, with default header values. -Telnexus Response with Database objects +Taxnexus Response with Database objects */ type PostDatabasesOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/database/put_databases_parameters.go b/api/devops/devops_client/database/put_databases_parameters.go index 9ed3700..b4d640a 100644 --- a/api/devops/devops_client/database/put_databases_parameters.go +++ b/api/devops/devops_client/database/put_databases_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/database/put_databases_responses.go b/api/devops/devops_client/database/put_databases_responses.go index 6b83d53..04c475b 100644 --- a/api/devops/devops_client/database/put_databases_responses.go +++ b/api/devops/devops_client/database/put_databases_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPutDatabasesOK() *PutDatabasesOK { /* PutDatabasesOK describes a response with status code 200, with default header values. -Telnexus Response with Database objects +Taxnexus Response with Database objects */ type PutDatabasesOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/devops_client.go b/api/devops/devops_client/devops_client.go index c5ed4b2..c84754d 100644 --- a/api/devops/devops_client/devops_client.go +++ b/api/devops/devops_client/devops_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/ingest/get_ingest_parameters.go b/api/devops/devops_client/ingest/get_ingest_parameters.go index 3c60393..722f5d0 100644 --- a/api/devops/devops_client/ingest/get_ingest_parameters.go +++ b/api/devops/devops_client/ingest/get_ingest_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -65,7 +65,7 @@ type GetIngestParams struct { /* IngestIDPath. - Telnexus Record Id of a Ingest + Taxnexus Record Id of a Ingest */ IngestIDPath string diff --git a/api/devops/devops_client/ingest/get_ingest_responses.go b/api/devops/devops_client/ingest/get_ingest_responses.go index c89c09d..b7e6b4d 100644 --- a/api/devops/devops_client/ingest/get_ingest_responses.go +++ b/api/devops/devops_client/ingest/get_ingest_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/ingest/get_ingests_observable_parameters.go b/api/devops/devops_client/ingest/get_ingests_observable_parameters.go index 49ba2af..f5aab57 100644 --- a/api/devops/devops_client/ingest/get_ingests_observable_parameters.go +++ b/api/devops/devops_client/ingest/get_ingests_observable_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/ingest/get_ingests_observable_responses.go b/api/devops/devops_client/ingest/get_ingests_observable_responses.go index f4b4b36..7d3dc1e 100644 --- a/api/devops/devops_client/ingest/get_ingests_observable_responses.go +++ b/api/devops/devops_client/ingest/get_ingests_observable_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/ingest/get_ingests_parameters.go b/api/devops/devops_client/ingest/get_ingests_parameters.go index 580d597..587a203 100644 --- a/api/devops/devops_client/ingest/get_ingests_parameters.go +++ b/api/devops/devops_client/ingest/get_ingests_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -66,19 +66,19 @@ type GetIngestsParams struct { /* AccountID. - Telnexus Record Id of an Account + Taxnexus Record Id of an Account */ AccountID *string /* CompanyID. - Telnexus Record Id of a Company + Taxnexus Record Id of a Company */ CompanyID *string /* IngestID. - Telnexus Record Id of an Ingest + Taxnexus Record Id of an Ingest */ IngestID *string diff --git a/api/devops/devops_client/ingest/get_ingests_responses.go b/api/devops/devops_client/ingest/get_ingests_responses.go index 7d92a56..66951a6 100644 --- a/api/devops/devops_client/ingest/get_ingests_responses.go +++ b/api/devops/devops_client/ingest/get_ingests_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetIngestsOK() *GetIngestsOK { /* GetIngestsOK describes a response with status code 200, with default header values. -Telnexus Response with Ingest objects +Taxnexus Response with Ingest objects */ type GetIngestsOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/ingest/ingest_client.go b/api/devops/devops_client/ingest/ingest_client.go index dd144f3..4232b47 100644 --- a/api/devops/devops_client/ingest/ingest_client.go +++ b/api/devops/devops_client/ingest/ingest_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/ingest/post_ingests_parameters.go b/api/devops/devops_client/ingest/post_ingests_parameters.go index b9655c7..611cb17 100644 --- a/api/devops/devops_client/ingest/post_ingests_parameters.go +++ b/api/devops/devops_client/ingest/post_ingests_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/ingest/post_ingests_responses.go b/api/devops/devops_client/ingest/post_ingests_responses.go index 9b71e3b..507b4da 100644 --- a/api/devops/devops_client/ingest/post_ingests_responses.go +++ b/api/devops/devops_client/ingest/post_ingests_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPostIngestsOK() *PostIngestsOK { /* PostIngestsOK describes a response with status code 200, with default header values. -Telnexus Response with Ingest objects +Taxnexus Response with Ingest objects */ type PostIngestsOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/ingest/put_ingests_parameters.go b/api/devops/devops_client/ingest/put_ingests_parameters.go index 39d2338..d5f4230 100644 --- a/api/devops/devops_client/ingest/put_ingests_parameters.go +++ b/api/devops/devops_client/ingest/put_ingests_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/ingest/put_ingests_responses.go b/api/devops/devops_client/ingest/put_ingests_responses.go index 4746e4c..af853d3 100644 --- a/api/devops/devops_client/ingest/put_ingests_responses.go +++ b/api/devops/devops_client/ingest/put_ingests_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPutIngestsOK() *PutIngestsOK { /* PutIngestsOK describes a response with status code 200, with default header values. -Telnexus Response with Ingest objects +Taxnexus Response with Ingest objects */ type PutIngestsOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/job/get_job_parameters.go b/api/devops/devops_client/job/get_job_parameters.go index 59f86a2..b8ed4f2 100644 --- a/api/devops/devops_client/job/get_job_parameters.go +++ b/api/devops/devops_client/job/get_job_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -65,7 +65,7 @@ type GetJobParams struct { /* JobIDPath. - Telnexus Record Id of a Job + Taxnexus Record Id of a Job */ JobIDPath string diff --git a/api/devops/devops_client/job/get_job_responses.go b/api/devops/devops_client/job/get_job_responses.go index 021928f..065fa96 100644 --- a/api/devops/devops_client/job/get_job_responses.go +++ b/api/devops/devops_client/job/get_job_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/job/get_jobs_observable_parameters.go b/api/devops/devops_client/job/get_jobs_observable_parameters.go index 15f2f34..36e8f9a 100644 --- a/api/devops/devops_client/job/get_jobs_observable_parameters.go +++ b/api/devops/devops_client/job/get_jobs_observable_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/job/get_jobs_observable_responses.go b/api/devops/devops_client/job/get_jobs_observable_responses.go index 8894d9f..ec02afd 100644 --- a/api/devops/devops_client/job/get_jobs_observable_responses.go +++ b/api/devops/devops_client/job/get_jobs_observable_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/job/get_jobs_parameters.go b/api/devops/devops_client/job/get_jobs_parameters.go index 13517c2..d509412 100644 --- a/api/devops/devops_client/job/get_jobs_parameters.go +++ b/api/devops/devops_client/job/get_jobs_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -66,7 +66,7 @@ type GetJobsParams struct { /* AccountID. - Telnexus Record Id of an Account + Taxnexus Record Id of an Account */ AccountID *string @@ -78,13 +78,13 @@ type GetJobsParams struct { /* CompanyID. - Telnexus Record Id of a Company + Taxnexus Record Id of a Company */ CompanyID *string /* JobID. - Telnexus Record Id of a Job + Taxnexus Record Id of a Job */ JobID *string diff --git a/api/devops/devops_client/job/get_jobs_responses.go b/api/devops/devops_client/job/get_jobs_responses.go index 196f73b..5fa7fe5 100644 --- a/api/devops/devops_client/job/get_jobs_responses.go +++ b/api/devops/devops_client/job/get_jobs_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetJobsOK() *GetJobsOK { /* GetJobsOK describes a response with status code 200, with default header values. -Telnexus Response with Job objects +Taxnexus Response with Job objects */ type GetJobsOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/job/job_client.go b/api/devops/devops_client/job/job_client.go index f9b1293..6cece08 100644 --- a/api/devops/devops_client/job/job_client.go +++ b/api/devops/devops_client/job/job_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -173,7 +173,7 @@ func (a *Client) GetJobsObservable(params *GetJobsObservableParams, authInfo run /* PostJobs creates new jobs - Create and enqueue Jobs in Telnexus + Create and enqueue Jobs in Taxnexus */ func (a *Client) PostJobs(params *PostJobsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostJobsOK, error) { // TODO: Validate the params before sending @@ -214,7 +214,7 @@ func (a *Client) PostJobs(params *PostJobsParams, authInfo runtime.ClientAuthInf /* PutJobs updates jobs - Update Jobs in Telnexus + Update Jobs in Taxnexus */ func (a *Client) PutJobs(params *PutJobsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutJobsOK, error) { // TODO: Validate the params before sending diff --git a/api/devops/devops_client/job/post_jobs_parameters.go b/api/devops/devops_client/job/post_jobs_parameters.go index 3817deb..310c21e 100644 --- a/api/devops/devops_client/job/post_jobs_parameters.go +++ b/api/devops/devops_client/job/post_jobs_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/job/post_jobs_responses.go b/api/devops/devops_client/job/post_jobs_responses.go index 5980b53..e3b1891 100644 --- a/api/devops/devops_client/job/post_jobs_responses.go +++ b/api/devops/devops_client/job/post_jobs_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPostJobsOK() *PostJobsOK { /* PostJobsOK describes a response with status code 200, with default header values. -Telnexus Response with Job objects +Taxnexus Response with Job objects */ type PostJobsOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/job/put_jobs_parameters.go b/api/devops/devops_client/job/put_jobs_parameters.go index 3b93408..0ac860d 100644 --- a/api/devops/devops_client/job/put_jobs_parameters.go +++ b/api/devops/devops_client/job/put_jobs_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/job/put_jobs_responses.go b/api/devops/devops_client/job/put_jobs_responses.go index 70ca95b..45fc73c 100644 --- a/api/devops/devops_client/job/put_jobs_responses.go +++ b/api/devops/devops_client/job/put_jobs_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPutJobsOK() *PutJobsOK { /* PutJobsOK describes a response with status code 200, with default header values. -Telnexus Response with Job objects +Taxnexus Response with Job objects */ type PutJobsOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/service/get_service_parameters.go b/api/devops/devops_client/service/get_service_parameters.go index cf501a9..44404a0 100644 --- a/api/devops/devops_client/service/get_service_parameters.go +++ b/api/devops/devops_client/service/get_service_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -65,7 +65,7 @@ type GetServiceParams struct { /* ServiceIDPath. - Telnexus Record Id of a Service + Taxnexus Record Id of a Service */ ServiceIDPath string diff --git a/api/devops/devops_client/service/get_service_responses.go b/api/devops/devops_client/service/get_service_responses.go index 7f19296..35f9f6d 100644 --- a/api/devops/devops_client/service/get_service_responses.go +++ b/api/devops/devops_client/service/get_service_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/service/get_services_observable_parameters.go b/api/devops/devops_client/service/get_services_observable_parameters.go index d0173c5..708e6c8 100644 --- a/api/devops/devops_client/service/get_services_observable_parameters.go +++ b/api/devops/devops_client/service/get_services_observable_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/service/get_services_observable_responses.go b/api/devops/devops_client/service/get_services_observable_responses.go index 930c5e7..46bc7cf 100644 --- a/api/devops/devops_client/service/get_services_observable_responses.go +++ b/api/devops/devops_client/service/get_services_observable_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/service/get_services_parameters.go b/api/devops/devops_client/service/get_services_parameters.go index 821bb3f..2f9c1bc 100644 --- a/api/devops/devops_client/service/get_services_parameters.go +++ b/api/devops/devops_client/service/get_services_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/service/get_services_responses.go b/api/devops/devops_client/service/get_services_responses.go index dc2329a..b8066b4 100644 --- a/api/devops/devops_client/service/get_services_responses.go +++ b/api/devops/devops_client/service/get_services_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetServicesOK() *GetServicesOK { /* GetServicesOK describes a response with status code 200, with default header values. -Telnexus Response with Service objects +Taxnexus Response with Service objects */ type GetServicesOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/service/post_services_parameters.go b/api/devops/devops_client/service/post_services_parameters.go index 3007ac3..da06569 100644 --- a/api/devops/devops_client/service/post_services_parameters.go +++ b/api/devops/devops_client/service/post_services_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/service/post_services_responses.go b/api/devops/devops_client/service/post_services_responses.go index 79cc26b..31391dc 100644 --- a/api/devops/devops_client/service/post_services_responses.go +++ b/api/devops/devops_client/service/post_services_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPostServicesOK() *PostServicesOK { /* PostServicesOK describes a response with status code 200, with default header values. -Telnexus Response with Service objects +Taxnexus Response with Service objects */ type PostServicesOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/service/put_services_parameters.go b/api/devops/devops_client/service/put_services_parameters.go index 4bcc1fe..e323f7d 100644 --- a/api/devops/devops_client/service/put_services_parameters.go +++ b/api/devops/devops_client/service/put_services_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/service/put_services_responses.go b/api/devops/devops_client/service/put_services_responses.go index 751b760..42235aa 100644 --- a/api/devops/devops_client/service/put_services_responses.go +++ b/api/devops/devops_client/service/put_services_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPutServicesOK() *PutServicesOK { /* PutServicesOK describes a response with status code 200, with default header values. -Telnexus Response with Service objects +Taxnexus Response with Service objects */ type PutServicesOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/service/service_client.go b/api/devops/devops_client/service/service_client.go index 213e711..5195155 100644 --- a/api/devops/devops_client/service/service_client.go +++ b/api/devops/devops_client/service/service_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -173,7 +173,7 @@ func (a *Client) GetServicesObservable(params *GetServicesObservableParams, auth /* PostServices creates new services - Create Services in Telnexus + Create Services in Taxnexus */ func (a *Client) PostServices(params *PostServicesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostServicesOK, error) { // TODO: Validate the params before sending @@ -214,7 +214,7 @@ func (a *Client) PostServices(params *PostServicesParams, authInfo runtime.Clien /* PutServices updates services - Update Services in Telnexus + Update Services in Taxnexus */ func (a *Client) PutServices(params *PutServicesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutServicesOK, error) { // TODO: Validate the params before sending diff --git a/api/devops/devops_client/template/get_template_parameters.go b/api/devops/devops_client/template/get_template_parameters.go index 38efb7f..54704b8 100644 --- a/api/devops/devops_client/template/get_template_parameters.go +++ b/api/devops/devops_client/template/get_template_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -65,7 +65,7 @@ type GetTemplateParams struct { /* TemplateIDPath. - Telnexus Record Id of a Template + Taxnexus Record Id of a Template */ TemplateIDPath string diff --git a/api/devops/devops_client/template/get_template_responses.go b/api/devops/devops_client/template/get_template_responses.go index b76a3c3..1f32d9c 100644 --- a/api/devops/devops_client/template/get_template_responses.go +++ b/api/devops/devops_client/template/get_template_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/template/get_templates_observable_parameters.go b/api/devops/devops_client/template/get_templates_observable_parameters.go index 20f8ef6..20ae7f1 100644 --- a/api/devops/devops_client/template/get_templates_observable_parameters.go +++ b/api/devops/devops_client/template/get_templates_observable_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/template/get_templates_observable_responses.go b/api/devops/devops_client/template/get_templates_observable_responses.go index ec74e9f..25ad68d 100644 --- a/api/devops/devops_client/template/get_templates_observable_responses.go +++ b/api/devops/devops_client/template/get_templates_observable_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/template/get_templates_parameters.go b/api/devops/devops_client/template/get_templates_parameters.go index 9a638b7..bfa8a23 100644 --- a/api/devops/devops_client/template/get_templates_parameters.go +++ b/api/devops/devops_client/template/get_templates_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/template/get_templates_responses.go b/api/devops/devops_client/template/get_templates_responses.go index 2ef8e86..2f8cf01 100644 --- a/api/devops/devops_client/template/get_templates_responses.go +++ b/api/devops/devops_client/template/get_templates_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetTemplatesOK() *GetTemplatesOK { /* GetTemplatesOK describes a response with status code 200, with default header values. -Telnexus Response with Template objects +Taxnexus Response with Template objects */ type GetTemplatesOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/template/post_templates_parameters.go b/api/devops/devops_client/template/post_templates_parameters.go index 8806c8d..d9501ab 100644 --- a/api/devops/devops_client/template/post_templates_parameters.go +++ b/api/devops/devops_client/template/post_templates_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/template/post_templates_responses.go b/api/devops/devops_client/template/post_templates_responses.go index 62b1b9e..68cce0f 100644 --- a/api/devops/devops_client/template/post_templates_responses.go +++ b/api/devops/devops_client/template/post_templates_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPostTemplatesOK() *PostTemplatesOK { /* PostTemplatesOK describes a response with status code 200, with default header values. -Telnexus Response with Template objects +Taxnexus Response with Template objects */ type PostTemplatesOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/template/template_client.go b/api/devops/devops_client/template/template_client.go index c72d02b..daae50f 100644 --- a/api/devops/devops_client/template/template_client.go +++ b/api/devops/devops_client/template/template_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/tenant/get_tenant_parameters.go b/api/devops/devops_client/tenant/get_tenant_parameters.go index 20dc214..6fdef24 100644 --- a/api/devops/devops_client/tenant/get_tenant_parameters.go +++ b/api/devops/devops_client/tenant/get_tenant_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -65,7 +65,7 @@ type GetTenantParams struct { /* TenantIDPath. - Telnexus Record Id of a Tenant + Taxnexus Record Id of a Tenant */ TenantIDPath string diff --git a/api/devops/devops_client/tenant/get_tenant_responses.go b/api/devops/devops_client/tenant/get_tenant_responses.go index d5823d7..14798af 100644 --- a/api/devops/devops_client/tenant/get_tenant_responses.go +++ b/api/devops/devops_client/tenant/get_tenant_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/tenant/get_tenants_observable_parameters.go b/api/devops/devops_client/tenant/get_tenants_observable_parameters.go index 94e855d..acc7c00 100644 --- a/api/devops/devops_client/tenant/get_tenants_observable_parameters.go +++ b/api/devops/devops_client/tenant/get_tenants_observable_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/tenant/get_tenants_observable_responses.go b/api/devops/devops_client/tenant/get_tenants_observable_responses.go index a485a53..d770556 100644 --- a/api/devops/devops_client/tenant/get_tenants_observable_responses.go +++ b/api/devops/devops_client/tenant/get_tenants_observable_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/tenant/get_tenants_parameters.go b/api/devops/devops_client/tenant/get_tenants_parameters.go index 984ba58..0bc7b69 100644 --- a/api/devops/devops_client/tenant/get_tenants_parameters.go +++ b/api/devops/devops_client/tenant/get_tenants_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -64,15 +64,9 @@ func NewGetTenantsParamsWithHTTPClient(client *http.Client) *GetTenantsParams { */ type GetTenantsParams struct { - /* TelnexusAccount. - - Telnexus Account of a Tenant - */ - TelnexusAccount *string - /* CompanyID. - Telnexus Record Id of a Company + Taxnexus Record Id of a Company */ CompanyID *string @@ -92,9 +86,15 @@ type GetTenantsParams struct { */ Offset *int64 + /* TaxnexusAccount. + + Taxnexus Account of a Tenant + */ + TaxnexusAccount *string + /* TenantID. - Telnexus Record Id of a Tenant + Taxnexus Record Id of a Tenant */ TenantID *string @@ -151,17 +151,6 @@ func (o *GetTenantsParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } -// WithTelnexusAccount adds the telnexusAccount to the get tenants params -func (o *GetTenantsParams) WithTelnexusAccount(telnexusAccount *string) *GetTenantsParams { - o.SetTelnexusAccount(telnexusAccount) - return o -} - -// SetTelnexusAccount adds the telnexusAccount to the get tenants params -func (o *GetTenantsParams) SetTelnexusAccount(telnexusAccount *string) { - o.TelnexusAccount = telnexusAccount -} - // WithCompanyID adds the companyID to the get tenants params func (o *GetTenantsParams) WithCompanyID(companyID *string) *GetTenantsParams { o.SetCompanyID(companyID) @@ -195,6 +184,17 @@ func (o *GetTenantsParams) SetOffset(offset *int64) { o.Offset = offset } +// WithTaxnexusAccount adds the taxnexusAccount to the get tenants params +func (o *GetTenantsParams) WithTaxnexusAccount(taxnexusAccount *string) *GetTenantsParams { + o.SetTaxnexusAccount(taxnexusAccount) + return o +} + +// SetTaxnexusAccount adds the taxnexusAccount to the get tenants params +func (o *GetTenantsParams) SetTaxnexusAccount(taxnexusAccount *string) { + o.TaxnexusAccount = taxnexusAccount +} + // WithTenantID adds the tenantID to the get tenants params func (o *GetTenantsParams) WithTenantID(tenantID *string) *GetTenantsParams { o.SetTenantID(tenantID) @@ -214,23 +214,6 @@ func (o *GetTenantsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Re } var res []error - if o.TelnexusAccount != nil { - - // query param TelnexusAccount - var qrTelnexusAccount string - - if o.TelnexusAccount != nil { - qrTelnexusAccount = *o.TelnexusAccount - } - qTelnexusAccount := qrTelnexusAccount - if qTelnexusAccount != "" { - - if err := r.SetQueryParam("TelnexusAccount", qTelnexusAccount); err != nil { - return err - } - } - } - if o.CompanyID != nil { // query param companyId @@ -282,6 +265,23 @@ func (o *GetTenantsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Re } } + if o.TaxnexusAccount != nil { + + // query param taxnexusAccount + var qrTaxnexusAccount string + + if o.TaxnexusAccount != nil { + qrTaxnexusAccount = *o.TaxnexusAccount + } + qTaxnexusAccount := qrTaxnexusAccount + if qTaxnexusAccount != "" { + + if err := r.SetQueryParam("taxnexusAccount", qTaxnexusAccount); err != nil { + return err + } + } + } + if o.TenantID != nil { // query param tenantId diff --git a/api/devops/devops_client/tenant/get_tenants_responses.go b/api/devops/devops_client/tenant/get_tenants_responses.go index bbefb8b..ae6fcf0 100644 --- a/api/devops/devops_client/tenant/get_tenants_responses.go +++ b/api/devops/devops_client/tenant/get_tenants_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetTenantsOK() *GetTenantsOK { /* GetTenantsOK describes a response with status code 200, with default header values. -Telnexus Response with Tenant objects +Taxnexus Response with Tenant objects */ type GetTenantsOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/tenant/post_tenants_parameters.go b/api/devops/devops_client/tenant/post_tenants_parameters.go index 0a1e608..92d0b07 100644 --- a/api/devops/devops_client/tenant/post_tenants_parameters.go +++ b/api/devops/devops_client/tenant/post_tenants_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/tenant/post_tenants_responses.go b/api/devops/devops_client/tenant/post_tenants_responses.go index 1b6da49..66a67dc 100644 --- a/api/devops/devops_client/tenant/post_tenants_responses.go +++ b/api/devops/devops_client/tenant/post_tenants_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPostTenantsOK() *PostTenantsOK { /* PostTenantsOK describes a response with status code 200, with default header values. -Telnexus Response with Tenant objects +Taxnexus Response with Tenant objects */ type PostTenantsOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/tenant/put_tenants_parameters.go b/api/devops/devops_client/tenant/put_tenants_parameters.go index 345cd28..61bb9b5 100644 --- a/api/devops/devops_client/tenant/put_tenants_parameters.go +++ b/api/devops/devops_client/tenant/put_tenants_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/tenant/put_tenants_responses.go b/api/devops/devops_client/tenant/put_tenants_responses.go index 3380787..95dc807 100644 --- a/api/devops/devops_client/tenant/put_tenants_responses.go +++ b/api/devops/devops_client/tenant/put_tenants_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPutTenantsOK() *PutTenantsOK { /* PutTenantsOK describes a response with status code 200, with default header values. -Telnexus Response with Tenant objects +Taxnexus Response with Tenant objects */ type PutTenantsOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/tenant/tenant_client.go b/api/devops/devops_client/tenant/tenant_client.go index 8cc24c8..6a46542 100644 --- a/api/devops/devops_client/tenant/tenant_client.go +++ b/api/devops/devops_client/tenant/tenant_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -173,7 +173,7 @@ func (a *Client) GetTenantsObservable(params *GetTenantsObservableParams, authIn /* PostTenants creates new tenants - Create Tenants in Telnexus + Create Tenants in Taxnexus */ func (a *Client) PostTenants(params *PostTenantsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostTenantsOK, error) { // TODO: Validate the params before sending @@ -214,7 +214,7 @@ func (a *Client) PostTenants(params *PostTenantsParams, authInfo runtime.ClientA /* PutTenants updates tenants - Update Tenant in Telnexus + Update Tenant in Taxnexus */ func (a *Client) PutTenants(params *PutTenantsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutTenantsOK, error) { // TODO: Validate the params before sending diff --git a/api/devops/devops_client/user/get_user_parameters.go b/api/devops/devops_client/user/get_user_parameters.go index 993ca34..799d96f 100644 --- a/api/devops/devops_client/user/get_user_parameters.go +++ b/api/devops/devops_client/user/get_user_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -65,7 +65,7 @@ type GetUserParams struct { /* UserIDPath. - Telnexus Record Id of a User + Taxnexus Record Id of a User */ UserIDPath string diff --git a/api/devops/devops_client/user/get_user_responses.go b/api/devops/devops_client/user/get_user_responses.go index 8c54d4b..8b4b273 100644 --- a/api/devops/devops_client/user/get_user_responses.go +++ b/api/devops/devops_client/user/get_user_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/user/get_users_observable_parameters.go b/api/devops/devops_client/user/get_users_observable_parameters.go index 0f4bfad..1dc18a4 100644 --- a/api/devops/devops_client/user/get_users_observable_parameters.go +++ b/api/devops/devops_client/user/get_users_observable_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/user/get_users_observable_responses.go b/api/devops/devops_client/user/get_users_observable_responses.go index 224ad89..d89a76f 100644 --- a/api/devops/devops_client/user/get_users_observable_responses.go +++ b/api/devops/devops_client/user/get_users_observable_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/user/get_users_parameters.go b/api/devops/devops_client/user/get_users_parameters.go index aefde18..db19d3f 100644 --- a/api/devops/devops_client/user/get_users_parameters.go +++ b/api/devops/devops_client/user/get_users_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -66,7 +66,7 @@ type GetUsersParams struct { /* AccountID. - Telnexus Record Id of an Account + Taxnexus Record Id of an Account */ AccountID *string @@ -78,7 +78,7 @@ type GetUsersParams struct { /* ContactID. - Telnexus Record Id of a Contact + Taxnexus Record Id of a Contact */ ContactID *string @@ -106,7 +106,7 @@ type GetUsersParams struct { /* UserID. - Telnexus User ID (unique) + Taxnexus User ID (unique) */ UserID *string diff --git a/api/devops/devops_client/user/get_users_responses.go b/api/devops/devops_client/user/get_users_responses.go index 65eb73c..530a80e 100644 --- a/api/devops/devops_client/user/get_users_responses.go +++ b/api/devops/devops_client/user/get_users_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewGetUsersOK() *GetUsersOK { /* GetUsersOK describes a response with status code 200, with default header values. -Telnexus Response with User objects +Taxnexus Response with User objects */ type GetUsersOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/user/post_users_parameters.go b/api/devops/devops_client/user/post_users_parameters.go index e14def6..b80400f 100644 --- a/api/devops/devops_client/user/post_users_parameters.go +++ b/api/devops/devops_client/user/post_users_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/user/post_users_responses.go b/api/devops/devops_client/user/post_users_responses.go index ae8dfff..da23a35 100644 --- a/api/devops/devops_client/user/post_users_responses.go +++ b/api/devops/devops_client/user/post_users_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPostUsersOK() *PostUsersOK { /* PostUsersOK describes a response with status code 200, with default header values. -Telnexus Response with User objects +Taxnexus Response with User objects */ type PostUsersOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/user/put_users_parameters.go b/api/devops/devops_client/user/put_users_parameters.go index 3a43aff..a128e8b 100644 --- a/api/devops/devops_client/user/put_users_parameters.go +++ b/api/devops/devops_client/user/put_users_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_client/user/put_users_responses.go b/api/devops/devops_client/user/put_users_responses.go index 88808ef..66ee1cc 100644 --- a/api/devops/devops_client/user/put_users_responses.go +++ b/api/devops/devops_client/user/put_users_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -75,7 +75,7 @@ func NewPutUsersOK() *PutUsersOK { /* PutUsersOK describes a response with status code 200, with default header values. -Telnexus Response with User objects +Taxnexus Response with User objects */ type PutUsersOK struct { AccessControlAllowOrigin string diff --git a/api/devops/devops_client/user/user_client.go b/api/devops/devops_client/user/user_client.go index adb80d8..777fe95 100644 --- a/api/devops/devops_client/user/user_client.go +++ b/api/devops/devops_client/user/user_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/address.go b/api/devops/devops_models/address.go index 407c757..21b6b9e 100644 --- a/api/devops/devops_models/address.go +++ b/api/devops/devops_models/address.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/cluster.go b/api/devops/devops_models/cluster.go index 13fee34..a5cfd76 100644 --- a/api/devops/devops_models/cluster.go +++ b/api/devops/devops_models/cluster.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -36,7 +36,7 @@ type Cluster struct { // Gateway Gateway string `json:"Gateway,omitempty"` - // Telnexus Record Id + // Taxnexus Record Id ID string `json:"ID,omitempty"` // IP Address diff --git a/api/devops/devops_models/cluster_request.go b/api/devops/devops_models/cluster_request.go index a0f4399..75553a5 100644 --- a/api/devops/devops_models/cluster_request.go +++ b/api/devops/devops_models/cluster_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/cluster_response.go b/api/devops/devops_models/cluster_response.go index 4a2284c..b35e6fd 100644 --- a/api/devops/devops_models/cluster_response.go +++ b/api/devops/devops_models/cluster_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/database.go b/api/devops/devops_models/database.go index 09be23b..bfd0053 100644 --- a/api/devops/devops_models/database.go +++ b/api/devops/devops_models/database.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -48,7 +48,7 @@ type Database struct { // Last Modifed Date LastModifiedDate string `json:"LastModifiedDate,omitempty"` - // List of Telnexus microservices implemented by this Database + // List of Taxnexus microservices implemented by this Database Microservices string `json:"Microservices,omitempty"` // The current status of this Tenant diff --git a/api/devops/devops_models/database_request.go b/api/devops/devops_models/database_request.go index 12a47b9..99abe7b 100644 --- a/api/devops/devops_models/database_request.go +++ b/api/devops/devops_models/database_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/database_response.go b/api/devops/devops_models/database_response.go index 51ed0b9..c2b6078 100644 --- a/api/devops/devops_models/database_response.go +++ b/api/devops/devops_models/database_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/delete_response.go b/api/devops/devops_models/delete_response.go index 5625e3c..e903566 100644 --- a/api/devops/devops_models/delete_response.go +++ b/api/devops/devops_models/delete_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/error.go b/api/devops/devops_models/error.go index 3db3500..08ea91d 100644 --- a/api/devops/devops_models/error.go +++ b/api/devops/devops_models/error.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/ingest.go b/api/devops/devops_models/ingest.go index 666a449..5cd3382 100644 --- a/api/devops/devops_models/ingest.go +++ b/api/devops/devops_models/ingest.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -19,7 +19,7 @@ import ( "github.com/go-openapi/validate" ) -// Ingest A record of the Ingest of information into Telnexus +// Ingest A record of the Ingest of information into Taxnexus // // swagger:model Ingest type Ingest struct { @@ -37,7 +37,7 @@ type Ingest struct { // Company ID CompanyID string `json:"CompanyID,omitempty"` - // Telnexus User ID + // Taxnexus User ID CreatedByID string `json:"CreatedByID,omitempty"` // Date of Job Creation @@ -71,7 +71,7 @@ type Ingest struct { // Job ID JobID string `json:"JobID,omitempty"` - // Telnexus User ID + // Taxnexus User ID LastModifiedByID string `json:"LastModifiedByID,omitempty"` // Last Modified Date diff --git a/api/devops/devops_models/ingest_request.go b/api/devops/devops_models/ingest_request.go index 11276a5..e752b14 100644 --- a/api/devops/devops_models/ingest_request.go +++ b/api/devops/devops_models/ingest_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/ingest_response.go b/api/devops/devops_models/ingest_response.go index 1a3880a..886dad6 100644 --- a/api/devops/devops_models/ingest_response.go +++ b/api/devops/devops_models/ingest_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/job.go b/api/devops/devops_models/job.go index 42330a2..f837ba4 100644 --- a/api/devops/devops_models/job.go +++ b/api/devops/devops_models/job.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -24,20 +24,20 @@ import ( // swagger:model Job type Job struct { - // Telnexus Account Id + // Taxnexus Account Id // Required: true AccountID *string `json:"AccountID"` - // Telnexus Backend ID + // Taxnexus Backend ID BackendID string `json:"BackendID,omitempty"` - // Telnexus Company ID + // Taxnexus Company ID CompanyID string `json:"CompanyID,omitempty"` - // Telnexus Coordinate ID + // Taxnexus Coordinate ID CoordinateID string `json:"CoordinateID,omitempty"` - // Telnexus User ID + // Taxnexus User ID CreatedByID string `json:"CreatedByID,omitempty"` // Date of Job Creation @@ -54,7 +54,7 @@ type Job struct { // Error Reason ErrorReason string `json:"ErrorReason,omitempty"` - // Telnexus Record Id of the Job record + // Taxnexus Record Id of the Job record ID string `json:"ID,omitempty"` // The time interval by which multiple jobs are executed within the Duration diff --git a/api/devops/devops_models/job_request.go b/api/devops/devops_models/job_request.go index dd27179..daa9577 100644 --- a/api/devops/devops_models/job_request.go +++ b/api/devops/devops_models/job_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/job_response.go b/api/devops/devops_models/job_response.go index 9d2f64c..655e293 100644 --- a/api/devops/devops_models/job_response.go +++ b/api/devops/devops_models/job_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/message.go b/api/devops/devops_models/message.go index 5dfa00c..621df2b 100644 --- a/api/devops/devops_models/message.go +++ b/api/devops/devops_models/message.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/pagination.go b/api/devops/devops_models/pagination.go index ffdea03..963bce0 100644 --- a/api/devops/devops_models/pagination.go +++ b/api/devops/devops_models/pagination.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/request_meta.go b/api/devops/devops_models/request_meta.go index 8dd7155..f806956 100644 --- a/api/devops/devops_models/request_meta.go +++ b/api/devops/devops_models/request_meta.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -23,16 +23,16 @@ import ( // swagger:model RequestMeta type RequestMeta struct { - // Telnexus Account Number of the Reseller or OEM + // Taxnexus Account Number of the Reseller or OEM // Required: true - TelnexusAccount *string `json:"TelnexusAccount"` + TaxnexusAccount *string `json:"TaxnexusAccount"` } // Validate validates this request meta func (m *RequestMeta) Validate(formats strfmt.Registry) error { var res []error - if err := m.validateTelnexusAccount(formats); err != nil { + if err := m.validateTaxnexusAccount(formats); err != nil { res = append(res, err) } @@ -42,9 +42,9 @@ func (m *RequestMeta) Validate(formats strfmt.Registry) error { return nil } -func (m *RequestMeta) validateTelnexusAccount(formats strfmt.Registry) error { +func (m *RequestMeta) validateTaxnexusAccount(formats strfmt.Registry) error { - if err := validate.Required("TelnexusAccount", "body", m.TelnexusAccount); err != nil { + if err := validate.Required("TaxnexusAccount", "body", m.TaxnexusAccount); err != nil { return err } diff --git a/api/devops/devops_models/response_meta.go b/api/devops/devops_models/response_meta.go index afc77d3..67ac126 100644 --- a/api/devops/devops_models/response_meta.go +++ b/api/devops/devops_models/response_meta.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -55,8 +55,8 @@ type ResponseMeta struct { // Backend Server Timestamp ServerTimestamp string `json:"ServerTimestamp,omitempty"` - // Telnexus Account Number used for recording transactions - TelnexusAccount string `json:"TelnexusAccount,omitempty"` + // Taxnexus Account Number used for recording transactions + TaxnexusAccount string `json:"TaxnexusAccount,omitempty"` } // Validate validates this response meta diff --git a/api/devops/devops_models/role.go b/api/devops/devops_models/role.go index 88473fc..78bb820 100644 --- a/api/devops/devops_models/role.go +++ b/api/devops/devops_models/role.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/role_request.go b/api/devops/devops_models/role_request.go index 0c8e6d9..4ebb020 100644 --- a/api/devops/devops_models/role_request.go +++ b/api/devops/devops_models/role_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/role_response.go b/api/devops/devops_models/role_response.go index 44375ee..693074f 100644 --- a/api/devops/devops_models/role_response.go +++ b/api/devops/devops_models/role_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/service.go b/api/devops/devops_models/service.go index 7c49597..eed4324 100644 --- a/api/devops/devops_models/service.go +++ b/api/devops/devops_models/service.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -48,7 +48,7 @@ type Service struct { // GELF Address GELFAddress string `json:"GELFAddress,omitempty"` - // Telnexus Record Id + // Taxnexus Record Id ID string `json:"ID,omitempty"` // Last Modified By diff --git a/api/devops/devops_models/service_request.go b/api/devops/devops_models/service_request.go index e127613..091468f 100644 --- a/api/devops/devops_models/service_request.go +++ b/api/devops/devops_models/service_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/service_response.go b/api/devops/devops_models/service_response.go index 20b99ca..adba1d4 100644 --- a/api/devops/devops_models/service_response.go +++ b/api/devops/devops_models/service_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/template.go b/api/devops/devops_models/template.go index 6631f28..ddc5553 100644 --- a/api/devops/devops_models/template.go +++ b/api/devops/devops_models/template.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -37,7 +37,7 @@ type Template struct { // Format: byte HTML strfmt.Base64 `json:"HTML,omitempty"` - // Telnexus Record Id + // Taxnexus Record Id ID string `json:"ID,omitempty"` // Active? diff --git a/api/devops/devops_models/template_request.go b/api/devops/devops_models/template_request.go index 16854c8..03ab95e 100644 --- a/api/devops/devops_models/template_request.go +++ b/api/devops/devops_models/template_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/template_response.go b/api/devops/devops_models/template_response.go index 243418a..6a765bb 100644 --- a/api/devops/devops_models/template_response.go +++ b/api/devops/devops_models/template_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/tenant.go b/api/devops/devops_models/tenant.go index affccb5..e6490f4 100644 --- a/api/devops/devops_models/tenant.go +++ b/api/devops/devops_models/tenant.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -18,7 +18,7 @@ import ( "github.com/go-openapi/swag" ) -// Tenant Telnexus Account Tenant +// Tenant Taxnexus Account Tenant // // swagger:model Tenant type Tenant struct { diff --git a/api/devops/devops_models/tenant_request.go b/api/devops/devops_models/tenant_request.go index f7caaba..97e9878 100644 --- a/api/devops/devops_models/tenant_request.go +++ b/api/devops/devops_models/tenant_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/tenant_response.go b/api/devops/devops_models/tenant_response.go index 2771efa..08bf737 100644 --- a/api/devops/devops_models/tenant_response.go +++ b/api/devops/devops_models/tenant_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/tenant_user.go b/api/devops/devops_models/tenant_user.go index b169a74..c363644 100644 --- a/api/devops/devops_models/tenant_user.go +++ b/api/devops/devops_models/tenant_user.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -36,8 +36,8 @@ type TenantUser struct { // Contact ID ContactID string `json:"ContactID,omitempty"` - // Telnexus Account - TelnexusAccount string `json:"TelnexusAccount,omitempty"` + // Taxnexus Account + TaxnexusAccount string `json:"TaxnexusAccount,omitempty"` // Tenant active? TenantActive bool `json:"TenantActive,omitempty"` diff --git a/api/devops/devops_models/user.go b/api/devops/devops_models/user.go index 3edb787..661a802 100644 --- a/api/devops/devops_models/user.go +++ b/api/devops/devops_models/user.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -95,7 +95,7 @@ type User struct { // Full Photo URL FullPhotoURL string `json:"FullPhotoURL,omitempty"` - // Telnexus ID + // Taxnexus ID ID string `json:"ID,omitempty"` // Active @@ -170,8 +170,8 @@ type User struct { // The time day starts StartOfDay string `json:"StartOfDay,omitempty"` - // Telnexus Account - TelnexusAccount string `json:"TelnexusAccount,omitempty"` + // Taxnexus Account + TaxnexusAccount string `json:"TaxnexusAccount,omitempty"` // Tenant ID associated with this user TenantID string `json:"TenantID,omitempty"` diff --git a/api/devops/devops_models/user_request.go b/api/devops/devops_models/user_request.go index b243238..f6b1a39 100644 --- a/api/devops/devops_models/user_request.go +++ b/api/devops/devops_models/user_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/user_response.go b/api/devops/devops_models/user_response.go index 6776d31..d423712 100644 --- a/api/devops/devops_models/user_response.go +++ b/api/devops/devops_models/user_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/devops/devops_models/user_role.go b/api/devops/devops_models/user_role.go index eea9e81..ae9805b 100644 --- a/api/devops/devops_models/user_role.go +++ b/api/devops/devops_models/user_role.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -45,8 +45,8 @@ type UserRole struct { // Role Name RoleName string `json:"RoleName,omitempty"` - // Telnexus Account Number - TelnexusAccount string `json:"TelnexusAccount,omitempty"` + // Taxnexus Account Number + TaxnexusAccount string `json:"TaxnexusAccount,omitempty"` // User Email Address UserEmail string `json:"UserEmail,omitempty"` diff --git a/api/isp/isp_client/isp_client.go b/api/isp/isp_client/isp_client.go deleted file mode 100644 index 04d0e13..0000000 --- a/api/isp/isp_client/isp_client.go +++ /dev/null @@ -1,116 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package isp_client - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "github.com/go-openapi/runtime" - httptransport "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/isp/isp_client/zone" -) - -// Default isp HTTP client. -var Default = NewHTTPClient(nil) - -const ( - // DefaultHost is the default Host - // found in Meta (info) section of spec file - DefaultHost string = "isp.infra.tnxs.net:8080" - // DefaultBasePath is the default BasePath - // found in Meta (info) section of spec file - DefaultBasePath string = "/v1" -) - -// DefaultSchemes are the default schemes found in Meta (info) section of spec file -var DefaultSchemes = []string{"http"} - -// NewHTTPClient creates a new isp HTTP client. -func NewHTTPClient(formats strfmt.Registry) *Isp { - return NewHTTPClientWithConfig(formats, nil) -} - -// NewHTTPClientWithConfig creates a new isp HTTP client, -// using a customizable transport config. -func NewHTTPClientWithConfig(formats strfmt.Registry, cfg *TransportConfig) *Isp { - // ensure nullable parameters have default - if cfg == nil { - cfg = DefaultTransportConfig() - } - - // create transport and client - transport := httptransport.New(cfg.Host, cfg.BasePath, cfg.Schemes) - return New(transport, formats) -} - -// New creates a new isp client -func New(transport runtime.ClientTransport, formats strfmt.Registry) *Isp { - // ensure nullable parameters have default - if formats == nil { - formats = strfmt.Default - } - - cli := new(Isp) - cli.Transport = transport - cli.Zone = zone.New(transport, formats) - return cli -} - -// DefaultTransportConfig creates a TransportConfig with the -// default settings taken from the meta section of the spec file. -func DefaultTransportConfig() *TransportConfig { - return &TransportConfig{ - Host: DefaultHost, - BasePath: DefaultBasePath, - Schemes: DefaultSchemes, - } -} - -// TransportConfig contains the transport related info, -// found in the meta section of the spec file. -type TransportConfig struct { - Host string - BasePath string - Schemes []string -} - -// WithHost overrides the default host, -// provided by the meta section of the spec file. -func (cfg *TransportConfig) WithHost(host string) *TransportConfig { - cfg.Host = host - return cfg -} - -// WithBasePath overrides the default basePath, -// provided by the meta section of the spec file. -func (cfg *TransportConfig) WithBasePath(basePath string) *TransportConfig { - cfg.BasePath = basePath - return cfg -} - -// WithSchemes overrides the default schemes, -// provided by the meta section of the spec file. -func (cfg *TransportConfig) WithSchemes(schemes []string) *TransportConfig { - cfg.Schemes = schemes - return cfg -} - -// Isp is a client for isp -type Isp struct { - Zone zone.ClientService - - Transport runtime.ClientTransport -} - -// SetTransport changes the transport on the client and all its subresources -func (c *Isp) SetTransport(transport runtime.ClientTransport) { - c.Transport = transport - c.Zone.SetTransport(transport) -} diff --git a/api/isp/isp_client/zone/get_zones_parameters.go b/api/isp/isp_client/zone/get_zones_parameters.go deleted file mode 100644 index ac0eba7..0000000 --- a/api/isp/isp_client/zone/get_zones_parameters.go +++ /dev/null @@ -1,253 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package zone - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// NewGetZonesParams creates a new GetZonesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetZonesParams() *GetZonesParams { - return &GetZonesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetZonesParamsWithTimeout creates a new GetZonesParams object -// with the ability to set a timeout on a request. -func NewGetZonesParamsWithTimeout(timeout time.Duration) *GetZonesParams { - return &GetZonesParams{ - timeout: timeout, - } -} - -// NewGetZonesParamsWithContext creates a new GetZonesParams object -// with the ability to set a context for a request. -func NewGetZonesParamsWithContext(ctx context.Context) *GetZonesParams { - return &GetZonesParams{ - Context: ctx, - } -} - -// NewGetZonesParamsWithHTTPClient creates a new GetZonesParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetZonesParamsWithHTTPClient(client *http.Client) *GetZonesParams { - return &GetZonesParams{ - HTTPClient: client, - } -} - -/* GetZonesParams contains all the parameters to send to the API endpoint - for the get zones operation. - - Typically these are written to a http.Request. -*/ -type GetZonesParams struct { - - /* Limit. - - How many objects to return at one time (max 300, default 100) - - Format: int64 - Default: 100 - */ - Limit *int64 - - /* Offset. - - How many objects to skip? (default 0) - - Format: int64 - */ - Offset *int64 - - /* ZoneID. - - Telnexus Record Id of a Zone - */ - ZoneID *string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get zones params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetZonesParams) WithDefaults() *GetZonesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get zones params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetZonesParams) SetDefaults() { - var ( - limitDefault = int64(100) - - offsetDefault = int64(0) - ) - - val := GetZonesParams{ - Limit: &limitDefault, - Offset: &offsetDefault, - } - - val.timeout = o.timeout - val.Context = o.Context - val.HTTPClient = o.HTTPClient - *o = val -} - -// WithTimeout adds the timeout to the get zones params -func (o *GetZonesParams) WithTimeout(timeout time.Duration) *GetZonesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get zones params -func (o *GetZonesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get zones params -func (o *GetZonesParams) WithContext(ctx context.Context) *GetZonesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get zones params -func (o *GetZonesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get zones params -func (o *GetZonesParams) WithHTTPClient(client *http.Client) *GetZonesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get zones params -func (o *GetZonesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithLimit adds the limit to the get zones params -func (o *GetZonesParams) WithLimit(limit *int64) *GetZonesParams { - o.SetLimit(limit) - return o -} - -// SetLimit adds the limit to the get zones params -func (o *GetZonesParams) SetLimit(limit *int64) { - o.Limit = limit -} - -// WithOffset adds the offset to the get zones params -func (o *GetZonesParams) WithOffset(offset *int64) *GetZonesParams { - o.SetOffset(offset) - return o -} - -// SetOffset adds the offset to the get zones params -func (o *GetZonesParams) SetOffset(offset *int64) { - o.Offset = offset -} - -// WithZoneID adds the zoneID to the get zones params -func (o *GetZonesParams) WithZoneID(zoneID *string) *GetZonesParams { - o.SetZoneID(zoneID) - return o -} - -// SetZoneID adds the zoneId to the get zones params -func (o *GetZonesParams) SetZoneID(zoneID *string) { - o.ZoneID = zoneID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetZonesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - if o.Limit != nil { - - // query param limit - var qrLimit int64 - - if o.Limit != nil { - qrLimit = *o.Limit - } - qLimit := swag.FormatInt64(qrLimit) - if qLimit != "" { - - if err := r.SetQueryParam("limit", qLimit); err != nil { - return err - } - } - } - - if o.Offset != nil { - - // query param offset - var qrOffset int64 - - if o.Offset != nil { - qrOffset = *o.Offset - } - qOffset := swag.FormatInt64(qrOffset) - if qOffset != "" { - - if err := r.SetQueryParam("offset", qOffset); err != nil { - return err - } - } - } - - if o.ZoneID != nil { - - // query param zoneId - var qrZoneID string - - if o.ZoneID != nil { - qrZoneID = *o.ZoneID - } - qZoneID := qrZoneID - if qZoneID != "" { - - if err := r.SetQueryParam("zoneId", qZoneID); err != nil { - return err - } - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/isp/isp_client/zone/get_zones_responses.go b/api/isp/isp_client/zone/get_zones_responses.go deleted file mode 100644 index 8a44ba2..0000000 --- a/api/isp/isp_client/zone/get_zones_responses.go +++ /dev/null @@ -1,363 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package zone - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/isp/isp_models" -) - -// GetZonesReader is a Reader for the GetZones structure. -type GetZonesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetZonesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetZonesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetZonesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewGetZonesForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetZonesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewGetZonesUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewGetZonesInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetZonesOK creates a GetZonesOK with default headers values -func NewGetZonesOK() *GetZonesOK { - return &GetZonesOK{} -} - -/* GetZonesOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of Zone objects -*/ -type GetZonesOK struct { - AccessControlAllowOrigin string - CacheControl string - - Payload *isp_models.ZoneResponse -} - -func (o *GetZonesOK) Error() string { - return fmt.Sprintf("[GET /zone][%d] getZonesOK %+v", 200, o.Payload) -} -func (o *GetZonesOK) GetPayload() *isp_models.ZoneResponse { - return o.Payload -} - -func (o *GetZonesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - // hydrates response header Access-Control-Allow-Origin - hdrAccessControlAllowOrigin := response.GetHeader("Access-Control-Allow-Origin") - - if hdrAccessControlAllowOrigin != "" { - o.AccessControlAllowOrigin = hdrAccessControlAllowOrigin - } - - // hydrates response header Cache-Control - hdrCacheControl := response.GetHeader("Cache-Control") - - if hdrCacheControl != "" { - o.CacheControl = hdrCacheControl - } - - o.Payload = new(isp_models.ZoneResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetZonesUnauthorized creates a GetZonesUnauthorized with default headers values -func NewGetZonesUnauthorized() *GetZonesUnauthorized { - return &GetZonesUnauthorized{} -} - -/* GetZonesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetZonesUnauthorized struct { - AccessControlAllowOrigin string - CacheControl string - - Payload *isp_models.Error -} - -func (o *GetZonesUnauthorized) Error() string { - return fmt.Sprintf("[GET /zone][%d] getZonesUnauthorized %+v", 401, o.Payload) -} -func (o *GetZonesUnauthorized) GetPayload() *isp_models.Error { - return o.Payload -} - -func (o *GetZonesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - // hydrates response header Access-Control-Allow-Origin - hdrAccessControlAllowOrigin := response.GetHeader("Access-Control-Allow-Origin") - - if hdrAccessControlAllowOrigin != "" { - o.AccessControlAllowOrigin = hdrAccessControlAllowOrigin - } - - // hydrates response header Cache-Control - hdrCacheControl := response.GetHeader("Cache-Control") - - if hdrCacheControl != "" { - o.CacheControl = hdrCacheControl - } - - o.Payload = new(isp_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetZonesForbidden creates a GetZonesForbidden with default headers values -func NewGetZonesForbidden() *GetZonesForbidden { - return &GetZonesForbidden{} -} - -/* GetZonesForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type GetZonesForbidden struct { - AccessControlAllowOrigin string - CacheControl string - - Payload *isp_models.Error -} - -func (o *GetZonesForbidden) Error() string { - return fmt.Sprintf("[GET /zone][%d] getZonesForbidden %+v", 403, o.Payload) -} -func (o *GetZonesForbidden) GetPayload() *isp_models.Error { - return o.Payload -} - -func (o *GetZonesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - // hydrates response header Access-Control-Allow-Origin - hdrAccessControlAllowOrigin := response.GetHeader("Access-Control-Allow-Origin") - - if hdrAccessControlAllowOrigin != "" { - o.AccessControlAllowOrigin = hdrAccessControlAllowOrigin - } - - // hydrates response header Cache-Control - hdrCacheControl := response.GetHeader("Cache-Control") - - if hdrCacheControl != "" { - o.CacheControl = hdrCacheControl - } - - o.Payload = new(isp_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetZonesNotFound creates a GetZonesNotFound with default headers values -func NewGetZonesNotFound() *GetZonesNotFound { - return &GetZonesNotFound{} -} - -/* GetZonesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetZonesNotFound struct { - AccessControlAllowOrigin string - CacheControl string - - Payload *isp_models.Error -} - -func (o *GetZonesNotFound) Error() string { - return fmt.Sprintf("[GET /zone][%d] getZonesNotFound %+v", 404, o.Payload) -} -func (o *GetZonesNotFound) GetPayload() *isp_models.Error { - return o.Payload -} - -func (o *GetZonesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - // hydrates response header Access-Control-Allow-Origin - hdrAccessControlAllowOrigin := response.GetHeader("Access-Control-Allow-Origin") - - if hdrAccessControlAllowOrigin != "" { - o.AccessControlAllowOrigin = hdrAccessControlAllowOrigin - } - - // hydrates response header Cache-Control - hdrCacheControl := response.GetHeader("Cache-Control") - - if hdrCacheControl != "" { - o.CacheControl = hdrCacheControl - } - - o.Payload = new(isp_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetZonesUnprocessableEntity creates a GetZonesUnprocessableEntity with default headers values -func NewGetZonesUnprocessableEntity() *GetZonesUnprocessableEntity { - return &GetZonesUnprocessableEntity{} -} - -/* GetZonesUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type GetZonesUnprocessableEntity struct { - AccessControlAllowOrigin string - CacheControl string - - Payload *isp_models.Error -} - -func (o *GetZonesUnprocessableEntity) Error() string { - return fmt.Sprintf("[GET /zone][%d] getZonesUnprocessableEntity %+v", 422, o.Payload) -} -func (o *GetZonesUnprocessableEntity) GetPayload() *isp_models.Error { - return o.Payload -} - -func (o *GetZonesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - // hydrates response header Access-Control-Allow-Origin - hdrAccessControlAllowOrigin := response.GetHeader("Access-Control-Allow-Origin") - - if hdrAccessControlAllowOrigin != "" { - o.AccessControlAllowOrigin = hdrAccessControlAllowOrigin - } - - // hydrates response header Cache-Control - hdrCacheControl := response.GetHeader("Cache-Control") - - if hdrCacheControl != "" { - o.CacheControl = hdrCacheControl - } - - o.Payload = new(isp_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetZonesInternalServerError creates a GetZonesInternalServerError with default headers values -func NewGetZonesInternalServerError() *GetZonesInternalServerError { - return &GetZonesInternalServerError{} -} - -/* GetZonesInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type GetZonesInternalServerError struct { - AccessControlAllowOrigin string - CacheControl string - - Payload *isp_models.Error -} - -func (o *GetZonesInternalServerError) Error() string { - return fmt.Sprintf("[GET /zone][%d] getZonesInternalServerError %+v", 500, o.Payload) -} -func (o *GetZonesInternalServerError) GetPayload() *isp_models.Error { - return o.Payload -} - -func (o *GetZonesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - // hydrates response header Access-Control-Allow-Origin - hdrAccessControlAllowOrigin := response.GetHeader("Access-Control-Allow-Origin") - - if hdrAccessControlAllowOrigin != "" { - o.AccessControlAllowOrigin = hdrAccessControlAllowOrigin - } - - // hydrates response header Cache-Control - hdrCacheControl := response.GetHeader("Cache-Control") - - if hdrCacheControl != "" { - o.CacheControl = hdrCacheControl - } - - o.Payload = new(isp_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/isp/isp_models/registrar.go b/api/isp/isp_models/registrar.go deleted file mode 100644 index 5df0526..0000000 --- a/api/isp/isp_models/registrar.go +++ /dev/null @@ -1,87 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package isp_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// Registrar registrar -// -// swagger:model Registrar -type Registrar struct { - - // Account - AccountID string `json:"AccountID,omitempty"` - - // Contact - ContactID string `json:"ContactID,omitempty"` - - // Created By - CreatedByID string `json:"CreatedById,omitempty"` - - // Created Date - CreatedDate string `json:"CreatedDate,omitempty"` - - // End Date - DateEnd string `json:"DateEnd,omitempty"` - - // Start Date - DateStart string `json:"DateStart,omitempty"` - - // Description - Description string `json:"Description,omitempty"` - - // Record Id - ID string `json:"ID,omitempty"` - - // Last Modified By - LastModifiedByID string `json:"LastModifiedById,omitempty"` - - // Last Modifed Date - LastModifiedDate string `json:"LastModifiedDate,omitempty"` - - // Registrar Name - RegistrarName string `json:"RegistrarName,omitempty"` - - // Registrar URL - URL string `json:"URL,omitempty"` -} - -// Validate validates this registrar -func (m *Registrar) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this registrar based on context it is used -func (m *Registrar) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *Registrar) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *Registrar) UnmarshalBinary(b []byte) error { - var res Registrar - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/isp/isp_models/response_meta.go b/api/isp/isp_models/response_meta.go deleted file mode 100644 index d6909a7..0000000 --- a/api/isp/isp_models/response_meta.go +++ /dev/null @@ -1,84 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package isp_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// ResponseMeta response meta -// -// swagger:model ResponseMeta -type ResponseMeta struct { - - // Microservice Contact Info - Contact string `json:"Contact,omitempty"` - - // Copyright Info - Copyright string `json:"Copyright,omitempty"` - - // License Information and Restrictions - License string `json:"License,omitempty"` - - // Operation ID - OperationID string `json:"OperationID,omitempty"` - - // Request IP Address - RequestIP string `json:"RequestIP,omitempty"` - - // Request Type - RequestType string `json:"RequestType,omitempty"` - - // Request URL - RequestURL string `json:"RequestURL,omitempty"` - - // Data Server Info - ServerInfo string `json:"ServerInfo,omitempty"` - - // Data Server Response Time (ms) - ServerResponseTime string `json:"ServerResponseTime,omitempty"` - - // Backend Server Timestamp - ServerTimestamp string `json:"ServerTimestamp,omitempty"` - - // Telnexus Account Number used for recording transactions - TelnexusAccount string `json:"TelnexusAccount,omitempty"` -} - -// Validate validates this response meta -func (m *ResponseMeta) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this response meta based on context it is used -func (m *ResponseMeta) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *ResponseMeta) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *ResponseMeta) UnmarshalBinary(b []byte) error { - var res ResponseMeta - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/isp/isp_models/zone.go b/api/isp/isp_models/zone.go deleted file mode 100644 index 14050b3..0000000 --- a/api/isp/isp_models/zone.go +++ /dev/null @@ -1,102 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package isp_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// Zone zone -// -// swagger:model Zone -type Zone struct { - - // Account - AccountID string `json:"AccountID,omitempty"` - - // Contact - ContactID string `json:"ContactID,omitempty"` - - // Created By - CreatedByID string `json:"CreatedById,omitempty"` - - // Created Date - CreatedDate string `json:"CreatedDate,omitempty"` - - // End Date - DateEnd string `json:"DateEnd,omitempty"` - - // Start Date - DateStart string `json:"DateStart,omitempty"` - - // Description - Description string `json:"Description,omitempty"` - - // Expiration Date - ExpirationDate string `json:"ExpirationDate,omitempty"` - - // The ID of the Host upon which this Zone is hosted - HostID string `json:"HostID,omitempty"` - - // Record Id - ID string `json:"ID,omitempty"` - - // ID Protect? - IDProtect bool `json:"IDProtect,omitempty"` - - // Last Modified By - LastModifiedByID string `json:"LastModifiedById,omitempty"` - - // Last Modifed Date - LastModifiedDate string `json:"LastModifiedDate,omitempty"` - - // Auto Renew? - PeriodStartID bool `json:"PeriodStartID,omitempty"` - - // ID of the Registar that owns this zone instance - RegistrarID string `json:"RegistrarID,omitempty"` - - // Term - Term string `json:"Term,omitempty"` - - // Zone Name - ZoneName string `json:"ZoneName,omitempty"` -} - -// Validate validates this zone -func (m *Zone) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this zone based on context it is used -func (m *Zone) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *Zone) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *Zone) UnmarshalBinary(b []byte) error { - var res Zone - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/kazoo/kazoo_client/account/account_client.go b/api/kazoo/kazoo_client/account/account_client.go deleted file mode 100644 index cf10b1c..0000000 --- a/api/kazoo/kazoo_client/account/account_client.go +++ /dev/null @@ -1,125 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package account - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" -) - -// New creates a new account API client. -func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { - return &Client{transport: transport, formats: formats} -} - -/* -Client for account API -*/ -type Client struct { - transport runtime.ClientTransport - formats strfmt.Registry -} - -// ClientOption is the option for Client methods -type ClientOption func(*runtime.ClientOperation) - -// ClientService is the interface for Client methods -type ClientService interface { - GetAccountDescendents(params *GetAccountDescendentsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountDescendentsOK, error) - - GetAccounts(params *GetAccountsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountsOK, error) - - SetTransport(transport runtime.ClientTransport) -} - -/* - GetAccountDescendents get account descendents API -*/ -func (a *Client) GetAccountDescendents(params *GetAccountDescendentsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountDescendentsOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewGetAccountDescendentsParams() - } - op := &runtime.ClientOperation{ - ID: "getAccountDescendents", - Method: "GET", - PathPattern: "/accounts/{accountId}/descendents", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"https"}, - Params: params, - Reader: &GetAccountDescendentsReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*GetAccountDescendentsOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getAccountDescendents: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -/* - GetAccounts get accounts API -*/ -func (a *Client) GetAccounts(params *GetAccountsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountsOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewGetAccountsParams() - } - op := &runtime.ClientOperation{ - ID: "getAccounts", - Method: "GET", - PathPattern: "/accounts/{accountId}", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"https"}, - Params: params, - Reader: &GetAccountsReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*GetAccountsOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getAccounts: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -// SetTransport changes the transport on the client -func (a *Client) SetTransport(transport runtime.ClientTransport) { - a.transport = transport -} diff --git a/api/kazoo/kazoo_client/account/get_account_descendents_parameters.go b/api/kazoo/kazoo_client/account/get_account_descendents_parameters.go deleted file mode 100644 index 18845e9..0000000 --- a/api/kazoo/kazoo_client/account/get_account_descendents_parameters.go +++ /dev/null @@ -1,150 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package account - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" -) - -// NewGetAccountDescendentsParams creates a new GetAccountDescendentsParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetAccountDescendentsParams() *GetAccountDescendentsParams { - return &GetAccountDescendentsParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetAccountDescendentsParamsWithTimeout creates a new GetAccountDescendentsParams object -// with the ability to set a timeout on a request. -func NewGetAccountDescendentsParamsWithTimeout(timeout time.Duration) *GetAccountDescendentsParams { - return &GetAccountDescendentsParams{ - timeout: timeout, - } -} - -// NewGetAccountDescendentsParamsWithContext creates a new GetAccountDescendentsParams object -// with the ability to set a context for a request. -func NewGetAccountDescendentsParamsWithContext(ctx context.Context) *GetAccountDescendentsParams { - return &GetAccountDescendentsParams{ - Context: ctx, - } -} - -// NewGetAccountDescendentsParamsWithHTTPClient creates a new GetAccountDescendentsParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetAccountDescendentsParamsWithHTTPClient(client *http.Client) *GetAccountDescendentsParams { - return &GetAccountDescendentsParams{ - HTTPClient: client, - } -} - -/* GetAccountDescendentsParams contains all the parameters to send to the API endpoint - for the get account descendents operation. - - Typically these are written to a http.Request. -*/ -type GetAccountDescendentsParams struct { - - // AccountID. - AccountID string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get account descendents params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountDescendentsParams) WithDefaults() *GetAccountDescendentsParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get account descendents params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountDescendentsParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the get account descendents params -func (o *GetAccountDescendentsParams) WithTimeout(timeout time.Duration) *GetAccountDescendentsParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get account descendents params -func (o *GetAccountDescendentsParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get account descendents params -func (o *GetAccountDescendentsParams) WithContext(ctx context.Context) *GetAccountDescendentsParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get account descendents params -func (o *GetAccountDescendentsParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get account descendents params -func (o *GetAccountDescendentsParams) WithHTTPClient(client *http.Client) *GetAccountDescendentsParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get account descendents params -func (o *GetAccountDescendentsParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAccountID adds the accountID to the get account descendents params -func (o *GetAccountDescendentsParams) WithAccountID(accountID string) *GetAccountDescendentsParams { - o.SetAccountID(accountID) - return o -} - -// SetAccountID adds the accountId to the get account descendents params -func (o *GetAccountDescendentsParams) SetAccountID(accountID string) { - o.AccountID = accountID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetAccountDescendentsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - // path param accountId - if err := r.SetPathParam("accountId", o.AccountID); err != nil { - return err - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/kazoo/kazoo_client/account/get_account_descendents_responses.go b/api/kazoo/kazoo_client/account/get_account_descendents_responses.go deleted file mode 100644 index d3c593e..0000000 --- a/api/kazoo/kazoo_client/account/get_account_descendents_responses.go +++ /dev/null @@ -1,147 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package account - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_models" -) - -// GetAccountDescendentsReader is a Reader for the GetAccountDescendents structure. -type GetAccountDescendentsReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetAccountDescendentsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetAccountDescendentsOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetAccountDescendentsUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetAccountDescendentsNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetAccountDescendentsOK creates a GetAccountDescendentsOK with default headers values -func NewGetAccountDescendentsOK() *GetAccountDescendentsOK { - return &GetAccountDescendentsOK{} -} - -/* GetAccountDescendentsOK describes a response with status code 200, with default header values. - -Kazoo response -*/ -type GetAccountDescendentsOK struct { - Payload *kazoo_models.GetAccountDescendentResponse -} - -func (o *GetAccountDescendentsOK) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/descendents][%d] getAccountDescendentsOK %+v", 200, o.Payload) -} -func (o *GetAccountDescendentsOK) GetPayload() *kazoo_models.GetAccountDescendentResponse { - return o.Payload -} - -func (o *GetAccountDescendentsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.GetAccountDescendentResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountDescendentsUnauthorized creates a GetAccountDescendentsUnauthorized with default headers values -func NewGetAccountDescendentsUnauthorized() *GetAccountDescendentsUnauthorized { - return &GetAccountDescendentsUnauthorized{} -} - -/* GetAccountDescendentsUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetAccountDescendentsUnauthorized struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountDescendentsUnauthorized) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/descendents][%d] getAccountDescendentsUnauthorized %+v", 401, o.Payload) -} -func (o *GetAccountDescendentsUnauthorized) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountDescendentsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountDescendentsNotFound creates a GetAccountDescendentsNotFound with default headers values -func NewGetAccountDescendentsNotFound() *GetAccountDescendentsNotFound { - return &GetAccountDescendentsNotFound{} -} - -/* GetAccountDescendentsNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetAccountDescendentsNotFound struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountDescendentsNotFound) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/descendents][%d] getAccountDescendentsNotFound %+v", 404, o.Payload) -} -func (o *GetAccountDescendentsNotFound) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountDescendentsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/kazoo/kazoo_client/account/get_accounts_responses.go b/api/kazoo/kazoo_client/account/get_accounts_responses.go deleted file mode 100644 index 721b7e3..0000000 --- a/api/kazoo/kazoo_client/account/get_accounts_responses.go +++ /dev/null @@ -1,147 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package account - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_models" -) - -// GetAccountsReader is a Reader for the GetAccounts structure. -type GetAccountsReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetAccountsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetAccountsOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetAccountsUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetAccountsNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetAccountsOK creates a GetAccountsOK with default headers values -func NewGetAccountsOK() *GetAccountsOK { - return &GetAccountsOK{} -} - -/* GetAccountsOK describes a response with status code 200, with default header values. - -Kazoo response -*/ -type GetAccountsOK struct { - Payload *kazoo_models.GetAccountResponse -} - -func (o *GetAccountsOK) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}][%d] getAccountsOK %+v", 200, o.Payload) -} -func (o *GetAccountsOK) GetPayload() *kazoo_models.GetAccountResponse { - return o.Payload -} - -func (o *GetAccountsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.GetAccountResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountsUnauthorized creates a GetAccountsUnauthorized with default headers values -func NewGetAccountsUnauthorized() *GetAccountsUnauthorized { - return &GetAccountsUnauthorized{} -} - -/* GetAccountsUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetAccountsUnauthorized struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountsUnauthorized) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}][%d] getAccountsUnauthorized %+v", 401, o.Payload) -} -func (o *GetAccountsUnauthorized) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountsNotFound creates a GetAccountsNotFound with default headers values -func NewGetAccountsNotFound() *GetAccountsNotFound { - return &GetAccountsNotFound{} -} - -/* GetAccountsNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetAccountsNotFound struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountsNotFound) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}][%d] getAccountsNotFound %+v", 404, o.Payload) -} -func (o *GetAccountsNotFound) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/kazoo/kazoo_client/call_flow/call_flow_client.go b/api/kazoo/kazoo_client/call_flow/call_flow_client.go deleted file mode 100644 index 9562915..0000000 --- a/api/kazoo/kazoo_client/call_flow/call_flow_client.go +++ /dev/null @@ -1,84 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package call_flow - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" -) - -// New creates a new call flow API client. -func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { - return &Client{transport: transport, formats: formats} -} - -/* -Client for call flow API -*/ -type Client struct { - transport runtime.ClientTransport - formats strfmt.Registry -} - -// ClientOption is the option for Client methods -type ClientOption func(*runtime.ClientOperation) - -// ClientService is the interface for Client methods -type ClientService interface { - GetAccountCallflows(params *GetAccountCallflowsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountCallflowsOK, error) - - SetTransport(transport runtime.ClientTransport) -} - -/* - GetAccountCallflows get account callflows API -*/ -func (a *Client) GetAccountCallflows(params *GetAccountCallflowsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountCallflowsOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewGetAccountCallflowsParams() - } - op := &runtime.ClientOperation{ - ID: "getAccountCallflows", - Method: "GET", - PathPattern: "/accounts/{accountId}/callflows", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"https"}, - Params: params, - Reader: &GetAccountCallflowsReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*GetAccountCallflowsOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getAccountCallflows: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -// SetTransport changes the transport on the client -func (a *Client) SetTransport(transport runtime.ClientTransport) { - a.transport = transport -} diff --git a/api/kazoo/kazoo_client/call_flow/get_account_callflows_parameters.go b/api/kazoo/kazoo_client/call_flow/get_account_callflows_parameters.go deleted file mode 100644 index 6397d6e..0000000 --- a/api/kazoo/kazoo_client/call_flow/get_account_callflows_parameters.go +++ /dev/null @@ -1,150 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package call_flow - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" -) - -// NewGetAccountCallflowsParams creates a new GetAccountCallflowsParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetAccountCallflowsParams() *GetAccountCallflowsParams { - return &GetAccountCallflowsParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetAccountCallflowsParamsWithTimeout creates a new GetAccountCallflowsParams object -// with the ability to set a timeout on a request. -func NewGetAccountCallflowsParamsWithTimeout(timeout time.Duration) *GetAccountCallflowsParams { - return &GetAccountCallflowsParams{ - timeout: timeout, - } -} - -// NewGetAccountCallflowsParamsWithContext creates a new GetAccountCallflowsParams object -// with the ability to set a context for a request. -func NewGetAccountCallflowsParamsWithContext(ctx context.Context) *GetAccountCallflowsParams { - return &GetAccountCallflowsParams{ - Context: ctx, - } -} - -// NewGetAccountCallflowsParamsWithHTTPClient creates a new GetAccountCallflowsParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetAccountCallflowsParamsWithHTTPClient(client *http.Client) *GetAccountCallflowsParams { - return &GetAccountCallflowsParams{ - HTTPClient: client, - } -} - -/* GetAccountCallflowsParams contains all the parameters to send to the API endpoint - for the get account callflows operation. - - Typically these are written to a http.Request. -*/ -type GetAccountCallflowsParams struct { - - // AccountID. - AccountID string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get account callflows params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountCallflowsParams) WithDefaults() *GetAccountCallflowsParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get account callflows params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountCallflowsParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the get account callflows params -func (o *GetAccountCallflowsParams) WithTimeout(timeout time.Duration) *GetAccountCallflowsParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get account callflows params -func (o *GetAccountCallflowsParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get account callflows params -func (o *GetAccountCallflowsParams) WithContext(ctx context.Context) *GetAccountCallflowsParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get account callflows params -func (o *GetAccountCallflowsParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get account callflows params -func (o *GetAccountCallflowsParams) WithHTTPClient(client *http.Client) *GetAccountCallflowsParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get account callflows params -func (o *GetAccountCallflowsParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAccountID adds the accountID to the get account callflows params -func (o *GetAccountCallflowsParams) WithAccountID(accountID string) *GetAccountCallflowsParams { - o.SetAccountID(accountID) - return o -} - -// SetAccountID adds the accountId to the get account callflows params -func (o *GetAccountCallflowsParams) SetAccountID(accountID string) { - o.AccountID = accountID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetAccountCallflowsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - // path param accountId - if err := r.SetPathParam("accountId", o.AccountID); err != nil { - return err - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/kazoo/kazoo_client/call_flow/get_account_callflows_responses.go b/api/kazoo/kazoo_client/call_flow/get_account_callflows_responses.go deleted file mode 100644 index a143358..0000000 --- a/api/kazoo/kazoo_client/call_flow/get_account_callflows_responses.go +++ /dev/null @@ -1,147 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package call_flow - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_models" -) - -// GetAccountCallflowsReader is a Reader for the GetAccountCallflows structure. -type GetAccountCallflowsReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetAccountCallflowsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetAccountCallflowsOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetAccountCallflowsUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetAccountCallflowsNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetAccountCallflowsOK creates a GetAccountCallflowsOK with default headers values -func NewGetAccountCallflowsOK() *GetAccountCallflowsOK { - return &GetAccountCallflowsOK{} -} - -/* GetAccountCallflowsOK describes a response with status code 200, with default header values. - -Kazoo response -*/ -type GetAccountCallflowsOK struct { - Payload *kazoo_models.GetAccountCallflowResponse -} - -func (o *GetAccountCallflowsOK) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/callflows][%d] getAccountCallflowsOK %+v", 200, o.Payload) -} -func (o *GetAccountCallflowsOK) GetPayload() *kazoo_models.GetAccountCallflowResponse { - return o.Payload -} - -func (o *GetAccountCallflowsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.GetAccountCallflowResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountCallflowsUnauthorized creates a GetAccountCallflowsUnauthorized with default headers values -func NewGetAccountCallflowsUnauthorized() *GetAccountCallflowsUnauthorized { - return &GetAccountCallflowsUnauthorized{} -} - -/* GetAccountCallflowsUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetAccountCallflowsUnauthorized struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountCallflowsUnauthorized) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/callflows][%d] getAccountCallflowsUnauthorized %+v", 401, o.Payload) -} -func (o *GetAccountCallflowsUnauthorized) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountCallflowsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountCallflowsNotFound creates a GetAccountCallflowsNotFound with default headers values -func NewGetAccountCallflowsNotFound() *GetAccountCallflowsNotFound { - return &GetAccountCallflowsNotFound{} -} - -/* GetAccountCallflowsNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetAccountCallflowsNotFound struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountCallflowsNotFound) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/callflows][%d] getAccountCallflowsNotFound %+v", 404, o.Payload) -} -func (o *GetAccountCallflowsNotFound) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountCallflowsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/kazoo/kazoo_client/cdr/get_account_c_d_rs_parameters.go b/api/kazoo/kazoo_client/cdr/get_account_c_d_rs_parameters.go deleted file mode 100644 index 892aefc..0000000 --- a/api/kazoo/kazoo_client/cdr/get_account_c_d_rs_parameters.go +++ /dev/null @@ -1,203 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package cdr - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// NewGetAccountCDRsParams creates a new GetAccountCDRsParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetAccountCDRsParams() *GetAccountCDRsParams { - return &GetAccountCDRsParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetAccountCDRsParamsWithTimeout creates a new GetAccountCDRsParams object -// with the ability to set a timeout on a request. -func NewGetAccountCDRsParamsWithTimeout(timeout time.Duration) *GetAccountCDRsParams { - return &GetAccountCDRsParams{ - timeout: timeout, - } -} - -// NewGetAccountCDRsParamsWithContext creates a new GetAccountCDRsParams object -// with the ability to set a context for a request. -func NewGetAccountCDRsParamsWithContext(ctx context.Context) *GetAccountCDRsParams { - return &GetAccountCDRsParams{ - Context: ctx, - } -} - -// NewGetAccountCDRsParamsWithHTTPClient creates a new GetAccountCDRsParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetAccountCDRsParamsWithHTTPClient(client *http.Client) *GetAccountCDRsParams { - return &GetAccountCDRsParams{ - HTTPClient: client, - } -} - -/* GetAccountCDRsParams contains all the parameters to send to the API endpoint - for the get account c d rs operation. - - Typically these are written to a http.Request. -*/ -type GetAccountCDRsParams struct { - - // AccountID. - AccountID string - - // CreatedFrom. - // - // Format: int64 - CreatedFrom int64 - - // CreatedTo. - // - // Format: int64 - CreatedTo int64 - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get account c d rs params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountCDRsParams) WithDefaults() *GetAccountCDRsParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get account c d rs params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountCDRsParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the get account c d rs params -func (o *GetAccountCDRsParams) WithTimeout(timeout time.Duration) *GetAccountCDRsParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get account c d rs params -func (o *GetAccountCDRsParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get account c d rs params -func (o *GetAccountCDRsParams) WithContext(ctx context.Context) *GetAccountCDRsParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get account c d rs params -func (o *GetAccountCDRsParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get account c d rs params -func (o *GetAccountCDRsParams) WithHTTPClient(client *http.Client) *GetAccountCDRsParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get account c d rs params -func (o *GetAccountCDRsParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAccountID adds the accountID to the get account c d rs params -func (o *GetAccountCDRsParams) WithAccountID(accountID string) *GetAccountCDRsParams { - o.SetAccountID(accountID) - return o -} - -// SetAccountID adds the accountId to the get account c d rs params -func (o *GetAccountCDRsParams) SetAccountID(accountID string) { - o.AccountID = accountID -} - -// WithCreatedFrom adds the createdFrom to the get account c d rs params -func (o *GetAccountCDRsParams) WithCreatedFrom(createdFrom int64) *GetAccountCDRsParams { - o.SetCreatedFrom(createdFrom) - return o -} - -// SetCreatedFrom adds the createdFrom to the get account c d rs params -func (o *GetAccountCDRsParams) SetCreatedFrom(createdFrom int64) { - o.CreatedFrom = createdFrom -} - -// WithCreatedTo adds the createdTo to the get account c d rs params -func (o *GetAccountCDRsParams) WithCreatedTo(createdTo int64) *GetAccountCDRsParams { - o.SetCreatedTo(createdTo) - return o -} - -// SetCreatedTo adds the createdTo to the get account c d rs params -func (o *GetAccountCDRsParams) SetCreatedTo(createdTo int64) { - o.CreatedTo = createdTo -} - -// WriteToRequest writes these params to a swagger request -func (o *GetAccountCDRsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - // path param accountId - if err := r.SetPathParam("accountId", o.AccountID); err != nil { - return err - } - - // query param created_from - qrCreatedFrom := o.CreatedFrom - qCreatedFrom := swag.FormatInt64(qrCreatedFrom) - if qCreatedFrom != "" { - - if err := r.SetQueryParam("created_from", qCreatedFrom); err != nil { - return err - } - } - - // query param created_to - qrCreatedTo := o.CreatedTo - qCreatedTo := swag.FormatInt64(qrCreatedTo) - if qCreatedTo != "" { - - if err := r.SetQueryParam("created_to", qCreatedTo); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/kazoo/kazoo_client/cdr/get_account_c_d_rs_responses.go b/api/kazoo/kazoo_client/cdr/get_account_c_d_rs_responses.go deleted file mode 100644 index e3f1ac6..0000000 --- a/api/kazoo/kazoo_client/cdr/get_account_c_d_rs_responses.go +++ /dev/null @@ -1,147 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package cdr - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_models" -) - -// GetAccountCDRsReader is a Reader for the GetAccountCDRs structure. -type GetAccountCDRsReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetAccountCDRsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetAccountCDRsOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetAccountCDRsUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetAccountCDRsNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetAccountCDRsOK creates a GetAccountCDRsOK with default headers values -func NewGetAccountCDRsOK() *GetAccountCDRsOK { - return &GetAccountCDRsOK{} -} - -/* GetAccountCDRsOK describes a response with status code 200, with default header values. - -Kazoo response -*/ -type GetAccountCDRsOK struct { - Payload *kazoo_models.GetAccountCdrResponse -} - -func (o *GetAccountCDRsOK) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/cdrs][%d] getAccountCDRsOK %+v", 200, o.Payload) -} -func (o *GetAccountCDRsOK) GetPayload() *kazoo_models.GetAccountCdrResponse { - return o.Payload -} - -func (o *GetAccountCDRsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.GetAccountCdrResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountCDRsUnauthorized creates a GetAccountCDRsUnauthorized with default headers values -func NewGetAccountCDRsUnauthorized() *GetAccountCDRsUnauthorized { - return &GetAccountCDRsUnauthorized{} -} - -/* GetAccountCDRsUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetAccountCDRsUnauthorized struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountCDRsUnauthorized) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/cdrs][%d] getAccountCDRsUnauthorized %+v", 401, o.Payload) -} -func (o *GetAccountCDRsUnauthorized) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountCDRsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountCDRsNotFound creates a GetAccountCDRsNotFound with default headers values -func NewGetAccountCDRsNotFound() *GetAccountCDRsNotFound { - return &GetAccountCDRsNotFound{} -} - -/* GetAccountCDRsNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetAccountCDRsNotFound struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountCDRsNotFound) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/cdrs][%d] getAccountCDRsNotFound %+v", 404, o.Payload) -} -func (o *GetAccountCDRsNotFound) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountCDRsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/kazoo/kazoo_client/device/device_client.go b/api/kazoo/kazoo_client/device/device_client.go deleted file mode 100644 index 57c64f3..0000000 --- a/api/kazoo/kazoo_client/device/device_client.go +++ /dev/null @@ -1,125 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package device - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" -) - -// New creates a new device API client. -func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { - return &Client{transport: transport, formats: formats} -} - -/* -Client for device API -*/ -type Client struct { - transport runtime.ClientTransport - formats strfmt.Registry -} - -// ClientOption is the option for Client methods -type ClientOption func(*runtime.ClientOperation) - -// ClientService is the interface for Client methods -type ClientService interface { - GetAccountDevices(params *GetAccountDevicesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountDevicesOK, error) - - GetUserDevices(params *GetUserDevicesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetUserDevicesOK, error) - - SetTransport(transport runtime.ClientTransport) -} - -/* - GetAccountDevices get account devices API -*/ -func (a *Client) GetAccountDevices(params *GetAccountDevicesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountDevicesOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewGetAccountDevicesParams() - } - op := &runtime.ClientOperation{ - ID: "getAccountDevices", - Method: "GET", - PathPattern: "/accounts/{accountId}/devices", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"https"}, - Params: params, - Reader: &GetAccountDevicesReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*GetAccountDevicesOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getAccountDevices: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -/* - GetUserDevices get user devices API -*/ -func (a *Client) GetUserDevices(params *GetUserDevicesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetUserDevicesOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewGetUserDevicesParams() - } - op := &runtime.ClientOperation{ - ID: "getUserDevices", - Method: "GET", - PathPattern: "/accounts/{accountId}/users/{userId}/devices", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"https"}, - Params: params, - Reader: &GetUserDevicesReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*GetUserDevicesOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getUserDevices: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -// SetTransport changes the transport on the client -func (a *Client) SetTransport(transport runtime.ClientTransport) { - a.transport = transport -} diff --git a/api/kazoo/kazoo_client/device/get_account_devices_parameters.go b/api/kazoo/kazoo_client/device/get_account_devices_parameters.go deleted file mode 100644 index bc48f53..0000000 --- a/api/kazoo/kazoo_client/device/get_account_devices_parameters.go +++ /dev/null @@ -1,150 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package device - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" -) - -// NewGetAccountDevicesParams creates a new GetAccountDevicesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetAccountDevicesParams() *GetAccountDevicesParams { - return &GetAccountDevicesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetAccountDevicesParamsWithTimeout creates a new GetAccountDevicesParams object -// with the ability to set a timeout on a request. -func NewGetAccountDevicesParamsWithTimeout(timeout time.Duration) *GetAccountDevicesParams { - return &GetAccountDevicesParams{ - timeout: timeout, - } -} - -// NewGetAccountDevicesParamsWithContext creates a new GetAccountDevicesParams object -// with the ability to set a context for a request. -func NewGetAccountDevicesParamsWithContext(ctx context.Context) *GetAccountDevicesParams { - return &GetAccountDevicesParams{ - Context: ctx, - } -} - -// NewGetAccountDevicesParamsWithHTTPClient creates a new GetAccountDevicesParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetAccountDevicesParamsWithHTTPClient(client *http.Client) *GetAccountDevicesParams { - return &GetAccountDevicesParams{ - HTTPClient: client, - } -} - -/* GetAccountDevicesParams contains all the parameters to send to the API endpoint - for the get account devices operation. - - Typically these are written to a http.Request. -*/ -type GetAccountDevicesParams struct { - - // AccountID. - AccountID string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get account devices params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountDevicesParams) WithDefaults() *GetAccountDevicesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get account devices params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountDevicesParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the get account devices params -func (o *GetAccountDevicesParams) WithTimeout(timeout time.Duration) *GetAccountDevicesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get account devices params -func (o *GetAccountDevicesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get account devices params -func (o *GetAccountDevicesParams) WithContext(ctx context.Context) *GetAccountDevicesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get account devices params -func (o *GetAccountDevicesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get account devices params -func (o *GetAccountDevicesParams) WithHTTPClient(client *http.Client) *GetAccountDevicesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get account devices params -func (o *GetAccountDevicesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAccountID adds the accountID to the get account devices params -func (o *GetAccountDevicesParams) WithAccountID(accountID string) *GetAccountDevicesParams { - o.SetAccountID(accountID) - return o -} - -// SetAccountID adds the accountId to the get account devices params -func (o *GetAccountDevicesParams) SetAccountID(accountID string) { - o.AccountID = accountID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetAccountDevicesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - // path param accountId - if err := r.SetPathParam("accountId", o.AccountID); err != nil { - return err - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/kazoo/kazoo_client/device/get_account_devices_responses.go b/api/kazoo/kazoo_client/device/get_account_devices_responses.go deleted file mode 100644 index 26a95e3..0000000 --- a/api/kazoo/kazoo_client/device/get_account_devices_responses.go +++ /dev/null @@ -1,147 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package device - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_models" -) - -// GetAccountDevicesReader is a Reader for the GetAccountDevices structure. -type GetAccountDevicesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetAccountDevicesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetAccountDevicesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetAccountDevicesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetAccountDevicesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetAccountDevicesOK creates a GetAccountDevicesOK with default headers values -func NewGetAccountDevicesOK() *GetAccountDevicesOK { - return &GetAccountDevicesOK{} -} - -/* GetAccountDevicesOK describes a response with status code 200, with default header values. - -Kazoo response -*/ -type GetAccountDevicesOK struct { - Payload *kazoo_models.GetDeviceResponse -} - -func (o *GetAccountDevicesOK) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/devices][%d] getAccountDevicesOK %+v", 200, o.Payload) -} -func (o *GetAccountDevicesOK) GetPayload() *kazoo_models.GetDeviceResponse { - return o.Payload -} - -func (o *GetAccountDevicesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.GetDeviceResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountDevicesUnauthorized creates a GetAccountDevicesUnauthorized with default headers values -func NewGetAccountDevicesUnauthorized() *GetAccountDevicesUnauthorized { - return &GetAccountDevicesUnauthorized{} -} - -/* GetAccountDevicesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetAccountDevicesUnauthorized struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountDevicesUnauthorized) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/devices][%d] getAccountDevicesUnauthorized %+v", 401, o.Payload) -} -func (o *GetAccountDevicesUnauthorized) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountDevicesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountDevicesNotFound creates a GetAccountDevicesNotFound with default headers values -func NewGetAccountDevicesNotFound() *GetAccountDevicesNotFound { - return &GetAccountDevicesNotFound{} -} - -/* GetAccountDevicesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetAccountDevicesNotFound struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountDevicesNotFound) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/devices][%d] getAccountDevicesNotFound %+v", 404, o.Payload) -} -func (o *GetAccountDevicesNotFound) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountDevicesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/kazoo/kazoo_client/device/get_user_devices_parameters.go b/api/kazoo/kazoo_client/device/get_user_devices_parameters.go deleted file mode 100644 index 4725646..0000000 --- a/api/kazoo/kazoo_client/device/get_user_devices_parameters.go +++ /dev/null @@ -1,169 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package device - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" -) - -// NewGetUserDevicesParams creates a new GetUserDevicesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetUserDevicesParams() *GetUserDevicesParams { - return &GetUserDevicesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetUserDevicesParamsWithTimeout creates a new GetUserDevicesParams object -// with the ability to set a timeout on a request. -func NewGetUserDevicesParamsWithTimeout(timeout time.Duration) *GetUserDevicesParams { - return &GetUserDevicesParams{ - timeout: timeout, - } -} - -// NewGetUserDevicesParamsWithContext creates a new GetUserDevicesParams object -// with the ability to set a context for a request. -func NewGetUserDevicesParamsWithContext(ctx context.Context) *GetUserDevicesParams { - return &GetUserDevicesParams{ - Context: ctx, - } -} - -// NewGetUserDevicesParamsWithHTTPClient creates a new GetUserDevicesParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetUserDevicesParamsWithHTTPClient(client *http.Client) *GetUserDevicesParams { - return &GetUserDevicesParams{ - HTTPClient: client, - } -} - -/* GetUserDevicesParams contains all the parameters to send to the API endpoint - for the get user devices operation. - - Typically these are written to a http.Request. -*/ -type GetUserDevicesParams struct { - - // AccountID. - AccountID string - - // UserID. - UserID string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get user devices params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetUserDevicesParams) WithDefaults() *GetUserDevicesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get user devices params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetUserDevicesParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the get user devices params -func (o *GetUserDevicesParams) WithTimeout(timeout time.Duration) *GetUserDevicesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get user devices params -func (o *GetUserDevicesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get user devices params -func (o *GetUserDevicesParams) WithContext(ctx context.Context) *GetUserDevicesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get user devices params -func (o *GetUserDevicesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get user devices params -func (o *GetUserDevicesParams) WithHTTPClient(client *http.Client) *GetUserDevicesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get user devices params -func (o *GetUserDevicesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAccountID adds the accountID to the get user devices params -func (o *GetUserDevicesParams) WithAccountID(accountID string) *GetUserDevicesParams { - o.SetAccountID(accountID) - return o -} - -// SetAccountID adds the accountId to the get user devices params -func (o *GetUserDevicesParams) SetAccountID(accountID string) { - o.AccountID = accountID -} - -// WithUserID adds the userID to the get user devices params -func (o *GetUserDevicesParams) WithUserID(userID string) *GetUserDevicesParams { - o.SetUserID(userID) - return o -} - -// SetUserID adds the userId to the get user devices params -func (o *GetUserDevicesParams) SetUserID(userID string) { - o.UserID = userID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetUserDevicesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - // path param accountId - if err := r.SetPathParam("accountId", o.AccountID); err != nil { - return err - } - - // path param userId - if err := r.SetPathParam("userId", o.UserID); err != nil { - return err - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/kazoo/kazoo_client/device/get_user_devices_responses.go b/api/kazoo/kazoo_client/device/get_user_devices_responses.go deleted file mode 100644 index 70dfb81..0000000 --- a/api/kazoo/kazoo_client/device/get_user_devices_responses.go +++ /dev/null @@ -1,147 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package device - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_models" -) - -// GetUserDevicesReader is a Reader for the GetUserDevices structure. -type GetUserDevicesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetUserDevicesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetUserDevicesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetUserDevicesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetUserDevicesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetUserDevicesOK creates a GetUserDevicesOK with default headers values -func NewGetUserDevicesOK() *GetUserDevicesOK { - return &GetUserDevicesOK{} -} - -/* GetUserDevicesOK describes a response with status code 200, with default header values. - -Kazoo response -*/ -type GetUserDevicesOK struct { - Payload *kazoo_models.GetDeviceResponse -} - -func (o *GetUserDevicesOK) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/users/{userId}/devices][%d] getUserDevicesOK %+v", 200, o.Payload) -} -func (o *GetUserDevicesOK) GetPayload() *kazoo_models.GetDeviceResponse { - return o.Payload -} - -func (o *GetUserDevicesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.GetDeviceResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetUserDevicesUnauthorized creates a GetUserDevicesUnauthorized with default headers values -func NewGetUserDevicesUnauthorized() *GetUserDevicesUnauthorized { - return &GetUserDevicesUnauthorized{} -} - -/* GetUserDevicesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetUserDevicesUnauthorized struct { - Payload *kazoo_models.Error -} - -func (o *GetUserDevicesUnauthorized) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/users/{userId}/devices][%d] getUserDevicesUnauthorized %+v", 401, o.Payload) -} -func (o *GetUserDevicesUnauthorized) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetUserDevicesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetUserDevicesNotFound creates a GetUserDevicesNotFound with default headers values -func NewGetUserDevicesNotFound() *GetUserDevicesNotFound { - return &GetUserDevicesNotFound{} -} - -/* GetUserDevicesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetUserDevicesNotFound struct { - Payload *kazoo_models.Error -} - -func (o *GetUserDevicesNotFound) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/users/{userId}/devices][%d] getUserDevicesNotFound %+v", 404, o.Payload) -} -func (o *GetUserDevicesNotFound) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetUserDevicesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/kazoo/kazoo_client/group/get_account_groups_parameters.go b/api/kazoo/kazoo_client/group/get_account_groups_parameters.go deleted file mode 100644 index f7024d8..0000000 --- a/api/kazoo/kazoo_client/group/get_account_groups_parameters.go +++ /dev/null @@ -1,150 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package group - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" -) - -// NewGetAccountGroupsParams creates a new GetAccountGroupsParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetAccountGroupsParams() *GetAccountGroupsParams { - return &GetAccountGroupsParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetAccountGroupsParamsWithTimeout creates a new GetAccountGroupsParams object -// with the ability to set a timeout on a request. -func NewGetAccountGroupsParamsWithTimeout(timeout time.Duration) *GetAccountGroupsParams { - return &GetAccountGroupsParams{ - timeout: timeout, - } -} - -// NewGetAccountGroupsParamsWithContext creates a new GetAccountGroupsParams object -// with the ability to set a context for a request. -func NewGetAccountGroupsParamsWithContext(ctx context.Context) *GetAccountGroupsParams { - return &GetAccountGroupsParams{ - Context: ctx, - } -} - -// NewGetAccountGroupsParamsWithHTTPClient creates a new GetAccountGroupsParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetAccountGroupsParamsWithHTTPClient(client *http.Client) *GetAccountGroupsParams { - return &GetAccountGroupsParams{ - HTTPClient: client, - } -} - -/* GetAccountGroupsParams contains all the parameters to send to the API endpoint - for the get account groups operation. - - Typically these are written to a http.Request. -*/ -type GetAccountGroupsParams struct { - - // AccountID. - AccountID string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get account groups params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountGroupsParams) WithDefaults() *GetAccountGroupsParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get account groups params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountGroupsParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the get account groups params -func (o *GetAccountGroupsParams) WithTimeout(timeout time.Duration) *GetAccountGroupsParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get account groups params -func (o *GetAccountGroupsParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get account groups params -func (o *GetAccountGroupsParams) WithContext(ctx context.Context) *GetAccountGroupsParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get account groups params -func (o *GetAccountGroupsParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get account groups params -func (o *GetAccountGroupsParams) WithHTTPClient(client *http.Client) *GetAccountGroupsParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get account groups params -func (o *GetAccountGroupsParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAccountID adds the accountID to the get account groups params -func (o *GetAccountGroupsParams) WithAccountID(accountID string) *GetAccountGroupsParams { - o.SetAccountID(accountID) - return o -} - -// SetAccountID adds the accountId to the get account groups params -func (o *GetAccountGroupsParams) SetAccountID(accountID string) { - o.AccountID = accountID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetAccountGroupsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - // path param accountId - if err := r.SetPathParam("accountId", o.AccountID); err != nil { - return err - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/kazoo/kazoo_client/group/get_account_groups_responses.go b/api/kazoo/kazoo_client/group/get_account_groups_responses.go deleted file mode 100644 index 9c2daa2..0000000 --- a/api/kazoo/kazoo_client/group/get_account_groups_responses.go +++ /dev/null @@ -1,147 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package group - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_models" -) - -// GetAccountGroupsReader is a Reader for the GetAccountGroups structure. -type GetAccountGroupsReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetAccountGroupsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetAccountGroupsOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetAccountGroupsUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetAccountGroupsNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetAccountGroupsOK creates a GetAccountGroupsOK with default headers values -func NewGetAccountGroupsOK() *GetAccountGroupsOK { - return &GetAccountGroupsOK{} -} - -/* GetAccountGroupsOK describes a response with status code 200, with default header values. - -Kazoo response -*/ -type GetAccountGroupsOK struct { - Payload *kazoo_models.GetAccountGroupResponse -} - -func (o *GetAccountGroupsOK) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/groups][%d] getAccountGroupsOK %+v", 200, o.Payload) -} -func (o *GetAccountGroupsOK) GetPayload() *kazoo_models.GetAccountGroupResponse { - return o.Payload -} - -func (o *GetAccountGroupsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.GetAccountGroupResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountGroupsUnauthorized creates a GetAccountGroupsUnauthorized with default headers values -func NewGetAccountGroupsUnauthorized() *GetAccountGroupsUnauthorized { - return &GetAccountGroupsUnauthorized{} -} - -/* GetAccountGroupsUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetAccountGroupsUnauthorized struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountGroupsUnauthorized) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/groups][%d] getAccountGroupsUnauthorized %+v", 401, o.Payload) -} -func (o *GetAccountGroupsUnauthorized) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountGroupsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountGroupsNotFound creates a GetAccountGroupsNotFound with default headers values -func NewGetAccountGroupsNotFound() *GetAccountGroupsNotFound { - return &GetAccountGroupsNotFound{} -} - -/* GetAccountGroupsNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetAccountGroupsNotFound struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountGroupsNotFound) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/groups][%d] getAccountGroupsNotFound %+v", 404, o.Payload) -} -func (o *GetAccountGroupsNotFound) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountGroupsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/kazoo/kazoo_client/group/group_client.go b/api/kazoo/kazoo_client/group/group_client.go deleted file mode 100644 index 0cb59f1..0000000 --- a/api/kazoo/kazoo_client/group/group_client.go +++ /dev/null @@ -1,84 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package group - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" -) - -// New creates a new group API client. -func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { - return &Client{transport: transport, formats: formats} -} - -/* -Client for group API -*/ -type Client struct { - transport runtime.ClientTransport - formats strfmt.Registry -} - -// ClientOption is the option for Client methods -type ClientOption func(*runtime.ClientOperation) - -// ClientService is the interface for Client methods -type ClientService interface { - GetAccountGroups(params *GetAccountGroupsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountGroupsOK, error) - - SetTransport(transport runtime.ClientTransport) -} - -/* - GetAccountGroups get account groups API -*/ -func (a *Client) GetAccountGroups(params *GetAccountGroupsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountGroupsOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewGetAccountGroupsParams() - } - op := &runtime.ClientOperation{ - ID: "getAccountGroups", - Method: "GET", - PathPattern: "/accounts/{accountId}/groups", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"https"}, - Params: params, - Reader: &GetAccountGroupsReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*GetAccountGroupsOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getAccountGroups: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -// SetTransport changes the transport on the client -func (a *Client) SetTransport(transport runtime.ClientTransport) { - a.transport = transport -} diff --git a/api/kazoo/kazoo_client/kazoo_client.go b/api/kazoo/kazoo_client/kazoo_client.go deleted file mode 100644 index 92e4879..0000000 --- a/api/kazoo/kazoo_client/kazoo_client.go +++ /dev/null @@ -1,161 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package kazoo_client - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "github.com/go-openapi/runtime" - httptransport "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_client/account" - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_client/call_flow" - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_client/cdr" - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_client/device" - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_client/group" - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_client/media" - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_client/menu" - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_client/phone_number" - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_client/time_rule" - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_client/user" -) - -// Default kazoo HTTP client. -var Default = NewHTTPClient(nil) - -const ( - // DefaultHost is the default Host - // found in Meta (info) section of spec file - DefaultHost string = "api.zswitch.net:8443" - // DefaultBasePath is the default BasePath - // found in Meta (info) section of spec file - DefaultBasePath string = "/v2" -) - -// DefaultSchemes are the default schemes found in Meta (info) section of spec file -var DefaultSchemes = []string{"https"} - -// NewHTTPClient creates a new kazoo HTTP client. -func NewHTTPClient(formats strfmt.Registry) *Kazoo { - return NewHTTPClientWithConfig(formats, nil) -} - -// NewHTTPClientWithConfig creates a new kazoo HTTP client, -// using a customizable transport config. -func NewHTTPClientWithConfig(formats strfmt.Registry, cfg *TransportConfig) *Kazoo { - // ensure nullable parameters have default - if cfg == nil { - cfg = DefaultTransportConfig() - } - - // create transport and client - transport := httptransport.New(cfg.Host, cfg.BasePath, cfg.Schemes) - return New(transport, formats) -} - -// New creates a new kazoo client -func New(transport runtime.ClientTransport, formats strfmt.Registry) *Kazoo { - // ensure nullable parameters have default - if formats == nil { - formats = strfmt.Default - } - - cli := new(Kazoo) - cli.Transport = transport - cli.Account = account.New(transport, formats) - cli.CallFlow = call_flow.New(transport, formats) - cli.Cdr = cdr.New(transport, formats) - cli.Device = device.New(transport, formats) - cli.Group = group.New(transport, formats) - cli.Media = media.New(transport, formats) - cli.Menu = menu.New(transport, formats) - cli.PhoneNumber = phone_number.New(transport, formats) - cli.TimeRule = time_rule.New(transport, formats) - cli.User = user.New(transport, formats) - return cli -} - -// DefaultTransportConfig creates a TransportConfig with the -// default settings taken from the meta section of the spec file. -func DefaultTransportConfig() *TransportConfig { - return &TransportConfig{ - Host: DefaultHost, - BasePath: DefaultBasePath, - Schemes: DefaultSchemes, - } -} - -// TransportConfig contains the transport related info, -// found in the meta section of the spec file. -type TransportConfig struct { - Host string - BasePath string - Schemes []string -} - -// WithHost overrides the default host, -// provided by the meta section of the spec file. -func (cfg *TransportConfig) WithHost(host string) *TransportConfig { - cfg.Host = host - return cfg -} - -// WithBasePath overrides the default basePath, -// provided by the meta section of the spec file. -func (cfg *TransportConfig) WithBasePath(basePath string) *TransportConfig { - cfg.BasePath = basePath - return cfg -} - -// WithSchemes overrides the default schemes, -// provided by the meta section of the spec file. -func (cfg *TransportConfig) WithSchemes(schemes []string) *TransportConfig { - cfg.Schemes = schemes - return cfg -} - -// Kazoo is a client for kazoo -type Kazoo struct { - Account account.ClientService - - CallFlow call_flow.ClientService - - Cdr cdr.ClientService - - Device device.ClientService - - Group group.ClientService - - Media media.ClientService - - Menu menu.ClientService - - PhoneNumber phone_number.ClientService - - TimeRule time_rule.ClientService - - User user.ClientService - - Transport runtime.ClientTransport -} - -// SetTransport changes the transport on the client and all its subresources -func (c *Kazoo) SetTransport(transport runtime.ClientTransport) { - c.Transport = transport - c.Account.SetTransport(transport) - c.CallFlow.SetTransport(transport) - c.Cdr.SetTransport(transport) - c.Device.SetTransport(transport) - c.Group.SetTransport(transport) - c.Media.SetTransport(transport) - c.Menu.SetTransport(transport) - c.PhoneNumber.SetTransport(transport) - c.TimeRule.SetTransport(transport) - c.User.SetTransport(transport) -} diff --git a/api/kazoo/kazoo_client/media/get_account_media_parameters.go b/api/kazoo/kazoo_client/media/get_account_media_parameters.go deleted file mode 100644 index e49da17..0000000 --- a/api/kazoo/kazoo_client/media/get_account_media_parameters.go +++ /dev/null @@ -1,150 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package media - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" -) - -// NewGetAccountMediaParams creates a new GetAccountMediaParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetAccountMediaParams() *GetAccountMediaParams { - return &GetAccountMediaParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetAccountMediaParamsWithTimeout creates a new GetAccountMediaParams object -// with the ability to set a timeout on a request. -func NewGetAccountMediaParamsWithTimeout(timeout time.Duration) *GetAccountMediaParams { - return &GetAccountMediaParams{ - timeout: timeout, - } -} - -// NewGetAccountMediaParamsWithContext creates a new GetAccountMediaParams object -// with the ability to set a context for a request. -func NewGetAccountMediaParamsWithContext(ctx context.Context) *GetAccountMediaParams { - return &GetAccountMediaParams{ - Context: ctx, - } -} - -// NewGetAccountMediaParamsWithHTTPClient creates a new GetAccountMediaParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetAccountMediaParamsWithHTTPClient(client *http.Client) *GetAccountMediaParams { - return &GetAccountMediaParams{ - HTTPClient: client, - } -} - -/* GetAccountMediaParams contains all the parameters to send to the API endpoint - for the get account media operation. - - Typically these are written to a http.Request. -*/ -type GetAccountMediaParams struct { - - // AccountID. - AccountID string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get account media params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountMediaParams) WithDefaults() *GetAccountMediaParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get account media params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountMediaParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the get account media params -func (o *GetAccountMediaParams) WithTimeout(timeout time.Duration) *GetAccountMediaParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get account media params -func (o *GetAccountMediaParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get account media params -func (o *GetAccountMediaParams) WithContext(ctx context.Context) *GetAccountMediaParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get account media params -func (o *GetAccountMediaParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get account media params -func (o *GetAccountMediaParams) WithHTTPClient(client *http.Client) *GetAccountMediaParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get account media params -func (o *GetAccountMediaParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAccountID adds the accountID to the get account media params -func (o *GetAccountMediaParams) WithAccountID(accountID string) *GetAccountMediaParams { - o.SetAccountID(accountID) - return o -} - -// SetAccountID adds the accountId to the get account media params -func (o *GetAccountMediaParams) SetAccountID(accountID string) { - o.AccountID = accountID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetAccountMediaParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - // path param accountId - if err := r.SetPathParam("accountId", o.AccountID); err != nil { - return err - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/kazoo/kazoo_client/media/get_account_media_responses.go b/api/kazoo/kazoo_client/media/get_account_media_responses.go deleted file mode 100644 index eb6eca0..0000000 --- a/api/kazoo/kazoo_client/media/get_account_media_responses.go +++ /dev/null @@ -1,147 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package media - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_models" -) - -// GetAccountMediaReader is a Reader for the GetAccountMedia structure. -type GetAccountMediaReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetAccountMediaReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetAccountMediaOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetAccountMediaUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetAccountMediaNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetAccountMediaOK creates a GetAccountMediaOK with default headers values -func NewGetAccountMediaOK() *GetAccountMediaOK { - return &GetAccountMediaOK{} -} - -/* GetAccountMediaOK describes a response with status code 200, with default header values. - -Kazoo response -*/ -type GetAccountMediaOK struct { - Payload *kazoo_models.GetAccountMediaResponse -} - -func (o *GetAccountMediaOK) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/media][%d] getAccountMediaOK %+v", 200, o.Payload) -} -func (o *GetAccountMediaOK) GetPayload() *kazoo_models.GetAccountMediaResponse { - return o.Payload -} - -func (o *GetAccountMediaOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.GetAccountMediaResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountMediaUnauthorized creates a GetAccountMediaUnauthorized with default headers values -func NewGetAccountMediaUnauthorized() *GetAccountMediaUnauthorized { - return &GetAccountMediaUnauthorized{} -} - -/* GetAccountMediaUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetAccountMediaUnauthorized struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountMediaUnauthorized) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/media][%d] getAccountMediaUnauthorized %+v", 401, o.Payload) -} -func (o *GetAccountMediaUnauthorized) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountMediaUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountMediaNotFound creates a GetAccountMediaNotFound with default headers values -func NewGetAccountMediaNotFound() *GetAccountMediaNotFound { - return &GetAccountMediaNotFound{} -} - -/* GetAccountMediaNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetAccountMediaNotFound struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountMediaNotFound) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/media][%d] getAccountMediaNotFound %+v", 404, o.Payload) -} -func (o *GetAccountMediaNotFound) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountMediaNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/kazoo/kazoo_client/media/media_client.go b/api/kazoo/kazoo_client/media/media_client.go deleted file mode 100644 index 053d18e..0000000 --- a/api/kazoo/kazoo_client/media/media_client.go +++ /dev/null @@ -1,84 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package media - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" -) - -// New creates a new media API client. -func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { - return &Client{transport: transport, formats: formats} -} - -/* -Client for media API -*/ -type Client struct { - transport runtime.ClientTransport - formats strfmt.Registry -} - -// ClientOption is the option for Client methods -type ClientOption func(*runtime.ClientOperation) - -// ClientService is the interface for Client methods -type ClientService interface { - GetAccountMedia(params *GetAccountMediaParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountMediaOK, error) - - SetTransport(transport runtime.ClientTransport) -} - -/* - GetAccountMedia get account media API -*/ -func (a *Client) GetAccountMedia(params *GetAccountMediaParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountMediaOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewGetAccountMediaParams() - } - op := &runtime.ClientOperation{ - ID: "getAccountMedia", - Method: "GET", - PathPattern: "/accounts/{accountId}/media", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"https"}, - Params: params, - Reader: &GetAccountMediaReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*GetAccountMediaOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getAccountMedia: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -// SetTransport changes the transport on the client -func (a *Client) SetTransport(transport runtime.ClientTransport) { - a.transport = transport -} diff --git a/api/kazoo/kazoo_client/menu/get_account_menus_parameters.go b/api/kazoo/kazoo_client/menu/get_account_menus_parameters.go deleted file mode 100644 index 59cdfaa..0000000 --- a/api/kazoo/kazoo_client/menu/get_account_menus_parameters.go +++ /dev/null @@ -1,150 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package menu - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" -) - -// NewGetAccountMenusParams creates a new GetAccountMenusParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetAccountMenusParams() *GetAccountMenusParams { - return &GetAccountMenusParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetAccountMenusParamsWithTimeout creates a new GetAccountMenusParams object -// with the ability to set a timeout on a request. -func NewGetAccountMenusParamsWithTimeout(timeout time.Duration) *GetAccountMenusParams { - return &GetAccountMenusParams{ - timeout: timeout, - } -} - -// NewGetAccountMenusParamsWithContext creates a new GetAccountMenusParams object -// with the ability to set a context for a request. -func NewGetAccountMenusParamsWithContext(ctx context.Context) *GetAccountMenusParams { - return &GetAccountMenusParams{ - Context: ctx, - } -} - -// NewGetAccountMenusParamsWithHTTPClient creates a new GetAccountMenusParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetAccountMenusParamsWithHTTPClient(client *http.Client) *GetAccountMenusParams { - return &GetAccountMenusParams{ - HTTPClient: client, - } -} - -/* GetAccountMenusParams contains all the parameters to send to the API endpoint - for the get account menus operation. - - Typically these are written to a http.Request. -*/ -type GetAccountMenusParams struct { - - // AccountID. - AccountID string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get account menus params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountMenusParams) WithDefaults() *GetAccountMenusParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get account menus params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountMenusParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the get account menus params -func (o *GetAccountMenusParams) WithTimeout(timeout time.Duration) *GetAccountMenusParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get account menus params -func (o *GetAccountMenusParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get account menus params -func (o *GetAccountMenusParams) WithContext(ctx context.Context) *GetAccountMenusParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get account menus params -func (o *GetAccountMenusParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get account menus params -func (o *GetAccountMenusParams) WithHTTPClient(client *http.Client) *GetAccountMenusParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get account menus params -func (o *GetAccountMenusParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAccountID adds the accountID to the get account menus params -func (o *GetAccountMenusParams) WithAccountID(accountID string) *GetAccountMenusParams { - o.SetAccountID(accountID) - return o -} - -// SetAccountID adds the accountId to the get account menus params -func (o *GetAccountMenusParams) SetAccountID(accountID string) { - o.AccountID = accountID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetAccountMenusParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - // path param accountId - if err := r.SetPathParam("accountId", o.AccountID); err != nil { - return err - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/kazoo/kazoo_client/menu/get_account_menus_responses.go b/api/kazoo/kazoo_client/menu/get_account_menus_responses.go deleted file mode 100644 index 314b3c1..0000000 --- a/api/kazoo/kazoo_client/menu/get_account_menus_responses.go +++ /dev/null @@ -1,147 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package menu - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_models" -) - -// GetAccountMenusReader is a Reader for the GetAccountMenus structure. -type GetAccountMenusReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetAccountMenusReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetAccountMenusOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetAccountMenusUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetAccountMenusNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetAccountMenusOK creates a GetAccountMenusOK with default headers values -func NewGetAccountMenusOK() *GetAccountMenusOK { - return &GetAccountMenusOK{} -} - -/* GetAccountMenusOK describes a response with status code 200, with default header values. - -Kazoo response -*/ -type GetAccountMenusOK struct { - Payload *kazoo_models.GetAccountMenusResponse -} - -func (o *GetAccountMenusOK) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/menus][%d] getAccountMenusOK %+v", 200, o.Payload) -} -func (o *GetAccountMenusOK) GetPayload() *kazoo_models.GetAccountMenusResponse { - return o.Payload -} - -func (o *GetAccountMenusOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.GetAccountMenusResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountMenusUnauthorized creates a GetAccountMenusUnauthorized with default headers values -func NewGetAccountMenusUnauthorized() *GetAccountMenusUnauthorized { - return &GetAccountMenusUnauthorized{} -} - -/* GetAccountMenusUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetAccountMenusUnauthorized struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountMenusUnauthorized) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/menus][%d] getAccountMenusUnauthorized %+v", 401, o.Payload) -} -func (o *GetAccountMenusUnauthorized) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountMenusUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountMenusNotFound creates a GetAccountMenusNotFound with default headers values -func NewGetAccountMenusNotFound() *GetAccountMenusNotFound { - return &GetAccountMenusNotFound{} -} - -/* GetAccountMenusNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetAccountMenusNotFound struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountMenusNotFound) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/menus][%d] getAccountMenusNotFound %+v", 404, o.Payload) -} -func (o *GetAccountMenusNotFound) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountMenusNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/kazoo/kazoo_client/phone_number/get_account_numbers_parameters.go b/api/kazoo/kazoo_client/phone_number/get_account_numbers_parameters.go deleted file mode 100644 index 02e2f2c..0000000 --- a/api/kazoo/kazoo_client/phone_number/get_account_numbers_parameters.go +++ /dev/null @@ -1,150 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package phone_number - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" -) - -// NewGetAccountNumbersParams creates a new GetAccountNumbersParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetAccountNumbersParams() *GetAccountNumbersParams { - return &GetAccountNumbersParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetAccountNumbersParamsWithTimeout creates a new GetAccountNumbersParams object -// with the ability to set a timeout on a request. -func NewGetAccountNumbersParamsWithTimeout(timeout time.Duration) *GetAccountNumbersParams { - return &GetAccountNumbersParams{ - timeout: timeout, - } -} - -// NewGetAccountNumbersParamsWithContext creates a new GetAccountNumbersParams object -// with the ability to set a context for a request. -func NewGetAccountNumbersParamsWithContext(ctx context.Context) *GetAccountNumbersParams { - return &GetAccountNumbersParams{ - Context: ctx, - } -} - -// NewGetAccountNumbersParamsWithHTTPClient creates a new GetAccountNumbersParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetAccountNumbersParamsWithHTTPClient(client *http.Client) *GetAccountNumbersParams { - return &GetAccountNumbersParams{ - HTTPClient: client, - } -} - -/* GetAccountNumbersParams contains all the parameters to send to the API endpoint - for the get account numbers operation. - - Typically these are written to a http.Request. -*/ -type GetAccountNumbersParams struct { - - // AccountID. - AccountID string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get account numbers params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountNumbersParams) WithDefaults() *GetAccountNumbersParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get account numbers params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountNumbersParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the get account numbers params -func (o *GetAccountNumbersParams) WithTimeout(timeout time.Duration) *GetAccountNumbersParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get account numbers params -func (o *GetAccountNumbersParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get account numbers params -func (o *GetAccountNumbersParams) WithContext(ctx context.Context) *GetAccountNumbersParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get account numbers params -func (o *GetAccountNumbersParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get account numbers params -func (o *GetAccountNumbersParams) WithHTTPClient(client *http.Client) *GetAccountNumbersParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get account numbers params -func (o *GetAccountNumbersParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAccountID adds the accountID to the get account numbers params -func (o *GetAccountNumbersParams) WithAccountID(accountID string) *GetAccountNumbersParams { - o.SetAccountID(accountID) - return o -} - -// SetAccountID adds the accountId to the get account numbers params -func (o *GetAccountNumbersParams) SetAccountID(accountID string) { - o.AccountID = accountID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetAccountNumbersParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - // path param accountId - if err := r.SetPathParam("accountId", o.AccountID); err != nil { - return err - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/kazoo/kazoo_client/phone_number/get_account_numbers_responses.go b/api/kazoo/kazoo_client/phone_number/get_account_numbers_responses.go deleted file mode 100644 index 0be903d..0000000 --- a/api/kazoo/kazoo_client/phone_number/get_account_numbers_responses.go +++ /dev/null @@ -1,147 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package phone_number - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_models" -) - -// GetAccountNumbersReader is a Reader for the GetAccountNumbers structure. -type GetAccountNumbersReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetAccountNumbersReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetAccountNumbersOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetAccountNumbersUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetAccountNumbersNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetAccountNumbersOK creates a GetAccountNumbersOK with default headers values -func NewGetAccountNumbersOK() *GetAccountNumbersOK { - return &GetAccountNumbersOK{} -} - -/* GetAccountNumbersOK describes a response with status code 200, with default header values. - -Kazoo response -*/ -type GetAccountNumbersOK struct { - Payload *kazoo_models.GetNumberResponse -} - -func (o *GetAccountNumbersOK) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/phone_numebers][%d] getAccountNumbersOK %+v", 200, o.Payload) -} -func (o *GetAccountNumbersOK) GetPayload() *kazoo_models.GetNumberResponse { - return o.Payload -} - -func (o *GetAccountNumbersOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.GetNumberResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountNumbersUnauthorized creates a GetAccountNumbersUnauthorized with default headers values -func NewGetAccountNumbersUnauthorized() *GetAccountNumbersUnauthorized { - return &GetAccountNumbersUnauthorized{} -} - -/* GetAccountNumbersUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetAccountNumbersUnauthorized struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountNumbersUnauthorized) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/phone_numebers][%d] getAccountNumbersUnauthorized %+v", 401, o.Payload) -} -func (o *GetAccountNumbersUnauthorized) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountNumbersUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountNumbersNotFound creates a GetAccountNumbersNotFound with default headers values -func NewGetAccountNumbersNotFound() *GetAccountNumbersNotFound { - return &GetAccountNumbersNotFound{} -} - -/* GetAccountNumbersNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetAccountNumbersNotFound struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountNumbersNotFound) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/phone_numebers][%d] getAccountNumbersNotFound %+v", 404, o.Payload) -} -func (o *GetAccountNumbersNotFound) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountNumbersNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/kazoo/kazoo_client/phone_number/get_kazoo_numbers_parameters.go b/api/kazoo/kazoo_client/phone_number/get_kazoo_numbers_parameters.go deleted file mode 100644 index 086f0c3..0000000 --- a/api/kazoo/kazoo_client/phone_number/get_kazoo_numbers_parameters.go +++ /dev/null @@ -1,198 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package phone_number - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// NewGetKazooNumbersParams creates a new GetKazooNumbersParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetKazooNumbersParams() *GetKazooNumbersParams { - return &GetKazooNumbersParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetKazooNumbersParamsWithTimeout creates a new GetKazooNumbersParams object -// with the ability to set a timeout on a request. -func NewGetKazooNumbersParamsWithTimeout(timeout time.Duration) *GetKazooNumbersParams { - return &GetKazooNumbersParams{ - timeout: timeout, - } -} - -// NewGetKazooNumbersParamsWithContext creates a new GetKazooNumbersParams object -// with the ability to set a context for a request. -func NewGetKazooNumbersParamsWithContext(ctx context.Context) *GetKazooNumbersParams { - return &GetKazooNumbersParams{ - Context: ctx, - } -} - -// NewGetKazooNumbersParamsWithHTTPClient creates a new GetKazooNumbersParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetKazooNumbersParamsWithHTTPClient(client *http.Client) *GetKazooNumbersParams { - return &GetKazooNumbersParams{ - HTTPClient: client, - } -} - -/* GetKazooNumbersParams contains all the parameters to send to the API endpoint - for the get kazoo numbers operation. - - Typically these are written to a http.Request. -*/ -type GetKazooNumbersParams struct { - - // Prefix. - // - // Format: int32 - Prefix *int32 - - // Quantity. - // - // Format: int32 - Quantity *int32 - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get kazoo numbers params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetKazooNumbersParams) WithDefaults() *GetKazooNumbersParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get kazoo numbers params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetKazooNumbersParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the get kazoo numbers params -func (o *GetKazooNumbersParams) WithTimeout(timeout time.Duration) *GetKazooNumbersParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get kazoo numbers params -func (o *GetKazooNumbersParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get kazoo numbers params -func (o *GetKazooNumbersParams) WithContext(ctx context.Context) *GetKazooNumbersParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get kazoo numbers params -func (o *GetKazooNumbersParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get kazoo numbers params -func (o *GetKazooNumbersParams) WithHTTPClient(client *http.Client) *GetKazooNumbersParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get kazoo numbers params -func (o *GetKazooNumbersParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithPrefix adds the prefix to the get kazoo numbers params -func (o *GetKazooNumbersParams) WithPrefix(prefix *int32) *GetKazooNumbersParams { - o.SetPrefix(prefix) - return o -} - -// SetPrefix adds the prefix to the get kazoo numbers params -func (o *GetKazooNumbersParams) SetPrefix(prefix *int32) { - o.Prefix = prefix -} - -// WithQuantity adds the quantity to the get kazoo numbers params -func (o *GetKazooNumbersParams) WithQuantity(quantity *int32) *GetKazooNumbersParams { - o.SetQuantity(quantity) - return o -} - -// SetQuantity adds the quantity to the get kazoo numbers params -func (o *GetKazooNumbersParams) SetQuantity(quantity *int32) { - o.Quantity = quantity -} - -// WriteToRequest writes these params to a swagger request -func (o *GetKazooNumbersParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - if o.Prefix != nil { - - // query param prefix - var qrPrefix int32 - - if o.Prefix != nil { - qrPrefix = *o.Prefix - } - qPrefix := swag.FormatInt32(qrPrefix) - if qPrefix != "" { - - if err := r.SetQueryParam("prefix", qPrefix); err != nil { - return err - } - } - } - - if o.Quantity != nil { - - // query param quantity - var qrQuantity int32 - - if o.Quantity != nil { - qrQuantity = *o.Quantity - } - qQuantity := swag.FormatInt32(qrQuantity) - if qQuantity != "" { - - if err := r.SetQueryParam("quantity", qQuantity); err != nil { - return err - } - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/kazoo/kazoo_client/phone_number/get_kazoo_numbers_responses.go b/api/kazoo/kazoo_client/phone_number/get_kazoo_numbers_responses.go deleted file mode 100644 index d4af6c8..0000000 --- a/api/kazoo/kazoo_client/phone_number/get_kazoo_numbers_responses.go +++ /dev/null @@ -1,147 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package phone_number - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_models" -) - -// GetKazooNumbersReader is a Reader for the GetKazooNumbers structure. -type GetKazooNumbersReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetKazooNumbersReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetKazooNumbersOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetKazooNumbersUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetKazooNumbersNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetKazooNumbersOK creates a GetKazooNumbersOK with default headers values -func NewGetKazooNumbersOK() *GetKazooNumbersOK { - return &GetKazooNumbersOK{} -} - -/* GetKazooNumbersOK describes a response with status code 200, with default header values. - -Kazoo response -*/ -type GetKazooNumbersOK struct { - Payload *kazoo_models.GetKazooNumberResponse -} - -func (o *GetKazooNumbersOK) Error() string { - return fmt.Sprintf("[GET /phone_numebers][%d] getKazooNumbersOK %+v", 200, o.Payload) -} -func (o *GetKazooNumbersOK) GetPayload() *kazoo_models.GetKazooNumberResponse { - return o.Payload -} - -func (o *GetKazooNumbersOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.GetKazooNumberResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetKazooNumbersUnauthorized creates a GetKazooNumbersUnauthorized with default headers values -func NewGetKazooNumbersUnauthorized() *GetKazooNumbersUnauthorized { - return &GetKazooNumbersUnauthorized{} -} - -/* GetKazooNumbersUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetKazooNumbersUnauthorized struct { - Payload *kazoo_models.Error -} - -func (o *GetKazooNumbersUnauthorized) Error() string { - return fmt.Sprintf("[GET /phone_numebers][%d] getKazooNumbersUnauthorized %+v", 401, o.Payload) -} -func (o *GetKazooNumbersUnauthorized) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetKazooNumbersUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetKazooNumbersNotFound creates a GetKazooNumbersNotFound with default headers values -func NewGetKazooNumbersNotFound() *GetKazooNumbersNotFound { - return &GetKazooNumbersNotFound{} -} - -/* GetKazooNumbersNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetKazooNumbersNotFound struct { - Payload *kazoo_models.Error -} - -func (o *GetKazooNumbersNotFound) Error() string { - return fmt.Sprintf("[GET /phone_numebers][%d] getKazooNumbersNotFound %+v", 404, o.Payload) -} -func (o *GetKazooNumbersNotFound) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetKazooNumbersNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/kazoo/kazoo_client/phone_number/phone_number_client.go b/api/kazoo/kazoo_client/phone_number/phone_number_client.go deleted file mode 100644 index 86b10d2..0000000 --- a/api/kazoo/kazoo_client/phone_number/phone_number_client.go +++ /dev/null @@ -1,125 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package phone_number - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" -) - -// New creates a new phone number API client. -func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { - return &Client{transport: transport, formats: formats} -} - -/* -Client for phone number API -*/ -type Client struct { - transport runtime.ClientTransport - formats strfmt.Registry -} - -// ClientOption is the option for Client methods -type ClientOption func(*runtime.ClientOperation) - -// ClientService is the interface for Client methods -type ClientService interface { - GetAccountNumbers(params *GetAccountNumbersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountNumbersOK, error) - - GetKazooNumbers(params *GetKazooNumbersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetKazooNumbersOK, error) - - SetTransport(transport runtime.ClientTransport) -} - -/* - GetAccountNumbers get account numbers API -*/ -func (a *Client) GetAccountNumbers(params *GetAccountNumbersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountNumbersOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewGetAccountNumbersParams() - } - op := &runtime.ClientOperation{ - ID: "getAccountNumbers", - Method: "GET", - PathPattern: "/accounts/{accountId}/phone_numebers", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"https"}, - Params: params, - Reader: &GetAccountNumbersReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*GetAccountNumbersOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getAccountNumbers: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -/* - GetKazooNumbers get kazoo numbers API -*/ -func (a *Client) GetKazooNumbers(params *GetKazooNumbersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetKazooNumbersOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewGetKazooNumbersParams() - } - op := &runtime.ClientOperation{ - ID: "getKazooNumbers", - Method: "GET", - PathPattern: "/phone_numebers", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"https"}, - Params: params, - Reader: &GetKazooNumbersReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*GetKazooNumbersOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getKazooNumbers: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -// SetTransport changes the transport on the client -func (a *Client) SetTransport(transport runtime.ClientTransport) { - a.transport = transport -} diff --git a/api/kazoo/kazoo_client/time_rule/get_account_time_rules_parameters.go b/api/kazoo/kazoo_client/time_rule/get_account_time_rules_parameters.go deleted file mode 100644 index dbb3f64..0000000 --- a/api/kazoo/kazoo_client/time_rule/get_account_time_rules_parameters.go +++ /dev/null @@ -1,150 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package time_rule - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" -) - -// NewGetAccountTimeRulesParams creates a new GetAccountTimeRulesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetAccountTimeRulesParams() *GetAccountTimeRulesParams { - return &GetAccountTimeRulesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetAccountTimeRulesParamsWithTimeout creates a new GetAccountTimeRulesParams object -// with the ability to set a timeout on a request. -func NewGetAccountTimeRulesParamsWithTimeout(timeout time.Duration) *GetAccountTimeRulesParams { - return &GetAccountTimeRulesParams{ - timeout: timeout, - } -} - -// NewGetAccountTimeRulesParamsWithContext creates a new GetAccountTimeRulesParams object -// with the ability to set a context for a request. -func NewGetAccountTimeRulesParamsWithContext(ctx context.Context) *GetAccountTimeRulesParams { - return &GetAccountTimeRulesParams{ - Context: ctx, - } -} - -// NewGetAccountTimeRulesParamsWithHTTPClient creates a new GetAccountTimeRulesParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetAccountTimeRulesParamsWithHTTPClient(client *http.Client) *GetAccountTimeRulesParams { - return &GetAccountTimeRulesParams{ - HTTPClient: client, - } -} - -/* GetAccountTimeRulesParams contains all the parameters to send to the API endpoint - for the get account time rules operation. - - Typically these are written to a http.Request. -*/ -type GetAccountTimeRulesParams struct { - - // AccountID. - AccountID string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get account time rules params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountTimeRulesParams) WithDefaults() *GetAccountTimeRulesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get account time rules params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountTimeRulesParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the get account time rules params -func (o *GetAccountTimeRulesParams) WithTimeout(timeout time.Duration) *GetAccountTimeRulesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get account time rules params -func (o *GetAccountTimeRulesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get account time rules params -func (o *GetAccountTimeRulesParams) WithContext(ctx context.Context) *GetAccountTimeRulesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get account time rules params -func (o *GetAccountTimeRulesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get account time rules params -func (o *GetAccountTimeRulesParams) WithHTTPClient(client *http.Client) *GetAccountTimeRulesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get account time rules params -func (o *GetAccountTimeRulesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAccountID adds the accountID to the get account time rules params -func (o *GetAccountTimeRulesParams) WithAccountID(accountID string) *GetAccountTimeRulesParams { - o.SetAccountID(accountID) - return o -} - -// SetAccountID adds the accountId to the get account time rules params -func (o *GetAccountTimeRulesParams) SetAccountID(accountID string) { - o.AccountID = accountID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetAccountTimeRulesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - // path param accountId - if err := r.SetPathParam("accountId", o.AccountID); err != nil { - return err - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/kazoo/kazoo_client/time_rule/get_account_time_rules_responses.go b/api/kazoo/kazoo_client/time_rule/get_account_time_rules_responses.go deleted file mode 100644 index d91d63f..0000000 --- a/api/kazoo/kazoo_client/time_rule/get_account_time_rules_responses.go +++ /dev/null @@ -1,147 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package time_rule - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_models" -) - -// GetAccountTimeRulesReader is a Reader for the GetAccountTimeRules structure. -type GetAccountTimeRulesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetAccountTimeRulesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetAccountTimeRulesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetAccountTimeRulesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetAccountTimeRulesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetAccountTimeRulesOK creates a GetAccountTimeRulesOK with default headers values -func NewGetAccountTimeRulesOK() *GetAccountTimeRulesOK { - return &GetAccountTimeRulesOK{} -} - -/* GetAccountTimeRulesOK describes a response with status code 200, with default header values. - -Kazoo response -*/ -type GetAccountTimeRulesOK struct { - Payload *kazoo_models.GetAccountTimeRuleResponse -} - -func (o *GetAccountTimeRulesOK) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/temporal_rules][%d] getAccountTimeRulesOK %+v", 200, o.Payload) -} -func (o *GetAccountTimeRulesOK) GetPayload() *kazoo_models.GetAccountTimeRuleResponse { - return o.Payload -} - -func (o *GetAccountTimeRulesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.GetAccountTimeRuleResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountTimeRulesUnauthorized creates a GetAccountTimeRulesUnauthorized with default headers values -func NewGetAccountTimeRulesUnauthorized() *GetAccountTimeRulesUnauthorized { - return &GetAccountTimeRulesUnauthorized{} -} - -/* GetAccountTimeRulesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetAccountTimeRulesUnauthorized struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountTimeRulesUnauthorized) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/temporal_rules][%d] getAccountTimeRulesUnauthorized %+v", 401, o.Payload) -} -func (o *GetAccountTimeRulesUnauthorized) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountTimeRulesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountTimeRulesNotFound creates a GetAccountTimeRulesNotFound with default headers values -func NewGetAccountTimeRulesNotFound() *GetAccountTimeRulesNotFound { - return &GetAccountTimeRulesNotFound{} -} - -/* GetAccountTimeRulesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetAccountTimeRulesNotFound struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountTimeRulesNotFound) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/temporal_rules][%d] getAccountTimeRulesNotFound %+v", 404, o.Payload) -} -func (o *GetAccountTimeRulesNotFound) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountTimeRulesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/kazoo/kazoo_client/user/get_account_users_parameters.go b/api/kazoo/kazoo_client/user/get_account_users_parameters.go deleted file mode 100644 index 50bada6..0000000 --- a/api/kazoo/kazoo_client/user/get_account_users_parameters.go +++ /dev/null @@ -1,150 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package user - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" -) - -// NewGetAccountUsersParams creates a new GetAccountUsersParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetAccountUsersParams() *GetAccountUsersParams { - return &GetAccountUsersParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetAccountUsersParamsWithTimeout creates a new GetAccountUsersParams object -// with the ability to set a timeout on a request. -func NewGetAccountUsersParamsWithTimeout(timeout time.Duration) *GetAccountUsersParams { - return &GetAccountUsersParams{ - timeout: timeout, - } -} - -// NewGetAccountUsersParamsWithContext creates a new GetAccountUsersParams object -// with the ability to set a context for a request. -func NewGetAccountUsersParamsWithContext(ctx context.Context) *GetAccountUsersParams { - return &GetAccountUsersParams{ - Context: ctx, - } -} - -// NewGetAccountUsersParamsWithHTTPClient creates a new GetAccountUsersParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetAccountUsersParamsWithHTTPClient(client *http.Client) *GetAccountUsersParams { - return &GetAccountUsersParams{ - HTTPClient: client, - } -} - -/* GetAccountUsersParams contains all the parameters to send to the API endpoint - for the get account users operation. - - Typically these are written to a http.Request. -*/ -type GetAccountUsersParams struct { - - // AccountID. - AccountID string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get account users params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountUsersParams) WithDefaults() *GetAccountUsersParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get account users params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountUsersParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the get account users params -func (o *GetAccountUsersParams) WithTimeout(timeout time.Duration) *GetAccountUsersParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get account users params -func (o *GetAccountUsersParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get account users params -func (o *GetAccountUsersParams) WithContext(ctx context.Context) *GetAccountUsersParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get account users params -func (o *GetAccountUsersParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get account users params -func (o *GetAccountUsersParams) WithHTTPClient(client *http.Client) *GetAccountUsersParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get account users params -func (o *GetAccountUsersParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAccountID adds the accountID to the get account users params -func (o *GetAccountUsersParams) WithAccountID(accountID string) *GetAccountUsersParams { - o.SetAccountID(accountID) - return o -} - -// SetAccountID adds the accountId to the get account users params -func (o *GetAccountUsersParams) SetAccountID(accountID string) { - o.AccountID = accountID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetAccountUsersParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - // path param accountId - if err := r.SetPathParam("accountId", o.AccountID); err != nil { - return err - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/kazoo/kazoo_client/user/get_account_users_responses.go b/api/kazoo/kazoo_client/user/get_account_users_responses.go deleted file mode 100644 index b93f9f4..0000000 --- a/api/kazoo/kazoo_client/user/get_account_users_responses.go +++ /dev/null @@ -1,147 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package user - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_models" -) - -// GetAccountUsersReader is a Reader for the GetAccountUsers structure. -type GetAccountUsersReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetAccountUsersReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetAccountUsersOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetAccountUsersUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetAccountUsersNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetAccountUsersOK creates a GetAccountUsersOK with default headers values -func NewGetAccountUsersOK() *GetAccountUsersOK { - return &GetAccountUsersOK{} -} - -/* GetAccountUsersOK describes a response with status code 200, with default header values. - -Kazoo response -*/ -type GetAccountUsersOK struct { - Payload *kazoo_models.GetAccountUserResponse -} - -func (o *GetAccountUsersOK) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/users][%d] getAccountUsersOK %+v", 200, o.Payload) -} -func (o *GetAccountUsersOK) GetPayload() *kazoo_models.GetAccountUserResponse { - return o.Payload -} - -func (o *GetAccountUsersOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.GetAccountUserResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountUsersUnauthorized creates a GetAccountUsersUnauthorized with default headers values -func NewGetAccountUsersUnauthorized() *GetAccountUsersUnauthorized { - return &GetAccountUsersUnauthorized{} -} - -/* GetAccountUsersUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetAccountUsersUnauthorized struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountUsersUnauthorized) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/users][%d] getAccountUsersUnauthorized %+v", 401, o.Payload) -} -func (o *GetAccountUsersUnauthorized) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountUsersUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountUsersNotFound creates a GetAccountUsersNotFound with default headers values -func NewGetAccountUsersNotFound() *GetAccountUsersNotFound { - return &GetAccountUsersNotFound{} -} - -/* GetAccountUsersNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetAccountUsersNotFound struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountUsersNotFound) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/users][%d] getAccountUsersNotFound %+v", 404, o.Payload) -} -func (o *GetAccountUsersNotFound) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountUsersNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/kazoo/kazoo_client/user/get_account_vm_boxes_parameters.go b/api/kazoo/kazoo_client/user/get_account_vm_boxes_parameters.go deleted file mode 100644 index 037b40e..0000000 --- a/api/kazoo/kazoo_client/user/get_account_vm_boxes_parameters.go +++ /dev/null @@ -1,150 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package user - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" -) - -// NewGetAccountVMBoxesParams creates a new GetAccountVMBoxesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetAccountVMBoxesParams() *GetAccountVMBoxesParams { - return &GetAccountVMBoxesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetAccountVMBoxesParamsWithTimeout creates a new GetAccountVMBoxesParams object -// with the ability to set a timeout on a request. -func NewGetAccountVMBoxesParamsWithTimeout(timeout time.Duration) *GetAccountVMBoxesParams { - return &GetAccountVMBoxesParams{ - timeout: timeout, - } -} - -// NewGetAccountVMBoxesParamsWithContext creates a new GetAccountVMBoxesParams object -// with the ability to set a context for a request. -func NewGetAccountVMBoxesParamsWithContext(ctx context.Context) *GetAccountVMBoxesParams { - return &GetAccountVMBoxesParams{ - Context: ctx, - } -} - -// NewGetAccountVMBoxesParamsWithHTTPClient creates a new GetAccountVMBoxesParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetAccountVMBoxesParamsWithHTTPClient(client *http.Client) *GetAccountVMBoxesParams { - return &GetAccountVMBoxesParams{ - HTTPClient: client, - } -} - -/* GetAccountVMBoxesParams contains all the parameters to send to the API endpoint - for the get account Vm boxes operation. - - Typically these are written to a http.Request. -*/ -type GetAccountVMBoxesParams struct { - - // AccountID. - AccountID string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get account Vm boxes params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountVMBoxesParams) WithDefaults() *GetAccountVMBoxesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get account Vm boxes params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAccountVMBoxesParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the get account Vm boxes params -func (o *GetAccountVMBoxesParams) WithTimeout(timeout time.Duration) *GetAccountVMBoxesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get account Vm boxes params -func (o *GetAccountVMBoxesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get account Vm boxes params -func (o *GetAccountVMBoxesParams) WithContext(ctx context.Context) *GetAccountVMBoxesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get account Vm boxes params -func (o *GetAccountVMBoxesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get account Vm boxes params -func (o *GetAccountVMBoxesParams) WithHTTPClient(client *http.Client) *GetAccountVMBoxesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get account Vm boxes params -func (o *GetAccountVMBoxesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAccountID adds the accountID to the get account Vm boxes params -func (o *GetAccountVMBoxesParams) WithAccountID(accountID string) *GetAccountVMBoxesParams { - o.SetAccountID(accountID) - return o -} - -// SetAccountID adds the accountId to the get account Vm boxes params -func (o *GetAccountVMBoxesParams) SetAccountID(accountID string) { - o.AccountID = accountID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetAccountVMBoxesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - // path param accountId - if err := r.SetPathParam("accountId", o.AccountID); err != nil { - return err - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/kazoo/kazoo_client/user/get_account_vm_boxes_responses.go b/api/kazoo/kazoo_client/user/get_account_vm_boxes_responses.go deleted file mode 100644 index 88232c3..0000000 --- a/api/kazoo/kazoo_client/user/get_account_vm_boxes_responses.go +++ /dev/null @@ -1,147 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package user - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/kazoo/kazoo_models" -) - -// GetAccountVMBoxesReader is a Reader for the GetAccountVMBoxes structure. -type GetAccountVMBoxesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetAccountVMBoxesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetAccountVMBoxesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetAccountVMBoxesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetAccountVMBoxesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetAccountVMBoxesOK creates a GetAccountVMBoxesOK with default headers values -func NewGetAccountVMBoxesOK() *GetAccountVMBoxesOK { - return &GetAccountVMBoxesOK{} -} - -/* GetAccountVMBoxesOK describes a response with status code 200, with default header values. - -Kazoo response -*/ -type GetAccountVMBoxesOK struct { - Payload *kazoo_models.GetAccountVMBoxResponse -} - -func (o *GetAccountVMBoxesOK) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/vmboxes][%d] getAccountVmBoxesOK %+v", 200, o.Payload) -} -func (o *GetAccountVMBoxesOK) GetPayload() *kazoo_models.GetAccountVMBoxResponse { - return o.Payload -} - -func (o *GetAccountVMBoxesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.GetAccountVMBoxResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountVMBoxesUnauthorized creates a GetAccountVMBoxesUnauthorized with default headers values -func NewGetAccountVMBoxesUnauthorized() *GetAccountVMBoxesUnauthorized { - return &GetAccountVMBoxesUnauthorized{} -} - -/* GetAccountVMBoxesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetAccountVMBoxesUnauthorized struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountVMBoxesUnauthorized) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/vmboxes][%d] getAccountVmBoxesUnauthorized %+v", 401, o.Payload) -} -func (o *GetAccountVMBoxesUnauthorized) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountVMBoxesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAccountVMBoxesNotFound creates a GetAccountVMBoxesNotFound with default headers values -func NewGetAccountVMBoxesNotFound() *GetAccountVMBoxesNotFound { - return &GetAccountVMBoxesNotFound{} -} - -/* GetAccountVMBoxesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetAccountVMBoxesNotFound struct { - Payload *kazoo_models.Error -} - -func (o *GetAccountVMBoxesNotFound) Error() string { - return fmt.Sprintf("[GET /accounts/{accountId}/vmboxes][%d] getAccountVmBoxesNotFound %+v", 404, o.Payload) -} -func (o *GetAccountVMBoxesNotFound) GetPayload() *kazoo_models.Error { - return o.Payload -} - -func (o *GetAccountVMBoxesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(kazoo_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/kazoo/kazoo_models/get_account_callflow_response.go b/api/kazoo/kazoo_models/get_account_callflow_response.go deleted file mode 100644 index e83425c..0000000 --- a/api/kazoo/kazoo_models/get_account_callflow_response.go +++ /dev/null @@ -1,296 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package kazoo_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// GetAccountCallflowResponse get account callflow response -// -// swagger:model GetAccountCallflowResponse -type GetAccountCallflowResponse struct { - - // auth token - // Example: eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6ImM2M2I1NjY5YmE0NTQzZWVmMTE5OTc3ZTUyNDYxYzRlIn0.eyJpc3MiOiJrYXpvbyIsImlkZW50aXR5X3NpZyI6InJUMW5DNnNOOHNKQWp4blBSSk1LVE5Ed1ZEQWZwek9sSFBnb0FYTHgtQU0iLCJhY2NvdW50X2lkIjoiYTY2ZjJiN2E0MDk0NGI3NDRkY2M2M2NhNmYxMGY0N2EiLCJvd25lcl9pZCI6IjUwOTE2MWZmMmE1NzZiZDZhYmU1YjhjNzVmNmIxNWYwIiwibWV0aG9kIjoiY2JfdXNlcl9hdXRoIiwiZXhwIjoxNTg4ODE0OTcwfQ.cW38X_JKe_bToQ19LzPY1U4aqjf96cFSwkszhqMhdpoR2Kq5JuPxkuCWoG6q49lwpIHb_9mZyoYBG83eLnYkamcORoejyUDb0ob79VKMBAUHAlXPkMNz7H2apLEHp0O8bdxr8ymh0Il9I4nAZSVnPkufQpx8L41Oy_ovU0vHS0jb2dSeXsySO0qcrCsoR9psTtqvB1GZBCEO8S_9EJKpYaT3o-Kio8uHZh7HgCD3NCUbfW8emfE6omTFIzIY7FTwXM_4kaMbWTUv09nN7iIpxJw2r_2drT-V5K8GFXZLAvm_1CqtLOMTYb26i3Iae3-zh9GPANSU3O0fq79kKupHfw - AuthToken string `json:"auth_token,omitempty"` - - // data - Data []*GetAccountCallflowResponseDataItems0 `json:"data"` - - // node - // Example: dqZFtHthbelyE8MI6vU-LA - Node string `json:"node,omitempty"` - - // page size - // Example: 34 - PageSize float64 `json:"page_size,omitempty"` - - // request id - // Example: 3aa5241a8f3150258750425ce3c5c767 - RequestID string `json:"request_id,omitempty"` - - // revision - // Example: c10c73dd4f798fb595267e1d1c4eb9ff - Revision string `json:"revision,omitempty"` - - // status - // Example: success - Status string `json:"status,omitempty"` - - // timestamp - // Example: 2020-05-07T00:53:40Z - Timestamp string `json:"timestamp,omitempty"` - - // version - // Example: 4.3.103 - Version string `json:"version,omitempty"` -} - -// Validate validates this get account callflow response -func (m *GetAccountCallflowResponse) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountCallflowResponse) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this get account callflow response based on the context it is used -func (m *GetAccountCallflowResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountCallflowResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountCallflowResponse) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountCallflowResponse) UnmarshalBinary(b []byte) error { - var res GetAccountCallflowResponse - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountCallflowResponseDataItems0 get account callflow response data items0 -// -// swagger:model GetAccountCallflowResponseDataItems0 -type GetAccountCallflowResponseDataItems0 struct { - - // featurecode - Featurecode *GetAccountCallflowResponseDataItems0Featurecode `json:"featurecode,omitempty"` - - // id - // Example: ff059d91a6fe0d16ced1ef6ca1f2bc52 - ID string `json:"id,omitempty"` - - // modules - // Example: ["park"] - Modules []string `json:"modules"` - - // name - // Example: 2004 - Vern iPad - Name string `json:"name,omitempty"` - - // numbers - // Example: ["2004"] - Numbers []string `json:"numbers"` - - // patterns - // Example: ["^\\*3([0-9]*)$"] - Patterns []string `json:"patterns"` -} - -// Validate validates this get account callflow response data items0 -func (m *GetAccountCallflowResponseDataItems0) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateFeaturecode(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountCallflowResponseDataItems0) validateFeaturecode(formats strfmt.Registry) error { - if swag.IsZero(m.Featurecode) { // not required - return nil - } - - if m.Featurecode != nil { - if err := m.Featurecode.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("featurecode") - } - return err - } - } - - return nil -} - -// ContextValidate validate this get account callflow response data items0 based on the context it is used -func (m *GetAccountCallflowResponseDataItems0) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateFeaturecode(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountCallflowResponseDataItems0) contextValidateFeaturecode(ctx context.Context, formats strfmt.Registry) error { - - if m.Featurecode != nil { - if err := m.Featurecode.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("featurecode") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountCallflowResponseDataItems0) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountCallflowResponseDataItems0) UnmarshalBinary(b []byte) error { - var res GetAccountCallflowResponseDataItems0 - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountCallflowResponseDataItems0Featurecode get account callflow response data items0 featurecode -// -// swagger:model GetAccountCallflowResponseDataItems0Featurecode -type GetAccountCallflowResponseDataItems0Featurecode struct { - - // name - // Example: park_and_retrieve - Name string `json:"name,omitempty"` - - // number - // Example: 3 - Number string `json:"number,omitempty"` -} - -// Validate validates this get account callflow response data items0 featurecode -func (m *GetAccountCallflowResponseDataItems0Featurecode) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account callflow response data items0 featurecode based on context it is used -func (m *GetAccountCallflowResponseDataItems0Featurecode) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountCallflowResponseDataItems0Featurecode) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountCallflowResponseDataItems0Featurecode) UnmarshalBinary(b []byte) error { - var res GetAccountCallflowResponseDataItems0Featurecode - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/kazoo/kazoo_models/get_account_cdr_response.go b/api/kazoo/kazoo_models/get_account_cdr_response.go deleted file mode 100644 index 9139816..0000000 --- a/api/kazoo/kazoo_models/get_account_cdr_response.go +++ /dev/null @@ -1,309 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package kazoo_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// GetAccountCdrResponse get account cdr response -// -// swagger:model GetAccountCdrResponse -type GetAccountCdrResponse struct { - - // auth token - AuthToken string `json:"auth_token,omitempty"` - - // data - Data []*GetAccountCdrResponseDataItems0 `json:"data"` - - // node - // Example: dqZFtHthbelyE8MI6vU-LA - Node string `json:"node,omitempty"` - - // page size - // Example: 534 - PageSize string `json:"page_size,omitempty"` - - // request id - // Example: e7897c563fb45f3b377046d9b54c3cb5 - RequestID string `json:"request_id,omitempty"` - - // start key - // Example: g2wAAAACbgUAAOqn1w5oAWpq - StartKey string `json:"start_key,omitempty"` - - // status - // Example: success - Status string `json:"status,omitempty"` - - // timestamp - // Example: 2020-05-07T01:06:49Z - Timestamp string `json:"timestamp,omitempty"` - - // version - // Example: 4.3.103 - Version string `json:"version,omitempty"` -} - -// Validate validates this get account cdr response -func (m *GetAccountCdrResponse) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountCdrResponse) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this get account cdr response based on the context it is used -func (m *GetAccountCdrResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountCdrResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountCdrResponse) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountCdrResponse) UnmarshalBinary(b []byte) error { - var res GetAccountCdrResponse - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountCdrResponseDataItems0 get account cdr response data items0 -// -// swagger:model GetAccountCdrResponseDataItems0 -type GetAccountCdrResponseDataItems0 struct { - - // authorizing id - // Example: f9627ff1bcca2d112931ee00dcfdb0c6 - AuthorizingID string `json:"authorizing_id,omitempty"` - - // billing seconds - // Example: 0 - BillingSeconds float64 `json:"billing_seconds,omitempty"` - - // bridge id - // Example: 1967142278_134071066@67.231.5.176 - BridgeID string `json:"bridge_id,omitempty"` - - // call id - // Example: 2b35a5ec-43a1-11ea-99b1-ed64c60fd1ac - CallID string `json:"call_id,omitempty"` - - // call priority - CallPriority string `json:"call_priority,omitempty"` - - // call type - CallType string `json:"call_type,omitempty"` - - // callee id name - // Example: Telnexus - CalleeIDName string `json:"callee_id_name,omitempty"` - - // callee id number - // Example: +15108597000 - CalleeIDNumber string `json:"callee_id_number,omitempty"` - - // caller id name - // Example: Unavailable - CallerIDName string `json:"caller_id_name,omitempty"` - - // caller id number - // Example: +17045943795 - CallerIDNumber string `json:"caller_id_number,omitempty"` - - // calling from - // Example: +17045943795 - CallingFrom string `json:"calling_from,omitempty"` - - // cost - // Example: 0 - Cost string `json:"cost,omitempty"` - - // datetime - // Example: 2020-01-30 20:43:28 - Datetime string `json:"datetime,omitempty"` - - // dialed number - // Example: user_jaemid - DialedNumber string `json:"dialed_number,omitempty"` - - // direction - // Example: outbound - Direction string `json:"direction,omitempty"` - - // duration seconds - // Example: 15 - DurationSeconds float64 `json:"duration_seconds,omitempty"` - - // from - // Example: +17045943795@e0f5f0.s.zswitch.net - From string `json:"from,omitempty"` - - // hangup cause - // Example: ORIGINATOR_CANCEL - HangupCause string `json:"hangup_cause,omitempty"` - - // id - // Example: 202001-2b35a5ec-43a1-11ea-99b1-ed64c60fd1ac - ID string `json:"id,omitempty"` - - // interaction id - // Example: 63747636207-cc274afb - InteractionID string `json:"interaction_id,omitempty"` - - // iso 8601 - // Example: 2020-01-30 - Iso8601 string `json:"iso_8601,omitempty"` - - // iso 8601 combined - // Example: 2020-01-30T20:43:28Z - Iso8601Combined string `json:"iso_8601_combined,omitempty"` - - // media server - // Example: fs004.ord.p.zswitch.net - MediaServer string `json:"media_server,omitempty"` - - // other leg call id - // Example: 1967142278_134071066@67.231.5.176 - OtherLegCallID string `json:"other_leg_call_id,omitempty"` - - // owner id - // Example: c0a881b0dfbc7fc574cb67dcaf10879f - OwnerID string `json:"owner_id,omitempty"` - - // rate - // Example: 0.0 - Rate string `json:"rate,omitempty"` - - // rate name - RateName string `json:"rate_name,omitempty"` - - // recording url - RecordingURL string `json:"recording_url,omitempty"` - - // request - // Example: user_jaemid@e0f5f0.s.zswitch.net - Request string `json:"request,omitempty"` - - // rfc 1036 - // Example: Thu, 30 Jan 2020 20:43:28 GMT - Rfc1036 string `json:"rfc_1036,omitempty"` - - // timestamp - // Example: 63747636208 - Timestamp string `json:"timestamp,omitempty"` - - // to - // Example: user_jaemid@e0f5f0.s.zswitch.net - To string `json:"to,omitempty"` - - // unix timestamp - // Example: 1580417008 - UnixTimestamp string `json:"unix_timestamp,omitempty"` -} - -// Validate validates this get account cdr response data items0 -func (m *GetAccountCdrResponseDataItems0) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account cdr response data items0 based on context it is used -func (m *GetAccountCdrResponseDataItems0) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountCdrResponseDataItems0) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountCdrResponseDataItems0) UnmarshalBinary(b []byte) error { - var res GetAccountCdrResponseDataItems0 - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/kazoo/kazoo_models/get_account_descendent_response.go b/api/kazoo/kazoo_models/get_account_descendent_response.go deleted file mode 100644 index 204228f..0000000 --- a/api/kazoo/kazoo_models/get_account_descendent_response.go +++ /dev/null @@ -1,202 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package kazoo_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// GetAccountDescendentResponse get account descendent response -// -// swagger:model GetAccountDescendentResponse -type GetAccountDescendentResponse struct { - - // auth token - // Example: eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6ImM2M2I1NjY5YmE0NTQzZWVmMTE5OTc3ZTUyNDYxYzRlIn0.eyJpc3MiOiJrYXpvbyIsImlkZW50aXR5X3NpZyI6InJUMW5DNnNOOHNKQWp4blBSSk1LVE5Ed1ZEQWZwek9sSFBnb0FYTHgtQU0iLCJhY2NvdW50X2lkIjoiYTY2ZjJiN2E0MDk0NGI3NDRkY2M2M2NhNmYxMGY0N2EiLCJvd25lcl9pZCI6IjUwOTE2MWZmMmE1NzZiZDZhYmU1YjhjNzVmNmIxNWYwIiwibWV0aG9kIjoiY2JfdXNlcl9hdXRoIiwiZXhwIjoxNTg4ODA3NjcyfQ.rsxUwAef3JnHzTc4eckxIx_RToGbNsKr3WVUoVDEPQ7slKLxhpfDTrNqXQ_kou-1646Z539YQCQGRsB5One4BfEDAfhAmH63d6jKwEU49yQUiZCBn8tbuzN4iiZmYn6z8wmqUQHO2KA3fo6IKrjggs3t1EK8iG05se4ltS21ZVQ-C0HVvvENoERu9iKEcM2SeKhl9Ucl3cqQpWRKBN9BEvTKpuXqM_Bkf2FiczQ3TJQ2SS0YJTYjoIKnOLHfM4H59ZcPwnTh0S3zplJ8e6dQv6t020x0gVYdA_U9EseIGhNQTtMEAztwleZJwdpBh6kiDxJb9-l4ENX4kFtvxsH4QQ - AuthToken string `json:"auth_token,omitempty"` - - // data - Data []*GetAccountDescendentResponseDataItems0 `json:"data"` - - // node - // Example: dqZFtHthbelyE8MI6vU-LA - Node string `json:"node,omitempty"` - - // page size - // Example: 48 - PageSize float64 `json:"page_size,omitempty"` - - // request id - // Example: 0035dec0e0e4c486e3bcd4502cf6a95d - RequestID string `json:"request_id,omitempty"` - - // revision - // Example: b3a4cb72580c7c2f93572a6ef2748b74 - Revision string `json:"revision,omitempty"` - - // start key - // Example: g20AAAAA - StartKey string `json:"start_key,omitempty"` - - // status - // Example: success - Status string `json:"status,omitempty"` - - // timestamp - // Example: 2020-05-06T23:01:48Z - Timestamp string `json:"timestamp,omitempty"` - - // version - // Example: 4.3.103 - Version string `json:"version,omitempty"` -} - -// Validate validates this get account descendent response -func (m *GetAccountDescendentResponse) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountDescendentResponse) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this get account descendent response based on the context it is used -func (m *GetAccountDescendentResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountDescendentResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountDescendentResponse) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountDescendentResponse) UnmarshalBinary(b []byte) error { - var res GetAccountDescendentResponse - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountDescendentResponseDataItems0 get account descendent response data items0 -// -// swagger:model GetAccountDescendentResponseDataItems0 -type GetAccountDescendentResponseDataItems0 struct { - - // id - // Example: 7cebd991bd99ffd909dbb08a7d8e2db4 - ID string `json:"id,omitempty"` - - // name - // Example: Affinity - Name string `json:"name,omitempty"` - - // realm - // Example: b5df22.s.zswitch.net - Realm string `json:"realm,omitempty"` - - // tree - // Example: ["fb7cc960d5037466992af0e9504d0b27","d4804caa6d7a78c83ff2bc7fdf646398","33776f3f94eb642c81e199cf5f1059ae","a66f2b7a40944b744dcc63ca6f10f47a"] - Tree []string `json:"tree"` -} - -// Validate validates this get account descendent response data items0 -func (m *GetAccountDescendentResponseDataItems0) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account descendent response data items0 based on context it is used -func (m *GetAccountDescendentResponseDataItems0) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountDescendentResponseDataItems0) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountDescendentResponseDataItems0) UnmarshalBinary(b []byte) error { - var res GetAccountDescendentResponseDataItems0 - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/kazoo/kazoo_models/get_account_group_response.go b/api/kazoo/kazoo_models/get_account_group_response.go deleted file mode 100644 index 5dcb581..0000000 --- a/api/kazoo/kazoo_models/get_account_group_response.go +++ /dev/null @@ -1,193 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package kazoo_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// GetAccountGroupResponse get account group response -// -// swagger:model GetAccountGroupResponse -type GetAccountGroupResponse struct { - - // auth token - AuthToken string `json:"auth_token,omitempty"` - - // data - Data []*GetAccountGroupResponseDataItems0 `json:"data"` - - // node - // Example: dqZFtHthbelyE8MI6vU-LA - Node string `json:"node,omitempty"` - - // page size - // Example: 3 - PageSize float64 `json:"page_size,omitempty"` - - // request id - // Example: 22d1269690b8a553106e929bd8923a55 - RequestID string `json:"request_id,omitempty"` - - // revision - // Example: ac7c6fde786a11c16c4dd265eccb9aa5 - Revision string `json:"revision,omitempty"` - - // status - // Example: success - Status string `json:"status,omitempty"` - - // timestamp - // Example: 2020-05-07T01:36:50Z - Timestamp string `json:"timestamp,omitempty"` - - // version - // Example: 4.3.103 - Version string `json:"version,omitempty"` -} - -// Validate validates this get account group response -func (m *GetAccountGroupResponse) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountGroupResponse) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this get account group response based on the context it is used -func (m *GetAccountGroupResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountGroupResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountGroupResponse) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountGroupResponse) UnmarshalBinary(b []byte) error { - var res GetAccountGroupResponse - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountGroupResponseDataItems0 get account group response data items0 -// -// swagger:model GetAccountGroupResponseDataItems0 -type GetAccountGroupResponseDataItems0 struct { - - // endpoints - // Example: 5 - Endpoints float64 `json:"endpoints,omitempty"` - - // id - // Example: e9e0627a0d41c4be4e8fa65a6d4777aa - ID string `json:"id,omitempty"` - - // name - // Example: Berkeley Office - Name string `json:"name,omitempty"` -} - -// Validate validates this get account group response data items0 -func (m *GetAccountGroupResponseDataItems0) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account group response data items0 based on context it is used -func (m *GetAccountGroupResponseDataItems0) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountGroupResponseDataItems0) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountGroupResponseDataItems0) UnmarshalBinary(b []byte) error { - var res GetAccountGroupResponseDataItems0 - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/kazoo/kazoo_models/get_account_media_response.go b/api/kazoo/kazoo_models/get_account_media_response.go deleted file mode 100644 index 4d7f735..0000000 --- a/api/kazoo/kazoo_models/get_account_media_response.go +++ /dev/null @@ -1,201 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package kazoo_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// GetAccountMediaResponse get account media response -// -// swagger:model GetAccountMediaResponse -type GetAccountMediaResponse struct { - - // auth token - AuthToken string `json:"auth_token,omitempty"` - - // data - Data []*GetAccountMediaResponseDataItems0 `json:"data"` - - // node - // Example: dqZFtHthbelyE8MI6vU-LA - Node string `json:"node,omitempty"` - - // page size - // Example: 49 - PageSize float64 `json:"page_size,omitempty"` - - // request id - // Example: 6e6dc6f474d1aa1689ac27a3c0605b38 - RequestID string `json:"request_id,omitempty"` - - // revision - // Example: b74319c4b8fb8cdba510362fa98facf0 - Revision string `json:"revision,omitempty"` - - // status - // Example: success - Status string `json:"status,omitempty"` - - // timestamp - // Example: 2020-05-07T01:41:49Z - Timestamp string `json:"timestamp,omitempty"` - - // version - // Example: 4.3.103 - Version string `json:"version,omitempty"` -} - -// Validate validates this get account media response -func (m *GetAccountMediaResponse) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountMediaResponse) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this get account media response based on the context it is used -func (m *GetAccountMediaResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountMediaResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountMediaResponse) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountMediaResponse) UnmarshalBinary(b []byte) error { - var res GetAccountMediaResponse - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountMediaResponseDataItems0 get account media response data items0 -// -// swagger:model GetAccountMediaResponseDataItems0 -type GetAccountMediaResponseDataItems0 struct { - - // id - // Example: fea26d66047257e74c132092b149e533 - ID string `json:"id,omitempty"` - - // is prompt - // Example: false - IsPrompt bool `json:"is_prompt,omitempty"` - - // language - // Example: en-us - Language string `json:"language,omitempty"` - - // media source - // Example: tts - MediaSource string `json:"media_source,omitempty"` - - // name - // Example: test - Name string `json:"name,omitempty"` -} - -// Validate validates this get account media response data items0 -func (m *GetAccountMediaResponseDataItems0) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account media response data items0 based on context it is used -func (m *GetAccountMediaResponseDataItems0) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountMediaResponseDataItems0) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountMediaResponseDataItems0) UnmarshalBinary(b []byte) error { - var res GetAccountMediaResponseDataItems0 - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/kazoo/kazoo_models/get_account_menus_response.go b/api/kazoo/kazoo_models/get_account_menus_response.go deleted file mode 100644 index bf22987..0000000 --- a/api/kazoo/kazoo_models/get_account_menus_response.go +++ /dev/null @@ -1,189 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package kazoo_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// GetAccountMenusResponse get account menus response -// -// swagger:model GetAccountMenusResponse -type GetAccountMenusResponse struct { - - // auth token - AuthToken string `json:"auth_token,omitempty"` - - // data - Data []*GetAccountMenusResponseDataItems0 `json:"data"` - - // node - // Example: dqZFtHthbelyE8MI6vU-LA - Node string `json:"node,omitempty"` - - // page size - // Example: 18 - PageSize float64 `json:"page_size,omitempty"` - - // request id - // Example: 36c57100bce810968df34f77465e974a - RequestID string `json:"request_id,omitempty"` - - // revision - // Example: d512f1f2cff2684eec3825938f23275b - Revision string `json:"revision,omitempty"` - - // status - // Example: success - Status string `json:"status,omitempty"` - - // timestamp - // Example: 2020-05-07T01:53:07Z - Timestamp string `json:"timestamp,omitempty"` - - // version - // Example: 4.3.103 - Version string `json:"version,omitempty"` -} - -// Validate validates this get account menus response -func (m *GetAccountMenusResponse) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountMenusResponse) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this get account menus response based on the context it is used -func (m *GetAccountMenusResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountMenusResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountMenusResponse) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountMenusResponse) UnmarshalBinary(b []byte) error { - var res GetAccountMenusResponse - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountMenusResponseDataItems0 get account menus response data items0 -// -// swagger:model GetAccountMenusResponseDataItems0 -type GetAccountMenusResponseDataItems0 struct { - - // id - // Example: fe46dd5b556ce876ce693b2d49b6402d - ID string `json:"id,omitempty"` - - // name - // Example: RecordingStudio - Name string `json:"name,omitempty"` -} - -// Validate validates this get account menus response data items0 -func (m *GetAccountMenusResponseDataItems0) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account menus response data items0 based on context it is used -func (m *GetAccountMenusResponseDataItems0) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountMenusResponseDataItems0) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountMenusResponseDataItems0) UnmarshalBinary(b []byte) error { - var res GetAccountMenusResponseDataItems0 - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/kazoo/kazoo_models/get_account_response.go b/api/kazoo/kazoo_models/get_account_response.go deleted file mode 100644 index d932a38..0000000 --- a/api/kazoo/kazoo_models/get_account_response.go +++ /dev/null @@ -1,3070 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package kazoo_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// GetAccountResponse get account response -// -// swagger:model GetAccountResponse -type GetAccountResponse struct { - - // auth token - // Example: eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6ImM2M2I1NjY5YmE0NTQzZWVmMTE5OTc3ZTUyNDYxYzRlIn0.eyJpc3MiOiJrYXpvbyIsImlkZW50aXR5X3NpZyI6InJUMW5DNnNOOHNKQWp4blBSSk1LVE5Ed1ZEQWZwek9sSFBnb0FYTHgtQU0iLCJhY2NvdW50X2lkIjoiYTY2ZjJiN2E0MDk0NGI3NDRkY2M2M2NhNmYxMGY0N2EiLCJvd25lcl9pZCI6IjUwOTE2MWZmMmE1NzZiZDZhYmU1YjhjNzVmNmIxNWYwIiwibWV0aG9kIjoiY2JfdXNlcl9hdXRoIiwiZXhwIjoxNTg4ODA3NjcyfQ.rsxUwAef3JnHzTc4eckxIx_RToGbNsKr3WVUoVDEPQ7slKLxhpfDTrNqXQ_kou-1646Z539YQCQGRsB5One4BfEDAfhAmH63d6jKwEU49yQUiZCBn8tbuzN4iiZmYn6z8wmqUQHO2KA3fo6IKrjggs3t1EK8iG05se4ltS21ZVQ-C0HVvvENoERu9iKEcM2SeKhl9Ucl3cqQpWRKBN9BEvTKpuXqM_Bkf2FiczQ3TJQ2SS0YJTYjoIKnOLHfM4H59ZcPwnTh0S3zplJ8e6dQv6t020x0gVYdA_U9EseIGhNQTtMEAztwleZJwdpBh6kiDxJb9-l4ENX4kFtvxsH4QQ - AuthToken string `json:"auth_token,omitempty"` - - // data - Data *GetAccountResponseData `json:"data,omitempty"` - - // node - // Example: dqZFtHthbelyE8MI6vU-LA - Node string `json:"node,omitempty"` - - // request id - // Example: 1bea6f4e37f65627452f9798d8398385 - RequestID string `json:"request_id,omitempty"` - - // revision - // Example: 270-8664316349384947d416dc00285fb532 - Revision string `json:"revision,omitempty"` - - // status - // Example: success - Status string `json:"status,omitempty"` - - // timestamp - // Example: 2020-05-06T22:42:58Z - Timestamp string `json:"timestamp,omitempty"` - - // version - // Example: 4.3.103 - Version string `json:"version,omitempty"` -} - -// Validate validates this get account response -func (m *GetAccountResponse) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponse) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - if m.Data != nil { - if err := m.Data.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data") - } - return err - } - } - - return nil -} - -// ContextValidate validate this get account response based on the context it is used -func (m *GetAccountResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - if m.Data != nil { - if err := m.Data.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponse) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponse) UnmarshalBinary(b []byte) error { - var res GetAccountResponse - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseData get account response data -// -// swagger:model GetAccountResponseData -type GetAccountResponseData struct { - - // available apps - // Example: ["voip","cluster","userportal","accounts","developer","pbxs","numbers"] - AvailableApps []string `json:"available_apps"` - - // billing id - // Example: a66f2b7a40944b744dcc63ca6f10f47a - BillingID string `json:"billing_id,omitempty"` - - // billing mode - // Example: manual - BillingMode string `json:"billing_mode,omitempty"` - - // call restriction - CallRestriction *GetAccountResponseDataCallRestriction `json:"call_restriction,omitempty"` - - // caller id - CallerID *GetAccountResponseDataCallerID `json:"caller_id,omitempty"` - - // contact - Contact *GetAccountResponseDataContact `json:"contact,omitempty"` - - // created - // Example: 63552627756 - Created int64 `json:"created,omitempty"` - - // descendants count - // Example: 48 - DescendantsCount float64 `json:"descendants_count,omitempty"` - - // enabled - // Example: true - Enabled bool `json:"enabled,omitempty"` - - // format from uri - // Example: false - FormatFromURI bool `json:"format_from_uri,omitempty"` - - // id - // Example: a66f2b7a40944b744dcc63ca6f10f47a - ID string `json:"id,omitempty"` - - // is reseller - // Example: false - IsReseller bool `json:"is_reseller,omitempty"` - - // language - // Example: en-us - Language string `json:"language,omitempty"` - - // media - Media *GetAccountResponseDataMedia `json:"media,omitempty"` - - // name - // Example: Telnexus Direct - Name string `json:"name,omitempty"` - - // notification preference - // Example: teletype - NotificationPreference string `json:"notification_preference,omitempty"` - - // notifications - Notifications *GetAccountResponseDataNotifications `json:"notifications,omitempty"` - - // provision - Provision *GetAccountResponseDataProvision `json:"provision,omitempty"` - - // realm - // Example: f5b70e.s.zswitch.net - Realm string `json:"realm,omitempty"` - - // reseller id - // Example: 33776f3f94eb642c81e199cf5f1059ae - ResellerID string `json:"reseller_id,omitempty"` - - // superduper admin - // Example: false - SuperduperAdmin bool `json:"superduper_admin,omitempty"` - - // timezone - // Example: America/Los_Angeles - Timezone string `json:"timezone,omitempty"` - - // ui metadata - UIMetadata *GetAccountResponseDataUIMetadata `json:"ui_metadata,omitempty"` - - // ui restrictions - UIRestrictions *GetAccountResponseDataUIRestrictions `json:"ui_restrictions,omitempty"` - - // wnm allow additions - // Example: false - WnmAllowAdditions bool `json:"wnm_allow_additions,omitempty"` -} - -// Validate validates this get account response data -func (m *GetAccountResponseData) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateCallRestriction(formats); err != nil { - res = append(res, err) - } - - if err := m.validateCallerID(formats); err != nil { - res = append(res, err) - } - - if err := m.validateContact(formats); err != nil { - res = append(res, err) - } - - if err := m.validateMedia(formats); err != nil { - res = append(res, err) - } - - if err := m.validateNotifications(formats); err != nil { - res = append(res, err) - } - - if err := m.validateProvision(formats); err != nil { - res = append(res, err) - } - - if err := m.validateUIMetadata(formats); err != nil { - res = append(res, err) - } - - if err := m.validateUIRestrictions(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponseData) validateCallRestriction(formats strfmt.Registry) error { - if swag.IsZero(m.CallRestriction) { // not required - return nil - } - - if m.CallRestriction != nil { - if err := m.CallRestriction.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseData) validateCallerID(formats strfmt.Registry) error { - if swag.IsZero(m.CallerID) { // not required - return nil - } - - if m.CallerID != nil { - if err := m.CallerID.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "caller_id") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseData) validateContact(formats strfmt.Registry) error { - if swag.IsZero(m.Contact) { // not required - return nil - } - - if m.Contact != nil { - if err := m.Contact.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "contact") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseData) validateMedia(formats strfmt.Registry) error { - if swag.IsZero(m.Media) { // not required - return nil - } - - if m.Media != nil { - if err := m.Media.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "media") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseData) validateNotifications(formats strfmt.Registry) error { - if swag.IsZero(m.Notifications) { // not required - return nil - } - - if m.Notifications != nil { - if err := m.Notifications.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "notifications") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseData) validateProvision(formats strfmt.Registry) error { - if swag.IsZero(m.Provision) { // not required - return nil - } - - if m.Provision != nil { - if err := m.Provision.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "provision") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseData) validateUIMetadata(formats strfmt.Registry) error { - if swag.IsZero(m.UIMetadata) { // not required - return nil - } - - if m.UIMetadata != nil { - if err := m.UIMetadata.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_metadata") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseData) validateUIRestrictions(formats strfmt.Registry) error { - if swag.IsZero(m.UIRestrictions) { // not required - return nil - } - - if m.UIRestrictions != nil { - if err := m.UIRestrictions.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions") - } - return err - } - } - - return nil -} - -// ContextValidate validate this get account response data based on the context it is used -func (m *GetAccountResponseData) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateCallRestriction(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateCallerID(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateContact(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateMedia(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateNotifications(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateProvision(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateUIMetadata(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateUIRestrictions(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponseData) contextValidateCallRestriction(ctx context.Context, formats strfmt.Registry) error { - - if m.CallRestriction != nil { - if err := m.CallRestriction.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseData) contextValidateCallerID(ctx context.Context, formats strfmt.Registry) error { - - if m.CallerID != nil { - if err := m.CallerID.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "caller_id") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseData) contextValidateContact(ctx context.Context, formats strfmt.Registry) error { - - if m.Contact != nil { - if err := m.Contact.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "contact") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseData) contextValidateMedia(ctx context.Context, formats strfmt.Registry) error { - - if m.Media != nil { - if err := m.Media.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "media") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseData) contextValidateNotifications(ctx context.Context, formats strfmt.Registry) error { - - if m.Notifications != nil { - if err := m.Notifications.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "notifications") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseData) contextValidateProvision(ctx context.Context, formats strfmt.Registry) error { - - if m.Provision != nil { - if err := m.Provision.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "provision") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseData) contextValidateUIMetadata(ctx context.Context, formats strfmt.Registry) error { - - if m.UIMetadata != nil { - if err := m.UIMetadata.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_metadata") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseData) contextValidateUIRestrictions(ctx context.Context, formats strfmt.Registry) error { - - if m.UIRestrictions != nil { - if err := m.UIRestrictions.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseData) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseData) UnmarshalBinary(b []byte) error { - var res GetAccountResponseData - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataCallRestriction get account response data call restriction -// -// swagger:model GetAccountResponseDataCallRestriction -type GetAccountResponseDataCallRestriction struct { - - // caribbean - Caribbean *GetAccountResponseDataCallRestrictionCaribbean `json:"caribbean,omitempty"` - - // did us - DidUs *GetAccountResponseDataCallRestrictionDidUs `json:"did_us,omitempty"` - - // directory - Directory *GetAccountResponseDataCallRestrictionDirectory `json:"directory,omitempty"` - - // emergency - Emergency *GetAccountResponseDataCallRestrictionEmergency `json:"emergency,omitempty"` - - // international - International *GetAccountResponseDataCallRestrictionInternational `json:"international,omitempty"` - - // toll us - TollUs *GetAccountResponseDataCallRestrictionTollUs `json:"toll_us,omitempty"` - - // tollfree us - TollfreeUs *GetAccountResponseDataCallRestrictionTollfreeUs `json:"tollfree_us,omitempty"` - - // unknown - Unknown *GetAccountResponseDataCallRestrictionUnknown `json:"unknown,omitempty"` -} - -// Validate validates this get account response data call restriction -func (m *GetAccountResponseDataCallRestriction) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateCaribbean(formats); err != nil { - res = append(res, err) - } - - if err := m.validateDidUs(formats); err != nil { - res = append(res, err) - } - - if err := m.validateDirectory(formats); err != nil { - res = append(res, err) - } - - if err := m.validateEmergency(formats); err != nil { - res = append(res, err) - } - - if err := m.validateInternational(formats); err != nil { - res = append(res, err) - } - - if err := m.validateTollUs(formats); err != nil { - res = append(res, err) - } - - if err := m.validateTollfreeUs(formats); err != nil { - res = append(res, err) - } - - if err := m.validateUnknown(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponseDataCallRestriction) validateCaribbean(formats strfmt.Registry) error { - if swag.IsZero(m.Caribbean) { // not required - return nil - } - - if m.Caribbean != nil { - if err := m.Caribbean.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "caribbean") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallRestriction) validateDidUs(formats strfmt.Registry) error { - if swag.IsZero(m.DidUs) { // not required - return nil - } - - if m.DidUs != nil { - if err := m.DidUs.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "did_us") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallRestriction) validateDirectory(formats strfmt.Registry) error { - if swag.IsZero(m.Directory) { // not required - return nil - } - - if m.Directory != nil { - if err := m.Directory.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "directory") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallRestriction) validateEmergency(formats strfmt.Registry) error { - if swag.IsZero(m.Emergency) { // not required - return nil - } - - if m.Emergency != nil { - if err := m.Emergency.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "emergency") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallRestriction) validateInternational(formats strfmt.Registry) error { - if swag.IsZero(m.International) { // not required - return nil - } - - if m.International != nil { - if err := m.International.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "international") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallRestriction) validateTollUs(formats strfmt.Registry) error { - if swag.IsZero(m.TollUs) { // not required - return nil - } - - if m.TollUs != nil { - if err := m.TollUs.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "toll_us") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallRestriction) validateTollfreeUs(formats strfmt.Registry) error { - if swag.IsZero(m.TollfreeUs) { // not required - return nil - } - - if m.TollfreeUs != nil { - if err := m.TollfreeUs.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "tollfree_us") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallRestriction) validateUnknown(formats strfmt.Registry) error { - if swag.IsZero(m.Unknown) { // not required - return nil - } - - if m.Unknown != nil { - if err := m.Unknown.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "unknown") - } - return err - } - } - - return nil -} - -// ContextValidate validate this get account response data call restriction based on the context it is used -func (m *GetAccountResponseDataCallRestriction) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateCaribbean(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateDidUs(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateDirectory(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateEmergency(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateInternational(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateTollUs(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateTollfreeUs(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateUnknown(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponseDataCallRestriction) contextValidateCaribbean(ctx context.Context, formats strfmt.Registry) error { - - if m.Caribbean != nil { - if err := m.Caribbean.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "caribbean") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallRestriction) contextValidateDidUs(ctx context.Context, formats strfmt.Registry) error { - - if m.DidUs != nil { - if err := m.DidUs.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "did_us") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallRestriction) contextValidateDirectory(ctx context.Context, formats strfmt.Registry) error { - - if m.Directory != nil { - if err := m.Directory.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "directory") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallRestriction) contextValidateEmergency(ctx context.Context, formats strfmt.Registry) error { - - if m.Emergency != nil { - if err := m.Emergency.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "emergency") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallRestriction) contextValidateInternational(ctx context.Context, formats strfmt.Registry) error { - - if m.International != nil { - if err := m.International.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "international") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallRestriction) contextValidateTollUs(ctx context.Context, formats strfmt.Registry) error { - - if m.TollUs != nil { - if err := m.TollUs.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "toll_us") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallRestriction) contextValidateTollfreeUs(ctx context.Context, formats strfmt.Registry) error { - - if m.TollfreeUs != nil { - if err := m.TollfreeUs.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "tollfree_us") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallRestriction) contextValidateUnknown(ctx context.Context, formats strfmt.Registry) error { - - if m.Unknown != nil { - if err := m.Unknown.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "call_restriction" + "." + "unknown") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestriction) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestriction) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataCallRestriction - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataCallRestrictionCaribbean get account response data call restriction caribbean -// -// swagger:model GetAccountResponseDataCallRestrictionCaribbean -type GetAccountResponseDataCallRestrictionCaribbean struct { - - // action - // Example: inherit - Action string `json:"action,omitempty"` -} - -// Validate validates this get account response data call restriction caribbean -func (m *GetAccountResponseDataCallRestrictionCaribbean) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data call restriction caribbean based on context it is used -func (m *GetAccountResponseDataCallRestrictionCaribbean) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionCaribbean) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionCaribbean) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataCallRestrictionCaribbean - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataCallRestrictionDidUs get account response data call restriction did us -// -// swagger:model GetAccountResponseDataCallRestrictionDidUs -type GetAccountResponseDataCallRestrictionDidUs struct { - - // action - // Example: inherit - Action string `json:"action,omitempty"` -} - -// Validate validates this get account response data call restriction did us -func (m *GetAccountResponseDataCallRestrictionDidUs) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data call restriction did us based on context it is used -func (m *GetAccountResponseDataCallRestrictionDidUs) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionDidUs) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionDidUs) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataCallRestrictionDidUs - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataCallRestrictionDirectory get account response data call restriction directory -// -// swagger:model GetAccountResponseDataCallRestrictionDirectory -type GetAccountResponseDataCallRestrictionDirectory struct { - - // action - // Example: inherit - Action string `json:"action,omitempty"` -} - -// Validate validates this get account response data call restriction directory -func (m *GetAccountResponseDataCallRestrictionDirectory) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data call restriction directory based on context it is used -func (m *GetAccountResponseDataCallRestrictionDirectory) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionDirectory) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionDirectory) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataCallRestrictionDirectory - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataCallRestrictionEmergency get account response data call restriction emergency -// -// swagger:model GetAccountResponseDataCallRestrictionEmergency -type GetAccountResponseDataCallRestrictionEmergency struct { - - // action - // Example: inherit - Action string `json:"action,omitempty"` -} - -// Validate validates this get account response data call restriction emergency -func (m *GetAccountResponseDataCallRestrictionEmergency) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data call restriction emergency based on context it is used -func (m *GetAccountResponseDataCallRestrictionEmergency) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionEmergency) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionEmergency) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataCallRestrictionEmergency - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataCallRestrictionInternational get account response data call restriction international -// -// swagger:model GetAccountResponseDataCallRestrictionInternational -type GetAccountResponseDataCallRestrictionInternational struct { - - // action - // Example: inherit - Action string `json:"action,omitempty"` -} - -// Validate validates this get account response data call restriction international -func (m *GetAccountResponseDataCallRestrictionInternational) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data call restriction international based on context it is used -func (m *GetAccountResponseDataCallRestrictionInternational) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionInternational) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionInternational) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataCallRestrictionInternational - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataCallRestrictionTollUs get account response data call restriction toll us -// -// swagger:model GetAccountResponseDataCallRestrictionTollUs -type GetAccountResponseDataCallRestrictionTollUs struct { - - // action - // Example: inherit - Action string `json:"action,omitempty"` -} - -// Validate validates this get account response data call restriction toll us -func (m *GetAccountResponseDataCallRestrictionTollUs) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data call restriction toll us based on context it is used -func (m *GetAccountResponseDataCallRestrictionTollUs) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionTollUs) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionTollUs) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataCallRestrictionTollUs - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataCallRestrictionTollfreeUs get account response data call restriction tollfree us -// -// swagger:model GetAccountResponseDataCallRestrictionTollfreeUs -type GetAccountResponseDataCallRestrictionTollfreeUs struct { - - // action - // Example: inherit - Action string `json:"action,omitempty"` -} - -// Validate validates this get account response data call restriction tollfree us -func (m *GetAccountResponseDataCallRestrictionTollfreeUs) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data call restriction tollfree us based on context it is used -func (m *GetAccountResponseDataCallRestrictionTollfreeUs) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionTollfreeUs) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionTollfreeUs) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataCallRestrictionTollfreeUs - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataCallRestrictionUnknown get account response data call restriction unknown -// -// swagger:model GetAccountResponseDataCallRestrictionUnknown -type GetAccountResponseDataCallRestrictionUnknown struct { - - // action - // Example: inherit - Action string `json:"action,omitempty"` -} - -// Validate validates this get account response data call restriction unknown -func (m *GetAccountResponseDataCallRestrictionUnknown) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data call restriction unknown based on context it is used -func (m *GetAccountResponseDataCallRestrictionUnknown) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionUnknown) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataCallRestrictionUnknown) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataCallRestrictionUnknown - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataCallerID get account response data caller ID -// -// swagger:model GetAccountResponseDataCallerID -type GetAccountResponseDataCallerID struct { - - // emergency - Emergency *GetAccountResponseDataCallerIDEmergency `json:"emergency,omitempty"` - - // external - External *GetAccountResponseDataCallerIDExternal `json:"external,omitempty"` -} - -// Validate validates this get account response data caller ID -func (m *GetAccountResponseDataCallerID) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateEmergency(formats); err != nil { - res = append(res, err) - } - - if err := m.validateExternal(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponseDataCallerID) validateEmergency(formats strfmt.Registry) error { - if swag.IsZero(m.Emergency) { // not required - return nil - } - - if m.Emergency != nil { - if err := m.Emergency.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "caller_id" + "." + "emergency") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallerID) validateExternal(formats strfmt.Registry) error { - if swag.IsZero(m.External) { // not required - return nil - } - - if m.External != nil { - if err := m.External.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "caller_id" + "." + "external") - } - return err - } - } - - return nil -} - -// ContextValidate validate this get account response data caller ID based on the context it is used -func (m *GetAccountResponseDataCallerID) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateEmergency(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateExternal(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponseDataCallerID) contextValidateEmergency(ctx context.Context, formats strfmt.Registry) error { - - if m.Emergency != nil { - if err := m.Emergency.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "caller_id" + "." + "emergency") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataCallerID) contextValidateExternal(ctx context.Context, formats strfmt.Registry) error { - - if m.External != nil { - if err := m.External.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "caller_id" + "." + "external") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataCallerID) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataCallerID) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataCallerID - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataCallerIDEmergency get account response data caller ID emergency -// -// swagger:model GetAccountResponseDataCallerIDEmergency -type GetAccountResponseDataCallerIDEmergency struct { - - // name - // Example: Telnexus - Name string `json:"name,omitempty"` - - // number - // Example: +15109911114 - Number string `json:"number,omitempty"` -} - -// Validate validates this get account response data caller ID emergency -func (m *GetAccountResponseDataCallerIDEmergency) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data caller ID emergency based on context it is used -func (m *GetAccountResponseDataCallerIDEmergency) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataCallerIDEmergency) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataCallerIDEmergency) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataCallerIDEmergency - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataCallerIDExternal get account response data caller ID external -// -// swagger:model GetAccountResponseDataCallerIDExternal -type GetAccountResponseDataCallerIDExternal struct { - - // name - // Example: Telnexus - Name string `json:"name,omitempty"` - - // number - // Example: +15109911114 - Number string `json:"number,omitempty"` -} - -// Validate validates this get account response data caller ID external -func (m *GetAccountResponseDataCallerIDExternal) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data caller ID external based on context it is used -func (m *GetAccountResponseDataCallerIDExternal) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataCallerIDExternal) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataCallerIDExternal) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataCallerIDExternal - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataContact get account response data contact -// -// swagger:model GetAccountResponseDataContact -type GetAccountResponseDataContact struct { - - // billing - Billing *GetAccountResponseDataContactBilling `json:"billing,omitempty"` - - // technical - Technical *GetAccountResponseDataContactTechnical `json:"technical,omitempty"` -} - -// Validate validates this get account response data contact -func (m *GetAccountResponseDataContact) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateBilling(formats); err != nil { - res = append(res, err) - } - - if err := m.validateTechnical(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponseDataContact) validateBilling(formats strfmt.Registry) error { - if swag.IsZero(m.Billing) { // not required - return nil - } - - if m.Billing != nil { - if err := m.Billing.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "contact" + "." + "billing") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataContact) validateTechnical(formats strfmt.Registry) error { - if swag.IsZero(m.Technical) { // not required - return nil - } - - if m.Technical != nil { - if err := m.Technical.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "contact" + "." + "technical") - } - return err - } - } - - return nil -} - -// ContextValidate validate this get account response data contact based on the context it is used -func (m *GetAccountResponseDataContact) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateBilling(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateTechnical(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponseDataContact) contextValidateBilling(ctx context.Context, formats strfmt.Registry) error { - - if m.Billing != nil { - if err := m.Billing.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "contact" + "." + "billing") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataContact) contextValidateTechnical(ctx context.Context, formats strfmt.Registry) error { - - if m.Technical != nil { - if err := m.Technical.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "contact" + "." + "technical") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataContact) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataContact) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataContact - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataContactBilling get account response data contact billing -// -// swagger:model GetAccountResponseDataContactBilling -type GetAccountResponseDataContactBilling struct { - - // email - // Example: noc@telnexus.com - Email string `json:"email,omitempty"` - - // name - Name string `json:"name,omitempty"` - - // number - // Example: 5108597000 - Number string `json:"number,omitempty"` -} - -// Validate validates this get account response data contact billing -func (m *GetAccountResponseDataContactBilling) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data contact billing based on context it is used -func (m *GetAccountResponseDataContactBilling) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataContactBilling) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataContactBilling) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataContactBilling - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataContactTechnical get account response data contact technical -// -// swagger:model GetAccountResponseDataContactTechnical -type GetAccountResponseDataContactTechnical struct { - - // email - // Example: noc@telnexus.com - Email string `json:"email,omitempty"` - - // number - // Example: 5108497000 - Number string `json:"number,omitempty"` -} - -// Validate validates this get account response data contact technical -func (m *GetAccountResponseDataContactTechnical) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data contact technical based on context it is used -func (m *GetAccountResponseDataContactTechnical) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataContactTechnical) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataContactTechnical) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataContactTechnical - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataMedia get account response data media -// -// swagger:model GetAccountResponseDataMedia -type GetAccountResponseDataMedia struct { - - // bypass media - // Example: auto - BypassMedia string `json:"bypass_media,omitempty"` -} - -// Validate validates this get account response data media -func (m *GetAccountResponseDataMedia) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data media based on context it is used -func (m *GetAccountResponseDataMedia) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataMedia) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataMedia) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataMedia - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataNotifications get account response data notifications -// -// swagger:model GetAccountResponseDataNotifications -type GetAccountResponseDataNotifications struct { - - // fax to email - FaxToEmail *GetAccountResponseDataNotificationsFaxToEmail `json:"fax_to_email,omitempty"` - - // low balance - LowBalance *GetAccountResponseDataNotificationsLowBalance `json:"low_balance,omitempty"` - - // voicemail to email - VoicemailToEmail *GetAccountResponseDataNotificationsVoicemailToEmail `json:"voicemail_to_email,omitempty"` -} - -// Validate validates this get account response data notifications -func (m *GetAccountResponseDataNotifications) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateFaxToEmail(formats); err != nil { - res = append(res, err) - } - - if err := m.validateLowBalance(formats); err != nil { - res = append(res, err) - } - - if err := m.validateVoicemailToEmail(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponseDataNotifications) validateFaxToEmail(formats strfmt.Registry) error { - if swag.IsZero(m.FaxToEmail) { // not required - return nil - } - - if m.FaxToEmail != nil { - if err := m.FaxToEmail.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "notifications" + "." + "fax_to_email") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataNotifications) validateLowBalance(formats strfmt.Registry) error { - if swag.IsZero(m.LowBalance) { // not required - return nil - } - - if m.LowBalance != nil { - if err := m.LowBalance.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "notifications" + "." + "low_balance") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataNotifications) validateVoicemailToEmail(formats strfmt.Registry) error { - if swag.IsZero(m.VoicemailToEmail) { // not required - return nil - } - - if m.VoicemailToEmail != nil { - if err := m.VoicemailToEmail.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "notifications" + "." + "voicemail_to_email") - } - return err - } - } - - return nil -} - -// ContextValidate validate this get account response data notifications based on the context it is used -func (m *GetAccountResponseDataNotifications) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateFaxToEmail(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateLowBalance(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateVoicemailToEmail(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponseDataNotifications) contextValidateFaxToEmail(ctx context.Context, formats strfmt.Registry) error { - - if m.FaxToEmail != nil { - if err := m.FaxToEmail.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "notifications" + "." + "fax_to_email") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataNotifications) contextValidateLowBalance(ctx context.Context, formats strfmt.Registry) error { - - if m.LowBalance != nil { - if err := m.LowBalance.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "notifications" + "." + "low_balance") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataNotifications) contextValidateVoicemailToEmail(ctx context.Context, formats strfmt.Registry) error { - - if m.VoicemailToEmail != nil { - if err := m.VoicemailToEmail.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "notifications" + "." + "voicemail_to_email") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataNotifications) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataNotifications) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataNotifications - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataNotificationsFaxToEmail get account response data notifications fax to email -// -// swagger:model GetAccountResponseDataNotificationsFaxToEmail -type GetAccountResponseDataNotificationsFaxToEmail struct { - - // service name - // Example: support@telnexus.com - ServiceName string `json:"service_name,omitempty"` - - // service provider - // Example: support@telnexus.com - ServiceProvider string `json:"service_provider,omitempty"` - - // service url - // Example: telnexus.com - ServiceURL string `json:"service_url,omitempty"` - - // support email - // Example: support@telnexus.com - SupportEmail string `json:"support_email,omitempty"` - - // support number - // Example: 510-991-1114 - SupportNumber string `json:"support_number,omitempty"` -} - -// Validate validates this get account response data notifications fax to email -func (m *GetAccountResponseDataNotificationsFaxToEmail) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data notifications fax to email based on context it is used -func (m *GetAccountResponseDataNotificationsFaxToEmail) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataNotificationsFaxToEmail) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataNotificationsFaxToEmail) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataNotificationsFaxToEmail - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataNotificationsLowBalance get account response data notifications low balance -// -// swagger:model GetAccountResponseDataNotificationsLowBalance -type GetAccountResponseDataNotificationsLowBalance struct { - - // sent low balance - // Example: false - SentLowBalance bool `json:"sent_low_balance,omitempty"` -} - -// Validate validates this get account response data notifications low balance -func (m *GetAccountResponseDataNotificationsLowBalance) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data notifications low balance based on context it is used -func (m *GetAccountResponseDataNotificationsLowBalance) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataNotificationsLowBalance) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataNotificationsLowBalance) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataNotificationsLowBalance - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataNotificationsVoicemailToEmail get account response data notifications voicemail to email -// -// swagger:model GetAccountResponseDataNotificationsVoicemailToEmail -type GetAccountResponseDataNotificationsVoicemailToEmail struct { - - // service name - // Example: support@telnexus.com - ServiceName string `json:"service_name,omitempty"` - - // service provider - // Example: support@telnexus.com - ServiceProvider string `json:"service_provider,omitempty"` - - // service url - // Example: telnexus.com - ServiceURL string `json:"service_url,omitempty"` - - // support email - // Example: support@telnexus.com - SupportEmail string `json:"support_email,omitempty"` - - // support number - // Example: 510-991-1114 - SupportNumber string `json:"support_number,omitempty"` -} - -// Validate validates this get account response data notifications voicemail to email -func (m *GetAccountResponseDataNotificationsVoicemailToEmail) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data notifications voicemail to email based on context it is used -func (m *GetAccountResponseDataNotificationsVoicemailToEmail) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataNotificationsVoicemailToEmail) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataNotificationsVoicemailToEmail) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataNotificationsVoicemailToEmail - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataProvision get account response data provision -// -// swagger:model GetAccountResponseDataProvision -type GetAccountResponseDataProvision struct { - - // admin password - AdminPassword string `json:"admin_password,omitempty"` -} - -// Validate validates this get account response data provision -func (m *GetAccountResponseDataProvision) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data provision based on context it is used -func (m *GetAccountResponseDataProvision) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataProvision) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataProvision) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataProvision - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataUIMetadata get account response data UI metadata -// -// swagger:model GetAccountResponseDataUIMetadata -type GetAccountResponseDataUIMetadata struct { - - // origin - // Example: accounts - Origin string `json:"origin,omitempty"` - - // ui - // Example: monster-ui - UI string `json:"ui,omitempty"` - - // version - // Example: 4.1-56 - Version string `json:"version,omitempty"` -} - -// Validate validates this get account response data UI metadata -func (m *GetAccountResponseDataUIMetadata) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data UI metadata based on context it is used -func (m *GetAccountResponseDataUIMetadata) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataUIMetadata) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataUIMetadata) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataUIMetadata - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataUIRestrictions get account response data UI restrictions -// -// swagger:model GetAccountResponseDataUIRestrictions -type GetAccountResponseDataUIRestrictions struct { - - // myaccount - Myaccount *GetAccountResponseDataUIRestrictionsMyaccount `json:"myaccount,omitempty"` -} - -// Validate validates this get account response data UI restrictions -func (m *GetAccountResponseDataUIRestrictions) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateMyaccount(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponseDataUIRestrictions) validateMyaccount(formats strfmt.Registry) error { - if swag.IsZero(m.Myaccount) { // not required - return nil - } - - if m.Myaccount != nil { - if err := m.Myaccount.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount") - } - return err - } - } - - return nil -} - -// ContextValidate validate this get account response data UI restrictions based on the context it is used -func (m *GetAccountResponseDataUIRestrictions) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateMyaccount(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponseDataUIRestrictions) contextValidateMyaccount(ctx context.Context, formats strfmt.Registry) error { - - if m.Myaccount != nil { - if err := m.Myaccount.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictions) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictions) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataUIRestrictions - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataUIRestrictionsMyaccount get account response data UI restrictions myaccount -// -// swagger:model GetAccountResponseDataUIRestrictionsMyaccount -type GetAccountResponseDataUIRestrictionsMyaccount struct { - - // account - Account *GetAccountResponseDataUIRestrictionsMyaccountAccount `json:"account,omitempty"` - - // balance - Balance *GetAccountResponseDataUIRestrictionsMyaccountBalance `json:"balance,omitempty"` - - // billing - Billing *GetAccountResponseDataUIRestrictionsMyaccountBilling `json:"billing,omitempty"` - - // error tracker - ErrorTracker *GetAccountResponseDataUIRestrictionsMyaccountErrorTracker `json:"errorTracker,omitempty"` - - // inbound - Inbound *GetAccountResponseDataUIRestrictionsMyaccountInbound `json:"inbound,omitempty"` - - // outbound - Outbound *GetAccountResponseDataUIRestrictionsMyaccountOutbound `json:"outbound,omitempty"` - - // service plan - ServicePlan *GetAccountResponseDataUIRestrictionsMyaccountServicePlan `json:"service_plan,omitempty"` - - // transactions - Transactions *GetAccountResponseDataUIRestrictionsMyaccountTransactions `json:"transactions,omitempty"` - - // twoway - Twoway *GetAccountResponseDataUIRestrictionsMyaccountTwoway `json:"twoway,omitempty"` - - // user - User *GetAccountResponseDataUIRestrictionsMyaccountUser `json:"user,omitempty"` -} - -// Validate validates this get account response data UI restrictions myaccount -func (m *GetAccountResponseDataUIRestrictionsMyaccount) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateAccount(formats); err != nil { - res = append(res, err) - } - - if err := m.validateBalance(formats); err != nil { - res = append(res, err) - } - - if err := m.validateBilling(formats); err != nil { - res = append(res, err) - } - - if err := m.validateErrorTracker(formats); err != nil { - res = append(res, err) - } - - if err := m.validateInbound(formats); err != nil { - res = append(res, err) - } - - if err := m.validateOutbound(formats); err != nil { - res = append(res, err) - } - - if err := m.validateServicePlan(formats); err != nil { - res = append(res, err) - } - - if err := m.validateTransactions(formats); err != nil { - res = append(res, err) - } - - if err := m.validateTwoway(formats); err != nil { - res = append(res, err) - } - - if err := m.validateUser(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) validateAccount(formats strfmt.Registry) error { - if swag.IsZero(m.Account) { // not required - return nil - } - - if m.Account != nil { - if err := m.Account.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "account") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) validateBalance(formats strfmt.Registry) error { - if swag.IsZero(m.Balance) { // not required - return nil - } - - if m.Balance != nil { - if err := m.Balance.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "balance") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) validateBilling(formats strfmt.Registry) error { - if swag.IsZero(m.Billing) { // not required - return nil - } - - if m.Billing != nil { - if err := m.Billing.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "billing") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) validateErrorTracker(formats strfmt.Registry) error { - if swag.IsZero(m.ErrorTracker) { // not required - return nil - } - - if m.ErrorTracker != nil { - if err := m.ErrorTracker.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "errorTracker") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) validateInbound(formats strfmt.Registry) error { - if swag.IsZero(m.Inbound) { // not required - return nil - } - - if m.Inbound != nil { - if err := m.Inbound.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "inbound") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) validateOutbound(formats strfmt.Registry) error { - if swag.IsZero(m.Outbound) { // not required - return nil - } - - if m.Outbound != nil { - if err := m.Outbound.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "outbound") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) validateServicePlan(formats strfmt.Registry) error { - if swag.IsZero(m.ServicePlan) { // not required - return nil - } - - if m.ServicePlan != nil { - if err := m.ServicePlan.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "service_plan") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) validateTransactions(formats strfmt.Registry) error { - if swag.IsZero(m.Transactions) { // not required - return nil - } - - if m.Transactions != nil { - if err := m.Transactions.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "transactions") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) validateTwoway(formats strfmt.Registry) error { - if swag.IsZero(m.Twoway) { // not required - return nil - } - - if m.Twoway != nil { - if err := m.Twoway.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "twoway") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) validateUser(formats strfmt.Registry) error { - if swag.IsZero(m.User) { // not required - return nil - } - - if m.User != nil { - if err := m.User.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "user") - } - return err - } - } - - return nil -} - -// ContextValidate validate this get account response data UI restrictions myaccount based on the context it is used -func (m *GetAccountResponseDataUIRestrictionsMyaccount) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateAccount(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateBalance(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateBilling(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateErrorTracker(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateInbound(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateOutbound(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateServicePlan(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateTransactions(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateTwoway(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateUser(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) contextValidateAccount(ctx context.Context, formats strfmt.Registry) error { - - if m.Account != nil { - if err := m.Account.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "account") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) contextValidateBalance(ctx context.Context, formats strfmt.Registry) error { - - if m.Balance != nil { - if err := m.Balance.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "balance") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) contextValidateBilling(ctx context.Context, formats strfmt.Registry) error { - - if m.Billing != nil { - if err := m.Billing.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "billing") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) contextValidateErrorTracker(ctx context.Context, formats strfmt.Registry) error { - - if m.ErrorTracker != nil { - if err := m.ErrorTracker.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "errorTracker") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) contextValidateInbound(ctx context.Context, formats strfmt.Registry) error { - - if m.Inbound != nil { - if err := m.Inbound.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "inbound") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) contextValidateOutbound(ctx context.Context, formats strfmt.Registry) error { - - if m.Outbound != nil { - if err := m.Outbound.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "outbound") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) contextValidateServicePlan(ctx context.Context, formats strfmt.Registry) error { - - if m.ServicePlan != nil { - if err := m.ServicePlan.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "service_plan") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) contextValidateTransactions(ctx context.Context, formats strfmt.Registry) error { - - if m.Transactions != nil { - if err := m.Transactions.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "transactions") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) contextValidateTwoway(ctx context.Context, formats strfmt.Registry) error { - - if m.Twoway != nil { - if err := m.Twoway.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "twoway") - } - return err - } - } - - return nil -} - -func (m *GetAccountResponseDataUIRestrictionsMyaccount) contextValidateUser(ctx context.Context, formats strfmt.Registry) error { - - if m.User != nil { - if err := m.User.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "ui_restrictions" + "." + "myaccount" + "." + "user") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccount) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccount) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataUIRestrictionsMyaccount - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataUIRestrictionsMyaccountAccount get account response data UI restrictions myaccount account -// -// swagger:model GetAccountResponseDataUIRestrictionsMyaccountAccount -type GetAccountResponseDataUIRestrictionsMyaccountAccount struct { - - // show tab - // Example: true - ShowTab bool `json:"show_tab,omitempty"` -} - -// Validate validates this get account response data UI restrictions myaccount account -func (m *GetAccountResponseDataUIRestrictionsMyaccountAccount) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data UI restrictions myaccount account based on context it is used -func (m *GetAccountResponseDataUIRestrictionsMyaccountAccount) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountAccount) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountAccount) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataUIRestrictionsMyaccountAccount - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataUIRestrictionsMyaccountBalance get account response data UI restrictions myaccount balance -// -// swagger:model GetAccountResponseDataUIRestrictionsMyaccountBalance -type GetAccountResponseDataUIRestrictionsMyaccountBalance struct { - - // show credit - // Example: true - ShowCredit bool `json:"show_credit,omitempty"` - - // show header - // Example: true - ShowHeader bool `json:"show_header,omitempty"` - - // show minutes - // Example: true - ShowMinutes bool `json:"show_minutes,omitempty"` - - // show tab - // Example: true - ShowTab bool `json:"show_tab,omitempty"` -} - -// Validate validates this get account response data UI restrictions myaccount balance -func (m *GetAccountResponseDataUIRestrictionsMyaccountBalance) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data UI restrictions myaccount balance based on context it is used -func (m *GetAccountResponseDataUIRestrictionsMyaccountBalance) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountBalance) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountBalance) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataUIRestrictionsMyaccountBalance - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataUIRestrictionsMyaccountBilling get account response data UI restrictions myaccount billing -// -// swagger:model GetAccountResponseDataUIRestrictionsMyaccountBilling -type GetAccountResponseDataUIRestrictionsMyaccountBilling struct { - - // show tab - // Example: true - ShowTab bool `json:"show_tab,omitempty"` -} - -// Validate validates this get account response data UI restrictions myaccount billing -func (m *GetAccountResponseDataUIRestrictionsMyaccountBilling) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data UI restrictions myaccount billing based on context it is used -func (m *GetAccountResponseDataUIRestrictionsMyaccountBilling) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountBilling) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountBilling) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataUIRestrictionsMyaccountBilling - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataUIRestrictionsMyaccountErrorTracker get account response data UI restrictions myaccount error tracker -// -// swagger:model GetAccountResponseDataUIRestrictionsMyaccountErrorTracker -type GetAccountResponseDataUIRestrictionsMyaccountErrorTracker struct { - - // show tab - // Example: true - ShowTab bool `json:"show_tab,omitempty"` -} - -// Validate validates this get account response data UI restrictions myaccount error tracker -func (m *GetAccountResponseDataUIRestrictionsMyaccountErrorTracker) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data UI restrictions myaccount error tracker based on context it is used -func (m *GetAccountResponseDataUIRestrictionsMyaccountErrorTracker) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountErrorTracker) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountErrorTracker) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataUIRestrictionsMyaccountErrorTracker - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataUIRestrictionsMyaccountInbound get account response data UI restrictions myaccount inbound -// -// swagger:model GetAccountResponseDataUIRestrictionsMyaccountInbound -type GetAccountResponseDataUIRestrictionsMyaccountInbound struct { - - // show tab - // Example: true - ShowTab bool `json:"show_tab,omitempty"` -} - -// Validate validates this get account response data UI restrictions myaccount inbound -func (m *GetAccountResponseDataUIRestrictionsMyaccountInbound) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data UI restrictions myaccount inbound based on context it is used -func (m *GetAccountResponseDataUIRestrictionsMyaccountInbound) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountInbound) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountInbound) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataUIRestrictionsMyaccountInbound - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataUIRestrictionsMyaccountOutbound get account response data UI restrictions myaccount outbound -// -// swagger:model GetAccountResponseDataUIRestrictionsMyaccountOutbound -type GetAccountResponseDataUIRestrictionsMyaccountOutbound struct { - - // show tab - // Example: true - ShowTab bool `json:"show_tab,omitempty"` -} - -// Validate validates this get account response data UI restrictions myaccount outbound -func (m *GetAccountResponseDataUIRestrictionsMyaccountOutbound) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data UI restrictions myaccount outbound based on context it is used -func (m *GetAccountResponseDataUIRestrictionsMyaccountOutbound) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountOutbound) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountOutbound) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataUIRestrictionsMyaccountOutbound - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataUIRestrictionsMyaccountServicePlan get account response data UI restrictions myaccount service plan -// -// swagger:model GetAccountResponseDataUIRestrictionsMyaccountServicePlan -type GetAccountResponseDataUIRestrictionsMyaccountServicePlan struct { - - // show tab - // Example: true - ShowTab bool `json:"show_tab,omitempty"` -} - -// Validate validates this get account response data UI restrictions myaccount service plan -func (m *GetAccountResponseDataUIRestrictionsMyaccountServicePlan) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data UI restrictions myaccount service plan based on context it is used -func (m *GetAccountResponseDataUIRestrictionsMyaccountServicePlan) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountServicePlan) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountServicePlan) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataUIRestrictionsMyaccountServicePlan - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataUIRestrictionsMyaccountTransactions get account response data UI restrictions myaccount transactions -// -// swagger:model GetAccountResponseDataUIRestrictionsMyaccountTransactions -type GetAccountResponseDataUIRestrictionsMyaccountTransactions struct { - - // show tab - // Example: true - ShowTab bool `json:"show_tab,omitempty"` -} - -// Validate validates this get account response data UI restrictions myaccount transactions -func (m *GetAccountResponseDataUIRestrictionsMyaccountTransactions) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data UI restrictions myaccount transactions based on context it is used -func (m *GetAccountResponseDataUIRestrictionsMyaccountTransactions) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountTransactions) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountTransactions) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataUIRestrictionsMyaccountTransactions - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataUIRestrictionsMyaccountTwoway get account response data UI restrictions myaccount twoway -// -// swagger:model GetAccountResponseDataUIRestrictionsMyaccountTwoway -type GetAccountResponseDataUIRestrictionsMyaccountTwoway struct { - - // show tab - // Example: true - ShowTab bool `json:"show_tab,omitempty"` -} - -// Validate validates this get account response data UI restrictions myaccount twoway -func (m *GetAccountResponseDataUIRestrictionsMyaccountTwoway) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data UI restrictions myaccount twoway based on context it is used -func (m *GetAccountResponseDataUIRestrictionsMyaccountTwoway) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountTwoway) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountTwoway) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataUIRestrictionsMyaccountTwoway - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountResponseDataUIRestrictionsMyaccountUser get account response data UI restrictions myaccount user -// -// swagger:model GetAccountResponseDataUIRestrictionsMyaccountUser -type GetAccountResponseDataUIRestrictionsMyaccountUser struct { - - // show tab - // Example: true - ShowTab bool `json:"show_tab,omitempty"` -} - -// Validate validates this get account response data UI restrictions myaccount user -func (m *GetAccountResponseDataUIRestrictionsMyaccountUser) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account response data UI restrictions myaccount user based on context it is used -func (m *GetAccountResponseDataUIRestrictionsMyaccountUser) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountUser) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountResponseDataUIRestrictionsMyaccountUser) UnmarshalBinary(b []byte) error { - var res GetAccountResponseDataUIRestrictionsMyaccountUser - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/kazoo/kazoo_models/get_account_time_rule_response.go b/api/kazoo/kazoo_models/get_account_time_rule_response.go deleted file mode 100644 index db4109c..0000000 --- a/api/kazoo/kazoo_models/get_account_time_rule_response.go +++ /dev/null @@ -1,189 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package kazoo_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// GetAccountTimeRuleResponse get account time rule response -// -// swagger:model GetAccountTimeRuleResponse -type GetAccountTimeRuleResponse struct { - - // auth token - AuthToken string `json:"auth_token,omitempty"` - - // data - Data []*GetAccountTimeRuleResponseDataItems0 `json:"data"` - - // node - // Example: dqZFtHthbelyE8MI6vU-LA - Node string `json:"node,omitempty"` - - // page size - // Example: 1 - PageSize float64 `json:"page_size,omitempty"` - - // request id - // Example: 7372ec1ec4dc316cd0a8cf6786defde6 - RequestID string `json:"request_id,omitempty"` - - // revision - // Example: b694bae5e001d52cf40637b618bc6bfb - Revision string `json:"revision,omitempty"` - - // status - // Example: success - Status string `json:"status,omitempty"` - - // timestamp - // Example: 2020-05-07T02:43:06Z - Timestamp string `json:"timestamp,omitempty"` - - // version - // Example: 4.3.103 - Version string `json:"version,omitempty"` -} - -// Validate validates this get account time rule response -func (m *GetAccountTimeRuleResponse) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountTimeRuleResponse) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this get account time rule response based on the context it is used -func (m *GetAccountTimeRuleResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountTimeRuleResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountTimeRuleResponse) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountTimeRuleResponse) UnmarshalBinary(b []byte) error { - var res GetAccountTimeRuleResponse - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountTimeRuleResponseDataItems0 get account time rule response data items0 -// -// swagger:model GetAccountTimeRuleResponseDataItems0 -type GetAccountTimeRuleResponseDataItems0 struct { - - // id - // Example: 1c3939fd0afcdadaa2986bc61c787d03 - ID string `json:"id,omitempty"` - - // name - // Example: Business Hours - Name string `json:"name,omitempty"` -} - -// Validate validates this get account time rule response data items0 -func (m *GetAccountTimeRuleResponseDataItems0) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account time rule response data items0 based on context it is used -func (m *GetAccountTimeRuleResponseDataItems0) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountTimeRuleResponseDataItems0) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountTimeRuleResponseDataItems0) UnmarshalBinary(b []byte) error { - var res GetAccountTimeRuleResponseDataItems0 - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/kazoo/kazoo_models/get_account_user_response.go b/api/kazoo/kazoo_models/get_account_user_response.go deleted file mode 100644 index 5db2ac0..0000000 --- a/api/kazoo/kazoo_models/get_account_user_response.go +++ /dev/null @@ -1,213 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package kazoo_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// GetAccountUserResponse get account user response -// -// swagger:model GetAccountUserResponse -type GetAccountUserResponse struct { - - // auth token - AuthToken string `json:"auth_token,omitempty"` - - // data - Data []*GetAccountUserResponseDataItems0 `json:"data"` - - // node - // Example: dqZFtHthbelyE8MI6vU-LA - Node string `json:"node,omitempty"` - - // page size - // Example: 4 - PageSize float64 `json:"page_size,omitempty"` - - // request id - // Example: c11b939a99b181b3a09b7770c4e49302 - RequestID string `json:"request_id,omitempty"` - - // revision - // Example: c989520cf895f314b32d163d3b59d723 - Revision string `json:"revision,omitempty"` - - // status - // Example: success - Status string `json:"status,omitempty"` - - // timestamp - // Example: 2020-05-07T02:44:28Z - Timestamp string `json:"timestamp,omitempty"` - - // version - // Example: 4.3.103 - Version string `json:"version,omitempty"` -} - -// Validate validates this get account user response -func (m *GetAccountUserResponse) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountUserResponse) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this get account user response based on the context it is used -func (m *GetAccountUserResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountUserResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountUserResponse) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountUserResponse) UnmarshalBinary(b []byte) error { - var res GetAccountUserResponse - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountUserResponseDataItems0 get account user response data items0 -// -// swagger:model GetAccountUserResponseDataItems0 -type GetAccountUserResponseDataItems0 struct { - - // email - // Example: reception@telnexus.com - Email string `json:"email,omitempty"` - - // features - // Example: ["vm_to_email"] - Features []string `json:"features"` - - // first name - // Example: Phil - FirstName string `json:"first_name,omitempty"` - - // id - // Example: 8c571470fef7db363994c8427c07b7bb - ID string `json:"id,omitempty"` - - // last name - // Example: Cranepool - LastName string `json:"last_name,omitempty"` - - // priv level - // Example: user - PrivLevel string `json:"priv_level,omitempty"` - - // timezone - // Example: America/Los_Angeles - Timezone string `json:"timezone,omitempty"` - - // username - // Example: phil - Username string `json:"username,omitempty"` -} - -// Validate validates this get account user response data items0 -func (m *GetAccountUserResponseDataItems0) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account user response data items0 based on context it is used -func (m *GetAccountUserResponseDataItems0) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountUserResponseDataItems0) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountUserResponseDataItems0) UnmarshalBinary(b []byte) error { - var res GetAccountUserResponseDataItems0 - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/kazoo/kazoo_models/get_account_vm_box_response.go b/api/kazoo/kazoo_models/get_account_vm_box_response.go deleted file mode 100644 index 6b90976..0000000 --- a/api/kazoo/kazoo_models/get_account_vm_box_response.go +++ /dev/null @@ -1,201 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package kazoo_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// GetAccountVMBoxResponse get account Vm box response -// -// swagger:model GetAccountVmBoxResponse -type GetAccountVMBoxResponse struct { - - // auth token - AuthToken string `json:"auth_token,omitempty"` - - // data - Data []*GetAccountVMBoxResponseDataItems0 `json:"data"` - - // node - // Example: dqZFtHthbelyE8MI6vU-LA - Node string `json:"node,omitempty"` - - // page size - // Example: 5 - PageSize float64 `json:"page_size,omitempty"` - - // request id - // Example: 0452de0d2fbef2cbccafaf7b3894bc0b - RequestID string `json:"request_id,omitempty"` - - // revision - // Example: 171c5eb1c826f66fe16cfb0669f55994 - Revision string `json:"revision,omitempty"` - - // status - // Example: success - Status string `json:"status,omitempty"` - - // timestamp - // Example: 2020-05-07T02:52:10Z - Timestamp string `json:"timestamp,omitempty"` - - // version - // Example: 4.3.103 - Version string `json:"version,omitempty"` -} - -// Validate validates this get account Vm box response -func (m *GetAccountVMBoxResponse) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountVMBoxResponse) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this get account Vm box response based on the context it is used -func (m *GetAccountVMBoxResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetAccountVMBoxResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountVMBoxResponse) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountVMBoxResponse) UnmarshalBinary(b []byte) error { - var res GetAccountVMBoxResponse - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetAccountVMBoxResponseDataItems0 get account VM box response data items0 -// -// swagger:model GetAccountVMBoxResponseDataItems0 -type GetAccountVMBoxResponseDataItems0 struct { - - // id - // Example: cbd3606fea91c9b834c5a1fc0efa1098 - ID string `json:"id,omitempty"` - - // mailbox - // Example: 2005 - Mailbox string `json:"mailbox,omitempty"` - - // messages - // Example: 12 - Messages float64 `json:"messages,omitempty"` - - // name - // Example: 2005 - Bill VM - Name string `json:"name,omitempty"` - - // owner id - // Example: f95626ebc2db4fd1a2b5ac5f6b11f7a3 - OwnerID string `json:"owner_id,omitempty"` -} - -// Validate validates this get account VM box response data items0 -func (m *GetAccountVMBoxResponseDataItems0) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get account VM box response data items0 based on context it is used -func (m *GetAccountVMBoxResponseDataItems0) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetAccountVMBoxResponseDataItems0) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetAccountVMBoxResponseDataItems0) UnmarshalBinary(b []byte) error { - var res GetAccountVMBoxResponseDataItems0 - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/kazoo/kazoo_models/get_device_response.go b/api/kazoo/kazoo_models/get_device_response.go deleted file mode 100644 index 9b045e0..0000000 --- a/api/kazoo/kazoo_models/get_device_response.go +++ /dev/null @@ -1,209 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package kazoo_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// GetDeviceResponse get device response -// -// swagger:model GetDeviceResponse -type GetDeviceResponse struct { - - // auth token - AuthToken string `json:"auth_token,omitempty"` - - // data - Data []*GetDeviceResponseDataItems0 `json:"data"` - - // node - // Example: dqZFtHthbelyE8MI6vU-LA - Node string `json:"node,omitempty"` - - // page size - // Example: 4 - PageSize float64 `json:"page_size,omitempty"` - - // request id - // Example: 29c9cccc07016866243a9dbd9481c88a - RequestID string `json:"request_id,omitempty"` - - // revision - // Example: 794a8debed3fca4330ba2373cd703773 - Revision string `json:"revision,omitempty"` - - // status - // Example: success - Status string `json:"status,omitempty"` - - // timestamp - // Example: 2020-05-07T01:20:21Z - Timestamp string `json:"timestamp,omitempty"` - - // version - // Example: 4.3.103 - Version string `json:"version,omitempty"` -} - -// Validate validates this get device response -func (m *GetDeviceResponse) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetDeviceResponse) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this get device response based on the context it is used -func (m *GetDeviceResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetDeviceResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetDeviceResponse) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetDeviceResponse) UnmarshalBinary(b []byte) error { - var res GetDeviceResponse - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetDeviceResponseDataItems0 get device response data items0 -// -// swagger:model GetDeviceResponseDataItems0 -type GetDeviceResponseDataItems0 struct { - - // device type - // Example: softphone - DeviceType string `json:"device_type,omitempty"` - - // enabled - // Example: true - Enabled bool `json:"enabled,omitempty"` - - // id - // Example: f9627ff1bcca2d112931ee00dcfdb0c6 - ID string `json:"id,omitempty"` - - // mac address - // Example: string - MacAddress string `json:"mac_address,omitempty"` - - // name - // Example: 2007 - Vern iPhone Personal - Name string `json:"name,omitempty"` - - // owner id - // Example: c0a881b0dfbc7fc574cb67dcaf10879f - OwnerID string `json:"owner_id,omitempty"` - - // username - // Example: user_jaemid - Username string `json:"username,omitempty"` -} - -// Validate validates this get device response data items0 -func (m *GetDeviceResponseDataItems0) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get device response data items0 based on context it is used -func (m *GetDeviceResponseDataItems0) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetDeviceResponseDataItems0) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetDeviceResponseDataItems0) UnmarshalBinary(b []byte) error { - var res GetDeviceResponseDataItems0 - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/kazoo/kazoo_models/get_kazoo_number_response.go b/api/kazoo/kazoo_models/get_kazoo_number_response.go deleted file mode 100644 index 9efb922..0000000 --- a/api/kazoo/kazoo_models/get_kazoo_number_response.go +++ /dev/null @@ -1,181 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package kazoo_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// GetKazooNumberResponse get kazoo number response -// -// swagger:model GetKazooNumberResponse -type GetKazooNumberResponse struct { - - // auth token - AuthToken string `json:"auth_token,omitempty"` - - // data - Data []*GetKazooNumberResponseDataItems0 `json:"data"` - - // node - // Example: dqZFtHthbelyE8MI6vU-LA - Node string `json:"node,omitempty"` - - // request id - // Example: b310489bd3933c740590b2dcec953de8 - RequestID string `json:"request_id,omitempty"` - - // status - // Example: success - Status string `json:"status,omitempty"` - - // timestamp - // Example: 2020-05-07T02:30:03Z - Timestamp string `json:"timestamp,omitempty"` - - // version - // Example: 4.3.103 - Version string `json:"version,omitempty"` -} - -// Validate validates this get kazoo number response -func (m *GetKazooNumberResponse) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetKazooNumberResponse) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this get kazoo number response based on the context it is used -func (m *GetKazooNumberResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetKazooNumberResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetKazooNumberResponse) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetKazooNumberResponse) UnmarshalBinary(b []byte) error { - var res GetKazooNumberResponse - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetKazooNumberResponseDataItems0 get kazoo number response data items0 -// -// swagger:model GetKazooNumberResponseDataItems0 -type GetKazooNumberResponseDataItems0 struct { - - // number - // Example: +15183486324 - Number string `json:"number,omitempty"` - - // state - // Example: discovery - State string `json:"state,omitempty"` -} - -// Validate validates this get kazoo number response data items0 -func (m *GetKazooNumberResponseDataItems0) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get kazoo number response data items0 based on context it is used -func (m *GetKazooNumberResponseDataItems0) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetKazooNumberResponseDataItems0) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetKazooNumberResponseDataItems0) UnmarshalBinary(b []byte) error { - var res GetKazooNumberResponseDataItems0 - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/kazoo/kazoo_models/get_number_response.go b/api/kazoo/kazoo_models/get_number_response.go deleted file mode 100644 index 94e893f..0000000 --- a/api/kazoo/kazoo_models/get_number_response.go +++ /dev/null @@ -1,369 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package kazoo_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// GetNumberResponse get number response -// -// swagger:model GetNumberResponse -type GetNumberResponse struct { - - // auth token - AuthToken string `json:"auth_token,omitempty"` - - // data - Data *GetNumberResponseData `json:"data,omitempty"` - - // node - // Example: dqZFtHthbelyE8MI6vU-LA - Node string `json:"node,omitempty"` - - // page size - // Example: 117 - PageSize float64 `json:"page_size,omitempty"` - - // request id - // Example: a73973839c028f42519105681482b64f - RequestID string `json:"request_id,omitempty"` - - // revision - // Example: 7c9f4f30f97ba288bad4f0f620e9e0bc - Revision string `json:"revision,omitempty"` - - // status - // Example: success - Status string `json:"status,omitempty"` - - // timestamp - // Example: 2020-05-07T01:56:53Z - Timestamp string `json:"timestamp,omitempty"` - - // version - // Example: 4.3.103 - Version string `json:"version,omitempty"` -} - -// Validate validates this get number response -func (m *GetNumberResponse) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetNumberResponse) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - if m.Data != nil { - if err := m.Data.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data") - } - return err - } - } - - return nil -} - -// ContextValidate validate this get number response based on the context it is used -func (m *GetNumberResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetNumberResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - if m.Data != nil { - if err := m.Data.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetNumberResponse) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetNumberResponse) UnmarshalBinary(b []byte) error { - var res GetNumberResponse - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetNumberResponseData get number response data -// -// swagger:model GetNumberResponseData -type GetNumberResponseData struct { - - // cascade quantity - // Example: 61 - CascadeQuantity float64 `json:"cascade_quantity,omitempty"` - - // numbers - Numbers *GetNumberResponseDataNumbers `json:"numbers,omitempty"` -} - -// Validate validates this get number response data -func (m *GetNumberResponseData) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateNumbers(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetNumberResponseData) validateNumbers(formats strfmt.Registry) error { - if swag.IsZero(m.Numbers) { // not required - return nil - } - - if m.Numbers != nil { - if err := m.Numbers.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "numbers") - } - return err - } - } - - return nil -} - -// ContextValidate validate this get number response data based on the context it is used -func (m *GetNumberResponseData) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateNumbers(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetNumberResponseData) contextValidateNumbers(ctx context.Context, formats strfmt.Registry) error { - - if m.Numbers != nil { - if err := m.Numbers.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "numbers") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetNumberResponseData) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetNumberResponseData) UnmarshalBinary(b []byte) error { - var res GetNumberResponseData - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetNumberResponseDataNumbers get number response data numbers -// -// swagger:model GetNumberResponseDataNumbers -type GetNumberResponseDataNumbers struct { - - // numberitem - Numberitem *GetNumberResponseDataNumbersNumberitem `json:"numberitem,omitempty"` -} - -// Validate validates this get number response data numbers -func (m *GetNumberResponseDataNumbers) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateNumberitem(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetNumberResponseDataNumbers) validateNumberitem(formats strfmt.Registry) error { - if swag.IsZero(m.Numberitem) { // not required - return nil - } - - if m.Numberitem != nil { - if err := m.Numberitem.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "numbers" + "." + "numberitem") - } - return err - } - } - - return nil -} - -// ContextValidate validate this get number response data numbers based on the context it is used -func (m *GetNumberResponseDataNumbers) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateNumberitem(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *GetNumberResponseDataNumbers) contextValidateNumberitem(ctx context.Context, formats strfmt.Registry) error { - - if m.Numberitem != nil { - if err := m.Numberitem.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("data" + "." + "numbers" + "." + "numberitem") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *GetNumberResponseDataNumbers) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetNumberResponseDataNumbers) UnmarshalBinary(b []byte) error { - var res GetNumberResponseDataNumbers - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// GetNumberResponseDataNumbersNumberitem get number response data numbers numberitem -// -// swagger:model GetNumberResponseDataNumbersNumberitem -type GetNumberResponseDataNumbersNumberitem struct { - - // assigned to - // Example: a66f2b7a40944b744dcc63ca6f10f47a - AssignedTo string `json:"assigned_to,omitempty"` - - // created - // Example: 63714718327 - Created float64 `json:"created,omitempty"` - - // features - // Example: ["local"] - Features []string `json:"features"` - - // features available - // Example: ["cnam","e911","force_outbound","port","prepend","ringback"] - FeaturesAvailable []string `json:"features_available"` - - // state - // Example: in_service - State string `json:"state,omitempty"` - - // updated - // Example: 63755492918 - Updated float64 `json:"updated,omitempty"` -} - -// Validate validates this get number response data numbers numberitem -func (m *GetNumberResponseDataNumbersNumberitem) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this get number response data numbers numberitem based on context it is used -func (m *GetNumberResponseDataNumbersNumberitem) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *GetNumberResponseDataNumbersNumberitem) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *GetNumberResponseDataNumbersNumberitem) UnmarshalBinary(b []byte) error { - var res GetNumberResponseDataNumbersNumberitem - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_client/pbx_user/pbx_user_client.go b/api/sfgate/sfgate_client/accounts/accounts_client.go similarity index 62% rename from api/voip/voip_client/pbx_user/pbx_user_client.go rename to api/sfgate/sfgate_client/accounts/accounts_client.go index 0137dc9..82b8da6 100644 --- a/api/voip/voip_client/pbx_user/pbx_user_client.go +++ b/api/sfgate/sfgate_client/accounts/accounts_client.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package pbx_user +package accounts // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -16,13 +16,13 @@ import ( "github.com/go-openapi/strfmt" ) -// New creates a new pbx user API client. +// New creates a new accounts API client. func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { return &Client{transport: transport, formats: formats} } /* -Client for pbx user API +Client for accounts API */ type Client struct { transport runtime.ClientTransport @@ -34,75 +34,34 @@ type ClientOption func(*runtime.ClientOperation) // ClientService is the interface for Client methods type ClientService interface { - PBXUsers(params *PBXUsersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PBXUsersOK, error) + GetAccounts(params *GetAccountsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountsOK, error) - GetPBXUsers(params *GetPBXUsersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetPBXUsersOK, error) + PostAccounts(params *PostAccountsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostAccountsOK, error) - PostPBXUsers(params *PostPBXUsersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostPBXUsersOK, error) + PutAccount(params *PutAccountParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutAccountOK, error) SetTransport(transport runtime.ClientTransport) } /* - PBXUsers updates p b x users + GetAccounts gets a list of accounts - Update fields in PBXUsers record identified by Telnexus Id + Return a list of Accounts */ -func (a *Client) PBXUsers(params *PBXUsersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PBXUsersOK, error) { +func (a *Client) GetAccounts(params *GetAccountsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountsOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewPBXUsersParams() + params = NewGetAccountsParams() } op := &runtime.ClientOperation{ - ID: "PBXUsers", - Method: "PUT", - PathPattern: "/pbxusers", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"http"}, - Params: params, - Reader: &PBXUsersReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*PBXUsersOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for PBXUsers: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -/* - GetPBXUsers gets a list of authorities - - Return a list of available PBX Users -*/ -func (a *Client) GetPBXUsers(params *GetPBXUsersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetPBXUsersOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewGetPBXUsersParams() - } - op := &runtime.ClientOperation{ - ID: "getPBXUsers", + ID: "getAccounts", Method: "GET", - PathPattern: "/pbxusers", + PathPattern: "/accounts", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &GetPBXUsersReader{formats: a.formats}, + Reader: &GetAccountsReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -115,35 +74,35 @@ func (a *Client) GetPBXUsers(params *GetPBXUsersParams, authInfo runtime.ClientA if err != nil { return nil, err } - success, ok := result.(*GetPBXUsersOK) + success, ok := result.(*GetAccountsOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getPBXUsers: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for getAccounts: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - PostPBXUsers adds new p b x users + PostAccounts adds a new account to taxnexus - Create new PBXUsers + Account record to be added */ -func (a *Client) PostPBXUsers(params *PostPBXUsersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostPBXUsersOK, error) { +func (a *Client) PostAccounts(params *PostAccountsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostAccountsOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewPostPBXUsersParams() + params = NewPostAccountsParams() } op := &runtime.ClientOperation{ - ID: "postPBXUsers", + ID: "postAccounts", Method: "POST", - PathPattern: "/pbxusers", + PathPattern: "/accounts", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &PostPBXUsersReader{formats: a.formats}, + Reader: &PostAccountsReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -156,13 +115,54 @@ func (a *Client) PostPBXUsers(params *PostPBXUsersParams, authInfo runtime.Clien if err != nil { return nil, err } - success, ok := result.(*PostPBXUsersOK) + success, ok := result.(*PostAccountsOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for postPBXUsers: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for postAccounts: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + PutAccount updates a single account + + Update a single account specified by accountId +*/ +func (a *Client) PutAccount(params *PutAccountParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutAccountOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewPutAccountParams() + } + op := &runtime.ClientOperation{ + ID: "putAccount", + Method: "PUT", + PathPattern: "/accounts", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &PutAccountReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*PutAccountOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for putAccount: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } diff --git a/api/kazoo/kazoo_client/account/get_accounts_parameters.go b/api/sfgate/sfgate_client/accounts/get_accounts_parameters.go similarity index 60% rename from api/kazoo/kazoo_client/account/get_accounts_parameters.go rename to api/sfgate/sfgate_client/accounts/get_accounts_parameters.go index b351a0b..24bc1e2 100644 --- a/api/kazoo/kazoo_client/account/get_accounts_parameters.go +++ b/api/sfgate/sfgate_client/accounts/get_accounts_parameters.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package account +package accounts // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -18,6 +18,7 @@ import ( "github.com/go-openapi/runtime" cr "github.com/go-openapi/runtime/client" "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" ) // NewGetAccountsParams creates a new GetAccountsParams object, @@ -63,8 +64,33 @@ func NewGetAccountsParamsWithHTTPClient(client *http.Client) *GetAccountsParams */ type GetAccountsParams struct { - // AccountID. - AccountID string + /* AccountID. + + Taxnexus Id of the Account to be used a record retrieval + */ + AccountID *string + + /* Active. + + Retrieve only active records? + */ + Active *bool + + /* Limit. + + How many objects to return at one time + + Format: int64 + */ + Limit *int64 + + /* Offset. + + How many objects to skip? (default 0) + + Format: int64 + */ + Offset *int64 timeout time.Duration Context context.Context @@ -120,16 +146,49 @@ func (o *GetAccountsParams) SetHTTPClient(client *http.Client) { } // WithAccountID adds the accountID to the get accounts params -func (o *GetAccountsParams) WithAccountID(accountID string) *GetAccountsParams { +func (o *GetAccountsParams) WithAccountID(accountID *string) *GetAccountsParams { o.SetAccountID(accountID) return o } // SetAccountID adds the accountId to the get accounts params -func (o *GetAccountsParams) SetAccountID(accountID string) { +func (o *GetAccountsParams) SetAccountID(accountID *string) { o.AccountID = accountID } +// WithActive adds the active to the get accounts params +func (o *GetAccountsParams) WithActive(active *bool) *GetAccountsParams { + o.SetActive(active) + return o +} + +// SetActive adds the active to the get accounts params +func (o *GetAccountsParams) SetActive(active *bool) { + o.Active = active +} + +// WithLimit adds the limit to the get accounts params +func (o *GetAccountsParams) WithLimit(limit *int64) *GetAccountsParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the get accounts params +func (o *GetAccountsParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithOffset adds the offset to the get accounts params +func (o *GetAccountsParams) WithOffset(offset *int64) *GetAccountsParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the get accounts params +func (o *GetAccountsParams) SetOffset(offset *int64) { + o.Offset = offset +} + // WriteToRequest writes these params to a swagger request func (o *GetAccountsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -138,9 +197,72 @@ func (o *GetAccountsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.R } var res []error - // path param accountId - if err := r.SetPathParam("accountId", o.AccountID); err != nil { - return err + if o.AccountID != nil { + + // query param accountId + var qrAccountID string + + if o.AccountID != nil { + qrAccountID = *o.AccountID + } + qAccountID := qrAccountID + if qAccountID != "" { + + if err := r.SetQueryParam("accountId", qAccountID); err != nil { + return err + } + } + } + + if o.Active != nil { + + // query param active + var qrActive bool + + if o.Active != nil { + qrActive = *o.Active + } + qActive := swag.FormatBool(qrActive) + if qActive != "" { + + if err := r.SetQueryParam("active", qActive); err != nil { + return err + } + } + } + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } } if len(res) > 0 { diff --git a/api/sfgate/sfgate_client/accounts/get_accounts_responses.go b/api/sfgate/sfgate_client/accounts/get_accounts_responses.go new file mode 100644 index 0000000..2e78bff --- /dev/null +++ b/api/sfgate/sfgate_client/accounts/get_accounts_responses.go @@ -0,0 +1,261 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package accounts + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// GetAccountsReader is a Reader for the GetAccounts structure. +type GetAccountsReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *GetAccountsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewGetAccountsOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewGetAccountsUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewGetAccountsForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewGetAccountsNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 422: + result := NewGetAccountsUnprocessableEntity() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewGetAccountsInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewGetAccountsOK creates a GetAccountsOK with default headers values +func NewGetAccountsOK() *GetAccountsOK { + return &GetAccountsOK{} +} + +/* GetAccountsOK describes a response with status code 200, with default header values. + +Taxnexus Response with Account objects +*/ +type GetAccountsOK struct { + Payload *sfgate_models.AccountResponse +} + +func (o *GetAccountsOK) Error() string { + return fmt.Sprintf("[GET /accounts][%d] getAccountsOK %+v", 200, o.Payload) +} +func (o *GetAccountsOK) GetPayload() *sfgate_models.AccountResponse { + return o.Payload +} + +func (o *GetAccountsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.AccountResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetAccountsUnauthorized creates a GetAccountsUnauthorized with default headers values +func NewGetAccountsUnauthorized() *GetAccountsUnauthorized { + return &GetAccountsUnauthorized{} +} + +/* GetAccountsUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type GetAccountsUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *GetAccountsUnauthorized) Error() string { + return fmt.Sprintf("[GET /accounts][%d] getAccountsUnauthorized %+v", 401, o.Payload) +} +func (o *GetAccountsUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetAccountsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetAccountsForbidden creates a GetAccountsForbidden with default headers values +func NewGetAccountsForbidden() *GetAccountsForbidden { + return &GetAccountsForbidden{} +} + +/* GetAccountsForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type GetAccountsForbidden struct { + Payload *sfgate_models.Error +} + +func (o *GetAccountsForbidden) Error() string { + return fmt.Sprintf("[GET /accounts][%d] getAccountsForbidden %+v", 403, o.Payload) +} +func (o *GetAccountsForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetAccountsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetAccountsNotFound creates a GetAccountsNotFound with default headers values +func NewGetAccountsNotFound() *GetAccountsNotFound { + return &GetAccountsNotFound{} +} + +/* GetAccountsNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type GetAccountsNotFound struct { + Payload *sfgate_models.Error +} + +func (o *GetAccountsNotFound) Error() string { + return fmt.Sprintf("[GET /accounts][%d] getAccountsNotFound %+v", 404, o.Payload) +} +func (o *GetAccountsNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetAccountsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetAccountsUnprocessableEntity creates a GetAccountsUnprocessableEntity with default headers values +func NewGetAccountsUnprocessableEntity() *GetAccountsUnprocessableEntity { + return &GetAccountsUnprocessableEntity{} +} + +/* GetAccountsUnprocessableEntity describes a response with status code 422, with default header values. + +Unprocessable Entity, likely a bad parameter +*/ +type GetAccountsUnprocessableEntity struct { + Payload *sfgate_models.Error +} + +func (o *GetAccountsUnprocessableEntity) Error() string { + return fmt.Sprintf("[GET /accounts][%d] getAccountsUnprocessableEntity %+v", 422, o.Payload) +} +func (o *GetAccountsUnprocessableEntity) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetAccountsUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetAccountsInternalServerError creates a GetAccountsInternalServerError with default headers values +func NewGetAccountsInternalServerError() *GetAccountsInternalServerError { + return &GetAccountsInternalServerError{} +} + +/* GetAccountsInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type GetAccountsInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *GetAccountsInternalServerError) Error() string { + return fmt.Sprintf("[GET /accounts][%d] getAccountsInternalServerError %+v", 500, o.Payload) +} +func (o *GetAccountsInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetAccountsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/sfgate/sfgate_client/accounts/post_accounts_parameters.go b/api/sfgate/sfgate_client/accounts/post_accounts_parameters.go new file mode 100644 index 0000000..d586bfd --- /dev/null +++ b/api/sfgate/sfgate_client/accounts/post_accounts_parameters.go @@ -0,0 +1,155 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package accounts + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// NewPostAccountsParams creates a new PostAccountsParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewPostAccountsParams() *PostAccountsParams { + return &PostAccountsParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewPostAccountsParamsWithTimeout creates a new PostAccountsParams object +// with the ability to set a timeout on a request. +func NewPostAccountsParamsWithTimeout(timeout time.Duration) *PostAccountsParams { + return &PostAccountsParams{ + timeout: timeout, + } +} + +// NewPostAccountsParamsWithContext creates a new PostAccountsParams object +// with the ability to set a context for a request. +func NewPostAccountsParamsWithContext(ctx context.Context) *PostAccountsParams { + return &PostAccountsParams{ + Context: ctx, + } +} + +// NewPostAccountsParamsWithHTTPClient creates a new PostAccountsParams object +// with the ability to set a custom HTTPClient for a request. +func NewPostAccountsParamsWithHTTPClient(client *http.Client) *PostAccountsParams { + return &PostAccountsParams{ + HTTPClient: client, + } +} + +/* PostAccountsParams contains all the parameters to send to the API endpoint + for the post accounts operation. + + Typically these are written to a http.Request. +*/ +type PostAccountsParams struct { + + /* AccountRequest. + + A request with an array of Account Objects + */ + AccountRequest *sfgate_models.AccountRequest + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the post accounts params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *PostAccountsParams) WithDefaults() *PostAccountsParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the post accounts params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *PostAccountsParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the post accounts params +func (o *PostAccountsParams) WithTimeout(timeout time.Duration) *PostAccountsParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the post accounts params +func (o *PostAccountsParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the post accounts params +func (o *PostAccountsParams) WithContext(ctx context.Context) *PostAccountsParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the post accounts params +func (o *PostAccountsParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the post accounts params +func (o *PostAccountsParams) WithHTTPClient(client *http.Client) *PostAccountsParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the post accounts params +func (o *PostAccountsParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithAccountRequest adds the accountRequest to the post accounts params +func (o *PostAccountsParams) WithAccountRequest(accountRequest *sfgate_models.AccountRequest) *PostAccountsParams { + o.SetAccountRequest(accountRequest) + return o +} + +// SetAccountRequest adds the accountRequest to the post accounts params +func (o *PostAccountsParams) SetAccountRequest(accountRequest *sfgate_models.AccountRequest) { + o.AccountRequest = accountRequest +} + +// WriteToRequest writes these params to a swagger request +func (o *PostAccountsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.AccountRequest != nil { + if err := r.SetBodyParam(o.AccountRequest); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/accounts/post_accounts_responses.go b/api/sfgate/sfgate_client/accounts/post_accounts_responses.go new file mode 100644 index 0000000..f56be14 --- /dev/null +++ b/api/sfgate/sfgate_client/accounts/post_accounts_responses.go @@ -0,0 +1,223 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package accounts + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// PostAccountsReader is a Reader for the PostAccounts structure. +type PostAccountsReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *PostAccountsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewPostAccountsOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewPostAccountsUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewPostAccountsForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewPostAccountsNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewPostAccountsInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewPostAccountsOK creates a PostAccountsOK with default headers values +func NewPostAccountsOK() *PostAccountsOK { + return &PostAccountsOK{} +} + +/* PostAccountsOK describes a response with status code 200, with default header values. + +Taxnexus Response with Account objects +*/ +type PostAccountsOK struct { + Payload *sfgate_models.AccountResponse +} + +func (o *PostAccountsOK) Error() string { + return fmt.Sprintf("[POST /accounts][%d] postAccountsOK %+v", 200, o.Payload) +} +func (o *PostAccountsOK) GetPayload() *sfgate_models.AccountResponse { + return o.Payload +} + +func (o *PostAccountsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.AccountResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostAccountsUnauthorized creates a PostAccountsUnauthorized with default headers values +func NewPostAccountsUnauthorized() *PostAccountsUnauthorized { + return &PostAccountsUnauthorized{} +} + +/* PostAccountsUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type PostAccountsUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *PostAccountsUnauthorized) Error() string { + return fmt.Sprintf("[POST /accounts][%d] postAccountsUnauthorized %+v", 401, o.Payload) +} +func (o *PostAccountsUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PostAccountsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostAccountsForbidden creates a PostAccountsForbidden with default headers values +func NewPostAccountsForbidden() *PostAccountsForbidden { + return &PostAccountsForbidden{} +} + +/* PostAccountsForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type PostAccountsForbidden struct { + Payload *sfgate_models.Error +} + +func (o *PostAccountsForbidden) Error() string { + return fmt.Sprintf("[POST /accounts][%d] postAccountsForbidden %+v", 403, o.Payload) +} +func (o *PostAccountsForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PostAccountsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostAccountsNotFound creates a PostAccountsNotFound with default headers values +func NewPostAccountsNotFound() *PostAccountsNotFound { + return &PostAccountsNotFound{} +} + +/* PostAccountsNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type PostAccountsNotFound struct { + Payload *sfgate_models.Error +} + +func (o *PostAccountsNotFound) Error() string { + return fmt.Sprintf("[POST /accounts][%d] postAccountsNotFound %+v", 404, o.Payload) +} +func (o *PostAccountsNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PostAccountsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostAccountsInternalServerError creates a PostAccountsInternalServerError with default headers values +func NewPostAccountsInternalServerError() *PostAccountsInternalServerError { + return &PostAccountsInternalServerError{} +} + +/* PostAccountsInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type PostAccountsInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *PostAccountsInternalServerError) Error() string { + return fmt.Sprintf("[POST /accounts][%d] postAccountsInternalServerError %+v", 500, o.Payload) +} +func (o *PostAccountsInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PostAccountsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/sfgate/sfgate_client/accounts/put_account_parameters.go b/api/sfgate/sfgate_client/accounts/put_account_parameters.go new file mode 100644 index 0000000..1102d10 --- /dev/null +++ b/api/sfgate/sfgate_client/accounts/put_account_parameters.go @@ -0,0 +1,155 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package accounts + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// NewPutAccountParams creates a new PutAccountParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewPutAccountParams() *PutAccountParams { + return &PutAccountParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewPutAccountParamsWithTimeout creates a new PutAccountParams object +// with the ability to set a timeout on a request. +func NewPutAccountParamsWithTimeout(timeout time.Duration) *PutAccountParams { + return &PutAccountParams{ + timeout: timeout, + } +} + +// NewPutAccountParamsWithContext creates a new PutAccountParams object +// with the ability to set a context for a request. +func NewPutAccountParamsWithContext(ctx context.Context) *PutAccountParams { + return &PutAccountParams{ + Context: ctx, + } +} + +// NewPutAccountParamsWithHTTPClient creates a new PutAccountParams object +// with the ability to set a custom HTTPClient for a request. +func NewPutAccountParamsWithHTTPClient(client *http.Client) *PutAccountParams { + return &PutAccountParams{ + HTTPClient: client, + } +} + +/* PutAccountParams contains all the parameters to send to the API endpoint + for the put account operation. + + Typically these are written to a http.Request. +*/ +type PutAccountParams struct { + + /* AccountRequest. + + A request with an array of Account Objects + */ + AccountRequest *sfgate_models.AccountRequest + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the put account params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *PutAccountParams) WithDefaults() *PutAccountParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the put account params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *PutAccountParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the put account params +func (o *PutAccountParams) WithTimeout(timeout time.Duration) *PutAccountParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the put account params +func (o *PutAccountParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the put account params +func (o *PutAccountParams) WithContext(ctx context.Context) *PutAccountParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the put account params +func (o *PutAccountParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the put account params +func (o *PutAccountParams) WithHTTPClient(client *http.Client) *PutAccountParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the put account params +func (o *PutAccountParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithAccountRequest adds the accountRequest to the put account params +func (o *PutAccountParams) WithAccountRequest(accountRequest *sfgate_models.AccountRequest) *PutAccountParams { + o.SetAccountRequest(accountRequest) + return o +} + +// SetAccountRequest adds the accountRequest to the put account params +func (o *PutAccountParams) SetAccountRequest(accountRequest *sfgate_models.AccountRequest) { + o.AccountRequest = accountRequest +} + +// WriteToRequest writes these params to a swagger request +func (o *PutAccountParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.AccountRequest != nil { + if err := r.SetBodyParam(o.AccountRequest); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/accounts/put_account_responses.go b/api/sfgate/sfgate_client/accounts/put_account_responses.go new file mode 100644 index 0000000..8f44bd3 --- /dev/null +++ b/api/sfgate/sfgate_client/accounts/put_account_responses.go @@ -0,0 +1,223 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package accounts + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// PutAccountReader is a Reader for the PutAccount structure. +type PutAccountReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *PutAccountReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewPutAccountOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewPutAccountUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewPutAccountForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewPutAccountNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewPutAccountInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewPutAccountOK creates a PutAccountOK with default headers values +func NewPutAccountOK() *PutAccountOK { + return &PutAccountOK{} +} + +/* PutAccountOK describes a response with status code 200, with default header values. + +Taxnexus Response with Account objects +*/ +type PutAccountOK struct { + Payload *sfgate_models.AccountResponse +} + +func (o *PutAccountOK) Error() string { + return fmt.Sprintf("[PUT /accounts][%d] putAccountOK %+v", 200, o.Payload) +} +func (o *PutAccountOK) GetPayload() *sfgate_models.AccountResponse { + return o.Payload +} + +func (o *PutAccountOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.AccountResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutAccountUnauthorized creates a PutAccountUnauthorized with default headers values +func NewPutAccountUnauthorized() *PutAccountUnauthorized { + return &PutAccountUnauthorized{} +} + +/* PutAccountUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type PutAccountUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *PutAccountUnauthorized) Error() string { + return fmt.Sprintf("[PUT /accounts][%d] putAccountUnauthorized %+v", 401, o.Payload) +} +func (o *PutAccountUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutAccountUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutAccountForbidden creates a PutAccountForbidden with default headers values +func NewPutAccountForbidden() *PutAccountForbidden { + return &PutAccountForbidden{} +} + +/* PutAccountForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type PutAccountForbidden struct { + Payload *sfgate_models.Error +} + +func (o *PutAccountForbidden) Error() string { + return fmt.Sprintf("[PUT /accounts][%d] putAccountForbidden %+v", 403, o.Payload) +} +func (o *PutAccountForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutAccountForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutAccountNotFound creates a PutAccountNotFound with default headers values +func NewPutAccountNotFound() *PutAccountNotFound { + return &PutAccountNotFound{} +} + +/* PutAccountNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type PutAccountNotFound struct { + Payload *sfgate_models.Error +} + +func (o *PutAccountNotFound) Error() string { + return fmt.Sprintf("[PUT /accounts][%d] putAccountNotFound %+v", 404, o.Payload) +} +func (o *PutAccountNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutAccountNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutAccountInternalServerError creates a PutAccountInternalServerError with default headers values +func NewPutAccountInternalServerError() *PutAccountInternalServerError { + return &PutAccountInternalServerError{} +} + +/* PutAccountInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type PutAccountInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *PutAccountInternalServerError) Error() string { + return fmt.Sprintf("[PUT /accounts][%d] putAccountInternalServerError %+v", 500, o.Payload) +} +func (o *PutAccountInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutAccountInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/kazoo/kazoo_client/cdr/cdr_client.go b/api/sfgate/sfgate_client/companies/companies_client.go similarity index 65% rename from api/kazoo/kazoo_client/cdr/cdr_client.go rename to api/sfgate/sfgate_client/companies/companies_client.go index 8bfea6d..4ec68b1 100644 --- a/api/kazoo/kazoo_client/cdr/cdr_client.go +++ b/api/sfgate/sfgate_client/companies/companies_client.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package cdr +package companies // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -16,13 +16,13 @@ import ( "github.com/go-openapi/strfmt" ) -// New creates a new cdr API client. +// New creates a new companies API client. func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { return &Client{transport: transport, formats: formats} } /* -Client for cdr API +Client for companies API */ type Client struct { transport runtime.ClientTransport @@ -34,28 +34,30 @@ type ClientOption func(*runtime.ClientOperation) // ClientService is the interface for Client methods type ClientService interface { - GetAccountCDRs(params *GetAccountCDRsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountCDRsOK, error) + GetCompanies(params *GetCompaniesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetCompaniesOK, error) SetTransport(transport runtime.ClientTransport) } /* - GetAccountCDRs get account c d rs API + GetCompanies gets a company record + + Retrieve a Company record from the datastore */ -func (a *Client) GetAccountCDRs(params *GetAccountCDRsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountCDRsOK, error) { +func (a *Client) GetCompanies(params *GetCompaniesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetCompaniesOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewGetAccountCDRsParams() + params = NewGetCompaniesParams() } op := &runtime.ClientOperation{ - ID: "getAccountCDRs", + ID: "getCompanies", Method: "GET", - PathPattern: "/accounts/{accountId}/cdrs", + PathPattern: "/companies", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"https"}, + Schemes: []string{"http"}, Params: params, - Reader: &GetAccountCDRsReader{formats: a.formats}, + Reader: &GetCompaniesReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -68,13 +70,13 @@ func (a *Client) GetAccountCDRs(params *GetAccountCDRsParams, authInfo runtime.C if err != nil { return nil, err } - success, ok := result.(*GetAccountCDRsOK) + success, ok := result.(*GetCompaniesOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getAccountCDRs: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for getCompanies: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } diff --git a/api/sfgate/sfgate_client/companies/get_companies_parameters.go b/api/sfgate/sfgate_client/companies/get_companies_parameters.go new file mode 100644 index 0000000..668862a --- /dev/null +++ b/api/sfgate/sfgate_client/companies/get_companies_parameters.go @@ -0,0 +1,238 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package companies + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewGetCompaniesParams creates a new GetCompaniesParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewGetCompaniesParams() *GetCompaniesParams { + return &GetCompaniesParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewGetCompaniesParamsWithTimeout creates a new GetCompaniesParams object +// with the ability to set a timeout on a request. +func NewGetCompaniesParamsWithTimeout(timeout time.Duration) *GetCompaniesParams { + return &GetCompaniesParams{ + timeout: timeout, + } +} + +// NewGetCompaniesParamsWithContext creates a new GetCompaniesParams object +// with the ability to set a context for a request. +func NewGetCompaniesParamsWithContext(ctx context.Context) *GetCompaniesParams { + return &GetCompaniesParams{ + Context: ctx, + } +} + +// NewGetCompaniesParamsWithHTTPClient creates a new GetCompaniesParams object +// with the ability to set a custom HTTPClient for a request. +func NewGetCompaniesParamsWithHTTPClient(client *http.Client) *GetCompaniesParams { + return &GetCompaniesParams{ + HTTPClient: client, + } +} + +/* GetCompaniesParams contains all the parameters to send to the API endpoint + for the get companies operation. + + Typically these are written to a http.Request. +*/ +type GetCompaniesParams struct { + + /* CompanyID. + + Taxnexus Id of the Company to be retrieved + */ + CompanyID *string + + /* Limit. + + How many objects to return at one time + + Format: int64 + */ + Limit *int64 + + /* Offset. + + How many objects to skip? (default 0) + + Format: int64 + */ + Offset *int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the get companies params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *GetCompaniesParams) WithDefaults() *GetCompaniesParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the get companies params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *GetCompaniesParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the get companies params +func (o *GetCompaniesParams) WithTimeout(timeout time.Duration) *GetCompaniesParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the get companies params +func (o *GetCompaniesParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the get companies params +func (o *GetCompaniesParams) WithContext(ctx context.Context) *GetCompaniesParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the get companies params +func (o *GetCompaniesParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the get companies params +func (o *GetCompaniesParams) WithHTTPClient(client *http.Client) *GetCompaniesParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the get companies params +func (o *GetCompaniesParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithCompanyID adds the companyID to the get companies params +func (o *GetCompaniesParams) WithCompanyID(companyID *string) *GetCompaniesParams { + o.SetCompanyID(companyID) + return o +} + +// SetCompanyID adds the companyId to the get companies params +func (o *GetCompaniesParams) SetCompanyID(companyID *string) { + o.CompanyID = companyID +} + +// WithLimit adds the limit to the get companies params +func (o *GetCompaniesParams) WithLimit(limit *int64) *GetCompaniesParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the get companies params +func (o *GetCompaniesParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithOffset adds the offset to the get companies params +func (o *GetCompaniesParams) WithOffset(offset *int64) *GetCompaniesParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the get companies params +func (o *GetCompaniesParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WriteToRequest writes these params to a swagger request +func (o *GetCompaniesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.CompanyID != nil { + + // query param companyId + var qrCompanyID string + + if o.CompanyID != nil { + qrCompanyID = *o.CompanyID + } + qCompanyID := qrCompanyID + if qCompanyID != "" { + + if err := r.SetQueryParam("companyId", qCompanyID); err != nil { + return err + } + } + } + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/companies/get_companies_responses.go b/api/sfgate/sfgate_client/companies/get_companies_responses.go new file mode 100644 index 0000000..b040c15 --- /dev/null +++ b/api/sfgate/sfgate_client/companies/get_companies_responses.go @@ -0,0 +1,261 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package companies + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// GetCompaniesReader is a Reader for the GetCompanies structure. +type GetCompaniesReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *GetCompaniesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewGetCompaniesOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewGetCompaniesUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewGetCompaniesForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewGetCompaniesNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 422: + result := NewGetCompaniesUnprocessableEntity() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewGetCompaniesInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewGetCompaniesOK creates a GetCompaniesOK with default headers values +func NewGetCompaniesOK() *GetCompaniesOK { + return &GetCompaniesOK{} +} + +/* GetCompaniesOK describes a response with status code 200, with default header values. + +Taxnexus Response with Company objects +*/ +type GetCompaniesOK struct { + Payload *sfgate_models.CompanyResponse +} + +func (o *GetCompaniesOK) Error() string { + return fmt.Sprintf("[GET /companies][%d] getCompaniesOK %+v", 200, o.Payload) +} +func (o *GetCompaniesOK) GetPayload() *sfgate_models.CompanyResponse { + return o.Payload +} + +func (o *GetCompaniesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.CompanyResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetCompaniesUnauthorized creates a GetCompaniesUnauthorized with default headers values +func NewGetCompaniesUnauthorized() *GetCompaniesUnauthorized { + return &GetCompaniesUnauthorized{} +} + +/* GetCompaniesUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type GetCompaniesUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *GetCompaniesUnauthorized) Error() string { + return fmt.Sprintf("[GET /companies][%d] getCompaniesUnauthorized %+v", 401, o.Payload) +} +func (o *GetCompaniesUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetCompaniesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetCompaniesForbidden creates a GetCompaniesForbidden with default headers values +func NewGetCompaniesForbidden() *GetCompaniesForbidden { + return &GetCompaniesForbidden{} +} + +/* GetCompaniesForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type GetCompaniesForbidden struct { + Payload *sfgate_models.Error +} + +func (o *GetCompaniesForbidden) Error() string { + return fmt.Sprintf("[GET /companies][%d] getCompaniesForbidden %+v", 403, o.Payload) +} +func (o *GetCompaniesForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetCompaniesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetCompaniesNotFound creates a GetCompaniesNotFound with default headers values +func NewGetCompaniesNotFound() *GetCompaniesNotFound { + return &GetCompaniesNotFound{} +} + +/* GetCompaniesNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type GetCompaniesNotFound struct { + Payload *sfgate_models.Error +} + +func (o *GetCompaniesNotFound) Error() string { + return fmt.Sprintf("[GET /companies][%d] getCompaniesNotFound %+v", 404, o.Payload) +} +func (o *GetCompaniesNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetCompaniesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetCompaniesUnprocessableEntity creates a GetCompaniesUnprocessableEntity with default headers values +func NewGetCompaniesUnprocessableEntity() *GetCompaniesUnprocessableEntity { + return &GetCompaniesUnprocessableEntity{} +} + +/* GetCompaniesUnprocessableEntity describes a response with status code 422, with default header values. + +Unprocessable Entity, likely a bad parameter +*/ +type GetCompaniesUnprocessableEntity struct { + Payload *sfgate_models.Error +} + +func (o *GetCompaniesUnprocessableEntity) Error() string { + return fmt.Sprintf("[GET /companies][%d] getCompaniesUnprocessableEntity %+v", 422, o.Payload) +} +func (o *GetCompaniesUnprocessableEntity) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetCompaniesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetCompaniesInternalServerError creates a GetCompaniesInternalServerError with default headers values +func NewGetCompaniesInternalServerError() *GetCompaniesInternalServerError { + return &GetCompaniesInternalServerError{} +} + +/* GetCompaniesInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type GetCompaniesInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *GetCompaniesInternalServerError) Error() string { + return fmt.Sprintf("[GET /companies][%d] getCompaniesInternalServerError %+v", 500, o.Payload) +} +func (o *GetCompaniesInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetCompaniesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/cloud/cloud_client/hub/hub_client.go b/api/sfgate/sfgate_client/contacts/contacts_client.go similarity index 57% rename from api/cloud/cloud_client/hub/hub_client.go rename to api/sfgate/sfgate_client/contacts/contacts_client.go index 0d1a617..3de63a8 100644 --- a/api/cloud/cloud_client/hub/hub_client.go +++ b/api/sfgate/sfgate_client/contacts/contacts_client.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package hub +package contacts // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -16,13 +16,13 @@ import ( "github.com/go-openapi/strfmt" ) -// New creates a new hub API client. +// New creates a new contacts API client. func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { return &Client{transport: transport, formats: formats} } /* -Client for hub API +Client for contacts API */ type Client struct { transport runtime.ClientTransport @@ -34,36 +34,36 @@ type ClientOption func(*runtime.ClientOperation) // ClientService is the interface for Client methods type ClientService interface { - DeleteHub(params *DeleteHubParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*DeleteHubOK, error) + DeleteContact(params *DeleteContactParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*DeleteContactOK, error) - GetHubs(params *GetHubsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetHubsOK, error) + GetContacts(params *GetContactsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetContactsOK, error) - PostHubs(params *PostHubsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostHubsOK, error) + PostContacts(params *PostContactsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostContactsOK, error) - PutHub(params *PutHubParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutHubOK, error) + PutContacts(params *PutContactsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutContactsOK, error) SetTransport(transport runtime.ClientTransport) } /* - DeleteHub deletes an hub + DeleteContact deletes a contact - Delete Telnexus Hub record + Delete Taxnexus Contact record */ -func (a *Client) DeleteHub(params *DeleteHubParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*DeleteHubOK, error) { +func (a *Client) DeleteContact(params *DeleteContactParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*DeleteContactOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewDeleteHubParams() + params = NewDeleteContactParams() } op := &runtime.ClientOperation{ - ID: "deleteHub", + ID: "deleteContact", Method: "DELETE", - PathPattern: "/hubs", + PathPattern: "/contacts", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &DeleteHubReader{formats: a.formats}, + Reader: &DeleteContactReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -76,35 +76,35 @@ func (a *Client) DeleteHub(params *DeleteHubParams, authInfo runtime.ClientAuthI if err != nil { return nil, err } - success, ok := result.(*DeleteHubOK) + success, ok := result.(*DeleteContactOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for deleteHub: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for deleteContact: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - GetHubs gets a list of accounts + GetContacts gets a list of contacts - Return a list of all available Hubs + Return a list of all available Contacts */ -func (a *Client) GetHubs(params *GetHubsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetHubsOK, error) { +func (a *Client) GetContacts(params *GetContactsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetContactsOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewGetHubsParams() + params = NewGetContactsParams() } op := &runtime.ClientOperation{ - ID: "getHubs", + ID: "getContacts", Method: "GET", - PathPattern: "/hubs", + PathPattern: "/contacts", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &GetHubsReader{formats: a.formats}, + Reader: &GetContactsReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -117,35 +117,35 @@ func (a *Client) GetHubs(params *GetHubsParams, authInfo runtime.ClientAuthInfoW if err != nil { return nil, err } - success, ok := result.(*GetHubsOK) + success, ok := result.(*GetContactsOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getHubs: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for getContacts: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - PostHubs adds a new account to telnexus + PostContacts adds new contacts - Hub record to be added + Contact record to be added */ -func (a *Client) PostHubs(params *PostHubsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostHubsOK, error) { +func (a *Client) PostContacts(params *PostContactsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostContactsOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewPostHubsParams() + params = NewPostContactsParams() } op := &runtime.ClientOperation{ - ID: "postHubs", + ID: "postContacts", Method: "POST", - PathPattern: "/hubs", + PathPattern: "/contacts", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &PostHubsReader{formats: a.formats}, + Reader: &PostContactsReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -158,35 +158,35 @@ func (a *Client) PostHubs(params *PostHubsParams, authInfo runtime.ClientAuthInf if err != nil { return nil, err } - success, ok := result.(*PostHubsOK) + success, ok := result.(*PostContactsOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for postHubs: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for postContacts: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - PutHub updates a single account + PutContacts updates contact - Update Hubs + Update Contact records */ -func (a *Client) PutHub(params *PutHubParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutHubOK, error) { +func (a *Client) PutContacts(params *PutContactsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutContactsOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewPutHubParams() + params = NewPutContactsParams() } op := &runtime.ClientOperation{ - ID: "putHub", + ID: "putContacts", Method: "PUT", - PathPattern: "/hubs", + PathPattern: "/contacts", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &PutHubReader{formats: a.formats}, + Reader: &PutContactsReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -199,13 +199,13 @@ func (a *Client) PutHub(params *PutHubParams, authInfo runtime.ClientAuthInfoWri if err != nil { return nil, err } - success, ok := result.(*PutHubOK) + success, ok := result.(*PutContactsOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for putHub: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for putContacts: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } diff --git a/api/sfgate/sfgate_client/contacts/delete_contact_parameters.go b/api/sfgate/sfgate_client/contacts/delete_contact_parameters.go new file mode 100644 index 0000000..27e2cb2 --- /dev/null +++ b/api/sfgate/sfgate_client/contacts/delete_contact_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package contacts + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewDeleteContactParams creates a new DeleteContactParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewDeleteContactParams() *DeleteContactParams { + return &DeleteContactParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewDeleteContactParamsWithTimeout creates a new DeleteContactParams object +// with the ability to set a timeout on a request. +func NewDeleteContactParamsWithTimeout(timeout time.Duration) *DeleteContactParams { + return &DeleteContactParams{ + timeout: timeout, + } +} + +// NewDeleteContactParamsWithContext creates a new DeleteContactParams object +// with the ability to set a context for a request. +func NewDeleteContactParamsWithContext(ctx context.Context) *DeleteContactParams { + return &DeleteContactParams{ + Context: ctx, + } +} + +// NewDeleteContactParamsWithHTTPClient creates a new DeleteContactParams object +// with the ability to set a custom HTTPClient for a request. +func NewDeleteContactParamsWithHTTPClient(client *http.Client) *DeleteContactParams { + return &DeleteContactParams{ + HTTPClient: client, + } +} + +/* DeleteContactParams contains all the parameters to send to the API endpoint + for the delete contact operation. + + Typically these are written to a http.Request. +*/ +type DeleteContactParams struct { + + /* ContactID. + + Taxnexus Id of the Contact to be retrieved + */ + ContactID *string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the delete contact params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *DeleteContactParams) WithDefaults() *DeleteContactParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the delete contact params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *DeleteContactParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the delete contact params +func (o *DeleteContactParams) WithTimeout(timeout time.Duration) *DeleteContactParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the delete contact params +func (o *DeleteContactParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the delete contact params +func (o *DeleteContactParams) WithContext(ctx context.Context) *DeleteContactParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the delete contact params +func (o *DeleteContactParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the delete contact params +func (o *DeleteContactParams) WithHTTPClient(client *http.Client) *DeleteContactParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the delete contact params +func (o *DeleteContactParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithContactID adds the contactID to the delete contact params +func (o *DeleteContactParams) WithContactID(contactID *string) *DeleteContactParams { + o.SetContactID(contactID) + return o +} + +// SetContactID adds the contactId to the delete contact params +func (o *DeleteContactParams) SetContactID(contactID *string) { + o.ContactID = contactID +} + +// WriteToRequest writes these params to a swagger request +func (o *DeleteContactParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.ContactID != nil { + + // query param contactId + var qrContactID string + + if o.ContactID != nil { + qrContactID = *o.ContactID + } + qContactID := qrContactID + if qContactID != "" { + + if err := r.SetQueryParam("contactId", qContactID); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/contacts/delete_contact_responses.go b/api/sfgate/sfgate_client/contacts/delete_contact_responses.go new file mode 100644 index 0000000..6841a35 --- /dev/null +++ b/api/sfgate/sfgate_client/contacts/delete_contact_responses.go @@ -0,0 +1,366 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package contacts + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "fmt" + "io" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// DeleteContactReader is a Reader for the DeleteContact structure. +type DeleteContactReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *DeleteContactReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewDeleteContactOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewDeleteContactUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewDeleteContactForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewDeleteContactNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewDeleteContactInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewDeleteContactOK creates a DeleteContactOK with default headers values +func NewDeleteContactOK() *DeleteContactOK { + return &DeleteContactOK{} +} + +/* DeleteContactOK describes a response with status code 200, with default header values. + +An array of Message Objects with Delete Status +*/ +type DeleteContactOK struct { + Payload *DeleteContactOKBody +} + +func (o *DeleteContactOK) Error() string { + return fmt.Sprintf("[DELETE /contacts][%d] deleteContactOK %+v", 200, o.Payload) +} +func (o *DeleteContactOK) GetPayload() *DeleteContactOKBody { + return o.Payload +} + +func (o *DeleteContactOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(DeleteContactOKBody) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewDeleteContactUnauthorized creates a DeleteContactUnauthorized with default headers values +func NewDeleteContactUnauthorized() *DeleteContactUnauthorized { + return &DeleteContactUnauthorized{} +} + +/* DeleteContactUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type DeleteContactUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *DeleteContactUnauthorized) Error() string { + return fmt.Sprintf("[DELETE /contacts][%d] deleteContactUnauthorized %+v", 401, o.Payload) +} +func (o *DeleteContactUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *DeleteContactUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewDeleteContactForbidden creates a DeleteContactForbidden with default headers values +func NewDeleteContactForbidden() *DeleteContactForbidden { + return &DeleteContactForbidden{} +} + +/* DeleteContactForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type DeleteContactForbidden struct { + Payload *sfgate_models.Error +} + +func (o *DeleteContactForbidden) Error() string { + return fmt.Sprintf("[DELETE /contacts][%d] deleteContactForbidden %+v", 403, o.Payload) +} +func (o *DeleteContactForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *DeleteContactForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewDeleteContactNotFound creates a DeleteContactNotFound with default headers values +func NewDeleteContactNotFound() *DeleteContactNotFound { + return &DeleteContactNotFound{} +} + +/* DeleteContactNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type DeleteContactNotFound struct { + Payload *sfgate_models.Error +} + +func (o *DeleteContactNotFound) Error() string { + return fmt.Sprintf("[DELETE /contacts][%d] deleteContactNotFound %+v", 404, o.Payload) +} +func (o *DeleteContactNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *DeleteContactNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewDeleteContactInternalServerError creates a DeleteContactInternalServerError with default headers values +func NewDeleteContactInternalServerError() *DeleteContactInternalServerError { + return &DeleteContactInternalServerError{} +} + +/* DeleteContactInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type DeleteContactInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *DeleteContactInternalServerError) Error() string { + return fmt.Sprintf("[DELETE /contacts][%d] deleteContactInternalServerError %+v", 500, o.Payload) +} +func (o *DeleteContactInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *DeleteContactInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +/*DeleteContactOKBody delete contact o k body +swagger:model DeleteContactOKBody +*/ +type DeleteContactOKBody struct { + + // data + Data []*sfgate_models.Message `json:"data"` + + // meta + Meta *sfgate_models.ResponseMeta `json:"meta,omitempty"` +} + +// Validate validates this delete contact o k body +func (o *DeleteContactOKBody) Validate(formats strfmt.Registry) error { + var res []error + + if err := o.validateData(formats); err != nil { + res = append(res, err) + } + + if err := o.validateMeta(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *DeleteContactOKBody) validateData(formats strfmt.Registry) error { + if swag.IsZero(o.Data) { // not required + return nil + } + + for i := 0; i < len(o.Data); i++ { + if swag.IsZero(o.Data[i]) { // not required + continue + } + + if o.Data[i] != nil { + if err := o.Data[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("deleteContactOK" + "." + "data" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (o *DeleteContactOKBody) validateMeta(formats strfmt.Registry) error { + if swag.IsZero(o.Meta) { // not required + return nil + } + + if o.Meta != nil { + if err := o.Meta.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("deleteContactOK" + "." + "meta") + } + return err + } + } + + return nil +} + +// ContextValidate validate this delete contact o k body based on the context it is used +func (o *DeleteContactOKBody) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := o.contextValidateData(ctx, formats); err != nil { + res = append(res, err) + } + + if err := o.contextValidateMeta(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *DeleteContactOKBody) contextValidateData(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(o.Data); i++ { + + if o.Data[i] != nil { + if err := o.Data[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("deleteContactOK" + "." + "data" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (o *DeleteContactOKBody) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { + + if o.Meta != nil { + if err := o.Meta.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("deleteContactOK" + "." + "meta") + } + return err + } + } + + return nil +} + +// MarshalBinary interface implementation +func (o *DeleteContactOKBody) MarshalBinary() ([]byte, error) { + if o == nil { + return nil, nil + } + return swag.WriteJSON(o) +} + +// UnmarshalBinary interface implementation +func (o *DeleteContactOKBody) UnmarshalBinary(b []byte) error { + var res DeleteContactOKBody + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *o = res + return nil +} diff --git a/api/sfgate/sfgate_client/contacts/get_contacts_parameters.go b/api/sfgate/sfgate_client/contacts/get_contacts_parameters.go new file mode 100644 index 0000000..7152316 --- /dev/null +++ b/api/sfgate/sfgate_client/contacts/get_contacts_parameters.go @@ -0,0 +1,340 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package contacts + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewGetContactsParams creates a new GetContactsParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewGetContactsParams() *GetContactsParams { + return &GetContactsParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewGetContactsParamsWithTimeout creates a new GetContactsParams object +// with the ability to set a timeout on a request. +func NewGetContactsParamsWithTimeout(timeout time.Duration) *GetContactsParams { + return &GetContactsParams{ + timeout: timeout, + } +} + +// NewGetContactsParamsWithContext creates a new GetContactsParams object +// with the ability to set a context for a request. +func NewGetContactsParamsWithContext(ctx context.Context) *GetContactsParams { + return &GetContactsParams{ + Context: ctx, + } +} + +// NewGetContactsParamsWithHTTPClient creates a new GetContactsParams object +// with the ability to set a custom HTTPClient for a request. +func NewGetContactsParamsWithHTTPClient(client *http.Client) *GetContactsParams { + return &GetContactsParams{ + HTTPClient: client, + } +} + +/* GetContactsParams contains all the parameters to send to the API endpoint + for the get contacts operation. + + Typically these are written to a http.Request. +*/ +type GetContactsParams struct { + + /* AccountID. + + Taxnexus Id of the Account to be used a record retrieval + */ + AccountID *string + + /* Active. + + Retrieve only active records? + */ + Active *bool + + /* CompanyID. + + Taxnexus Id of the Company to be retrieved + */ + CompanyID *string + + /* ContactID. + + Taxnexus Id of the Contact to be retrieved + */ + ContactID *string + + /* Limit. + + How many objects to return at one time + + Format: int64 + */ + Limit *int64 + + /* Offset. + + How many objects to skip? (default 0) + + Format: int64 + */ + Offset *int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the get contacts params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *GetContactsParams) WithDefaults() *GetContactsParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the get contacts params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *GetContactsParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the get contacts params +func (o *GetContactsParams) WithTimeout(timeout time.Duration) *GetContactsParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the get contacts params +func (o *GetContactsParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the get contacts params +func (o *GetContactsParams) WithContext(ctx context.Context) *GetContactsParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the get contacts params +func (o *GetContactsParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the get contacts params +func (o *GetContactsParams) WithHTTPClient(client *http.Client) *GetContactsParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the get contacts params +func (o *GetContactsParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithAccountID adds the accountID to the get contacts params +func (o *GetContactsParams) WithAccountID(accountID *string) *GetContactsParams { + o.SetAccountID(accountID) + return o +} + +// SetAccountID adds the accountId to the get contacts params +func (o *GetContactsParams) SetAccountID(accountID *string) { + o.AccountID = accountID +} + +// WithActive adds the active to the get contacts params +func (o *GetContactsParams) WithActive(active *bool) *GetContactsParams { + o.SetActive(active) + return o +} + +// SetActive adds the active to the get contacts params +func (o *GetContactsParams) SetActive(active *bool) { + o.Active = active +} + +// WithCompanyID adds the companyID to the get contacts params +func (o *GetContactsParams) WithCompanyID(companyID *string) *GetContactsParams { + o.SetCompanyID(companyID) + return o +} + +// SetCompanyID adds the companyId to the get contacts params +func (o *GetContactsParams) SetCompanyID(companyID *string) { + o.CompanyID = companyID +} + +// WithContactID adds the contactID to the get contacts params +func (o *GetContactsParams) WithContactID(contactID *string) *GetContactsParams { + o.SetContactID(contactID) + return o +} + +// SetContactID adds the contactId to the get contacts params +func (o *GetContactsParams) SetContactID(contactID *string) { + o.ContactID = contactID +} + +// WithLimit adds the limit to the get contacts params +func (o *GetContactsParams) WithLimit(limit *int64) *GetContactsParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the get contacts params +func (o *GetContactsParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithOffset adds the offset to the get contacts params +func (o *GetContactsParams) WithOffset(offset *int64) *GetContactsParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the get contacts params +func (o *GetContactsParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WriteToRequest writes these params to a swagger request +func (o *GetContactsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.AccountID != nil { + + // query param accountId + var qrAccountID string + + if o.AccountID != nil { + qrAccountID = *o.AccountID + } + qAccountID := qrAccountID + if qAccountID != "" { + + if err := r.SetQueryParam("accountId", qAccountID); err != nil { + return err + } + } + } + + if o.Active != nil { + + // query param active + var qrActive bool + + if o.Active != nil { + qrActive = *o.Active + } + qActive := swag.FormatBool(qrActive) + if qActive != "" { + + if err := r.SetQueryParam("active", qActive); err != nil { + return err + } + } + } + + if o.CompanyID != nil { + + // query param companyId + var qrCompanyID string + + if o.CompanyID != nil { + qrCompanyID = *o.CompanyID + } + qCompanyID := qrCompanyID + if qCompanyID != "" { + + if err := r.SetQueryParam("companyId", qCompanyID); err != nil { + return err + } + } + } + + if o.ContactID != nil { + + // query param contactId + var qrContactID string + + if o.ContactID != nil { + qrContactID = *o.ContactID + } + qContactID := qrContactID + if qContactID != "" { + + if err := r.SetQueryParam("contactId", qContactID); err != nil { + return err + } + } + } + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/contacts/get_contacts_responses.go b/api/sfgate/sfgate_client/contacts/get_contacts_responses.go new file mode 100644 index 0000000..be0dd8f --- /dev/null +++ b/api/sfgate/sfgate_client/contacts/get_contacts_responses.go @@ -0,0 +1,261 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package contacts + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// GetContactsReader is a Reader for the GetContacts structure. +type GetContactsReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *GetContactsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewGetContactsOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewGetContactsUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewGetContactsForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewGetContactsNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 422: + result := NewGetContactsUnprocessableEntity() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewGetContactsInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewGetContactsOK creates a GetContactsOK with default headers values +func NewGetContactsOK() *GetContactsOK { + return &GetContactsOK{} +} + +/* GetContactsOK describes a response with status code 200, with default header values. + +An array of Contact objects +*/ +type GetContactsOK struct { + Payload *sfgate_models.ContactResponse +} + +func (o *GetContactsOK) Error() string { + return fmt.Sprintf("[GET /contacts][%d] getContactsOK %+v", 200, o.Payload) +} +func (o *GetContactsOK) GetPayload() *sfgate_models.ContactResponse { + return o.Payload +} + +func (o *GetContactsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.ContactResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetContactsUnauthorized creates a GetContactsUnauthorized with default headers values +func NewGetContactsUnauthorized() *GetContactsUnauthorized { + return &GetContactsUnauthorized{} +} + +/* GetContactsUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type GetContactsUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *GetContactsUnauthorized) Error() string { + return fmt.Sprintf("[GET /contacts][%d] getContactsUnauthorized %+v", 401, o.Payload) +} +func (o *GetContactsUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetContactsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetContactsForbidden creates a GetContactsForbidden with default headers values +func NewGetContactsForbidden() *GetContactsForbidden { + return &GetContactsForbidden{} +} + +/* GetContactsForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type GetContactsForbidden struct { + Payload *sfgate_models.Error +} + +func (o *GetContactsForbidden) Error() string { + return fmt.Sprintf("[GET /contacts][%d] getContactsForbidden %+v", 403, o.Payload) +} +func (o *GetContactsForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetContactsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetContactsNotFound creates a GetContactsNotFound with default headers values +func NewGetContactsNotFound() *GetContactsNotFound { + return &GetContactsNotFound{} +} + +/* GetContactsNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type GetContactsNotFound struct { + Payload *sfgate_models.Error +} + +func (o *GetContactsNotFound) Error() string { + return fmt.Sprintf("[GET /contacts][%d] getContactsNotFound %+v", 404, o.Payload) +} +func (o *GetContactsNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetContactsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetContactsUnprocessableEntity creates a GetContactsUnprocessableEntity with default headers values +func NewGetContactsUnprocessableEntity() *GetContactsUnprocessableEntity { + return &GetContactsUnprocessableEntity{} +} + +/* GetContactsUnprocessableEntity describes a response with status code 422, with default header values. + +Unprocessable Entity, likely a bad parameter +*/ +type GetContactsUnprocessableEntity struct { + Payload *sfgate_models.Error +} + +func (o *GetContactsUnprocessableEntity) Error() string { + return fmt.Sprintf("[GET /contacts][%d] getContactsUnprocessableEntity %+v", 422, o.Payload) +} +func (o *GetContactsUnprocessableEntity) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetContactsUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetContactsInternalServerError creates a GetContactsInternalServerError with default headers values +func NewGetContactsInternalServerError() *GetContactsInternalServerError { + return &GetContactsInternalServerError{} +} + +/* GetContactsInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type GetContactsInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *GetContactsInternalServerError) Error() string { + return fmt.Sprintf("[GET /contacts][%d] getContactsInternalServerError %+v", 500, o.Payload) +} +func (o *GetContactsInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetContactsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/sfgate/sfgate_client/contacts/post_contacts_parameters.go b/api/sfgate/sfgate_client/contacts/post_contacts_parameters.go new file mode 100644 index 0000000..1035eb3 --- /dev/null +++ b/api/sfgate/sfgate_client/contacts/post_contacts_parameters.go @@ -0,0 +1,155 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package contacts + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// NewPostContactsParams creates a new PostContactsParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewPostContactsParams() *PostContactsParams { + return &PostContactsParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewPostContactsParamsWithTimeout creates a new PostContactsParams object +// with the ability to set a timeout on a request. +func NewPostContactsParamsWithTimeout(timeout time.Duration) *PostContactsParams { + return &PostContactsParams{ + timeout: timeout, + } +} + +// NewPostContactsParamsWithContext creates a new PostContactsParams object +// with the ability to set a context for a request. +func NewPostContactsParamsWithContext(ctx context.Context) *PostContactsParams { + return &PostContactsParams{ + Context: ctx, + } +} + +// NewPostContactsParamsWithHTTPClient creates a new PostContactsParams object +// with the ability to set a custom HTTPClient for a request. +func NewPostContactsParamsWithHTTPClient(client *http.Client) *PostContactsParams { + return &PostContactsParams{ + HTTPClient: client, + } +} + +/* PostContactsParams contains all the parameters to send to the API endpoint + for the post contacts operation. + + Typically these are written to a http.Request. +*/ +type PostContactsParams struct { + + /* ContactsRequest. + + An array of new Contact records + */ + ContactsRequest *sfgate_models.ContactRequest + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the post contacts params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *PostContactsParams) WithDefaults() *PostContactsParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the post contacts params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *PostContactsParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the post contacts params +func (o *PostContactsParams) WithTimeout(timeout time.Duration) *PostContactsParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the post contacts params +func (o *PostContactsParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the post contacts params +func (o *PostContactsParams) WithContext(ctx context.Context) *PostContactsParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the post contacts params +func (o *PostContactsParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the post contacts params +func (o *PostContactsParams) WithHTTPClient(client *http.Client) *PostContactsParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the post contacts params +func (o *PostContactsParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithContactsRequest adds the contactsRequest to the post contacts params +func (o *PostContactsParams) WithContactsRequest(contactsRequest *sfgate_models.ContactRequest) *PostContactsParams { + o.SetContactsRequest(contactsRequest) + return o +} + +// SetContactsRequest adds the contactsRequest to the post contacts params +func (o *PostContactsParams) SetContactsRequest(contactsRequest *sfgate_models.ContactRequest) { + o.ContactsRequest = contactsRequest +} + +// WriteToRequest writes these params to a swagger request +func (o *PostContactsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.ContactsRequest != nil { + if err := r.SetBodyParam(o.ContactsRequest); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/contacts/post_contacts_responses.go b/api/sfgate/sfgate_client/contacts/post_contacts_responses.go new file mode 100644 index 0000000..0461cd3 --- /dev/null +++ b/api/sfgate/sfgate_client/contacts/post_contacts_responses.go @@ -0,0 +1,223 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package contacts + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// PostContactsReader is a Reader for the PostContacts structure. +type PostContactsReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *PostContactsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewPostContactsOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewPostContactsUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewPostContactsForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewPostContactsNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewPostContactsInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewPostContactsOK creates a PostContactsOK with default headers values +func NewPostContactsOK() *PostContactsOK { + return &PostContactsOK{} +} + +/* PostContactsOK describes a response with status code 200, with default header values. + +An array of Contact objects +*/ +type PostContactsOK struct { + Payload *sfgate_models.ContactResponse +} + +func (o *PostContactsOK) Error() string { + return fmt.Sprintf("[POST /contacts][%d] postContactsOK %+v", 200, o.Payload) +} +func (o *PostContactsOK) GetPayload() *sfgate_models.ContactResponse { + return o.Payload +} + +func (o *PostContactsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.ContactResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostContactsUnauthorized creates a PostContactsUnauthorized with default headers values +func NewPostContactsUnauthorized() *PostContactsUnauthorized { + return &PostContactsUnauthorized{} +} + +/* PostContactsUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type PostContactsUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *PostContactsUnauthorized) Error() string { + return fmt.Sprintf("[POST /contacts][%d] postContactsUnauthorized %+v", 401, o.Payload) +} +func (o *PostContactsUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PostContactsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostContactsForbidden creates a PostContactsForbidden with default headers values +func NewPostContactsForbidden() *PostContactsForbidden { + return &PostContactsForbidden{} +} + +/* PostContactsForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type PostContactsForbidden struct { + Payload *sfgate_models.Error +} + +func (o *PostContactsForbidden) Error() string { + return fmt.Sprintf("[POST /contacts][%d] postContactsForbidden %+v", 403, o.Payload) +} +func (o *PostContactsForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PostContactsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostContactsNotFound creates a PostContactsNotFound with default headers values +func NewPostContactsNotFound() *PostContactsNotFound { + return &PostContactsNotFound{} +} + +/* PostContactsNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type PostContactsNotFound struct { + Payload *sfgate_models.Error +} + +func (o *PostContactsNotFound) Error() string { + return fmt.Sprintf("[POST /contacts][%d] postContactsNotFound %+v", 404, o.Payload) +} +func (o *PostContactsNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PostContactsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostContactsInternalServerError creates a PostContactsInternalServerError with default headers values +func NewPostContactsInternalServerError() *PostContactsInternalServerError { + return &PostContactsInternalServerError{} +} + +/* PostContactsInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type PostContactsInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *PostContactsInternalServerError) Error() string { + return fmt.Sprintf("[POST /contacts][%d] postContactsInternalServerError %+v", 500, o.Payload) +} +func (o *PostContactsInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PostContactsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/sfgate/sfgate_client/contacts/put_contacts_parameters.go b/api/sfgate/sfgate_client/contacts/put_contacts_parameters.go new file mode 100644 index 0000000..260d4a5 --- /dev/null +++ b/api/sfgate/sfgate_client/contacts/put_contacts_parameters.go @@ -0,0 +1,155 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package contacts + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// NewPutContactsParams creates a new PutContactsParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewPutContactsParams() *PutContactsParams { + return &PutContactsParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewPutContactsParamsWithTimeout creates a new PutContactsParams object +// with the ability to set a timeout on a request. +func NewPutContactsParamsWithTimeout(timeout time.Duration) *PutContactsParams { + return &PutContactsParams{ + timeout: timeout, + } +} + +// NewPutContactsParamsWithContext creates a new PutContactsParams object +// with the ability to set a context for a request. +func NewPutContactsParamsWithContext(ctx context.Context) *PutContactsParams { + return &PutContactsParams{ + Context: ctx, + } +} + +// NewPutContactsParamsWithHTTPClient creates a new PutContactsParams object +// with the ability to set a custom HTTPClient for a request. +func NewPutContactsParamsWithHTTPClient(client *http.Client) *PutContactsParams { + return &PutContactsParams{ + HTTPClient: client, + } +} + +/* PutContactsParams contains all the parameters to send to the API endpoint + for the put contacts operation. + + Typically these are written to a http.Request. +*/ +type PutContactsParams struct { + + /* ContactsRequest. + + An array of new Contact records + */ + ContactsRequest *sfgate_models.ContactRequest + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the put contacts params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *PutContactsParams) WithDefaults() *PutContactsParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the put contacts params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *PutContactsParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the put contacts params +func (o *PutContactsParams) WithTimeout(timeout time.Duration) *PutContactsParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the put contacts params +func (o *PutContactsParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the put contacts params +func (o *PutContactsParams) WithContext(ctx context.Context) *PutContactsParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the put contacts params +func (o *PutContactsParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the put contacts params +func (o *PutContactsParams) WithHTTPClient(client *http.Client) *PutContactsParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the put contacts params +func (o *PutContactsParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithContactsRequest adds the contactsRequest to the put contacts params +func (o *PutContactsParams) WithContactsRequest(contactsRequest *sfgate_models.ContactRequest) *PutContactsParams { + o.SetContactsRequest(contactsRequest) + return o +} + +// SetContactsRequest adds the contactsRequest to the put contacts params +func (o *PutContactsParams) SetContactsRequest(contactsRequest *sfgate_models.ContactRequest) { + o.ContactsRequest = contactsRequest +} + +// WriteToRequest writes these params to a swagger request +func (o *PutContactsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.ContactsRequest != nil { + if err := r.SetBodyParam(o.ContactsRequest); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/contacts/put_contacts_responses.go b/api/sfgate/sfgate_client/contacts/put_contacts_responses.go new file mode 100644 index 0000000..e46b8da --- /dev/null +++ b/api/sfgate/sfgate_client/contacts/put_contacts_responses.go @@ -0,0 +1,223 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package contacts + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// PutContactsReader is a Reader for the PutContacts structure. +type PutContactsReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *PutContactsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewPutContactsOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewPutContactsUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewPutContactsForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewPutContactsNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewPutContactsInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewPutContactsOK creates a PutContactsOK with default headers values +func NewPutContactsOK() *PutContactsOK { + return &PutContactsOK{} +} + +/* PutContactsOK describes a response with status code 200, with default header values. + +An array of Contact objects +*/ +type PutContactsOK struct { + Payload *sfgate_models.ContactResponse +} + +func (o *PutContactsOK) Error() string { + return fmt.Sprintf("[PUT /contacts][%d] putContactsOK %+v", 200, o.Payload) +} +func (o *PutContactsOK) GetPayload() *sfgate_models.ContactResponse { + return o.Payload +} + +func (o *PutContactsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.ContactResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutContactsUnauthorized creates a PutContactsUnauthorized with default headers values +func NewPutContactsUnauthorized() *PutContactsUnauthorized { + return &PutContactsUnauthorized{} +} + +/* PutContactsUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type PutContactsUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *PutContactsUnauthorized) Error() string { + return fmt.Sprintf("[PUT /contacts][%d] putContactsUnauthorized %+v", 401, o.Payload) +} +func (o *PutContactsUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutContactsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutContactsForbidden creates a PutContactsForbidden with default headers values +func NewPutContactsForbidden() *PutContactsForbidden { + return &PutContactsForbidden{} +} + +/* PutContactsForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type PutContactsForbidden struct { + Payload *sfgate_models.Error +} + +func (o *PutContactsForbidden) Error() string { + return fmt.Sprintf("[PUT /contacts][%d] putContactsForbidden %+v", 403, o.Payload) +} +func (o *PutContactsForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutContactsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutContactsNotFound creates a PutContactsNotFound with default headers values +func NewPutContactsNotFound() *PutContactsNotFound { + return &PutContactsNotFound{} +} + +/* PutContactsNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type PutContactsNotFound struct { + Payload *sfgate_models.Error +} + +func (o *PutContactsNotFound) Error() string { + return fmt.Sprintf("[PUT /contacts][%d] putContactsNotFound %+v", 404, o.Payload) +} +func (o *PutContactsNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutContactsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutContactsInternalServerError creates a PutContactsInternalServerError with default headers values +func NewPutContactsInternalServerError() *PutContactsInternalServerError { + return &PutContactsInternalServerError{} +} + +/* PutContactsInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type PutContactsInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *PutContactsInternalServerError) Error() string { + return fmt.Sprintf("[PUT /contacts][%d] putContactsInternalServerError %+v", 500, o.Payload) +} +func (o *PutContactsInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutContactsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/sfgate/sfgate_client/notebooks/get_notebooks_parameters.go b/api/sfgate/sfgate_client/notebooks/get_notebooks_parameters.go new file mode 100644 index 0000000..44129b1 --- /dev/null +++ b/api/sfgate/sfgate_client/notebooks/get_notebooks_parameters.go @@ -0,0 +1,238 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package notebooks + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewGetNotebooksParams creates a new GetNotebooksParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewGetNotebooksParams() *GetNotebooksParams { + return &GetNotebooksParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewGetNotebooksParamsWithTimeout creates a new GetNotebooksParams object +// with the ability to set a timeout on a request. +func NewGetNotebooksParamsWithTimeout(timeout time.Duration) *GetNotebooksParams { + return &GetNotebooksParams{ + timeout: timeout, + } +} + +// NewGetNotebooksParamsWithContext creates a new GetNotebooksParams object +// with the ability to set a context for a request. +func NewGetNotebooksParamsWithContext(ctx context.Context) *GetNotebooksParams { + return &GetNotebooksParams{ + Context: ctx, + } +} + +// NewGetNotebooksParamsWithHTTPClient creates a new GetNotebooksParams object +// with the ability to set a custom HTTPClient for a request. +func NewGetNotebooksParamsWithHTTPClient(client *http.Client) *GetNotebooksParams { + return &GetNotebooksParams{ + HTTPClient: client, + } +} + +/* GetNotebooksParams contains all the parameters to send to the API endpoint + for the get notebooks operation. + + Typically these are written to a http.Request. +*/ +type GetNotebooksParams struct { + + /* Limit. + + How many objects to return at one time + + Format: int64 + */ + Limit *int64 + + /* NotebookID. + + Template ID + */ + NotebookID *string + + /* Offset. + + How many objects to skip? (default 0) + + Format: int64 + */ + Offset *int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the get notebooks params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *GetNotebooksParams) WithDefaults() *GetNotebooksParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the get notebooks params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *GetNotebooksParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the get notebooks params +func (o *GetNotebooksParams) WithTimeout(timeout time.Duration) *GetNotebooksParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the get notebooks params +func (o *GetNotebooksParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the get notebooks params +func (o *GetNotebooksParams) WithContext(ctx context.Context) *GetNotebooksParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the get notebooks params +func (o *GetNotebooksParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the get notebooks params +func (o *GetNotebooksParams) WithHTTPClient(client *http.Client) *GetNotebooksParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the get notebooks params +func (o *GetNotebooksParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithLimit adds the limit to the get notebooks params +func (o *GetNotebooksParams) WithLimit(limit *int64) *GetNotebooksParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the get notebooks params +func (o *GetNotebooksParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithNotebookID adds the notebookID to the get notebooks params +func (o *GetNotebooksParams) WithNotebookID(notebookID *string) *GetNotebooksParams { + o.SetNotebookID(notebookID) + return o +} + +// SetNotebookID adds the notebookId to the get notebooks params +func (o *GetNotebooksParams) SetNotebookID(notebookID *string) { + o.NotebookID = notebookID +} + +// WithOffset adds the offset to the get notebooks params +func (o *GetNotebooksParams) WithOffset(offset *int64) *GetNotebooksParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the get notebooks params +func (o *GetNotebooksParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WriteToRequest writes these params to a swagger request +func (o *GetNotebooksParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.NotebookID != nil { + + // query param notebookId + var qrNotebookID string + + if o.NotebookID != nil { + qrNotebookID = *o.NotebookID + } + qNotebookID := qrNotebookID + if qNotebookID != "" { + + if err := r.SetQueryParam("notebookId", qNotebookID); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/notebooks/get_notebooks_responses.go b/api/sfgate/sfgate_client/notebooks/get_notebooks_responses.go new file mode 100644 index 0000000..c418870 --- /dev/null +++ b/api/sfgate/sfgate_client/notebooks/get_notebooks_responses.go @@ -0,0 +1,261 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package notebooks + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// GetNotebooksReader is a Reader for the GetNotebooks structure. +type GetNotebooksReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *GetNotebooksReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewGetNotebooksOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewGetNotebooksUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewGetNotebooksForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewGetNotebooksNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 422: + result := NewGetNotebooksUnprocessableEntity() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewGetNotebooksInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewGetNotebooksOK creates a GetNotebooksOK with default headers values +func NewGetNotebooksOK() *GetNotebooksOK { + return &GetNotebooksOK{} +} + +/* GetNotebooksOK describes a response with status code 200, with default header values. + +Taxnexus Response with Notebook objects +*/ +type GetNotebooksOK struct { + Payload *sfgate_models.NotebookResponse +} + +func (o *GetNotebooksOK) Error() string { + return fmt.Sprintf("[GET /notebooks][%d] getNotebooksOK %+v", 200, o.Payload) +} +func (o *GetNotebooksOK) GetPayload() *sfgate_models.NotebookResponse { + return o.Payload +} + +func (o *GetNotebooksOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.NotebookResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetNotebooksUnauthorized creates a GetNotebooksUnauthorized with default headers values +func NewGetNotebooksUnauthorized() *GetNotebooksUnauthorized { + return &GetNotebooksUnauthorized{} +} + +/* GetNotebooksUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type GetNotebooksUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *GetNotebooksUnauthorized) Error() string { + return fmt.Sprintf("[GET /notebooks][%d] getNotebooksUnauthorized %+v", 401, o.Payload) +} +func (o *GetNotebooksUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetNotebooksUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetNotebooksForbidden creates a GetNotebooksForbidden with default headers values +func NewGetNotebooksForbidden() *GetNotebooksForbidden { + return &GetNotebooksForbidden{} +} + +/* GetNotebooksForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type GetNotebooksForbidden struct { + Payload *sfgate_models.Error +} + +func (o *GetNotebooksForbidden) Error() string { + return fmt.Sprintf("[GET /notebooks][%d] getNotebooksForbidden %+v", 403, o.Payload) +} +func (o *GetNotebooksForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetNotebooksForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetNotebooksNotFound creates a GetNotebooksNotFound with default headers values +func NewGetNotebooksNotFound() *GetNotebooksNotFound { + return &GetNotebooksNotFound{} +} + +/* GetNotebooksNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type GetNotebooksNotFound struct { + Payload *sfgate_models.Error +} + +func (o *GetNotebooksNotFound) Error() string { + return fmt.Sprintf("[GET /notebooks][%d] getNotebooksNotFound %+v", 404, o.Payload) +} +func (o *GetNotebooksNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetNotebooksNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetNotebooksUnprocessableEntity creates a GetNotebooksUnprocessableEntity with default headers values +func NewGetNotebooksUnprocessableEntity() *GetNotebooksUnprocessableEntity { + return &GetNotebooksUnprocessableEntity{} +} + +/* GetNotebooksUnprocessableEntity describes a response with status code 422, with default header values. + +Unprocessable Entity, likely a bad parameter +*/ +type GetNotebooksUnprocessableEntity struct { + Payload *sfgate_models.Error +} + +func (o *GetNotebooksUnprocessableEntity) Error() string { + return fmt.Sprintf("[GET /notebooks][%d] getNotebooksUnprocessableEntity %+v", 422, o.Payload) +} +func (o *GetNotebooksUnprocessableEntity) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetNotebooksUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetNotebooksInternalServerError creates a GetNotebooksInternalServerError with default headers values +func NewGetNotebooksInternalServerError() *GetNotebooksInternalServerError { + return &GetNotebooksInternalServerError{} +} + +/* GetNotebooksInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type GetNotebooksInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *GetNotebooksInternalServerError) Error() string { + return fmt.Sprintf("[GET /notebooks][%d] getNotebooksInternalServerError %+v", 500, o.Payload) +} +func (o *GetNotebooksInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetNotebooksInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/voip/voip_client/endpoint/endpoint_client.go b/api/sfgate/sfgate_client/notebooks/notebooks_client.go similarity index 62% rename from api/voip/voip_client/endpoint/endpoint_client.go rename to api/sfgate/sfgate_client/notebooks/notebooks_client.go index 543cc6d..ff82b33 100644 --- a/api/voip/voip_client/endpoint/endpoint_client.go +++ b/api/sfgate/sfgate_client/notebooks/notebooks_client.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package endpoint +package notebooks // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -16,13 +16,13 @@ import ( "github.com/go-openapi/strfmt" ) -// New creates a new endpoint API client. +// New creates a new notebooks API client. func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { return &Client{transport: transport, formats: formats} } /* -Client for endpoint API +Client for notebooks API */ type Client struct { transport runtime.ClientTransport @@ -34,34 +34,34 @@ type ClientOption func(*runtime.ClientOperation) // ClientService is the interface for Client methods type ClientService interface { - GetEndpoints(params *GetEndpointsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetEndpointsOK, error) + GetNotebooks(params *GetNotebooksParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetNotebooksOK, error) - PostEndpoints(params *PostEndpointsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostEndpointsOK, error) + PostNotebooks(params *PostNotebooksParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostNotebooksOK, error) - PutEndpoints(params *PutEndpointsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutEndpointsOK, error) + PutNotebooks(params *PutNotebooksParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutNotebooksOK, error) SetTransport(transport runtime.ClientTransport) } /* - GetEndpoints gets a list of endpoints + GetNotebooks gets a list of notebooks - Return a list of available Endpoint entities + Return a list of Notebook records from the datastore */ -func (a *Client) GetEndpoints(params *GetEndpointsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetEndpointsOK, error) { +func (a *Client) GetNotebooks(params *GetNotebooksParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetNotebooksOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewGetEndpointsParams() + params = NewGetNotebooksParams() } op := &runtime.ClientOperation{ - ID: "getEndpoints", + ID: "getNotebooks", Method: "GET", - PathPattern: "/endpoints", + PathPattern: "/notebooks", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &GetEndpointsReader{formats: a.formats}, + Reader: &GetNotebooksReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -74,35 +74,35 @@ func (a *Client) GetEndpoints(params *GetEndpointsParams, authInfo runtime.Clien if err != nil { return nil, err } - success, ok := result.(*GetEndpointsOK) + success, ok := result.(*GetNotebooksOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getEndpoints: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for getNotebooks: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - PostEndpoints adds new endpoints + PostNotebooks creates new notebooks - Create new Endpoints + Create Notebooks in Taxnexus */ -func (a *Client) PostEndpoints(params *PostEndpointsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostEndpointsOK, error) { +func (a *Client) PostNotebooks(params *PostNotebooksParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostNotebooksOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewPostEndpointsParams() + params = NewPostNotebooksParams() } op := &runtime.ClientOperation{ - ID: "postEndpoints", + ID: "postNotebooks", Method: "POST", - PathPattern: "/endpoints", + PathPattern: "/notebooks", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &PostEndpointsReader{formats: a.formats}, + Reader: &PostNotebooksReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -115,35 +115,35 @@ func (a *Client) PostEndpoints(params *PostEndpointsParams, authInfo runtime.Cli if err != nil { return nil, err } - success, ok := result.(*PostEndpointsOK) + success, ok := result.(*PostNotebooksOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for postEndpoints: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for postNotebooks: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - PutEndpoints updates endpoints + PutNotebooks updates notebooks - Update fields in Endpoint records identified by Telnexus Id + Update Notebooks in Taxnexus */ -func (a *Client) PutEndpoints(params *PutEndpointsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutEndpointsOK, error) { +func (a *Client) PutNotebooks(params *PutNotebooksParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutNotebooksOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewPutEndpointsParams() + params = NewPutNotebooksParams() } op := &runtime.ClientOperation{ - ID: "putEndpoints", + ID: "putNotebooks", Method: "PUT", - PathPattern: "/endpoints", + PathPattern: "/notebooks", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &PutEndpointsReader{formats: a.formats}, + Reader: &PutNotebooksReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -156,13 +156,13 @@ func (a *Client) PutEndpoints(params *PutEndpointsParams, authInfo runtime.Clien if err != nil { return nil, err } - success, ok := result.(*PutEndpointsOK) + success, ok := result.(*PutNotebooksOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for putEndpoints: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for putNotebooks: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } diff --git a/api/sfgate/sfgate_client/notebooks/post_notebooks_parameters.go b/api/sfgate/sfgate_client/notebooks/post_notebooks_parameters.go new file mode 100644 index 0000000..88b8aba --- /dev/null +++ b/api/sfgate/sfgate_client/notebooks/post_notebooks_parameters.go @@ -0,0 +1,155 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package notebooks + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// NewPostNotebooksParams creates a new PostNotebooksParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewPostNotebooksParams() *PostNotebooksParams { + return &PostNotebooksParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewPostNotebooksParamsWithTimeout creates a new PostNotebooksParams object +// with the ability to set a timeout on a request. +func NewPostNotebooksParamsWithTimeout(timeout time.Duration) *PostNotebooksParams { + return &PostNotebooksParams{ + timeout: timeout, + } +} + +// NewPostNotebooksParamsWithContext creates a new PostNotebooksParams object +// with the ability to set a context for a request. +func NewPostNotebooksParamsWithContext(ctx context.Context) *PostNotebooksParams { + return &PostNotebooksParams{ + Context: ctx, + } +} + +// NewPostNotebooksParamsWithHTTPClient creates a new PostNotebooksParams object +// with the ability to set a custom HTTPClient for a request. +func NewPostNotebooksParamsWithHTTPClient(client *http.Client) *PostNotebooksParams { + return &PostNotebooksParams{ + HTTPClient: client, + } +} + +/* PostNotebooksParams contains all the parameters to send to the API endpoint + for the post notebooks operation. + + Typically these are written to a http.Request. +*/ +type PostNotebooksParams struct { + + /* NotebookRequest. + + An array of Notebook records + */ + NotebookRequest *sfgate_models.NotebookRequest + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the post notebooks params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *PostNotebooksParams) WithDefaults() *PostNotebooksParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the post notebooks params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *PostNotebooksParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the post notebooks params +func (o *PostNotebooksParams) WithTimeout(timeout time.Duration) *PostNotebooksParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the post notebooks params +func (o *PostNotebooksParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the post notebooks params +func (o *PostNotebooksParams) WithContext(ctx context.Context) *PostNotebooksParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the post notebooks params +func (o *PostNotebooksParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the post notebooks params +func (o *PostNotebooksParams) WithHTTPClient(client *http.Client) *PostNotebooksParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the post notebooks params +func (o *PostNotebooksParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithNotebookRequest adds the notebookRequest to the post notebooks params +func (o *PostNotebooksParams) WithNotebookRequest(notebookRequest *sfgate_models.NotebookRequest) *PostNotebooksParams { + o.SetNotebookRequest(notebookRequest) + return o +} + +// SetNotebookRequest adds the notebookRequest to the post notebooks params +func (o *PostNotebooksParams) SetNotebookRequest(notebookRequest *sfgate_models.NotebookRequest) { + o.NotebookRequest = notebookRequest +} + +// WriteToRequest writes these params to a swagger request +func (o *PostNotebooksParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.NotebookRequest != nil { + if err := r.SetBodyParam(o.NotebookRequest); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/notebooks/post_notebooks_responses.go b/api/sfgate/sfgate_client/notebooks/post_notebooks_responses.go new file mode 100644 index 0000000..0fe6229 --- /dev/null +++ b/api/sfgate/sfgate_client/notebooks/post_notebooks_responses.go @@ -0,0 +1,261 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package notebooks + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// PostNotebooksReader is a Reader for the PostNotebooks structure. +type PostNotebooksReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *PostNotebooksReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewPostNotebooksOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewPostNotebooksUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewPostNotebooksForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewPostNotebooksNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 422: + result := NewPostNotebooksUnprocessableEntity() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewPostNotebooksInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewPostNotebooksOK creates a PostNotebooksOK with default headers values +func NewPostNotebooksOK() *PostNotebooksOK { + return &PostNotebooksOK{} +} + +/* PostNotebooksOK describes a response with status code 200, with default header values. + +Taxnexus Response with Notebook objects +*/ +type PostNotebooksOK struct { + Payload *sfgate_models.NotebookResponse +} + +func (o *PostNotebooksOK) Error() string { + return fmt.Sprintf("[POST /notebooks][%d] postNotebooksOK %+v", 200, o.Payload) +} +func (o *PostNotebooksOK) GetPayload() *sfgate_models.NotebookResponse { + return o.Payload +} + +func (o *PostNotebooksOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.NotebookResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostNotebooksUnauthorized creates a PostNotebooksUnauthorized with default headers values +func NewPostNotebooksUnauthorized() *PostNotebooksUnauthorized { + return &PostNotebooksUnauthorized{} +} + +/* PostNotebooksUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type PostNotebooksUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *PostNotebooksUnauthorized) Error() string { + return fmt.Sprintf("[POST /notebooks][%d] postNotebooksUnauthorized %+v", 401, o.Payload) +} +func (o *PostNotebooksUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PostNotebooksUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostNotebooksForbidden creates a PostNotebooksForbidden with default headers values +func NewPostNotebooksForbidden() *PostNotebooksForbidden { + return &PostNotebooksForbidden{} +} + +/* PostNotebooksForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type PostNotebooksForbidden struct { + Payload *sfgate_models.Error +} + +func (o *PostNotebooksForbidden) Error() string { + return fmt.Sprintf("[POST /notebooks][%d] postNotebooksForbidden %+v", 403, o.Payload) +} +func (o *PostNotebooksForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PostNotebooksForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostNotebooksNotFound creates a PostNotebooksNotFound with default headers values +func NewPostNotebooksNotFound() *PostNotebooksNotFound { + return &PostNotebooksNotFound{} +} + +/* PostNotebooksNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type PostNotebooksNotFound struct { + Payload *sfgate_models.Error +} + +func (o *PostNotebooksNotFound) Error() string { + return fmt.Sprintf("[POST /notebooks][%d] postNotebooksNotFound %+v", 404, o.Payload) +} +func (o *PostNotebooksNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PostNotebooksNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostNotebooksUnprocessableEntity creates a PostNotebooksUnprocessableEntity with default headers values +func NewPostNotebooksUnprocessableEntity() *PostNotebooksUnprocessableEntity { + return &PostNotebooksUnprocessableEntity{} +} + +/* PostNotebooksUnprocessableEntity describes a response with status code 422, with default header values. + +Unprocessable Entity, likely a bad parameter +*/ +type PostNotebooksUnprocessableEntity struct { + Payload *sfgate_models.Error +} + +func (o *PostNotebooksUnprocessableEntity) Error() string { + return fmt.Sprintf("[POST /notebooks][%d] postNotebooksUnprocessableEntity %+v", 422, o.Payload) +} +func (o *PostNotebooksUnprocessableEntity) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PostNotebooksUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPostNotebooksInternalServerError creates a PostNotebooksInternalServerError with default headers values +func NewPostNotebooksInternalServerError() *PostNotebooksInternalServerError { + return &PostNotebooksInternalServerError{} +} + +/* PostNotebooksInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type PostNotebooksInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *PostNotebooksInternalServerError) Error() string { + return fmt.Sprintf("[POST /notebooks][%d] postNotebooksInternalServerError %+v", 500, o.Payload) +} +func (o *PostNotebooksInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PostNotebooksInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/sfgate/sfgate_client/notebooks/put_notebooks_parameters.go b/api/sfgate/sfgate_client/notebooks/put_notebooks_parameters.go new file mode 100644 index 0000000..b26e84b --- /dev/null +++ b/api/sfgate/sfgate_client/notebooks/put_notebooks_parameters.go @@ -0,0 +1,155 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package notebooks + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// NewPutNotebooksParams creates a new PutNotebooksParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewPutNotebooksParams() *PutNotebooksParams { + return &PutNotebooksParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewPutNotebooksParamsWithTimeout creates a new PutNotebooksParams object +// with the ability to set a timeout on a request. +func NewPutNotebooksParamsWithTimeout(timeout time.Duration) *PutNotebooksParams { + return &PutNotebooksParams{ + timeout: timeout, + } +} + +// NewPutNotebooksParamsWithContext creates a new PutNotebooksParams object +// with the ability to set a context for a request. +func NewPutNotebooksParamsWithContext(ctx context.Context) *PutNotebooksParams { + return &PutNotebooksParams{ + Context: ctx, + } +} + +// NewPutNotebooksParamsWithHTTPClient creates a new PutNotebooksParams object +// with the ability to set a custom HTTPClient for a request. +func NewPutNotebooksParamsWithHTTPClient(client *http.Client) *PutNotebooksParams { + return &PutNotebooksParams{ + HTTPClient: client, + } +} + +/* PutNotebooksParams contains all the parameters to send to the API endpoint + for the put notebooks operation. + + Typically these are written to a http.Request. +*/ +type PutNotebooksParams struct { + + /* NotebookRequest. + + An array of Notebook records + */ + NotebookRequest *sfgate_models.NotebookRequest + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the put notebooks params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *PutNotebooksParams) WithDefaults() *PutNotebooksParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the put notebooks params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *PutNotebooksParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the put notebooks params +func (o *PutNotebooksParams) WithTimeout(timeout time.Duration) *PutNotebooksParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the put notebooks params +func (o *PutNotebooksParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the put notebooks params +func (o *PutNotebooksParams) WithContext(ctx context.Context) *PutNotebooksParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the put notebooks params +func (o *PutNotebooksParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the put notebooks params +func (o *PutNotebooksParams) WithHTTPClient(client *http.Client) *PutNotebooksParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the put notebooks params +func (o *PutNotebooksParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithNotebookRequest adds the notebookRequest to the put notebooks params +func (o *PutNotebooksParams) WithNotebookRequest(notebookRequest *sfgate_models.NotebookRequest) *PutNotebooksParams { + o.SetNotebookRequest(notebookRequest) + return o +} + +// SetNotebookRequest adds the notebookRequest to the put notebooks params +func (o *PutNotebooksParams) SetNotebookRequest(notebookRequest *sfgate_models.NotebookRequest) { + o.NotebookRequest = notebookRequest +} + +// WriteToRequest writes these params to a swagger request +func (o *PutNotebooksParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.NotebookRequest != nil { + if err := r.SetBodyParam(o.NotebookRequest); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/notebooks/put_notebooks_responses.go b/api/sfgate/sfgate_client/notebooks/put_notebooks_responses.go new file mode 100644 index 0000000..2708c49 --- /dev/null +++ b/api/sfgate/sfgate_client/notebooks/put_notebooks_responses.go @@ -0,0 +1,261 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package notebooks + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// PutNotebooksReader is a Reader for the PutNotebooks structure. +type PutNotebooksReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *PutNotebooksReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewPutNotebooksOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewPutNotebooksUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewPutNotebooksForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewPutNotebooksNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 422: + result := NewPutNotebooksUnprocessableEntity() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewPutNotebooksInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewPutNotebooksOK creates a PutNotebooksOK with default headers values +func NewPutNotebooksOK() *PutNotebooksOK { + return &PutNotebooksOK{} +} + +/* PutNotebooksOK describes a response with status code 200, with default header values. + +Taxnexus Response with Notebook objects +*/ +type PutNotebooksOK struct { + Payload *sfgate_models.NotebookResponse +} + +func (o *PutNotebooksOK) Error() string { + return fmt.Sprintf("[PUT /notebooks][%d] putNotebooksOK %+v", 200, o.Payload) +} +func (o *PutNotebooksOK) GetPayload() *sfgate_models.NotebookResponse { + return o.Payload +} + +func (o *PutNotebooksOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.NotebookResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutNotebooksUnauthorized creates a PutNotebooksUnauthorized with default headers values +func NewPutNotebooksUnauthorized() *PutNotebooksUnauthorized { + return &PutNotebooksUnauthorized{} +} + +/* PutNotebooksUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type PutNotebooksUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *PutNotebooksUnauthorized) Error() string { + return fmt.Sprintf("[PUT /notebooks][%d] putNotebooksUnauthorized %+v", 401, o.Payload) +} +func (o *PutNotebooksUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutNotebooksUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutNotebooksForbidden creates a PutNotebooksForbidden with default headers values +func NewPutNotebooksForbidden() *PutNotebooksForbidden { + return &PutNotebooksForbidden{} +} + +/* PutNotebooksForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type PutNotebooksForbidden struct { + Payload *sfgate_models.Error +} + +func (o *PutNotebooksForbidden) Error() string { + return fmt.Sprintf("[PUT /notebooks][%d] putNotebooksForbidden %+v", 403, o.Payload) +} +func (o *PutNotebooksForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutNotebooksForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutNotebooksNotFound creates a PutNotebooksNotFound with default headers values +func NewPutNotebooksNotFound() *PutNotebooksNotFound { + return &PutNotebooksNotFound{} +} + +/* PutNotebooksNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type PutNotebooksNotFound struct { + Payload *sfgate_models.Error +} + +func (o *PutNotebooksNotFound) Error() string { + return fmt.Sprintf("[PUT /notebooks][%d] putNotebooksNotFound %+v", 404, o.Payload) +} +func (o *PutNotebooksNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutNotebooksNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutNotebooksUnprocessableEntity creates a PutNotebooksUnprocessableEntity with default headers values +func NewPutNotebooksUnprocessableEntity() *PutNotebooksUnprocessableEntity { + return &PutNotebooksUnprocessableEntity{} +} + +/* PutNotebooksUnprocessableEntity describes a response with status code 422, with default header values. + +Unprocessable Entity, likely a bad parameter +*/ +type PutNotebooksUnprocessableEntity struct { + Payload *sfgate_models.Error +} + +func (o *PutNotebooksUnprocessableEntity) Error() string { + return fmt.Sprintf("[PUT /notebooks][%d] putNotebooksUnprocessableEntity %+v", 422, o.Payload) +} +func (o *PutNotebooksUnprocessableEntity) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutNotebooksUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutNotebooksInternalServerError creates a PutNotebooksInternalServerError with default headers values +func NewPutNotebooksInternalServerError() *PutNotebooksInternalServerError { + return &PutNotebooksInternalServerError{} +} + +/* PutNotebooksInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type PutNotebooksInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *PutNotebooksInternalServerError) Error() string { + return fmt.Sprintf("[PUT /notebooks][%d] putNotebooksInternalServerError %+v", 500, o.Payload) +} +func (o *PutNotebooksInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutNotebooksInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/sfgate/sfgate_client/products/get_products_parameters.go b/api/sfgate/sfgate_client/products/get_products_parameters.go new file mode 100644 index 0000000..7fce5a5 --- /dev/null +++ b/api/sfgate/sfgate_client/products/get_products_parameters.go @@ -0,0 +1,272 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package products + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewGetProductsParams creates a new GetProductsParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewGetProductsParams() *GetProductsParams { + return &GetProductsParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewGetProductsParamsWithTimeout creates a new GetProductsParams object +// with the ability to set a timeout on a request. +func NewGetProductsParamsWithTimeout(timeout time.Duration) *GetProductsParams { + return &GetProductsParams{ + timeout: timeout, + } +} + +// NewGetProductsParamsWithContext creates a new GetProductsParams object +// with the ability to set a context for a request. +func NewGetProductsParamsWithContext(ctx context.Context) *GetProductsParams { + return &GetProductsParams{ + Context: ctx, + } +} + +// NewGetProductsParamsWithHTTPClient creates a new GetProductsParams object +// with the ability to set a custom HTTPClient for a request. +func NewGetProductsParamsWithHTTPClient(client *http.Client) *GetProductsParams { + return &GetProductsParams{ + HTTPClient: client, + } +} + +/* GetProductsParams contains all the parameters to send to the API endpoint + for the get products operation. + + Typically these are written to a http.Request. +*/ +type GetProductsParams struct { + + /* Active. + + Retrieve only active records? + */ + Active *bool + + /* Limit. + + How many objects to return at one time + + Format: int64 + */ + Limit *int64 + + /* Offset. + + How many objects to skip? (default 0) + + Format: int64 + */ + Offset *int64 + + /* ProductID. + + Taxnexus Id of the Account to be used a record retrieval + */ + ProductID *string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the get products params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *GetProductsParams) WithDefaults() *GetProductsParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the get products params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *GetProductsParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the get products params +func (o *GetProductsParams) WithTimeout(timeout time.Duration) *GetProductsParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the get products params +func (o *GetProductsParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the get products params +func (o *GetProductsParams) WithContext(ctx context.Context) *GetProductsParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the get products params +func (o *GetProductsParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the get products params +func (o *GetProductsParams) WithHTTPClient(client *http.Client) *GetProductsParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the get products params +func (o *GetProductsParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithActive adds the active to the get products params +func (o *GetProductsParams) WithActive(active *bool) *GetProductsParams { + o.SetActive(active) + return o +} + +// SetActive adds the active to the get products params +func (o *GetProductsParams) SetActive(active *bool) { + o.Active = active +} + +// WithLimit adds the limit to the get products params +func (o *GetProductsParams) WithLimit(limit *int64) *GetProductsParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the get products params +func (o *GetProductsParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithOffset adds the offset to the get products params +func (o *GetProductsParams) WithOffset(offset *int64) *GetProductsParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the get products params +func (o *GetProductsParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WithProductID adds the productID to the get products params +func (o *GetProductsParams) WithProductID(productID *string) *GetProductsParams { + o.SetProductID(productID) + return o +} + +// SetProductID adds the productId to the get products params +func (o *GetProductsParams) SetProductID(productID *string) { + o.ProductID = productID +} + +// WriteToRequest writes these params to a swagger request +func (o *GetProductsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.Active != nil { + + // query param active + var qrActive bool + + if o.Active != nil { + qrActive = *o.Active + } + qActive := swag.FormatBool(qrActive) + if qActive != "" { + + if err := r.SetQueryParam("active", qActive); err != nil { + return err + } + } + } + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if o.ProductID != nil { + + // query param productId + var qrProductID string + + if o.ProductID != nil { + qrProductID = *o.ProductID + } + qProductID := qrProductID + if qProductID != "" { + + if err := r.SetQueryParam("productId", qProductID); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/products/get_products_responses.go b/api/sfgate/sfgate_client/products/get_products_responses.go new file mode 100644 index 0000000..6b7d424 --- /dev/null +++ b/api/sfgate/sfgate_client/products/get_products_responses.go @@ -0,0 +1,261 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package products + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// GetProductsReader is a Reader for the GetProducts structure. +type GetProductsReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *GetProductsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewGetProductsOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewGetProductsUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewGetProductsForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewGetProductsNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 422: + result := NewGetProductsUnprocessableEntity() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewGetProductsInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewGetProductsOK creates a GetProductsOK with default headers values +func NewGetProductsOK() *GetProductsOK { + return &GetProductsOK{} +} + +/* GetProductsOK describes a response with status code 200, with default header values. + +An array of Product objects +*/ +type GetProductsOK struct { + Payload *sfgate_models.ProductResponse +} + +func (o *GetProductsOK) Error() string { + return fmt.Sprintf("[GET /products][%d] getProductsOK %+v", 200, o.Payload) +} +func (o *GetProductsOK) GetPayload() *sfgate_models.ProductResponse { + return o.Payload +} + +func (o *GetProductsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.ProductResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetProductsUnauthorized creates a GetProductsUnauthorized with default headers values +func NewGetProductsUnauthorized() *GetProductsUnauthorized { + return &GetProductsUnauthorized{} +} + +/* GetProductsUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type GetProductsUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *GetProductsUnauthorized) Error() string { + return fmt.Sprintf("[GET /products][%d] getProductsUnauthorized %+v", 401, o.Payload) +} +func (o *GetProductsUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetProductsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetProductsForbidden creates a GetProductsForbidden with default headers values +func NewGetProductsForbidden() *GetProductsForbidden { + return &GetProductsForbidden{} +} + +/* GetProductsForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type GetProductsForbidden struct { + Payload *sfgate_models.Error +} + +func (o *GetProductsForbidden) Error() string { + return fmt.Sprintf("[GET /products][%d] getProductsForbidden %+v", 403, o.Payload) +} +func (o *GetProductsForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetProductsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetProductsNotFound creates a GetProductsNotFound with default headers values +func NewGetProductsNotFound() *GetProductsNotFound { + return &GetProductsNotFound{} +} + +/* GetProductsNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type GetProductsNotFound struct { + Payload *sfgate_models.Error +} + +func (o *GetProductsNotFound) Error() string { + return fmt.Sprintf("[GET /products][%d] getProductsNotFound %+v", 404, o.Payload) +} +func (o *GetProductsNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetProductsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetProductsUnprocessableEntity creates a GetProductsUnprocessableEntity with default headers values +func NewGetProductsUnprocessableEntity() *GetProductsUnprocessableEntity { + return &GetProductsUnprocessableEntity{} +} + +/* GetProductsUnprocessableEntity describes a response with status code 422, with default header values. + +Unprocessable Entity, likely a bad parameter +*/ +type GetProductsUnprocessableEntity struct { + Payload *sfgate_models.Error +} + +func (o *GetProductsUnprocessableEntity) Error() string { + return fmt.Sprintf("[GET /products][%d] getProductsUnprocessableEntity %+v", 422, o.Payload) +} +func (o *GetProductsUnprocessableEntity) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetProductsUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetProductsInternalServerError creates a GetProductsInternalServerError with default headers values +func NewGetProductsInternalServerError() *GetProductsInternalServerError { + return &GetProductsInternalServerError{} +} + +/* GetProductsInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type GetProductsInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *GetProductsInternalServerError) Error() string { + return fmt.Sprintf("[GET /products][%d] getProductsInternalServerError %+v", 500, o.Payload) +} +func (o *GetProductsInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetProductsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/cloud/cloud_client/cors/cors_client.go b/api/sfgate/sfgate_client/products/products_client.go similarity index 66% rename from api/cloud/cloud_client/cors/cors_client.go rename to api/sfgate/sfgate_client/products/products_client.go index 66151a0..82bc0df 100644 --- a/api/cloud/cloud_client/cors/cors_client.go +++ b/api/sfgate/sfgate_client/products/products_client.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package cors +package products // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -16,13 +16,13 @@ import ( "github.com/go-openapi/strfmt" ) -// New creates a new cors API client. +// New creates a new products API client. func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { return &Client{transport: transport, formats: formats} } /* -Client for cors API +Client for products API */ type Client struct { transport runtime.ClientTransport @@ -34,28 +34,30 @@ type ClientOption func(*runtime.ClientOperation) // ClientService is the interface for Client methods type ClientService interface { - AccountOptions(params *AccountOptionsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*AccountOptionsOK, error) + GetProducts(params *GetProductsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetProductsOK, error) SetTransport(transport runtime.ClientTransport) } /* - AccountOptions CORS support + GetProducts gets a list of products + + Return a list of all available Products */ -func (a *Client) AccountOptions(params *AccountOptionsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*AccountOptionsOK, error) { +func (a *Client) GetProducts(params *GetProductsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetProductsOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewAccountOptionsParams() + params = NewGetProductsParams() } op := &runtime.ClientOperation{ - ID: "accountOptions", - Method: "OPTIONS", - PathPattern: "/hubs", + ID: "getProducts", + Method: "GET", + PathPattern: "/products", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &AccountOptionsReader{formats: a.formats}, + Reader: &GetProductsReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -68,13 +70,13 @@ func (a *Client) AccountOptions(params *AccountOptionsParams, authInfo runtime.C if err != nil { return nil, err } - success, ok := result.(*AccountOptionsOK) + success, ok := result.(*GetProductsOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for accountOptions: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for getProducts: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } diff --git a/api/sfgate/sfgate_client/roles/get_roles_parameters.go b/api/sfgate/sfgate_client/roles/get_roles_parameters.go new file mode 100644 index 0000000..6e65659 --- /dev/null +++ b/api/sfgate/sfgate_client/roles/get_roles_parameters.go @@ -0,0 +1,238 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package roles + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewGetRolesParams creates a new GetRolesParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewGetRolesParams() *GetRolesParams { + return &GetRolesParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewGetRolesParamsWithTimeout creates a new GetRolesParams object +// with the ability to set a timeout on a request. +func NewGetRolesParamsWithTimeout(timeout time.Duration) *GetRolesParams { + return &GetRolesParams{ + timeout: timeout, + } +} + +// NewGetRolesParamsWithContext creates a new GetRolesParams object +// with the ability to set a context for a request. +func NewGetRolesParamsWithContext(ctx context.Context) *GetRolesParams { + return &GetRolesParams{ + Context: ctx, + } +} + +// NewGetRolesParamsWithHTTPClient creates a new GetRolesParams object +// with the ability to set a custom HTTPClient for a request. +func NewGetRolesParamsWithHTTPClient(client *http.Client) *GetRolesParams { + return &GetRolesParams{ + HTTPClient: client, + } +} + +/* GetRolesParams contains all the parameters to send to the API endpoint + for the get roles operation. + + Typically these are written to a http.Request. +*/ +type GetRolesParams struct { + + /* Limit. + + How many objects to return at one time + + Format: int64 + */ + Limit *int64 + + /* Offset. + + How many objects to skip? (default 0) + + Format: int64 + */ + Offset *int64 + + /* RoleID. + + Taxnexus Id of the Role to be retrieved + */ + RoleID *string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the get roles params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *GetRolesParams) WithDefaults() *GetRolesParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the get roles params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *GetRolesParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the get roles params +func (o *GetRolesParams) WithTimeout(timeout time.Duration) *GetRolesParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the get roles params +func (o *GetRolesParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the get roles params +func (o *GetRolesParams) WithContext(ctx context.Context) *GetRolesParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the get roles params +func (o *GetRolesParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the get roles params +func (o *GetRolesParams) WithHTTPClient(client *http.Client) *GetRolesParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the get roles params +func (o *GetRolesParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithLimit adds the limit to the get roles params +func (o *GetRolesParams) WithLimit(limit *int64) *GetRolesParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the get roles params +func (o *GetRolesParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithOffset adds the offset to the get roles params +func (o *GetRolesParams) WithOffset(offset *int64) *GetRolesParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the get roles params +func (o *GetRolesParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WithRoleID adds the roleID to the get roles params +func (o *GetRolesParams) WithRoleID(roleID *string) *GetRolesParams { + o.SetRoleID(roleID) + return o +} + +// SetRoleID adds the roleId to the get roles params +func (o *GetRolesParams) SetRoleID(roleID *string) { + o.RoleID = roleID +} + +// WriteToRequest writes these params to a swagger request +func (o *GetRolesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if o.RoleID != nil { + + // query param roleId + var qrRoleID string + + if o.RoleID != nil { + qrRoleID = *o.RoleID + } + qRoleID := qrRoleID + if qRoleID != "" { + + if err := r.SetQueryParam("roleId", qRoleID); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/roles/get_roles_responses.go b/api/sfgate/sfgate_client/roles/get_roles_responses.go new file mode 100644 index 0000000..1b7c235 --- /dev/null +++ b/api/sfgate/sfgate_client/roles/get_roles_responses.go @@ -0,0 +1,261 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package roles + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// GetRolesReader is a Reader for the GetRoles structure. +type GetRolesReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *GetRolesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewGetRolesOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewGetRolesUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewGetRolesForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewGetRolesNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 422: + result := NewGetRolesUnprocessableEntity() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewGetRolesInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewGetRolesOK creates a GetRolesOK with default headers values +func NewGetRolesOK() *GetRolesOK { + return &GetRolesOK{} +} + +/* GetRolesOK describes a response with status code 200, with default header values. + +Taxnexus Response with Role objects +*/ +type GetRolesOK struct { + Payload *sfgate_models.RoleResponse +} + +func (o *GetRolesOK) Error() string { + return fmt.Sprintf("[GET /roles][%d] getRolesOK %+v", 200, o.Payload) +} +func (o *GetRolesOK) GetPayload() *sfgate_models.RoleResponse { + return o.Payload +} + +func (o *GetRolesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.RoleResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetRolesUnauthorized creates a GetRolesUnauthorized with default headers values +func NewGetRolesUnauthorized() *GetRolesUnauthorized { + return &GetRolesUnauthorized{} +} + +/* GetRolesUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type GetRolesUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *GetRolesUnauthorized) Error() string { + return fmt.Sprintf("[GET /roles][%d] getRolesUnauthorized %+v", 401, o.Payload) +} +func (o *GetRolesUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetRolesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetRolesForbidden creates a GetRolesForbidden with default headers values +func NewGetRolesForbidden() *GetRolesForbidden { + return &GetRolesForbidden{} +} + +/* GetRolesForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type GetRolesForbidden struct { + Payload *sfgate_models.Error +} + +func (o *GetRolesForbidden) Error() string { + return fmt.Sprintf("[GET /roles][%d] getRolesForbidden %+v", 403, o.Payload) +} +func (o *GetRolesForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetRolesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetRolesNotFound creates a GetRolesNotFound with default headers values +func NewGetRolesNotFound() *GetRolesNotFound { + return &GetRolesNotFound{} +} + +/* GetRolesNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type GetRolesNotFound struct { + Payload *sfgate_models.Error +} + +func (o *GetRolesNotFound) Error() string { + return fmt.Sprintf("[GET /roles][%d] getRolesNotFound %+v", 404, o.Payload) +} +func (o *GetRolesNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetRolesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetRolesUnprocessableEntity creates a GetRolesUnprocessableEntity with default headers values +func NewGetRolesUnprocessableEntity() *GetRolesUnprocessableEntity { + return &GetRolesUnprocessableEntity{} +} + +/* GetRolesUnprocessableEntity describes a response with status code 422, with default header values. + +Unprocessable Entity, likely a bad parameter +*/ +type GetRolesUnprocessableEntity struct { + Payload *sfgate_models.Error +} + +func (o *GetRolesUnprocessableEntity) Error() string { + return fmt.Sprintf("[GET /roles][%d] getRolesUnprocessableEntity %+v", 422, o.Payload) +} +func (o *GetRolesUnprocessableEntity) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetRolesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetRolesInternalServerError creates a GetRolesInternalServerError with default headers values +func NewGetRolesInternalServerError() *GetRolesInternalServerError { + return &GetRolesInternalServerError{} +} + +/* GetRolesInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type GetRolesInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *GetRolesInternalServerError) Error() string { + return fmt.Sprintf("[GET /roles][%d] getRolesInternalServerError %+v", 500, o.Payload) +} +func (o *GetRolesInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetRolesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/isp/isp_client/zone/zone_client.go b/api/sfgate/sfgate_client/roles/roles_client.go similarity index 73% rename from api/isp/isp_client/zone/zone_client.go rename to api/sfgate/sfgate_client/roles/roles_client.go index 0da6283..eaff6e0 100644 --- a/api/isp/isp_client/zone/zone_client.go +++ b/api/sfgate/sfgate_client/roles/roles_client.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package zone +package roles // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -16,13 +16,13 @@ import ( "github.com/go-openapi/strfmt" ) -// New creates a new zone API client. +// New creates a new roles API client. func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { return &Client{transport: transport, formats: formats} } /* -Client for zone API +Client for roles API */ type Client struct { transport runtime.ClientTransport @@ -34,30 +34,30 @@ type ClientOption func(*runtime.ClientOperation) // ClientService is the interface for Client methods type ClientService interface { - GetZones(params *GetZonesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetZonesOK, error) + GetRoles(params *GetRolesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetRolesOK, error) SetTransport(transport runtime.ClientTransport) } /* - GetZones gets DNS zones + GetRoles gets a list of roles - Get DNS Zones + Return a list of Roles */ -func (a *Client) GetZones(params *GetZonesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetZonesOK, error) { +func (a *Client) GetRoles(params *GetRolesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetRolesOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewGetZonesParams() + params = NewGetRolesParams() } op := &runtime.ClientOperation{ - ID: "getZones", + ID: "getRoles", Method: "GET", - PathPattern: "/zone", + PathPattern: "/roles", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &GetZonesReader{formats: a.formats}, + Reader: &GetRolesReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -70,13 +70,13 @@ func (a *Client) GetZones(params *GetZonesParams, authInfo runtime.ClientAuthInf if err != nil { return nil, err } - success, ok := result.(*GetZonesOK) + success, ok := result.(*GetRolesOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getZones: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for getRoles: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } diff --git a/api/voip/voip_client/voip_client.go b/api/sfgate/sfgate_client/sfgate_client.go similarity index 54% rename from api/voip/voip_client/voip_client.go rename to api/sfgate/sfgate_client/sfgate_client.go index 162d050..31aad0f 100644 --- a/api/voip/voip_client/voip_client.go +++ b/api/sfgate/sfgate_client/sfgate_client.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package voip_client +package sfgate_client // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -14,22 +14,24 @@ import ( httptransport "github.com/go-openapi/runtime/client" "github.com/go-openapi/strfmt" - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_client/authority" - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_client/endpoint" - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_client/pbx" - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_client/pbx_user" - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_client/phone_number" - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_client/queue" - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_client/vm_box" + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_client/accounts" + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_client/companies" + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_client/contacts" + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_client/notebooks" + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_client/products" + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_client/roles" + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_client/templates" + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_client/tenants" + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_client/users" ) -// Default voip HTTP client. +// Default sfgate HTTP client. var Default = NewHTTPClient(nil) const ( // DefaultHost is the default Host // found in Meta (info) section of spec file - DefaultHost string = "voip.infra.tnxs.net:8080" + DefaultHost string = "sf-gate.fabric.tnxs.net:8080" // DefaultBasePath is the default BasePath // found in Meta (info) section of spec file DefaultBasePath string = "/v1" @@ -38,14 +40,14 @@ const ( // DefaultSchemes are the default schemes found in Meta (info) section of spec file var DefaultSchemes = []string{"http"} -// NewHTTPClient creates a new voip HTTP client. -func NewHTTPClient(formats strfmt.Registry) *Voip { +// NewHTTPClient creates a new sfgate HTTP client. +func NewHTTPClient(formats strfmt.Registry) *Sfgate { return NewHTTPClientWithConfig(formats, nil) } -// NewHTTPClientWithConfig creates a new voip HTTP client, +// NewHTTPClientWithConfig creates a new sfgate HTTP client, // using a customizable transport config. -func NewHTTPClientWithConfig(formats strfmt.Registry, cfg *TransportConfig) *Voip { +func NewHTTPClientWithConfig(formats strfmt.Registry, cfg *TransportConfig) *Sfgate { // ensure nullable parameters have default if cfg == nil { cfg = DefaultTransportConfig() @@ -56,22 +58,24 @@ func NewHTTPClientWithConfig(formats strfmt.Registry, cfg *TransportConfig) *Voi return New(transport, formats) } -// New creates a new voip client -func New(transport runtime.ClientTransport, formats strfmt.Registry) *Voip { +// New creates a new sfgate client +func New(transport runtime.ClientTransport, formats strfmt.Registry) *Sfgate { // ensure nullable parameters have default if formats == nil { formats = strfmt.Default } - cli := new(Voip) + cli := new(Sfgate) cli.Transport = transport - cli.Authority = authority.New(transport, formats) - cli.Endpoint = endpoint.New(transport, formats) - cli.Pbx = pbx.New(transport, formats) - cli.PbxUser = pbx_user.New(transport, formats) - cli.PhoneNumber = phone_number.New(transport, formats) - cli.Queue = queue.New(transport, formats) - cli.VMBox = vm_box.New(transport, formats) + cli.Accounts = accounts.New(transport, formats) + cli.Companies = companies.New(transport, formats) + cli.Contacts = contacts.New(transport, formats) + cli.Notebooks = notebooks.New(transport, formats) + cli.Products = products.New(transport, formats) + cli.Roles = roles.New(transport, formats) + cli.Templates = templates.New(transport, formats) + cli.Tenants = tenants.New(transport, formats) + cli.Users = users.New(transport, formats) return cli } @@ -114,33 +118,39 @@ func (cfg *TransportConfig) WithSchemes(schemes []string) *TransportConfig { return cfg } -// Voip is a client for voip -type Voip struct { - Authority authority.ClientService +// Sfgate is a client for sfgate +type Sfgate struct { + Accounts accounts.ClientService - Endpoint endpoint.ClientService + Companies companies.ClientService - Pbx pbx.ClientService + Contacts contacts.ClientService - PbxUser pbx_user.ClientService + Notebooks notebooks.ClientService - PhoneNumber phone_number.ClientService + Products products.ClientService - Queue queue.ClientService + Roles roles.ClientService - VMBox vm_box.ClientService + Templates templates.ClientService + + Tenants tenants.ClientService + + Users users.ClientService Transport runtime.ClientTransport } // SetTransport changes the transport on the client and all its subresources -func (c *Voip) SetTransport(transport runtime.ClientTransport) { +func (c *Sfgate) SetTransport(transport runtime.ClientTransport) { c.Transport = transport - c.Authority.SetTransport(transport) - c.Endpoint.SetTransport(transport) - c.Pbx.SetTransport(transport) - c.PbxUser.SetTransport(transport) - c.PhoneNumber.SetTransport(transport) - c.Queue.SetTransport(transport) - c.VMBox.SetTransport(transport) + c.Accounts.SetTransport(transport) + c.Companies.SetTransport(transport) + c.Contacts.SetTransport(transport) + c.Notebooks.SetTransport(transport) + c.Products.SetTransport(transport) + c.Roles.SetTransport(transport) + c.Templates.SetTransport(transport) + c.Tenants.SetTransport(transport) + c.Users.SetTransport(transport) } diff --git a/api/sfgate/sfgate_client/templates/get_templates_parameters.go b/api/sfgate/sfgate_client/templates/get_templates_parameters.go new file mode 100644 index 0000000..5d9cc17 --- /dev/null +++ b/api/sfgate/sfgate_client/templates/get_templates_parameters.go @@ -0,0 +1,238 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package templates + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewGetTemplatesParams creates a new GetTemplatesParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewGetTemplatesParams() *GetTemplatesParams { + return &GetTemplatesParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewGetTemplatesParamsWithTimeout creates a new GetTemplatesParams object +// with the ability to set a timeout on a request. +func NewGetTemplatesParamsWithTimeout(timeout time.Duration) *GetTemplatesParams { + return &GetTemplatesParams{ + timeout: timeout, + } +} + +// NewGetTemplatesParamsWithContext creates a new GetTemplatesParams object +// with the ability to set a context for a request. +func NewGetTemplatesParamsWithContext(ctx context.Context) *GetTemplatesParams { + return &GetTemplatesParams{ + Context: ctx, + } +} + +// NewGetTemplatesParamsWithHTTPClient creates a new GetTemplatesParams object +// with the ability to set a custom HTTPClient for a request. +func NewGetTemplatesParamsWithHTTPClient(client *http.Client) *GetTemplatesParams { + return &GetTemplatesParams{ + HTTPClient: client, + } +} + +/* GetTemplatesParams contains all the parameters to send to the API endpoint + for the get templates operation. + + Typically these are written to a http.Request. +*/ +type GetTemplatesParams struct { + + /* Limit. + + How many objects to return at one time + + Format: int64 + */ + Limit *int64 + + /* Offset. + + How many objects to skip? (default 0) + + Format: int64 + */ + Offset *int64 + + /* TemplateID. + + Taxnexus Record Id of a Template + */ + TemplateID *string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the get templates params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *GetTemplatesParams) WithDefaults() *GetTemplatesParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the get templates params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *GetTemplatesParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the get templates params +func (o *GetTemplatesParams) WithTimeout(timeout time.Duration) *GetTemplatesParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the get templates params +func (o *GetTemplatesParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the get templates params +func (o *GetTemplatesParams) WithContext(ctx context.Context) *GetTemplatesParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the get templates params +func (o *GetTemplatesParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the get templates params +func (o *GetTemplatesParams) WithHTTPClient(client *http.Client) *GetTemplatesParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the get templates params +func (o *GetTemplatesParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithLimit adds the limit to the get templates params +func (o *GetTemplatesParams) WithLimit(limit *int64) *GetTemplatesParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the get templates params +func (o *GetTemplatesParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithOffset adds the offset to the get templates params +func (o *GetTemplatesParams) WithOffset(offset *int64) *GetTemplatesParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the get templates params +func (o *GetTemplatesParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WithTemplateID adds the templateID to the get templates params +func (o *GetTemplatesParams) WithTemplateID(templateID *string) *GetTemplatesParams { + o.SetTemplateID(templateID) + return o +} + +// SetTemplateID adds the templateId to the get templates params +func (o *GetTemplatesParams) SetTemplateID(templateID *string) { + o.TemplateID = templateID +} + +// WriteToRequest writes these params to a swagger request +func (o *GetTemplatesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if o.TemplateID != nil { + + // query param templateId + var qrTemplateID string + + if o.TemplateID != nil { + qrTemplateID = *o.TemplateID + } + qTemplateID := qrTemplateID + if qTemplateID != "" { + + if err := r.SetQueryParam("templateId", qTemplateID); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/templates/get_templates_responses.go b/api/sfgate/sfgate_client/templates/get_templates_responses.go new file mode 100644 index 0000000..f58d94f --- /dev/null +++ b/api/sfgate/sfgate_client/templates/get_templates_responses.go @@ -0,0 +1,261 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package templates + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// GetTemplatesReader is a Reader for the GetTemplates structure. +type GetTemplatesReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *GetTemplatesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewGetTemplatesOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewGetTemplatesUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewGetTemplatesForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewGetTemplatesNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 422: + result := NewGetTemplatesUnprocessableEntity() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewGetTemplatesInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewGetTemplatesOK creates a GetTemplatesOK with default headers values +func NewGetTemplatesOK() *GetTemplatesOK { + return &GetTemplatesOK{} +} + +/* GetTemplatesOK describes a response with status code 200, with default header values. + +Taxnexus Response with Template objects +*/ +type GetTemplatesOK struct { + Payload *sfgate_models.TemplateResponse +} + +func (o *GetTemplatesOK) Error() string { + return fmt.Sprintf("[GET /templates][%d] getTemplatesOK %+v", 200, o.Payload) +} +func (o *GetTemplatesOK) GetPayload() *sfgate_models.TemplateResponse { + return o.Payload +} + +func (o *GetTemplatesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.TemplateResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetTemplatesUnauthorized creates a GetTemplatesUnauthorized with default headers values +func NewGetTemplatesUnauthorized() *GetTemplatesUnauthorized { + return &GetTemplatesUnauthorized{} +} + +/* GetTemplatesUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type GetTemplatesUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *GetTemplatesUnauthorized) Error() string { + return fmt.Sprintf("[GET /templates][%d] getTemplatesUnauthorized %+v", 401, o.Payload) +} +func (o *GetTemplatesUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetTemplatesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetTemplatesForbidden creates a GetTemplatesForbidden with default headers values +func NewGetTemplatesForbidden() *GetTemplatesForbidden { + return &GetTemplatesForbidden{} +} + +/* GetTemplatesForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type GetTemplatesForbidden struct { + Payload *sfgate_models.Error +} + +func (o *GetTemplatesForbidden) Error() string { + return fmt.Sprintf("[GET /templates][%d] getTemplatesForbidden %+v", 403, o.Payload) +} +func (o *GetTemplatesForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetTemplatesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetTemplatesNotFound creates a GetTemplatesNotFound with default headers values +func NewGetTemplatesNotFound() *GetTemplatesNotFound { + return &GetTemplatesNotFound{} +} + +/* GetTemplatesNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type GetTemplatesNotFound struct { + Payload *sfgate_models.Error +} + +func (o *GetTemplatesNotFound) Error() string { + return fmt.Sprintf("[GET /templates][%d] getTemplatesNotFound %+v", 404, o.Payload) +} +func (o *GetTemplatesNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetTemplatesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetTemplatesUnprocessableEntity creates a GetTemplatesUnprocessableEntity with default headers values +func NewGetTemplatesUnprocessableEntity() *GetTemplatesUnprocessableEntity { + return &GetTemplatesUnprocessableEntity{} +} + +/* GetTemplatesUnprocessableEntity describes a response with status code 422, with default header values. + +Unprocessable Entity, likely a bad parameter +*/ +type GetTemplatesUnprocessableEntity struct { + Payload *sfgate_models.Error +} + +func (o *GetTemplatesUnprocessableEntity) Error() string { + return fmt.Sprintf("[GET /templates][%d] getTemplatesUnprocessableEntity %+v", 422, o.Payload) +} +func (o *GetTemplatesUnprocessableEntity) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetTemplatesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetTemplatesInternalServerError creates a GetTemplatesInternalServerError with default headers values +func NewGetTemplatesInternalServerError() *GetTemplatesInternalServerError { + return &GetTemplatesInternalServerError{} +} + +/* GetTemplatesInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type GetTemplatesInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *GetTemplatesInternalServerError) Error() string { + return fmt.Sprintf("[GET /templates][%d] getTemplatesInternalServerError %+v", 500, o.Payload) +} +func (o *GetTemplatesInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetTemplatesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/kazoo/kazoo_client/time_rule/time_rule_client.go b/api/sfgate/sfgate_client/templates/templates_client.go similarity index 65% rename from api/kazoo/kazoo_client/time_rule/time_rule_client.go rename to api/sfgate/sfgate_client/templates/templates_client.go index 96522cd..df16a99 100644 --- a/api/kazoo/kazoo_client/time_rule/time_rule_client.go +++ b/api/sfgate/sfgate_client/templates/templates_client.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package time_rule +package templates // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -16,13 +16,13 @@ import ( "github.com/go-openapi/strfmt" ) -// New creates a new time rule API client. +// New creates a new templates API client. func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { return &Client{transport: transport, formats: formats} } /* -Client for time rule API +Client for templates API */ type Client struct { transport runtime.ClientTransport @@ -34,28 +34,30 @@ type ClientOption func(*runtime.ClientOperation) // ClientService is the interface for Client methods type ClientService interface { - GetAccountTimeRules(params *GetAccountTimeRulesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountTimeRulesOK, error) + GetTemplates(params *GetTemplatesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetTemplatesOK, error) SetTransport(transport runtime.ClientTransport) } /* - GetAccountTimeRules get account time rules API + GetTemplates gets p d f rendering templates + + Returns the PDF rendering template, or a link to where to get the template */ -func (a *Client) GetAccountTimeRules(params *GetAccountTimeRulesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAccountTimeRulesOK, error) { +func (a *Client) GetTemplates(params *GetTemplatesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetTemplatesOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewGetAccountTimeRulesParams() + params = NewGetTemplatesParams() } op := &runtime.ClientOperation{ - ID: "getAccountTimeRules", + ID: "getTemplates", Method: "GET", - PathPattern: "/accounts/{accountId}/temporal_rules", + PathPattern: "/templates", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"https"}, + Schemes: []string{"http"}, Params: params, - Reader: &GetAccountTimeRulesReader{formats: a.formats}, + Reader: &GetTemplatesReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -68,13 +70,13 @@ func (a *Client) GetAccountTimeRules(params *GetAccountTimeRulesParams, authInfo if err != nil { return nil, err } - success, ok := result.(*GetAccountTimeRulesOK) + success, ok := result.(*GetTemplatesOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getAccountTimeRules: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for getTemplates: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } diff --git a/api/sfgate/sfgate_client/tenants/get_tenants_parameters.go b/api/sfgate/sfgate_client/tenants/get_tenants_parameters.go new file mode 100644 index 0000000..d598064 --- /dev/null +++ b/api/sfgate/sfgate_client/tenants/get_tenants_parameters.go @@ -0,0 +1,272 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package tenants + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewGetTenantsParams creates a new GetTenantsParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewGetTenantsParams() *GetTenantsParams { + return &GetTenantsParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewGetTenantsParamsWithTimeout creates a new GetTenantsParams object +// with the ability to set a timeout on a request. +func NewGetTenantsParamsWithTimeout(timeout time.Duration) *GetTenantsParams { + return &GetTenantsParams{ + timeout: timeout, + } +} + +// NewGetTenantsParamsWithContext creates a new GetTenantsParams object +// with the ability to set a context for a request. +func NewGetTenantsParamsWithContext(ctx context.Context) *GetTenantsParams { + return &GetTenantsParams{ + Context: ctx, + } +} + +// NewGetTenantsParamsWithHTTPClient creates a new GetTenantsParams object +// with the ability to set a custom HTTPClient for a request. +func NewGetTenantsParamsWithHTTPClient(client *http.Client) *GetTenantsParams { + return &GetTenantsParams{ + HTTPClient: client, + } +} + +/* GetTenantsParams contains all the parameters to send to the API endpoint + for the get tenants operation. + + Typically these are written to a http.Request. +*/ +type GetTenantsParams struct { + + /* CompanyID. + + Taxnexus Id of the Company to be retrieved + */ + CompanyID *string + + /* Limit. + + How many objects to return at one time + + Format: int64 + */ + Limit *int64 + + /* Offset. + + How many objects to skip? (default 0) + + Format: int64 + */ + Offset *int64 + + /* TenantID. + + Taxnexus Record Id of a Tenant + */ + TenantID *string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the get tenants params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *GetTenantsParams) WithDefaults() *GetTenantsParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the get tenants params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *GetTenantsParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the get tenants params +func (o *GetTenantsParams) WithTimeout(timeout time.Duration) *GetTenantsParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the get tenants params +func (o *GetTenantsParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the get tenants params +func (o *GetTenantsParams) WithContext(ctx context.Context) *GetTenantsParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the get tenants params +func (o *GetTenantsParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the get tenants params +func (o *GetTenantsParams) WithHTTPClient(client *http.Client) *GetTenantsParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the get tenants params +func (o *GetTenantsParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithCompanyID adds the companyID to the get tenants params +func (o *GetTenantsParams) WithCompanyID(companyID *string) *GetTenantsParams { + o.SetCompanyID(companyID) + return o +} + +// SetCompanyID adds the companyId to the get tenants params +func (o *GetTenantsParams) SetCompanyID(companyID *string) { + o.CompanyID = companyID +} + +// WithLimit adds the limit to the get tenants params +func (o *GetTenantsParams) WithLimit(limit *int64) *GetTenantsParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the get tenants params +func (o *GetTenantsParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithOffset adds the offset to the get tenants params +func (o *GetTenantsParams) WithOffset(offset *int64) *GetTenantsParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the get tenants params +func (o *GetTenantsParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WithTenantID adds the tenantID to the get tenants params +func (o *GetTenantsParams) WithTenantID(tenantID *string) *GetTenantsParams { + o.SetTenantID(tenantID) + return o +} + +// SetTenantID adds the tenantId to the get tenants params +func (o *GetTenantsParams) SetTenantID(tenantID *string) { + o.TenantID = tenantID +} + +// WriteToRequest writes these params to a swagger request +func (o *GetTenantsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.CompanyID != nil { + + // query param companyId + var qrCompanyID string + + if o.CompanyID != nil { + qrCompanyID = *o.CompanyID + } + qCompanyID := qrCompanyID + if qCompanyID != "" { + + if err := r.SetQueryParam("companyId", qCompanyID); err != nil { + return err + } + } + } + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if o.TenantID != nil { + + // query param tenantId + var qrTenantID string + + if o.TenantID != nil { + qrTenantID = *o.TenantID + } + qTenantID := qrTenantID + if qTenantID != "" { + + if err := r.SetQueryParam("tenantId", qTenantID); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/tenants/get_tenants_responses.go b/api/sfgate/sfgate_client/tenants/get_tenants_responses.go new file mode 100644 index 0000000..12cac9c --- /dev/null +++ b/api/sfgate/sfgate_client/tenants/get_tenants_responses.go @@ -0,0 +1,261 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package tenants + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// GetTenantsReader is a Reader for the GetTenants structure. +type GetTenantsReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *GetTenantsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewGetTenantsOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewGetTenantsUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewGetTenantsForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewGetTenantsNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 422: + result := NewGetTenantsUnprocessableEntity() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewGetTenantsInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewGetTenantsOK creates a GetTenantsOK with default headers values +func NewGetTenantsOK() *GetTenantsOK { + return &GetTenantsOK{} +} + +/* GetTenantsOK describes a response with status code 200, with default header values. + +Taxnexus Response with Tenant objects +*/ +type GetTenantsOK struct { + Payload *sfgate_models.TenantResponse +} + +func (o *GetTenantsOK) Error() string { + return fmt.Sprintf("[GET /tenants][%d] getTenantsOK %+v", 200, o.Payload) +} +func (o *GetTenantsOK) GetPayload() *sfgate_models.TenantResponse { + return o.Payload +} + +func (o *GetTenantsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.TenantResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetTenantsUnauthorized creates a GetTenantsUnauthorized with default headers values +func NewGetTenantsUnauthorized() *GetTenantsUnauthorized { + return &GetTenantsUnauthorized{} +} + +/* GetTenantsUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type GetTenantsUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *GetTenantsUnauthorized) Error() string { + return fmt.Sprintf("[GET /tenants][%d] getTenantsUnauthorized %+v", 401, o.Payload) +} +func (o *GetTenantsUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetTenantsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetTenantsForbidden creates a GetTenantsForbidden with default headers values +func NewGetTenantsForbidden() *GetTenantsForbidden { + return &GetTenantsForbidden{} +} + +/* GetTenantsForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type GetTenantsForbidden struct { + Payload *sfgate_models.Error +} + +func (o *GetTenantsForbidden) Error() string { + return fmt.Sprintf("[GET /tenants][%d] getTenantsForbidden %+v", 403, o.Payload) +} +func (o *GetTenantsForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetTenantsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetTenantsNotFound creates a GetTenantsNotFound with default headers values +func NewGetTenantsNotFound() *GetTenantsNotFound { + return &GetTenantsNotFound{} +} + +/* GetTenantsNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type GetTenantsNotFound struct { + Payload *sfgate_models.Error +} + +func (o *GetTenantsNotFound) Error() string { + return fmt.Sprintf("[GET /tenants][%d] getTenantsNotFound %+v", 404, o.Payload) +} +func (o *GetTenantsNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetTenantsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetTenantsUnprocessableEntity creates a GetTenantsUnprocessableEntity with default headers values +func NewGetTenantsUnprocessableEntity() *GetTenantsUnprocessableEntity { + return &GetTenantsUnprocessableEntity{} +} + +/* GetTenantsUnprocessableEntity describes a response with status code 422, with default header values. + +Unprocessable Entity, likely a bad parameter +*/ +type GetTenantsUnprocessableEntity struct { + Payload *sfgate_models.Error +} + +func (o *GetTenantsUnprocessableEntity) Error() string { + return fmt.Sprintf("[GET /tenants][%d] getTenantsUnprocessableEntity %+v", 422, o.Payload) +} +func (o *GetTenantsUnprocessableEntity) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetTenantsUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewGetTenantsInternalServerError creates a GetTenantsInternalServerError with default headers values +func NewGetTenantsInternalServerError() *GetTenantsInternalServerError { + return &GetTenantsInternalServerError{} +} + +/* GetTenantsInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type GetTenantsInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *GetTenantsInternalServerError) Error() string { + return fmt.Sprintf("[GET /tenants][%d] getTenantsInternalServerError %+v", 500, o.Payload) +} +func (o *GetTenantsInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *GetTenantsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/sfgate/sfgate_client/tenants/put_tenants_parameters.go b/api/sfgate/sfgate_client/tenants/put_tenants_parameters.go new file mode 100644 index 0000000..7a8effd --- /dev/null +++ b/api/sfgate/sfgate_client/tenants/put_tenants_parameters.go @@ -0,0 +1,155 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package tenants + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// NewPutTenantsParams creates a new PutTenantsParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewPutTenantsParams() *PutTenantsParams { + return &PutTenantsParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewPutTenantsParamsWithTimeout creates a new PutTenantsParams object +// with the ability to set a timeout on a request. +func NewPutTenantsParamsWithTimeout(timeout time.Duration) *PutTenantsParams { + return &PutTenantsParams{ + timeout: timeout, + } +} + +// NewPutTenantsParamsWithContext creates a new PutTenantsParams object +// with the ability to set a context for a request. +func NewPutTenantsParamsWithContext(ctx context.Context) *PutTenantsParams { + return &PutTenantsParams{ + Context: ctx, + } +} + +// NewPutTenantsParamsWithHTTPClient creates a new PutTenantsParams object +// with the ability to set a custom HTTPClient for a request. +func NewPutTenantsParamsWithHTTPClient(client *http.Client) *PutTenantsParams { + return &PutTenantsParams{ + HTTPClient: client, + } +} + +/* PutTenantsParams contains all the parameters to send to the API endpoint + for the put tenants operation. + + Typically these are written to a http.Request. +*/ +type PutTenantsParams struct { + + /* CTenantRequest. + + An array of Tenant records + */ + CTenantRequest *sfgate_models.TenantRequest + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the put tenants params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *PutTenantsParams) WithDefaults() *PutTenantsParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the put tenants params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *PutTenantsParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the put tenants params +func (o *PutTenantsParams) WithTimeout(timeout time.Duration) *PutTenantsParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the put tenants params +func (o *PutTenantsParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the put tenants params +func (o *PutTenantsParams) WithContext(ctx context.Context) *PutTenantsParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the put tenants params +func (o *PutTenantsParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the put tenants params +func (o *PutTenantsParams) WithHTTPClient(client *http.Client) *PutTenantsParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the put tenants params +func (o *PutTenantsParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithCTenantRequest adds the cTenantRequest to the put tenants params +func (o *PutTenantsParams) WithCTenantRequest(cTenantRequest *sfgate_models.TenantRequest) *PutTenantsParams { + o.SetCTenantRequest(cTenantRequest) + return o +} + +// SetCTenantRequest adds the cTenantRequest to the put tenants params +func (o *PutTenantsParams) SetCTenantRequest(cTenantRequest *sfgate_models.TenantRequest) { + o.CTenantRequest = cTenantRequest +} + +// WriteToRequest writes these params to a swagger request +func (o *PutTenantsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.CTenantRequest != nil { + if err := r.SetBodyParam(o.CTenantRequest); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/tenants/put_tenants_responses.go b/api/sfgate/sfgate_client/tenants/put_tenants_responses.go new file mode 100644 index 0000000..0c120d6 --- /dev/null +++ b/api/sfgate/sfgate_client/tenants/put_tenants_responses.go @@ -0,0 +1,261 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package tenants + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// PutTenantsReader is a Reader for the PutTenants structure. +type PutTenantsReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *PutTenantsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewPutTenantsOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewPutTenantsUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewPutTenantsForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewPutTenantsNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 422: + result := NewPutTenantsUnprocessableEntity() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewPutTenantsInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewPutTenantsOK creates a PutTenantsOK with default headers values +func NewPutTenantsOK() *PutTenantsOK { + return &PutTenantsOK{} +} + +/* PutTenantsOK describes a response with status code 200, with default header values. + +Taxnexus Response with Tenant objects +*/ +type PutTenantsOK struct { + Payload *sfgate_models.TenantResponse +} + +func (o *PutTenantsOK) Error() string { + return fmt.Sprintf("[PUT /tenants][%d] putTenantsOK %+v", 200, o.Payload) +} +func (o *PutTenantsOK) GetPayload() *sfgate_models.TenantResponse { + return o.Payload +} + +func (o *PutTenantsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.TenantResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutTenantsUnauthorized creates a PutTenantsUnauthorized with default headers values +func NewPutTenantsUnauthorized() *PutTenantsUnauthorized { + return &PutTenantsUnauthorized{} +} + +/* PutTenantsUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type PutTenantsUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *PutTenantsUnauthorized) Error() string { + return fmt.Sprintf("[PUT /tenants][%d] putTenantsUnauthorized %+v", 401, o.Payload) +} +func (o *PutTenantsUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutTenantsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutTenantsForbidden creates a PutTenantsForbidden with default headers values +func NewPutTenantsForbidden() *PutTenantsForbidden { + return &PutTenantsForbidden{} +} + +/* PutTenantsForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type PutTenantsForbidden struct { + Payload *sfgate_models.Error +} + +func (o *PutTenantsForbidden) Error() string { + return fmt.Sprintf("[PUT /tenants][%d] putTenantsForbidden %+v", 403, o.Payload) +} +func (o *PutTenantsForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutTenantsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutTenantsNotFound creates a PutTenantsNotFound with default headers values +func NewPutTenantsNotFound() *PutTenantsNotFound { + return &PutTenantsNotFound{} +} + +/* PutTenantsNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type PutTenantsNotFound struct { + Payload *sfgate_models.Error +} + +func (o *PutTenantsNotFound) Error() string { + return fmt.Sprintf("[PUT /tenants][%d] putTenantsNotFound %+v", 404, o.Payload) +} +func (o *PutTenantsNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutTenantsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutTenantsUnprocessableEntity creates a PutTenantsUnprocessableEntity with default headers values +func NewPutTenantsUnprocessableEntity() *PutTenantsUnprocessableEntity { + return &PutTenantsUnprocessableEntity{} +} + +/* PutTenantsUnprocessableEntity describes a response with status code 422, with default header values. + +Unprocessable Entity, likely a bad parameter +*/ +type PutTenantsUnprocessableEntity struct { + Payload *sfgate_models.Error +} + +func (o *PutTenantsUnprocessableEntity) Error() string { + return fmt.Sprintf("[PUT /tenants][%d] putTenantsUnprocessableEntity %+v", 422, o.Payload) +} +func (o *PutTenantsUnprocessableEntity) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutTenantsUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPutTenantsInternalServerError creates a PutTenantsInternalServerError with default headers values +func NewPutTenantsInternalServerError() *PutTenantsInternalServerError { + return &PutTenantsInternalServerError{} +} + +/* PutTenantsInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type PutTenantsInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *PutTenantsInternalServerError) Error() string { + return fmt.Sprintf("[PUT /tenants][%d] putTenantsInternalServerError %+v", 500, o.Payload) +} +func (o *PutTenantsInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *PutTenantsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/voip/voip_client/vm_box/vm_box_client.go b/api/sfgate/sfgate_client/tenants/tenants_client.go similarity index 62% rename from api/voip/voip_client/vm_box/vm_box_client.go rename to api/sfgate/sfgate_client/tenants/tenants_client.go index 3d31634..6d22520 100644 --- a/api/voip/voip_client/vm_box/vm_box_client.go +++ b/api/sfgate/sfgate_client/tenants/tenants_client.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package vm_box +package tenants // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -16,13 +16,13 @@ import ( "github.com/go-openapi/strfmt" ) -// New creates a new vm box API client. +// New creates a new tenants API client. func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { return &Client{transport: transport, formats: formats} } /* -Client for vm box API +Client for tenants API */ type Client struct { transport runtime.ClientTransport @@ -34,75 +34,34 @@ type ClientOption func(*runtime.ClientOperation) // ClientService is the interface for Client methods type ClientService interface { - GetVMBoxes(params *GetVMBoxesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetVMBoxesOK, error) + Tenants(params *TenantsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenantsOK, error) - PostVMBoxes(params *PostVMBoxesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostVMBoxesOK, error) + GetTenants(params *GetTenantsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetTenantsOK, error) - PutVMBoxes(params *PutVMBoxesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutVMBoxesOK, error) + PutTenants(params *PutTenantsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutTenantsOK, error) SetTransport(transport runtime.ClientTransport) } /* - GetVMBoxes gets a list of voice mail boxes + Tenants creates new tenants - Return a list of available Voice Mail Box entities + Create Tenants in Taxnexus */ -func (a *Client) GetVMBoxes(params *GetVMBoxesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetVMBoxesOK, error) { +func (a *Client) Tenants(params *TenantsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenantsOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewGetVMBoxesParams() + params = NewTenantsParams() } op := &runtime.ClientOperation{ - ID: "getVmBoxes", - Method: "GET", - PathPattern: "/vmboxes", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"http"}, - Params: params, - Reader: &GetVMBoxesReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*GetVMBoxesOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getVmBoxes: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -/* - PostVMBoxes adds new voice mail boxes - - Create new VmBoxes -*/ -func (a *Client) PostVMBoxes(params *PostVMBoxesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostVMBoxesOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewPostVMBoxesParams() - } - op := &runtime.ClientOperation{ - ID: "postVmBoxes", + ID: "Tenants", Method: "POST", - PathPattern: "/vmboxes", + PathPattern: "/tenants", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &PostVMBoxesReader{formats: a.formats}, + Reader: &TenantsReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -115,35 +74,35 @@ func (a *Client) PostVMBoxes(params *PostVMBoxesParams, authInfo runtime.ClientA if err != nil { return nil, err } - success, ok := result.(*PostVMBoxesOK) + success, ok := result.(*TenantsOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for postVmBoxes: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for Tenants: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - PutVMBoxes updates voice mail boxes + GetTenants gets a list tenants - Update fields in Voice Mail Box records identified by Telnexus Id + Return a list of Tenant records from the datastore */ -func (a *Client) PutVMBoxes(params *PutVMBoxesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutVMBoxesOK, error) { +func (a *Client) GetTenants(params *GetTenantsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetTenantsOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewPutVMBoxesParams() + params = NewGetTenantsParams() } op := &runtime.ClientOperation{ - ID: "putVmBoxes", - Method: "PUT", - PathPattern: "/vmboxes", + ID: "getTenants", + Method: "GET", + PathPattern: "/tenants", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &PutVMBoxesReader{formats: a.formats}, + Reader: &GetTenantsReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -156,13 +115,54 @@ func (a *Client) PutVMBoxes(params *PutVMBoxesParams, authInfo runtime.ClientAut if err != nil { return nil, err } - success, ok := result.(*PutVMBoxesOK) + success, ok := result.(*GetTenantsOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for putVmBoxes: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for getTenants: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + PutTenants updates tenants + + Update Tenant in Taxnexus +*/ +func (a *Client) PutTenants(params *PutTenantsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutTenantsOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewPutTenantsParams() + } + op := &runtime.ClientOperation{ + ID: "putTenants", + Method: "PUT", + PathPattern: "/tenants", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &PutTenantsReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*PutTenantsOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for putTenants: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } diff --git a/api/sfgate/sfgate_client/tenants/tenants_parameters.go b/api/sfgate/sfgate_client/tenants/tenants_parameters.go new file mode 100644 index 0000000..d1fbf91 --- /dev/null +++ b/api/sfgate/sfgate_client/tenants/tenants_parameters.go @@ -0,0 +1,155 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package tenants + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// NewTenantsParams creates a new TenantsParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenantsParams() *TenantsParams { + return &TenantsParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenantsParamsWithTimeout creates a new TenantsParams object +// with the ability to set a timeout on a request. +func NewTenantsParamsWithTimeout(timeout time.Duration) *TenantsParams { + return &TenantsParams{ + timeout: timeout, + } +} + +// NewTenantsParamsWithContext creates a new TenantsParams object +// with the ability to set a context for a request. +func NewTenantsParamsWithContext(ctx context.Context) *TenantsParams { + return &TenantsParams{ + Context: ctx, + } +} + +// NewTenantsParamsWithHTTPClient creates a new TenantsParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenantsParamsWithHTTPClient(client *http.Client) *TenantsParams { + return &TenantsParams{ + HTTPClient: client, + } +} + +/* TenantsParams contains all the parameters to send to the API endpoint + for the tenants operation. + + Typically these are written to a http.Request. +*/ +type TenantsParams struct { + + /* CTenantRequest. + + An array of Tenant records + */ + CTenantRequest *sfgate_models.TenantRequest + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenants params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenantsParams) WithDefaults() *TenantsParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenants params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenantsParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenants params +func (o *TenantsParams) WithTimeout(timeout time.Duration) *TenantsParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenants params +func (o *TenantsParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenants params +func (o *TenantsParams) WithContext(ctx context.Context) *TenantsParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenants params +func (o *TenantsParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenants params +func (o *TenantsParams) WithHTTPClient(client *http.Client) *TenantsParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenants params +func (o *TenantsParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithCTenantRequest adds the cTenantRequest to the tenants params +func (o *TenantsParams) WithCTenantRequest(cTenantRequest *sfgate_models.TenantRequest) *TenantsParams { + o.SetCTenantRequest(cTenantRequest) + return o +} + +// SetCTenantRequest adds the cTenantRequest to the tenants params +func (o *TenantsParams) SetCTenantRequest(cTenantRequest *sfgate_models.TenantRequest) { + o.CTenantRequest = cTenantRequest +} + +// WriteToRequest writes these params to a swagger request +func (o *TenantsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.CTenantRequest != nil { + if err := r.SetBodyParam(o.CTenantRequest); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/sfgate/sfgate_client/tenants/tenants_responses.go b/api/sfgate/sfgate_client/tenants/tenants_responses.go new file mode 100644 index 0000000..d092314 --- /dev/null +++ b/api/sfgate/sfgate_client/tenants/tenants_responses.go @@ -0,0 +1,261 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package tenants + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" +) + +// TenantsReader is a Reader for the Tenants structure. +type TenantsReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenantsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenantsOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + case 401: + result := NewTenantsUnauthorized() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 403: + result := NewTenantsForbidden() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 404: + result := NewTenantsNotFound() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 422: + result := NewTenantsUnprocessableEntity() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + case 500: + result := NewTenantsInternalServerError() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return nil, result + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenantsOK creates a TenantsOK with default headers values +func NewTenantsOK() *TenantsOK { + return &TenantsOK{} +} + +/* TenantsOK describes a response with status code 200, with default header values. + +Taxnexus Response with Tenant objects +*/ +type TenantsOK struct { + Payload *sfgate_models.TenantResponse +} + +func (o *TenantsOK) Error() string { + return fmt.Sprintf("[POST /tenants][%d] tenantsOK %+v", 200, o.Payload) +} +func (o *TenantsOK) GetPayload() *sfgate_models.TenantResponse { + return o.Payload +} + +func (o *TenantsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.TenantResponse) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewTenantsUnauthorized creates a TenantsUnauthorized with default headers values +func NewTenantsUnauthorized() *TenantsUnauthorized { + return &TenantsUnauthorized{} +} + +/* TenantsUnauthorized describes a response with status code 401, with default header values. + +Access unauthorized, invalid API-KEY was used +*/ +type TenantsUnauthorized struct { + Payload *sfgate_models.Error +} + +func (o *TenantsUnauthorized) Error() string { + return fmt.Sprintf("[POST /tenants][%d] tenantsUnauthorized %+v", 401, o.Payload) +} +func (o *TenantsUnauthorized) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *TenantsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewTenantsForbidden creates a TenantsForbidden with default headers values +func NewTenantsForbidden() *TenantsForbidden { + return &TenantsForbidden{} +} + +/* TenantsForbidden describes a response with status code 403, with default header values. + +Access forbidden, account lacks access +*/ +type TenantsForbidden struct { + Payload *sfgate_models.Error +} + +func (o *TenantsForbidden) Error() string { + return fmt.Sprintf("[POST /tenants][%d] tenantsForbidden %+v", 403, o.Payload) +} +func (o *TenantsForbidden) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *TenantsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewTenantsNotFound creates a TenantsNotFound with default headers values +func NewTenantsNotFound() *TenantsNotFound { + return &TenantsNotFound{} +} + +/* TenantsNotFound describes a response with status code 404, with default header values. + +Resource was not found +*/ +type TenantsNotFound struct { + Payload *sfgate_models.Error +} + +func (o *TenantsNotFound) Error() string { + return fmt.Sprintf("[POST /tenants][%d] tenantsNotFound %+v", 404, o.Payload) +} +func (o *TenantsNotFound) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *TenantsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewTenantsUnprocessableEntity creates a TenantsUnprocessableEntity with default headers values +func NewTenantsUnprocessableEntity() *TenantsUnprocessableEntity { + return &TenantsUnprocessableEntity{} +} + +/* TenantsUnprocessableEntity describes a response with status code 422, with default header values. + +Unprocessable Entity, likely a bad parameter +*/ +type TenantsUnprocessableEntity struct { + Payload *sfgate_models.Error +} + +func (o *TenantsUnprocessableEntity) Error() string { + return fmt.Sprintf("[POST /tenants][%d] tenantsUnprocessableEntity %+v", 422, o.Payload) +} +func (o *TenantsUnprocessableEntity) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *TenantsUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewTenantsInternalServerError creates a TenantsInternalServerError with default headers values +func NewTenantsInternalServerError() *TenantsInternalServerError { + return &TenantsInternalServerError{} +} + +/* TenantsInternalServerError describes a response with status code 500, with default header values. + +Server Internal Error +*/ +type TenantsInternalServerError struct { + Payload *sfgate_models.Error +} + +func (o *TenantsInternalServerError) Error() string { + return fmt.Sprintf("[POST /tenants][%d] tenantsInternalServerError %+v", 500, o.Payload) +} +func (o *TenantsInternalServerError) GetPayload() *sfgate_models.Error { + return o.Payload +} + +func (o *TenantsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(sfgate_models.Error) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/api/cloud/cloud_client/user/get_users_parameters.go b/api/sfgate/sfgate_client/users/get_users_parameters.go similarity index 61% rename from api/cloud/cloud_client/user/get_users_parameters.go rename to api/sfgate/sfgate_client/users/get_users_parameters.go index b24a54c..8d42027 100644 --- a/api/cloud/cloud_client/user/get_users_parameters.go +++ b/api/sfgate/sfgate_client/users/get_users_parameters.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package user +package users // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -18,6 +18,7 @@ import ( "github.com/go-openapi/runtime" cr "github.com/go-openapi/runtime/client" "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" ) // NewGetUsersParams creates a new GetUsersParams object, @@ -63,12 +64,40 @@ func NewGetUsersParamsWithHTTPClient(client *http.Client) *GetUsersParams { */ type GetUsersParams struct { + /* Active. + + Retrieve only active records? + */ + Active *bool + /* Apikey. - Service account or developer API key + Taxnexus Id of the User to be retrieved */ Apikey *string + /* Limit. + + How many objects to return at one time + + Format: int64 + */ + Limit *int64 + + /* Offset. + + How many objects to skip? (default 0) + + Format: int64 + */ + Offset *int64 + + /* UserID. + + Taxnexus Id of the User to be retrieved + */ + UserID *string + timeout time.Duration Context context.Context HTTPClient *http.Client @@ -122,6 +151,17 @@ func (o *GetUsersParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } +// WithActive adds the active to the get users params +func (o *GetUsersParams) WithActive(active *bool) *GetUsersParams { + o.SetActive(active) + return o +} + +// SetActive adds the active to the get users params +func (o *GetUsersParams) SetActive(active *bool) { + o.Active = active +} + // WithApikey adds the apikey to the get users params func (o *GetUsersParams) WithApikey(apikey *string) *GetUsersParams { o.SetApikey(apikey) @@ -133,6 +173,39 @@ func (o *GetUsersParams) SetApikey(apikey *string) { o.Apikey = apikey } +// WithLimit adds the limit to the get users params +func (o *GetUsersParams) WithLimit(limit *int64) *GetUsersParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the get users params +func (o *GetUsersParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithOffset adds the offset to the get users params +func (o *GetUsersParams) WithOffset(offset *int64) *GetUsersParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the get users params +func (o *GetUsersParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WithUserID adds the userID to the get users params +func (o *GetUsersParams) WithUserID(userID *string) *GetUsersParams { + o.SetUserID(userID) + return o +} + +// SetUserID adds the userId to the get users params +func (o *GetUsersParams) SetUserID(userID *string) { + o.UserID = userID +} + // WriteToRequest writes these params to a swagger request func (o *GetUsersParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -141,6 +214,23 @@ func (o *GetUsersParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Regi } var res []error + if o.Active != nil { + + // query param active + var qrActive bool + + if o.Active != nil { + qrActive = *o.Active + } + qActive := swag.FormatBool(qrActive) + if qActive != "" { + + if err := r.SetQueryParam("active", qActive); err != nil { + return err + } + } + } + if o.Apikey != nil { // query param apikey @@ -158,6 +248,57 @@ func (o *GetUsersParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Regi } } + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if o.UserID != nil { + + // query param userId + var qrUserID string + + if o.UserID != nil { + qrUserID = *o.UserID + } + qUserID := qrUserID + if qUserID != "" { + + if err := r.SetQueryParam("userId", qUserID); err != nil { + return err + } + } + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } diff --git a/api/cloud/cloud_client/user/get_users_responses.go b/api/sfgate/sfgate_client/users/get_users_responses.go similarity index 86% rename from api/cloud/cloud_client/user/get_users_responses.go rename to api/sfgate/sfgate_client/users/get_users_responses.go index 2204091..6bf4bac 100644 --- a/api/cloud/cloud_client/user/get_users_responses.go +++ b/api/sfgate/sfgate_client/users/get_users_responses.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package user +package users // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -16,7 +16,7 @@ import ( "github.com/go-openapi/runtime" "github.com/go-openapi/strfmt" - "code.tnxs.net/vernonkeenan/lib/api/cloud/cloud_models" + "code.tnxs.net/vernonkeenan/lib/api/sfgate/sfgate_models" ) // GetUsersReader is a Reader for the GetUsers structure. @@ -78,19 +78,19 @@ func NewGetUsersOK() *GetUsersOK { Taxnexus Response with User objects */ type GetUsersOK struct { - Payload *cloud_models.UserResponse + Payload *sfgate_models.UserResponse } func (o *GetUsersOK) Error() string { return fmt.Sprintf("[GET /users][%d] getUsersOK %+v", 200, o.Payload) } -func (o *GetUsersOK) GetPayload() *cloud_models.UserResponse { +func (o *GetUsersOK) GetPayload() *sfgate_models.UserResponse { return o.Payload } func (o *GetUsersOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - o.Payload = new(cloud_models.UserResponse) + o.Payload = new(sfgate_models.UserResponse) // response payload if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { @@ -107,22 +107,22 @@ func NewGetUsersUnauthorized() *GetUsersUnauthorized { /* GetUsersUnauthorized describes a response with status code 401, with default header values. -Access Unauthorized, invalid API-KEY was used +Access unauthorized, invalid API-KEY was used */ type GetUsersUnauthorized struct { - Payload *cloud_models.Error + Payload *sfgate_models.Error } func (o *GetUsersUnauthorized) Error() string { return fmt.Sprintf("[GET /users][%d] getUsersUnauthorized %+v", 401, o.Payload) } -func (o *GetUsersUnauthorized) GetPayload() *cloud_models.Error { +func (o *GetUsersUnauthorized) GetPayload() *sfgate_models.Error { return o.Payload } func (o *GetUsersUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - o.Payload = new(cloud_models.Error) + o.Payload = new(sfgate_models.Error) // response payload if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { @@ -142,19 +142,19 @@ func NewGetUsersForbidden() *GetUsersForbidden { Access forbidden, account lacks access */ type GetUsersForbidden struct { - Payload *cloud_models.Error + Payload *sfgate_models.Error } func (o *GetUsersForbidden) Error() string { return fmt.Sprintf("[GET /users][%d] getUsersForbidden %+v", 403, o.Payload) } -func (o *GetUsersForbidden) GetPayload() *cloud_models.Error { +func (o *GetUsersForbidden) GetPayload() *sfgate_models.Error { return o.Payload } func (o *GetUsersForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - o.Payload = new(cloud_models.Error) + o.Payload = new(sfgate_models.Error) // response payload if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { @@ -174,19 +174,19 @@ func NewGetUsersNotFound() *GetUsersNotFound { Resource was not found */ type GetUsersNotFound struct { - Payload *cloud_models.Error + Payload *sfgate_models.Error } func (o *GetUsersNotFound) Error() string { return fmt.Sprintf("[GET /users][%d] getUsersNotFound %+v", 404, o.Payload) } -func (o *GetUsersNotFound) GetPayload() *cloud_models.Error { +func (o *GetUsersNotFound) GetPayload() *sfgate_models.Error { return o.Payload } func (o *GetUsersNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - o.Payload = new(cloud_models.Error) + o.Payload = new(sfgate_models.Error) // response payload if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { @@ -206,19 +206,19 @@ func NewGetUsersUnprocessableEntity() *GetUsersUnprocessableEntity { Unprocessable Entity, likely a bad parameter */ type GetUsersUnprocessableEntity struct { - Payload *cloud_models.Error + Payload *sfgate_models.Error } func (o *GetUsersUnprocessableEntity) Error() string { return fmt.Sprintf("[GET /users][%d] getUsersUnprocessableEntity %+v", 422, o.Payload) } -func (o *GetUsersUnprocessableEntity) GetPayload() *cloud_models.Error { +func (o *GetUsersUnprocessableEntity) GetPayload() *sfgate_models.Error { return o.Payload } func (o *GetUsersUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - o.Payload = new(cloud_models.Error) + o.Payload = new(sfgate_models.Error) // response payload if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { @@ -238,19 +238,19 @@ func NewGetUsersInternalServerError() *GetUsersInternalServerError { Server Internal Error */ type GetUsersInternalServerError struct { - Payload *cloud_models.Error + Payload *sfgate_models.Error } func (o *GetUsersInternalServerError) Error() string { return fmt.Sprintf("[GET /users][%d] getUsersInternalServerError %+v", 500, o.Payload) } -func (o *GetUsersInternalServerError) GetPayload() *cloud_models.Error { +func (o *GetUsersInternalServerError) GetPayload() *sfgate_models.Error { return o.Payload } func (o *GetUsersInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - o.Payload = new(cloud_models.Error) + o.Payload = new(sfgate_models.Error) // response payload if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { diff --git a/api/cloud/cloud_client/user/user_client.go b/api/sfgate/sfgate_client/users/users_client.go similarity index 92% rename from api/cloud/cloud_client/user/user_client.go rename to api/sfgate/sfgate_client/users/users_client.go index 3d1a6e1..c4f3838 100644 --- a/api/cloud/cloud_client/user/user_client.go +++ b/api/sfgate/sfgate_client/users/users_client.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package user +package users // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -16,13 +16,13 @@ import ( "github.com/go-openapi/strfmt" ) -// New creates a new user API client. +// New creates a new users API client. func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { return &Client{transport: transport, formats: formats} } /* -Client for user API +Client for users API */ type Client struct { transport runtime.ClientTransport @@ -40,9 +40,9 @@ type ClientService interface { } /* - GetUsers checks API key + GetUsers gets a list users - Checks for a valid API key, and returns full user record + Return a list of User records from the datastore */ func (a *Client) GetUsers(params *GetUsersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetUsersOK, error) { // TODO: Validate the params before sending diff --git a/api/sfgate/sfgate_models/account.go b/api/sfgate/sfgate_models/account.go new file mode 100644 index 0000000..9cba5ee --- /dev/null +++ b/api/sfgate/sfgate_models/account.go @@ -0,0 +1,482 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// Account account +// +// swagger:model Account +type Account struct { + + // Account Number + Accountnumber string `json:"accountnumber,omitempty"` + + // The marketing orgin of this account + Accountsource string `json:"accountsource,omitempty"` + + // Active + Active bool `json:"active,omitempty"` + + // For tax authorities, this account's administrative level, e.g. Local, County, State or Federal + Administrativelevel string `json:"administrativelevel,omitempty"` + + // Rollup Tax Amount + Amount float64 `json:"amount,omitempty"` + + // Amount Invoiced + Amountinvoiced float64 `json:"amountinvoiced,omitempty"` + + // Amount Paid + Amountpaid float64 `json:"amountpaid,omitempty"` + + // Annual Revenue Estimate + Annualrevenue float64 `json:"annualrevenue,omitempty"` + + // Account Balance + Balance float64 `json:"balance,omitempty"` + + // billingaddress + Billingaddress *Address `json:"billingaddress,omitempty"` + + // Contact ID + Billingcontactid string `json:"billingcontactid,omitempty"` + + // Billing Preference + Billingpreference string `json:"billingpreference,omitempty"` + + // businessaddress + Businessaddress *Address `json:"businessaddress,omitempty"` + + // Is this a cannabis customer? + Cannabiscustomer bool `json:"cannabiscustomer,omitempty"` + + // Channel Program Level Name + Channelprogramlevelname string `json:"channelprogramlevelname,omitempty"` + + // Channel Program Name + Channelprogramname string `json:"channelprogramname,omitempty"` + + // Client End Date + Clientenddate string `json:"clientenddate,omitempty"` + + // Client Start Date + Clientstartdate string `json:"clientstartdate,omitempty"` + + // The Company ID of this Account + Companyid string `json:"companyid,omitempty"` + + // The Id of the geo coordinates of this account + Coordinateid string `json:"coordinateid,omitempty"` + + // Created By User ID + Createdbyid string `json:"createdbyid,omitempty"` + + // Created Date + Createddate string `json:"createddate,omitempty"` + + // Customer ID from source system + Customerid string `json:"customerid,omitempty"` + + // Customer Priority + Customerpriority string `json:"customerpriority,omitempty"` + + // D-n-B Company + Dandbcompanyid string `json:"dandbcompanyid,omitempty"` + + // This Account's 'Doing Business As' name + Dba string `json:"dba,omitempty"` + + // defaultaddress + Defaultaddress *Address `json:"defaultaddress,omitempty"` + + // Default Backend ID + Defaultbackendid string `json:"defaultbackendid,omitempty"` + + // Default Delivery Address Contact ID + Defaultdeliverycontactid string `json:"defaultdeliverycontactid,omitempty"` + + // Default End User Contact ID + Defaultenduserid string `json:"defaultenduserid,omitempty"` + + // Description + Description string `json:"description,omitempty"` + + // D-U-N-S Number + Dunsnumber string `json:"dunsnumber,omitempty"` + + // EIN + Ein string `json:"ein,omitempty"` + + // Main Account Email + Email string `json:"email,omitempty"` + + // Enrollment Status + Enrollmentstatus string `json:"enrollmentstatus,omitempty"` + + // Fax + Fax string `json:"fax,omitempty"` + + // Taxnexus Account Id + ID string `json:"id,omitempty"` + + // Industry + Industry string `json:"industry,omitempty"` + + // Customer Portal Account + Iscustomerportal bool `json:"iscustomerportal,omitempty"` + + // Partner Account + Ispartner bool `json:"ispartner,omitempty"` + + // ISP Customer? + Ispcustomer bool `json:"ispcustomer,omitempty"` + + // Data.com Key + Jigsaw string `json:"jigsaw,omitempty"` + + // Last Modified By User ID + Lastmodifiedbyid string `json:"lastmodifiedbyid,omitempty"` + + // Last Modified Date + Lastmodifieddate string `json:"lastmodifieddate,omitempty"` + + // MSP Customer? + Mspcustomer bool `json:"mspcustomer,omitempty"` + + // NAICS Code + Naicscode string `json:"naicscode,omitempty"` + + // NAICS Description + Naicsdesc string `json:"naicsdesc,omitempty"` + + // Account Name + Name string `json:"name,omitempty"` + + // Employee Count Estimate + Numberofemployees int64 `json:"numberofemployees,omitempty"` + + // Number of Locations Estimate + Numberoflocations int64 `json:"numberoflocations,omitempty"` + + // Open Charges + Opencharges float64 `json:"opencharges,omitempty"` + + // Vendor Order Contact ID + Ordercontactid string `json:"ordercontactid,omitempty"` + + // Order Email + Orderemail string `json:"orderemail,omitempty"` + + // Account Owner User ID + Ownerid string `json:"ownerid,omitempty"` + + // Ownership + Ownership string `json:"ownership,omitempty"` + + // Parent Foreign Key + Parentfk string `json:"parentfk,omitempty"` + + // Parent Account + Parentid string `json:"parentid,omitempty"` + + // Phone + Phone string `json:"phone,omitempty"` + + // The ID of the Place situs record that applies to this Account + Placeid string `json:"placeid,omitempty"` + + // Tax Preparer Contact ID + Preparerid string `json:"preparerid,omitempty"` + + // Rating + Rating string `json:"rating,omitempty"` + + // Rating Engine identifier + Ratingengineid string `json:"ratingengineid,omitempty"` + + // External Reference ID + Ref string `json:"ref,omitempty"` + + // Rollup Revenue Base + Revenuebase float64 `json:"revenuebase,omitempty"` + + // Rollup Revenue Net + Revenuenet float64 `json:"revenuenet,omitempty"` + + // Rollup Revenue Not Taxable + Revenuenottaxable float64 `json:"revenuenottaxable,omitempty"` + + // shippingaddress + Shippingaddress *Address `json:"shippingaddress,omitempty"` + + // Shipping Census Tract + Shippingcensustract string `json:"shippingcensustract,omitempty"` + + // Shipping Contact ID + Shippingcontactid string `json:"shippingcontactid,omitempty"` + + // Shipping County + Shippingcounty string `json:"shippingcounty,omitempty"` + + // SIC Code + Sic string `json:"sic,omitempty"` + + // SIC Description + Sicdesc string `json:"sicdesc,omitempty"` + + // Account Site + Site string `json:"site,omitempty"` + + // Account Status + Status string `json:"status,omitempty"` + + // Tax Exemption + Taxexemption string `json:"taxexemption,omitempty"` + + // Rollup Tax On Tax + Taxontax float64 `json:"taxontax,omitempty"` + + // Telecom Customer? + Telecomcustomer bool `json:"telecomcustomer,omitempty"` + + // tenant identifier + Tenantid string `json:"tenantid,omitempty"` + + // Ticker Symbol + Tickersymbol string `json:"tickersymbol,omitempty"` + + // Tradestyle + Tradestyle string `json:"tradestyle,omitempty"` + + // Type + Type string `json:"type,omitempty"` + + // Unapplied Payments + Unappliedpayments float64 `json:"unappliedpayments,omitempty"` + + // Rollup Unit Base + Unitbase float64 `json:"unitbase,omitempty"` + + // Upsell Opportunity + Upsellopportunity string `json:"upsellopportunity,omitempty"` + + // Website + Website string `json:"website,omitempty"` + + // WHMCS Client ID + Whmcsclientid int64 `json:"whmcsclientid,omitempty"` + + // Xero Contact ID + Xerocontactid string `json:"xerocontactid,omitempty"` + + // Year Started + Yearstarted string `json:"yearstarted,omitempty"` +} + +// Validate validates this account +func (m *Account) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateBillingaddress(formats); err != nil { + res = append(res, err) + } + + if err := m.validateBusinessaddress(formats); err != nil { + res = append(res, err) + } + + if err := m.validateDefaultaddress(formats); err != nil { + res = append(res, err) + } + + if err := m.validateShippingaddress(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *Account) validateBillingaddress(formats strfmt.Registry) error { + if swag.IsZero(m.Billingaddress) { // not required + return nil + } + + if m.Billingaddress != nil { + if err := m.Billingaddress.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("billingaddress") + } + return err + } + } + + return nil +} + +func (m *Account) validateBusinessaddress(formats strfmt.Registry) error { + if swag.IsZero(m.Businessaddress) { // not required + return nil + } + + if m.Businessaddress != nil { + if err := m.Businessaddress.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("businessaddress") + } + return err + } + } + + return nil +} + +func (m *Account) validateDefaultaddress(formats strfmt.Registry) error { + if swag.IsZero(m.Defaultaddress) { // not required + return nil + } + + if m.Defaultaddress != nil { + if err := m.Defaultaddress.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("defaultaddress") + } + return err + } + } + + return nil +} + +func (m *Account) validateShippingaddress(formats strfmt.Registry) error { + if swag.IsZero(m.Shippingaddress) { // not required + return nil + } + + if m.Shippingaddress != nil { + if err := m.Shippingaddress.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("shippingaddress") + } + return err + } + } + + return nil +} + +// ContextValidate validate this account based on the context it is used +func (m *Account) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateBillingaddress(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateBusinessaddress(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDefaultaddress(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateShippingaddress(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *Account) contextValidateBillingaddress(ctx context.Context, formats strfmt.Registry) error { + + if m.Billingaddress != nil { + if err := m.Billingaddress.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("billingaddress") + } + return err + } + } + + return nil +} + +func (m *Account) contextValidateBusinessaddress(ctx context.Context, formats strfmt.Registry) error { + + if m.Businessaddress != nil { + if err := m.Businessaddress.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("businessaddress") + } + return err + } + } + + return nil +} + +func (m *Account) contextValidateDefaultaddress(ctx context.Context, formats strfmt.Registry) error { + + if m.Defaultaddress != nil { + if err := m.Defaultaddress.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("defaultaddress") + } + return err + } + } + + return nil +} + +func (m *Account) contextValidateShippingaddress(ctx context.Context, formats strfmt.Registry) error { + + if m.Shippingaddress != nil { + if err := m.Shippingaddress.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("shippingaddress") + } + return err + } + } + + return nil +} + +// MarshalBinary interface implementation +func (m *Account) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *Account) UnmarshalBinary(b []byte) error { + var res Account + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/cloud/cloud_models/delete_response.go b/api/sfgate/sfgate_models/account_request.go similarity index 68% rename from api/cloud/cloud_models/delete_response.go rename to api/sfgate/sfgate_models/account_request.go index 8e9f149..5f5f533 100644 --- a/api/cloud/cloud_models/delete_response.go +++ b/api/sfgate/sfgate_models/account_request.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package cloud_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -18,20 +18,20 @@ import ( "github.com/go-openapi/swag" ) -// DeleteResponse delete response +// AccountRequest account request // -// swagger:model DeleteResponse -type DeleteResponse struct { +// swagger:model AccountRequest +type AccountRequest struct { // data - Data []*Message `json:"Data"` + Data []*Account `json:"data"` // meta - Meta *ResponseMeta `json:"Meta,omitempty"` + Meta *RequestMeta `json:"meta,omitempty"` } -// Validate validates this delete response -func (m *DeleteResponse) Validate(formats strfmt.Registry) error { +// Validate validates this account request +func (m *AccountRequest) Validate(formats strfmt.Registry) error { var res []error if err := m.validateData(formats); err != nil { @@ -48,7 +48,7 @@ func (m *DeleteResponse) Validate(formats strfmt.Registry) error { return nil } -func (m *DeleteResponse) validateData(formats strfmt.Registry) error { +func (m *AccountRequest) validateData(formats strfmt.Registry) error { if swag.IsZero(m.Data) { // not required return nil } @@ -61,7 +61,7 @@ func (m *DeleteResponse) validateData(formats strfmt.Registry) error { if m.Data[i] != nil { if err := m.Data[i].Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -72,7 +72,7 @@ func (m *DeleteResponse) validateData(formats strfmt.Registry) error { return nil } -func (m *DeleteResponse) validateMeta(formats strfmt.Registry) error { +func (m *AccountRequest) validateMeta(formats strfmt.Registry) error { if swag.IsZero(m.Meta) { // not required return nil } @@ -80,7 +80,7 @@ func (m *DeleteResponse) validateMeta(formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -89,8 +89,8 @@ func (m *DeleteResponse) validateMeta(formats strfmt.Registry) error { return nil } -// ContextValidate validate this delete response based on the context it is used -func (m *DeleteResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { +// ContextValidate validate this account request based on the context it is used +func (m *AccountRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error if err := m.contextValidateData(ctx, formats); err != nil { @@ -107,14 +107,14 @@ func (m *DeleteResponse) ContextValidate(ctx context.Context, formats strfmt.Reg return nil } -func (m *DeleteResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { +func (m *AccountRequest) contextValidateData(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Data); i++ { if m.Data[i] != nil { if err := m.Data[i].ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -125,12 +125,12 @@ func (m *DeleteResponse) contextValidateData(ctx context.Context, formats strfmt return nil } -func (m *DeleteResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { +func (m *AccountRequest) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -140,7 +140,7 @@ func (m *DeleteResponse) contextValidateMeta(ctx context.Context, formats strfmt } // MarshalBinary interface implementation -func (m *DeleteResponse) MarshalBinary() ([]byte, error) { +func (m *AccountRequest) MarshalBinary() ([]byte, error) { if m == nil { return nil, nil } @@ -148,8 +148,8 @@ func (m *DeleteResponse) MarshalBinary() ([]byte, error) { } // UnmarshalBinary interface implementation -func (m *DeleteResponse) UnmarshalBinary(b []byte) error { - var res DeleteResponse +func (m *AccountRequest) UnmarshalBinary(b []byte) error { + var res AccountRequest if err := swag.ReadJSON(b, &res); err != nil { return err } diff --git a/api/sfgate/sfgate_models/account_response.go b/api/sfgate/sfgate_models/account_response.go new file mode 100644 index 0000000..cb5c12a --- /dev/null +++ b/api/sfgate/sfgate_models/account_response.go @@ -0,0 +1,158 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// AccountResponse An array of Account objects +// +// swagger:model AccountResponse +type AccountResponse struct { + + // data + Data []*Account `json:"data"` + + // meta + Meta *ResponseMeta `json:"meta,omitempty"` +} + +// Validate validates this account response +func (m *AccountResponse) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateData(formats); err != nil { + res = append(res, err) + } + + if err := m.validateMeta(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *AccountResponse) validateData(formats strfmt.Registry) error { + if swag.IsZero(m.Data) { // not required + return nil + } + + for i := 0; i < len(m.Data); i++ { + if swag.IsZero(m.Data[i]) { // not required + continue + } + + if m.Data[i] != nil { + if err := m.Data[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("data" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *AccountResponse) validateMeta(formats strfmt.Registry) error { + if swag.IsZero(m.Meta) { // not required + return nil + } + + if m.Meta != nil { + if err := m.Meta.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + +// ContextValidate validate this account response based on the context it is used +func (m *AccountResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateData(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateMeta(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *AccountResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Data); i++ { + + if m.Data[i] != nil { + if err := m.Data[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("data" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *AccountResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { + + if m.Meta != nil { + if err := m.Meta.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + +// MarshalBinary interface implementation +func (m *AccountResponse) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *AccountResponse) UnmarshalBinary(b []byte) error { + var res AccountResponse + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/cloud/cloud_models/address.go b/api/sfgate/sfgate_models/address.go similarity index 53% rename from api/cloud/cloud_models/address.go rename to api/sfgate/sfgate_models/address.go index e6ac2c0..7771cd8 100644 --- a/api/cloud/cloud_models/address.go +++ b/api/sfgate/sfgate_models/address.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package cloud_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -12,8 +12,10 @@ package cloud_models import ( "context" + "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" "github.com/go-openapi/swag" + "github.com/go-openapi/validate" ) // Address address @@ -22,29 +24,62 @@ import ( type Address struct { // City - City string `json:"City,omitempty"` + // Required: true + City *string `json:"city"` // Country full name - Country string `json:"Country,omitempty"` + Country string `json:"country,omitempty"` // Country Code - CountryCode string `json:"CountryCode,omitempty"` + Countrycode string `json:"countrycode,omitempty"` // Postal Code - PostalCode string `json:"PostalCode,omitempty"` + Postalcode string `json:"postalcode,omitempty"` // State full name - State string `json:"State,omitempty"` + State string `json:"state,omitempty"` // State Code - StateCode string `json:"StateCode,omitempty"` + // Required: true + Statecode *string `json:"statecode"` // Street number and name - Street string `json:"Street,omitempty"` + Street string `json:"street,omitempty"` } // Validate validates this address func (m *Address) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateCity(formats); err != nil { + res = append(res, err) + } + + if err := m.validateStatecode(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *Address) validateCity(formats strfmt.Registry) error { + + if err := validate.Required("city", "body", m.City); err != nil { + return err + } + + return nil +} + +func (m *Address) validateStatecode(formats strfmt.Registry) error { + + if err := validate.Required("statecode", "body", m.Statecode); err != nil { + return err + } + return nil } diff --git a/api/sfgate/sfgate_models/authority.go b/api/sfgate/sfgate_models/authority.go new file mode 100644 index 0000000..b26f684 --- /dev/null +++ b/api/sfgate/sfgate_models/authority.go @@ -0,0 +1,138 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// Authority authority +// +// swagger:model Authority +type Authority struct { + + // Account + Accountid string `json:"accountid,omitempty"` + + // Address Line 1 + Addressline1 string `json:"addressline1,omitempty"` + + // Address Line 2 + Addressline2 string `json:"addressline2,omitempty"` + + // Billing Telephone Number + Btn string `json:"btn,omitempty"` + + // City + City string `json:"city,omitempty"` + + // Contact ID + Contactid string `json:"contactid,omitempty"` + + // country + Country string `json:"country,omitempty"` + + // Created By User ID + Createdbyid string `json:"createdbyid,omitempty"` + + // Created Date + Createddate string `json:"createddate,omitempty"` + + // date + Date string `json:"date,omitempty"` + + // Date Approved + Dateapproved string `json:"dateapproved,omitempty"` + + // Taxnexus Record Identifier + ID string `json:"id,omitempty"` + + // Last Modified By User ID + Lastmodifiedbyid string `json:"lastmodifiedbyid,omitempty"` + + // Last Modified Date + Lastmodifieddate string `json:"lastmodifieddate,omitempty"` + + // Losing Carrier + Losingcarrier string `json:"losingcarrier,omitempty"` + + // Authority Number + Name string `json:"name,omitempty"` + + // Name Line 1 + Nameline1 string `json:"nameline1,omitempty"` + + // Name Line 2 + Nameline2 string `json:"nameline2,omitempty"` + + // Opportunity ID + Opportunityid string `json:"opportunityid,omitempty"` + + // Order ID + Orderid string `json:"orderid,omitempty"` + + // UUID Reference the master record that owns this item + Parentfk string `json:"parentfk,omitempty"` + + // Zip Code + Postalcode string `json:"postalcode,omitempty"` + + // Quote ID + Quoteid string `json:"quoteid,omitempty"` + + // Source System identifier for this record, if any + Ref string `json:"ref,omitempty"` + + // State + State string `json:"state,omitempty"` + + // Status + Status string `json:"status,omitempty"` + + // tenant identifier + Tenantid string `json:"tenantid,omitempty"` + + // Transfer Date + Transferdate string `json:"transferdate,omitempty"` + + // Authority Type + Type string `json:"type,omitempty"` +} + +// Validate validates this authority +func (m *Authority) Validate(formats strfmt.Registry) error { + return nil +} + +// ContextValidate validates this authority based on context it is used +func (m *Authority) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *Authority) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *Authority) UnmarshalBinary(b []byte) error { + var res Authority + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/voip/voip_models/authority_request.go b/api/sfgate/sfgate_models/authority_request.go similarity index 68% rename from api/voip/voip_models/authority_request.go rename to api/sfgate/sfgate_models/authority_request.go index c94560c..a017761 100644 --- a/api/voip/voip_models/authority_request.go +++ b/api/sfgate/sfgate_models/authority_request.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package voip_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -24,7 +24,10 @@ import ( type AuthorityRequest struct { // data - Data []*Authority `json:"Data"` + Data []*Authority `json:"data"` + + // meta + Meta *RequestMeta `json:"meta,omitempty"` } // Validate validates this authority request @@ -35,6 +38,10 @@ func (m *AuthorityRequest) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateMeta(formats); err != nil { + res = append(res, err) + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } @@ -54,7 +61,7 @@ func (m *AuthorityRequest) validateData(formats strfmt.Registry) error { if m.Data[i] != nil { if err := m.Data[i].Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -65,6 +72,23 @@ func (m *AuthorityRequest) validateData(formats strfmt.Registry) error { return nil } +func (m *AuthorityRequest) validateMeta(formats strfmt.Registry) error { + if swag.IsZero(m.Meta) { // not required + return nil + } + + if m.Meta != nil { + if err := m.Meta.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + // ContextValidate validate this authority request based on the context it is used func (m *AuthorityRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error @@ -73,6 +97,10 @@ func (m *AuthorityRequest) ContextValidate(ctx context.Context, formats strfmt.R res = append(res, err) } + if err := m.contextValidateMeta(ctx, formats); err != nil { + res = append(res, err) + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } @@ -86,7 +114,7 @@ func (m *AuthorityRequest) contextValidateData(ctx context.Context, formats strf if m.Data[i] != nil { if err := m.Data[i].ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -97,6 +125,20 @@ func (m *AuthorityRequest) contextValidateData(ctx context.Context, formats strf return nil } +func (m *AuthorityRequest) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { + + if m.Meta != nil { + if err := m.Meta.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + // MarshalBinary interface implementation func (m *AuthorityRequest) MarshalBinary() ([]byte, error) { if m == nil { diff --git a/api/voip/voip_models/authority_response.go b/api/sfgate/sfgate_models/authority_response.go similarity index 89% rename from api/voip/voip_models/authority_response.go rename to api/sfgate/sfgate_models/authority_response.go index e6ab5a2..bc49c4a 100644 --- a/api/voip/voip_models/authority_response.go +++ b/api/sfgate/sfgate_models/authority_response.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package voip_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -18,16 +18,16 @@ import ( "github.com/go-openapi/swag" ) -// AuthorityResponse An array of Authority objects +// AuthorityResponse authority response // // swagger:model AuthorityResponse type AuthorityResponse struct { // data - Data []*Authority `json:"Data"` + Data []*Authority `json:"data"` // meta - Meta *ResponseMeta `json:"Meta,omitempty"` + Meta *ResponseMeta `json:"meta,omitempty"` } // Validate validates this authority response @@ -61,7 +61,7 @@ func (m *AuthorityResponse) validateData(formats strfmt.Registry) error { if m.Data[i] != nil { if err := m.Data[i].Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -80,7 +80,7 @@ func (m *AuthorityResponse) validateMeta(formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -114,7 +114,7 @@ func (m *AuthorityResponse) contextValidateData(ctx context.Context, formats str if m.Data[i] != nil { if err := m.Data[i].ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -130,7 +130,7 @@ func (m *AuthorityResponse) contextValidateMeta(ctx context.Context, formats str if m.Meta != nil { if err := m.Meta.ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } diff --git a/api/sfgate/sfgate_models/company.go b/api/sfgate/sfgate_models/company.go new file mode 100644 index 0000000..12f9a56 --- /dev/null +++ b/api/sfgate/sfgate_models/company.go @@ -0,0 +1,260 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// Company company +// +// swagger:model Company +type Company struct { + + // Taxnexus ID of the Account that owns this Company + Accountid string `json:"accountid,omitempty"` + + // Account Number Prefix + Accountnumberprefix string `json:"accountnumberprefix,omitempty"` + + // The next period to be used in periodic billing + Advancedperiodid string `json:"advancedperiodid,omitempty"` + + // billingaddress + Billingaddress *Address `json:"billingaddress,omitempty"` + + // Billing Advice + Billingadvice string `json:"billingadvice,omitempty"` + + // Contact ID + Billingcontactid string `json:"billingcontactid,omitempty"` + + // Billing Email + Billingemail string `json:"billingemail,omitempty"` + + // Billing Phone + Billingphone string `json:"billingphone,omitempty"` + + // Billing Website + Billingwebsite string `json:"billingwebsite,omitempty"` + + // The last closed period + Closedperiodid string `json:"closedperiodid,omitempty"` + + // Chart of Accounts Template Account ID + Coatemplateid string `json:"coatemplateid,omitempty"` + + // Color Accent1 + Coloraccent1 string `json:"coloraccent1,omitempty"` + + // Color Accent2 + Coloraccent2 string `json:"coloraccent2,omitempty"` + + // Color Primary + Colorprimary string `json:"colorprimary,omitempty"` + + // Created By User ID + Createdbyid string `json:"createdbyid,omitempty"` + + // Created Date + Createddate string `json:"createddate,omitempty"` + + // The current period + Currentperiodid string `json:"currentperiodid,omitempty"` + + // The current period's status value + Currentperiodstatus string `json:"currentperiodstatus,omitempty"` + + // User ID of default Customer Success user + Customersuccessid string `json:"customersuccessid,omitempty"` + + // Date Closed + Dateclosed string `json:"dateclosed,omitempty"` + + // defaultaddress + Defaultaddress *Address `json:"defaultaddress,omitempty"` + + // Default Company? + Defaultcompany bool `json:"defaultcompany,omitempty"` + + // Font Name for Body Text + Fontbody string `json:"fontbody,omitempty"` + + // Font Name for Heading + Fontheading string `json:"fontheading,omitempty"` + + // Font Name for Heading Narrow + Fontheadingnarrow string `json:"fontheadingnarrow,omitempty"` + + // Font Names for CSS Link + Fontlink string `json:"fontlink,omitempty"` + + // Font Name for Monospace + Fontmono string `json:"fontmono,omitempty"` + + // Taxnexus Record Id + ID string `json:"id,omitempty"` + + // International Customers? + International bool `json:"international,omitempty"` + + // Last Account Number + Lastaccountnumber int64 `json:"lastaccountnumber,omitempty"` + + // Last Modified By User ID + Lastmodifiedbyid string `json:"lastmodifiedbyid,omitempty"` + + // Last Modified Date + Lastmodifieddate string `json:"lastmodifieddate,omitempty"` + + // Last TaxType Number + Lasttaxtypenumber int64 `json:"lasttaxtypenumber,omitempty"` + + // Logo URL + Logo string `json:"logo,omitempty"` + + // Company Name + Name string `json:"name,omitempty"` + + // The ID of the contact who owns this Company + Ownerid string `json:"ownerid,omitempty"` + + // User ID of the default tax preparer + Preparerid string `json:"preparerid,omitempty"` + + // The ID of the default Pricebook for this company + Pricebookid string `json:"pricebookid,omitempty"` + + // tenant identifier + Tenantid string `json:"tenantid,omitempty"` + + // The ID of the contact who is the User Tech Lead for Company + Usertechleadid string `json:"usertechleadid,omitempty"` +} + +// Validate validates this company +func (m *Company) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateBillingaddress(formats); err != nil { + res = append(res, err) + } + + if err := m.validateDefaultaddress(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *Company) validateBillingaddress(formats strfmt.Registry) error { + if swag.IsZero(m.Billingaddress) { // not required + return nil + } + + if m.Billingaddress != nil { + if err := m.Billingaddress.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("billingaddress") + } + return err + } + } + + return nil +} + +func (m *Company) validateDefaultaddress(formats strfmt.Registry) error { + if swag.IsZero(m.Defaultaddress) { // not required + return nil + } + + if m.Defaultaddress != nil { + if err := m.Defaultaddress.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("defaultaddress") + } + return err + } + } + + return nil +} + +// ContextValidate validate this company based on the context it is used +func (m *Company) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateBillingaddress(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDefaultaddress(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *Company) contextValidateBillingaddress(ctx context.Context, formats strfmt.Registry) error { + + if m.Billingaddress != nil { + if err := m.Billingaddress.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("billingaddress") + } + return err + } + } + + return nil +} + +func (m *Company) contextValidateDefaultaddress(ctx context.Context, formats strfmt.Registry) error { + + if m.Defaultaddress != nil { + if err := m.Defaultaddress.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("defaultaddress") + } + return err + } + } + + return nil +} + +// MarshalBinary interface implementation +func (m *Company) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *Company) UnmarshalBinary(b []byte) error { + var res Company + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/sfgate/sfgate_models/company_response.go b/api/sfgate/sfgate_models/company_response.go new file mode 100644 index 0000000..58f3636 --- /dev/null +++ b/api/sfgate/sfgate_models/company_response.go @@ -0,0 +1,158 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// CompanyResponse An array of Company objects +// +// swagger:model CompanyResponse +type CompanyResponse struct { + + // data + Data []*Company `json:"data"` + + // meta + Meta *ResponseMeta `json:"meta,omitempty"` +} + +// Validate validates this company response +func (m *CompanyResponse) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateData(formats); err != nil { + res = append(res, err) + } + + if err := m.validateMeta(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *CompanyResponse) validateData(formats strfmt.Registry) error { + if swag.IsZero(m.Data) { // not required + return nil + } + + for i := 0; i < len(m.Data); i++ { + if swag.IsZero(m.Data[i]) { // not required + continue + } + + if m.Data[i] != nil { + if err := m.Data[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("data" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *CompanyResponse) validateMeta(formats strfmt.Registry) error { + if swag.IsZero(m.Meta) { // not required + return nil + } + + if m.Meta != nil { + if err := m.Meta.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + +// ContextValidate validate this company response based on the context it is used +func (m *CompanyResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateData(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateMeta(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *CompanyResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Data); i++ { + + if m.Data[i] != nil { + if err := m.Data[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("data" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *CompanyResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { + + if m.Meta != nil { + if err := m.Meta.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + +// MarshalBinary interface implementation +func (m *CompanyResponse) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *CompanyResponse) UnmarshalBinary(b []byte) error { + var res CompanyResponse + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/sfgate/sfgate_models/contact.go b/api/sfgate/sfgate_models/contact.go new file mode 100644 index 0000000..f998e84 --- /dev/null +++ b/api/sfgate/sfgate_models/contact.go @@ -0,0 +1,275 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// Contact contact +// +// swagger:model Contact +type Contact struct { + + // The primary account ID of this contact + Accountid string `json:"accountid,omitempty"` + + // Assistant Name + Assistantname string `json:"assistantname,omitempty"` + + // Asst. Phone + Assistantphone string `json:"assistantphone,omitempty"` + + // Birthdate + Birthdate string `json:"birthdate,omitempty"` + + // Created By User ID + Createdbyid string `json:"createdbyid,omitempty"` + + // Created Date + Createddate string `json:"createddate,omitempty"` + + // Department + Department string `json:"department,omitempty"` + + // Description + Description string `json:"description,omitempty"` + + // Do Not Call? + Donotcall bool `json:"donotcall,omitempty"` + + // Email address + Email string `json:"email,omitempty"` + + // Email Bounce Date + Emailbounceddate string `json:"emailbounceddate,omitempty"` + + // Email Bounce Reason + Emailbouncedreason string `json:"emailbouncedreason,omitempty"` + + // Taxnexus Enrollment Status + Enrollmentstatus string `json:"enrollmentstatus,omitempty"` + + // Fax Number + Fax string `json:"fax,omitempty"` + + // First Name + Firstname string `json:"firstname,omitempty"` + + // Email Opt Out + Hasoptedoutofemail bool `json:"hasoptedoutofemail,omitempty"` + + // Fax Opt Out + Hasoptedoutoffax bool `json:"hasoptedoutoffax,omitempty"` + + // Home Phone + Homephone string `json:"homephone,omitempty"` + + // Taxnexus Record Id + ID string `json:"id,omitempty"` + + // Does this contact have bounced emails? + Isemailbounced bool `json:"isemailbounced,omitempty"` + + // Is Provisioned? + Isprovisioned bool `json:"isprovisioned,omitempty"` + + // Last Modified By User ID + Lastmodifiedbyid string `json:"lastmodifiedbyid,omitempty"` + + // Last Modified Date + Lastmodifieddate string `json:"lastmodifieddate,omitempty"` + + // Last Name + Lastname string `json:"lastname,omitempty"` + + // Lead Source + Leadsource string `json:"leadsource,omitempty"` + + // Level + Level string `json:"level,omitempty"` + + // LinkedIn Page + Linkedin string `json:"linkedin,omitempty"` + + // mailingaddress + Mailingaddress *Address `json:"mailingaddress,omitempty"` + + // Mailing Lists + Mailinglists string `json:"mailinglists,omitempty"` + + // Mobile Phone + Mobilephone string `json:"mobilephone,omitempty"` + + // Full Name + Name string `json:"name,omitempty"` + + // otheraddress + Otheraddress *Address `json:"otheraddress,omitempty"` + + // Other Phone + Otherphone string `json:"otherphone,omitempty"` + + // The User ID of the user who owns this Contact + Ownerid string `json:"ownerid,omitempty"` + + // Personal Email Address for this Contact + Personalemail string `json:"personalemail,omitempty"` + + // Phone Number + Phone string `json:"phone,omitempty"` + + // URL of a photograph of this User + Photourl string `json:"photourl,omitempty"` + + // Recruiting Status + Recruitingstatus string `json:"recruitingstatus,omitempty"` + + // External reference to this contact, if any + Ref string `json:"ref,omitempty"` + + // Reports To Contact ID + Reportstoid string `json:"reportstoid,omitempty"` + + // Contact Salutation + Salutation string `json:"salutation,omitempty"` + + // The Contact Status + Status string `json:"status,omitempty"` + + // tenant identifier + Tenantid string `json:"tenantid,omitempty"` + + // Contact Title + Title string `json:"title,omitempty"` + + // Contact Type + Type string `json:"type,omitempty"` +} + +// Validate validates this contact +func (m *Contact) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateMailingaddress(formats); err != nil { + res = append(res, err) + } + + if err := m.validateOtheraddress(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *Contact) validateMailingaddress(formats strfmt.Registry) error { + if swag.IsZero(m.Mailingaddress) { // not required + return nil + } + + if m.Mailingaddress != nil { + if err := m.Mailingaddress.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("mailingaddress") + } + return err + } + } + + return nil +} + +func (m *Contact) validateOtheraddress(formats strfmt.Registry) error { + if swag.IsZero(m.Otheraddress) { // not required + return nil + } + + if m.Otheraddress != nil { + if err := m.Otheraddress.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("otheraddress") + } + return err + } + } + + return nil +} + +// ContextValidate validate this contact based on the context it is used +func (m *Contact) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateMailingaddress(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateOtheraddress(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *Contact) contextValidateMailingaddress(ctx context.Context, formats strfmt.Registry) error { + + if m.Mailingaddress != nil { + if err := m.Mailingaddress.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("mailingaddress") + } + return err + } + } + + return nil +} + +func (m *Contact) contextValidateOtheraddress(ctx context.Context, formats strfmt.Registry) error { + + if m.Otheraddress != nil { + if err := m.Otheraddress.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("otheraddress") + } + return err + } + } + + return nil +} + +// MarshalBinary interface implementation +func (m *Contact) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *Contact) UnmarshalBinary(b []byte) error { + var res Contact + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/sfgate/sfgate_models/contact_request.go b/api/sfgate/sfgate_models/contact_request.go new file mode 100644 index 0000000..6a1bbf2 --- /dev/null +++ b/api/sfgate/sfgate_models/contact_request.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// ContactRequest contact request +// +// swagger:model ContactRequest +type ContactRequest struct { + + // data + // Required: true + Data []*Contact `json:"data"` + + // meta + // Required: true + Meta *RequestMeta `json:"meta"` +} + +// Validate validates this contact request +func (m *ContactRequest) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateData(formats); err != nil { + res = append(res, err) + } + + if err := m.validateMeta(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *ContactRequest) validateData(formats strfmt.Registry) error { + + if err := validate.Required("data", "body", m.Data); err != nil { + return err + } + + for i := 0; i < len(m.Data); i++ { + if swag.IsZero(m.Data[i]) { // not required + continue + } + + if m.Data[i] != nil { + if err := m.Data[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("data" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *ContactRequest) validateMeta(formats strfmt.Registry) error { + + if err := validate.Required("meta", "body", m.Meta); err != nil { + return err + } + + if m.Meta != nil { + if err := m.Meta.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + +// ContextValidate validate this contact request based on the context it is used +func (m *ContactRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateData(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateMeta(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *ContactRequest) contextValidateData(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Data); i++ { + + if m.Data[i] != nil { + if err := m.Data[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("data" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *ContactRequest) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { + + if m.Meta != nil { + if err := m.Meta.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + +// MarshalBinary interface implementation +func (m *ContactRequest) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *ContactRequest) UnmarshalBinary(b []byte) error { + var res ContactRequest + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/voip/voip_models/pbx_user_response.go b/api/sfgate/sfgate_models/contact_response.go similarity index 67% rename from api/voip/voip_models/pbx_user_response.go rename to api/sfgate/sfgate_models/contact_response.go index a6528e2..7960fae 100644 --- a/api/voip/voip_models/pbx_user_response.go +++ b/api/sfgate/sfgate_models/contact_response.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package voip_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -18,20 +18,20 @@ import ( "github.com/go-openapi/swag" ) -// PbxUserResponse An array of PBX objects +// ContactResponse contact response // -// swagger:model PbxUserResponse -type PbxUserResponse struct { +// swagger:model ContactResponse +type ContactResponse struct { // data - Data []*PbxUser `json:"Data"` + Data []*Contact `json:"data"` // meta - Meta *ResponseMeta `json:"Meta,omitempty"` + Meta *ResponseMeta `json:"meta,omitempty"` } -// Validate validates this pbx user response -func (m *PbxUserResponse) Validate(formats strfmt.Registry) error { +// Validate validates this contact response +func (m *ContactResponse) Validate(formats strfmt.Registry) error { var res []error if err := m.validateData(formats); err != nil { @@ -48,7 +48,7 @@ func (m *PbxUserResponse) Validate(formats strfmt.Registry) error { return nil } -func (m *PbxUserResponse) validateData(formats strfmt.Registry) error { +func (m *ContactResponse) validateData(formats strfmt.Registry) error { if swag.IsZero(m.Data) { // not required return nil } @@ -61,7 +61,7 @@ func (m *PbxUserResponse) validateData(formats strfmt.Registry) error { if m.Data[i] != nil { if err := m.Data[i].Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -72,7 +72,7 @@ func (m *PbxUserResponse) validateData(formats strfmt.Registry) error { return nil } -func (m *PbxUserResponse) validateMeta(formats strfmt.Registry) error { +func (m *ContactResponse) validateMeta(formats strfmt.Registry) error { if swag.IsZero(m.Meta) { // not required return nil } @@ -80,7 +80,7 @@ func (m *PbxUserResponse) validateMeta(formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -89,8 +89,8 @@ func (m *PbxUserResponse) validateMeta(formats strfmt.Registry) error { return nil } -// ContextValidate validate this pbx user response based on the context it is used -func (m *PbxUserResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { +// ContextValidate validate this contact response based on the context it is used +func (m *ContactResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error if err := m.contextValidateData(ctx, formats); err != nil { @@ -107,14 +107,14 @@ func (m *PbxUserResponse) ContextValidate(ctx context.Context, formats strfmt.Re return nil } -func (m *PbxUserResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { +func (m *ContactResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Data); i++ { if m.Data[i] != nil { if err := m.Data[i].ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -125,12 +125,12 @@ func (m *PbxUserResponse) contextValidateData(ctx context.Context, formats strfm return nil } -func (m *PbxUserResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { +func (m *ContactResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -140,7 +140,7 @@ func (m *PbxUserResponse) contextValidateMeta(ctx context.Context, formats strfm } // MarshalBinary interface implementation -func (m *PbxUserResponse) MarshalBinary() ([]byte, error) { +func (m *ContactResponse) MarshalBinary() ([]byte, error) { if m == nil { return nil, nil } @@ -148,8 +148,8 @@ func (m *PbxUserResponse) MarshalBinary() ([]byte, error) { } // UnmarshalBinary interface implementation -func (m *PbxUserResponse) UnmarshalBinary(b []byte) error { - var res PbxUserResponse +func (m *ContactResponse) UnmarshalBinary(b []byte) error { + var res ContactResponse if err := swag.ReadJSON(b, &res); err != nil { return err } diff --git a/api/sfgate/sfgate_models/contract_basic.go b/api/sfgate/sfgate_models/contract_basic.go new file mode 100644 index 0000000..37d3fdd --- /dev/null +++ b/api/sfgate/sfgate_models/contract_basic.go @@ -0,0 +1,93 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// ContractBasic contract basic +// +// swagger:model ContractBasic +type ContractBasic struct { + + // Description + Description string `json:"description,omitempty"` + + // Contract End Date + Enddate string `json:"enddate,omitempty"` + + // Hourly Rate + Hourlyrate float64 `json:"hourlyrate,omitempty"` + + // Taxnexus Record Id + ID string `json:"id,omitempty"` + + // Is Active? + Isactive bool `json:"isactive,omitempty"` + + // Contract Name + Name string `json:"name,omitempty"` + + // UUID Reference the master record that owns this item + Parentfk string `json:"parentfk,omitempty"` + + // Payment Terms + Paymentterms string `json:"paymentterms,omitempty"` + + // Price Book + Pricebook2id string `json:"pricebook2id,omitempty"` + + // Source System identifier for this record, if any + Ref string `json:"ref,omitempty"` + + // Contract Start Date + Startdate string `json:"startdate,omitempty"` + + // Status + Status string `json:"status,omitempty"` + + // tenant identifier + Tenantid string `json:"tenantid,omitempty"` + + // Contract Type + Type string `json:"type,omitempty"` +} + +// Validate validates this contract basic +func (m *ContractBasic) Validate(formats strfmt.Registry) error { + return nil +} + +// ContextValidate validates this contract basic based on context it is used +func (m *ContractBasic) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *ContractBasic) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *ContractBasic) UnmarshalBinary(b []byte) error { + var res ContractBasic + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/isp/isp_models/error.go b/api/sfgate/sfgate_models/error.go similarity index 95% rename from api/isp/isp_models/error.go rename to api/sfgate/sfgate_models/error.go index 3e79517..f16e4c9 100644 --- a/api/isp/isp_models/error.go +++ b/api/sfgate/sfgate_models/error.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package isp_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command diff --git a/api/sfgate/sfgate_models/ids.go b/api/sfgate/sfgate_models/ids.go new file mode 100644 index 0000000..a35e2d7 --- /dev/null +++ b/api/sfgate/sfgate_models/ids.go @@ -0,0 +1,31 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/strfmt" +) + +// Ids Taxnexus Record Ids +// +// swagger:model Ids +type Ids []string + +// Validate validates this ids +func (m Ids) Validate(formats strfmt.Registry) error { + return nil +} + +// ContextValidate validates this ids based on context it is used +func (m Ids) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} diff --git a/api/sfgate/sfgate_models/ids_request.go b/api/sfgate/sfgate_models/ids_request.go new file mode 100644 index 0000000..897de3f --- /dev/null +++ b/api/sfgate/sfgate_models/ids_request.go @@ -0,0 +1,151 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// IdsRequest ids request +// +// swagger:model IdsRequest +type IdsRequest struct { + + // data + Data []Ids `json:"data"` + + // meta + Meta *RequestMeta `json:"meta,omitempty"` +} + +// Validate validates this ids request +func (m *IdsRequest) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateData(formats); err != nil { + res = append(res, err) + } + + if err := m.validateMeta(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *IdsRequest) validateData(formats strfmt.Registry) error { + if swag.IsZero(m.Data) { // not required + return nil + } + + for i := 0; i < len(m.Data); i++ { + + if err := m.Data[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("data" + "." + strconv.Itoa(i)) + } + return err + } + + } + + return nil +} + +func (m *IdsRequest) validateMeta(formats strfmt.Registry) error { + if swag.IsZero(m.Meta) { // not required + return nil + } + + if m.Meta != nil { + if err := m.Meta.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + +// ContextValidate validate this ids request based on the context it is used +func (m *IdsRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateData(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateMeta(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *IdsRequest) contextValidateData(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Data); i++ { + + if err := m.Data[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("data" + "." + strconv.Itoa(i)) + } + return err + } + + } + + return nil +} + +func (m *IdsRequest) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { + + if m.Meta != nil { + if err := m.Meta.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + +// MarshalBinary interface implementation +func (m *IdsRequest) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *IdsRequest) UnmarshalBinary(b []byte) error { + var res IdsRequest + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/sfgate/sfgate_models/invalid_error.go b/api/sfgate/sfgate_models/invalid_error.go new file mode 100644 index 0000000..ae9631d --- /dev/null +++ b/api/sfgate/sfgate_models/invalid_error.go @@ -0,0 +1,121 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// InvalidError invalid error +// +// swagger:model InvalidError +type InvalidError struct { + Error + + // details + Details []string `json:"details"` +} + +// UnmarshalJSON unmarshals this object from a JSON structure +func (m *InvalidError) UnmarshalJSON(raw []byte) error { + // AO0 + var aO0 Error + if err := swag.ReadJSON(raw, &aO0); err != nil { + return err + } + m.Error = aO0 + + // AO1 + var dataAO1 struct { + Details []string `json:"details"` + } + if err := swag.ReadJSON(raw, &dataAO1); err != nil { + return err + } + + m.Details = dataAO1.Details + + return nil +} + +// MarshalJSON marshals this object to a JSON structure +func (m InvalidError) MarshalJSON() ([]byte, error) { + _parts := make([][]byte, 0, 2) + + aO0, err := swag.WriteJSON(m.Error) + if err != nil { + return nil, err + } + _parts = append(_parts, aO0) + var dataAO1 struct { + Details []string `json:"details"` + } + + dataAO1.Details = m.Details + + jsonDataAO1, errAO1 := swag.WriteJSON(dataAO1) + if errAO1 != nil { + return nil, errAO1 + } + _parts = append(_parts, jsonDataAO1) + return swag.ConcatJSON(_parts...), nil +} + +// Validate validates this invalid error +func (m *InvalidError) Validate(formats strfmt.Registry) error { + var res []error + + // validation for a type composition with Error + if err := m.Error.Validate(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +// ContextValidate validate this invalid error based on the context it is used +func (m *InvalidError) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + // validation for a type composition with Error + if err := m.Error.ContextValidate(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +// MarshalBinary interface implementation +func (m *InvalidError) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *InvalidError) UnmarshalBinary(b []byte) error { + var res InvalidError + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/cloud/cloud_models/message.go b/api/sfgate/sfgate_models/message.go similarity index 91% rename from api/cloud/cloud_models/message.go rename to api/sfgate/sfgate_models/message.go index d3abda8..182b640 100644 --- a/api/cloud/cloud_models/message.go +++ b/api/sfgate/sfgate_models/message.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package cloud_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -26,6 +26,9 @@ type Message struct { // ref Ref string `json:"ref,omitempty"` + + // status + Status int64 `json:"status,omitempty"` } // Validate validates this message diff --git a/api/sfgate/sfgate_models/notebook.go b/api/sfgate/sfgate_models/notebook.go new file mode 100644 index 0000000..0672c55 --- /dev/null +++ b/api/sfgate/sfgate_models/notebook.go @@ -0,0 +1,164 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// Notebook Defines a Taxnexus Notebook +// +// swagger:model Notebook +type Notebook struct { + + // Account + Accountid string `json:"accountid,omitempty"` + + // Contact + Contactid string `json:"contactid,omitempty"` + + // Created By + Createdbyid string `json:"createdbyid,omitempty"` + + // Created Date + Createddate string `json:"createddate,omitempty"` + + // Analysis Date + Date string `json:"date,omitempty"` + + // End Date + Dateend string `json:"dateend,omitempty"` + + // Start Date + Datestart string `json:"datestart,omitempty"` + + // Description + Description string `json:"description,omitempty"` + + // Record Id + ID string `json:"id,omitempty"` + + // items + Items []*NotebookItem `json:"items"` + + // Last Modified By + Lastmodifiedbyid string `json:"lastmodifiedbyid,omitempty"` + + // Last Modifed Date + Lastmodifieddate string `json:"lastmodifieddate,omitempty"` + + // Ending Period + Periodendid string `json:"periodendid,omitempty"` + + // Starting Period + Periodstartid string `json:"periodstartid,omitempty"` + + // Preparer + Preparerid string `json:"preparerid,omitempty"` + + // tenant identifier + Tenantid string `json:"tenantid,omitempty"` + + // Title + Title string `json:"title,omitempty"` +} + +// Validate validates this notebook +func (m *Notebook) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateItems(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *Notebook) validateItems(formats strfmt.Registry) error { + if swag.IsZero(m.Items) { // not required + return nil + } + + for i := 0; i < len(m.Items); i++ { + if swag.IsZero(m.Items[i]) { // not required + continue + } + + if m.Items[i] != nil { + if err := m.Items[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("items" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// ContextValidate validate this notebook based on the context it is used +func (m *Notebook) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateItems(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *Notebook) contextValidateItems(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Items); i++ { + + if m.Items[i] != nil { + if err := m.Items[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("items" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (m *Notebook) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *Notebook) UnmarshalBinary(b []byte) error { + var res Notebook + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/sfgate/sfgate_models/notebook_item.go b/api/sfgate/sfgate_models/notebook_item.go new file mode 100644 index 0000000..952d858 --- /dev/null +++ b/api/sfgate/sfgate_models/notebook_item.go @@ -0,0 +1,66 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NotebookItem An analysis item associated with a Notebook +// +// swagger:model NotebookItem +type NotebookItem struct { + + // Record Id + ID string `json:"id,omitempty"` + + // Developer name of component + Itemname string `json:"itemname,omitempty"` + + // The notebook that owns this Item + Notebookid string `json:"notebookid,omitempty"` + + // tenant identifier + Tenantid string `json:"tenantid,omitempty"` + + // Display title + Title string `json:"title,omitempty"` +} + +// Validate validates this notebook item +func (m *NotebookItem) Validate(formats strfmt.Registry) error { + return nil +} + +// ContextValidate validates this notebook item based on context it is used +func (m *NotebookItem) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *NotebookItem) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *NotebookItem) UnmarshalBinary(b []byte) error { + var res NotebookItem + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/sfgate/sfgate_models/notebook_request.go b/api/sfgate/sfgate_models/notebook_request.go new file mode 100644 index 0000000..37f7846 --- /dev/null +++ b/api/sfgate/sfgate_models/notebook_request.go @@ -0,0 +1,158 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NotebookRequest An array of Notebook objects +// +// swagger:model NotebookRequest +type NotebookRequest struct { + + // data + Data []*Notebook `json:"data"` + + // meta + Meta *RequestMeta `json:"meta,omitempty"` +} + +// Validate validates this notebook request +func (m *NotebookRequest) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateData(formats); err != nil { + res = append(res, err) + } + + if err := m.validateMeta(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NotebookRequest) validateData(formats strfmt.Registry) error { + if swag.IsZero(m.Data) { // not required + return nil + } + + for i := 0; i < len(m.Data); i++ { + if swag.IsZero(m.Data[i]) { // not required + continue + } + + if m.Data[i] != nil { + if err := m.Data[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("data" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *NotebookRequest) validateMeta(formats strfmt.Registry) error { + if swag.IsZero(m.Meta) { // not required + return nil + } + + if m.Meta != nil { + if err := m.Meta.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + +// ContextValidate validate this notebook request based on the context it is used +func (m *NotebookRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateData(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateMeta(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NotebookRequest) contextValidateData(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Data); i++ { + + if m.Data[i] != nil { + if err := m.Data[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("data" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *NotebookRequest) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { + + if m.Meta != nil { + if err := m.Meta.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + +// MarshalBinary interface implementation +func (m *NotebookRequest) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *NotebookRequest) UnmarshalBinary(b []byte) error { + var res NotebookRequest + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/voip/voip_models/endpoint_response.go b/api/sfgate/sfgate_models/notebook_response.go similarity index 67% rename from api/voip/voip_models/endpoint_response.go rename to api/sfgate/sfgate_models/notebook_response.go index 1f918ea..2adc282 100644 --- a/api/voip/voip_models/endpoint_response.go +++ b/api/sfgate/sfgate_models/notebook_response.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package voip_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -18,20 +18,20 @@ import ( "github.com/go-openapi/swag" ) -// EndpointResponse An array of Endpoint objects sent in response to a request +// NotebookResponse An array of Notebook objects // -// swagger:model EndpointResponse -type EndpointResponse struct { +// swagger:model NotebookResponse +type NotebookResponse struct { // data - Data []*Endpoint `json:"Data"` + Data []*Notebook `json:"data"` // meta - Meta *ResponseMeta `json:"Meta,omitempty"` + Meta *ResponseMeta `json:"meta,omitempty"` } -// Validate validates this endpoint response -func (m *EndpointResponse) Validate(formats strfmt.Registry) error { +// Validate validates this notebook response +func (m *NotebookResponse) Validate(formats strfmt.Registry) error { var res []error if err := m.validateData(formats); err != nil { @@ -48,7 +48,7 @@ func (m *EndpointResponse) Validate(formats strfmt.Registry) error { return nil } -func (m *EndpointResponse) validateData(formats strfmt.Registry) error { +func (m *NotebookResponse) validateData(formats strfmt.Registry) error { if swag.IsZero(m.Data) { // not required return nil } @@ -61,7 +61,7 @@ func (m *EndpointResponse) validateData(formats strfmt.Registry) error { if m.Data[i] != nil { if err := m.Data[i].Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -72,7 +72,7 @@ func (m *EndpointResponse) validateData(formats strfmt.Registry) error { return nil } -func (m *EndpointResponse) validateMeta(formats strfmt.Registry) error { +func (m *NotebookResponse) validateMeta(formats strfmt.Registry) error { if swag.IsZero(m.Meta) { // not required return nil } @@ -80,7 +80,7 @@ func (m *EndpointResponse) validateMeta(formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -89,8 +89,8 @@ func (m *EndpointResponse) validateMeta(formats strfmt.Registry) error { return nil } -// ContextValidate validate this endpoint response based on the context it is used -func (m *EndpointResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { +// ContextValidate validate this notebook response based on the context it is used +func (m *NotebookResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error if err := m.contextValidateData(ctx, formats); err != nil { @@ -107,14 +107,14 @@ func (m *EndpointResponse) ContextValidate(ctx context.Context, formats strfmt.R return nil } -func (m *EndpointResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { +func (m *NotebookResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Data); i++ { if m.Data[i] != nil { if err := m.Data[i].ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -125,12 +125,12 @@ func (m *EndpointResponse) contextValidateData(ctx context.Context, formats strf return nil } -func (m *EndpointResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { +func (m *NotebookResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -140,7 +140,7 @@ func (m *EndpointResponse) contextValidateMeta(ctx context.Context, formats strf } // MarshalBinary interface implementation -func (m *EndpointResponse) MarshalBinary() ([]byte, error) { +func (m *NotebookResponse) MarshalBinary() ([]byte, error) { if m == nil { return nil, nil } @@ -148,8 +148,8 @@ func (m *EndpointResponse) MarshalBinary() ([]byte, error) { } // UnmarshalBinary interface implementation -func (m *EndpointResponse) UnmarshalBinary(b []byte) error { - var res EndpointResponse +func (m *NotebookResponse) UnmarshalBinary(b []byte) error { + var res NotebookResponse if err := swag.ReadJSON(b, &res); err != nil { return err } diff --git a/api/sfgate/sfgate_models/pagination.go b/api/sfgate/sfgate_models/pagination.go new file mode 100644 index 0000000..b724c61 --- /dev/null +++ b/api/sfgate/sfgate_models/pagination.go @@ -0,0 +1,66 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// Pagination pagination +// +// swagger:model Pagination +type Pagination struct { + + // next link + NextLink string `json:"NextLink,omitempty"` + + // p limit + PLimit int64 `json:"PLimit,omitempty"` + + // p offset + POffset int64 `json:"POffset,omitempty"` + + // page size + PageSize int64 `json:"PageSize,omitempty"` + + // set size + SetSize int64 `json:"SetSize,omitempty"` +} + +// Validate validates this pagination +func (m *Pagination) Validate(formats strfmt.Registry) error { + return nil +} + +// ContextValidate validates this pagination based on context it is used +func (m *Pagination) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *Pagination) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *Pagination) UnmarshalBinary(b []byte) error { + var res Pagination + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/sfgate/sfgate_models/product.go b/api/sfgate/sfgate_models/product.go new file mode 100644 index 0000000..3658628 --- /dev/null +++ b/api/sfgate/sfgate_models/product.go @@ -0,0 +1,168 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// Product product +// +// swagger:model Product +type Product struct { + + // The ID of the Account that owns this product + AccountID string `json:"AccountID,omitempty"` + + // Agency Type + AgencyType string `json:"AgencyType,omitempty"` + + // Asset Tracking? + AssetTracking bool `json:"AssetTracking,omitempty"` + + // ID of who created this record instance + CreatedByID string `json:"CreatedByID,omitempty"` + + // Date of record creation + CreatedDate string `json:"CreatedDate,omitempty"` + + // Product Description + Description string `json:"Description,omitempty"` + + // DescriptionSKU + DescriptionSKU string `json:"DescriptionSKU,omitempty"` + + // Display URL + DisplayURL string `json:"DisplayURL,omitempty"` + + // Product Family + Family string `json:"Family,omitempty"` + + // Taxnexus Record Id + ID string `json:"ID,omitempty"` + + // Image (500) + Image500 string `json:"Image500,omitempty"` + + // Image (Full) + ImageFull string `json:"ImageFull,omitempty"` + + // Inventory Tracking? + InventoryTracking bool `json:"InventoryTracking,omitempty"` + + // Active + IsActive bool `json:"IsActive,omitempty"` + + // isGeneric + IsGeneric bool `json:"IsGeneric,omitempty"` + + // Last Modified Date + LastModfiedDate string `json:"LastModfiedDate,omitempty"` + + // Last modified by ID + LastModifiedByID string `json:"LastModifiedByID,omitempty"` + + // MRC Interval + MRCInterval int64 `json:"MRCInterval,omitempty"` + + // MSRP + MSRP float64 `json:"MSRP,omitempty"` + + // Manufacturer + Manufacturer string `json:"Manufacturer,omitempty"` + + // Manufacturer Product Code + ManufacturerProductCode string `json:"ManufacturerProductCode,omitempty"` + + // Product Name + Name string `json:"Name,omitempty"` + + // Product Code + ProductCode string `json:"ProductCode,omitempty"` + + // Prorateable? + Prorateable bool `json:"Prorateable,omitempty"` + + // Publish? + Publish bool `json:"Publish,omitempty"` + + // Publish UPC + PublishUPC string `json:"PublishUPC,omitempty"` + + // Quantity Unit Of Measure + QuantityUnitOfMeasure string `json:"QuantityUnitOfMeasure,omitempty"` + + // Refundable? + Refundable bool `json:"Refundable,omitempty"` + + // SKU + SKU string `json:"SKU,omitempty"` + + // Shipping Weight + ShippingWeight float64 `json:"ShippingWeight,omitempty"` + + // Specifications + Specifications string `json:"Specifications,omitempty"` + + // Taxnexus Code Name + TaxnexusCode string `json:"TaxnexusCode,omitempty"` + + // Taxnexus Code + TaxnexusCodeID string `json:"TaxnexusCodeID,omitempty"` + + // tenant identifier + TenantID string `json:"TenantID,omitempty"` + + // Units + Units string `json:"Units,omitempty"` + + // Vendor + VendorID string `json:"VendorID,omitempty"` + + // Vendor Name + VendorName string `json:"VendorName,omitempty"` + + // Vendor Part Number + VendorPartNumber string `json:"VendorPartNumber,omitempty"` + + // Vendor Price + VendorPrice float64 `json:"VendorPrice,omitempty"` +} + +// Validate validates this product +func (m *Product) Validate(formats strfmt.Registry) error { + return nil +} + +// ContextValidate validates this product based on context it is used +func (m *Product) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *Product) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *Product) UnmarshalBinary(b []byte) error { + var res Product + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/voip/voip_models/vm_box_response.go b/api/sfgate/sfgate_models/product_request.go similarity index 65% rename from api/voip/voip_models/vm_box_response.go rename to api/sfgate/sfgate_models/product_request.go index 604ef38..2dbdfca 100644 --- a/api/voip/voip_models/vm_box_response.go +++ b/api/sfgate/sfgate_models/product_request.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package voip_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -18,20 +18,20 @@ import ( "github.com/go-openapi/swag" ) -// VMBoxResponse An array of VmBox objects +// ProductRequest product request // -// swagger:model VmBoxResponse -type VMBoxResponse struct { +// swagger:model ProductRequest +type ProductRequest struct { // data - Data []*VMBox `json:"Data"` + Data []*Product `json:"data"` // meta - Meta *ResponseMeta `json:"Meta,omitempty"` + Meta *RequestMeta `json:"meta,omitempty"` } -// Validate validates this Vm box response -func (m *VMBoxResponse) Validate(formats strfmt.Registry) error { +// Validate validates this product request +func (m *ProductRequest) Validate(formats strfmt.Registry) error { var res []error if err := m.validateData(formats); err != nil { @@ -48,7 +48,7 @@ func (m *VMBoxResponse) Validate(formats strfmt.Registry) error { return nil } -func (m *VMBoxResponse) validateData(formats strfmt.Registry) error { +func (m *ProductRequest) validateData(formats strfmt.Registry) error { if swag.IsZero(m.Data) { // not required return nil } @@ -61,7 +61,7 @@ func (m *VMBoxResponse) validateData(formats strfmt.Registry) error { if m.Data[i] != nil { if err := m.Data[i].Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -72,7 +72,7 @@ func (m *VMBoxResponse) validateData(formats strfmt.Registry) error { return nil } -func (m *VMBoxResponse) validateMeta(formats strfmt.Registry) error { +func (m *ProductRequest) validateMeta(formats strfmt.Registry) error { if swag.IsZero(m.Meta) { // not required return nil } @@ -80,7 +80,7 @@ func (m *VMBoxResponse) validateMeta(formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -89,8 +89,8 @@ func (m *VMBoxResponse) validateMeta(formats strfmt.Registry) error { return nil } -// ContextValidate validate this Vm box response based on the context it is used -func (m *VMBoxResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { +// ContextValidate validate this product request based on the context it is used +func (m *ProductRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error if err := m.contextValidateData(ctx, formats); err != nil { @@ -107,14 +107,14 @@ func (m *VMBoxResponse) ContextValidate(ctx context.Context, formats strfmt.Regi return nil } -func (m *VMBoxResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { +func (m *ProductRequest) contextValidateData(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Data); i++ { if m.Data[i] != nil { if err := m.Data[i].ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -125,12 +125,12 @@ func (m *VMBoxResponse) contextValidateData(ctx context.Context, formats strfmt. return nil } -func (m *VMBoxResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { +func (m *ProductRequest) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -140,7 +140,7 @@ func (m *VMBoxResponse) contextValidateMeta(ctx context.Context, formats strfmt. } // MarshalBinary interface implementation -func (m *VMBoxResponse) MarshalBinary() ([]byte, error) { +func (m *ProductRequest) MarshalBinary() ([]byte, error) { if m == nil { return nil, nil } @@ -148,8 +148,8 @@ func (m *VMBoxResponse) MarshalBinary() ([]byte, error) { } // UnmarshalBinary interface implementation -func (m *VMBoxResponse) UnmarshalBinary(b []byte) error { - var res VMBoxResponse +func (m *ProductRequest) UnmarshalBinary(b []byte) error { + var res ProductRequest if err := swag.ReadJSON(b, &res); err != nil { return err } diff --git a/api/voip/voip_models/pbx_response.go b/api/sfgate/sfgate_models/product_response.go similarity index 65% rename from api/voip/voip_models/pbx_response.go rename to api/sfgate/sfgate_models/product_response.go index fe33c2b..306aa39 100644 --- a/api/voip/voip_models/pbx_response.go +++ b/api/sfgate/sfgate_models/product_response.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package voip_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -18,20 +18,20 @@ import ( "github.com/go-openapi/swag" ) -// PbxResponse An array of Authority objects +// ProductResponse product response // -// swagger:model PbxResponse -type PbxResponse struct { +// swagger:model ProductResponse +type ProductResponse struct { // data - Data []*Pbx `json:"Data"` + Data []*Product `json:"data"` // meta - Meta *ResponseMeta `json:"Meta,omitempty"` + Meta *ResponseMeta `json:"meta,omitempty"` } -// Validate validates this pbx response -func (m *PbxResponse) Validate(formats strfmt.Registry) error { +// Validate validates this product response +func (m *ProductResponse) Validate(formats strfmt.Registry) error { var res []error if err := m.validateData(formats); err != nil { @@ -48,7 +48,7 @@ func (m *PbxResponse) Validate(formats strfmt.Registry) error { return nil } -func (m *PbxResponse) validateData(formats strfmt.Registry) error { +func (m *ProductResponse) validateData(formats strfmt.Registry) error { if swag.IsZero(m.Data) { // not required return nil } @@ -61,7 +61,7 @@ func (m *PbxResponse) validateData(formats strfmt.Registry) error { if m.Data[i] != nil { if err := m.Data[i].Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -72,7 +72,7 @@ func (m *PbxResponse) validateData(formats strfmt.Registry) error { return nil } -func (m *PbxResponse) validateMeta(formats strfmt.Registry) error { +func (m *ProductResponse) validateMeta(formats strfmt.Registry) error { if swag.IsZero(m.Meta) { // not required return nil } @@ -80,7 +80,7 @@ func (m *PbxResponse) validateMeta(formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -89,8 +89,8 @@ func (m *PbxResponse) validateMeta(formats strfmt.Registry) error { return nil } -// ContextValidate validate this pbx response based on the context it is used -func (m *PbxResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { +// ContextValidate validate this product response based on the context it is used +func (m *ProductResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error if err := m.contextValidateData(ctx, formats); err != nil { @@ -107,14 +107,14 @@ func (m *PbxResponse) ContextValidate(ctx context.Context, formats strfmt.Regist return nil } -func (m *PbxResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { +func (m *ProductResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Data); i++ { if m.Data[i] != nil { if err := m.Data[i].ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -125,12 +125,12 @@ func (m *PbxResponse) contextValidateData(ctx context.Context, formats strfmt.Re return nil } -func (m *PbxResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { +func (m *ProductResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -140,7 +140,7 @@ func (m *PbxResponse) contextValidateMeta(ctx context.Context, formats strfmt.Re } // MarshalBinary interface implementation -func (m *PbxResponse) MarshalBinary() ([]byte, error) { +func (m *ProductResponse) MarshalBinary() ([]byte, error) { if m == nil { return nil, nil } @@ -148,8 +148,8 @@ func (m *PbxResponse) MarshalBinary() ([]byte, error) { } // UnmarshalBinary interface implementation -func (m *PbxResponse) UnmarshalBinary(b []byte) error { - var res PbxResponse +func (m *ProductResponse) UnmarshalBinary(b []byte) error { + var res ProductResponse if err := swag.ReadJSON(b, &res); err != nil { return err } diff --git a/api/sfgate/sfgate_models/request_meta.go b/api/sfgate/sfgate_models/request_meta.go new file mode 100644 index 0000000..d7671ab --- /dev/null +++ b/api/sfgate/sfgate_models/request_meta.go @@ -0,0 +1,75 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// RequestMeta request meta +// +// swagger:model RequestMeta +type RequestMeta struct { + + // Taxnexus Account Number of the Reseller or OEM + // Required: true + TaxnexusAccount *string `json:"TaxnexusAccount"` +} + +// Validate validates this request meta +func (m *RequestMeta) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateTaxnexusAccount(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *RequestMeta) validateTaxnexusAccount(formats strfmt.Registry) error { + + if err := validate.Required("TaxnexusAccount", "body", m.TaxnexusAccount); err != nil { + return err + } + + return nil +} + +// ContextValidate validates this request meta based on context it is used +func (m *RequestMeta) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *RequestMeta) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *RequestMeta) UnmarshalBinary(b []byte) error { + var res RequestMeta + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/sfgate/sfgate_models/response_meta.go b/api/sfgate/sfgate_models/response_meta.go new file mode 100644 index 0000000..40850cf --- /dev/null +++ b/api/sfgate/sfgate_models/response_meta.go @@ -0,0 +1,143 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// ResponseMeta response meta +// +// swagger:model ResponseMeta +type ResponseMeta struct { + + // Contact Info + Contact string `json:"Contact,omitempty"` + + // Copyright Info + Copyright string `json:"Copyright,omitempty"` + + // API Information + Info string `json:"Info,omitempty"` + + // License Info + License string `json:"License,omitempty"` + + // operation ID + OperationID string `json:"OperationID,omitempty"` + + // pagination + Pagination *Pagination `json:"Pagination,omitempty"` + + // request IP + RequestIP string `json:"RequestIP,omitempty"` + + // request type + RequestType string `json:"RequestType,omitempty"` + + // request URL + RequestURL string `json:"RequestURL,omitempty"` + + // server info + ServerInfo string `json:"ServerInfo,omitempty"` + + // server response time + ServerResponseTime string `json:"ServerResponseTime,omitempty"` + + // server time stamp + ServerTimeStamp string `json:"ServerTimeStamp,omitempty"` + + // taxnexus account + TaxnexusAccount string `json:"TaxnexusAccount,omitempty"` + + // user ID + UserID string `json:"UserID,omitempty"` +} + +// Validate validates this response meta +func (m *ResponseMeta) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validatePagination(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *ResponseMeta) validatePagination(formats strfmt.Registry) error { + if swag.IsZero(m.Pagination) { // not required + return nil + } + + if m.Pagination != nil { + if err := m.Pagination.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("Pagination") + } + return err + } + } + + return nil +} + +// ContextValidate validate this response meta based on the context it is used +func (m *ResponseMeta) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidatePagination(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *ResponseMeta) contextValidatePagination(ctx context.Context, formats strfmt.Registry) error { + + if m.Pagination != nil { + if err := m.Pagination.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("Pagination") + } + return err + } + } + + return nil +} + +// MarshalBinary interface implementation +func (m *ResponseMeta) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *ResponseMeta) UnmarshalBinary(b []byte) error { + var res ResponseMeta + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/sfgate/sfgate_models/role.go b/api/sfgate/sfgate_models/role.go new file mode 100644 index 0000000..de8b908 --- /dev/null +++ b/api/sfgate/sfgate_models/role.go @@ -0,0 +1,78 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// Role A functional role within a Tenant +// +// swagger:model Role +type Role struct { + + // the corresponding auth0 role + Auth0roleid string `json:"auth0roleid,omitempty"` + + // created by + Createdbyid string `json:"createdbyid,omitempty"` + + // created date + Createddate string `json:"createddate,omitempty"` + + // role description + Description string `json:"description,omitempty"` + + // record id + ID string `json:"id,omitempty"` + + // last modified by + Lastmodifiedbyid string `json:"lastmodifiedbyid,omitempty"` + + // last modifed date + Lastmodifieddate string `json:"lastmodifieddate,omitempty"` + + // the name of this role + Rolename string `json:"rolename,omitempty"` + + // the id of the tenant that owns this role + Tenantid string `json:"tenantid,omitempty"` +} + +// Validate validates this role +func (m *Role) Validate(formats strfmt.Registry) error { + return nil +} + +// ContextValidate validates this role based on context it is used +func (m *Role) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *Role) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *Role) UnmarshalBinary(b []byte) error { + var res Role + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/cloud/cloud_models/hub_response.go b/api/sfgate/sfgate_models/role_request.go similarity index 68% rename from api/cloud/cloud_models/hub_response.go rename to api/sfgate/sfgate_models/role_request.go index d348859..4b12316 100644 --- a/api/cloud/cloud_models/hub_response.go +++ b/api/sfgate/sfgate_models/role_request.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package cloud_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -18,20 +18,20 @@ import ( "github.com/go-openapi/swag" ) -// HubResponse An array of Hub objects +// RoleRequest An array of Role objects // -// swagger:model HubResponse -type HubResponse struct { +// swagger:model RoleRequest +type RoleRequest struct { // data - Data []*Hub `json:"Data"` + Data []*Role `json:"data"` // meta - Meta *ResponseMeta `json:"Meta,omitempty"` + Meta *RequestMeta `json:"meta,omitempty"` } -// Validate validates this hub response -func (m *HubResponse) Validate(formats strfmt.Registry) error { +// Validate validates this role request +func (m *RoleRequest) Validate(formats strfmt.Registry) error { var res []error if err := m.validateData(formats); err != nil { @@ -48,7 +48,7 @@ func (m *HubResponse) Validate(formats strfmt.Registry) error { return nil } -func (m *HubResponse) validateData(formats strfmt.Registry) error { +func (m *RoleRequest) validateData(formats strfmt.Registry) error { if swag.IsZero(m.Data) { // not required return nil } @@ -61,7 +61,7 @@ func (m *HubResponse) validateData(formats strfmt.Registry) error { if m.Data[i] != nil { if err := m.Data[i].Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -72,7 +72,7 @@ func (m *HubResponse) validateData(formats strfmt.Registry) error { return nil } -func (m *HubResponse) validateMeta(formats strfmt.Registry) error { +func (m *RoleRequest) validateMeta(formats strfmt.Registry) error { if swag.IsZero(m.Meta) { // not required return nil } @@ -80,7 +80,7 @@ func (m *HubResponse) validateMeta(formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -89,8 +89,8 @@ func (m *HubResponse) validateMeta(formats strfmt.Registry) error { return nil } -// ContextValidate validate this hub response based on the context it is used -func (m *HubResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { +// ContextValidate validate this role request based on the context it is used +func (m *RoleRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error if err := m.contextValidateData(ctx, formats); err != nil { @@ -107,14 +107,14 @@ func (m *HubResponse) ContextValidate(ctx context.Context, formats strfmt.Regist return nil } -func (m *HubResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { +func (m *RoleRequest) contextValidateData(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Data); i++ { if m.Data[i] != nil { if err := m.Data[i].ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -125,12 +125,12 @@ func (m *HubResponse) contextValidateData(ctx context.Context, formats strfmt.Re return nil } -func (m *HubResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { +func (m *RoleRequest) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -140,7 +140,7 @@ func (m *HubResponse) contextValidateMeta(ctx context.Context, formats strfmt.Re } // MarshalBinary interface implementation -func (m *HubResponse) MarshalBinary() ([]byte, error) { +func (m *RoleRequest) MarshalBinary() ([]byte, error) { if m == nil { return nil, nil } @@ -148,8 +148,8 @@ func (m *HubResponse) MarshalBinary() ([]byte, error) { } // UnmarshalBinary interface implementation -func (m *HubResponse) UnmarshalBinary(b []byte) error { - var res HubResponse +func (m *RoleRequest) UnmarshalBinary(b []byte) error { + var res RoleRequest if err := swag.ReadJSON(b, &res); err != nil { return err } diff --git a/api/isp/isp_models/zone_response.go b/api/sfgate/sfgate_models/role_response.go similarity index 75% rename from api/isp/isp_models/zone_response.go rename to api/sfgate/sfgate_models/role_response.go index 59fee6e..d222924 100644 --- a/api/isp/isp_models/zone_response.go +++ b/api/sfgate/sfgate_models/role_response.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package isp_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -18,20 +18,20 @@ import ( "github.com/go-openapi/swag" ) -// ZoneResponse An array of Zone objects +// RoleResponse An array of Role objects // -// swagger:model ZoneResponse -type ZoneResponse struct { +// swagger:model RoleResponse +type RoleResponse struct { // data - Data []*Zone `json:"data"` + Data []*Role `json:"data"` // meta Meta *ResponseMeta `json:"meta,omitempty"` } -// Validate validates this zone response -func (m *ZoneResponse) Validate(formats strfmt.Registry) error { +// Validate validates this role response +func (m *RoleResponse) Validate(formats strfmt.Registry) error { var res []error if err := m.validateData(formats); err != nil { @@ -48,7 +48,7 @@ func (m *ZoneResponse) Validate(formats strfmt.Registry) error { return nil } -func (m *ZoneResponse) validateData(formats strfmt.Registry) error { +func (m *RoleResponse) validateData(formats strfmt.Registry) error { if swag.IsZero(m.Data) { // not required return nil } @@ -72,7 +72,7 @@ func (m *ZoneResponse) validateData(formats strfmt.Registry) error { return nil } -func (m *ZoneResponse) validateMeta(formats strfmt.Registry) error { +func (m *RoleResponse) validateMeta(formats strfmt.Registry) error { if swag.IsZero(m.Meta) { // not required return nil } @@ -89,8 +89,8 @@ func (m *ZoneResponse) validateMeta(formats strfmt.Registry) error { return nil } -// ContextValidate validate this zone response based on the context it is used -func (m *ZoneResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { +// ContextValidate validate this role response based on the context it is used +func (m *RoleResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error if err := m.contextValidateData(ctx, formats); err != nil { @@ -107,7 +107,7 @@ func (m *ZoneResponse) ContextValidate(ctx context.Context, formats strfmt.Regis return nil } -func (m *ZoneResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { +func (m *RoleResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Data); i++ { @@ -125,7 +125,7 @@ func (m *ZoneResponse) contextValidateData(ctx context.Context, formats strfmt.R return nil } -func (m *ZoneResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { +func (m *RoleResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.ContextValidate(ctx, formats); err != nil { @@ -140,7 +140,7 @@ func (m *ZoneResponse) contextValidateMeta(ctx context.Context, formats strfmt.R } // MarshalBinary interface implementation -func (m *ZoneResponse) MarshalBinary() ([]byte, error) { +func (m *RoleResponse) MarshalBinary() ([]byte, error) { if m == nil { return nil, nil } @@ -148,8 +148,8 @@ func (m *ZoneResponse) MarshalBinary() ([]byte, error) { } // UnmarshalBinary interface implementation -func (m *ZoneResponse) UnmarshalBinary(b []byte) error { - var res ZoneResponse +func (m *RoleResponse) UnmarshalBinary(b []byte) error { + var res RoleResponse if err := swag.ReadJSON(b, &res); err != nil { return err } diff --git a/api/sfgate/sfgate_models/template.go b/api/sfgate/sfgate_models/template.go new file mode 100644 index 0000000..79f3f38 --- /dev/null +++ b/api/sfgate/sfgate_models/template.go @@ -0,0 +1,100 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// Template template +// +// swagger:model Template +type Template struct { + + // Company + CompanyID string `json:"CompanyID,omitempty"` + + // created by ID + CreatedByID string `json:"CreatedByID,omitempty"` + + // created date + CreatedDate string `json:"CreatedDate,omitempty"` + + // Description + Description string `json:"Description,omitempty"` + + // HTML Body + // Format: byte + HTML strfmt.Base64 `json:"HTML,omitempty"` + + // Taxnexus Record Id + ID string `json:"ID,omitempty"` + + // Active? + IsActive bool `json:"IsActive,omitempty"` + + // Master Template? + IsMaster bool `json:"IsMaster,omitempty"` + + // last modified by ID + LastModifiedByID string `json:"LastModifiedByID,omitempty"` + + // last modified date + LastModifiedDate string `json:"LastModifiedDate,omitempty"` + + // Template Name + Name string `json:"Name,omitempty"` + + // Object + ObjectType string `json:"ObjectType,omitempty"` + + // Record Type Name + RecordTypeName string `json:"RecordTypeName,omitempty"` + + // Type + Type string `json:"Type,omitempty"` + + // URL + URL string `json:"URL,omitempty"` + + // tenant identifier + Tenantid string `json:"tenantid,omitempty"` +} + +// Validate validates this template +func (m *Template) Validate(formats strfmt.Registry) error { + return nil +} + +// ContextValidate validates this template based on context it is used +func (m *Template) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *Template) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *Template) UnmarshalBinary(b []byte) error { + var res Template + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/sfgate/sfgate_models/template_response.go b/api/sfgate/sfgate_models/template_response.go new file mode 100644 index 0000000..0c56b03 --- /dev/null +++ b/api/sfgate/sfgate_models/template_response.go @@ -0,0 +1,158 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// TemplateResponse template response +// +// swagger:model TemplateResponse +type TemplateResponse struct { + + // data + Data []*Template `json:"data"` + + // meta + Meta *ResponseMeta `json:"meta,omitempty"` +} + +// Validate validates this template response +func (m *TemplateResponse) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateData(formats); err != nil { + res = append(res, err) + } + + if err := m.validateMeta(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *TemplateResponse) validateData(formats strfmt.Registry) error { + if swag.IsZero(m.Data) { // not required + return nil + } + + for i := 0; i < len(m.Data); i++ { + if swag.IsZero(m.Data[i]) { // not required + continue + } + + if m.Data[i] != nil { + if err := m.Data[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("data" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *TemplateResponse) validateMeta(formats strfmt.Registry) error { + if swag.IsZero(m.Meta) { // not required + return nil + } + + if m.Meta != nil { + if err := m.Meta.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + +// ContextValidate validate this template response based on the context it is used +func (m *TemplateResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateData(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateMeta(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *TemplateResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Data); i++ { + + if m.Data[i] != nil { + if err := m.Data[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("data" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *TemplateResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { + + if m.Meta != nil { + if err := m.Meta.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + +// MarshalBinary interface implementation +func (m *TemplateResponse) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *TemplateResponse) UnmarshalBinary(b []byte) error { + var res TemplateResponse + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/sfgate/sfgate_models/tenant.go b/api/sfgate/sfgate_models/tenant.go new file mode 100644 index 0000000..28556ee --- /dev/null +++ b/api/sfgate/sfgate_models/tenant.go @@ -0,0 +1,202 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// Tenant Taxnexus Account Tenant +// +// swagger:model Tenant +type Tenant struct { + + // The Account that owns this Tenant + Accountid string `json:"accountid,omitempty"` + + // Is this Tenant currently active? + Active bool `json:"active,omitempty"` + + // Created By + Createdbyid string `json:"createdbyid,omitempty"` + + // Created Date + Createddate string `json:"createddate,omitempty"` + + // Record Id + ID string `json:"id,omitempty"` + + // Last Modified By + Lastmodifiedbyid string `json:"lastmodifiedbyid,omitempty"` + + // Last Modifed Date + Lastmodifieddate string `json:"lastmodifieddate,omitempty"` + + // roles + Roles []*Role `json:"roles"` + + // The current status of this Tenant + Status string `json:"status,omitempty"` + + // Name of the Tenant Resource + Tenantname string `json:"tenantname,omitempty"` + + // tenantusers + Tenantusers []*TenantUser `json:"tenantusers"` + + // Type of tenant + Type string `json:"type,omitempty"` + + // The version number of the Tenant Onboarding system used to create this tenant + Version string `json:"version,omitempty"` +} + +// Validate validates this tenant +func (m *Tenant) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateRoles(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTenantusers(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *Tenant) validateRoles(formats strfmt.Registry) error { + if swag.IsZero(m.Roles) { // not required + return nil + } + + for i := 0; i < len(m.Roles); i++ { + if swag.IsZero(m.Roles[i]) { // not required + continue + } + + if m.Roles[i] != nil { + if err := m.Roles[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("roles" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *Tenant) validateTenantusers(formats strfmt.Registry) error { + if swag.IsZero(m.Tenantusers) { // not required + return nil + } + + for i := 0; i < len(m.Tenantusers); i++ { + if swag.IsZero(m.Tenantusers[i]) { // not required + continue + } + + if m.Tenantusers[i] != nil { + if err := m.Tenantusers[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenantusers" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// ContextValidate validate this tenant based on the context it is used +func (m *Tenant) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateRoles(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTenantusers(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *Tenant) contextValidateRoles(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Roles); i++ { + + if m.Roles[i] != nil { + if err := m.Roles[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("roles" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *Tenant) contextValidateTenantusers(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tenantusers); i++ { + + if m.Tenantusers[i] != nil { + if err := m.Tenantusers[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenantusers" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (m *Tenant) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *Tenant) UnmarshalBinary(b []byte) error { + var res Tenant + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/voip/voip_models/queue_response.go b/api/sfgate/sfgate_models/tenant_request.go similarity index 68% rename from api/voip/voip_models/queue_response.go rename to api/sfgate/sfgate_models/tenant_request.go index 3449c34..ab9a9eb 100644 --- a/api/voip/voip_models/queue_response.go +++ b/api/sfgate/sfgate_models/tenant_request.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package voip_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -18,20 +18,20 @@ import ( "github.com/go-openapi/swag" ) -// QueueResponse An array of Recipient objects +// TenantRequest An array of Tenant objects // -// swagger:model QueueResponse -type QueueResponse struct { +// swagger:model TenantRequest +type TenantRequest struct { // data - Data []*Recipient `json:"Data"` + Data []*Tenant `json:"data"` // meta - Meta *ResponseMeta `json:"Meta,omitempty"` + Meta *RequestMeta `json:"meta,omitempty"` } -// Validate validates this queue response -func (m *QueueResponse) Validate(formats strfmt.Registry) error { +// Validate validates this tenant request +func (m *TenantRequest) Validate(formats strfmt.Registry) error { var res []error if err := m.validateData(formats); err != nil { @@ -48,7 +48,7 @@ func (m *QueueResponse) Validate(formats strfmt.Registry) error { return nil } -func (m *QueueResponse) validateData(formats strfmt.Registry) error { +func (m *TenantRequest) validateData(formats strfmt.Registry) error { if swag.IsZero(m.Data) { // not required return nil } @@ -61,7 +61,7 @@ func (m *QueueResponse) validateData(formats strfmt.Registry) error { if m.Data[i] != nil { if err := m.Data[i].Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -72,7 +72,7 @@ func (m *QueueResponse) validateData(formats strfmt.Registry) error { return nil } -func (m *QueueResponse) validateMeta(formats strfmt.Registry) error { +func (m *TenantRequest) validateMeta(formats strfmt.Registry) error { if swag.IsZero(m.Meta) { // not required return nil } @@ -80,7 +80,7 @@ func (m *QueueResponse) validateMeta(formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -89,8 +89,8 @@ func (m *QueueResponse) validateMeta(formats strfmt.Registry) error { return nil } -// ContextValidate validate this queue response based on the context it is used -func (m *QueueResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { +// ContextValidate validate this tenant request based on the context it is used +func (m *TenantRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error if err := m.contextValidateData(ctx, formats); err != nil { @@ -107,14 +107,14 @@ func (m *QueueResponse) ContextValidate(ctx context.Context, formats strfmt.Regi return nil } -func (m *QueueResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { +func (m *TenantRequest) contextValidateData(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Data); i++ { if m.Data[i] != nil { if err := m.Data[i].ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -125,12 +125,12 @@ func (m *QueueResponse) contextValidateData(ctx context.Context, formats strfmt. return nil } -func (m *QueueResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { +func (m *TenantRequest) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -140,7 +140,7 @@ func (m *QueueResponse) contextValidateMeta(ctx context.Context, formats strfmt. } // MarshalBinary interface implementation -func (m *QueueResponse) MarshalBinary() ([]byte, error) { +func (m *TenantRequest) MarshalBinary() ([]byte, error) { if m == nil { return nil, nil } @@ -148,8 +148,8 @@ func (m *QueueResponse) MarshalBinary() ([]byte, error) { } // UnmarshalBinary interface implementation -func (m *QueueResponse) UnmarshalBinary(b []byte) error { - var res QueueResponse +func (m *TenantRequest) UnmarshalBinary(b []byte) error { + var res TenantRequest if err := swag.ReadJSON(b, &res); err != nil { return err } diff --git a/api/sfgate/sfgate_models/tenant_response.go b/api/sfgate/sfgate_models/tenant_response.go new file mode 100644 index 0000000..1257797 --- /dev/null +++ b/api/sfgate/sfgate_models/tenant_response.go @@ -0,0 +1,158 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// TenantResponse An array of Tenant objects +// +// swagger:model TenantResponse +type TenantResponse struct { + + // data + Data []*Tenant `json:"data"` + + // meta + Meta *ResponseMeta `json:"meta,omitempty"` +} + +// Validate validates this tenant response +func (m *TenantResponse) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateData(formats); err != nil { + res = append(res, err) + } + + if err := m.validateMeta(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *TenantResponse) validateData(formats strfmt.Registry) error { + if swag.IsZero(m.Data) { // not required + return nil + } + + for i := 0; i < len(m.Data); i++ { + if swag.IsZero(m.Data[i]) { // not required + continue + } + + if m.Data[i] != nil { + if err := m.Data[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("data" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *TenantResponse) validateMeta(formats strfmt.Registry) error { + if swag.IsZero(m.Meta) { // not required + return nil + } + + if m.Meta != nil { + if err := m.Meta.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + +// ContextValidate validate this tenant response based on the context it is used +func (m *TenantResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateData(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateMeta(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *TenantResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Data); i++ { + + if m.Data[i] != nil { + if err := m.Data[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("data" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *TenantResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { + + if m.Meta != nil { + if err := m.Meta.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("meta") + } + return err + } + } + + return nil +} + +// MarshalBinary interface implementation +func (m *TenantResponse) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *TenantResponse) UnmarshalBinary(b []byte) error { + var res TenantResponse + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/cloud/cloud_models/tenant_user.go b/api/sfgate/sfgate_models/tenant_user.go similarity index 50% rename from api/cloud/cloud_models/tenant_user.go rename to api/sfgate/sfgate_models/tenant_user.go index 3c387ee..0ce54e9 100644 --- a/api/cloud/cloud_models/tenant_user.go +++ b/api/sfgate/sfgate_models/tenant_user.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package cloud_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -21,53 +21,14 @@ import ( // swagger:model TenantUser type TenantUser struct { - // The makeTenantUser access level for this User - AccessLevel string `json:"AccessLevel,omitempty"` - - // Account ID - AccountID string `json:"AccountID,omitempty"` - - // Auth0 User ID - Auth0UserID string `json:"Auth0UserID,omitempty"` - - // Account Name - CompanyName string `json:"CompanyName,omitempty"` - - // Contact ID - ContactID string `json:"ContactID,omitempty"` - - // Taxnexus Account - TelnexusAccount string `json:"TelnexusAccount,omitempty"` - - // Tenant active? - TenantActive bool `json:"TenantActive,omitempty"` + // The Tenant access level for this User + Accesslevel string `json:"accesslevel,omitempty"` // The Tenant ID - TenantID string `json:"TenantID,omitempty"` - - // Tenant Name - TenantName string `json:"TenantName,omitempty"` - - // Tenant Status - TenantStatus string `json:"TenantStatus,omitempty"` - - // Tenant type - TenantType string `json:"TenantType,omitempty"` - - // Tenant Version - TenantVersion string `json:"TenantVersion,omitempty"` - - // User Email Address - UserEmail string `json:"UserEmail,omitempty"` - - // User Full Name - UserFullName string `json:"UserFullName,omitempty"` + Tenantid string `json:"tenantid,omitempty"` // The User ID - UserID string `json:"UserID,omitempty"` - - // Username - Username string `json:"Username,omitempty"` + Userid string `json:"userid,omitempty"` } // Validate validates this tenant user diff --git a/api/sfgate/sfgate_models/user.go b/api/sfgate/sfgate_models/user.go new file mode 100644 index 0000000..6a6258c --- /dev/null +++ b/api/sfgate/sfgate_models/user.go @@ -0,0 +1,376 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// (c) 2012-2020 by Taxnexus, Inc. +// All rights reserved worldwide. +// Proprietary product; unlicensed use is not allowed + +package sfgate_models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// User user +// +// swagger:model User +type User struct { + + // About Me + Aboutme string `json:"aboutme,omitempty"` + + // Account ID + Accountid string `json:"accountid,omitempty"` + + // address + Address *Address `json:"address,omitempty"` + + // Alias + Alias string `json:"alias,omitempty"` + + // API Key + Apikey string `json:"apikey,omitempty"` + + // Auth0 User ID + Auth0userid string `json:"auth0userid,omitempty"` + + // Nickname + Communitynickname string `json:"communitynickname,omitempty"` + + // Company Name + Companyname string `json:"companyname,omitempty"` + + // Contact + Contactid string `json:"contactid,omitempty"` + + // Created User ID + Createdbyid string `json:"createdbyid,omitempty"` + + // Date Created + Createddate string `json:"createddate,omitempty"` + + // Delegated Approver + Delegatedapproverid string `json:"delegatedapproverid,omitempty"` + + // Department + Department string `json:"department,omitempty"` + + // Division + Division string `json:"division,omitempty"` + + // Email address + Email string `json:"email,omitempty"` + + // Employee Number + Employeenumber string `json:"employeenumber,omitempty"` + + // Time day ends + Endday string `json:"endday,omitempty"` + + // Environment + Environment string `json:"environment,omitempty"` + + // Extension + Extension string `json:"extension,omitempty"` + + // Fabric API Key + Fabricapikey string `json:"fabricapikey,omitempty"` + + // Fax + Fax string `json:"fax,omitempty"` + + // The first name + Firstname string `json:"firstname,omitempty"` + + // Allow Forecasting + Forecastenabled bool `json:"forecastenabled,omitempty"` + + // Full Photo URL + Fullphotourl string `json:"fullphotourl,omitempty"` + + // Taxnexus ID + ID string `json:"id,omitempty"` + + // Active + Isactive bool `json:"isactive,omitempty"` + + // Is the user enabled for Communities? + Isportalenabled bool `json:"isportalenabled,omitempty"` + + // Has Profile Photo + Isprofilephotoactive bool `json:"isprofilephotoactive,omitempty"` + + // issystemcontrolled + Issystemcontrolled bool `json:"issystemcontrolled,omitempty"` + + // ip address of last login + Lastip string `json:"lastip,omitempty"` + + // last login time + Lastlogin string `json:"lastlogin,omitempty"` + + // Last Modified User ID + Lastmodifiedbyid string `json:"lastmodifiedbyid,omitempty"` + + // Last Modified Date + Lastmodifieddate string `json:"lastmodifieddate,omitempty"` + + // The Last Name + Lastname string `json:"lastname,omitempty"` + + // number of times user has logged in + Logincount int64 `json:"logincount,omitempty"` + + // Manager + Managerid string `json:"managerid,omitempty"` + + // Mobile + Mobilephone string `json:"mobilephone,omitempty"` + + // Name + Name string `json:"name,omitempty"` + + // Out of office message + Outofofficemessage string `json:"outofofficemessage,omitempty"` + + // Phone + Phone string `json:"phone,omitempty"` + + // Portal Role Level + Portalrole string `json:"portalrole,omitempty"` + + // Profile + Profileid string `json:"profileid,omitempty"` + + // Admin Info Emails + Receivesadmininfoemails bool `json:"receivesadmininfoemails,omitempty"` + + // Info Emails + Receivesinfoemails bool `json:"receivesinfoemails,omitempty"` + + // Email Sender Address + Senderemail string `json:"senderemail,omitempty"` + + // Email Sender Name + Sendername string `json:"sendername,omitempty"` + + // Email Signature + Signature string `json:"signature,omitempty"` + + // Small Photo URL + Smallphotourl string `json:"smallphotourl,omitempty"` + + // The time day starts + Startday string `json:"startday,omitempty"` + + // Taxnexus Account + Taxnexusaccount string `json:"taxnexusaccount,omitempty"` + + // tenantid + Tenantid string `json:"tenantid,omitempty"` + + // tenantusers + Tenantusers []*TenantUser `json:"tenantusers"` + + // Time Zone + Timezonesidkey string `json:"timezonesidkey,omitempty"` + + // Title + Title string `json:"title,omitempty"` + + // Username + Username string `json:"username,omitempty"` + + // Role + Userroleid string `json:"userroleid,omitempty"` + + // userroles + Userroles []*UserRole `json:"userroles"` + + // User Type + Usertype string `json:"usertype,omitempty"` +} + +// Validate validates this user +func (m *User) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateAddress(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTenantusers(formats); err != nil { + res = append(res, err) + } + + if err := m.validateUserroles(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *User) validateAddress(formats strfmt.Registry) error { + if swag.IsZero(m.Address) { // not required + return nil + } + + if m.Address != nil { + if err := m.Address.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("address") + } + return err + } + } + + return nil +} + +func (m *User) validateTenantusers(formats strfmt.Registry) error { + if swag.IsZero(m.Tenantusers) { // not required + return nil + } + + for i := 0; i < len(m.Tenantusers); i++ { + if swag.IsZero(m.Tenantusers[i]) { // not required + continue + } + + if m.Tenantusers[i] != nil { + if err := m.Tenantusers[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenantusers" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *User) validateUserroles(formats strfmt.Registry) error { + if swag.IsZero(m.Userroles) { // not required + return nil + } + + for i := 0; i < len(m.Userroles); i++ { + if swag.IsZero(m.Userroles[i]) { // not required + continue + } + + if m.Userroles[i] != nil { + if err := m.Userroles[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("userroles" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// ContextValidate validate this user based on the context it is used +func (m *User) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateAddress(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTenantusers(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateUserroles(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *User) contextValidateAddress(ctx context.Context, formats strfmt.Registry) error { + + if m.Address != nil { + if err := m.Address.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("address") + } + return err + } + } + + return nil +} + +func (m *User) contextValidateTenantusers(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tenantusers); i++ { + + if m.Tenantusers[i] != nil { + if err := m.Tenantusers[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenantusers" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *User) contextValidateUserroles(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Userroles); i++ { + + if m.Userroles[i] != nil { + if err := m.Userroles[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("userroles" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (m *User) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *User) UnmarshalBinary(b []byte) error { + var res User + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/api/cloud/cloud_models/user_response.go b/api/sfgate/sfgate_models/user_response.go similarity index 88% rename from api/cloud/cloud_models/user_response.go rename to api/sfgate/sfgate_models/user_response.go index ef55498..a5a4862 100644 --- a/api/cloud/cloud_models/user_response.go +++ b/api/sfgate/sfgate_models/user_response.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package cloud_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -18,16 +18,16 @@ import ( "github.com/go-openapi/swag" ) -// UserResponse An array Taxnexus user objects +// UserResponse An array of Print-Ready ingest Objects // // swagger:model UserResponse type UserResponse struct { // data - Data []*User `json:"Data"` + Data []*User `json:"data"` // meta - Meta *ResponseMeta `json:"Meta,omitempty"` + Meta *ResponseMeta `json:"meta,omitempty"` } // Validate validates this user response @@ -61,7 +61,7 @@ func (m *UserResponse) validateData(formats strfmt.Registry) error { if m.Data[i] != nil { if err := m.Data[i].Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -80,7 +80,7 @@ func (m *UserResponse) validateMeta(formats strfmt.Registry) error { if m.Meta != nil { if err := m.Meta.Validate(formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } @@ -114,7 +114,7 @@ func (m *UserResponse) contextValidateData(ctx context.Context, formats strfmt.R if m.Data[i] != nil { if err := m.Data[i].ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) + return ve.ValidateName("data" + "." + strconv.Itoa(i)) } return err } @@ -130,7 +130,7 @@ func (m *UserResponse) contextValidateMeta(ctx context.Context, formats strfmt.R if m.Meta != nil { if err := m.Meta.ContextValidate(ctx, formats); err != nil { if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") + return ve.ValidateName("meta") } return err } diff --git a/api/cloud/cloud_models/user_role.go b/api/sfgate/sfgate_models/user_role.go similarity index 58% rename from api/cloud/cloud_models/user_role.go rename to api/sfgate/sfgate_models/user_role.go index 99e14ad..79540dc 100644 --- a/api/cloud/cloud_models/user_role.go +++ b/api/sfgate/sfgate_models/user_role.go @@ -1,10 +1,10 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed -package cloud_models +package sfgate_models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command @@ -21,44 +21,20 @@ import ( // swagger:model UserRole type UserRole struct { - // Account Id - AccountID string `json:"AccountID,omitempty"` - // Linked role ID - Auth0RoleID string `json:"Auth0RoleID,omitempty"` - - // Auth0 User ID - Auth0UserID string `json:"Auth0UserID,omitempty"` - - // Company Name - CompanyName string `json:"CompanyName,omitempty"` - - // Contact ID - ContactID string `json:"ContactID,omitempty"` + Auth0roleid string `json:"auth0roleid,omitempty"` // Role description - RoleDescription string `json:"RoleDescription,omitempty"` - - // The Role ID - RoleID string `json:"RoleID,omitempty"` + Description string `json:"description,omitempty"` // Role Name - RoleName string `json:"RoleName,omitempty"` + Name string `json:"name,omitempty"` - // Taxnexus Account Number - TelnexusAccount string `json:"TelnexusAccount,omitempty"` - - // User Email Address - UserEmail string `json:"UserEmail,omitempty"` - - // User Full Name - UserFullName string `json:"UserFullName,omitempty"` + // The Role ID + Roleid string `json:"roleid,omitempty"` // The User ID - UserID string `json:"UserID,omitempty"` - - // Username - Username string `json:"Username,omitempty"` + Userid string `json:"userid,omitempty"` } // Validate validates this user role diff --git a/api/stash/stash_client/stash_client.go b/api/stash/stash_client/stash_client.go index 7cd9afd..5751403 100644 --- a/api/stash/stash_client/stash_client.go +++ b/api/stash/stash_client/stash_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -23,7 +23,7 @@ var Default = NewHTTPClient(nil) const ( // DefaultHost is the default Host // found in Meta (info) section of spec file - DefaultHost string = "stash.infra.tnxs.net:8080" + DefaultHost string = "stash.vernonkeenan.com:8080" // DefaultBasePath is the default BasePath // found in Meta (info) section of spec file DefaultBasePath string = "/v1" diff --git a/api/stash/stash_client/stash_pdf/post_pdfs_parameters.go b/api/stash/stash_client/stash_pdf/post_pdfs_parameters.go index bd1a5e5..fd2a7f0 100644 --- a/api/stash/stash_client/stash_pdf/post_pdfs_parameters.go +++ b/api/stash/stash_client/stash_pdf/post_pdfs_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/stash/stash_client/stash_pdf/post_pdfs_responses.go b/api/stash/stash_client/stash_pdf/post_pdfs_responses.go index badd124..fba5d37 100644 --- a/api/stash/stash_client/stash_pdf/post_pdfs_responses.go +++ b/api/stash/stash_client/stash_pdf/post_pdfs_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/stash/stash_client/stash_pdf/stash_pdf_client.go b/api/stash/stash_client/stash_pdf/stash_pdf_client.go index f9c4602..0f2690a 100644 --- a/api/stash/stash_client/stash_pdf/stash_pdf_client.go +++ b/api/stash/stash_client/stash_pdf/stash_pdf_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/stash/stash_models/document.go b/api/stash/stash_models/document.go index 97ef4a1..3a53c23 100644 --- a/api/stash/stash_models/document.go +++ b/api/stash/stash_models/document.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/stash/stash_models/document_response.go b/api/stash/stash_models/document_response.go index 1208241..ce3e096 100644 --- a/api/stash/stash_models/document_response.go +++ b/api/stash/stash_models/document_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/stash/stash_models/error.go b/api/stash/stash_models/error.go index c9d7366..6fc090b 100644 --- a/api/stash/stash_models/error.go +++ b/api/stash/stash_models/error.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/stash/stash_models/new_p_d_f.go b/api/stash/stash_models/new_p_d_f.go index 1a63a01..ece5e94 100644 --- a/api/stash/stash_models/new_p_d_f.go +++ b/api/stash/stash_models/new_p_d_f.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/stash/stash_models/p_d_f_request.go b/api/stash/stash_models/p_d_f_request.go index a9e9037..92d8106 100644 --- a/api/stash/stash_models/p_d_f_request.go +++ b/api/stash/stash_models/p_d_f_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/stash/stash_models/request_meta.go b/api/stash/stash_models/request_meta.go index b74f07e..b8724a4 100644 --- a/api/stash/stash_models/request_meta.go +++ b/api/stash/stash_models/request_meta.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -23,16 +23,16 @@ import ( // swagger:model RequestMeta type RequestMeta struct { - // Telnexus Account Number of the Reseller or OEM + // Taxnexus Account Number of the Reseller or OEM // Required: true - TelnexusAccount *string `json:"TelnexusAccount"` + TaxnexusAccount *string `json:"TaxnexusAccount"` } // Validate validates this request meta func (m *RequestMeta) Validate(formats strfmt.Registry) error { var res []error - if err := m.validateTelnexusAccount(formats); err != nil { + if err := m.validateTaxnexusAccount(formats); err != nil { res = append(res, err) } @@ -42,9 +42,9 @@ func (m *RequestMeta) Validate(formats strfmt.Registry) error { return nil } -func (m *RequestMeta) validateTelnexusAccount(formats strfmt.Registry) error { +func (m *RequestMeta) validateTaxnexusAccount(formats strfmt.Registry) error { - if err := validate.Required("TelnexusAccount", "body", m.TelnexusAccount); err != nil { + if err := validate.Required("TaxnexusAccount", "body", m.TaxnexusAccount); err != nil { return err } diff --git a/api/stash/stash_models/response_meta.go b/api/stash/stash_models/response_meta.go index 84f0b37..ce89868 100644 --- a/api/stash/stash_models/response_meta.go +++ b/api/stash/stash_models/response_meta.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -51,8 +51,8 @@ type ResponseMeta struct { // Backend Server Timestamp ServerTimestamp string `json:"ServerTimestamp,omitempty"` - // Telnexus Account Number used for recording transactions - TelnexusAccount string `json:"TelnexusAccount,omitempty"` + // Taxnexus Account Number used for recording transactions + TaxnexusAccount string `json:"TaxnexusAccount,omitempty"` } // Validate validates this response meta diff --git a/api/voip/voip_client/authority/authority_client.go b/api/voip/voip_client/authority/authority_client.go deleted file mode 100644 index 697d1f5..0000000 --- a/api/voip/voip_client/authority/authority_client.go +++ /dev/null @@ -1,172 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package authority - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" -) - -// New creates a new authority API client. -func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { - return &Client{transport: transport, formats: formats} -} - -/* -Client for authority API -*/ -type Client struct { - transport runtime.ClientTransport - formats strfmt.Registry -} - -// ClientOption is the option for Client methods -type ClientOption func(*runtime.ClientOperation) - -// ClientService is the interface for Client methods -type ClientService interface { - GetAuthorities(params *GetAuthoritiesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAuthoritiesOK, error) - - PostAuthorities(params *PostAuthoritiesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostAuthoritiesOK, error) - - PutAuthorities(params *PutAuthoritiesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutAuthoritiesOK, error) - - SetTransport(transport runtime.ClientTransport) -} - -/* - GetAuthorities gets a list of authorities - - Return a list of available Authorities -*/ -func (a *Client) GetAuthorities(params *GetAuthoritiesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetAuthoritiesOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewGetAuthoritiesParams() - } - op := &runtime.ClientOperation{ - ID: "getAuthorities", - Method: "GET", - PathPattern: "/authorities", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"http"}, - Params: params, - Reader: &GetAuthoritiesReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*GetAuthoritiesOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getAuthorities: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -/* - PostAuthorities adds new authorities - - Create new Authorities -*/ -func (a *Client) PostAuthorities(params *PostAuthoritiesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostAuthoritiesOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewPostAuthoritiesParams() - } - op := &runtime.ClientOperation{ - ID: "postAuthorities", - Method: "POST", - PathPattern: "/authorities", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"http"}, - Params: params, - Reader: &PostAuthoritiesReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*PostAuthoritiesOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for postAuthorities: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -/* - PutAuthorities updates authorities - - Update fields in an Authority record identified by Telnexus Id -*/ -func (a *Client) PutAuthorities(params *PutAuthoritiesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutAuthoritiesOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewPutAuthoritiesParams() - } - op := &runtime.ClientOperation{ - ID: "putAuthorities", - Method: "PUT", - PathPattern: "/authorities", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"http"}, - Params: params, - Reader: &PutAuthoritiesReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*PutAuthoritiesOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for putAuthorities: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -// SetTransport changes the transport on the client -func (a *Client) SetTransport(transport runtime.ClientTransport) { - a.transport = transport -} diff --git a/api/voip/voip_client/authority/get_authorities_parameters.go b/api/voip/voip_client/authority/get_authorities_parameters.go deleted file mode 100644 index 983a99a..0000000 --- a/api/voip/voip_client/authority/get_authorities_parameters.go +++ /dev/null @@ -1,253 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package authority - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// NewGetAuthoritiesParams creates a new GetAuthoritiesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetAuthoritiesParams() *GetAuthoritiesParams { - return &GetAuthoritiesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetAuthoritiesParamsWithTimeout creates a new GetAuthoritiesParams object -// with the ability to set a timeout on a request. -func NewGetAuthoritiesParamsWithTimeout(timeout time.Duration) *GetAuthoritiesParams { - return &GetAuthoritiesParams{ - timeout: timeout, - } -} - -// NewGetAuthoritiesParamsWithContext creates a new GetAuthoritiesParams object -// with the ability to set a context for a request. -func NewGetAuthoritiesParamsWithContext(ctx context.Context) *GetAuthoritiesParams { - return &GetAuthoritiesParams{ - Context: ctx, - } -} - -// NewGetAuthoritiesParamsWithHTTPClient creates a new GetAuthoritiesParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetAuthoritiesParamsWithHTTPClient(client *http.Client) *GetAuthoritiesParams { - return &GetAuthoritiesParams{ - HTTPClient: client, - } -} - -/* GetAuthoritiesParams contains all the parameters to send to the API endpoint - for the get authorities operation. - - Typically these are written to a http.Request. -*/ -type GetAuthoritiesParams struct { - - /* AuthorityID. - - Telnexus Id of the Authority to be retrieved - */ - AuthorityID *string - - /* Limit. - - How many objects to return at one time (max 300, default 100) - - Format: int64 - Default: 100 - */ - Limit *int64 - - /* Offset. - - How many objects to skip? (default 0) - - Format: int64 - */ - Offset *int64 - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get authorities params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAuthoritiesParams) WithDefaults() *GetAuthoritiesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get authorities params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetAuthoritiesParams) SetDefaults() { - var ( - limitDefault = int64(100) - - offsetDefault = int64(0) - ) - - val := GetAuthoritiesParams{ - Limit: &limitDefault, - Offset: &offsetDefault, - } - - val.timeout = o.timeout - val.Context = o.Context - val.HTTPClient = o.HTTPClient - *o = val -} - -// WithTimeout adds the timeout to the get authorities params -func (o *GetAuthoritiesParams) WithTimeout(timeout time.Duration) *GetAuthoritiesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get authorities params -func (o *GetAuthoritiesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get authorities params -func (o *GetAuthoritiesParams) WithContext(ctx context.Context) *GetAuthoritiesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get authorities params -func (o *GetAuthoritiesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get authorities params -func (o *GetAuthoritiesParams) WithHTTPClient(client *http.Client) *GetAuthoritiesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get authorities params -func (o *GetAuthoritiesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAuthorityID adds the authorityID to the get authorities params -func (o *GetAuthoritiesParams) WithAuthorityID(authorityID *string) *GetAuthoritiesParams { - o.SetAuthorityID(authorityID) - return o -} - -// SetAuthorityID adds the authorityId to the get authorities params -func (o *GetAuthoritiesParams) SetAuthorityID(authorityID *string) { - o.AuthorityID = authorityID -} - -// WithLimit adds the limit to the get authorities params -func (o *GetAuthoritiesParams) WithLimit(limit *int64) *GetAuthoritiesParams { - o.SetLimit(limit) - return o -} - -// SetLimit adds the limit to the get authorities params -func (o *GetAuthoritiesParams) SetLimit(limit *int64) { - o.Limit = limit -} - -// WithOffset adds the offset to the get authorities params -func (o *GetAuthoritiesParams) WithOffset(offset *int64) *GetAuthoritiesParams { - o.SetOffset(offset) - return o -} - -// SetOffset adds the offset to the get authorities params -func (o *GetAuthoritiesParams) SetOffset(offset *int64) { - o.Offset = offset -} - -// WriteToRequest writes these params to a swagger request -func (o *GetAuthoritiesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - if o.AuthorityID != nil { - - // query param authorityId - var qrAuthorityID string - - if o.AuthorityID != nil { - qrAuthorityID = *o.AuthorityID - } - qAuthorityID := qrAuthorityID - if qAuthorityID != "" { - - if err := r.SetQueryParam("authorityId", qAuthorityID); err != nil { - return err - } - } - } - - if o.Limit != nil { - - // query param limit - var qrLimit int64 - - if o.Limit != nil { - qrLimit = *o.Limit - } - qLimit := swag.FormatInt64(qrLimit) - if qLimit != "" { - - if err := r.SetQueryParam("limit", qLimit); err != nil { - return err - } - } - } - - if o.Offset != nil { - - // query param offset - var qrOffset int64 - - if o.Offset != nil { - qrOffset = *o.Offset - } - qOffset := swag.FormatInt64(qrOffset) - if qOffset != "" { - - if err := r.SetQueryParam("offset", qOffset); err != nil { - return err - } - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/authority/get_authorities_responses.go b/api/voip/voip_client/authority/get_authorities_responses.go deleted file mode 100644 index dd7af98..0000000 --- a/api/voip/voip_client/authority/get_authorities_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package authority - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// GetAuthoritiesReader is a Reader for the GetAuthorities structure. -type GetAuthoritiesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetAuthoritiesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetAuthoritiesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetAuthoritiesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewGetAuthoritiesForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetAuthoritiesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewGetAuthoritiesUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewGetAuthoritiesInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetAuthoritiesOK creates a GetAuthoritiesOK with default headers values -func NewGetAuthoritiesOK() *GetAuthoritiesOK { - return &GetAuthoritiesOK{} -} - -/* GetAuthoritiesOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of Authority objects -*/ -type GetAuthoritiesOK struct { - Payload *voip_models.AuthorityResponse -} - -func (o *GetAuthoritiesOK) Error() string { - return fmt.Sprintf("[GET /authorities][%d] getAuthoritiesOK %+v", 200, o.Payload) -} -func (o *GetAuthoritiesOK) GetPayload() *voip_models.AuthorityResponse { - return o.Payload -} - -func (o *GetAuthoritiesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.AuthorityResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAuthoritiesUnauthorized creates a GetAuthoritiesUnauthorized with default headers values -func NewGetAuthoritiesUnauthorized() *GetAuthoritiesUnauthorized { - return &GetAuthoritiesUnauthorized{} -} - -/* GetAuthoritiesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetAuthoritiesUnauthorized struct { - Payload *voip_models.Error -} - -func (o *GetAuthoritiesUnauthorized) Error() string { - return fmt.Sprintf("[GET /authorities][%d] getAuthoritiesUnauthorized %+v", 401, o.Payload) -} -func (o *GetAuthoritiesUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetAuthoritiesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAuthoritiesForbidden creates a GetAuthoritiesForbidden with default headers values -func NewGetAuthoritiesForbidden() *GetAuthoritiesForbidden { - return &GetAuthoritiesForbidden{} -} - -/* GetAuthoritiesForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type GetAuthoritiesForbidden struct { - Payload *voip_models.Error -} - -func (o *GetAuthoritiesForbidden) Error() string { - return fmt.Sprintf("[GET /authorities][%d] getAuthoritiesForbidden %+v", 403, o.Payload) -} -func (o *GetAuthoritiesForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetAuthoritiesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAuthoritiesNotFound creates a GetAuthoritiesNotFound with default headers values -func NewGetAuthoritiesNotFound() *GetAuthoritiesNotFound { - return &GetAuthoritiesNotFound{} -} - -/* GetAuthoritiesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetAuthoritiesNotFound struct { - Payload *voip_models.Error -} - -func (o *GetAuthoritiesNotFound) Error() string { - return fmt.Sprintf("[GET /authorities][%d] getAuthoritiesNotFound %+v", 404, o.Payload) -} -func (o *GetAuthoritiesNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetAuthoritiesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAuthoritiesUnprocessableEntity creates a GetAuthoritiesUnprocessableEntity with default headers values -func NewGetAuthoritiesUnprocessableEntity() *GetAuthoritiesUnprocessableEntity { - return &GetAuthoritiesUnprocessableEntity{} -} - -/* GetAuthoritiesUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type GetAuthoritiesUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *GetAuthoritiesUnprocessableEntity) Error() string { - return fmt.Sprintf("[GET /authorities][%d] getAuthoritiesUnprocessableEntity %+v", 422, o.Payload) -} -func (o *GetAuthoritiesUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetAuthoritiesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetAuthoritiesInternalServerError creates a GetAuthoritiesInternalServerError with default headers values -func NewGetAuthoritiesInternalServerError() *GetAuthoritiesInternalServerError { - return &GetAuthoritiesInternalServerError{} -} - -/* GetAuthoritiesInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type GetAuthoritiesInternalServerError struct { - Payload *voip_models.Error -} - -func (o *GetAuthoritiesInternalServerError) Error() string { - return fmt.Sprintf("[GET /authorities][%d] getAuthoritiesInternalServerError %+v", 500, o.Payload) -} -func (o *GetAuthoritiesInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetAuthoritiesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/authority/post_authorities_parameters.go b/api/voip/voip_client/authority/post_authorities_parameters.go deleted file mode 100644 index 5b92190..0000000 --- a/api/voip/voip_client/authority/post_authorities_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package authority - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// NewPostAuthoritiesParams creates a new PostAuthoritiesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPostAuthoritiesParams() *PostAuthoritiesParams { - return &PostAuthoritiesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPostAuthoritiesParamsWithTimeout creates a new PostAuthoritiesParams object -// with the ability to set a timeout on a request. -func NewPostAuthoritiesParamsWithTimeout(timeout time.Duration) *PostAuthoritiesParams { - return &PostAuthoritiesParams{ - timeout: timeout, - } -} - -// NewPostAuthoritiesParamsWithContext creates a new PostAuthoritiesParams object -// with the ability to set a context for a request. -func NewPostAuthoritiesParamsWithContext(ctx context.Context) *PostAuthoritiesParams { - return &PostAuthoritiesParams{ - Context: ctx, - } -} - -// NewPostAuthoritiesParamsWithHTTPClient creates a new PostAuthoritiesParams object -// with the ability to set a custom HTTPClient for a request. -func NewPostAuthoritiesParamsWithHTTPClient(client *http.Client) *PostAuthoritiesParams { - return &PostAuthoritiesParams{ - HTTPClient: client, - } -} - -/* PostAuthoritiesParams contains all the parameters to send to the API endpoint - for the post authorities operation. - - Typically these are written to a http.Request. -*/ -type PostAuthoritiesParams struct { - - /* AuthorityRequest. - - A request with an array of Authority Objects - */ - AuthorityRequest *voip_models.AuthorityRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the post authorities params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostAuthoritiesParams) WithDefaults() *PostAuthoritiesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the post authorities params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostAuthoritiesParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the post authorities params -func (o *PostAuthoritiesParams) WithTimeout(timeout time.Duration) *PostAuthoritiesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the post authorities params -func (o *PostAuthoritiesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the post authorities params -func (o *PostAuthoritiesParams) WithContext(ctx context.Context) *PostAuthoritiesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the post authorities params -func (o *PostAuthoritiesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the post authorities params -func (o *PostAuthoritiesParams) WithHTTPClient(client *http.Client) *PostAuthoritiesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the post authorities params -func (o *PostAuthoritiesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAuthorityRequest adds the authorityRequest to the post authorities params -func (o *PostAuthoritiesParams) WithAuthorityRequest(authorityRequest *voip_models.AuthorityRequest) *PostAuthoritiesParams { - o.SetAuthorityRequest(authorityRequest) - return o -} - -// SetAuthorityRequest adds the authorityRequest to the post authorities params -func (o *PostAuthoritiesParams) SetAuthorityRequest(authorityRequest *voip_models.AuthorityRequest) { - o.AuthorityRequest = authorityRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PostAuthoritiesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.AuthorityRequest != nil { - if err := r.SetBodyParam(o.AuthorityRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/authority/post_authorities_responses.go b/api/voip/voip_client/authority/post_authorities_responses.go deleted file mode 100644 index 5e8363f..0000000 --- a/api/voip/voip_client/authority/post_authorities_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package authority - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// PostAuthoritiesReader is a Reader for the PostAuthorities structure. -type PostAuthoritiesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PostAuthoritiesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPostAuthoritiesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPostAuthoritiesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPostAuthoritiesForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPostAuthoritiesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPostAuthoritiesUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPostAuthoritiesInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPostAuthoritiesOK creates a PostAuthoritiesOK with default headers values -func NewPostAuthoritiesOK() *PostAuthoritiesOK { - return &PostAuthoritiesOK{} -} - -/* PostAuthoritiesOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of Authority objects -*/ -type PostAuthoritiesOK struct { - Payload *voip_models.AuthorityResponse -} - -func (o *PostAuthoritiesOK) Error() string { - return fmt.Sprintf("[POST /authorities][%d] postAuthoritiesOK %+v", 200, o.Payload) -} -func (o *PostAuthoritiesOK) GetPayload() *voip_models.AuthorityResponse { - return o.Payload -} - -func (o *PostAuthoritiesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.AuthorityResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostAuthoritiesUnauthorized creates a PostAuthoritiesUnauthorized with default headers values -func NewPostAuthoritiesUnauthorized() *PostAuthoritiesUnauthorized { - return &PostAuthoritiesUnauthorized{} -} - -/* PostAuthoritiesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PostAuthoritiesUnauthorized struct { - Payload *voip_models.Error -} - -func (o *PostAuthoritiesUnauthorized) Error() string { - return fmt.Sprintf("[POST /authorities][%d] postAuthoritiesUnauthorized %+v", 401, o.Payload) -} -func (o *PostAuthoritiesUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostAuthoritiesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostAuthoritiesForbidden creates a PostAuthoritiesForbidden with default headers values -func NewPostAuthoritiesForbidden() *PostAuthoritiesForbidden { - return &PostAuthoritiesForbidden{} -} - -/* PostAuthoritiesForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PostAuthoritiesForbidden struct { - Payload *voip_models.Error -} - -func (o *PostAuthoritiesForbidden) Error() string { - return fmt.Sprintf("[POST /authorities][%d] postAuthoritiesForbidden %+v", 403, o.Payload) -} -func (o *PostAuthoritiesForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostAuthoritiesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostAuthoritiesNotFound creates a PostAuthoritiesNotFound with default headers values -func NewPostAuthoritiesNotFound() *PostAuthoritiesNotFound { - return &PostAuthoritiesNotFound{} -} - -/* PostAuthoritiesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PostAuthoritiesNotFound struct { - Payload *voip_models.Error -} - -func (o *PostAuthoritiesNotFound) Error() string { - return fmt.Sprintf("[POST /authorities][%d] postAuthoritiesNotFound %+v", 404, o.Payload) -} -func (o *PostAuthoritiesNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostAuthoritiesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostAuthoritiesUnprocessableEntity creates a PostAuthoritiesUnprocessableEntity with default headers values -func NewPostAuthoritiesUnprocessableEntity() *PostAuthoritiesUnprocessableEntity { - return &PostAuthoritiesUnprocessableEntity{} -} - -/* PostAuthoritiesUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PostAuthoritiesUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *PostAuthoritiesUnprocessableEntity) Error() string { - return fmt.Sprintf("[POST /authorities][%d] postAuthoritiesUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PostAuthoritiesUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostAuthoritiesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostAuthoritiesInternalServerError creates a PostAuthoritiesInternalServerError with default headers values -func NewPostAuthoritiesInternalServerError() *PostAuthoritiesInternalServerError { - return &PostAuthoritiesInternalServerError{} -} - -/* PostAuthoritiesInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PostAuthoritiesInternalServerError struct { - Payload *voip_models.Error -} - -func (o *PostAuthoritiesInternalServerError) Error() string { - return fmt.Sprintf("[POST /authorities][%d] postAuthoritiesInternalServerError %+v", 500, o.Payload) -} -func (o *PostAuthoritiesInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostAuthoritiesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/authority/put_authorities_parameters.go b/api/voip/voip_client/authority/put_authorities_parameters.go deleted file mode 100644 index 54a8ced..0000000 --- a/api/voip/voip_client/authority/put_authorities_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package authority - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// NewPutAuthoritiesParams creates a new PutAuthoritiesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPutAuthoritiesParams() *PutAuthoritiesParams { - return &PutAuthoritiesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPutAuthoritiesParamsWithTimeout creates a new PutAuthoritiesParams object -// with the ability to set a timeout on a request. -func NewPutAuthoritiesParamsWithTimeout(timeout time.Duration) *PutAuthoritiesParams { - return &PutAuthoritiesParams{ - timeout: timeout, - } -} - -// NewPutAuthoritiesParamsWithContext creates a new PutAuthoritiesParams object -// with the ability to set a context for a request. -func NewPutAuthoritiesParamsWithContext(ctx context.Context) *PutAuthoritiesParams { - return &PutAuthoritiesParams{ - Context: ctx, - } -} - -// NewPutAuthoritiesParamsWithHTTPClient creates a new PutAuthoritiesParams object -// with the ability to set a custom HTTPClient for a request. -func NewPutAuthoritiesParamsWithHTTPClient(client *http.Client) *PutAuthoritiesParams { - return &PutAuthoritiesParams{ - HTTPClient: client, - } -} - -/* PutAuthoritiesParams contains all the parameters to send to the API endpoint - for the put authorities operation. - - Typically these are written to a http.Request. -*/ -type PutAuthoritiesParams struct { - - /* AuthorityRequest. - - A request with an array of Authority Objects - */ - AuthorityRequest *voip_models.AuthorityRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the put authorities params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PutAuthoritiesParams) WithDefaults() *PutAuthoritiesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the put authorities params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PutAuthoritiesParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the put authorities params -func (o *PutAuthoritiesParams) WithTimeout(timeout time.Duration) *PutAuthoritiesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the put authorities params -func (o *PutAuthoritiesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the put authorities params -func (o *PutAuthoritiesParams) WithContext(ctx context.Context) *PutAuthoritiesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the put authorities params -func (o *PutAuthoritiesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the put authorities params -func (o *PutAuthoritiesParams) WithHTTPClient(client *http.Client) *PutAuthoritiesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the put authorities params -func (o *PutAuthoritiesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithAuthorityRequest adds the authorityRequest to the put authorities params -func (o *PutAuthoritiesParams) WithAuthorityRequest(authorityRequest *voip_models.AuthorityRequest) *PutAuthoritiesParams { - o.SetAuthorityRequest(authorityRequest) - return o -} - -// SetAuthorityRequest adds the authorityRequest to the put authorities params -func (o *PutAuthoritiesParams) SetAuthorityRequest(authorityRequest *voip_models.AuthorityRequest) { - o.AuthorityRequest = authorityRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PutAuthoritiesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.AuthorityRequest != nil { - if err := r.SetBodyParam(o.AuthorityRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/authority/put_authorities_responses.go b/api/voip/voip_client/authority/put_authorities_responses.go deleted file mode 100644 index 58f0f31..0000000 --- a/api/voip/voip_client/authority/put_authorities_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package authority - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// PutAuthoritiesReader is a Reader for the PutAuthorities structure. -type PutAuthoritiesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PutAuthoritiesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPutAuthoritiesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPutAuthoritiesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPutAuthoritiesForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPutAuthoritiesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPutAuthoritiesUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPutAuthoritiesInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPutAuthoritiesOK creates a PutAuthoritiesOK with default headers values -func NewPutAuthoritiesOK() *PutAuthoritiesOK { - return &PutAuthoritiesOK{} -} - -/* PutAuthoritiesOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of Authority objects -*/ -type PutAuthoritiesOK struct { - Payload *voip_models.AuthorityResponse -} - -func (o *PutAuthoritiesOK) Error() string { - return fmt.Sprintf("[PUT /authorities][%d] putAuthoritiesOK %+v", 200, o.Payload) -} -func (o *PutAuthoritiesOK) GetPayload() *voip_models.AuthorityResponse { - return o.Payload -} - -func (o *PutAuthoritiesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.AuthorityResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutAuthoritiesUnauthorized creates a PutAuthoritiesUnauthorized with default headers values -func NewPutAuthoritiesUnauthorized() *PutAuthoritiesUnauthorized { - return &PutAuthoritiesUnauthorized{} -} - -/* PutAuthoritiesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PutAuthoritiesUnauthorized struct { - Payload *voip_models.Error -} - -func (o *PutAuthoritiesUnauthorized) Error() string { - return fmt.Sprintf("[PUT /authorities][%d] putAuthoritiesUnauthorized %+v", 401, o.Payload) -} -func (o *PutAuthoritiesUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutAuthoritiesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutAuthoritiesForbidden creates a PutAuthoritiesForbidden with default headers values -func NewPutAuthoritiesForbidden() *PutAuthoritiesForbidden { - return &PutAuthoritiesForbidden{} -} - -/* PutAuthoritiesForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PutAuthoritiesForbidden struct { - Payload *voip_models.Error -} - -func (o *PutAuthoritiesForbidden) Error() string { - return fmt.Sprintf("[PUT /authorities][%d] putAuthoritiesForbidden %+v", 403, o.Payload) -} -func (o *PutAuthoritiesForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutAuthoritiesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutAuthoritiesNotFound creates a PutAuthoritiesNotFound with default headers values -func NewPutAuthoritiesNotFound() *PutAuthoritiesNotFound { - return &PutAuthoritiesNotFound{} -} - -/* PutAuthoritiesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PutAuthoritiesNotFound struct { - Payload *voip_models.Error -} - -func (o *PutAuthoritiesNotFound) Error() string { - return fmt.Sprintf("[PUT /authorities][%d] putAuthoritiesNotFound %+v", 404, o.Payload) -} -func (o *PutAuthoritiesNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutAuthoritiesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutAuthoritiesUnprocessableEntity creates a PutAuthoritiesUnprocessableEntity with default headers values -func NewPutAuthoritiesUnprocessableEntity() *PutAuthoritiesUnprocessableEntity { - return &PutAuthoritiesUnprocessableEntity{} -} - -/* PutAuthoritiesUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PutAuthoritiesUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *PutAuthoritiesUnprocessableEntity) Error() string { - return fmt.Sprintf("[PUT /authorities][%d] putAuthoritiesUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PutAuthoritiesUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutAuthoritiesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutAuthoritiesInternalServerError creates a PutAuthoritiesInternalServerError with default headers values -func NewPutAuthoritiesInternalServerError() *PutAuthoritiesInternalServerError { - return &PutAuthoritiesInternalServerError{} -} - -/* PutAuthoritiesInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PutAuthoritiesInternalServerError struct { - Payload *voip_models.Error -} - -func (o *PutAuthoritiesInternalServerError) Error() string { - return fmt.Sprintf("[PUT /authorities][%d] putAuthoritiesInternalServerError %+v", 500, o.Payload) -} -func (o *PutAuthoritiesInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutAuthoritiesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/endpoint/get_endpoints_parameters.go b/api/voip/voip_client/endpoint/get_endpoints_parameters.go deleted file mode 100644 index 734a9b7..0000000 --- a/api/voip/voip_client/endpoint/get_endpoints_parameters.go +++ /dev/null @@ -1,253 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package endpoint - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// NewGetEndpointsParams creates a new GetEndpointsParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetEndpointsParams() *GetEndpointsParams { - return &GetEndpointsParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetEndpointsParamsWithTimeout creates a new GetEndpointsParams object -// with the ability to set a timeout on a request. -func NewGetEndpointsParamsWithTimeout(timeout time.Duration) *GetEndpointsParams { - return &GetEndpointsParams{ - timeout: timeout, - } -} - -// NewGetEndpointsParamsWithContext creates a new GetEndpointsParams object -// with the ability to set a context for a request. -func NewGetEndpointsParamsWithContext(ctx context.Context) *GetEndpointsParams { - return &GetEndpointsParams{ - Context: ctx, - } -} - -// NewGetEndpointsParamsWithHTTPClient creates a new GetEndpointsParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetEndpointsParamsWithHTTPClient(client *http.Client) *GetEndpointsParams { - return &GetEndpointsParams{ - HTTPClient: client, - } -} - -/* GetEndpointsParams contains all the parameters to send to the API endpoint - for the get endpoints operation. - - Typically these are written to a http.Request. -*/ -type GetEndpointsParams struct { - - /* EndpointID. - - Telnexus Id of the endpoint to be retrieved - */ - EndpointID *string - - /* Limit. - - How many objects to return at one time (max 300, default 100) - - Format: int64 - Default: 100 - */ - Limit *int64 - - /* Offset. - - How many objects to skip? (default 0) - - Format: int64 - */ - Offset *int64 - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get endpoints params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetEndpointsParams) WithDefaults() *GetEndpointsParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get endpoints params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetEndpointsParams) SetDefaults() { - var ( - limitDefault = int64(100) - - offsetDefault = int64(0) - ) - - val := GetEndpointsParams{ - Limit: &limitDefault, - Offset: &offsetDefault, - } - - val.timeout = o.timeout - val.Context = o.Context - val.HTTPClient = o.HTTPClient - *o = val -} - -// WithTimeout adds the timeout to the get endpoints params -func (o *GetEndpointsParams) WithTimeout(timeout time.Duration) *GetEndpointsParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get endpoints params -func (o *GetEndpointsParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get endpoints params -func (o *GetEndpointsParams) WithContext(ctx context.Context) *GetEndpointsParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get endpoints params -func (o *GetEndpointsParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get endpoints params -func (o *GetEndpointsParams) WithHTTPClient(client *http.Client) *GetEndpointsParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get endpoints params -func (o *GetEndpointsParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithEndpointID adds the endpointID to the get endpoints params -func (o *GetEndpointsParams) WithEndpointID(endpointID *string) *GetEndpointsParams { - o.SetEndpointID(endpointID) - return o -} - -// SetEndpointID adds the endpointId to the get endpoints params -func (o *GetEndpointsParams) SetEndpointID(endpointID *string) { - o.EndpointID = endpointID -} - -// WithLimit adds the limit to the get endpoints params -func (o *GetEndpointsParams) WithLimit(limit *int64) *GetEndpointsParams { - o.SetLimit(limit) - return o -} - -// SetLimit adds the limit to the get endpoints params -func (o *GetEndpointsParams) SetLimit(limit *int64) { - o.Limit = limit -} - -// WithOffset adds the offset to the get endpoints params -func (o *GetEndpointsParams) WithOffset(offset *int64) *GetEndpointsParams { - o.SetOffset(offset) - return o -} - -// SetOffset adds the offset to the get endpoints params -func (o *GetEndpointsParams) SetOffset(offset *int64) { - o.Offset = offset -} - -// WriteToRequest writes these params to a swagger request -func (o *GetEndpointsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - if o.EndpointID != nil { - - // query param endpointId - var qrEndpointID string - - if o.EndpointID != nil { - qrEndpointID = *o.EndpointID - } - qEndpointID := qrEndpointID - if qEndpointID != "" { - - if err := r.SetQueryParam("endpointId", qEndpointID); err != nil { - return err - } - } - } - - if o.Limit != nil { - - // query param limit - var qrLimit int64 - - if o.Limit != nil { - qrLimit = *o.Limit - } - qLimit := swag.FormatInt64(qrLimit) - if qLimit != "" { - - if err := r.SetQueryParam("limit", qLimit); err != nil { - return err - } - } - } - - if o.Offset != nil { - - // query param offset - var qrOffset int64 - - if o.Offset != nil { - qrOffset = *o.Offset - } - qOffset := swag.FormatInt64(qrOffset) - if qOffset != "" { - - if err := r.SetQueryParam("offset", qOffset); err != nil { - return err - } - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/endpoint/get_endpoints_responses.go b/api/voip/voip_client/endpoint/get_endpoints_responses.go deleted file mode 100644 index b2755bc..0000000 --- a/api/voip/voip_client/endpoint/get_endpoints_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package endpoint - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// GetEndpointsReader is a Reader for the GetEndpoints structure. -type GetEndpointsReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetEndpointsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetEndpointsOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetEndpointsUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewGetEndpointsForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetEndpointsNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewGetEndpointsUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewGetEndpointsInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetEndpointsOK creates a GetEndpointsOK with default headers values -func NewGetEndpointsOK() *GetEndpointsOK { - return &GetEndpointsOK{} -} - -/* GetEndpointsOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of PBX objects -*/ -type GetEndpointsOK struct { - Payload *voip_models.EndpointResponse -} - -func (o *GetEndpointsOK) Error() string { - return fmt.Sprintf("[GET /endpoints][%d] getEndpointsOK %+v", 200, o.Payload) -} -func (o *GetEndpointsOK) GetPayload() *voip_models.EndpointResponse { - return o.Payload -} - -func (o *GetEndpointsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.EndpointResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetEndpointsUnauthorized creates a GetEndpointsUnauthorized with default headers values -func NewGetEndpointsUnauthorized() *GetEndpointsUnauthorized { - return &GetEndpointsUnauthorized{} -} - -/* GetEndpointsUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetEndpointsUnauthorized struct { - Payload *voip_models.Error -} - -func (o *GetEndpointsUnauthorized) Error() string { - return fmt.Sprintf("[GET /endpoints][%d] getEndpointsUnauthorized %+v", 401, o.Payload) -} -func (o *GetEndpointsUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetEndpointsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetEndpointsForbidden creates a GetEndpointsForbidden with default headers values -func NewGetEndpointsForbidden() *GetEndpointsForbidden { - return &GetEndpointsForbidden{} -} - -/* GetEndpointsForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type GetEndpointsForbidden struct { - Payload *voip_models.Error -} - -func (o *GetEndpointsForbidden) Error() string { - return fmt.Sprintf("[GET /endpoints][%d] getEndpointsForbidden %+v", 403, o.Payload) -} -func (o *GetEndpointsForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetEndpointsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetEndpointsNotFound creates a GetEndpointsNotFound with default headers values -func NewGetEndpointsNotFound() *GetEndpointsNotFound { - return &GetEndpointsNotFound{} -} - -/* GetEndpointsNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetEndpointsNotFound struct { - Payload *voip_models.Error -} - -func (o *GetEndpointsNotFound) Error() string { - return fmt.Sprintf("[GET /endpoints][%d] getEndpointsNotFound %+v", 404, o.Payload) -} -func (o *GetEndpointsNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetEndpointsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetEndpointsUnprocessableEntity creates a GetEndpointsUnprocessableEntity with default headers values -func NewGetEndpointsUnprocessableEntity() *GetEndpointsUnprocessableEntity { - return &GetEndpointsUnprocessableEntity{} -} - -/* GetEndpointsUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type GetEndpointsUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *GetEndpointsUnprocessableEntity) Error() string { - return fmt.Sprintf("[GET /endpoints][%d] getEndpointsUnprocessableEntity %+v", 422, o.Payload) -} -func (o *GetEndpointsUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetEndpointsUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetEndpointsInternalServerError creates a GetEndpointsInternalServerError with default headers values -func NewGetEndpointsInternalServerError() *GetEndpointsInternalServerError { - return &GetEndpointsInternalServerError{} -} - -/* GetEndpointsInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type GetEndpointsInternalServerError struct { - Payload *voip_models.Error -} - -func (o *GetEndpointsInternalServerError) Error() string { - return fmt.Sprintf("[GET /endpoints][%d] getEndpointsInternalServerError %+v", 500, o.Payload) -} -func (o *GetEndpointsInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetEndpointsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/endpoint/post_endpoints_parameters.go b/api/voip/voip_client/endpoint/post_endpoints_parameters.go deleted file mode 100644 index ecb31a4..0000000 --- a/api/voip/voip_client/endpoint/post_endpoints_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package endpoint - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// NewPostEndpointsParams creates a new PostEndpointsParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPostEndpointsParams() *PostEndpointsParams { - return &PostEndpointsParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPostEndpointsParamsWithTimeout creates a new PostEndpointsParams object -// with the ability to set a timeout on a request. -func NewPostEndpointsParamsWithTimeout(timeout time.Duration) *PostEndpointsParams { - return &PostEndpointsParams{ - timeout: timeout, - } -} - -// NewPostEndpointsParamsWithContext creates a new PostEndpointsParams object -// with the ability to set a context for a request. -func NewPostEndpointsParamsWithContext(ctx context.Context) *PostEndpointsParams { - return &PostEndpointsParams{ - Context: ctx, - } -} - -// NewPostEndpointsParamsWithHTTPClient creates a new PostEndpointsParams object -// with the ability to set a custom HTTPClient for a request. -func NewPostEndpointsParamsWithHTTPClient(client *http.Client) *PostEndpointsParams { - return &PostEndpointsParams{ - HTTPClient: client, - } -} - -/* PostEndpointsParams contains all the parameters to send to the API endpoint - for the post endpoints operation. - - Typically these are written to a http.Request. -*/ -type PostEndpointsParams struct { - - /* EndpointRequest. - - An array of new PBX records - */ - EndpointRequest *voip_models.EndpointRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the post endpoints params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostEndpointsParams) WithDefaults() *PostEndpointsParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the post endpoints params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostEndpointsParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the post endpoints params -func (o *PostEndpointsParams) WithTimeout(timeout time.Duration) *PostEndpointsParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the post endpoints params -func (o *PostEndpointsParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the post endpoints params -func (o *PostEndpointsParams) WithContext(ctx context.Context) *PostEndpointsParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the post endpoints params -func (o *PostEndpointsParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the post endpoints params -func (o *PostEndpointsParams) WithHTTPClient(client *http.Client) *PostEndpointsParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the post endpoints params -func (o *PostEndpointsParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithEndpointRequest adds the endpointRequest to the post endpoints params -func (o *PostEndpointsParams) WithEndpointRequest(endpointRequest *voip_models.EndpointRequest) *PostEndpointsParams { - o.SetEndpointRequest(endpointRequest) - return o -} - -// SetEndpointRequest adds the endpointRequest to the post endpoints params -func (o *PostEndpointsParams) SetEndpointRequest(endpointRequest *voip_models.EndpointRequest) { - o.EndpointRequest = endpointRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PostEndpointsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.EndpointRequest != nil { - if err := r.SetBodyParam(o.EndpointRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/endpoint/post_endpoints_responses.go b/api/voip/voip_client/endpoint/post_endpoints_responses.go deleted file mode 100644 index d266c0d..0000000 --- a/api/voip/voip_client/endpoint/post_endpoints_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package endpoint - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// PostEndpointsReader is a Reader for the PostEndpoints structure. -type PostEndpointsReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PostEndpointsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPostEndpointsOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPostEndpointsUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPostEndpointsForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPostEndpointsNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPostEndpointsUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPostEndpointsInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPostEndpointsOK creates a PostEndpointsOK with default headers values -func NewPostEndpointsOK() *PostEndpointsOK { - return &PostEndpointsOK{} -} - -/* PostEndpointsOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of PBX objects -*/ -type PostEndpointsOK struct { - Payload *voip_models.EndpointResponse -} - -func (o *PostEndpointsOK) Error() string { - return fmt.Sprintf("[POST /endpoints][%d] postEndpointsOK %+v", 200, o.Payload) -} -func (o *PostEndpointsOK) GetPayload() *voip_models.EndpointResponse { - return o.Payload -} - -func (o *PostEndpointsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.EndpointResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostEndpointsUnauthorized creates a PostEndpointsUnauthorized with default headers values -func NewPostEndpointsUnauthorized() *PostEndpointsUnauthorized { - return &PostEndpointsUnauthorized{} -} - -/* PostEndpointsUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PostEndpointsUnauthorized struct { - Payload *voip_models.Error -} - -func (o *PostEndpointsUnauthorized) Error() string { - return fmt.Sprintf("[POST /endpoints][%d] postEndpointsUnauthorized %+v", 401, o.Payload) -} -func (o *PostEndpointsUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostEndpointsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostEndpointsForbidden creates a PostEndpointsForbidden with default headers values -func NewPostEndpointsForbidden() *PostEndpointsForbidden { - return &PostEndpointsForbidden{} -} - -/* PostEndpointsForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PostEndpointsForbidden struct { - Payload *voip_models.Error -} - -func (o *PostEndpointsForbidden) Error() string { - return fmt.Sprintf("[POST /endpoints][%d] postEndpointsForbidden %+v", 403, o.Payload) -} -func (o *PostEndpointsForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostEndpointsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostEndpointsNotFound creates a PostEndpointsNotFound with default headers values -func NewPostEndpointsNotFound() *PostEndpointsNotFound { - return &PostEndpointsNotFound{} -} - -/* PostEndpointsNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PostEndpointsNotFound struct { - Payload *voip_models.Error -} - -func (o *PostEndpointsNotFound) Error() string { - return fmt.Sprintf("[POST /endpoints][%d] postEndpointsNotFound %+v", 404, o.Payload) -} -func (o *PostEndpointsNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostEndpointsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostEndpointsUnprocessableEntity creates a PostEndpointsUnprocessableEntity with default headers values -func NewPostEndpointsUnprocessableEntity() *PostEndpointsUnprocessableEntity { - return &PostEndpointsUnprocessableEntity{} -} - -/* PostEndpointsUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PostEndpointsUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *PostEndpointsUnprocessableEntity) Error() string { - return fmt.Sprintf("[POST /endpoints][%d] postEndpointsUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PostEndpointsUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostEndpointsUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostEndpointsInternalServerError creates a PostEndpointsInternalServerError with default headers values -func NewPostEndpointsInternalServerError() *PostEndpointsInternalServerError { - return &PostEndpointsInternalServerError{} -} - -/* PostEndpointsInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PostEndpointsInternalServerError struct { - Payload *voip_models.Error -} - -func (o *PostEndpointsInternalServerError) Error() string { - return fmt.Sprintf("[POST /endpoints][%d] postEndpointsInternalServerError %+v", 500, o.Payload) -} -func (o *PostEndpointsInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostEndpointsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/endpoint/put_endpoints_parameters.go b/api/voip/voip_client/endpoint/put_endpoints_parameters.go deleted file mode 100644 index 2f3ae50..0000000 --- a/api/voip/voip_client/endpoint/put_endpoints_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package endpoint - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// NewPutEndpointsParams creates a new PutEndpointsParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPutEndpointsParams() *PutEndpointsParams { - return &PutEndpointsParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPutEndpointsParamsWithTimeout creates a new PutEndpointsParams object -// with the ability to set a timeout on a request. -func NewPutEndpointsParamsWithTimeout(timeout time.Duration) *PutEndpointsParams { - return &PutEndpointsParams{ - timeout: timeout, - } -} - -// NewPutEndpointsParamsWithContext creates a new PutEndpointsParams object -// with the ability to set a context for a request. -func NewPutEndpointsParamsWithContext(ctx context.Context) *PutEndpointsParams { - return &PutEndpointsParams{ - Context: ctx, - } -} - -// NewPutEndpointsParamsWithHTTPClient creates a new PutEndpointsParams object -// with the ability to set a custom HTTPClient for a request. -func NewPutEndpointsParamsWithHTTPClient(client *http.Client) *PutEndpointsParams { - return &PutEndpointsParams{ - HTTPClient: client, - } -} - -/* PutEndpointsParams contains all the parameters to send to the API endpoint - for the put endpoints operation. - - Typically these are written to a http.Request. -*/ -type PutEndpointsParams struct { - - /* EndpointRequest. - - An array of new PBX records - */ - EndpointRequest *voip_models.EndpointRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the put endpoints params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PutEndpointsParams) WithDefaults() *PutEndpointsParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the put endpoints params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PutEndpointsParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the put endpoints params -func (o *PutEndpointsParams) WithTimeout(timeout time.Duration) *PutEndpointsParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the put endpoints params -func (o *PutEndpointsParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the put endpoints params -func (o *PutEndpointsParams) WithContext(ctx context.Context) *PutEndpointsParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the put endpoints params -func (o *PutEndpointsParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the put endpoints params -func (o *PutEndpointsParams) WithHTTPClient(client *http.Client) *PutEndpointsParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the put endpoints params -func (o *PutEndpointsParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithEndpointRequest adds the endpointRequest to the put endpoints params -func (o *PutEndpointsParams) WithEndpointRequest(endpointRequest *voip_models.EndpointRequest) *PutEndpointsParams { - o.SetEndpointRequest(endpointRequest) - return o -} - -// SetEndpointRequest adds the endpointRequest to the put endpoints params -func (o *PutEndpointsParams) SetEndpointRequest(endpointRequest *voip_models.EndpointRequest) { - o.EndpointRequest = endpointRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PutEndpointsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.EndpointRequest != nil { - if err := r.SetBodyParam(o.EndpointRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/endpoint/put_endpoints_responses.go b/api/voip/voip_client/endpoint/put_endpoints_responses.go deleted file mode 100644 index ccf3ec6..0000000 --- a/api/voip/voip_client/endpoint/put_endpoints_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package endpoint - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// PutEndpointsReader is a Reader for the PutEndpoints structure. -type PutEndpointsReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PutEndpointsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPutEndpointsOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPutEndpointsUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPutEndpointsForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPutEndpointsNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPutEndpointsUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPutEndpointsInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPutEndpointsOK creates a PutEndpointsOK with default headers values -func NewPutEndpointsOK() *PutEndpointsOK { - return &PutEndpointsOK{} -} - -/* PutEndpointsOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of PBX objects -*/ -type PutEndpointsOK struct { - Payload *voip_models.EndpointResponse -} - -func (o *PutEndpointsOK) Error() string { - return fmt.Sprintf("[PUT /endpoints][%d] putEndpointsOK %+v", 200, o.Payload) -} -func (o *PutEndpointsOK) GetPayload() *voip_models.EndpointResponse { - return o.Payload -} - -func (o *PutEndpointsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.EndpointResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutEndpointsUnauthorized creates a PutEndpointsUnauthorized with default headers values -func NewPutEndpointsUnauthorized() *PutEndpointsUnauthorized { - return &PutEndpointsUnauthorized{} -} - -/* PutEndpointsUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PutEndpointsUnauthorized struct { - Payload *voip_models.Error -} - -func (o *PutEndpointsUnauthorized) Error() string { - return fmt.Sprintf("[PUT /endpoints][%d] putEndpointsUnauthorized %+v", 401, o.Payload) -} -func (o *PutEndpointsUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutEndpointsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutEndpointsForbidden creates a PutEndpointsForbidden with default headers values -func NewPutEndpointsForbidden() *PutEndpointsForbidden { - return &PutEndpointsForbidden{} -} - -/* PutEndpointsForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PutEndpointsForbidden struct { - Payload *voip_models.Error -} - -func (o *PutEndpointsForbidden) Error() string { - return fmt.Sprintf("[PUT /endpoints][%d] putEndpointsForbidden %+v", 403, o.Payload) -} -func (o *PutEndpointsForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutEndpointsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutEndpointsNotFound creates a PutEndpointsNotFound with default headers values -func NewPutEndpointsNotFound() *PutEndpointsNotFound { - return &PutEndpointsNotFound{} -} - -/* PutEndpointsNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PutEndpointsNotFound struct { - Payload *voip_models.Error -} - -func (o *PutEndpointsNotFound) Error() string { - return fmt.Sprintf("[PUT /endpoints][%d] putEndpointsNotFound %+v", 404, o.Payload) -} -func (o *PutEndpointsNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutEndpointsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutEndpointsUnprocessableEntity creates a PutEndpointsUnprocessableEntity with default headers values -func NewPutEndpointsUnprocessableEntity() *PutEndpointsUnprocessableEntity { - return &PutEndpointsUnprocessableEntity{} -} - -/* PutEndpointsUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PutEndpointsUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *PutEndpointsUnprocessableEntity) Error() string { - return fmt.Sprintf("[PUT /endpoints][%d] putEndpointsUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PutEndpointsUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutEndpointsUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutEndpointsInternalServerError creates a PutEndpointsInternalServerError with default headers values -func NewPutEndpointsInternalServerError() *PutEndpointsInternalServerError { - return &PutEndpointsInternalServerError{} -} - -/* PutEndpointsInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PutEndpointsInternalServerError struct { - Payload *voip_models.Error -} - -func (o *PutEndpointsInternalServerError) Error() string { - return fmt.Sprintf("[PUT /endpoints][%d] putEndpointsInternalServerError %+v", 500, o.Payload) -} -func (o *PutEndpointsInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutEndpointsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/pbx/get_p_b_xes_parameters.go b/api/voip/voip_client/pbx/get_p_b_xes_parameters.go deleted file mode 100644 index 6acbcbf..0000000 --- a/api/voip/voip_client/pbx/get_p_b_xes_parameters.go +++ /dev/null @@ -1,253 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package pbx - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// NewGetPBXesParams creates a new GetPBXesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetPBXesParams() *GetPBXesParams { - return &GetPBXesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetPBXesParamsWithTimeout creates a new GetPBXesParams object -// with the ability to set a timeout on a request. -func NewGetPBXesParamsWithTimeout(timeout time.Duration) *GetPBXesParams { - return &GetPBXesParams{ - timeout: timeout, - } -} - -// NewGetPBXesParamsWithContext creates a new GetPBXesParams object -// with the ability to set a context for a request. -func NewGetPBXesParamsWithContext(ctx context.Context) *GetPBXesParams { - return &GetPBXesParams{ - Context: ctx, - } -} - -// NewGetPBXesParamsWithHTTPClient creates a new GetPBXesParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetPBXesParamsWithHTTPClient(client *http.Client) *GetPBXesParams { - return &GetPBXesParams{ - HTTPClient: client, - } -} - -/* GetPBXesParams contains all the parameters to send to the API endpoint - for the get p b xes operation. - - Typically these are written to a http.Request. -*/ -type GetPBXesParams struct { - - /* Limit. - - How many objects to return at one time (max 300, default 100) - - Format: int64 - Default: 100 - */ - Limit *int64 - - /* Offset. - - How many objects to skip? (default 0) - - Format: int64 - */ - Offset *int64 - - /* PbxID. - - Telnexus Id of the PBX to be retrieved - */ - PbxID *string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get p b xes params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetPBXesParams) WithDefaults() *GetPBXesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get p b xes params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetPBXesParams) SetDefaults() { - var ( - limitDefault = int64(100) - - offsetDefault = int64(0) - ) - - val := GetPBXesParams{ - Limit: &limitDefault, - Offset: &offsetDefault, - } - - val.timeout = o.timeout - val.Context = o.Context - val.HTTPClient = o.HTTPClient - *o = val -} - -// WithTimeout adds the timeout to the get p b xes params -func (o *GetPBXesParams) WithTimeout(timeout time.Duration) *GetPBXesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get p b xes params -func (o *GetPBXesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get p b xes params -func (o *GetPBXesParams) WithContext(ctx context.Context) *GetPBXesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get p b xes params -func (o *GetPBXesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get p b xes params -func (o *GetPBXesParams) WithHTTPClient(client *http.Client) *GetPBXesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get p b xes params -func (o *GetPBXesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithLimit adds the limit to the get p b xes params -func (o *GetPBXesParams) WithLimit(limit *int64) *GetPBXesParams { - o.SetLimit(limit) - return o -} - -// SetLimit adds the limit to the get p b xes params -func (o *GetPBXesParams) SetLimit(limit *int64) { - o.Limit = limit -} - -// WithOffset adds the offset to the get p b xes params -func (o *GetPBXesParams) WithOffset(offset *int64) *GetPBXesParams { - o.SetOffset(offset) - return o -} - -// SetOffset adds the offset to the get p b xes params -func (o *GetPBXesParams) SetOffset(offset *int64) { - o.Offset = offset -} - -// WithPbxID adds the pbxID to the get p b xes params -func (o *GetPBXesParams) WithPbxID(pbxID *string) *GetPBXesParams { - o.SetPbxID(pbxID) - return o -} - -// SetPbxID adds the pbxId to the get p b xes params -func (o *GetPBXesParams) SetPbxID(pbxID *string) { - o.PbxID = pbxID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetPBXesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - if o.Limit != nil { - - // query param limit - var qrLimit int64 - - if o.Limit != nil { - qrLimit = *o.Limit - } - qLimit := swag.FormatInt64(qrLimit) - if qLimit != "" { - - if err := r.SetQueryParam("limit", qLimit); err != nil { - return err - } - } - } - - if o.Offset != nil { - - // query param offset - var qrOffset int64 - - if o.Offset != nil { - qrOffset = *o.Offset - } - qOffset := swag.FormatInt64(qrOffset) - if qOffset != "" { - - if err := r.SetQueryParam("offset", qOffset); err != nil { - return err - } - } - } - - if o.PbxID != nil { - - // query param pbxId - var qrPbxID string - - if o.PbxID != nil { - qrPbxID = *o.PbxID - } - qPbxID := qrPbxID - if qPbxID != "" { - - if err := r.SetQueryParam("pbxId", qPbxID); err != nil { - return err - } - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/pbx/get_p_b_xes_responses.go b/api/voip/voip_client/pbx/get_p_b_xes_responses.go deleted file mode 100644 index 60b2554..0000000 --- a/api/voip/voip_client/pbx/get_p_b_xes_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package pbx - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// GetPBXesReader is a Reader for the GetPBXes structure. -type GetPBXesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetPBXesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetPBXesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetPBXesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewGetPBXesForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetPBXesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewGetPBXesUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewGetPBXesInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetPBXesOK creates a GetPBXesOK with default headers values -func NewGetPBXesOK() *GetPBXesOK { - return &GetPBXesOK{} -} - -/* GetPBXesOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of PBX objects -*/ -type GetPBXesOK struct { - Payload *voip_models.PbxResponse -} - -func (o *GetPBXesOK) Error() string { - return fmt.Sprintf("[GET /pbxes][%d] getPBXesOK %+v", 200, o.Payload) -} -func (o *GetPBXesOK) GetPayload() *voip_models.PbxResponse { - return o.Payload -} - -func (o *GetPBXesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.PbxResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetPBXesUnauthorized creates a GetPBXesUnauthorized with default headers values -func NewGetPBXesUnauthorized() *GetPBXesUnauthorized { - return &GetPBXesUnauthorized{} -} - -/* GetPBXesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetPBXesUnauthorized struct { - Payload *voip_models.Error -} - -func (o *GetPBXesUnauthorized) Error() string { - return fmt.Sprintf("[GET /pbxes][%d] getPBXesUnauthorized %+v", 401, o.Payload) -} -func (o *GetPBXesUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetPBXesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetPBXesForbidden creates a GetPBXesForbidden with default headers values -func NewGetPBXesForbidden() *GetPBXesForbidden { - return &GetPBXesForbidden{} -} - -/* GetPBXesForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type GetPBXesForbidden struct { - Payload *voip_models.Error -} - -func (o *GetPBXesForbidden) Error() string { - return fmt.Sprintf("[GET /pbxes][%d] getPBXesForbidden %+v", 403, o.Payload) -} -func (o *GetPBXesForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetPBXesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetPBXesNotFound creates a GetPBXesNotFound with default headers values -func NewGetPBXesNotFound() *GetPBXesNotFound { - return &GetPBXesNotFound{} -} - -/* GetPBXesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetPBXesNotFound struct { - Payload *voip_models.Error -} - -func (o *GetPBXesNotFound) Error() string { - return fmt.Sprintf("[GET /pbxes][%d] getPBXesNotFound %+v", 404, o.Payload) -} -func (o *GetPBXesNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetPBXesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetPBXesUnprocessableEntity creates a GetPBXesUnprocessableEntity with default headers values -func NewGetPBXesUnprocessableEntity() *GetPBXesUnprocessableEntity { - return &GetPBXesUnprocessableEntity{} -} - -/* GetPBXesUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type GetPBXesUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *GetPBXesUnprocessableEntity) Error() string { - return fmt.Sprintf("[GET /pbxes][%d] getPBXesUnprocessableEntity %+v", 422, o.Payload) -} -func (o *GetPBXesUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetPBXesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetPBXesInternalServerError creates a GetPBXesInternalServerError with default headers values -func NewGetPBXesInternalServerError() *GetPBXesInternalServerError { - return &GetPBXesInternalServerError{} -} - -/* GetPBXesInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type GetPBXesInternalServerError struct { - Payload *voip_models.Error -} - -func (o *GetPBXesInternalServerError) Error() string { - return fmt.Sprintf("[GET /pbxes][%d] getPBXesInternalServerError %+v", 500, o.Payload) -} -func (o *GetPBXesInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetPBXesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/pbx/pbx_client.go b/api/voip/voip_client/pbx/pbx_client.go deleted file mode 100644 index d994727..0000000 --- a/api/voip/voip_client/pbx/pbx_client.go +++ /dev/null @@ -1,172 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package pbx - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" -) - -// New creates a new pbx API client. -func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { - return &Client{transport: transport, formats: formats} -} - -/* -Client for pbx API -*/ -type Client struct { - transport runtime.ClientTransport - formats strfmt.Registry -} - -// ClientOption is the option for Client methods -type ClientOption func(*runtime.ClientOperation) - -// ClientService is the interface for Client methods -type ClientService interface { - GetPBXes(params *GetPBXesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetPBXesOK, error) - - PostPBXes(params *PostPBXesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostPBXesOK, error) - - PutPBXes(params *PutPBXesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutPBXesOK, error) - - SetTransport(transport runtime.ClientTransport) -} - -/* - GetPBXes gets a list of p b xes - - Return a list of available PBX entities -*/ -func (a *Client) GetPBXes(params *GetPBXesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetPBXesOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewGetPBXesParams() - } - op := &runtime.ClientOperation{ - ID: "getPBXes", - Method: "GET", - PathPattern: "/pbxes", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"http"}, - Params: params, - Reader: &GetPBXesReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*GetPBXesOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getPBXes: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -/* - PostPBXes adds new p b xes - - Create new PBXes -*/ -func (a *Client) PostPBXes(params *PostPBXesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostPBXesOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewPostPBXesParams() - } - op := &runtime.ClientOperation{ - ID: "postPBXes", - Method: "POST", - PathPattern: "/pbxes", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"http"}, - Params: params, - Reader: &PostPBXesReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*PostPBXesOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for postPBXes: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -/* - PutPBXes updates p b xes - - Update fields in an PBX record identified by Telnexus Id -*/ -func (a *Client) PutPBXes(params *PutPBXesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutPBXesOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewPutPBXesParams() - } - op := &runtime.ClientOperation{ - ID: "putPBXes", - Method: "PUT", - PathPattern: "/pbxes", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"http"}, - Params: params, - Reader: &PutPBXesReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*PutPBXesOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for putPBXes: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -// SetTransport changes the transport on the client -func (a *Client) SetTransport(transport runtime.ClientTransport) { - a.transport = transport -} diff --git a/api/voip/voip_client/pbx/post_p_b_xes_parameters.go b/api/voip/voip_client/pbx/post_p_b_xes_parameters.go deleted file mode 100644 index 8995f17..0000000 --- a/api/voip/voip_client/pbx/post_p_b_xes_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package pbx - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// NewPostPBXesParams creates a new PostPBXesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPostPBXesParams() *PostPBXesParams { - return &PostPBXesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPostPBXesParamsWithTimeout creates a new PostPBXesParams object -// with the ability to set a timeout on a request. -func NewPostPBXesParamsWithTimeout(timeout time.Duration) *PostPBXesParams { - return &PostPBXesParams{ - timeout: timeout, - } -} - -// NewPostPBXesParamsWithContext creates a new PostPBXesParams object -// with the ability to set a context for a request. -func NewPostPBXesParamsWithContext(ctx context.Context) *PostPBXesParams { - return &PostPBXesParams{ - Context: ctx, - } -} - -// NewPostPBXesParamsWithHTTPClient creates a new PostPBXesParams object -// with the ability to set a custom HTTPClient for a request. -func NewPostPBXesParamsWithHTTPClient(client *http.Client) *PostPBXesParams { - return &PostPBXesParams{ - HTTPClient: client, - } -} - -/* PostPBXesParams contains all the parameters to send to the API endpoint - for the post p b xes operation. - - Typically these are written to a http.Request. -*/ -type PostPBXesParams struct { - - /* PbxRequest. - - An array of new PBX records - */ - PbxRequest *voip_models.PbxRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the post p b xes params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostPBXesParams) WithDefaults() *PostPBXesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the post p b xes params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostPBXesParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the post p b xes params -func (o *PostPBXesParams) WithTimeout(timeout time.Duration) *PostPBXesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the post p b xes params -func (o *PostPBXesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the post p b xes params -func (o *PostPBXesParams) WithContext(ctx context.Context) *PostPBXesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the post p b xes params -func (o *PostPBXesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the post p b xes params -func (o *PostPBXesParams) WithHTTPClient(client *http.Client) *PostPBXesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the post p b xes params -func (o *PostPBXesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithPbxRequest adds the pbxRequest to the post p b xes params -func (o *PostPBXesParams) WithPbxRequest(pbxRequest *voip_models.PbxRequest) *PostPBXesParams { - o.SetPbxRequest(pbxRequest) - return o -} - -// SetPbxRequest adds the pbxRequest to the post p b xes params -func (o *PostPBXesParams) SetPbxRequest(pbxRequest *voip_models.PbxRequest) { - o.PbxRequest = pbxRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PostPBXesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.PbxRequest != nil { - if err := r.SetBodyParam(o.PbxRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/pbx/post_p_b_xes_responses.go b/api/voip/voip_client/pbx/post_p_b_xes_responses.go deleted file mode 100644 index 85a4d43..0000000 --- a/api/voip/voip_client/pbx/post_p_b_xes_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package pbx - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// PostPBXesReader is a Reader for the PostPBXes structure. -type PostPBXesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PostPBXesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPostPBXesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPostPBXesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPostPBXesForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPostPBXesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPostPBXesUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPostPBXesInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPostPBXesOK creates a PostPBXesOK with default headers values -func NewPostPBXesOK() *PostPBXesOK { - return &PostPBXesOK{} -} - -/* PostPBXesOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of PBX objects -*/ -type PostPBXesOK struct { - Payload *voip_models.PbxResponse -} - -func (o *PostPBXesOK) Error() string { - return fmt.Sprintf("[POST /pbxes][%d] postPBXesOK %+v", 200, o.Payload) -} -func (o *PostPBXesOK) GetPayload() *voip_models.PbxResponse { - return o.Payload -} - -func (o *PostPBXesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.PbxResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostPBXesUnauthorized creates a PostPBXesUnauthorized with default headers values -func NewPostPBXesUnauthorized() *PostPBXesUnauthorized { - return &PostPBXesUnauthorized{} -} - -/* PostPBXesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PostPBXesUnauthorized struct { - Payload *voip_models.Error -} - -func (o *PostPBXesUnauthorized) Error() string { - return fmt.Sprintf("[POST /pbxes][%d] postPBXesUnauthorized %+v", 401, o.Payload) -} -func (o *PostPBXesUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostPBXesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostPBXesForbidden creates a PostPBXesForbidden with default headers values -func NewPostPBXesForbidden() *PostPBXesForbidden { - return &PostPBXesForbidden{} -} - -/* PostPBXesForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PostPBXesForbidden struct { - Payload *voip_models.Error -} - -func (o *PostPBXesForbidden) Error() string { - return fmt.Sprintf("[POST /pbxes][%d] postPBXesForbidden %+v", 403, o.Payload) -} -func (o *PostPBXesForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostPBXesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostPBXesNotFound creates a PostPBXesNotFound with default headers values -func NewPostPBXesNotFound() *PostPBXesNotFound { - return &PostPBXesNotFound{} -} - -/* PostPBXesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PostPBXesNotFound struct { - Payload *voip_models.Error -} - -func (o *PostPBXesNotFound) Error() string { - return fmt.Sprintf("[POST /pbxes][%d] postPBXesNotFound %+v", 404, o.Payload) -} -func (o *PostPBXesNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostPBXesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostPBXesUnprocessableEntity creates a PostPBXesUnprocessableEntity with default headers values -func NewPostPBXesUnprocessableEntity() *PostPBXesUnprocessableEntity { - return &PostPBXesUnprocessableEntity{} -} - -/* PostPBXesUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PostPBXesUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *PostPBXesUnprocessableEntity) Error() string { - return fmt.Sprintf("[POST /pbxes][%d] postPBXesUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PostPBXesUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostPBXesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostPBXesInternalServerError creates a PostPBXesInternalServerError with default headers values -func NewPostPBXesInternalServerError() *PostPBXesInternalServerError { - return &PostPBXesInternalServerError{} -} - -/* PostPBXesInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PostPBXesInternalServerError struct { - Payload *voip_models.Error -} - -func (o *PostPBXesInternalServerError) Error() string { - return fmt.Sprintf("[POST /pbxes][%d] postPBXesInternalServerError %+v", 500, o.Payload) -} -func (o *PostPBXesInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostPBXesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/pbx/put_p_b_xes_parameters.go b/api/voip/voip_client/pbx/put_p_b_xes_parameters.go deleted file mode 100644 index a6cfbe6..0000000 --- a/api/voip/voip_client/pbx/put_p_b_xes_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package pbx - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// NewPutPBXesParams creates a new PutPBXesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPutPBXesParams() *PutPBXesParams { - return &PutPBXesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPutPBXesParamsWithTimeout creates a new PutPBXesParams object -// with the ability to set a timeout on a request. -func NewPutPBXesParamsWithTimeout(timeout time.Duration) *PutPBXesParams { - return &PutPBXesParams{ - timeout: timeout, - } -} - -// NewPutPBXesParamsWithContext creates a new PutPBXesParams object -// with the ability to set a context for a request. -func NewPutPBXesParamsWithContext(ctx context.Context) *PutPBXesParams { - return &PutPBXesParams{ - Context: ctx, - } -} - -// NewPutPBXesParamsWithHTTPClient creates a new PutPBXesParams object -// with the ability to set a custom HTTPClient for a request. -func NewPutPBXesParamsWithHTTPClient(client *http.Client) *PutPBXesParams { - return &PutPBXesParams{ - HTTPClient: client, - } -} - -/* PutPBXesParams contains all the parameters to send to the API endpoint - for the put p b xes operation. - - Typically these are written to a http.Request. -*/ -type PutPBXesParams struct { - - /* PbxRequest. - - An array of new PBX records - */ - PbxRequest *voip_models.PbxRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the put p b xes params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PutPBXesParams) WithDefaults() *PutPBXesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the put p b xes params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PutPBXesParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the put p b xes params -func (o *PutPBXesParams) WithTimeout(timeout time.Duration) *PutPBXesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the put p b xes params -func (o *PutPBXesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the put p b xes params -func (o *PutPBXesParams) WithContext(ctx context.Context) *PutPBXesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the put p b xes params -func (o *PutPBXesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the put p b xes params -func (o *PutPBXesParams) WithHTTPClient(client *http.Client) *PutPBXesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the put p b xes params -func (o *PutPBXesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithPbxRequest adds the pbxRequest to the put p b xes params -func (o *PutPBXesParams) WithPbxRequest(pbxRequest *voip_models.PbxRequest) *PutPBXesParams { - o.SetPbxRequest(pbxRequest) - return o -} - -// SetPbxRequest adds the pbxRequest to the put p b xes params -func (o *PutPBXesParams) SetPbxRequest(pbxRequest *voip_models.PbxRequest) { - o.PbxRequest = pbxRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PutPBXesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.PbxRequest != nil { - if err := r.SetBodyParam(o.PbxRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/pbx/put_p_b_xes_responses.go b/api/voip/voip_client/pbx/put_p_b_xes_responses.go deleted file mode 100644 index 8f8964d..0000000 --- a/api/voip/voip_client/pbx/put_p_b_xes_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package pbx - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// PutPBXesReader is a Reader for the PutPBXes structure. -type PutPBXesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PutPBXesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPutPBXesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPutPBXesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPutPBXesForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPutPBXesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPutPBXesUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPutPBXesInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPutPBXesOK creates a PutPBXesOK with default headers values -func NewPutPBXesOK() *PutPBXesOK { - return &PutPBXesOK{} -} - -/* PutPBXesOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of PBX objects -*/ -type PutPBXesOK struct { - Payload *voip_models.PbxResponse -} - -func (o *PutPBXesOK) Error() string { - return fmt.Sprintf("[PUT /pbxes][%d] putPBXesOK %+v", 200, o.Payload) -} -func (o *PutPBXesOK) GetPayload() *voip_models.PbxResponse { - return o.Payload -} - -func (o *PutPBXesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.PbxResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutPBXesUnauthorized creates a PutPBXesUnauthorized with default headers values -func NewPutPBXesUnauthorized() *PutPBXesUnauthorized { - return &PutPBXesUnauthorized{} -} - -/* PutPBXesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PutPBXesUnauthorized struct { - Payload *voip_models.Error -} - -func (o *PutPBXesUnauthorized) Error() string { - return fmt.Sprintf("[PUT /pbxes][%d] putPBXesUnauthorized %+v", 401, o.Payload) -} -func (o *PutPBXesUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutPBXesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutPBXesForbidden creates a PutPBXesForbidden with default headers values -func NewPutPBXesForbidden() *PutPBXesForbidden { - return &PutPBXesForbidden{} -} - -/* PutPBXesForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PutPBXesForbidden struct { - Payload *voip_models.Error -} - -func (o *PutPBXesForbidden) Error() string { - return fmt.Sprintf("[PUT /pbxes][%d] putPBXesForbidden %+v", 403, o.Payload) -} -func (o *PutPBXesForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutPBXesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutPBXesNotFound creates a PutPBXesNotFound with default headers values -func NewPutPBXesNotFound() *PutPBXesNotFound { - return &PutPBXesNotFound{} -} - -/* PutPBXesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PutPBXesNotFound struct { - Payload *voip_models.Error -} - -func (o *PutPBXesNotFound) Error() string { - return fmt.Sprintf("[PUT /pbxes][%d] putPBXesNotFound %+v", 404, o.Payload) -} -func (o *PutPBXesNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutPBXesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutPBXesUnprocessableEntity creates a PutPBXesUnprocessableEntity with default headers values -func NewPutPBXesUnprocessableEntity() *PutPBXesUnprocessableEntity { - return &PutPBXesUnprocessableEntity{} -} - -/* PutPBXesUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PutPBXesUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *PutPBXesUnprocessableEntity) Error() string { - return fmt.Sprintf("[PUT /pbxes][%d] putPBXesUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PutPBXesUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutPBXesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutPBXesInternalServerError creates a PutPBXesInternalServerError with default headers values -func NewPutPBXesInternalServerError() *PutPBXesInternalServerError { - return &PutPBXesInternalServerError{} -} - -/* PutPBXesInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PutPBXesInternalServerError struct { - Payload *voip_models.Error -} - -func (o *PutPBXesInternalServerError) Error() string { - return fmt.Sprintf("[PUT /pbxes][%d] putPBXesInternalServerError %+v", 500, o.Payload) -} -func (o *PutPBXesInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutPBXesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/pbx_user/get_p_b_x_users_parameters.go b/api/voip/voip_client/pbx_user/get_p_b_x_users_parameters.go deleted file mode 100644 index c3fb936..0000000 --- a/api/voip/voip_client/pbx_user/get_p_b_x_users_parameters.go +++ /dev/null @@ -1,253 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package pbx_user - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// NewGetPBXUsersParams creates a new GetPBXUsersParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetPBXUsersParams() *GetPBXUsersParams { - return &GetPBXUsersParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetPBXUsersParamsWithTimeout creates a new GetPBXUsersParams object -// with the ability to set a timeout on a request. -func NewGetPBXUsersParamsWithTimeout(timeout time.Duration) *GetPBXUsersParams { - return &GetPBXUsersParams{ - timeout: timeout, - } -} - -// NewGetPBXUsersParamsWithContext creates a new GetPBXUsersParams object -// with the ability to set a context for a request. -func NewGetPBXUsersParamsWithContext(ctx context.Context) *GetPBXUsersParams { - return &GetPBXUsersParams{ - Context: ctx, - } -} - -// NewGetPBXUsersParamsWithHTTPClient creates a new GetPBXUsersParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetPBXUsersParamsWithHTTPClient(client *http.Client) *GetPBXUsersParams { - return &GetPBXUsersParams{ - HTTPClient: client, - } -} - -/* GetPBXUsersParams contains all the parameters to send to the API endpoint - for the get p b x users operation. - - Typically these are written to a http.Request. -*/ -type GetPBXUsersParams struct { - - /* Limit. - - How many objects to return at one time (max 300, default 100) - - Format: int64 - Default: 100 - */ - Limit *int64 - - /* Offset. - - How many objects to skip? (default 0) - - Format: int64 - */ - Offset *int64 - - /* PbxUserID. - - Telnexus Id of the PBX User to be retrieved - */ - PbxUserID *string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get p b x users params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetPBXUsersParams) WithDefaults() *GetPBXUsersParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get p b x users params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetPBXUsersParams) SetDefaults() { - var ( - limitDefault = int64(100) - - offsetDefault = int64(0) - ) - - val := GetPBXUsersParams{ - Limit: &limitDefault, - Offset: &offsetDefault, - } - - val.timeout = o.timeout - val.Context = o.Context - val.HTTPClient = o.HTTPClient - *o = val -} - -// WithTimeout adds the timeout to the get p b x users params -func (o *GetPBXUsersParams) WithTimeout(timeout time.Duration) *GetPBXUsersParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get p b x users params -func (o *GetPBXUsersParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get p b x users params -func (o *GetPBXUsersParams) WithContext(ctx context.Context) *GetPBXUsersParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get p b x users params -func (o *GetPBXUsersParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get p b x users params -func (o *GetPBXUsersParams) WithHTTPClient(client *http.Client) *GetPBXUsersParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get p b x users params -func (o *GetPBXUsersParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithLimit adds the limit to the get p b x users params -func (o *GetPBXUsersParams) WithLimit(limit *int64) *GetPBXUsersParams { - o.SetLimit(limit) - return o -} - -// SetLimit adds the limit to the get p b x users params -func (o *GetPBXUsersParams) SetLimit(limit *int64) { - o.Limit = limit -} - -// WithOffset adds the offset to the get p b x users params -func (o *GetPBXUsersParams) WithOffset(offset *int64) *GetPBXUsersParams { - o.SetOffset(offset) - return o -} - -// SetOffset adds the offset to the get p b x users params -func (o *GetPBXUsersParams) SetOffset(offset *int64) { - o.Offset = offset -} - -// WithPbxUserID adds the pbxUserID to the get p b x users params -func (o *GetPBXUsersParams) WithPbxUserID(pbxUserID *string) *GetPBXUsersParams { - o.SetPbxUserID(pbxUserID) - return o -} - -// SetPbxUserID adds the pbxUserId to the get p b x users params -func (o *GetPBXUsersParams) SetPbxUserID(pbxUserID *string) { - o.PbxUserID = pbxUserID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetPBXUsersParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - if o.Limit != nil { - - // query param limit - var qrLimit int64 - - if o.Limit != nil { - qrLimit = *o.Limit - } - qLimit := swag.FormatInt64(qrLimit) - if qLimit != "" { - - if err := r.SetQueryParam("limit", qLimit); err != nil { - return err - } - } - } - - if o.Offset != nil { - - // query param offset - var qrOffset int64 - - if o.Offset != nil { - qrOffset = *o.Offset - } - qOffset := swag.FormatInt64(qrOffset) - if qOffset != "" { - - if err := r.SetQueryParam("offset", qOffset); err != nil { - return err - } - } - } - - if o.PbxUserID != nil { - - // query param pbxUserId - var qrPbxUserID string - - if o.PbxUserID != nil { - qrPbxUserID = *o.PbxUserID - } - qPbxUserID := qrPbxUserID - if qPbxUserID != "" { - - if err := r.SetQueryParam("pbxUserId", qPbxUserID); err != nil { - return err - } - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/pbx_user/get_p_b_x_users_responses.go b/api/voip/voip_client/pbx_user/get_p_b_x_users_responses.go deleted file mode 100644 index 5fd9899..0000000 --- a/api/voip/voip_client/pbx_user/get_p_b_x_users_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package pbx_user - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// GetPBXUsersReader is a Reader for the GetPBXUsers structure. -type GetPBXUsersReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetPBXUsersReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetPBXUsersOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetPBXUsersUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewGetPBXUsersForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetPBXUsersNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewGetPBXUsersUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewGetPBXUsersInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetPBXUsersOK creates a GetPBXUsersOK with default headers values -func NewGetPBXUsersOK() *GetPBXUsersOK { - return &GetPBXUsersOK{} -} - -/* GetPBXUsersOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of PBX User objects -*/ -type GetPBXUsersOK struct { - Payload *voip_models.PbxUserResponse -} - -func (o *GetPBXUsersOK) Error() string { - return fmt.Sprintf("[GET /pbxusers][%d] getPBXUsersOK %+v", 200, o.Payload) -} -func (o *GetPBXUsersOK) GetPayload() *voip_models.PbxUserResponse { - return o.Payload -} - -func (o *GetPBXUsersOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.PbxUserResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetPBXUsersUnauthorized creates a GetPBXUsersUnauthorized with default headers values -func NewGetPBXUsersUnauthorized() *GetPBXUsersUnauthorized { - return &GetPBXUsersUnauthorized{} -} - -/* GetPBXUsersUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetPBXUsersUnauthorized struct { - Payload *voip_models.Error -} - -func (o *GetPBXUsersUnauthorized) Error() string { - return fmt.Sprintf("[GET /pbxusers][%d] getPBXUsersUnauthorized %+v", 401, o.Payload) -} -func (o *GetPBXUsersUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetPBXUsersUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetPBXUsersForbidden creates a GetPBXUsersForbidden with default headers values -func NewGetPBXUsersForbidden() *GetPBXUsersForbidden { - return &GetPBXUsersForbidden{} -} - -/* GetPBXUsersForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type GetPBXUsersForbidden struct { - Payload *voip_models.Error -} - -func (o *GetPBXUsersForbidden) Error() string { - return fmt.Sprintf("[GET /pbxusers][%d] getPBXUsersForbidden %+v", 403, o.Payload) -} -func (o *GetPBXUsersForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetPBXUsersForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetPBXUsersNotFound creates a GetPBXUsersNotFound with default headers values -func NewGetPBXUsersNotFound() *GetPBXUsersNotFound { - return &GetPBXUsersNotFound{} -} - -/* GetPBXUsersNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetPBXUsersNotFound struct { - Payload *voip_models.Error -} - -func (o *GetPBXUsersNotFound) Error() string { - return fmt.Sprintf("[GET /pbxusers][%d] getPBXUsersNotFound %+v", 404, o.Payload) -} -func (o *GetPBXUsersNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetPBXUsersNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetPBXUsersUnprocessableEntity creates a GetPBXUsersUnprocessableEntity with default headers values -func NewGetPBXUsersUnprocessableEntity() *GetPBXUsersUnprocessableEntity { - return &GetPBXUsersUnprocessableEntity{} -} - -/* GetPBXUsersUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type GetPBXUsersUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *GetPBXUsersUnprocessableEntity) Error() string { - return fmt.Sprintf("[GET /pbxusers][%d] getPBXUsersUnprocessableEntity %+v", 422, o.Payload) -} -func (o *GetPBXUsersUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetPBXUsersUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetPBXUsersInternalServerError creates a GetPBXUsersInternalServerError with default headers values -func NewGetPBXUsersInternalServerError() *GetPBXUsersInternalServerError { - return &GetPBXUsersInternalServerError{} -} - -/* GetPBXUsersInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type GetPBXUsersInternalServerError struct { - Payload *voip_models.Error -} - -func (o *GetPBXUsersInternalServerError) Error() string { - return fmt.Sprintf("[GET /pbxusers][%d] getPBXUsersInternalServerError %+v", 500, o.Payload) -} -func (o *GetPBXUsersInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetPBXUsersInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/pbx_user/p_b_x_users_parameters.go b/api/voip/voip_client/pbx_user/p_b_x_users_parameters.go deleted file mode 100644 index edaf080..0000000 --- a/api/voip/voip_client/pbx_user/p_b_x_users_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package pbx_user - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// NewPBXUsersParams creates a new PBXUsersParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPBXUsersParams() *PBXUsersParams { - return &PBXUsersParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPBXUsersParamsWithTimeout creates a new PBXUsersParams object -// with the ability to set a timeout on a request. -func NewPBXUsersParamsWithTimeout(timeout time.Duration) *PBXUsersParams { - return &PBXUsersParams{ - timeout: timeout, - } -} - -// NewPBXUsersParamsWithContext creates a new PBXUsersParams object -// with the ability to set a context for a request. -func NewPBXUsersParamsWithContext(ctx context.Context) *PBXUsersParams { - return &PBXUsersParams{ - Context: ctx, - } -} - -// NewPBXUsersParamsWithHTTPClient creates a new PBXUsersParams object -// with the ability to set a custom HTTPClient for a request. -func NewPBXUsersParamsWithHTTPClient(client *http.Client) *PBXUsersParams { - return &PBXUsersParams{ - HTTPClient: client, - } -} - -/* PBXUsersParams contains all the parameters to send to the API endpoint - for the p b x users operation. - - Typically these are written to a http.Request. -*/ -type PBXUsersParams struct { - - /* PbxUserRequest. - - An array of new PBX User records - */ - PbxUserRequest *voip_models.PbxUserRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the p b x users params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PBXUsersParams) WithDefaults() *PBXUsersParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the p b x users params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PBXUsersParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the p b x users params -func (o *PBXUsersParams) WithTimeout(timeout time.Duration) *PBXUsersParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the p b x users params -func (o *PBXUsersParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the p b x users params -func (o *PBXUsersParams) WithContext(ctx context.Context) *PBXUsersParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the p b x users params -func (o *PBXUsersParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the p b x users params -func (o *PBXUsersParams) WithHTTPClient(client *http.Client) *PBXUsersParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the p b x users params -func (o *PBXUsersParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithPbxUserRequest adds the pbxUserRequest to the p b x users params -func (o *PBXUsersParams) WithPbxUserRequest(pbxUserRequest *voip_models.PbxUserRequest) *PBXUsersParams { - o.SetPbxUserRequest(pbxUserRequest) - return o -} - -// SetPbxUserRequest adds the pbxUserRequest to the p b x users params -func (o *PBXUsersParams) SetPbxUserRequest(pbxUserRequest *voip_models.PbxUserRequest) { - o.PbxUserRequest = pbxUserRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PBXUsersParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.PbxUserRequest != nil { - if err := r.SetBodyParam(o.PbxUserRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/pbx_user/p_b_x_users_responses.go b/api/voip/voip_client/pbx_user/p_b_x_users_responses.go deleted file mode 100644 index 75275f1..0000000 --- a/api/voip/voip_client/pbx_user/p_b_x_users_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package pbx_user - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// PBXUsersReader is a Reader for the PBXUsers structure. -type PBXUsersReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PBXUsersReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPBXUsersOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPBXUsersUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPBXUsersForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPBXUsersNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPBXUsersUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPBXUsersInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPBXUsersOK creates a PBXUsersOK with default headers values -func NewPBXUsersOK() *PBXUsersOK { - return &PBXUsersOK{} -} - -/* PBXUsersOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of PBX User objects -*/ -type PBXUsersOK struct { - Payload *voip_models.PbxUserResponse -} - -func (o *PBXUsersOK) Error() string { - return fmt.Sprintf("[PUT /pbxusers][%d] pBXUsersOK %+v", 200, o.Payload) -} -func (o *PBXUsersOK) GetPayload() *voip_models.PbxUserResponse { - return o.Payload -} - -func (o *PBXUsersOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.PbxUserResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPBXUsersUnauthorized creates a PBXUsersUnauthorized with default headers values -func NewPBXUsersUnauthorized() *PBXUsersUnauthorized { - return &PBXUsersUnauthorized{} -} - -/* PBXUsersUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PBXUsersUnauthorized struct { - Payload *voip_models.Error -} - -func (o *PBXUsersUnauthorized) Error() string { - return fmt.Sprintf("[PUT /pbxusers][%d] pBXUsersUnauthorized %+v", 401, o.Payload) -} -func (o *PBXUsersUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PBXUsersUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPBXUsersForbidden creates a PBXUsersForbidden with default headers values -func NewPBXUsersForbidden() *PBXUsersForbidden { - return &PBXUsersForbidden{} -} - -/* PBXUsersForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PBXUsersForbidden struct { - Payload *voip_models.Error -} - -func (o *PBXUsersForbidden) Error() string { - return fmt.Sprintf("[PUT /pbxusers][%d] pBXUsersForbidden %+v", 403, o.Payload) -} -func (o *PBXUsersForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PBXUsersForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPBXUsersNotFound creates a PBXUsersNotFound with default headers values -func NewPBXUsersNotFound() *PBXUsersNotFound { - return &PBXUsersNotFound{} -} - -/* PBXUsersNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PBXUsersNotFound struct { - Payload *voip_models.Error -} - -func (o *PBXUsersNotFound) Error() string { - return fmt.Sprintf("[PUT /pbxusers][%d] pBXUsersNotFound %+v", 404, o.Payload) -} -func (o *PBXUsersNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PBXUsersNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPBXUsersUnprocessableEntity creates a PBXUsersUnprocessableEntity with default headers values -func NewPBXUsersUnprocessableEntity() *PBXUsersUnprocessableEntity { - return &PBXUsersUnprocessableEntity{} -} - -/* PBXUsersUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PBXUsersUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *PBXUsersUnprocessableEntity) Error() string { - return fmt.Sprintf("[PUT /pbxusers][%d] pBXUsersUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PBXUsersUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PBXUsersUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPBXUsersInternalServerError creates a PBXUsersInternalServerError with default headers values -func NewPBXUsersInternalServerError() *PBXUsersInternalServerError { - return &PBXUsersInternalServerError{} -} - -/* PBXUsersInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PBXUsersInternalServerError struct { - Payload *voip_models.Error -} - -func (o *PBXUsersInternalServerError) Error() string { - return fmt.Sprintf("[PUT /pbxusers][%d] pBXUsersInternalServerError %+v", 500, o.Payload) -} -func (o *PBXUsersInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PBXUsersInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/pbx_user/post_p_b_x_users_parameters.go b/api/voip/voip_client/pbx_user/post_p_b_x_users_parameters.go deleted file mode 100644 index 9a5b5bf..0000000 --- a/api/voip/voip_client/pbx_user/post_p_b_x_users_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package pbx_user - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// NewPostPBXUsersParams creates a new PostPBXUsersParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPostPBXUsersParams() *PostPBXUsersParams { - return &PostPBXUsersParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPostPBXUsersParamsWithTimeout creates a new PostPBXUsersParams object -// with the ability to set a timeout on a request. -func NewPostPBXUsersParamsWithTimeout(timeout time.Duration) *PostPBXUsersParams { - return &PostPBXUsersParams{ - timeout: timeout, - } -} - -// NewPostPBXUsersParamsWithContext creates a new PostPBXUsersParams object -// with the ability to set a context for a request. -func NewPostPBXUsersParamsWithContext(ctx context.Context) *PostPBXUsersParams { - return &PostPBXUsersParams{ - Context: ctx, - } -} - -// NewPostPBXUsersParamsWithHTTPClient creates a new PostPBXUsersParams object -// with the ability to set a custom HTTPClient for a request. -func NewPostPBXUsersParamsWithHTTPClient(client *http.Client) *PostPBXUsersParams { - return &PostPBXUsersParams{ - HTTPClient: client, - } -} - -/* PostPBXUsersParams contains all the parameters to send to the API endpoint - for the post p b x users operation. - - Typically these are written to a http.Request. -*/ -type PostPBXUsersParams struct { - - /* PbxUserRequest. - - An array of new PBX User records - */ - PbxUserRequest *voip_models.PbxUserRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the post p b x users params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostPBXUsersParams) WithDefaults() *PostPBXUsersParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the post p b x users params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostPBXUsersParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the post p b x users params -func (o *PostPBXUsersParams) WithTimeout(timeout time.Duration) *PostPBXUsersParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the post p b x users params -func (o *PostPBXUsersParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the post p b x users params -func (o *PostPBXUsersParams) WithContext(ctx context.Context) *PostPBXUsersParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the post p b x users params -func (o *PostPBXUsersParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the post p b x users params -func (o *PostPBXUsersParams) WithHTTPClient(client *http.Client) *PostPBXUsersParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the post p b x users params -func (o *PostPBXUsersParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithPbxUserRequest adds the pbxUserRequest to the post p b x users params -func (o *PostPBXUsersParams) WithPbxUserRequest(pbxUserRequest *voip_models.PbxUserRequest) *PostPBXUsersParams { - o.SetPbxUserRequest(pbxUserRequest) - return o -} - -// SetPbxUserRequest adds the pbxUserRequest to the post p b x users params -func (o *PostPBXUsersParams) SetPbxUserRequest(pbxUserRequest *voip_models.PbxUserRequest) { - o.PbxUserRequest = pbxUserRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PostPBXUsersParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.PbxUserRequest != nil { - if err := r.SetBodyParam(o.PbxUserRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/pbx_user/post_p_b_x_users_responses.go b/api/voip/voip_client/pbx_user/post_p_b_x_users_responses.go deleted file mode 100644 index 7545a1b..0000000 --- a/api/voip/voip_client/pbx_user/post_p_b_x_users_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package pbx_user - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// PostPBXUsersReader is a Reader for the PostPBXUsers structure. -type PostPBXUsersReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PostPBXUsersReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPostPBXUsersOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPostPBXUsersUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPostPBXUsersForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPostPBXUsersNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPostPBXUsersUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPostPBXUsersInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPostPBXUsersOK creates a PostPBXUsersOK with default headers values -func NewPostPBXUsersOK() *PostPBXUsersOK { - return &PostPBXUsersOK{} -} - -/* PostPBXUsersOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of PBX User objects -*/ -type PostPBXUsersOK struct { - Payload *voip_models.PbxUserResponse -} - -func (o *PostPBXUsersOK) Error() string { - return fmt.Sprintf("[POST /pbxusers][%d] postPBXUsersOK %+v", 200, o.Payload) -} -func (o *PostPBXUsersOK) GetPayload() *voip_models.PbxUserResponse { - return o.Payload -} - -func (o *PostPBXUsersOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.PbxUserResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostPBXUsersUnauthorized creates a PostPBXUsersUnauthorized with default headers values -func NewPostPBXUsersUnauthorized() *PostPBXUsersUnauthorized { - return &PostPBXUsersUnauthorized{} -} - -/* PostPBXUsersUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PostPBXUsersUnauthorized struct { - Payload *voip_models.Error -} - -func (o *PostPBXUsersUnauthorized) Error() string { - return fmt.Sprintf("[POST /pbxusers][%d] postPBXUsersUnauthorized %+v", 401, o.Payload) -} -func (o *PostPBXUsersUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostPBXUsersUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostPBXUsersForbidden creates a PostPBXUsersForbidden with default headers values -func NewPostPBXUsersForbidden() *PostPBXUsersForbidden { - return &PostPBXUsersForbidden{} -} - -/* PostPBXUsersForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PostPBXUsersForbidden struct { - Payload *voip_models.Error -} - -func (o *PostPBXUsersForbidden) Error() string { - return fmt.Sprintf("[POST /pbxusers][%d] postPBXUsersForbidden %+v", 403, o.Payload) -} -func (o *PostPBXUsersForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostPBXUsersForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostPBXUsersNotFound creates a PostPBXUsersNotFound with default headers values -func NewPostPBXUsersNotFound() *PostPBXUsersNotFound { - return &PostPBXUsersNotFound{} -} - -/* PostPBXUsersNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PostPBXUsersNotFound struct { - Payload *voip_models.Error -} - -func (o *PostPBXUsersNotFound) Error() string { - return fmt.Sprintf("[POST /pbxusers][%d] postPBXUsersNotFound %+v", 404, o.Payload) -} -func (o *PostPBXUsersNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostPBXUsersNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostPBXUsersUnprocessableEntity creates a PostPBXUsersUnprocessableEntity with default headers values -func NewPostPBXUsersUnprocessableEntity() *PostPBXUsersUnprocessableEntity { - return &PostPBXUsersUnprocessableEntity{} -} - -/* PostPBXUsersUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PostPBXUsersUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *PostPBXUsersUnprocessableEntity) Error() string { - return fmt.Sprintf("[POST /pbxusers][%d] postPBXUsersUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PostPBXUsersUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostPBXUsersUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostPBXUsersInternalServerError creates a PostPBXUsersInternalServerError with default headers values -func NewPostPBXUsersInternalServerError() *PostPBXUsersInternalServerError { - return &PostPBXUsersInternalServerError{} -} - -/* PostPBXUsersInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PostPBXUsersInternalServerError struct { - Payload *voip_models.Error -} - -func (o *PostPBXUsersInternalServerError) Error() string { - return fmt.Sprintf("[POST /pbxusers][%d] postPBXUsersInternalServerError %+v", 500, o.Payload) -} -func (o *PostPBXUsersInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostPBXUsersInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/phone_number/get_phone_numbers_parameters.go b/api/voip/voip_client/phone_number/get_phone_numbers_parameters.go deleted file mode 100644 index 5d65943..0000000 --- a/api/voip/voip_client/phone_number/get_phone_numbers_parameters.go +++ /dev/null @@ -1,253 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package phone_number - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// NewGetPhoneNumbersParams creates a new GetPhoneNumbersParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetPhoneNumbersParams() *GetPhoneNumbersParams { - return &GetPhoneNumbersParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetPhoneNumbersParamsWithTimeout creates a new GetPhoneNumbersParams object -// with the ability to set a timeout on a request. -func NewGetPhoneNumbersParamsWithTimeout(timeout time.Duration) *GetPhoneNumbersParams { - return &GetPhoneNumbersParams{ - timeout: timeout, - } -} - -// NewGetPhoneNumbersParamsWithContext creates a new GetPhoneNumbersParams object -// with the ability to set a context for a request. -func NewGetPhoneNumbersParamsWithContext(ctx context.Context) *GetPhoneNumbersParams { - return &GetPhoneNumbersParams{ - Context: ctx, - } -} - -// NewGetPhoneNumbersParamsWithHTTPClient creates a new GetPhoneNumbersParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetPhoneNumbersParamsWithHTTPClient(client *http.Client) *GetPhoneNumbersParams { - return &GetPhoneNumbersParams{ - HTTPClient: client, - } -} - -/* GetPhoneNumbersParams contains all the parameters to send to the API endpoint - for the get phone numbers operation. - - Typically these are written to a http.Request. -*/ -type GetPhoneNumbersParams struct { - - /* Limit. - - How many objects to return at one time (max 300, default 100) - - Format: int64 - Default: 100 - */ - Limit *int64 - - /* Offset. - - How many objects to skip? (default 0) - - Format: int64 - */ - Offset *int64 - - /* PhoneNumberID. - - Telnexus Id of the Phone Number to be retrieved - */ - PhoneNumberID *string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get phone numbers params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetPhoneNumbersParams) WithDefaults() *GetPhoneNumbersParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get phone numbers params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetPhoneNumbersParams) SetDefaults() { - var ( - limitDefault = int64(100) - - offsetDefault = int64(0) - ) - - val := GetPhoneNumbersParams{ - Limit: &limitDefault, - Offset: &offsetDefault, - } - - val.timeout = o.timeout - val.Context = o.Context - val.HTTPClient = o.HTTPClient - *o = val -} - -// WithTimeout adds the timeout to the get phone numbers params -func (o *GetPhoneNumbersParams) WithTimeout(timeout time.Duration) *GetPhoneNumbersParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get phone numbers params -func (o *GetPhoneNumbersParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get phone numbers params -func (o *GetPhoneNumbersParams) WithContext(ctx context.Context) *GetPhoneNumbersParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get phone numbers params -func (o *GetPhoneNumbersParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get phone numbers params -func (o *GetPhoneNumbersParams) WithHTTPClient(client *http.Client) *GetPhoneNumbersParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get phone numbers params -func (o *GetPhoneNumbersParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithLimit adds the limit to the get phone numbers params -func (o *GetPhoneNumbersParams) WithLimit(limit *int64) *GetPhoneNumbersParams { - o.SetLimit(limit) - return o -} - -// SetLimit adds the limit to the get phone numbers params -func (o *GetPhoneNumbersParams) SetLimit(limit *int64) { - o.Limit = limit -} - -// WithOffset adds the offset to the get phone numbers params -func (o *GetPhoneNumbersParams) WithOffset(offset *int64) *GetPhoneNumbersParams { - o.SetOffset(offset) - return o -} - -// SetOffset adds the offset to the get phone numbers params -func (o *GetPhoneNumbersParams) SetOffset(offset *int64) { - o.Offset = offset -} - -// WithPhoneNumberID adds the phoneNumberID to the get phone numbers params -func (o *GetPhoneNumbersParams) WithPhoneNumberID(phoneNumberID *string) *GetPhoneNumbersParams { - o.SetPhoneNumberID(phoneNumberID) - return o -} - -// SetPhoneNumberID adds the phoneNumberId to the get phone numbers params -func (o *GetPhoneNumbersParams) SetPhoneNumberID(phoneNumberID *string) { - o.PhoneNumberID = phoneNumberID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetPhoneNumbersParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - if o.Limit != nil { - - // query param limit - var qrLimit int64 - - if o.Limit != nil { - qrLimit = *o.Limit - } - qLimit := swag.FormatInt64(qrLimit) - if qLimit != "" { - - if err := r.SetQueryParam("limit", qLimit); err != nil { - return err - } - } - } - - if o.Offset != nil { - - // query param offset - var qrOffset int64 - - if o.Offset != nil { - qrOffset = *o.Offset - } - qOffset := swag.FormatInt64(qrOffset) - if qOffset != "" { - - if err := r.SetQueryParam("offset", qOffset); err != nil { - return err - } - } - } - - if o.PhoneNumberID != nil { - - // query param phoneNumberId - var qrPhoneNumberID string - - if o.PhoneNumberID != nil { - qrPhoneNumberID = *o.PhoneNumberID - } - qPhoneNumberID := qrPhoneNumberID - if qPhoneNumberID != "" { - - if err := r.SetQueryParam("phoneNumberId", qPhoneNumberID); err != nil { - return err - } - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/phone_number/get_phone_numbers_responses.go b/api/voip/voip_client/phone_number/get_phone_numbers_responses.go deleted file mode 100644 index d1866ae..0000000 --- a/api/voip/voip_client/phone_number/get_phone_numbers_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package phone_number - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// GetPhoneNumbersReader is a Reader for the GetPhoneNumbers structure. -type GetPhoneNumbersReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetPhoneNumbersReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetPhoneNumbersOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetPhoneNumbersUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewGetPhoneNumbersForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetPhoneNumbersNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewGetPhoneNumbersUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewGetPhoneNumbersInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetPhoneNumbersOK creates a GetPhoneNumbersOK with default headers values -func NewGetPhoneNumbersOK() *GetPhoneNumbersOK { - return &GetPhoneNumbersOK{} -} - -/* GetPhoneNumbersOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of PBX objects -*/ -type GetPhoneNumbersOK struct { - Payload *voip_models.PhoneNumberResponse -} - -func (o *GetPhoneNumbersOK) Error() string { - return fmt.Sprintf("[GET /phonenumbers][%d] getPhoneNumbersOK %+v", 200, o.Payload) -} -func (o *GetPhoneNumbersOK) GetPayload() *voip_models.PhoneNumberResponse { - return o.Payload -} - -func (o *GetPhoneNumbersOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.PhoneNumberResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetPhoneNumbersUnauthorized creates a GetPhoneNumbersUnauthorized with default headers values -func NewGetPhoneNumbersUnauthorized() *GetPhoneNumbersUnauthorized { - return &GetPhoneNumbersUnauthorized{} -} - -/* GetPhoneNumbersUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetPhoneNumbersUnauthorized struct { - Payload *voip_models.Error -} - -func (o *GetPhoneNumbersUnauthorized) Error() string { - return fmt.Sprintf("[GET /phonenumbers][%d] getPhoneNumbersUnauthorized %+v", 401, o.Payload) -} -func (o *GetPhoneNumbersUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetPhoneNumbersUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetPhoneNumbersForbidden creates a GetPhoneNumbersForbidden with default headers values -func NewGetPhoneNumbersForbidden() *GetPhoneNumbersForbidden { - return &GetPhoneNumbersForbidden{} -} - -/* GetPhoneNumbersForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type GetPhoneNumbersForbidden struct { - Payload *voip_models.Error -} - -func (o *GetPhoneNumbersForbidden) Error() string { - return fmt.Sprintf("[GET /phonenumbers][%d] getPhoneNumbersForbidden %+v", 403, o.Payload) -} -func (o *GetPhoneNumbersForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetPhoneNumbersForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetPhoneNumbersNotFound creates a GetPhoneNumbersNotFound with default headers values -func NewGetPhoneNumbersNotFound() *GetPhoneNumbersNotFound { - return &GetPhoneNumbersNotFound{} -} - -/* GetPhoneNumbersNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetPhoneNumbersNotFound struct { - Payload *voip_models.Error -} - -func (o *GetPhoneNumbersNotFound) Error() string { - return fmt.Sprintf("[GET /phonenumbers][%d] getPhoneNumbersNotFound %+v", 404, o.Payload) -} -func (o *GetPhoneNumbersNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetPhoneNumbersNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetPhoneNumbersUnprocessableEntity creates a GetPhoneNumbersUnprocessableEntity with default headers values -func NewGetPhoneNumbersUnprocessableEntity() *GetPhoneNumbersUnprocessableEntity { - return &GetPhoneNumbersUnprocessableEntity{} -} - -/* GetPhoneNumbersUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type GetPhoneNumbersUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *GetPhoneNumbersUnprocessableEntity) Error() string { - return fmt.Sprintf("[GET /phonenumbers][%d] getPhoneNumbersUnprocessableEntity %+v", 422, o.Payload) -} -func (o *GetPhoneNumbersUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetPhoneNumbersUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetPhoneNumbersInternalServerError creates a GetPhoneNumbersInternalServerError with default headers values -func NewGetPhoneNumbersInternalServerError() *GetPhoneNumbersInternalServerError { - return &GetPhoneNumbersInternalServerError{} -} - -/* GetPhoneNumbersInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type GetPhoneNumbersInternalServerError struct { - Payload *voip_models.Error -} - -func (o *GetPhoneNumbersInternalServerError) Error() string { - return fmt.Sprintf("[GET /phonenumbers][%d] getPhoneNumbersInternalServerError %+v", 500, o.Payload) -} -func (o *GetPhoneNumbersInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetPhoneNumbersInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/phone_number/phone_number_client.go b/api/voip/voip_client/phone_number/phone_number_client.go deleted file mode 100644 index 894270f..0000000 --- a/api/voip/voip_client/phone_number/phone_number_client.go +++ /dev/null @@ -1,172 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package phone_number - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" -) - -// New creates a new phone number API client. -func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { - return &Client{transport: transport, formats: formats} -} - -/* -Client for phone number API -*/ -type Client struct { - transport runtime.ClientTransport - formats strfmt.Registry -} - -// ClientOption is the option for Client methods -type ClientOption func(*runtime.ClientOperation) - -// ClientService is the interface for Client methods -type ClientService interface { - GetPhoneNumbers(params *GetPhoneNumbersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetPhoneNumbersOK, error) - - PostPhoneNumbers(params *PostPhoneNumbersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostPhoneNumbersOK, error) - - PutPhoneNumbers(params *PutPhoneNumbersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutPhoneNumbersOK, error) - - SetTransport(transport runtime.ClientTransport) -} - -/* - GetPhoneNumbers gets a list of phone number - - Return a list of available Phone Number entities -*/ -func (a *Client) GetPhoneNumbers(params *GetPhoneNumbersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetPhoneNumbersOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewGetPhoneNumbersParams() - } - op := &runtime.ClientOperation{ - ID: "getPhoneNumbers", - Method: "GET", - PathPattern: "/phonenumbers", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"http"}, - Params: params, - Reader: &GetPhoneNumbersReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*GetPhoneNumbersOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getPhoneNumbers: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -/* - PostPhoneNumbers adds new phone numbers - - Create new Phone Numbers -*/ -func (a *Client) PostPhoneNumbers(params *PostPhoneNumbersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostPhoneNumbersOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewPostPhoneNumbersParams() - } - op := &runtime.ClientOperation{ - ID: "postPhoneNumbers", - Method: "POST", - PathPattern: "/phonenumbers", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"http"}, - Params: params, - Reader: &PostPhoneNumbersReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*PostPhoneNumbersOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for postPhoneNumbers: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -/* - PutPhoneNumbers updates phone numbers - - Update fields in an Phone Number record identified by Telnexus Id -*/ -func (a *Client) PutPhoneNumbers(params *PutPhoneNumbersParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutPhoneNumbersOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewPutPhoneNumbersParams() - } - op := &runtime.ClientOperation{ - ID: "putPhoneNumbers", - Method: "PUT", - PathPattern: "/phonenumbers", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"http"}, - Params: params, - Reader: &PutPhoneNumbersReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*PutPhoneNumbersOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for putPhoneNumbers: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -// SetTransport changes the transport on the client -func (a *Client) SetTransport(transport runtime.ClientTransport) { - a.transport = transport -} diff --git a/api/voip/voip_client/phone_number/post_phone_numbers_parameters.go b/api/voip/voip_client/phone_number/post_phone_numbers_parameters.go deleted file mode 100644 index 533d4a5..0000000 --- a/api/voip/voip_client/phone_number/post_phone_numbers_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package phone_number - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// NewPostPhoneNumbersParams creates a new PostPhoneNumbersParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPostPhoneNumbersParams() *PostPhoneNumbersParams { - return &PostPhoneNumbersParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPostPhoneNumbersParamsWithTimeout creates a new PostPhoneNumbersParams object -// with the ability to set a timeout on a request. -func NewPostPhoneNumbersParamsWithTimeout(timeout time.Duration) *PostPhoneNumbersParams { - return &PostPhoneNumbersParams{ - timeout: timeout, - } -} - -// NewPostPhoneNumbersParamsWithContext creates a new PostPhoneNumbersParams object -// with the ability to set a context for a request. -func NewPostPhoneNumbersParamsWithContext(ctx context.Context) *PostPhoneNumbersParams { - return &PostPhoneNumbersParams{ - Context: ctx, - } -} - -// NewPostPhoneNumbersParamsWithHTTPClient creates a new PostPhoneNumbersParams object -// with the ability to set a custom HTTPClient for a request. -func NewPostPhoneNumbersParamsWithHTTPClient(client *http.Client) *PostPhoneNumbersParams { - return &PostPhoneNumbersParams{ - HTTPClient: client, - } -} - -/* PostPhoneNumbersParams contains all the parameters to send to the API endpoint - for the post phone numbers operation. - - Typically these are written to a http.Request. -*/ -type PostPhoneNumbersParams struct { - - /* PhoneNumberRequest. - - An array of new PBX records - */ - PhoneNumberRequest *voip_models.PhoneNumberRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the post phone numbers params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostPhoneNumbersParams) WithDefaults() *PostPhoneNumbersParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the post phone numbers params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostPhoneNumbersParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the post phone numbers params -func (o *PostPhoneNumbersParams) WithTimeout(timeout time.Duration) *PostPhoneNumbersParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the post phone numbers params -func (o *PostPhoneNumbersParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the post phone numbers params -func (o *PostPhoneNumbersParams) WithContext(ctx context.Context) *PostPhoneNumbersParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the post phone numbers params -func (o *PostPhoneNumbersParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the post phone numbers params -func (o *PostPhoneNumbersParams) WithHTTPClient(client *http.Client) *PostPhoneNumbersParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the post phone numbers params -func (o *PostPhoneNumbersParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithPhoneNumberRequest adds the phoneNumberRequest to the post phone numbers params -func (o *PostPhoneNumbersParams) WithPhoneNumberRequest(phoneNumberRequest *voip_models.PhoneNumberRequest) *PostPhoneNumbersParams { - o.SetPhoneNumberRequest(phoneNumberRequest) - return o -} - -// SetPhoneNumberRequest adds the phoneNumberRequest to the post phone numbers params -func (o *PostPhoneNumbersParams) SetPhoneNumberRequest(phoneNumberRequest *voip_models.PhoneNumberRequest) { - o.PhoneNumberRequest = phoneNumberRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PostPhoneNumbersParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.PhoneNumberRequest != nil { - if err := r.SetBodyParam(o.PhoneNumberRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/phone_number/post_phone_numbers_responses.go b/api/voip/voip_client/phone_number/post_phone_numbers_responses.go deleted file mode 100644 index 3c4702c..0000000 --- a/api/voip/voip_client/phone_number/post_phone_numbers_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package phone_number - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// PostPhoneNumbersReader is a Reader for the PostPhoneNumbers structure. -type PostPhoneNumbersReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PostPhoneNumbersReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPostPhoneNumbersOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPostPhoneNumbersUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPostPhoneNumbersForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPostPhoneNumbersNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPostPhoneNumbersUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPostPhoneNumbersInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPostPhoneNumbersOK creates a PostPhoneNumbersOK with default headers values -func NewPostPhoneNumbersOK() *PostPhoneNumbersOK { - return &PostPhoneNumbersOK{} -} - -/* PostPhoneNumbersOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of PBX objects -*/ -type PostPhoneNumbersOK struct { - Payload *voip_models.PhoneNumberResponse -} - -func (o *PostPhoneNumbersOK) Error() string { - return fmt.Sprintf("[POST /phonenumbers][%d] postPhoneNumbersOK %+v", 200, o.Payload) -} -func (o *PostPhoneNumbersOK) GetPayload() *voip_models.PhoneNumberResponse { - return o.Payload -} - -func (o *PostPhoneNumbersOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.PhoneNumberResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostPhoneNumbersUnauthorized creates a PostPhoneNumbersUnauthorized with default headers values -func NewPostPhoneNumbersUnauthorized() *PostPhoneNumbersUnauthorized { - return &PostPhoneNumbersUnauthorized{} -} - -/* PostPhoneNumbersUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PostPhoneNumbersUnauthorized struct { - Payload *voip_models.Error -} - -func (o *PostPhoneNumbersUnauthorized) Error() string { - return fmt.Sprintf("[POST /phonenumbers][%d] postPhoneNumbersUnauthorized %+v", 401, o.Payload) -} -func (o *PostPhoneNumbersUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostPhoneNumbersUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostPhoneNumbersForbidden creates a PostPhoneNumbersForbidden with default headers values -func NewPostPhoneNumbersForbidden() *PostPhoneNumbersForbidden { - return &PostPhoneNumbersForbidden{} -} - -/* PostPhoneNumbersForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PostPhoneNumbersForbidden struct { - Payload *voip_models.Error -} - -func (o *PostPhoneNumbersForbidden) Error() string { - return fmt.Sprintf("[POST /phonenumbers][%d] postPhoneNumbersForbidden %+v", 403, o.Payload) -} -func (o *PostPhoneNumbersForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostPhoneNumbersForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostPhoneNumbersNotFound creates a PostPhoneNumbersNotFound with default headers values -func NewPostPhoneNumbersNotFound() *PostPhoneNumbersNotFound { - return &PostPhoneNumbersNotFound{} -} - -/* PostPhoneNumbersNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PostPhoneNumbersNotFound struct { - Payload *voip_models.Error -} - -func (o *PostPhoneNumbersNotFound) Error() string { - return fmt.Sprintf("[POST /phonenumbers][%d] postPhoneNumbersNotFound %+v", 404, o.Payload) -} -func (o *PostPhoneNumbersNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostPhoneNumbersNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostPhoneNumbersUnprocessableEntity creates a PostPhoneNumbersUnprocessableEntity with default headers values -func NewPostPhoneNumbersUnprocessableEntity() *PostPhoneNumbersUnprocessableEntity { - return &PostPhoneNumbersUnprocessableEntity{} -} - -/* PostPhoneNumbersUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PostPhoneNumbersUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *PostPhoneNumbersUnprocessableEntity) Error() string { - return fmt.Sprintf("[POST /phonenumbers][%d] postPhoneNumbersUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PostPhoneNumbersUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostPhoneNumbersUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostPhoneNumbersInternalServerError creates a PostPhoneNumbersInternalServerError with default headers values -func NewPostPhoneNumbersInternalServerError() *PostPhoneNumbersInternalServerError { - return &PostPhoneNumbersInternalServerError{} -} - -/* PostPhoneNumbersInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PostPhoneNumbersInternalServerError struct { - Payload *voip_models.Error -} - -func (o *PostPhoneNumbersInternalServerError) Error() string { - return fmt.Sprintf("[POST /phonenumbers][%d] postPhoneNumbersInternalServerError %+v", 500, o.Payload) -} -func (o *PostPhoneNumbersInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostPhoneNumbersInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/phone_number/put_phone_numbers_parameters.go b/api/voip/voip_client/phone_number/put_phone_numbers_parameters.go deleted file mode 100644 index 1561da5..0000000 --- a/api/voip/voip_client/phone_number/put_phone_numbers_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package phone_number - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// NewPutPhoneNumbersParams creates a new PutPhoneNumbersParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPutPhoneNumbersParams() *PutPhoneNumbersParams { - return &PutPhoneNumbersParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPutPhoneNumbersParamsWithTimeout creates a new PutPhoneNumbersParams object -// with the ability to set a timeout on a request. -func NewPutPhoneNumbersParamsWithTimeout(timeout time.Duration) *PutPhoneNumbersParams { - return &PutPhoneNumbersParams{ - timeout: timeout, - } -} - -// NewPutPhoneNumbersParamsWithContext creates a new PutPhoneNumbersParams object -// with the ability to set a context for a request. -func NewPutPhoneNumbersParamsWithContext(ctx context.Context) *PutPhoneNumbersParams { - return &PutPhoneNumbersParams{ - Context: ctx, - } -} - -// NewPutPhoneNumbersParamsWithHTTPClient creates a new PutPhoneNumbersParams object -// with the ability to set a custom HTTPClient for a request. -func NewPutPhoneNumbersParamsWithHTTPClient(client *http.Client) *PutPhoneNumbersParams { - return &PutPhoneNumbersParams{ - HTTPClient: client, - } -} - -/* PutPhoneNumbersParams contains all the parameters to send to the API endpoint - for the put phone numbers operation. - - Typically these are written to a http.Request. -*/ -type PutPhoneNumbersParams struct { - - /* PhoneNumberRequest. - - An array of new PBX records - */ - PhoneNumberRequest *voip_models.PhoneNumberRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the put phone numbers params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PutPhoneNumbersParams) WithDefaults() *PutPhoneNumbersParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the put phone numbers params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PutPhoneNumbersParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the put phone numbers params -func (o *PutPhoneNumbersParams) WithTimeout(timeout time.Duration) *PutPhoneNumbersParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the put phone numbers params -func (o *PutPhoneNumbersParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the put phone numbers params -func (o *PutPhoneNumbersParams) WithContext(ctx context.Context) *PutPhoneNumbersParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the put phone numbers params -func (o *PutPhoneNumbersParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the put phone numbers params -func (o *PutPhoneNumbersParams) WithHTTPClient(client *http.Client) *PutPhoneNumbersParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the put phone numbers params -func (o *PutPhoneNumbersParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithPhoneNumberRequest adds the phoneNumberRequest to the put phone numbers params -func (o *PutPhoneNumbersParams) WithPhoneNumberRequest(phoneNumberRequest *voip_models.PhoneNumberRequest) *PutPhoneNumbersParams { - o.SetPhoneNumberRequest(phoneNumberRequest) - return o -} - -// SetPhoneNumberRequest adds the phoneNumberRequest to the put phone numbers params -func (o *PutPhoneNumbersParams) SetPhoneNumberRequest(phoneNumberRequest *voip_models.PhoneNumberRequest) { - o.PhoneNumberRequest = phoneNumberRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PutPhoneNumbersParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.PhoneNumberRequest != nil { - if err := r.SetBodyParam(o.PhoneNumberRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/phone_number/put_phone_numbers_responses.go b/api/voip/voip_client/phone_number/put_phone_numbers_responses.go deleted file mode 100644 index c1248d1..0000000 --- a/api/voip/voip_client/phone_number/put_phone_numbers_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package phone_number - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// PutPhoneNumbersReader is a Reader for the PutPhoneNumbers structure. -type PutPhoneNumbersReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PutPhoneNumbersReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPutPhoneNumbersOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPutPhoneNumbersUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPutPhoneNumbersForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPutPhoneNumbersNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPutPhoneNumbersUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPutPhoneNumbersInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPutPhoneNumbersOK creates a PutPhoneNumbersOK with default headers values -func NewPutPhoneNumbersOK() *PutPhoneNumbersOK { - return &PutPhoneNumbersOK{} -} - -/* PutPhoneNumbersOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of PBX objects -*/ -type PutPhoneNumbersOK struct { - Payload *voip_models.PhoneNumberResponse -} - -func (o *PutPhoneNumbersOK) Error() string { - return fmt.Sprintf("[PUT /phonenumbers][%d] putPhoneNumbersOK %+v", 200, o.Payload) -} -func (o *PutPhoneNumbersOK) GetPayload() *voip_models.PhoneNumberResponse { - return o.Payload -} - -func (o *PutPhoneNumbersOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.PhoneNumberResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutPhoneNumbersUnauthorized creates a PutPhoneNumbersUnauthorized with default headers values -func NewPutPhoneNumbersUnauthorized() *PutPhoneNumbersUnauthorized { - return &PutPhoneNumbersUnauthorized{} -} - -/* PutPhoneNumbersUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PutPhoneNumbersUnauthorized struct { - Payload *voip_models.Error -} - -func (o *PutPhoneNumbersUnauthorized) Error() string { - return fmt.Sprintf("[PUT /phonenumbers][%d] putPhoneNumbersUnauthorized %+v", 401, o.Payload) -} -func (o *PutPhoneNumbersUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutPhoneNumbersUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutPhoneNumbersForbidden creates a PutPhoneNumbersForbidden with default headers values -func NewPutPhoneNumbersForbidden() *PutPhoneNumbersForbidden { - return &PutPhoneNumbersForbidden{} -} - -/* PutPhoneNumbersForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PutPhoneNumbersForbidden struct { - Payload *voip_models.Error -} - -func (o *PutPhoneNumbersForbidden) Error() string { - return fmt.Sprintf("[PUT /phonenumbers][%d] putPhoneNumbersForbidden %+v", 403, o.Payload) -} -func (o *PutPhoneNumbersForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutPhoneNumbersForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutPhoneNumbersNotFound creates a PutPhoneNumbersNotFound with default headers values -func NewPutPhoneNumbersNotFound() *PutPhoneNumbersNotFound { - return &PutPhoneNumbersNotFound{} -} - -/* PutPhoneNumbersNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PutPhoneNumbersNotFound struct { - Payload *voip_models.Error -} - -func (o *PutPhoneNumbersNotFound) Error() string { - return fmt.Sprintf("[PUT /phonenumbers][%d] putPhoneNumbersNotFound %+v", 404, o.Payload) -} -func (o *PutPhoneNumbersNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutPhoneNumbersNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutPhoneNumbersUnprocessableEntity creates a PutPhoneNumbersUnprocessableEntity with default headers values -func NewPutPhoneNumbersUnprocessableEntity() *PutPhoneNumbersUnprocessableEntity { - return &PutPhoneNumbersUnprocessableEntity{} -} - -/* PutPhoneNumbersUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PutPhoneNumbersUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *PutPhoneNumbersUnprocessableEntity) Error() string { - return fmt.Sprintf("[PUT /phonenumbers][%d] putPhoneNumbersUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PutPhoneNumbersUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutPhoneNumbersUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutPhoneNumbersInternalServerError creates a PutPhoneNumbersInternalServerError with default headers values -func NewPutPhoneNumbersInternalServerError() *PutPhoneNumbersInternalServerError { - return &PutPhoneNumbersInternalServerError{} -} - -/* PutPhoneNumbersInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PutPhoneNumbersInternalServerError struct { - Payload *voip_models.Error -} - -func (o *PutPhoneNumbersInternalServerError) Error() string { - return fmt.Sprintf("[PUT /phonenumbers][%d] putPhoneNumbersInternalServerError %+v", 500, o.Payload) -} -func (o *PutPhoneNumbersInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutPhoneNumbersInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/queue/get_queues_parameters.go b/api/voip/voip_client/queue/get_queues_parameters.go deleted file mode 100644 index 63b7e2e..0000000 --- a/api/voip/voip_client/queue/get_queues_parameters.go +++ /dev/null @@ -1,253 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package queue - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// NewGetQueuesParams creates a new GetQueuesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetQueuesParams() *GetQueuesParams { - return &GetQueuesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetQueuesParamsWithTimeout creates a new GetQueuesParams object -// with the ability to set a timeout on a request. -func NewGetQueuesParamsWithTimeout(timeout time.Duration) *GetQueuesParams { - return &GetQueuesParams{ - timeout: timeout, - } -} - -// NewGetQueuesParamsWithContext creates a new GetQueuesParams object -// with the ability to set a context for a request. -func NewGetQueuesParamsWithContext(ctx context.Context) *GetQueuesParams { - return &GetQueuesParams{ - Context: ctx, - } -} - -// NewGetQueuesParamsWithHTTPClient creates a new GetQueuesParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetQueuesParamsWithHTTPClient(client *http.Client) *GetQueuesParams { - return &GetQueuesParams{ - HTTPClient: client, - } -} - -/* GetQueuesParams contains all the parameters to send to the API endpoint - for the get queues operation. - - Typically these are written to a http.Request. -*/ -type GetQueuesParams struct { - - /* Limit. - - How many objects to return at one time (max 300, default 100) - - Format: int64 - Default: 100 - */ - Limit *int64 - - /* Offset. - - How many objects to skip? (default 0) - - Format: int64 - */ - Offset *int64 - - /* QueueID. - - Telnexus Id of the Queue to be retrieved - */ - QueueID *string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get queues params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetQueuesParams) WithDefaults() *GetQueuesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get queues params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetQueuesParams) SetDefaults() { - var ( - limitDefault = int64(100) - - offsetDefault = int64(0) - ) - - val := GetQueuesParams{ - Limit: &limitDefault, - Offset: &offsetDefault, - } - - val.timeout = o.timeout - val.Context = o.Context - val.HTTPClient = o.HTTPClient - *o = val -} - -// WithTimeout adds the timeout to the get queues params -func (o *GetQueuesParams) WithTimeout(timeout time.Duration) *GetQueuesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get queues params -func (o *GetQueuesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get queues params -func (o *GetQueuesParams) WithContext(ctx context.Context) *GetQueuesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get queues params -func (o *GetQueuesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get queues params -func (o *GetQueuesParams) WithHTTPClient(client *http.Client) *GetQueuesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get queues params -func (o *GetQueuesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithLimit adds the limit to the get queues params -func (o *GetQueuesParams) WithLimit(limit *int64) *GetQueuesParams { - o.SetLimit(limit) - return o -} - -// SetLimit adds the limit to the get queues params -func (o *GetQueuesParams) SetLimit(limit *int64) { - o.Limit = limit -} - -// WithOffset adds the offset to the get queues params -func (o *GetQueuesParams) WithOffset(offset *int64) *GetQueuesParams { - o.SetOffset(offset) - return o -} - -// SetOffset adds the offset to the get queues params -func (o *GetQueuesParams) SetOffset(offset *int64) { - o.Offset = offset -} - -// WithQueueID adds the queueID to the get queues params -func (o *GetQueuesParams) WithQueueID(queueID *string) *GetQueuesParams { - o.SetQueueID(queueID) - return o -} - -// SetQueueID adds the queueId to the get queues params -func (o *GetQueuesParams) SetQueueID(queueID *string) { - o.QueueID = queueID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetQueuesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - if o.Limit != nil { - - // query param limit - var qrLimit int64 - - if o.Limit != nil { - qrLimit = *o.Limit - } - qLimit := swag.FormatInt64(qrLimit) - if qLimit != "" { - - if err := r.SetQueryParam("limit", qLimit); err != nil { - return err - } - } - } - - if o.Offset != nil { - - // query param offset - var qrOffset int64 - - if o.Offset != nil { - qrOffset = *o.Offset - } - qOffset := swag.FormatInt64(qrOffset) - if qOffset != "" { - - if err := r.SetQueryParam("offset", qOffset); err != nil { - return err - } - } - } - - if o.QueueID != nil { - - // query param queueId - var qrQueueID string - - if o.QueueID != nil { - qrQueueID = *o.QueueID - } - qQueueID := qrQueueID - if qQueueID != "" { - - if err := r.SetQueryParam("queueId", qQueueID); err != nil { - return err - } - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/queue/get_queues_responses.go b/api/voip/voip_client/queue/get_queues_responses.go deleted file mode 100644 index 70a3c1b..0000000 --- a/api/voip/voip_client/queue/get_queues_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package queue - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// GetQueuesReader is a Reader for the GetQueues structure. -type GetQueuesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetQueuesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetQueuesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetQueuesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewGetQueuesForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetQueuesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewGetQueuesUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewGetQueuesInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetQueuesOK creates a GetQueuesOK with default headers values -func NewGetQueuesOK() *GetQueuesOK { - return &GetQueuesOK{} -} - -/* GetQueuesOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of Queue objects -*/ -type GetQueuesOK struct { - Payload *voip_models.QueueResponse -} - -func (o *GetQueuesOK) Error() string { - return fmt.Sprintf("[GET /queues][%d] getQueuesOK %+v", 200, o.Payload) -} -func (o *GetQueuesOK) GetPayload() *voip_models.QueueResponse { - return o.Payload -} - -func (o *GetQueuesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.QueueResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetQueuesUnauthorized creates a GetQueuesUnauthorized with default headers values -func NewGetQueuesUnauthorized() *GetQueuesUnauthorized { - return &GetQueuesUnauthorized{} -} - -/* GetQueuesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetQueuesUnauthorized struct { - Payload *voip_models.Error -} - -func (o *GetQueuesUnauthorized) Error() string { - return fmt.Sprintf("[GET /queues][%d] getQueuesUnauthorized %+v", 401, o.Payload) -} -func (o *GetQueuesUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetQueuesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetQueuesForbidden creates a GetQueuesForbidden with default headers values -func NewGetQueuesForbidden() *GetQueuesForbidden { - return &GetQueuesForbidden{} -} - -/* GetQueuesForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type GetQueuesForbidden struct { - Payload *voip_models.Error -} - -func (o *GetQueuesForbidden) Error() string { - return fmt.Sprintf("[GET /queues][%d] getQueuesForbidden %+v", 403, o.Payload) -} -func (o *GetQueuesForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetQueuesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetQueuesNotFound creates a GetQueuesNotFound with default headers values -func NewGetQueuesNotFound() *GetQueuesNotFound { - return &GetQueuesNotFound{} -} - -/* GetQueuesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetQueuesNotFound struct { - Payload *voip_models.Error -} - -func (o *GetQueuesNotFound) Error() string { - return fmt.Sprintf("[GET /queues][%d] getQueuesNotFound %+v", 404, o.Payload) -} -func (o *GetQueuesNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetQueuesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetQueuesUnprocessableEntity creates a GetQueuesUnprocessableEntity with default headers values -func NewGetQueuesUnprocessableEntity() *GetQueuesUnprocessableEntity { - return &GetQueuesUnprocessableEntity{} -} - -/* GetQueuesUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type GetQueuesUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *GetQueuesUnprocessableEntity) Error() string { - return fmt.Sprintf("[GET /queues][%d] getQueuesUnprocessableEntity %+v", 422, o.Payload) -} -func (o *GetQueuesUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetQueuesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetQueuesInternalServerError creates a GetQueuesInternalServerError with default headers values -func NewGetQueuesInternalServerError() *GetQueuesInternalServerError { - return &GetQueuesInternalServerError{} -} - -/* GetQueuesInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type GetQueuesInternalServerError struct { - Payload *voip_models.Error -} - -func (o *GetQueuesInternalServerError) Error() string { - return fmt.Sprintf("[GET /queues][%d] getQueuesInternalServerError %+v", 500, o.Payload) -} -func (o *GetQueuesInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetQueuesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/queue/post_queues_parameters.go b/api/voip/voip_client/queue/post_queues_parameters.go deleted file mode 100644 index 7a98289..0000000 --- a/api/voip/voip_client/queue/post_queues_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package queue - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// NewPostQueuesParams creates a new PostQueuesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPostQueuesParams() *PostQueuesParams { - return &PostQueuesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPostQueuesParamsWithTimeout creates a new PostQueuesParams object -// with the ability to set a timeout on a request. -func NewPostQueuesParamsWithTimeout(timeout time.Duration) *PostQueuesParams { - return &PostQueuesParams{ - timeout: timeout, - } -} - -// NewPostQueuesParamsWithContext creates a new PostQueuesParams object -// with the ability to set a context for a request. -func NewPostQueuesParamsWithContext(ctx context.Context) *PostQueuesParams { - return &PostQueuesParams{ - Context: ctx, - } -} - -// NewPostQueuesParamsWithHTTPClient creates a new PostQueuesParams object -// with the ability to set a custom HTTPClient for a request. -func NewPostQueuesParamsWithHTTPClient(client *http.Client) *PostQueuesParams { - return &PostQueuesParams{ - HTTPClient: client, - } -} - -/* PostQueuesParams contains all the parameters to send to the API endpoint - for the post queues operation. - - Typically these are written to a http.Request. -*/ -type PostQueuesParams struct { - - /* QueueRequest. - - An array of new Queues - */ - QueueRequest *voip_models.QueueRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the post queues params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostQueuesParams) WithDefaults() *PostQueuesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the post queues params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostQueuesParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the post queues params -func (o *PostQueuesParams) WithTimeout(timeout time.Duration) *PostQueuesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the post queues params -func (o *PostQueuesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the post queues params -func (o *PostQueuesParams) WithContext(ctx context.Context) *PostQueuesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the post queues params -func (o *PostQueuesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the post queues params -func (o *PostQueuesParams) WithHTTPClient(client *http.Client) *PostQueuesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the post queues params -func (o *PostQueuesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithQueueRequest adds the queueRequest to the post queues params -func (o *PostQueuesParams) WithQueueRequest(queueRequest *voip_models.QueueRequest) *PostQueuesParams { - o.SetQueueRequest(queueRequest) - return o -} - -// SetQueueRequest adds the queueRequest to the post queues params -func (o *PostQueuesParams) SetQueueRequest(queueRequest *voip_models.QueueRequest) { - o.QueueRequest = queueRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PostQueuesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.QueueRequest != nil { - if err := r.SetBodyParam(o.QueueRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/queue/post_queues_responses.go b/api/voip/voip_client/queue/post_queues_responses.go deleted file mode 100644 index 1351005..0000000 --- a/api/voip/voip_client/queue/post_queues_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package queue - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// PostQueuesReader is a Reader for the PostQueues structure. -type PostQueuesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PostQueuesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPostQueuesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPostQueuesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPostQueuesForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPostQueuesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPostQueuesUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPostQueuesInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPostQueuesOK creates a PostQueuesOK with default headers values -func NewPostQueuesOK() *PostQueuesOK { - return &PostQueuesOK{} -} - -/* PostQueuesOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of Queue objects -*/ -type PostQueuesOK struct { - Payload *voip_models.QueueResponse -} - -func (o *PostQueuesOK) Error() string { - return fmt.Sprintf("[POST /queues][%d] postQueuesOK %+v", 200, o.Payload) -} -func (o *PostQueuesOK) GetPayload() *voip_models.QueueResponse { - return o.Payload -} - -func (o *PostQueuesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.QueueResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostQueuesUnauthorized creates a PostQueuesUnauthorized with default headers values -func NewPostQueuesUnauthorized() *PostQueuesUnauthorized { - return &PostQueuesUnauthorized{} -} - -/* PostQueuesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PostQueuesUnauthorized struct { - Payload *voip_models.Error -} - -func (o *PostQueuesUnauthorized) Error() string { - return fmt.Sprintf("[POST /queues][%d] postQueuesUnauthorized %+v", 401, o.Payload) -} -func (o *PostQueuesUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostQueuesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostQueuesForbidden creates a PostQueuesForbidden with default headers values -func NewPostQueuesForbidden() *PostQueuesForbidden { - return &PostQueuesForbidden{} -} - -/* PostQueuesForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PostQueuesForbidden struct { - Payload *voip_models.Error -} - -func (o *PostQueuesForbidden) Error() string { - return fmt.Sprintf("[POST /queues][%d] postQueuesForbidden %+v", 403, o.Payload) -} -func (o *PostQueuesForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostQueuesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostQueuesNotFound creates a PostQueuesNotFound with default headers values -func NewPostQueuesNotFound() *PostQueuesNotFound { - return &PostQueuesNotFound{} -} - -/* PostQueuesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PostQueuesNotFound struct { - Payload *voip_models.Error -} - -func (o *PostQueuesNotFound) Error() string { - return fmt.Sprintf("[POST /queues][%d] postQueuesNotFound %+v", 404, o.Payload) -} -func (o *PostQueuesNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostQueuesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostQueuesUnprocessableEntity creates a PostQueuesUnprocessableEntity with default headers values -func NewPostQueuesUnprocessableEntity() *PostQueuesUnprocessableEntity { - return &PostQueuesUnprocessableEntity{} -} - -/* PostQueuesUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PostQueuesUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *PostQueuesUnprocessableEntity) Error() string { - return fmt.Sprintf("[POST /queues][%d] postQueuesUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PostQueuesUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostQueuesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostQueuesInternalServerError creates a PostQueuesInternalServerError with default headers values -func NewPostQueuesInternalServerError() *PostQueuesInternalServerError { - return &PostQueuesInternalServerError{} -} - -/* PostQueuesInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PostQueuesInternalServerError struct { - Payload *voip_models.Error -} - -func (o *PostQueuesInternalServerError) Error() string { - return fmt.Sprintf("[POST /queues][%d] postQueuesInternalServerError %+v", 500, o.Payload) -} -func (o *PostQueuesInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostQueuesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/queue/put_queues_parameters.go b/api/voip/voip_client/queue/put_queues_parameters.go deleted file mode 100644 index 6a06672..0000000 --- a/api/voip/voip_client/queue/put_queues_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package queue - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// NewPutQueuesParams creates a new PutQueuesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPutQueuesParams() *PutQueuesParams { - return &PutQueuesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPutQueuesParamsWithTimeout creates a new PutQueuesParams object -// with the ability to set a timeout on a request. -func NewPutQueuesParamsWithTimeout(timeout time.Duration) *PutQueuesParams { - return &PutQueuesParams{ - timeout: timeout, - } -} - -// NewPutQueuesParamsWithContext creates a new PutQueuesParams object -// with the ability to set a context for a request. -func NewPutQueuesParamsWithContext(ctx context.Context) *PutQueuesParams { - return &PutQueuesParams{ - Context: ctx, - } -} - -// NewPutQueuesParamsWithHTTPClient creates a new PutQueuesParams object -// with the ability to set a custom HTTPClient for a request. -func NewPutQueuesParamsWithHTTPClient(client *http.Client) *PutQueuesParams { - return &PutQueuesParams{ - HTTPClient: client, - } -} - -/* PutQueuesParams contains all the parameters to send to the API endpoint - for the put queues operation. - - Typically these are written to a http.Request. -*/ -type PutQueuesParams struct { - - /* QueueRequest. - - An array of new Queues - */ - QueueRequest *voip_models.QueueRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the put queues params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PutQueuesParams) WithDefaults() *PutQueuesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the put queues params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PutQueuesParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the put queues params -func (o *PutQueuesParams) WithTimeout(timeout time.Duration) *PutQueuesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the put queues params -func (o *PutQueuesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the put queues params -func (o *PutQueuesParams) WithContext(ctx context.Context) *PutQueuesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the put queues params -func (o *PutQueuesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the put queues params -func (o *PutQueuesParams) WithHTTPClient(client *http.Client) *PutQueuesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the put queues params -func (o *PutQueuesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithQueueRequest adds the queueRequest to the put queues params -func (o *PutQueuesParams) WithQueueRequest(queueRequest *voip_models.QueueRequest) *PutQueuesParams { - o.SetQueueRequest(queueRequest) - return o -} - -// SetQueueRequest adds the queueRequest to the put queues params -func (o *PutQueuesParams) SetQueueRequest(queueRequest *voip_models.QueueRequest) { - o.QueueRequest = queueRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PutQueuesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.QueueRequest != nil { - if err := r.SetBodyParam(o.QueueRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/queue/put_queues_responses.go b/api/voip/voip_client/queue/put_queues_responses.go deleted file mode 100644 index 9005ff5..0000000 --- a/api/voip/voip_client/queue/put_queues_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package queue - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// PutQueuesReader is a Reader for the PutQueues structure. -type PutQueuesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PutQueuesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPutQueuesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPutQueuesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPutQueuesForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPutQueuesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPutQueuesUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPutQueuesInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPutQueuesOK creates a PutQueuesOK with default headers values -func NewPutQueuesOK() *PutQueuesOK { - return &PutQueuesOK{} -} - -/* PutQueuesOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of Queue objects -*/ -type PutQueuesOK struct { - Payload *voip_models.QueueResponse -} - -func (o *PutQueuesOK) Error() string { - return fmt.Sprintf("[PUT /queues][%d] putQueuesOK %+v", 200, o.Payload) -} -func (o *PutQueuesOK) GetPayload() *voip_models.QueueResponse { - return o.Payload -} - -func (o *PutQueuesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.QueueResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutQueuesUnauthorized creates a PutQueuesUnauthorized with default headers values -func NewPutQueuesUnauthorized() *PutQueuesUnauthorized { - return &PutQueuesUnauthorized{} -} - -/* PutQueuesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PutQueuesUnauthorized struct { - Payload *voip_models.Error -} - -func (o *PutQueuesUnauthorized) Error() string { - return fmt.Sprintf("[PUT /queues][%d] putQueuesUnauthorized %+v", 401, o.Payload) -} -func (o *PutQueuesUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutQueuesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutQueuesForbidden creates a PutQueuesForbidden with default headers values -func NewPutQueuesForbidden() *PutQueuesForbidden { - return &PutQueuesForbidden{} -} - -/* PutQueuesForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PutQueuesForbidden struct { - Payload *voip_models.Error -} - -func (o *PutQueuesForbidden) Error() string { - return fmt.Sprintf("[PUT /queues][%d] putQueuesForbidden %+v", 403, o.Payload) -} -func (o *PutQueuesForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutQueuesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutQueuesNotFound creates a PutQueuesNotFound with default headers values -func NewPutQueuesNotFound() *PutQueuesNotFound { - return &PutQueuesNotFound{} -} - -/* PutQueuesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PutQueuesNotFound struct { - Payload *voip_models.Error -} - -func (o *PutQueuesNotFound) Error() string { - return fmt.Sprintf("[PUT /queues][%d] putQueuesNotFound %+v", 404, o.Payload) -} -func (o *PutQueuesNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutQueuesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutQueuesUnprocessableEntity creates a PutQueuesUnprocessableEntity with default headers values -func NewPutQueuesUnprocessableEntity() *PutQueuesUnprocessableEntity { - return &PutQueuesUnprocessableEntity{} -} - -/* PutQueuesUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PutQueuesUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *PutQueuesUnprocessableEntity) Error() string { - return fmt.Sprintf("[PUT /queues][%d] putQueuesUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PutQueuesUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutQueuesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutQueuesInternalServerError creates a PutQueuesInternalServerError with default headers values -func NewPutQueuesInternalServerError() *PutQueuesInternalServerError { - return &PutQueuesInternalServerError{} -} - -/* PutQueuesInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PutQueuesInternalServerError struct { - Payload *voip_models.Error -} - -func (o *PutQueuesInternalServerError) Error() string { - return fmt.Sprintf("[PUT /queues][%d] putQueuesInternalServerError %+v", 500, o.Payload) -} -func (o *PutQueuesInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutQueuesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/queue/queue_client.go b/api/voip/voip_client/queue/queue_client.go deleted file mode 100644 index 34018b8..0000000 --- a/api/voip/voip_client/queue/queue_client.go +++ /dev/null @@ -1,172 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package queue - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" -) - -// New creates a new queue API client. -func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { - return &Client{transport: transport, formats: formats} -} - -/* -Client for queue API -*/ -type Client struct { - transport runtime.ClientTransport - formats strfmt.Registry -} - -// ClientOption is the option for Client methods -type ClientOption func(*runtime.ClientOperation) - -// ClientService is the interface for Client methods -type ClientService interface { - GetQueues(params *GetQueuesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetQueuesOK, error) - - PostQueues(params *PostQueuesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostQueuesOK, error) - - PutQueues(params *PutQueuesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutQueuesOK, error) - - SetTransport(transport runtime.ClientTransport) -} - -/* - GetQueues gets a list of queues - - Return a list of available Queues -*/ -func (a *Client) GetQueues(params *GetQueuesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetQueuesOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewGetQueuesParams() - } - op := &runtime.ClientOperation{ - ID: "getQueues", - Method: "GET", - PathPattern: "/queues", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"http"}, - Params: params, - Reader: &GetQueuesReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*GetQueuesOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for getQueues: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -/* - PostQueues adds new queues - - Create new Queues -*/ -func (a *Client) PostQueues(params *PostQueuesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PostQueuesOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewPostQueuesParams() - } - op := &runtime.ClientOperation{ - ID: "postQueues", - Method: "POST", - PathPattern: "/queues", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"http"}, - Params: params, - Reader: &PostQueuesReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*PostQueuesOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for postQueues: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -/* - PutQueues updates queues - - Update fields in Queue records identified by Telnexus Id -*/ -func (a *Client) PutQueues(params *PutQueuesParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*PutQueuesOK, error) { - // TODO: Validate the params before sending - if params == nil { - params = NewPutQueuesParams() - } - op := &runtime.ClientOperation{ - ID: "putQueues", - Method: "PUT", - PathPattern: "/queues", - ProducesMediaTypes: []string{"application/json"}, - ConsumesMediaTypes: []string{"application/json"}, - Schemes: []string{"http"}, - Params: params, - Reader: &PutQueuesReader{formats: a.formats}, - AuthInfo: authInfo, - Context: params.Context, - Client: params.HTTPClient, - } - for _, opt := range opts { - opt(op) - } - - result, err := a.transport.Submit(op) - if err != nil { - return nil, err - } - success, ok := result.(*PutQueuesOK) - if ok { - return success, nil - } - // unexpected success response - // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for putQueues: API contract not enforced by server. Client expected to get an error, but got: %T", result) - panic(msg) -} - -// SetTransport changes the transport on the client -func (a *Client) SetTransport(transport runtime.ClientTransport) { - a.transport = transport -} diff --git a/api/voip/voip_client/vm_box/get_vm_boxes_parameters.go b/api/voip/voip_client/vm_box/get_vm_boxes_parameters.go deleted file mode 100644 index 0d040a7..0000000 --- a/api/voip/voip_client/vm_box/get_vm_boxes_parameters.go +++ /dev/null @@ -1,253 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package vm_box - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// NewGetVMBoxesParams creates a new GetVMBoxesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewGetVMBoxesParams() *GetVMBoxesParams { - return &GetVMBoxesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewGetVMBoxesParamsWithTimeout creates a new GetVMBoxesParams object -// with the ability to set a timeout on a request. -func NewGetVMBoxesParamsWithTimeout(timeout time.Duration) *GetVMBoxesParams { - return &GetVMBoxesParams{ - timeout: timeout, - } -} - -// NewGetVMBoxesParamsWithContext creates a new GetVMBoxesParams object -// with the ability to set a context for a request. -func NewGetVMBoxesParamsWithContext(ctx context.Context) *GetVMBoxesParams { - return &GetVMBoxesParams{ - Context: ctx, - } -} - -// NewGetVMBoxesParamsWithHTTPClient creates a new GetVMBoxesParams object -// with the ability to set a custom HTTPClient for a request. -func NewGetVMBoxesParamsWithHTTPClient(client *http.Client) *GetVMBoxesParams { - return &GetVMBoxesParams{ - HTTPClient: client, - } -} - -/* GetVMBoxesParams contains all the parameters to send to the API endpoint - for the get Vm boxes operation. - - Typically these are written to a http.Request. -*/ -type GetVMBoxesParams struct { - - /* Limit. - - How many objects to return at one time (max 300, default 100) - - Format: int64 - Default: 100 - */ - Limit *int64 - - /* Offset. - - How many objects to skip? (default 0) - - Format: int64 - */ - Offset *int64 - - /* VMBoxID. - - Telnexus Id of the vmBox to be retrieved - */ - VMBoxID *string - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the get Vm boxes params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetVMBoxesParams) WithDefaults() *GetVMBoxesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the get Vm boxes params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *GetVMBoxesParams) SetDefaults() { - var ( - limitDefault = int64(100) - - offsetDefault = int64(0) - ) - - val := GetVMBoxesParams{ - Limit: &limitDefault, - Offset: &offsetDefault, - } - - val.timeout = o.timeout - val.Context = o.Context - val.HTTPClient = o.HTTPClient - *o = val -} - -// WithTimeout adds the timeout to the get Vm boxes params -func (o *GetVMBoxesParams) WithTimeout(timeout time.Duration) *GetVMBoxesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the get Vm boxes params -func (o *GetVMBoxesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the get Vm boxes params -func (o *GetVMBoxesParams) WithContext(ctx context.Context) *GetVMBoxesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the get Vm boxes params -func (o *GetVMBoxesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the get Vm boxes params -func (o *GetVMBoxesParams) WithHTTPClient(client *http.Client) *GetVMBoxesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the get Vm boxes params -func (o *GetVMBoxesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithLimit adds the limit to the get Vm boxes params -func (o *GetVMBoxesParams) WithLimit(limit *int64) *GetVMBoxesParams { - o.SetLimit(limit) - return o -} - -// SetLimit adds the limit to the get Vm boxes params -func (o *GetVMBoxesParams) SetLimit(limit *int64) { - o.Limit = limit -} - -// WithOffset adds the offset to the get Vm boxes params -func (o *GetVMBoxesParams) WithOffset(offset *int64) *GetVMBoxesParams { - o.SetOffset(offset) - return o -} - -// SetOffset adds the offset to the get Vm boxes params -func (o *GetVMBoxesParams) SetOffset(offset *int64) { - o.Offset = offset -} - -// WithVMBoxID adds the vMBoxID to the get Vm boxes params -func (o *GetVMBoxesParams) WithVMBoxID(vMBoxID *string) *GetVMBoxesParams { - o.SetVMBoxID(vMBoxID) - return o -} - -// SetVMBoxID adds the vmBoxId to the get Vm boxes params -func (o *GetVMBoxesParams) SetVMBoxID(vMBoxID *string) { - o.VMBoxID = vMBoxID -} - -// WriteToRequest writes these params to a swagger request -func (o *GetVMBoxesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - - if o.Limit != nil { - - // query param limit - var qrLimit int64 - - if o.Limit != nil { - qrLimit = *o.Limit - } - qLimit := swag.FormatInt64(qrLimit) - if qLimit != "" { - - if err := r.SetQueryParam("limit", qLimit); err != nil { - return err - } - } - } - - if o.Offset != nil { - - // query param offset - var qrOffset int64 - - if o.Offset != nil { - qrOffset = *o.Offset - } - qOffset := swag.FormatInt64(qrOffset) - if qOffset != "" { - - if err := r.SetQueryParam("offset", qOffset); err != nil { - return err - } - } - } - - if o.VMBoxID != nil { - - // query param vmBoxId - var qrVMBoxID string - - if o.VMBoxID != nil { - qrVMBoxID = *o.VMBoxID - } - qVMBoxID := qrVMBoxID - if qVMBoxID != "" { - - if err := r.SetQueryParam("vmBoxId", qVMBoxID); err != nil { - return err - } - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/vm_box/get_vm_boxes_responses.go b/api/voip/voip_client/vm_box/get_vm_boxes_responses.go deleted file mode 100644 index 6324edd..0000000 --- a/api/voip/voip_client/vm_box/get_vm_boxes_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package vm_box - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// GetVMBoxesReader is a Reader for the GetVMBoxes structure. -type GetVMBoxesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *GetVMBoxesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewGetVMBoxesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewGetVMBoxesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewGetVMBoxesForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewGetVMBoxesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewGetVMBoxesUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewGetVMBoxesInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewGetVMBoxesOK creates a GetVMBoxesOK with default headers values -func NewGetVMBoxesOK() *GetVMBoxesOK { - return &GetVMBoxesOK{} -} - -/* GetVMBoxesOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of PBX objects -*/ -type GetVMBoxesOK struct { - Payload *voip_models.VMBoxResponse -} - -func (o *GetVMBoxesOK) Error() string { - return fmt.Sprintf("[GET /vmboxes][%d] getVmBoxesOK %+v", 200, o.Payload) -} -func (o *GetVMBoxesOK) GetPayload() *voip_models.VMBoxResponse { - return o.Payload -} - -func (o *GetVMBoxesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.VMBoxResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetVMBoxesUnauthorized creates a GetVMBoxesUnauthorized with default headers values -func NewGetVMBoxesUnauthorized() *GetVMBoxesUnauthorized { - return &GetVMBoxesUnauthorized{} -} - -/* GetVMBoxesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type GetVMBoxesUnauthorized struct { - Payload *voip_models.Error -} - -func (o *GetVMBoxesUnauthorized) Error() string { - return fmt.Sprintf("[GET /vmboxes][%d] getVmBoxesUnauthorized %+v", 401, o.Payload) -} -func (o *GetVMBoxesUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetVMBoxesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetVMBoxesForbidden creates a GetVMBoxesForbidden with default headers values -func NewGetVMBoxesForbidden() *GetVMBoxesForbidden { - return &GetVMBoxesForbidden{} -} - -/* GetVMBoxesForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type GetVMBoxesForbidden struct { - Payload *voip_models.Error -} - -func (o *GetVMBoxesForbidden) Error() string { - return fmt.Sprintf("[GET /vmboxes][%d] getVmBoxesForbidden %+v", 403, o.Payload) -} -func (o *GetVMBoxesForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetVMBoxesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetVMBoxesNotFound creates a GetVMBoxesNotFound with default headers values -func NewGetVMBoxesNotFound() *GetVMBoxesNotFound { - return &GetVMBoxesNotFound{} -} - -/* GetVMBoxesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type GetVMBoxesNotFound struct { - Payload *voip_models.Error -} - -func (o *GetVMBoxesNotFound) Error() string { - return fmt.Sprintf("[GET /vmboxes][%d] getVmBoxesNotFound %+v", 404, o.Payload) -} -func (o *GetVMBoxesNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetVMBoxesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetVMBoxesUnprocessableEntity creates a GetVMBoxesUnprocessableEntity with default headers values -func NewGetVMBoxesUnprocessableEntity() *GetVMBoxesUnprocessableEntity { - return &GetVMBoxesUnprocessableEntity{} -} - -/* GetVMBoxesUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type GetVMBoxesUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *GetVMBoxesUnprocessableEntity) Error() string { - return fmt.Sprintf("[GET /vmboxes][%d] getVmBoxesUnprocessableEntity %+v", 422, o.Payload) -} -func (o *GetVMBoxesUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetVMBoxesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewGetVMBoxesInternalServerError creates a GetVMBoxesInternalServerError with default headers values -func NewGetVMBoxesInternalServerError() *GetVMBoxesInternalServerError { - return &GetVMBoxesInternalServerError{} -} - -/* GetVMBoxesInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type GetVMBoxesInternalServerError struct { - Payload *voip_models.Error -} - -func (o *GetVMBoxesInternalServerError) Error() string { - return fmt.Sprintf("[GET /vmboxes][%d] getVmBoxesInternalServerError %+v", 500, o.Payload) -} -func (o *GetVMBoxesInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *GetVMBoxesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/vm_box/post_vm_boxes_parameters.go b/api/voip/voip_client/vm_box/post_vm_boxes_parameters.go deleted file mode 100644 index 55d4271..0000000 --- a/api/voip/voip_client/vm_box/post_vm_boxes_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package vm_box - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// NewPostVMBoxesParams creates a new PostVMBoxesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPostVMBoxesParams() *PostVMBoxesParams { - return &PostVMBoxesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPostVMBoxesParamsWithTimeout creates a new PostVMBoxesParams object -// with the ability to set a timeout on a request. -func NewPostVMBoxesParamsWithTimeout(timeout time.Duration) *PostVMBoxesParams { - return &PostVMBoxesParams{ - timeout: timeout, - } -} - -// NewPostVMBoxesParamsWithContext creates a new PostVMBoxesParams object -// with the ability to set a context for a request. -func NewPostVMBoxesParamsWithContext(ctx context.Context) *PostVMBoxesParams { - return &PostVMBoxesParams{ - Context: ctx, - } -} - -// NewPostVMBoxesParamsWithHTTPClient creates a new PostVMBoxesParams object -// with the ability to set a custom HTTPClient for a request. -func NewPostVMBoxesParamsWithHTTPClient(client *http.Client) *PostVMBoxesParams { - return &PostVMBoxesParams{ - HTTPClient: client, - } -} - -/* PostVMBoxesParams contains all the parameters to send to the API endpoint - for the post Vm boxes operation. - - Typically these are written to a http.Request. -*/ -type PostVMBoxesParams struct { - - /* VMBoxRequest. - - An array of new VmBoxes - */ - VMBoxRequest *voip_models.VMBoxRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the post Vm boxes params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostVMBoxesParams) WithDefaults() *PostVMBoxesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the post Vm boxes params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PostVMBoxesParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the post Vm boxes params -func (o *PostVMBoxesParams) WithTimeout(timeout time.Duration) *PostVMBoxesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the post Vm boxes params -func (o *PostVMBoxesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the post Vm boxes params -func (o *PostVMBoxesParams) WithContext(ctx context.Context) *PostVMBoxesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the post Vm boxes params -func (o *PostVMBoxesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the post Vm boxes params -func (o *PostVMBoxesParams) WithHTTPClient(client *http.Client) *PostVMBoxesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the post Vm boxes params -func (o *PostVMBoxesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithVMBoxRequest adds the vMBoxRequest to the post Vm boxes params -func (o *PostVMBoxesParams) WithVMBoxRequest(vMBoxRequest *voip_models.VMBoxRequest) *PostVMBoxesParams { - o.SetVMBoxRequest(vMBoxRequest) - return o -} - -// SetVMBoxRequest adds the vmBoxRequest to the post Vm boxes params -func (o *PostVMBoxesParams) SetVMBoxRequest(vMBoxRequest *voip_models.VMBoxRequest) { - o.VMBoxRequest = vMBoxRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PostVMBoxesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.VMBoxRequest != nil { - if err := r.SetBodyParam(o.VMBoxRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/vm_box/post_vm_boxes_responses.go b/api/voip/voip_client/vm_box/post_vm_boxes_responses.go deleted file mode 100644 index 1fca7c2..0000000 --- a/api/voip/voip_client/vm_box/post_vm_boxes_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package vm_box - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// PostVMBoxesReader is a Reader for the PostVMBoxes structure. -type PostVMBoxesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PostVMBoxesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPostVMBoxesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPostVMBoxesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPostVMBoxesForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPostVMBoxesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPostVMBoxesUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPostVMBoxesInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPostVMBoxesOK creates a PostVMBoxesOK with default headers values -func NewPostVMBoxesOK() *PostVMBoxesOK { - return &PostVMBoxesOK{} -} - -/* PostVMBoxesOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of PBX objects -*/ -type PostVMBoxesOK struct { - Payload *voip_models.VMBoxResponse -} - -func (o *PostVMBoxesOK) Error() string { - return fmt.Sprintf("[POST /vmboxes][%d] postVmBoxesOK %+v", 200, o.Payload) -} -func (o *PostVMBoxesOK) GetPayload() *voip_models.VMBoxResponse { - return o.Payload -} - -func (o *PostVMBoxesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.VMBoxResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostVMBoxesUnauthorized creates a PostVMBoxesUnauthorized with default headers values -func NewPostVMBoxesUnauthorized() *PostVMBoxesUnauthorized { - return &PostVMBoxesUnauthorized{} -} - -/* PostVMBoxesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PostVMBoxesUnauthorized struct { - Payload *voip_models.Error -} - -func (o *PostVMBoxesUnauthorized) Error() string { - return fmt.Sprintf("[POST /vmboxes][%d] postVmBoxesUnauthorized %+v", 401, o.Payload) -} -func (o *PostVMBoxesUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostVMBoxesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostVMBoxesForbidden creates a PostVMBoxesForbidden with default headers values -func NewPostVMBoxesForbidden() *PostVMBoxesForbidden { - return &PostVMBoxesForbidden{} -} - -/* PostVMBoxesForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PostVMBoxesForbidden struct { - Payload *voip_models.Error -} - -func (o *PostVMBoxesForbidden) Error() string { - return fmt.Sprintf("[POST /vmboxes][%d] postVmBoxesForbidden %+v", 403, o.Payload) -} -func (o *PostVMBoxesForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostVMBoxesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostVMBoxesNotFound creates a PostVMBoxesNotFound with default headers values -func NewPostVMBoxesNotFound() *PostVMBoxesNotFound { - return &PostVMBoxesNotFound{} -} - -/* PostVMBoxesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PostVMBoxesNotFound struct { - Payload *voip_models.Error -} - -func (o *PostVMBoxesNotFound) Error() string { - return fmt.Sprintf("[POST /vmboxes][%d] postVmBoxesNotFound %+v", 404, o.Payload) -} -func (o *PostVMBoxesNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostVMBoxesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostVMBoxesUnprocessableEntity creates a PostVMBoxesUnprocessableEntity with default headers values -func NewPostVMBoxesUnprocessableEntity() *PostVMBoxesUnprocessableEntity { - return &PostVMBoxesUnprocessableEntity{} -} - -/* PostVMBoxesUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PostVMBoxesUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *PostVMBoxesUnprocessableEntity) Error() string { - return fmt.Sprintf("[POST /vmboxes][%d] postVmBoxesUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PostVMBoxesUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostVMBoxesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPostVMBoxesInternalServerError creates a PostVMBoxesInternalServerError with default headers values -func NewPostVMBoxesInternalServerError() *PostVMBoxesInternalServerError { - return &PostVMBoxesInternalServerError{} -} - -/* PostVMBoxesInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PostVMBoxesInternalServerError struct { - Payload *voip_models.Error -} - -func (o *PostVMBoxesInternalServerError) Error() string { - return fmt.Sprintf("[POST /vmboxes][%d] postVmBoxesInternalServerError %+v", 500, o.Payload) -} -func (o *PostVMBoxesInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PostVMBoxesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_client/vm_box/put_vm_boxes_parameters.go b/api/voip/voip_client/vm_box/put_vm_boxes_parameters.go deleted file mode 100644 index 419e589..0000000 --- a/api/voip/voip_client/vm_box/put_vm_boxes_parameters.go +++ /dev/null @@ -1,155 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package vm_box - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "net/http" - "time" - - "github.com/go-openapi/errors" - "github.com/go-openapi/runtime" - cr "github.com/go-openapi/runtime/client" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// NewPutVMBoxesParams creates a new PutVMBoxesParams object, -// with the default timeout for this client. -// -// Default values are not hydrated, since defaults are normally applied by the API server side. -// -// To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewPutVMBoxesParams() *PutVMBoxesParams { - return &PutVMBoxesParams{ - timeout: cr.DefaultTimeout, - } -} - -// NewPutVMBoxesParamsWithTimeout creates a new PutVMBoxesParams object -// with the ability to set a timeout on a request. -func NewPutVMBoxesParamsWithTimeout(timeout time.Duration) *PutVMBoxesParams { - return &PutVMBoxesParams{ - timeout: timeout, - } -} - -// NewPutVMBoxesParamsWithContext creates a new PutVMBoxesParams object -// with the ability to set a context for a request. -func NewPutVMBoxesParamsWithContext(ctx context.Context) *PutVMBoxesParams { - return &PutVMBoxesParams{ - Context: ctx, - } -} - -// NewPutVMBoxesParamsWithHTTPClient creates a new PutVMBoxesParams object -// with the ability to set a custom HTTPClient for a request. -func NewPutVMBoxesParamsWithHTTPClient(client *http.Client) *PutVMBoxesParams { - return &PutVMBoxesParams{ - HTTPClient: client, - } -} - -/* PutVMBoxesParams contains all the parameters to send to the API endpoint - for the put Vm boxes operation. - - Typically these are written to a http.Request. -*/ -type PutVMBoxesParams struct { - - /* VMBoxRequest. - - An array of new VmBoxes - */ - VMBoxRequest *voip_models.VMBoxRequest - - timeout time.Duration - Context context.Context - HTTPClient *http.Client -} - -// WithDefaults hydrates default values in the put Vm boxes params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PutVMBoxesParams) WithDefaults() *PutVMBoxesParams { - o.SetDefaults() - return o -} - -// SetDefaults hydrates default values in the put Vm boxes params (not the query body). -// -// All values with no default are reset to their zero value. -func (o *PutVMBoxesParams) SetDefaults() { - // no default values defined for this parameter -} - -// WithTimeout adds the timeout to the put Vm boxes params -func (o *PutVMBoxesParams) WithTimeout(timeout time.Duration) *PutVMBoxesParams { - o.SetTimeout(timeout) - return o -} - -// SetTimeout adds the timeout to the put Vm boxes params -func (o *PutVMBoxesParams) SetTimeout(timeout time.Duration) { - o.timeout = timeout -} - -// WithContext adds the context to the put Vm boxes params -func (o *PutVMBoxesParams) WithContext(ctx context.Context) *PutVMBoxesParams { - o.SetContext(ctx) - return o -} - -// SetContext adds the context to the put Vm boxes params -func (o *PutVMBoxesParams) SetContext(ctx context.Context) { - o.Context = ctx -} - -// WithHTTPClient adds the HTTPClient to the put Vm boxes params -func (o *PutVMBoxesParams) WithHTTPClient(client *http.Client) *PutVMBoxesParams { - o.SetHTTPClient(client) - return o -} - -// SetHTTPClient adds the HTTPClient to the put Vm boxes params -func (o *PutVMBoxesParams) SetHTTPClient(client *http.Client) { - o.HTTPClient = client -} - -// WithVMBoxRequest adds the vMBoxRequest to the put Vm boxes params -func (o *PutVMBoxesParams) WithVMBoxRequest(vMBoxRequest *voip_models.VMBoxRequest) *PutVMBoxesParams { - o.SetVMBoxRequest(vMBoxRequest) - return o -} - -// SetVMBoxRequest adds the vmBoxRequest to the put Vm boxes params -func (o *PutVMBoxesParams) SetVMBoxRequest(vMBoxRequest *voip_models.VMBoxRequest) { - o.VMBoxRequest = vMBoxRequest -} - -// WriteToRequest writes these params to a swagger request -func (o *PutVMBoxesParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { - - if err := r.SetTimeout(o.timeout); err != nil { - return err - } - var res []error - if o.VMBoxRequest != nil { - if err := r.SetBodyParam(o.VMBoxRequest); err != nil { - return err - } - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} diff --git a/api/voip/voip_client/vm_box/put_vm_boxes_responses.go b/api/voip/voip_client/vm_box/put_vm_boxes_responses.go deleted file mode 100644 index d05d6d7..0000000 --- a/api/voip/voip_client/vm_box/put_vm_boxes_responses.go +++ /dev/null @@ -1,261 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package vm_box - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "fmt" - "io" - - "github.com/go-openapi/runtime" - "github.com/go-openapi/strfmt" - - "code.tnxs.net/vernonkeenan/lib/api/voip/voip_models" -) - -// PutVMBoxesReader is a Reader for the PutVMBoxes structure. -type PutVMBoxesReader struct { - formats strfmt.Registry -} - -// ReadResponse reads a server response into the received o. -func (o *PutVMBoxesReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { - switch response.Code() { - case 200: - result := NewPutVMBoxesOK() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return result, nil - case 401: - result := NewPutVMBoxesUnauthorized() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 403: - result := NewPutVMBoxesForbidden() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 404: - result := NewPutVMBoxesNotFound() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 422: - result := NewPutVMBoxesUnprocessableEntity() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - case 500: - result := NewPutVMBoxesInternalServerError() - if err := result.readResponse(response, consumer, o.formats); err != nil { - return nil, err - } - return nil, result - default: - return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) - } -} - -// NewPutVMBoxesOK creates a PutVMBoxesOK with default headers values -func NewPutVMBoxesOK() *PutVMBoxesOK { - return &PutVMBoxesOK{} -} - -/* PutVMBoxesOK describes a response with status code 200, with default header values. - -Telnexus Response with an array of PBX objects -*/ -type PutVMBoxesOK struct { - Payload *voip_models.VMBoxResponse -} - -func (o *PutVMBoxesOK) Error() string { - return fmt.Sprintf("[PUT /vmboxes][%d] putVmBoxesOK %+v", 200, o.Payload) -} -func (o *PutVMBoxesOK) GetPayload() *voip_models.VMBoxResponse { - return o.Payload -} - -func (o *PutVMBoxesOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.VMBoxResponse) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutVMBoxesUnauthorized creates a PutVMBoxesUnauthorized with default headers values -func NewPutVMBoxesUnauthorized() *PutVMBoxesUnauthorized { - return &PutVMBoxesUnauthorized{} -} - -/* PutVMBoxesUnauthorized describes a response with status code 401, with default header values. - -Access Unauthorized, invalid API-KEY was used -*/ -type PutVMBoxesUnauthorized struct { - Payload *voip_models.Error -} - -func (o *PutVMBoxesUnauthorized) Error() string { - return fmt.Sprintf("[PUT /vmboxes][%d] putVmBoxesUnauthorized %+v", 401, o.Payload) -} -func (o *PutVMBoxesUnauthorized) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutVMBoxesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutVMBoxesForbidden creates a PutVMBoxesForbidden with default headers values -func NewPutVMBoxesForbidden() *PutVMBoxesForbidden { - return &PutVMBoxesForbidden{} -} - -/* PutVMBoxesForbidden describes a response with status code 403, with default header values. - -Access forbidden, account lacks access -*/ -type PutVMBoxesForbidden struct { - Payload *voip_models.Error -} - -func (o *PutVMBoxesForbidden) Error() string { - return fmt.Sprintf("[PUT /vmboxes][%d] putVmBoxesForbidden %+v", 403, o.Payload) -} -func (o *PutVMBoxesForbidden) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutVMBoxesForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutVMBoxesNotFound creates a PutVMBoxesNotFound with default headers values -func NewPutVMBoxesNotFound() *PutVMBoxesNotFound { - return &PutVMBoxesNotFound{} -} - -/* PutVMBoxesNotFound describes a response with status code 404, with default header values. - -Resource was not found -*/ -type PutVMBoxesNotFound struct { - Payload *voip_models.Error -} - -func (o *PutVMBoxesNotFound) Error() string { - return fmt.Sprintf("[PUT /vmboxes][%d] putVmBoxesNotFound %+v", 404, o.Payload) -} -func (o *PutVMBoxesNotFound) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutVMBoxesNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutVMBoxesUnprocessableEntity creates a PutVMBoxesUnprocessableEntity with default headers values -func NewPutVMBoxesUnprocessableEntity() *PutVMBoxesUnprocessableEntity { - return &PutVMBoxesUnprocessableEntity{} -} - -/* PutVMBoxesUnprocessableEntity describes a response with status code 422, with default header values. - -Unprocessable Entity, likely a bad parameter -*/ -type PutVMBoxesUnprocessableEntity struct { - Payload *voip_models.Error -} - -func (o *PutVMBoxesUnprocessableEntity) Error() string { - return fmt.Sprintf("[PUT /vmboxes][%d] putVmBoxesUnprocessableEntity %+v", 422, o.Payload) -} -func (o *PutVMBoxesUnprocessableEntity) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutVMBoxesUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} - -// NewPutVMBoxesInternalServerError creates a PutVMBoxesInternalServerError with default headers values -func NewPutVMBoxesInternalServerError() *PutVMBoxesInternalServerError { - return &PutVMBoxesInternalServerError{} -} - -/* PutVMBoxesInternalServerError describes a response with status code 500, with default header values. - -Server Internal Error -*/ -type PutVMBoxesInternalServerError struct { - Payload *voip_models.Error -} - -func (o *PutVMBoxesInternalServerError) Error() string { - return fmt.Sprintf("[PUT /vmboxes][%d] putVmBoxesInternalServerError %+v", 500, o.Payload) -} -func (o *PutVMBoxesInternalServerError) GetPayload() *voip_models.Error { - return o.Payload -} - -func (o *PutVMBoxesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - - o.Payload = new(voip_models.Error) - - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { - return err - } - - return nil -} diff --git a/api/voip/voip_models/authority.go b/api/voip/voip_models/authority.go deleted file mode 100644 index 3e3d33f..0000000 --- a/api/voip/voip_models/authority.go +++ /dev/null @@ -1,141 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// Authority authority -// -// swagger:model Authority -type Authority struct { - - // Account - AccountID string `json:"AccountID,omitempty"` - - // Address Line 1 - AddressLine1 string `json:"AddressLine1,omitempty"` - - // Address Line 2 - AddressLine2 string `json:"AddressLine2,omitempty"` - - // Billing Telephone Number - BTN string `json:"BTN,omitempty"` - - // City - City string `json:"City,omitempty"` - - // Contact Name - ContactID string `json:"ContactID,omitempty"` - - // Country - Country string `json:"Country,omitempty"` - - // Created By User ID - CreatedByID string `json:"CreatedByID,omitempty"` - - // Created Date - CreatedDate string `json:"CreatedDate,omitempty"` - - // Authority Date - Date string `json:"Date,omitempty"` - - // Date Approved - DateApproved string `json:"DateApproved,omitempty"` - - // Telnexus Record Identifier - ID string `json:"ID,omitempty"` - - // Last Modified By User ID - LastModifiedByID string `json:"LastModifiedByID,omitempty"` - - // Last Modified Date - LastModifiedDate string `json:"LastModifiedDate,omitempty"` - - // Losing Carrier - LosingCarrier string `json:"LosingCarrier,omitempty"` - - // Authority Number - Name string `json:"Name,omitempty"` - - // Name Line 1 - NameLine1 string `json:"NameLine1,omitempty"` - - // Name Line 2 - NameLine2 string `json:"NameLine2,omitempty"` - - // Opportunity Name - OpportunityID string `json:"OpportunityID,omitempty"` - - // Order Number - OrderID string `json:"OrderID,omitempty"` - - // UUID Reference the master record that owns this item - ParentFK string `json:"ParentFK,omitempty"` - - // Zip Code - PostalCode string `json:"PostalCode,omitempty"` - - // Quote Name - QuoteID string `json:"QuoteID,omitempty"` - - // Source System identifier for this record, if any - Ref string `json:"Ref,omitempty"` - - // State - State string `json:"State,omitempty"` - - // Status - Status string `json:"Status,omitempty"` - - // ID of the Template for this object instance - TemplateID string `json:"TemplateID,omitempty"` - - // Tenant that owns this object instance - TenantID string `json:"TenantID,omitempty"` - - // Transfer Date - TransferDate string `json:"TransferDate,omitempty"` - - // Authority Type - Type string `json:"Type,omitempty"` -} - -// Validate validates this authority -func (m *Authority) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this authority based on context it is used -func (m *Authority) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *Authority) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *Authority) UnmarshalBinary(b []byte) error { - var res Authority - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/call_flow_action.go b/api/voip/voip_models/call_flow_action.go deleted file mode 100644 index 0187b73..0000000 --- a/api/voip/voip_models/call_flow_action.go +++ /dev/null @@ -1,92 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" - "github.com/go-openapi/validate" -) - -// CallFlowAction Call flows describe steps to take in order to process a phone call. They are trees of information related to a phone call such as "answer, play file, record file" etc. that are logically grouped together and ordered. -// -// swagger:model CallFlowAction -type CallFlowAction struct { - - // Children callflows - Children interface{} `json:"Children,omitempty"` - - // The data/arguments of the callflow module - Data interface{} `json:"Data,omitempty"` - - // Telnexus Record Identifier - ID string `json:"ID,omitempty"` - - // The name of the callflow module to execute at this node - // Max Length: 64 - // Min Length: 1 - Module string `json:"Module,omitempty"` -} - -// Validate validates this call flow action -func (m *CallFlowAction) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateModule(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *CallFlowAction) validateModule(formats strfmt.Registry) error { - if swag.IsZero(m.Module) { // not required - return nil - } - - if err := validate.MinLength("Module", "body", m.Module, 1); err != nil { - return err - } - - if err := validate.MaxLength("Module", "body", m.Module, 64); err != nil { - return err - } - - return nil -} - -// ContextValidate validates this call flow action based on context it is used -func (m *CallFlowAction) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *CallFlowAction) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *CallFlowAction) UnmarshalBinary(b []byte) error { - var res CallFlowAction - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/callflow.go b/api/voip/voip_models/callflow.go deleted file mode 100644 index 5d18cd5..0000000 --- a/api/voip/voip_models/callflow.go +++ /dev/null @@ -1,249 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" - "github.com/go-openapi/validate" -) - -// Callflow Call flows describe steps to take in order to process a phone call. They are trees of information related to a phone call such as "answer, play file, record file" etc. that are logically grouped together and ordered. -// -// swagger:model Callflow -type Callflow struct { - - // feature code - FeatureCode *CallflowFeatureCode `json:"FeatureCode,omitempty"` - - // Flags set by external applications - Flags []string `json:"Flags"` - - // A callflow node defines a module to execute, data to provide to that module, and zero or more children to branch to - Flow *CallFlowAction `json:"Flow,omitempty"` - - // Telnexus Record Identifier - ID string `json:"ID,omitempty"` - - // A list of static numbers that the callflow should execute for - // Unique: true - Numbers []string `json:"Numbers"` - - // A list of regular expressions that the callflow should execute for, with optional capture groups - Patterns []string `json:"Patterns"` -} - -// Validate validates this callflow -func (m *Callflow) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateFeatureCode(formats); err != nil { - res = append(res, err) - } - - if err := m.validateFlow(formats); err != nil { - res = append(res, err) - } - - if err := m.validateNumbers(formats); err != nil { - res = append(res, err) - } - - if err := m.validatePatterns(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *Callflow) validateFeatureCode(formats strfmt.Registry) error { - if swag.IsZero(m.FeatureCode) { // not required - return nil - } - - if m.FeatureCode != nil { - if err := m.FeatureCode.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("FeatureCode") - } - return err - } - } - - return nil -} - -func (m *Callflow) validateFlow(formats strfmt.Registry) error { - if swag.IsZero(m.Flow) { // not required - return nil - } - - if m.Flow != nil { - if err := m.Flow.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Flow") - } - return err - } - } - - return nil -} - -func (m *Callflow) validateNumbers(formats strfmt.Registry) error { - if swag.IsZero(m.Numbers) { // not required - return nil - } - - if err := validate.UniqueItems("Numbers", "body", m.Numbers); err != nil { - return err - } - - for i := 0; i < len(m.Numbers); i++ { - - if err := validate.MinLength("Numbers"+"."+strconv.Itoa(i), "body", m.Numbers[i], 1); err != nil { - return err - } - - if err := validate.MaxLength("Numbers"+"."+strconv.Itoa(i), "body", m.Numbers[i], 36); err != nil { - return err - } - - } - - return nil -} - -func (m *Callflow) validatePatterns(formats strfmt.Registry) error { - if swag.IsZero(m.Patterns) { // not required - return nil - } - - for i := 0; i < len(m.Patterns); i++ { - - if err := validate.MinLength("Patterns"+"."+strconv.Itoa(i), "body", m.Patterns[i], 1); err != nil { - return err - } - - } - - return nil -} - -// ContextValidate validate this callflow based on the context it is used -func (m *Callflow) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateFeatureCode(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateFlow(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *Callflow) contextValidateFeatureCode(ctx context.Context, formats strfmt.Registry) error { - - if m.FeatureCode != nil { - if err := m.FeatureCode.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("FeatureCode") - } - return err - } - } - - return nil -} - -func (m *Callflow) contextValidateFlow(ctx context.Context, formats strfmt.Registry) error { - - if m.Flow != nil { - if err := m.Flow.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Flow") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *Callflow) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *Callflow) UnmarshalBinary(b []byte) error { - var res Callflow - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} - -// CallflowFeatureCode When the callflow is used as a featurecode this object tracks the intended match of the pattern and name of the feature -// -// swagger:model CallflowFeatureCode -type CallflowFeatureCode struct { - - // name - Name string `json:"name,omitempty"` - - // number - Number string `json:"number,omitempty"` -} - -// Validate validates this callflow feature code -func (m *CallflowFeatureCode) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this callflow feature code based on context it is used -func (m *CallflowFeatureCode) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *CallflowFeatureCode) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *CallflowFeatureCode) UnmarshalBinary(b []byte) error { - var res CallflowFeatureCode - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/endpoint.go b/api/voip/voip_models/endpoint.go deleted file mode 100644 index fcb2d5c..0000000 --- a/api/voip/voip_models/endpoint.go +++ /dev/null @@ -1,141 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// Endpoint endpoint -// -// swagger:model Endpoint -type Endpoint struct { - - // Asset ID - AssetID string `json:"AssetID,omitempty"` - - // Call Forwarding Record ID - CallForwardID string `json:"CallForwardID,omitempty"` - - // Call Restriction Record ID - CallRestrictionID string `json:"CallRestrictionID,omitempty"` - - // Endpoint CNAM Override - CallerIDOverride string `json:"CallerIdOverride,omitempty"` - - // Telnexus Contact ID - ContactID string `json:"ContactID,omitempty"` - - // Device Type - DeviceType string `json:"DeviceType,omitempty"` - - // Dial Plan - DialPlan string `json:"DialPlan,omitempty"` - - // Do Not Disturb - DoNotDisturb string `json:"DoNotDisturb,omitempty"` - - // Do Not Disturb Enabled? - DoNotDisturbEnabled bool `json:"DoNotDisturbEnabled,omitempty"` - - // Endpoint Enabled? - Enabled bool `json:"Enabled,omitempty"` - - // Endpoint Name - EndpointName string `json:"EndpointName,omitempty"` - - // Exclude From Queues? - ExcludeFromQueues bool `json:"ExcludeFromQueues,omitempty"` - - // Telnexus Record ID - ID string `json:"ID,omitempty"` - - // Kazoo Endpoint ID - KazooEndpointID string `json:"KazooEndpointID,omitempty"` - - // Endpoint Language Override - Language string `json:"Language,omitempty"` - - // MAC Address - MacAddress string `json:"MacAddress,omitempty"` - - // Music On Hold Override - MusicOnHold string `json:"MusicOnHold,omitempty"` - - // Kazoo MOH Media ID - MusicOnHoldMediaID string `json:"MusicOnHoldMediaID,omitempty"` - - // MWI Unassociated Updates? - MwiUnassociatedUpdates bool `json:"MwiUnassociatedUpdates,omitempty"` - - // Kazoo Owner ID - OwnerID string `json:"OwnerID,omitempty"` - - // Telnexus PBX ID - PbxID string `json:"PbxID,omitempty"` - - // Presence ID - PresenceID string `json:"PresenceID,omitempty"` - - // Provisioning Record ID - ProvisionID string `json:"ProvisionID,omitempty"` - - // Register Overwrite Notify? - RegisterOverwriteNotify bool `json:"RegisterOverwriteNotify,omitempty"` - - // Endpoint Ringtones - Ringtones string `json:"Ringtones,omitempty"` - - // Ringtones External - RingtonesExternal string `json:"RingtonesExternal,omitempty"` - - // Ringtones Internal - RingtonesInternal string `json:"RingtonesInternal,omitempty"` - - // SIP Information Record ID - SipID string `json:"SipID,omitempty"` - - // Suppress Unregister Notifications? - SuppressUnregisterNotifications bool `json:"SuppressUnregisterNotifications,omitempty"` - - // Endpoint Timezone Override - Timezone string `json:"Timezone,omitempty"` -} - -// Validate validates this endpoint -func (m *Endpoint) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this endpoint based on context it is used -func (m *Endpoint) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *Endpoint) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *Endpoint) UnmarshalBinary(b []byte) error { - var res Endpoint - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/endpoint_request.go b/api/voip/voip_models/endpoint_request.go deleted file mode 100644 index 1ec4b74..0000000 --- a/api/voip/voip_models/endpoint_request.go +++ /dev/null @@ -1,116 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// EndpointRequest An array of Endpoint objects sent to be processed in a request -// -// swagger:model EndpointRequest -type EndpointRequest struct { - - // data - Data []*Endpoint `json:"Data"` -} - -// Validate validates this endpoint request -func (m *EndpointRequest) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *EndpointRequest) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this endpoint request based on the context it is used -func (m *EndpointRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *EndpointRequest) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *EndpointRequest) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *EndpointRequest) UnmarshalBinary(b []byte) error { - var res EndpointRequest - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/error.go b/api/voip/voip_models/error.go deleted file mode 100644 index 3cd4773..0000000 --- a/api/voip/voip_models/error.go +++ /dev/null @@ -1,60 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// Error error -// -// swagger:model Error -type Error struct { - - // code - Code int32 `json:"Code,omitempty"` - - // fields - Fields string `json:"Fields,omitempty"` - - // message - Message string `json:"Message,omitempty"` -} - -// Validate validates this error -func (m *Error) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this error based on context it is used -func (m *Error) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *Error) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *Error) UnmarshalBinary(b []byte) error { - var res Error - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/pbx.go b/api/voip/voip_models/pbx.go deleted file mode 100644 index 116f34c..0000000 --- a/api/voip/voip_models/pbx.go +++ /dev/null @@ -1,120 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// Pbx pbx -// -// swagger:model Pbx -type Pbx struct { - - // Telnexus Account ID - AccountID string `json:"AccountID,omitempty"` - - // Backend ID - BackendID string `json:"BackendID,omitempty"` - - // Billing Contact ID - BillingContact string `json:"BillingContact,omitempty"` - - // Kazoo Billing ID - BillingID string `json:"BillingID,omitempty"` - - // Kazoo Billing Mode - BillingMode string `json:"BillingMode,omitempty"` - - // Call Restriction Record ID - CallRestrictionID string `json:"CallRestrictionID,omitempty"` - - // Caller ID Emergency Name - CallerIDEmergencyName string `json:"CallerIdEmergencyName,omitempty"` - - // Caller ID Emergency Number - CallerIDEmergencyNumber string `json:"CallerIdEmergencyNumber,omitempty"` - - // Caller ID External Name - CallerIDExternalName string `json:"CallerIdExternalName,omitempty"` - - // Caller ID External Number - CallerIDExternalNumber string `json:"CallerIdExternalNumber,omitempty"` - - // Date Created - Created string `json:"Created,omitempty"` - - // User Enabled? - Enabled bool `json:"Enabled,omitempty"` - - // Telnexus ID - ID string `json:"ID,omitempty"` - - // Is Account a Reseller? - IsReseller bool `json:"IsReseller,omitempty"` - - // Kazoo Account Name - KazooAccountName string `json:"KazooAccountName,omitempty"` - - // Kazoo PBX ID - KazooID string `json:"KazooID,omitempty"` - - // Language - Language string `json:"Language,omitempty"` - - // Default Music On Hold - MusicOnHold string `json:"MusicOnHold,omitempty"` - - // PBX Name - Name string `json:"Name,omitempty"` - - // PBX Realm - Realm string `json:"Realm,omitempty"` - - // Reseller ID - ResellerID string `json:"ResellerID,omitempty"` - - // Technical Contact - TechnicalContactID string `json:"TechnicalContactID,omitempty"` - - // PBX Timezone - Timezone string `json:"Timezone,omitempty"` -} - -// Validate validates this pbx -func (m *Pbx) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this pbx based on context it is used -func (m *Pbx) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *Pbx) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *Pbx) UnmarshalBinary(b []byte) error { - var res Pbx - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/pbx_request.go b/api/voip/voip_models/pbx_request.go deleted file mode 100644 index d3c0e07..0000000 --- a/api/voip/voip_models/pbx_request.go +++ /dev/null @@ -1,116 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// PbxRequest pbx request -// -// swagger:model PbxRequest -type PbxRequest struct { - - // data - Data []*Pbx `json:"Data"` -} - -// Validate validates this pbx request -func (m *PbxRequest) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *PbxRequest) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this pbx request based on the context it is used -func (m *PbxRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *PbxRequest) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *PbxRequest) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *PbxRequest) UnmarshalBinary(b []byte) error { - var res PbxRequest - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/pbx_user.go b/api/voip/voip_models/pbx_user.go deleted file mode 100644 index 6fe0a90..0000000 --- a/api/voip/voip_models/pbx_user.go +++ /dev/null @@ -1,108 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// PbxUser pbx user -// -// swagger:model PbxUser -type PbxUser struct { - - // Call Restriction Record ID - CallRestrictionID string `json:"CallRestrictionID,omitempty"` - - // CNAM Override - CallerID string `json:"CallerID,omitempty"` - - // Telnexus Contact ID - ContactID string `json:"ContactID,omitempty"` - - // Email Address - Email string `json:"Email,omitempty"` - - // Enabled? - Enabled bool `json:"Enabled,omitempty"` - - // Fax To Email Enabled? - FaxToEmailEnabled bool `json:"FaxToEmailEnabled,omitempty"` - - // First Name - FirstName string `json:"FirstName,omitempty"` - - // Telnexus ID - ID string `json:"ID,omitempty"` - - // Language - Language string `json:"Language,omitempty"` - - // Last Name - LastName string `json:"LastName,omitempty"` - - // Telnexus PBX ID - PbxID string `json:"PbxID,omitempty"` - - // Privilege Level - PrivLevel string `json:"PrivLevel,omitempty"` - - // RecordCall? - RecordCall bool `json:"RecordCall,omitempty"` - - // Require Passoword Update? - RequirePasswordUpdate bool `json:"RequirePasswordUpdate,omitempty"` - - // Timezone - Timezone string `json:"Timezone,omitempty"` - - // Kazoo User ID - UserID string `json:"UserID,omitempty"` - - // Kazoo Username - UserName string `json:"UserName,omitempty"` - - // Verified? - Verified bool `json:"Verified,omitempty"` - - // Voice Mail to Email Enabled? - VMToEmailEnabled bool `json:"VmToEmailEnabled,omitempty"` -} - -// Validate validates this pbx user -func (m *PbxUser) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this pbx user based on context it is used -func (m *PbxUser) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *PbxUser) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *PbxUser) UnmarshalBinary(b []byte) error { - var res PbxUser - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/pbx_user_request.go b/api/voip/voip_models/pbx_user_request.go deleted file mode 100644 index 06c7599..0000000 --- a/api/voip/voip_models/pbx_user_request.go +++ /dev/null @@ -1,116 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// PbxUserRequest pbx user request -// -// swagger:model PbxUserRequest -type PbxUserRequest struct { - - // data - Data []*PbxUser `json:"Data"` -} - -// Validate validates this pbx user request -func (m *PbxUserRequest) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *PbxUserRequest) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this pbx user request based on the context it is used -func (m *PbxUserRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *PbxUserRequest) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *PbxUserRequest) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *PbxUserRequest) UnmarshalBinary(b []byte) error { - var res PbxUserRequest - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/phone_number.go b/api/voip/voip_models/phone_number.go deleted file mode 100644 index adf7780..0000000 --- a/api/voip/voip_models/phone_number.go +++ /dev/null @@ -1,132 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// PhoneNumber phone number -// -// swagger:model PhoneNumber -type PhoneNumber struct { - - // Telnexus Account ID - AccountID string `json:"AccountID,omitempty"` - - // AuthorityID - AuthorityID string `json:"AuthorityID,omitempty"` - - // Telnexus Company ID - CompanyID string `json:"CompanyID,omitempty"` - - // Telnexus Contact ID - ContactID string `json:"ContactID,omitempty"` - - // Telnexus Contract ID - ContractID string `json:"ContractID,omitempty"` - - // Description - Description string `json:"Description,omitempty"` - - // Extension - Extension string `json:"Extension,omitempty"` - - // Fax Line? - FaxLine bool `json:"FaxLine,omitempty"` - - // Telnexus Record ID - ID string `json:"ID,omitempty"` - - // Indicator - Indicator string `json:"Indicator,omitempty"` - - // Local Service - LocalService bool `json:"LocalService,omitempty"` - - // Local Toll - LocalToll bool `json:"LocalToll,omitempty"` - - // Long Distance - LongDistance bool `json:"LongDistance,omitempty"` - - // Losing Carrier - LosingCarrier string `json:"LosingCarrier,omitempty"` - - // Telnexus Opportunity ID - OpportunityID string `json:"OpportunityID,omitempty"` - - // Telnexus Order ID - OrderID string `json:"OrderID,omitempty"` - - // Phone Number - PhoneNumber string `json:"PhoneNumber,omitempty"` - - // Is this number to ported out? - PortOut bool `json:"PortOut,omitempty"` - - // Telnexus Product ID - ProductID string `json:"ProductID,omitempty"` - - // Telnexus Quote ID - QuoteID string `json:"QuoteID,omitempty"` - - // Rate Center - Ratecenter string `json:"Ratecenter,omitempty"` - - // Is this a safety number? - Safety bool `json:"Safety,omitempty"` - - // Number Status - Status string `json:"Status,omitempty"` - - // Subscription ID - SubscriptionID string `json:"SubscriptionID,omitempty"` - - // Tollfree - Tollfree string `json:"Tollfree,omitempty"` - - // Number Type - Type string `json:"Type,omitempty"` - - // Wholesale Vendor ID - WholesalerID string `json:"WholesalerID,omitempty"` -} - -// Validate validates this phone number -func (m *PhoneNumber) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this phone number based on context it is used -func (m *PhoneNumber) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *PhoneNumber) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *PhoneNumber) UnmarshalBinary(b []byte) error { - var res PhoneNumber - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/phone_number_request.go b/api/voip/voip_models/phone_number_request.go deleted file mode 100644 index b514c2f..0000000 --- a/api/voip/voip_models/phone_number_request.go +++ /dev/null @@ -1,116 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// PhoneNumberRequest phone number request -// -// swagger:model PhoneNumberRequest -type PhoneNumberRequest struct { - - // data - Data []*PhoneNumber `json:"Data"` -} - -// Validate validates this phone number request -func (m *PhoneNumberRequest) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *PhoneNumberRequest) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this phone number request based on the context it is used -func (m *PhoneNumberRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *PhoneNumberRequest) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *PhoneNumberRequest) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *PhoneNumberRequest) UnmarshalBinary(b []byte) error { - var res PhoneNumberRequest - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/phone_number_response.go b/api/voip/voip_models/phone_number_response.go deleted file mode 100644 index 267ea7c..0000000 --- a/api/voip/voip_models/phone_number_response.go +++ /dev/null @@ -1,158 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// PhoneNumberResponse An array of Phone Number objects -// -// swagger:model PhoneNumberResponse -type PhoneNumberResponse struct { - - // data - Data []*PhoneNumber `json:"Data"` - - // meta - Meta *ResponseMeta `json:"Meta,omitempty"` -} - -// Validate validates this phone number response -func (m *PhoneNumberResponse) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if err := m.validateMeta(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *PhoneNumberResponse) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -func (m *PhoneNumberResponse) validateMeta(formats strfmt.Registry) error { - if swag.IsZero(m.Meta) { // not required - return nil - } - - if m.Meta != nil { - if err := m.Meta.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") - } - return err - } - } - - return nil -} - -// ContextValidate validate this phone number response based on the context it is used -func (m *PhoneNumberResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateMeta(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *PhoneNumberResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -func (m *PhoneNumberResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { - - if m.Meta != nil { - if err := m.Meta.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *PhoneNumberResponse) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *PhoneNumberResponse) UnmarshalBinary(b []byte) error { - var res PhoneNumberResponse - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/queue.go b/api/voip/voip_models/queue.go deleted file mode 100644 index a912d70..0000000 --- a/api/voip/voip_models/queue.go +++ /dev/null @@ -1,90 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// Queue queue -// -// swagger:model Queue -type Queue struct { - - // Pre-defined wait period applied after an agent handles a customer call (in seconds) - AgentWrapupTime int64 `json:"AgentWrapupTime,omitempty"` - - // If set to true and a recipient rejects a call, they will be forced to away state - ForceAwayOnReject bool `json:"ForceAwayOnReject,omitempty"` - - // Media ID (or appropriate media URI) of media to play while caller is on hold. - HoldTreatment string `json:"HoldTreatment,omitempty"` - - // Telnexus Record Identifier - ID string `json:"ID,omitempty"` - - // A friendly name for the queue - Name string `json:"Name,omitempty"` - - // The queue router used for routing and delivering calls to recipients - QueueRouter *string `json:"QueueRouter,omitempty"` - - // The type of queue - QueueType string `json:"QueueType,omitempty"` - - // Amount of time in seconds that qubicle will wait while ringing for the agent to successfully answer a call. - RingTimeout int64 `json:"RingTimeout,omitempty"` - - // The time between delivery ticks in milliseconds - TickTime int64 `json:"TickTime,omitempty"` - - // The maximum amount of time in seconds that a call will wait in queue. - Timeout int64 `json:"Timeout,omitempty"` - - // If set to a non-zero value the queue will immediately time out any call entering the queue over the size - TimeoutIfSizeExceeds int64 `json:"TimeoutIfSizeExceeds,omitempty"` - - // If set to true and a call enters the queue while it has no logged in agents, the call will time out - TimeoutImmediatelyIfEmpty bool `json:"TimeoutImmediatelyIfEmpty,omitempty"` - - // The ID of a queue that the call will be sent to in the event of a timeout - TimoutRedirect string `json:"TimoutRedirect,omitempty"` -} - -// Validate validates this queue -func (m *Queue) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this queue based on context it is used -func (m *Queue) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *Queue) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *Queue) UnmarshalBinary(b []byte) error { - var res Queue - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/queue_request.go b/api/voip/voip_models/queue_request.go deleted file mode 100644 index b347fa6..0000000 --- a/api/voip/voip_models/queue_request.go +++ /dev/null @@ -1,116 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// QueueRequest queue request -// -// swagger:model QueueRequest -type QueueRequest struct { - - // data - Data []*Queue `json:"Data"` -} - -// Validate validates this queue request -func (m *QueueRequest) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *QueueRequest) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this queue request based on the context it is used -func (m *QueueRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *QueueRequest) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *QueueRequest) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *QueueRequest) UnmarshalBinary(b []byte) error { - var res QueueRequest - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/recipient.go b/api/voip/voip_models/recipient.go deleted file mode 100644 index 5bc3593..0000000 --- a/api/voip/voip_models/recipient.go +++ /dev/null @@ -1,134 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// Recipient recipient -// -// swagger:model Recipient -type Recipient struct { - - // availability state - AvailabilityState string `json:"AvailabilityState,omitempty"` - - // available - Available string `json:"Available,omitempty"` - - // handling call - HandlingCall string `json:"HandlingCall,omitempty"` - - // Telnexus Record Identifier - ID string `json:"ID,omitempty"` - - // node - Node string `json:"Node,omitempty"` - - // offered call - OfferedCall string `json:"OfferedCall,omitempty"` - - // queue availability - QueueAvailability string `json:"QueueAvailability,omitempty"` - - // stats - Stats *RecipientStats `json:"Stats,omitempty"` - - // wiretap mode - WiretapMode string `json:"WiretapMode,omitempty"` - - // wiretapping recipient - WiretappingRecipient string `json:"WiretappingRecipient,omitempty"` - - // wrapup time seconds - WrapupTimeSeconds string `json:"WrapupTimeSeconds,omitempty"` -} - -// Validate validates this recipient -func (m *Recipient) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateStats(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *Recipient) validateStats(formats strfmt.Registry) error { - if swag.IsZero(m.Stats) { // not required - return nil - } - - if m.Stats != nil { - if err := m.Stats.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Stats") - } - return err - } - } - - return nil -} - -// ContextValidate validate this recipient based on the context it is used -func (m *Recipient) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateStats(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *Recipient) contextValidateStats(ctx context.Context, formats strfmt.Registry) error { - - if m.Stats != nil { - if err := m.Stats.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Stats") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *Recipient) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *Recipient) UnmarshalBinary(b []byte) error { - var res Recipient - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/recipient_request.go b/api/voip/voip_models/recipient_request.go deleted file mode 100644 index b7093a7..0000000 --- a/api/voip/voip_models/recipient_request.go +++ /dev/null @@ -1,116 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// RecipientRequest recipient request -// -// swagger:model RecipientRequest -type RecipientRequest struct { - - // data - Data []*Recipient `json:"Data"` -} - -// Validate validates this recipient request -func (m *RecipientRequest) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *RecipientRequest) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this recipient request based on the context it is used -func (m *RecipientRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *RecipientRequest) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *RecipientRequest) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *RecipientRequest) UnmarshalBinary(b []byte) error { - var res RecipientRequest - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/recipient_response.go b/api/voip/voip_models/recipient_response.go deleted file mode 100644 index cd10c70..0000000 --- a/api/voip/voip_models/recipient_response.go +++ /dev/null @@ -1,158 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// RecipientResponse An array of Recipient objects -// -// swagger:model RecipientResponse -type RecipientResponse struct { - - // data - Data []*Recipient `json:"Data"` - - // meta - Meta *ResponseMeta `json:"Meta,omitempty"` -} - -// Validate validates this recipient response -func (m *RecipientResponse) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if err := m.validateMeta(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *RecipientResponse) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -func (m *RecipientResponse) validateMeta(formats strfmt.Registry) error { - if swag.IsZero(m.Meta) { // not required - return nil - } - - if m.Meta != nil { - if err := m.Meta.Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") - } - return err - } - } - - return nil -} - -// ContextValidate validate this recipient response based on the context it is used -func (m *RecipientResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateMeta(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *RecipientResponse) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -func (m *RecipientResponse) contextValidateMeta(ctx context.Context, formats strfmt.Registry) error { - - if m.Meta != nil { - if err := m.Meta.ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Meta") - } - return err - } - } - - return nil -} - -// MarshalBinary interface implementation -func (m *RecipientResponse) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *RecipientResponse) UnmarshalBinary(b []byte) error { - var res RecipientResponse - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/recipient_stats.go b/api/voip/voip_models/recipient_stats.go deleted file mode 100644 index 03693d3..0000000 --- a/api/voip/voip_models/recipient_stats.go +++ /dev/null @@ -1,72 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// RecipientStats recipient stats -// -// swagger:model RecipientStats -type RecipientStats struct { - - // avg call time - AvgCallTime float64 `json:"AvgCallTime,omitempty"` - - // Telnexus Record Identifier - ID string `json:"ID,omitempty"` - - // last action time - LastActionTime float64 `json:"LastActionTime,omitempty"` - - // last handled time - LastHandledTime float64 `json:"LastHandledTime,omitempty"` - - // login time - LoginTime int64 `json:"LoginTime,omitempty"` - - // missed calls - MissedCalls int64 `json:"MissedCalls,omitempty"` - - // total calls - TotalCalls int64 `json:"TotalCalls,omitempty"` -} - -// Validate validates this recipient stats -func (m *RecipientStats) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this recipient stats based on context it is used -func (m *RecipientStats) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *RecipientStats) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *RecipientStats) UnmarshalBinary(b []byte) error { - var res RecipientStats - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/response_meta.go b/api/voip/voip_models/response_meta.go deleted file mode 100644 index 38821ee..0000000 --- a/api/voip/voip_models/response_meta.go +++ /dev/null @@ -1,84 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// ResponseMeta response meta -// -// swagger:model ResponseMeta -type ResponseMeta struct { - - // Microservice Contact Info - Contact string `json:"Contact,omitempty"` - - // Copyright Info - Copyright string `json:"Copyright,omitempty"` - - // License Information and Restrictions - License string `json:"License,omitempty"` - - // Request IP Address - RequestIP string `json:"RequestIP,omitempty"` - - // Request Type - RequestType string `json:"RequestType,omitempty"` - - // Request URL - RequestURL string `json:"RequestURL,omitempty"` - - // Data Server Info - ServerInfo string `json:"ServerInfo,omitempty"` - - // Data Server Response Time (ms) - ServerResponseTime string `json:"ServerResponseTime,omitempty"` - - // Backend Server Timestamp - ServerTimestamp string `json:"ServerTimestamp,omitempty"` - - // Telnexus Account Number used for recording transactions - TelnexusAccount string `json:"TelnexusAccount,omitempty"` - - // Operation ID - OperationID string `json:"operationId,omitempty"` -} - -// Validate validates this response meta -func (m *ResponseMeta) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this response meta based on context it is used -func (m *ResponseMeta) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *ResponseMeta) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *ResponseMeta) UnmarshalBinary(b []byte) error { - var res ResponseMeta - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/vm_box.go b/api/voip/voip_models/vm_box.go deleted file mode 100644 index 87daa2f..0000000 --- a/api/voip/voip_models/vm_box.go +++ /dev/null @@ -1,93 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// VMBox Vm box -// -// swagger:model VmBox -type VMBox struct { - - // Check if VM owner is owner of endpoint - CheckIfOwner bool `json:"CheckIfOwner,omitempty"` - - // Delete VM after notification - DeleteAfterNotify bool `json:"DeleteAfterNotify,omitempty"` - - // Telnexus Record ID - ID string `json:"ID,omitempty"` - - // Is this VM Box setup? - IsSetup bool `json:"IsSetup,omitempty"` - - // Kazoo Mailbox Id - KazooID string `json:"KazooID,omitempty"` - - // Kazoo User Id - KazooOwnerID string `json:"KazooOwnerID,omitempty"` - - // Kazoo Mailbox Number - MailboxNumber string `json:"MailboxNumber,omitempty"` - - // Mailbox Name - Name string `json:"Name,omitempty"` - - // Not Configurable? - NotConfigurable bool `json:"NotConfigurable,omitempty"` - - // Telnexus PBX ID - PbxID string `json:"PbxID,omitempty"` - - // Require PIN? - RequirePIN bool `json:"RequirePIN,omitempty"` - - // Save after notify? - SaveAfterNotify bool `json:"SaveAfterNotify,omitempty"` - - // Skip Greeting? - SkipGreeting bool `json:"SkipGreeting,omitempty"` - - // Skip Instructions? - SkipInstructions bool `json:"SkipInstructions,omitempty"` -} - -// Validate validates this Vm box -func (m *VMBox) Validate(formats strfmt.Registry) error { - return nil -} - -// ContextValidate validates this Vm box based on context it is used -func (m *VMBox) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - return nil -} - -// MarshalBinary interface implementation -func (m *VMBox) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *VMBox) UnmarshalBinary(b []byte) error { - var res VMBox - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/voip/voip_models/vm_box_request.go b/api/voip/voip_models/vm_box_request.go deleted file mode 100644 index bb85f4a..0000000 --- a/api/voip/voip_models/vm_box_request.go +++ /dev/null @@ -1,116 +0,0 @@ -// Code generated by go-swagger; DO NOT EDIT. - -// (c) 2012-2020 by Telnexus LLC -// All rights reserved worldwide. -// Proprietary product; unlicensed use is not allowed - -package voip_models - -// This file was generated by the swagger tool. -// Editing this file might prove futile when you re-run the swagger generate command - -import ( - "context" - "strconv" - - "github.com/go-openapi/errors" - "github.com/go-openapi/strfmt" - "github.com/go-openapi/swag" -) - -// VMBoxRequest Vm box request -// -// swagger:model VmBoxRequest -type VMBoxRequest struct { - - // data - Data []*VMBox `json:"Data"` -} - -// Validate validates this Vm box request -func (m *VMBoxRequest) Validate(formats strfmt.Registry) error { - var res []error - - if err := m.validateData(formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *VMBoxRequest) validateData(formats strfmt.Registry) error { - if swag.IsZero(m.Data) { // not required - return nil - } - - for i := 0; i < len(m.Data); i++ { - if swag.IsZero(m.Data[i]) { // not required - continue - } - - if m.Data[i] != nil { - if err := m.Data[i].Validate(formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// ContextValidate validate this Vm box request based on the context it is used -func (m *VMBoxRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error { - var res []error - - if err := m.contextValidateData(ctx, formats); err != nil { - res = append(res, err) - } - - if len(res) > 0 { - return errors.CompositeValidationError(res...) - } - return nil -} - -func (m *VMBoxRequest) contextValidateData(ctx context.Context, formats strfmt.Registry) error { - - for i := 0; i < len(m.Data); i++ { - - if m.Data[i] != nil { - if err := m.Data[i].ContextValidate(ctx, formats); err != nil { - if ve, ok := err.(*errors.Validation); ok { - return ve.ValidateName("Data" + "." + strconv.Itoa(i)) - } - return err - } - } - - } - - return nil -} - -// MarshalBinary interface implementation -func (m *VMBoxRequest) MarshalBinary() ([]byte, error) { - if m == nil { - return nil, nil - } - return swag.WriteJSON(m) -} - -// UnmarshalBinary interface implementation -func (m *VMBoxRequest) UnmarshalBinary(b []byte) error { - var res VMBoxRequest - if err := swag.ReadJSON(b, &res); err != nil { - return err - } - *m = res - return nil -} diff --git a/api/workflow/workflow_client/app_log/app_log_client.go b/api/workflow/workflow_client/app_log/app_log_client.go index 69523bf..734a8da 100644 --- a/api/workflow/workflow_client/app_log/app_log_client.go +++ b/api/workflow/workflow_client/app_log/app_log_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/app_log/post_app_logs_parameters.go b/api/workflow/workflow_client/app_log/post_app_logs_parameters.go index 5efbe13..2191033 100644 --- a/api/workflow/workflow_client/app_log/post_app_logs_parameters.go +++ b/api/workflow/workflow_client/app_log/post_app_logs_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/app_log/post_app_logs_responses.go b/api/workflow/workflow_client/app_log/post_app_logs_responses.go index 9eb6932..f74adbb 100644 --- a/api/workflow/workflow_client/app_log/post_app_logs_responses.go +++ b/api/workflow/workflow_client/app_log/post_app_logs_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/cors/app_log_options_parameters.go b/api/workflow/workflow_client/cors/app_log_options_parameters.go index ea6c245..f9faf4a 100644 --- a/api/workflow/workflow_client/cors/app_log_options_parameters.go +++ b/api/workflow/workflow_client/cors/app_log_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/cors/app_log_options_responses.go b/api/workflow/workflow_client/cors/app_log_options_responses.go index 6defabf..4bdae8f 100644 --- a/api/workflow/workflow_client/cors/app_log_options_responses.go +++ b/api/workflow/workflow_client/cors/app_log_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/cors/cors_client.go b/api/workflow/workflow_client/cors/cors_client.go index 71a8d51..4f005d1 100644 --- a/api/workflow/workflow_client/cors/cors_client.go +++ b/api/workflow/workflow_client/cors/cors_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/cors/email_message_options_parameters.go b/api/workflow/workflow_client/cors/email_message_options_parameters.go index 63d5584..d4455a8 100644 --- a/api/workflow/workflow_client/cors/email_message_options_parameters.go +++ b/api/workflow/workflow_client/cors/email_message_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/cors/email_message_options_responses.go b/api/workflow/workflow_client/cors/email_message_options_responses.go index b94bc3a..d8119c9 100644 --- a/api/workflow/workflow_client/cors/email_message_options_responses.go +++ b/api/workflow/workflow_client/cors/email_message_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/cors/outgoing_email_message_options_parameters.go b/api/workflow/workflow_client/cors/outgoing_email_message_options_parameters.go index 8b31ea7..630a9ee 100644 --- a/api/workflow/workflow_client/cors/outgoing_email_message_options_parameters.go +++ b/api/workflow/workflow_client/cors/outgoing_email_message_options_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/cors/outgoing_email_message_options_responses.go b/api/workflow/workflow_client/cors/outgoing_email_message_options_responses.go index 8201f46..458dab7 100644 --- a/api/workflow/workflow_client/cors/outgoing_email_message_options_responses.go +++ b/api/workflow/workflow_client/cors/outgoing_email_message_options_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/email_message/email_message_client.go b/api/workflow/workflow_client/email_message/email_message_client.go index c5fa7c2..cb28ac5 100644 --- a/api/workflow/workflow_client/email_message/email_message_client.go +++ b/api/workflow/workflow_client/email_message/email_message_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/email_message/get_email_messages_parameters.go b/api/workflow/workflow_client/email_message/get_email_messages_parameters.go index b5fbdd7..7957fc7 100644 --- a/api/workflow/workflow_client/email_message/get_email_messages_parameters.go +++ b/api/workflow/workflow_client/email_message/get_email_messages_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/email_message/get_email_messages_responses.go b/api/workflow/workflow_client/email_message/get_email_messages_responses.go index fc4f96d..05231da 100644 --- a/api/workflow/workflow_client/email_message/get_email_messages_responses.go +++ b/api/workflow/workflow_client/email_message/get_email_messages_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/outgoing_email_message/outgoing_email_message_client.go b/api/workflow/workflow_client/outgoing_email_message/outgoing_email_message_client.go index c5e1df6..edd43fa 100644 --- a/api/workflow/workflow_client/outgoing_email_message/outgoing_email_message_client.go +++ b/api/workflow/workflow_client/outgoing_email_message/outgoing_email_message_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/outgoing_email_message/post_outgoing_email_messages_parameters.go b/api/workflow/workflow_client/outgoing_email_message/post_outgoing_email_messages_parameters.go index 09a3891..812f592 100644 --- a/api/workflow/workflow_client/outgoing_email_message/post_outgoing_email_messages_parameters.go +++ b/api/workflow/workflow_client/outgoing_email_message/post_outgoing_email_messages_parameters.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/outgoing_email_message/post_outgoing_email_messages_responses.go b/api/workflow/workflow_client/outgoing_email_message/post_outgoing_email_messages_responses.go index a9f99e9..398a96d 100644 --- a/api/workflow/workflow_client/outgoing_email_message/post_outgoing_email_messages_responses.go +++ b/api/workflow/workflow_client/outgoing_email_message/post_outgoing_email_messages_responses.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_client/workflow_client.go b/api/workflow/workflow_client/workflow_client.go index 46a5c27..788708d 100644 --- a/api/workflow/workflow_client/workflow_client.go +++ b/api/workflow/workflow_client/workflow_client.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -26,7 +26,7 @@ var Default = NewHTTPClient(nil) const ( // DefaultHost is the default Host // found in Meta (info) section of spec file - DefaultHost string = "workflow.infra.tnxs.net:8080" + DefaultHost string = "workflow.vernonkeenan.com:8080" // DefaultBasePath is the default BasePath // found in Meta (info) section of spec file DefaultBasePath string = "/v1" diff --git a/api/workflow/workflow_models/app_log.go b/api/workflow/workflow_models/app_log.go index 4661c7e..3be64e9 100644 --- a/api/workflow/workflow_models/app_log.go +++ b/api/workflow/workflow_models/app_log.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_models/app_log_request.go b/api/workflow/workflow_models/app_log_request.go index c283d67..cb65f1a 100644 --- a/api/workflow/workflow_models/app_log_request.go +++ b/api/workflow/workflow_models/app_log_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -18,7 +18,7 @@ import ( "github.com/go-openapi/swag" ) -// AppLogRequest An array Telnexus Application Log objects +// AppLogRequest An array Taxnexus Application Log objects // // swagger:model AppLogRequest type AppLogRequest struct { diff --git a/api/workflow/workflow_models/app_log_response.go b/api/workflow/workflow_models/app_log_response.go index c1192be..6682fcd 100644 --- a/api/workflow/workflow_models/app_log_response.go +++ b/api/workflow/workflow_models/app_log_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -18,7 +18,7 @@ import ( "github.com/go-openapi/swag" ) -// AppLogResponse An array Telnexus Application Log objects +// AppLogResponse An array Taxnexus Application Log objects // // swagger:model AppLogResponse type AppLogResponse struct { diff --git a/api/workflow/workflow_models/document.go b/api/workflow/workflow_models/document.go index 5ce90d7..ab24081 100644 --- a/api/workflow/workflow_models/document.go +++ b/api/workflow/workflow_models/document.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -16,7 +16,7 @@ import ( "github.com/go-openapi/swag" ) -// Document Telnexus Document +// Document Taxnexus Document // // swagger:model Document type Document struct { diff --git a/api/workflow/workflow_models/email_message.go b/api/workflow/workflow_models/email_message.go index 7504423..8dc768e 100644 --- a/api/workflow/workflow_models/email_message.go +++ b/api/workflow/workflow_models/email_message.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_models/email_message_request.go b/api/workflow/workflow_models/email_message_request.go index fef3161..b751871 100644 --- a/api/workflow/workflow_models/email_message_request.go +++ b/api/workflow/workflow_models/email_message_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -18,7 +18,7 @@ import ( "github.com/go-openapi/swag" ) -// EmailMessageRequest An array Telnexus Send Email Message objects +// EmailMessageRequest An array Taxnexus Send Email Message objects // // swagger:model EmailMessageRequest type EmailMessageRequest struct { diff --git a/api/workflow/workflow_models/email_messages_response.go b/api/workflow/workflow_models/email_messages_response.go index 8883098..0cc5899 100644 --- a/api/workflow/workflow_models/email_messages_response.go +++ b/api/workflow/workflow_models/email_messages_response.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -18,7 +18,7 @@ import ( "github.com/go-openapi/swag" ) -// EmailMessagesResponse An array Telnexus user objects +// EmailMessagesResponse An array Taxnexus user objects // // swagger:model EmailMessagesResponse type EmailMessagesResponse struct { diff --git a/api/workflow/workflow_models/error.go b/api/workflow/workflow_models/error.go index d2c8dcc..22342e6 100644 --- a/api/workflow/workflow_models/error.go +++ b/api/workflow/workflow_models/error.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_models/headers.go b/api/workflow/workflow_models/headers.go index e34df53..17c36d6 100644 --- a/api/workflow/workflow_models/headers.go +++ b/api/workflow/workflow_models/headers.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_models/outgoing_email_message.go b/api/workflow/workflow_models/outgoing_email_message.go index bd77691..fe8c8da 100644 --- a/api/workflow/workflow_models/outgoing_email_message.go +++ b/api/workflow/workflow_models/outgoing_email_message.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed diff --git a/api/workflow/workflow_models/outgoing_email_message_request.go b/api/workflow/workflow_models/outgoing_email_message_request.go index c91eceb..d6abb80 100644 --- a/api/workflow/workflow_models/outgoing_email_message_request.go +++ b/api/workflow/workflow_models/outgoing_email_message_request.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -18,7 +18,7 @@ import ( "github.com/go-openapi/swag" ) -// OutgoingEmailMessageRequest An array Telnexus New Email Message objects +// OutgoingEmailMessageRequest An array Taxnexus New Email Message objects // // swagger:model OutgoingEmailMessageRequest type OutgoingEmailMessageRequest struct { diff --git a/api/workflow/workflow_models/request_meta.go b/api/workflow/workflow_models/request_meta.go index 027ed10..9ad31d4 100644 --- a/api/workflow/workflow_models/request_meta.go +++ b/api/workflow/workflow_models/request_meta.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -23,16 +23,16 @@ import ( // swagger:model RequestMeta type RequestMeta struct { - // Telnexus Account Number of the Reseller or OEM + // Taxnexus Account Number of the Reseller or OEM // Required: true - TelnexusAccount *string `json:"TelnexusAccount"` + TaxnexusAccount *string `json:"TaxnexusAccount"` } // Validate validates this request meta func (m *RequestMeta) Validate(formats strfmt.Registry) error { var res []error - if err := m.validateTelnexusAccount(formats); err != nil { + if err := m.validateTaxnexusAccount(formats); err != nil { res = append(res, err) } @@ -42,9 +42,9 @@ func (m *RequestMeta) Validate(formats strfmt.Registry) error { return nil } -func (m *RequestMeta) validateTelnexusAccount(formats strfmt.Registry) error { +func (m *RequestMeta) validateTaxnexusAccount(formats strfmt.Registry) error { - if err := validate.Required("TelnexusAccount", "body", m.TelnexusAccount); err != nil { + if err := validate.Required("TaxnexusAccount", "body", m.TaxnexusAccount); err != nil { return err } diff --git a/api/workflow/workflow_models/response_meta.go b/api/workflow/workflow_models/response_meta.go index 91cc747..f651cbf 100644 --- a/api/workflow/workflow_models/response_meta.go +++ b/api/workflow/workflow_models/response_meta.go @@ -1,6 +1,6 @@ // Code generated by go-swagger; DO NOT EDIT. -// (c) 2012-2020 by Telnexus LLC +// (c) 2012-2020 by Taxnexus, Inc. // All rights reserved worldwide. // Proprietary product; unlicensed use is not allowed @@ -51,8 +51,8 @@ type ResponseMeta struct { // Backend Server Timestamp ServerTimestamp string `json:"ServerTimestamp,omitempty"` - // Telnexus Account Number used for recording transactions - TelnexusAccount string `json:"TelnexusAccount,omitempty"` + // Taxnexus Account Number used for recording transactions + TaxnexusAccount string `json:"TaxnexusAccount,omitempty"` } // Validate validates this response meta diff --git a/app/address.go b/app/address.go deleted file mode 100644 index 448b11d..0000000 --- a/app/address.go +++ /dev/null @@ -1,20 +0,0 @@ -package app - -// Address address struct -type Address struct { - City string - Country string - CountryCode string - PostalCode string - State string - StateCode string - Street string -} - -// ToString returns the full address in a string -func (obj *Address) ToString() string { - return obj.Street + " " + - obj.City + " " + - obj.State + " " + - obj.PostalCode -} diff --git a/app/auth.go b/app/auth.go deleted file mode 100644 index 73b1b43..0000000 --- a/app/auth.go +++ /dev/null @@ -1,39 +0,0 @@ -package app - -import ( - "code.tnxs.net/vernonkeenan/lib/api/auth/auth_client/user" - "code.tnxs.net/vernonkeenan/lib/api/auth/auth_models" - httptransport "github.com/go-openapi/runtime/client" -) - -// CheckAPIUser authenticates a User with the auth service -// -// When called, ChechAPIUser assumes there is an "auth" service account in the -// app configuration file. -// -func CheckAPIUser(token *string) (*User, error) { - sugar.Debug("app.CheckAPIUser: 📥") - if authUser == nil { - authUser = &User{ - APIKey: GetServiceAccount("auth").APIKey, - Auth: httptransport.APIKeyAuth( - "X-API-Key", - "header", - GetServiceAccount("auth").APIKey, - ), - } - } - params := user.NewGetUsersParams() - params.Apikey = token - response, err := authClient.User.GetUsers(params, authUser.Auth) - if err != nil { - sugar.Warnf("app.CheckAPIUser: ❗ Access attempt with invalid API key: %s", *token) - return nil, err - } - var obj *auth_models.User - for _, itm := range response.Payload.Data { // single iteration execution - obj = itm - } - sugar.Debugf("app.CheckAPIUser: 📤 👍 ID = %s, Name = %s", obj.ID, obj.Name) - return MarshalAuthUserToSwagger(obj), nil -} diff --git a/app/config.go b/app/config.go deleted file mode 100644 index e1dd2a9..0000000 --- a/app/config.go +++ /dev/null @@ -1,217 +0,0 @@ -package app - -import ( - "time" - - "code.tnxs.net/vernonkeenan/lib/app/logger" - "go.uber.org/zap/zapcore" -) - -// Worker describes how many service workers to launch -type Worker struct { - ChannelSize int64 `mapstructure:"channel_size,omitempty"` - WorkerCount int `mapstructure:"worker_count,omitempty"` -} - -// CacheSize describes how to chunkify resources -type CacheSize struct { - Increment int64 -} - -// Metrics defines the if and where to collect data -type Metrics struct { - Address string `mapstructure:"address,omitempty"` - Enabled bool `mapstructure:"enabled,omitempty"` -} - -// Endpoint describes a web URL as a service endpoint -type Endpoint struct { - BasePath string `mapstructure:"base_path,omitempty"` - Host string `mapstructure:"host,omitempty"` - Scheme string `mapstructure:"scheme,omitempty"` -} - -// Chunk defines cache chunk size -type Chunk struct { - size int32 `mapstructure:"size,omitempty"` -} - -// ServiceAccount defines and external service -type ServiceAccount struct { - APIKey string `mapstructure:"api_key,omitempty"` - ApplicationName string `mapstructure:"application_name,omitempty"` - AuthenticationType string `mapstructure:"authentication_type,omitempty"` - BackendID string `mapstructure:"backend_id,omitempty"` - ClientID string `mapstructure:"client_id,omitempty"` - ClientSecret string `mapstructure:"client_secret,omitempty"` - DSN string `mapstructure:"dsn,omitempty"` - Endpoint Endpoint `mapstructure:"endpoint,omitempty"` - Password string `mapstructure:"password,omitempty"` - Production bool `mapstructure:"production,omitempty"` - SecurityToken string `mapstructure:"security_token,omitempty"` - Credentials string `mapstructure:"credentials,omitempty"` - Timeout time.Duration `mapstructure:"timeout,omitempty"` - Type string `mapstructure:"type,omitempty"` - Username string `mapstructure:"username,omitempty"` - Vendor string `mapstructure:"vendor,omitempty"` -} - -// Configuration defines the config struct -type Configuration struct { - AppName string `mapstructure:"app_name,omitempty"` - BackendID string `mapstructure:"backend_id,omitempty"` - BuildEnv string `mapstructure:"build_env,omitempty"` - CacheSizes map[string]CacheSize `mapstructure:"cache_sizes,omitempty"` - ClusterID string `mapstructure:"cluster_id,omitempty"` - Chunks map[string]Chunk `mapstructure:"chunks,omitempty"` - DBMS string `mapstructure:"dbms,omitempty"` - DBMSHost string `mapstructure:"dbms_host,omitempty"` - DBMSName string `mapstructure:"dbms_name,omitempty"` - DBMSPassword string `mapstructure:"dbms_password,omitempty"` - DBMSUsername string `mapstructure:"dbms_username,omitempty"` - DSN string `mapstructure:"dsn,omitempty"` - Endpoint Endpoint `mapstructure:"endpoint,omitempty"` - Environment string `mapstructure:"environment,omitempty"` - GelfURI string `mapstructure:"gelf_uri,omitempty"` - GitHubOrgName string `mapstructure:"git_hub_org_name,omitempty"` - LogLevel int `mapstructure:"log_level,omitempty"` - Metrics Metrics `mapstructure:"metrics,omitempty"` - KafkaServer string `mapstructure:"kafka_server,omitempty"` - PDFRenderEngine string `mapstructure:"pdf_render_engine,omitempty"` - RegistryPriv string `mapstructure:"registry_priv,omitempty"` - RegistryPublic string `mapstructure:"registry_public,omitempty"` - RepoName string `mapstructure:"repo_name,omitempty"` - ServiceAccounts map[string]ServiceAccount `mapstructure:"service_accounts,omitempty"` - ShutdownTimeout time.Duration `mapstructure:"shutdown_timeout,omitempty"` - Version string `mapstructure:"version,omitempty"` - Workers map[string]Worker `mapstructure:"workers,omitempty"` -} - -// GetCacheSize returns the named cache size -func GetCacheSize(name string) int64 { - obj, ok := config.CacheSizes[name] - if ok { - return obj.Increment - } - sugar.Warnf("app.GetCacheSize: unknown cache size identifier: %s", name) - return 0 -} - -// GetPDFRenderEngine returns a config file parameter -func GetPDFRenderEngine() string { - return config.PDFRenderEngine -} - -// GetKafkaServer returns a config file parameter -func GetKafkaServer() string { - if config.KafkaServer != "" { - return config.KafkaServer - } - return "nats.fabric.tnxs.net" -} - -// GetChunkSize returns a config file parameter -func GetChunkSize(chunkName string) int { - obj, ok := config.Chunks[chunkName] - if ok { - return int(obj.size) - } - return 0 -} - -// GetMetricsAddress return the metrics Address value -func GetMetricsAddress() string { - return config.Metrics.Address -} - -// IsMetrics returns TRUE if metrics enabled -func IsMetrics() bool { - return config.Metrics.Enabled -} - -// GetWorker returns the named worker record -func GetWorker(name string) *Worker { - worker, ok := config.Workers[name] - if ok { - return &worker - } - return nil -} - -// GetServiceAccount returns the named service account struct -func GetServiceAccount(name string) *ServiceAccount { - serviceaccount, ok := config.ServiceAccounts[name] - if ok { - return &serviceaccount - } - sugar.Errorf("app.config: 💣⛔ unknown service account: %s", name) - return nil -} - -// GetDBMSHost returns the parameter -func GetDBMSHost() string { - return config.DBMSHost -} - -// GetDBMSName returns the parameter -func GetDBMSName() string { - return config.DBMSName -} - -// GetDBMSPassword returns the parameter -func GetDBMSPassword() string { - return config.DBMSPassword -} - -// GetDBMSUsername returns the parameter -func GetDBMSUsername() string { - return config.DBMSUsername -} - -// GetAppName retrieves the Taxnexus App Name for this microservice -func GetAppName() string { - return config.AppName -} - -// GetEnvironment retrieves the current runtime environment -func GetEnvironment() string { - return config.Environment -} - -// GetBackendID retrieves the backend ID -func GetBackendID() string { - return config.BackendID -} - -// GetClusterID retrieves the cluster ID -func GetClusterID() string { - return config.ClusterID -} - -// GetDSN retrieves the Taxnexus database DSN for this microservice -func GetDSN() string { - return config.DSN -} - -// GetDBMS retrieves the DBMS string -func GetDBMS() string { - return config.DBMS -} - -// GetLogLevel returns the Log Level -func GetLogLevel() zapcore.Level { - switch config.LogLevel { - case int(logger.DebugLevel): - return logger.DebugLevel - case int(logger.InfoLevel): - return logger.InfoLevel - case int(logger.WarnLevel): - return logger.WarnLevel - case int(logger.ErrorLevel): - return logger.ErrorLevel - case int(logger.PanicLevel): - return logger.PanicLevel - default: - return logger.DebugLevel - } -} diff --git a/app/force.go b/app/force.go deleted file mode 100644 index 521af2b..0000000 --- a/app/force.go +++ /dev/null @@ -1,26 +0,0 @@ -package app - -import ( - "github.com/taxnexus/go-force/force" -) - -// InitForce creates a salesforce connection using serviceAccountName -func InitForce(serviceAccountName string) *force.API { - sugar.Infof("app.initForce: 📥 %s", serviceAccountName) - acct := GetServiceAccount(serviceAccountName) - theForce, err := force.Create( - "v45.0", - acct.ClientID, - acct.ClientSecret, - acct.Username, - acct.Password, - acct.SecurityToken, - "production", - ) - if err != nil { - sugar.Errorf("app.InitForce: salesforce error: %s", err.Error()) - return nil - } - sugar.Info("app.InitForce: 👍 📤") - return theForce -} diff --git a/app/logger/logger.go b/app/logger/logger.go deleted file mode 100644 index 7e5fb5f..0000000 --- a/app/logger/logger.go +++ /dev/null @@ -1,43 +0,0 @@ -// Package logger wraps an external logging package -package logger - -import ( - "log" - - "go.uber.org/zap" - "go.uber.org/zap/zapcore" -) - -type logger = zap.SugaredLogger - -// DebugLevel is exported (5) -var DebugLevel = zapcore.DebugLevel - -// InfoLevel is exported (4) -var InfoLevel = zapcore.InfoLevel - -// WarnLevel is exported (3) -var WarnLevel = zapcore.WarnLevel - -// ErrorLevel is exported (2) -var ErrorLevel = zapcore.ErrorLevel - -// PanicLevel is exported (1) -var PanicLevel = zapcore.PanicLevel - -// New creates a new logger and returns it -func New(level zapcore.Level) *logger { - var theLogger *zap.Logger - var err error - if level == zapcore.DebugLevel { - theLogger, err = zap.NewDevelopment() - } else { - theLogger, err = zap.NewProduction() - } - if err != nil { - log.Fatal("logger.New: 💣 ⛔ zap logger init fail") - } - // theLogger.SetLevel - defer theLogger.Sync() //nolint:errcheck // it's defered - return theLogger.Sugar() -} diff --git a/app/mysql.go b/app/mysql.go deleted file mode 100644 index 36db634..0000000 --- a/app/mysql.go +++ /dev/null @@ -1,29 +0,0 @@ -package app - -import ( - "database/sql" - - // need this for SQL - _ "github.com/go-sql-driver/mysql" -) - -// MyDB is the MySQL handler variable -var MyDB *sql.DB - -// InitDB initializes the MySQL database using DSN information from the config file -// -func InitDB() { - var db *sql.DB - var err error - if GetDBMS() != "mysql" { - sugar.Fatalf("app.InitDB: 💣 ⛔ unknown DBMS: %s", GetDBMS()) - return - } - db, err = sql.Open("mysql", GetDSN()) - if err != nil { - sugar.Fatalf("app.InitDB: 💣 ⛔ Can't log on to DBMS host: %w", err) - return - } - MyDB = db - sugar.Debugf("app.InitDB: 👍 📤 %s", GetDBMS()) -} diff --git a/app/prometheus.go b/app/prometheus.go deleted file mode 100644 index ed6f341..0000000 --- a/app/prometheus.go +++ /dev/null @@ -1,67 +0,0 @@ -package app - -import ( - "fmt" - "net/http" - "time" - - "github.com/prometheus/client_golang/prometheus" - "github.com/rs/cors" -) - -var ( - namespace = "collage" - - counter = prometheus.NewCounterVec(prometheus.CounterOpts{ - Namespace: namespace, - Name: "endpoint_request_count", - Help: "collage request count.", - }, []string{"app", "name", "method", "state"}) - - histogram = prometheus.NewHistogramVec(prometheus.HistogramOpts{ - Namespace: namespace, - Name: "endpoint_duration_seconds", - Help: "Time taken to execute endpoint.", - }, []string{"app", "name", "method", "status"}) -) - -type metricResponseWriter struct { - http.ResponseWriter - statusCode int -} - -func newMetricResponseWriter(w http.ResponseWriter) *metricResponseWriter { - return &metricResponseWriter{w, http.StatusOK} -} - -func (lrw *metricResponseWriter) WriteHeader(code int) { - lrw.statusCode = code - lrw.ResponseWriter.WriteHeader(code) -} - -// SetupPrometheusHandler enable CORS, handler metrics -func SetupPrometheusHandler(handler http.Handler, app string) http.Handler { - sugar.Debug("app.SetupPrometheusHandler: 📥") - handleCORS := cors.AllowAll().Handler - h := http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { - start := time.Now() - lrw := newMetricResponseWriter(w) - handler.ServeHTTP(lrw, r) - statusCode := lrw.statusCode - duration := time.Since(start) - histogram.WithLabelValues(app, r.URL.String(), r.Method, fmt.Sprintf("%d", statusCode)).Observe(duration.Seconds()) - counter.WithLabelValues(app, r.URL.String(), r.Method, fmt.Sprintf("%d", statusCode)).Inc() - }) - err := prometheus.Register(histogram) - if err != nil { - sugar.Errorf("app.SetupPrometheusHandler: 💣 ⛔ %s", err.Error()) - return nil - } - err = prometheus.Register(counter) - if err != nil { - sugar.Errorf("app.SetupPrometheusHandler: 💣 ⛔ %s", err.Error()) - return nil - } - sugar.Info("app.SetupPrometheusHandler: 👍 📤") - return handleCORS(h) -} diff --git a/app/root.go b/app/root.go deleted file mode 100644 index b58f6f8..0000000 --- a/app/root.go +++ /dev/null @@ -1,50 +0,0 @@ -// Package app is a utility package -package app - -import ( - "strings" - - "code.tnxs.net/vernonkeenan/lib/api/auth/auth_client" - "code.tnxs.net/vernonkeenan/lib/app/logger" - "github.com/spf13/viper" - "github.com/taxnexus/go-force/force" - "go.uber.org/zap" - "go.uber.org/zap/zapcore" -) - -// const dateTimeFormat = "2006-01-02T15:04:05-0800" -var sugar *zap.SugaredLogger -var config = Configuration{} -var appViper = viper.New() -var configured = false -var authClient = auth_client.Default -var authUser *User - -// TheForce exports the salesforce interface -var TheForce *force.API - -// InitConfig exports the config initialization func -func InitConfig(systemName string, initalLogLevel zapcore.Level) { - if configured { - return - } - sugar = logger.New(initalLogLevel) - sugar.Infof("app.InitConfig: 📥 %s", systemName) - appViper.SetConfigType("yaml") - appViper.SetConfigName(systemName) - appViper.AddConfigPath("/etc/telnexus") - appViper.SetEnvKeyReplacer(strings.NewReplacer(".", "_")) - appViper.SetEnvPrefix("telnexus") - appViper.AutomaticEnv() // read in environment variables that match - err := appViper.ReadInConfig() - if err != nil { - sugar.Fatalf("app.InitConfig: 💣 ⛔ can't read system config: %w", err) - } - err = appViper.Unmarshal(&config) - if err != nil { - sugar.Fatalf("app.InitConfig: 💣 ⛔ can't unmarshal system config: %w", err) - } - sugar = logger.New(GetLogLevel()) - sugar.Debugf("app.InitConfig: 👍 📤 serviceAccounts: %d", len(config.ServiceAccounts)) - configured = true -} diff --git a/app/tenantuser.go b/app/tenantuser.go deleted file mode 100644 index 206ef28..0000000 --- a/app/tenantuser.go +++ /dev/null @@ -1,31 +0,0 @@ -package app - -import "code.tnxs.net/vernonkeenan/lib/api/devops/devops_models" - -// TenantUserActivityWrapper wraps the object with workflow params -type TenantUserActivityWrapper struct { - Obj devops_models.TenantUser - APIKey string - SagaID string - SagaType string -} - -// TenantUser is a first class object type -type TenantUser struct { - AccessLevel string - AccountID string - Auth0UserID string - CompanyName string - ContactID string - TelnexusAccount string - TenantActive bool - TenantID string - TenantName string - TenantStatus string - TenantType string - TenantVersion string - UserEmail string - UserFullName string - UserID string - Username string -} diff --git a/app/user-helpers.go b/app/user-helpers.go deleted file mode 100644 index 986fd3c..0000000 --- a/app/user-helpers.go +++ /dev/null @@ -1,134 +0,0 @@ -package app - -import ( - "code.tnxs.net/vernonkeenan/lib/api/auth/auth_models" - httptransport "github.com/go-openapi/runtime/client" -) - -// MarshalAuthUserToSwagger is a helper function -func MarshalAuthUserToSwagger(obj *auth_models.User) *User { - var address *Address - if obj.Address != nil { - address = &Address{ - City: obj.Address.City, - Country: obj.Address.Country, - CountryCode: obj.Address.CountryCode, - PostalCode: obj.Address.PostalCode, - State: obj.Address.State, - StateCode: obj.Address.StateCode, - Street: obj.Address.Street, - } - } - var userRoles []*UserRole - if obj.UserRoles != nil { - userRoles = []*UserRole{} - for _, itm := range obj.UserRoles { - userRoles = append(userRoles, reMarshalUserRole(itm)) - } - } - var tenantUsers []*TenantUser - if obj.TenantUsers != nil { - tenantUsers = []*TenantUser{} - for _, itm := range obj.TenantUsers { - tenantUsers = append(tenantUsers, reMarshalTenantUser(itm)) - } - } - return &User{ - ID: obj.ID, - AboutMe: obj.AboutMe, - AccountID: obj.AccountID, - Address: address, - Alias: obj.Alias, - APIKey: obj.APIKey, - Auth: httptransport.APIKeyAuth("X-API-Key", "header", obj.APIKey), - Auth0UserID: obj.Auth0UserID, - CommunityNickname: obj.CommunityNickname, - CompanyName: obj.CompanyName, - ContactID: obj.ContactID, - CreatedByID: obj.CreatedByID, - CreatedDate: obj.CreatedDate, - DelegatedApproverID: obj.DelegatedApproverID, - Department: obj.Department, - Division: obj.Division, - Email: obj.Email, - EmployeeNumber: obj.EmployeeNumber, - EndOfDay: obj.EndOfDay, - Environment: obj.Environment, - Extension: obj.Extension, - FabricAPIKey: obj.FabricAPIKey, - Fax: obj.Fax, - FirstName: obj.FirstName, - ForecastEnabled: obj.ForecastEnabled, - FullPhotoURL: obj.FullPhotoURL, - IsActive: obj.IsActive, - IsPortalEnabled: obj.IsPortalEnabled, - IsProfilePhotoActive: obj.IsProphilePhotoActive, - IsSystemControlled: obj.IsSystemControlled, - LastIP: obj.LastIP, - LastLogin: obj.LastLogin, - LastModifiedByID: obj.LastModifiedByID, - LastModifiedDate: obj.LastModifiedDate, - LastName: obj.LastName, - LoginCount: obj.LoginCount, - ManagerID: obj.ManagerID, - MobilePhone: obj.MobilePhone, - Name: obj.Name, - OutOfOfficeMessage: obj.OutOfOfficeMessage, - Phone: obj.Phone, - PortalRole: obj.PortalRole, - ProfileID: obj.ProfileID, - ReceivesAdminEmails: obj.ReceivesAdminEmails, - ReceivesAdminInfoEmails: obj.ReceivesAdminInfoEmails, - SenderEmail: obj.SenderEmail, - SenderName: obj.SenderName, - Signature: obj.Signature, - SmallPhotoURL: obj.SmallPhotoURL, - StartOfDay: obj.StartOfDay, - TaxnexusAccount: obj.TelnexusAccount, - TenantID: obj.TenantID, - TenantUsers: tenantUsers, - TimeZone: obj.TimeZone, - Title: obj.Title, - Username: obj.Username, - UserRoleID: obj.UserRoleID, - UserRoles: userRoles, - UserType: obj.UserType, - } -} -func reMarshalUserRole(s *auth_models.UserRole) *UserRole { - return &UserRole{ - AccountID: s.AccountID, - Auth0RoleID: s.Auth0RoleID, - Auth0UserID: s.Auth0UserID, - CompanyName: s.CompanyName, - ContactID: s.ContactID, - RoleDescription: s.RoleDescription, - RoleID: s.RoleID, - RoleName: s.RoleName, - TelnexusAccount: s.TelnexusAccount, - UserEmail: s.UserEmail, - UserFullName: s.UserFullName, - UserID: s.UserID, - Username: s.Username, - } -} -func reMarshalTenantUser(s *auth_models.TenantUser) *TenantUser { - return &TenantUser{ - AccessLevel: s.AccessLevel, - AccountID: s.AccountID, - Auth0UserID: s.Auth0UserID, - CompanyName: s.CompanyName, - ContactID: s.ContactID, - TelnexusAccount: s.TelnexusAccount, - TenantActive: s.TenantActive, - TenantID: s.TenantID, - TenantName: s.TenantName, - TenantStatus: s.TenantStatus, - TenantType: s.TenantType, - TenantVersion: s.TenantVersion, - UserEmail: s.UserEmail, - UserFullName: s.UserFullName, - UserID: s.UserID, - Username: s.Username, - } -} diff --git a/app/user.go b/app/user.go deleted file mode 100644 index db4926f..0000000 --- a/app/user.go +++ /dev/null @@ -1,78 +0,0 @@ -package app - -import ( - "code.tnxs.net/vernonkeenan/lib/api/devops/devops_models" - "github.com/go-openapi/runtime" -) - -// UserActivityWrapper wraps the object with workflow params -type UserActivityWrapper struct { - Obj devops_models.User - APIKey string - SagaID string - SagaType string -} - -// User is a first class object type -type User struct { - ID string - AboutMe string - AccountID string - Address *Address - Alias string - APIKey string - Auth runtime.ClientAuthInfoWriter - Auth0UserID string - CommunityNickname string - CompanyName string - ContactID string - CreatedByID string - CreatedDate string - DelegatedApproverID string - Department string - Division string - Email string - EmployeeNumber string - EndOfDay string - Environment string - Extension string - FabricAPIKey string - Fax string - FirstName string - ForecastEnabled bool - FullPhotoURL string - IsActive bool - IsPortalEnabled bool - IsProfilePhotoActive bool - IsSystemControlled bool - LastIP string - LastLogin string - LastModifiedByID string - LastModifiedDate string - LastName string - LoginCount int64 - ManagerID string - MobilePhone string - Name string - OutOfOfficeMessage string - Phone string - PortalRole string - ProfileID string - ReceivesAdminEmails bool - ReceivesAdminInfoEmails bool - ReceivesInfoEmails bool - SenderEmail string - SenderName string - Signature string - SmallPhotoURL string - StartOfDay string - TaxnexusAccount string - TenantID string - TenantUsers []*TenantUser - TimeZone string - Title string - Username string - UserRoles []*UserRole - UserRoleID string - UserType string -} diff --git a/app/userrole.go b/app/userrole.go deleted file mode 100644 index b1bbc19..0000000 --- a/app/userrole.go +++ /dev/null @@ -1,28 +0,0 @@ -package app - -import "code.tnxs.net/vernonkeenan/lib/api/devops/devops_models" - -// UserRoleActivityWrapper wraps the object with workflow params -type UserRoleActivityWrapper struct { - Obj devops_models.UserRole - APIKey string - SagaID string - SagaType string -} - -// UserRole is a first class object type -type UserRole struct { - RoleID string - UserID string - Auth0RoleID string - RoleDescription string - RoleName string - AccountID string - CompanyName string - ContactID string - UserEmail string - UserFullName string - TelnexusAccount string - Username string - Auth0UserID string -} diff --git a/build/COPYRIGHT b/build/COPYRIGHT index 09cf3a9..a24e590 100644 --- a/build/COPYRIGHT +++ b/build/COPYRIGHT @@ -1,3 +1,3 @@ -(c) 2012-2020 by Telnexus LLC +(c) 2012-2020 by Taxnexus, Inc. All rights reserved worldwide. Proprietary product; unlicensed use is not allowed \ No newline at end of file diff --git a/go.mod b/go.mod index 590d26f..6ab5bf7 100644 --- a/go.mod +++ b/go.mod @@ -8,10 +8,6 @@ require ( github.com/go-openapi/strfmt v0.19.5 github.com/go-openapi/swag v0.19.9 github.com/go-openapi/validate v0.19.10 - github.com/go-sql-driver/mysql v1.4.0 - github.com/prometheus/client_golang v1.9.0 - github.com/rs/cors v1.7.0 - github.com/spf13/viper v1.7.1 - github.com/taxnexus/go-force v1.0.7 - go.uber.org/zap v1.16.0 + github.com/google/go-cmp v0.4.0 // indirect + golang.org/x/net v0.0.0-20200625001655-4c5254603344 // indirect ) diff --git a/go.sum b/go.sum index 11f4b2e..8fd1f43 100644 --- a/go.sum +++ b/go.sum @@ -1,107 +1,22 @@ -cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= -cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= -cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU= -cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU= -cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY= -cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc= -cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0= -cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o= -cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= -cloud.google.com/go/firestore v1.1.0/go.mod h1:ulACoGHTpvq5r8rxGJ4ddJZBZqakUQqClKRT5SZwBmk= -cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I= -cloud.google.com/go/storage v1.0.0/go.mod h1:IhtSnM/ZTZV8YYJWCY8RULGVqBDmpoyjwiyrjsg+URw= -dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= -github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= -github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= -github.com/Knetic/govaluate v3.0.1-0.20171022003610-9aa49832a739+incompatible/go.mod h1:r7JcOSlj0wfOMncg0iLm8Leh48TZaKVeNIfJntJ2wa0= -github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/PuerkitoBio/purell v1.1.0/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= github.com/PuerkitoBio/purell v1.1.1 h1:WEQqlqaGbrPkxLJWfBwQmfEAE1Z7ONdDLqrN38tNFfI= github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578 h1:d+Bc7a5rLufV/sSk/8dngufqelfh6jnri85riMAaF/M= github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE= -github.com/Shopify/sarama v1.19.0/go.mod h1:FVkBWblsNy7DGZRfXLU0O9RCGt5g3g3yEuWXgklEdEo= -github.com/Shopify/toxiproxy v2.1.4+incompatible/go.mod h1:OXgGpZ6Cli1/URJOF1DMxUHB2q5Ap20/P/eIdh4G0pI= -github.com/VividCortex/gohistogram v1.0.0/go.mod h1:Pf5mBqqDxYaXu3hDrrU+w6nw50o/4+TcAqDqk/vUH7g= -github.com/afex/hystrix-go v0.0.0-20180502004556-fa1af6a1f4f5/go.mod h1:SkGFH1ia65gfNATL8TAiHDNxPzPdmEL5uirI2Uyuz6c= -github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= -github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= -github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= -github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= -github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d/go.mod h1:rBZYJk541a8SKzHPHnH3zbiI+7dagKZ0cgpgrD7Fyho= -github.com/apache/thrift v0.12.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ= -github.com/apache/thrift v0.13.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ= -github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o= -github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY= -github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= -github.com/aryann/difflib v0.0.0-20170710044230-e206f873d14a/go.mod h1:DAHtR1m6lCRdSC2Tm3DSWRPvIPr6xNKyeHdqDQSQT+A= github.com/asaskevich/govalidator v0.0.0-20180720115003-f9ffefc3facf/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY= github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY= github.com/asaskevich/govalidator v0.0.0-20200108200545-475eaeb16496/go.mod h1:oGkLhpf+kjZl6xBf758TQhh5XrAeiJv/7FRz/2spLIg= github.com/asaskevich/govalidator v0.0.0-20200428143746-21a406dcc535 h1:4daAzAu0S6Vi7/lbWECcX0j45yZReDZ56BQsrVBOEEY= github.com/asaskevich/govalidator v0.0.0-20200428143746-21a406dcc535/go.mod h1:oGkLhpf+kjZl6xBf758TQhh5XrAeiJv/7FRz/2spLIg= -github.com/aws/aws-lambda-go v1.13.3/go.mod h1:4UKl9IzQMoD+QF79YdCuzCwp8VbmG4VAQwij/eHl5CU= -github.com/aws/aws-sdk-go v1.27.0/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= -github.com/aws/aws-sdk-go-v2 v0.18.0/go.mod h1:JWVYvqSMppoMJC0x5wdwiImzgXTI9FuZwxzkQq9wy+g= -github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= -github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8= -github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= -github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= -github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= -github.com/bketelsen/crypt v0.0.3-0.20200106085610-5cbc8cc4026c/go.mod h1:MKsuJmJgSg28kpZDP6UIiPt0e0Oz0kqKNGyRaWEPv84= -github.com/casbin/casbin/v2 v2.1.2/go.mod h1:YcPU1XXisHhLzuxH9coDNf2FbKpjGlbCg3n9yuLkIJQ= -github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= -github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= -github.com/cespare/xxhash v1.1.0 h1:a6HrQnmkObjyL+Gs60czilIUGqrzKutQD6XZog3p+ko= -github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= -github.com/cespare/xxhash/v2 v2.1.1 h1:6MnRN8NT7+YBpUIWxHtefFZOKTAPgGjpQSxqLNn0+qY= -github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/clbanning/x2j v0.0.0-20191024224557-825249438eec/go.mod h1:jMjuTZXRI4dUb/I5gc9Hdhagfvm9+RyrPryS/auMzxE= -github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= -github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8= -github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI= -github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= -github.com/coreos/etcd v3.3.13+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= -github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= -github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= -github.com/coreos/go-systemd v0.0.0-20180511133405-39ca1b05acc7/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= -github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= -github.com/coreos/pkg v0.0.0-20160727233714-3ac0863d7acf/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= -github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= -github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= -github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= -github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no= github.com/docker/go-units v0.3.3/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= github.com/docker/go-units v0.4.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= -github.com/dustin/go-humanize v0.0.0-20171111073723-bb3d318650d4/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= -github.com/eapache/go-resiliency v1.1.0/go.mod h1:kFI+JgMyC7bLPUVY133qvEBtVayf5mFgVsvEsIPBvNs= -github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21/go.mod h1:+020luEh2TKB4/GOp8oxxtq0Daoen/Cii55CzbTV6DU= -github.com/eapache/queue v1.1.0/go.mod h1:6eCeP0CKFpHLu8blIFXhExK/dRa7WDZfr6jVFPTqq+I= -github.com/edsrzf/mmap-go v1.0.0/go.mod h1:YO35OhQPt3KJa3ryjFM5Bs14WD66h8eGKpfaBNrHW5M= -github.com/envoyproxy/go-control-plane v0.6.9/go.mod h1:SBwIajubJHhxtWwsL9s8ss4safvEdbitLhGGK48rN6g= -github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= -github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= -github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= -github.com/franela/goblin v0.0.0-20200105215937-c9ffbefa60db/go.mod h1:7dvUGVsVBjqR7JHJk0brhHOZYGmfBYOrK0ZhYMEtBr4= -github.com/franela/goreq v0.0.0-20171204163338-bcd34c9993f8/go.mod h1:ZhphrRTfi2rbfLwlschooIH4+wKKDR4Pdxhh+TRoA20= -github.com/fsnotify/fsnotify v1.4.7 h1:IXs+QLmnXW2CcXuY+8Mzv/fWEsPGWxqefPtCP5CnV9I= -github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= -github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/globalsign/mgo v0.0.0-20180905125535-1ca0a4f7cbcb/go.mod h1:xkRDCp4j0OGD1HRkm4kmhM+pmpv3AKq5SU7GMg4oO/Q= github.com/globalsign/mgo v0.0.0-20181015135952-eeefdecb41b8/go.mod h1:xkRDCp4j0OGD1HRkm4kmhM+pmpv3AKq5SU7GMg4oO/Q= -github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= -github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= -github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= -github.com/go-kit/kit v0.10.0/go.mod h1:xUsJbQ/Fp4kEt7AFgCuvyX4a71u8h9jB8tj/ORgOZ7o= -github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= -github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= -github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= github.com/go-openapi/analysis v0.0.0-20180825180245-b006789cd277/go.mod h1:k70tL6pCuVxPJOHXQ+wIac1FUrvNkHolPie/cLEU6hI= github.com/go-openapi/analysis v0.17.0/go.mod h1:IowGgpVeD0vNm45So8nr+IcQ3pxVtpRoBWb8PVZO0ik= github.com/go-openapi/analysis v0.18.0/go.mod h1:IowGgpVeD0vNm45So8nr+IcQ3pxVtpRoBWb8PVZO0ik= @@ -166,8 +81,6 @@ github.com/go-openapi/validate v0.19.2/go.mod h1:1tRCw7m3jtI8eNWEEliiAqUIcBztB2K github.com/go-openapi/validate v0.19.3/go.mod h1:90Vh6jjkTn+OT1Eefm0ZixWNFjhtOH7vS9k0lo6zwJo= github.com/go-openapi/validate v0.19.10 h1:tG3SZ5DC5KF4cyt7nqLVcQXGj5A7mpaYkAcNPlDK+Yk= github.com/go-openapi/validate v0.19.10/go.mod h1:RKEZTUWDkxKQxN2jDT7ZnZi2bhZlbNMAuKvKB+IaGx8= -github.com/go-sql-driver/mysql v1.4.0 h1:7LxgVwFb2hIQtMm87NdgAVfXjnt4OePseqT1tKx+opk= -github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= github.com/go-stack/stack v1.8.0 h1:5SgMzNM5HxrEjV0ww2lTmX6E2Izsfxas4+YHWRs3Lsk= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= github.com/gobuffalo/attrs v0.0.0-20190224210810-a9411de4debd/go.mod h1:4duuawTqi2wkkpB4ePgWMaai6/Kc6WEz83bhFwpHzj0= @@ -194,121 +107,28 @@ github.com/gobuffalo/packd v0.1.0/go.mod h1:M2Juc+hhDXf/PnmBANFCqx4DM3wRbgDvnVWe github.com/gobuffalo/packr/v2 v2.0.9/go.mod h1:emmyGweYTm6Kdper+iywB6YK5YzuKchGtJQZ0Odn4pQ= github.com/gobuffalo/packr/v2 v2.2.0/go.mod h1:CaAwI0GPIAv+5wKLtv8Afwl+Cm78K/I/VCm/3ptBN+0= github.com/gobuffalo/syncx v0.0.0-20190224160051-33c29581e754/go.mod h1:HhnNqWY95UYwwW3uSASeV7vtgYkT2t16hJgV3AEPUpw= -github.com/gogo/googleapis v1.1.0/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= -github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= -github.com/gogo/protobuf v1.2.0/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= -github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4= -github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= -github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= -github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= -github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= -github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= -github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= -github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y= -github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= -github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= -github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= -github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8= -github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA= -github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= -github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= -github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= -github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= -github.com/golang/protobuf v1.4.3 h1:JjCZWpVbqXDqFVmTfYWEVTMIYrL/NPdPSCHPJ0T/raM= -github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= -github.com/golang/snappy v0.0.0-20180518054509-2e65f85255db/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.1/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= -github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= -github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= -github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.4.0 h1:xsAVV57WRhGj6kEIi8ReJzQlHHqcBYCElAvkovg3B/4= github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= -github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs= -github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= -github.com/google/pprof v0.0.0-20190515194954-54271f7e092f/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= -github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.1.1 h1:Gkbcsh/GbpXz7lPftLA3P6TYMwjCLYm83jiFQZF/3gY= github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= -github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= -github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1 h1:EGx4pi6eqNxGaHF6qqu48+N2wcFQ5qg5FXgOdqsJ5d8= -github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= -github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg= -github.com/gorilla/mux v1.6.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= -github.com/gorilla/mux v1.7.3/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= -github.com/gorilla/websocket v0.0.0-20170926233335-4201258b820c/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= -github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= -github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= -github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= -github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= -github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= -github.com/grpc-ecosystem/grpc-gateway v1.9.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= -github.com/hashicorp/consul/api v1.1.0/go.mod h1:VmuI/Lkw1nC05EYQWNKwWGbkg+FbDBtguAZLlVdkD9Q= -github.com/hashicorp/consul/api v1.3.0/go.mod h1:MmDNSzIMUjNpY/mQ398R4bk2FnqQLoPndWW5VkKPlCE= -github.com/hashicorp/consul/sdk v0.1.1/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8= -github.com/hashicorp/consul/sdk v0.3.0/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8= -github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= -github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= -github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= -github.com/hashicorp/go-msgpack v0.5.3/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM= -github.com/hashicorp/go-multierror v1.0.0/go.mod h1:dHtQlpGsu+cZNNAkkCN/P3hoUDHhCYQXV3UM06sGGrk= -github.com/hashicorp/go-rootcerts v1.0.0/go.mod h1:K6zTfqpRlCUIjkwsN4Z+hiSfzSTQa6eBIzfwKfwNnHU= -github.com/hashicorp/go-sockaddr v1.0.0/go.mod h1:7Xibr9yA9JjQq1JpNB2Vw7kxv8xerXegt+ozgdvDeDU= -github.com/hashicorp/go-syslog v1.0.0/go.mod h1:qPfqrKkXGihmCqbJM2mZgkZGvKG1dFdvsLplgctolz4= -github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= -github.com/hashicorp/go-uuid v1.0.1/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= -github.com/hashicorp/go-version v1.2.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= -github.com/hashicorp/go.net v0.0.1/go.mod h1:hjKkEWcCURg++eb33jQU7oqQcI9XDCnUzHA0oac0k90= -github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= -github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= -github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4= -github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= -github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64= -github.com/hashicorp/mdns v1.0.0/go.mod h1:tL+uN++7HEJ6SQLQ2/p+z2pH24WQKWjBPkE0mNTz8vQ= -github.com/hashicorp/memberlist v0.1.3/go.mod h1:ajVTdAv/9Im8oMAAj5G31PhhMCZJV2pPBoIllUwCN7I= -github.com/hashicorp/serf v0.8.2/go.mod h1:6hOLApaqBFA1NXqRQAsxw9QxuDEvNxSQRwA/JwenrHc= -github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= -github.com/hudl/fargo v1.3.0/go.mod h1:y3CKSmjA+wD2gak7sUSXTAoopbhU08POFhmITJgmKTg= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= -github.com/influxdata/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= -github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= github.com/joho/godotenv v1.3.0/go.mod h1:7hK45KPybAkOC6peb+G5yklZfMxEjkZhHbwpqxOKXbg= -github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo= -github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= -github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= -github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= -github.com/json-iterator/go v1.1.8/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= -github.com/json-iterator/go v1.1.10/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= -github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= -github.com/jtolds/gls v4.20.0+incompatible h1:xdiiI2gbIgH/gLH7ADydsJ1uDOEzR8yvV7C0MuV77Wo= -github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= -github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= -github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= github.com/karrick/godirwalk v1.8.0/go.mod h1:H5KPZjojv4lE+QYImBI8xVtrBRgYrIVsaRPx4tDPEn4= github.com/karrick/godirwalk v1.10.3/go.mod h1:RoGL9dQei4vP9ilrpETWE8CLOZ1kiN0LhBygSwrAsHA= -github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q= github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00= -github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/klauspost/compress v1.9.5/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/konsorten/go-windows-terminal-sequences v1.0.2/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= -github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= -github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= github.com/kr/pty v1.1.5/go.mod h1:9r2w37qlBe7rQ6e1fg1S/9xpWHSnaqNdHD3WcMdbPDA= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= -github.com/lightstep/lightstep-tracer-common/golang/gogo v0.0.0-20190605223551-bc2310a04743/go.mod h1:qklhhLq1aX+mtWk9cPHPzaBjWImj5ULL6C7HFJtXQMM= -github.com/lightstep/lightstep-tracer-go v0.18.1/go.mod h1:jlF1pusYV4pidLvZ+XD0UBX0ZE6WURAspgAczcDHrL4= -github.com/lyft/protoc-gen-validate v0.0.13/go.mod h1:XbGvPuh87YZc5TdIa2/I4pLk0QoUACkjt2znoq26NVQ= -github.com/magiconair/properties v1.8.1 h1:ZC2Vc7/ZFkGmsVC9KvOjumD+G5lXy2RtTKyzRKO2BQ4= -github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= github.com/mailru/easyjson v0.0.0-20180823135443-60711f1a8329/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= github.com/mailru/easyjson v0.0.0-20190312143242-1de009706dbe/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= @@ -317,144 +137,28 @@ github.com/mailru/easyjson v0.7.1 h1:mdxE1MF9o53iCb2Ghj1VfWvh7ZOwHpnVG/xwXrV90U8 github.com/mailru/easyjson v0.7.1/go.mod h1:KAzv3t3aY1NaHWoQz1+4F1ccyAH66Jk7yos7ldAVICs= github.com/markbates/oncer v0.0.0-20181203154359-bf2de49a0be2/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE= github.com/markbates/safe v1.0.1/go.mod h1:nAqgmRi7cY2nqMc92/bSEeQA+R4OheNU2T1kNSCBdG0= -github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= -github.com/mattn/go-isatty v0.0.3/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= -github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= -github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= -github.com/matttproud/golang_protobuf_extensions v1.0.1 h1:4hp9jkHxhMHkqkrB3Ix0jegS5sx/RkqARlsWZ6pIwiU= -github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= -github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= -github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc= -github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= -github.com/mitchellh/go-testing-interface v1.0.0/go.mod h1:kRemZodwjscx+RGhAo8eIhFbs2+BFgRtFPeD/KE+zxI= -github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS42BGNg= -github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY= -github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.3.2 h1:mRS76wmkOn3KkKAyXDu42V+6ebnXWIztFSYGN7GeoRg= github.com/mitchellh/mapstructure v1.3.2/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= -github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= -github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= -github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= -github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/montanaflynn/stats v0.0.0-20171201202039-1bf9dbcd8cbe/go.mod h1:wL8QJuTMNUDYhXwkmfOly8iTdp5TEcJFWZD2D7SIkUc= -github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= -github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= -github.com/nats-io/jwt v0.3.0/go.mod h1:fRYCDE99xlTsqUzISS1Bi75UBJ6ljOJQOAAu5VglpSg= -github.com/nats-io/jwt v0.3.2/go.mod h1:/euKqTS1ZD+zzjYrY7pseZrTtWQSjujC7xjPc8wL6eU= -github.com/nats-io/nats-server/v2 v2.1.2/go.mod h1:Afk+wRZqkMQs/p45uXdrVLuab3gwv3Z8C4HTBu8GD/k= -github.com/nats-io/nats.go v1.9.1/go.mod h1:ZjDU1L/7fJ09jvUSRVBR2e7+RnLiiIQyqyzEE/Zbp4w= -github.com/nats-io/nkeys v0.1.0/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxziKVo7w= -github.com/nats-io/nkeys v0.1.3/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxziKVo7w= -github.com/nats-io/nuid v1.0.1/go.mod h1:19wcPz3Ph3q0Jbyiqsd0kePYG7A95tJPxeL+1OSON2c= github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e h1:fD57ERR4JtEqsWbfPhv4DMiApHyliiK5xCTNVSPiaAs= github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= -github.com/oklog/oklog v0.3.2/go.mod h1:FCV+B7mhrz4o+ueLpx+KqkyXRGMWOYEvfiXtdGtbWGs= -github.com/oklog/run v1.0.0/go.mod h1:dlhp/R75TPv97u0XWUtDeV/lRKWPKSdTuV0TZvrmrQA= -github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U= -github.com/olekukonko/tablewriter v0.0.0-20170122224234-a0225b3f23b5/go.mod h1:vsDQFd/mU46D+Z4whnwzcISnGGzXWMclvtLoiIKAKIo= -github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/ginkgo v1.7.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/gomega v1.4.3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= -github.com/op/go-logging v0.0.0-20160315200505-970db520ece7/go.mod h1:HzydrMdWErDVzsI23lYNej1Htcns9BCg93Dk0bBINWk= -github.com/opentracing-contrib/go-observer v0.0.0-20170622124052-a52f23424492/go.mod h1:Ngi6UdF0k5OKD5t5wlmGhe/EDKPoUM3BXZSSfIuJbis= -github.com/opentracing/basictracer-go v1.0.0/go.mod h1:QfBfYuafItcjQuMwinw9GhYKwFXS9KnPs5lxoYwgW74= -github.com/opentracing/opentracing-go v1.0.2/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= -github.com/opentracing/opentracing-go v1.1.0/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= github.com/opentracing/opentracing-go v1.2.0 h1:uEJPy/1a5RIPAJ0Ov+OIO8OxWu77jEv+1B0VhjKrZUs= github.com/opentracing/opentracing-go v1.2.0/go.mod h1:GxEUsuufX4nBwe+T+Wl9TAgYrxe9dPLANfrWvHYVTgc= -github.com/openzipkin-contrib/zipkin-go-opentracing v0.4.5/go.mod h1:/wsWhb9smxSfWAKL3wpBW7V8scJMt8N8gnaMCS9E/cA= -github.com/openzipkin/zipkin-go v0.1.6/go.mod h1:QgAqvLzwWbR/WpD4A3cGpPtJrZXNIiJc5AZX7/PBEpw= -github.com/openzipkin/zipkin-go v0.2.1/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnhQw8ySjnjRyN4= -github.com/openzipkin/zipkin-go v0.2.2/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnhQw8ySjnjRyN4= -github.com/pact-foundation/pact-go v1.0.4/go.mod h1:uExwJY4kCzNPcHRj+hCR/HBbOOIwwtUjcrb0b5/5kLM= -github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pborman/uuid v1.2.0/go.mod h1:X/NO0urCmaxf9VXbdlT7C2Yzkj2IKimNn4k+gtPdI/k= -github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= -github.com/pelletier/go-toml v1.4.0 h1:u3Z1r+oOXJIkxqw34zVhyPgjBsm6X2wn21NWs/HfSeg= github.com/pelletier/go-toml v1.4.0/go.mod h1:PN7xzY2wHTK0K9p34ErDQMlFxa51Fk0OUruD3k1mMwo= -github.com/performancecopilot/speed v3.0.0+incompatible/go.mod h1:/CLtqpZ5gBg1M9iaPbIdPPGyKcA8hKdoy6hAWba7Yac= -github.com/pierrec/lz4 v1.0.2-0.20190131084431-473cd7ce01a1/go.mod h1:3/3N9NVKO0jef7pBehbT1qWhCMrIgbYNnFAZCqQ5LRc= -github.com/pierrec/lz4 v2.0.5+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= -github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= -github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= -github.com/pkg/profile v1.2.1/go.mod h1:hJw3o1OdXxsrSjjVksARp5W95eeEaEfptyVZyv6JUPA= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI= -github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= -github.com/prometheus/client_golang v0.9.3-0.20190127221311-3c4408c8b829/go.mod h1:p2iRAGwDERtqlqzRXnrOVns+ignqQo//hLXqYxZYVNs= -github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso= -github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo= -github.com/prometheus/client_golang v1.3.0/go.mod h1:hJaj2vgQTGQmVCsAACORcieXFeDPbaTKGT+JTgUa3og= -github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M= -github.com/prometheus/client_golang v1.9.0 h1:Rrch9mh17XcxvEu9D9DEpb4isxjGBtcevQjKvxPRQIU= -github.com/prometheus/client_golang v1.9.0/go.mod h1:FqZLKOZnGdFAhOK4nqGHa7D66IdsO+O441Eve7ptJDU= -github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= -github.com/prometheus/client_model v0.0.0-20190115171406-56726106282f/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= -github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= -github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= -github.com/prometheus/client_model v0.1.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= -github.com/prometheus/client_model v0.2.0 h1:uq5h0d+GuxiXLJLNABMgp2qUWDPiLvgCzz2dUR+/W/M= -github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= -github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro= -github.com/prometheus/common v0.2.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= -github.com/prometheus/common v0.4.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= -github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= -github.com/prometheus/common v0.7.0/go.mod h1:DjGbpBbp5NYNiECxcL/VnbXCCaQpKd3tt26CguLLsqA= -github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo= -github.com/prometheus/common v0.15.0 h1:4fgOnadei3EZvgRwxJ7RMpG1k1pOZth5Pc13tyspaKM= -github.com/prometheus/common v0.15.0/go.mod h1:U+gB1OBLb1lF3O42bTCL+FK18tX9Oar16Clt/msog/s= -github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= -github.com/prometheus/procfs v0.0.0-20190117184657-bf6a532e95b1/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= -github.com/prometheus/procfs v0.0.0-20190507164030-5867b95ac084/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= -github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= -github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= -github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= -github.com/prometheus/procfs v0.2.0 h1:wH4vA7pcjKuZzjF7lM8awk4fnuJO6idemZXoKnULUx4= -github.com/prometheus/procfs v0.2.0/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= -github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU= -github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= -github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= github.com/rogpeppe/go-internal v1.1.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= github.com/rogpeppe/go-internal v1.2.2/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= -github.com/rs/cors v1.7.0 h1:+88SsELBHx5r+hZ8TCkggzSstaWNbDvThkVK8H6f9ik= -github.com/rs/cors v1.7.0/go.mod h1:gFx+x8UowdsKA9AchylcLynDq+nNFfI8FkUZdN/jGCU= -github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= -github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= -github.com/samuel/go-zookeeper v0.0.0-20190923202752-2cc03de413da/go.mod h1:gi+0XIa01GRL2eRQVjQkKGqKF3SF9vZR/HnPullcV2E= -github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= -github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc= -github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/sirupsen/logrus v1.4.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/sirupsen/logrus v1.4.1/go.mod h1:ni0Sbl8bgC9z8RoU9G6nDWqqs/fq4eDPysMBDgk/93Q= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= -github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= -github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d h1:zE9ykElWQ6/NYmHa3jpm/yHnI4xSofP+UP6SpjHcSeM= -github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= -github.com/smartystreets/goconvey v1.6.4 h1:fv0U8FUIMPNf1L9lnHLvLhgicrIVChEkdzIKYqbNC9s= -github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= -github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM= -github.com/sony/gobreaker v0.4.1/go.mod h1:ZKptC7FHNvhBz7dN2LGjPVBz2sZJmc0/PkyDJOjmxWY= -github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= -github.com/spf13/afero v1.1.2 h1:m8/z1t7/fwjysjQRYbP0RD+bUIF/8tJwPdEZsI83ACI= -github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ= -github.com/spf13/cast v1.3.0 h1:oget//CVOEoFewqQxwr0Ej5yjygnqGkvggSE/gB35Q8= -github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ= -github.com/spf13/jwalterweatherman v1.0.0 h1:XHEdyB+EcvlqZamSM4ZOMGlc93t6AcsBEu9Gc1vn7yk= -github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo= -github.com/spf13/pflag v1.0.1/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= -github.com/spf13/pflag v1.0.3 h1:zPAT6CGy6wXeQ7NtTnaTerfKOsV6V6F8agHXFiazDkg= github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= -github.com/spf13/viper v1.7.1 h1:pM5oEahlgWv/WnHXpgbKz7iLIxRf65tye2Ci+XFK5sk= -github.com/spf13/viper v1.7.1/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg= -github.com/streadway/amqp v0.0.0-20190404075320-75d898a42a94/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= -github.com/streadway/amqp v0.0.0-20190827072141-edfb9018d271/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= -github.com/streadway/handy v0.0.0-20190108123426-d5acb3125c2a/go.mod h1:qNTQ5P5JnDBl6z3cMAg/SywNDC5ABu5ApDIw6lUbRmI= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE= @@ -463,247 +167,67 @@ github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UV github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= github.com/stretchr/testify v1.6.1 h1:hDPOHmpOpP40lSULcqw7IrRb/u7w6RpDC9399XyoNd0= github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/subosito/gotenv v1.2.0 h1:Slr1R9HxAlEKefgq5jn9U+DnETlIUa6HfgEzj0g5d7s= -github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= -github.com/taxnexus/go-force v1.0.7 h1:AhfmLToq3XIq5SkaC621uPu9kGjyTxwDi2k5XxuWws0= -github.com/taxnexus/go-force v1.0.7/go.mod h1:lJDnynWzSMNjYWpPzAMX4gGy+nwDxBFgdHd4z0U1BG0= github.com/tidwall/pretty v1.0.0 h1:HsD+QiTn7sK6flMKIvNmpqz1qrpP3Ps6jOKIKMooyg4= github.com/tidwall/pretty v1.0.0/go.mod h1:XNkn88O1ChpSDQmQeStsy+sBenx6DDtFZJxhVysOjyk= -github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= -github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= -github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA= -github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= github.com/xdg/scram v0.0.0-20180814205039-7eeb5667e42c/go.mod h1:lB8K/P019DLNhemzwFU4jHLhdvlE6uDZjXFejJXr49I= github.com/xdg/stringprep v0.0.0-20180714160509-73f8eece6fdc/go.mod h1:Jhud4/sHMO4oL310DaZAKk9ZaJ08SJfe+sJh0HrGL1Y= -github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= -go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= -go.etcd.io/bbolt v1.3.3/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= -go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738/go.mod h1:dnLIgRNXwCJa5e+c6mIZCrds/GIG4ncV9HhK5PX7jPg= go.mongodb.org/mongo-driver v1.0.3/go.mod h1:u7ryQJ+DOzQmeO7zB6MHyr8jkEQvC8vH7qLUO4lqsUM= go.mongodb.org/mongo-driver v1.1.1/go.mod h1:u7ryQJ+DOzQmeO7zB6MHyr8jkEQvC8vH7qLUO4lqsUM= go.mongodb.org/mongo-driver v1.3.0/go.mod h1:MSWZXKOynuguX+JSvwP8i+58jYCXxbia8HS3gZBapIE= go.mongodb.org/mongo-driver v1.3.4 h1:zs/dKNwX0gYUtzwrN9lLiR15hCO0nDwQj5xXx+vjCdE= go.mongodb.org/mongo-driver v1.3.4/go.mod h1:MSWZXKOynuguX+JSvwP8i+58jYCXxbia8HS3gZBapIE= -go.opencensus.io v0.20.1/go.mod h1:6WKK9ahsWS3RSO+PY9ZHZUfv2irvY6gN279GOPZjmmk= -go.opencensus.io v0.20.2/go.mod h1:6WKK9ahsWS3RSO+PY9ZHZUfv2irvY6gN279GOPZjmmk= -go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= -go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= -go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= -go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= -go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= -go.uber.org/atomic v1.5.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= -go.uber.org/atomic v1.6.0 h1:Ezj3JGmsOnG1MoRWQkPBsKLe9DwWD9QeXzTRzzldNVk= -go.uber.org/atomic v1.6.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= -go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= -go.uber.org/multierr v1.3.0/go.mod h1:VgVr7evmIr6uPjLBxg28wmKNXyqE9akIJ5XnfpiKl+4= -go.uber.org/multierr v1.5.0 h1:KCa4XfM8CWFCpxXRGok+Q0SS/0XBhMDbHHGABQLvD2A= -go.uber.org/multierr v1.5.0/go.mod h1:FeouvMocqHpRaaGuG9EjoKcStLC43Zu/fmqdUMPcKYU= -go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee h1:0mgffUl7nfd+FpvXMVz4IDEaUSmT1ysygQC7qYo7sG4= -go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee/go.mod h1:vJERXedbb3MVM5f9Ejo0C68/HhF8uaILCdgjnY+goOA= -go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= -go.uber.org/zap v1.13.0/go.mod h1:zwrFLgMcdUuIBviXEYEH1YKNaOBnKXsx2IPda5bBwHM= -go.uber.org/zap v1.16.0 h1:uFRZXykJGK9lLY4HtgSw44DnIcAM+kRBP7x5m+NpAOM= -go.uber.org/zap v1.16.0/go.mod h1:MA8QOfq0BHJwdXa996Y4dYkAqRKB8/1K1QMMZVaNZjQ= golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= -golang.org/x/crypto v0.0.0-20181029021203-45a5f77698d3/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190320223903-b7391e95e576/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190422162423-af44ce270edf/go.mod h1:WFFai1msRO1wXaEeE5yQxYXgSfI8pQAWXbQop6sCtWE= -golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190530122614-20be4c3c3ed5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190617133340-57b3e21c3d56/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= -golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= -golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= -golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek= -golang.org/x/exp v0.0.0-20191030013958-a1ab85dbe136/go.mod h1:JXzH8nQsPlswgeRAPE3MuO9GYsAcnJvJ4vnMwN/5qkY= -golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= -golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= -golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= -golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= -golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= -golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= -golang.org/x/lint v0.0.0-20190409202823-959b441ac422/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= -golang.org/x/lint v0.0.0-20190909230951-414d861bb4ac/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= -golang.org/x/lint v0.0.0-20190930215403-16217165b5de h1:5hukYrvBGR8/eNkX5mdUezrA6JiaEZDtJb9Ei+1LlBs= -golang.org/x/lint v0.0.0-20190930215403-16217165b5de/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= -golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE= -golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o= -golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc= -golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY= -golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= -golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20181005035420-146acd28ed58/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20181023162649-9b4f9f5ad519/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20181201002055-351d144fa1fc/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20181220203305-927f97764cc3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190125091013-d26f9f9a57f3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190320064053-1272bf9dcd53/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks= golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20200520182314-0ba52f642ac2/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= golang.org/x/net v0.0.0-20200602114024-627f9648deb9/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= golang.org/x/net v0.0.0-20200625001655-4c5254603344 h1:vGXIOMxbNfDTk/aXCmfdLgkrSV+Z2tcbze+pEc3v5W4= golang.org/x/net v0.0.0-20200625001655-4c5254603344/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= -golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= -golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= -golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= -golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190412183630-56d357773e84/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20181122145206-62eef0e2fa9b/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190321052220-f7bb7a8bee54/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190403152447-81d4e9dc473e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190419153524-e8e3143a4f4a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190531175056-4c3a928424d2/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190616124812-15dcb6c0061f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191220142924-d4481acd189f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200106162015-b016eb3dc98e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200625212154-ddb9806d33ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20201214210602-f9fddec55a1e h1:AyodaIpKjppX+cBfTASF2E1US3H2JFBj920Ot3rtDjs= -golang.org/x/sys v0.0.0-20201214210602-f9fddec55a1e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= -golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2 h1:tW2bmiBqwgJj/UpqtC8EpXEZVYOwU0yG4iWbprSVAcs= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= -golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/tools v0.0.0-20180221164845-07fd8470d635/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20180828015842-6cd1fcedba52/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= -golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190329151228-23e29df326fe/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190416151739-9c9e1878f421/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190420181800-aa740d480789/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= -golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= -golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190531172133-b3315ee88b7d/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= -golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190614205625-5aca471b1d59/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190617190820-da514acc4774/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= -golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= -golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= -golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20191012152004-8de300cfc20a/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20191029041327-9cc4af7d6b2c/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20191029190741-b9c20aec41a5/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20191112195655-aa38f8e97acc/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20200103221440-774c71fcf114 h1:DnSr2mCsxyCE6ZgIkmcWUQY2R5cH/6wL7eIxEmQOMSE= -golang.org/x/tools v0.0.0-20200103221440-774c71fcf114/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -google.golang.org/api v0.3.1/go.mod h1:6wY9I6uQWHQ8EM57III9mq/AjF+i8G65rmVagqKMtkk= -google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= -google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= -google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= -google.golang.org/api v0.9.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= -google.golang.org/api v0.13.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI= -google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= -google.golang.org/appengine v1.2.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= -google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= -google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= -google.golang.org/appengine v1.6.1 h1:QzqyMA1tlu6CgqCDUtU9V+ZKhLFT2dkJuANu5QaxI3I= -google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0= -google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= -google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= -google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= -google.golang.org/genproto v0.0.0-20190425155659-357c62f0e4bb/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= -google.golang.org/genproto v0.0.0-20190502173448-54afdca5d873/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= -google.golang.org/genproto v0.0.0-20190530194941-fb225487d101/go.mod h1:z3L6/3dTEVtUr6QSP8miRzeRqwQOioJ9I66odjN4I7s= -google.golang.org/genproto v0.0.0-20190801165951-fa694d86fc64/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= -google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= -google.golang.org/genproto v0.0.0-20190911173649-1774047e7e51/go.mod h1:IbNlFCBrqXvoKpeg0TB2l7cyZUmoaFKYIwrEpbDKLA8= -google.golang.org/genproto v0.0.0-20191108220845-16a3f7862a1a/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= -google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= -google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= -google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= -google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= -google.golang.org/grpc v1.21.0/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= -google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= -google.golang.org/grpc v1.22.1/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= -google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= -google.golang.org/grpc v1.23.1/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= -google.golang.org/grpc v1.26.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= -google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= -google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= -google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= -google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE= -google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo= -google.golang.org/protobuf v1.23.0 h1:4MY060fB1DLGMB/7MBTLnwQUY6+F09GEiz6SsrNqyzM= -google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f h1:BLraFXnmrev5lT+xlilqcH8XK9/i0At2xKjWk4p6zsU= gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/cheggaaa/pb.v1 v1.0.25/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qStrOgw= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= -gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= -gopkg.in/gcfg.v1 v1.2.3/go.mod h1:yesOnuUOFQAhST5vPY4nbZsb/huCgGGXlipJsBn0b3o= -gopkg.in/ini.v1 v1.51.0 h1:AQvPpx3LzTDM0AjnIRlVFwFFGC+npRopjZxLJj6gdno= -gopkg.in/ini.v1 v1.51.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= -gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo= -gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= -gopkg.in/warnings.v0 v0.1.2/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI= -gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74= gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.2.5/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.3.0 h1:clyUAQHOM3G0M3f5vQj7LuJrETvjVot3Z5el9nffUtU= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= @@ -711,13 +235,3 @@ gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C gopkg.in/yaml.v3 v3.0.0-20200605160147-a5ece683394c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776 h1:tQIYjPdBoyREyB9XMu+nnTclpTYkz2zFM+lzLJFO4gQ= gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -honnef.co/go/tools v0.0.1-2019.2.3 h1:3JgtbtFHMiCmsznwGVTUWbgGov+pVqnlf1dEJTNAXeM= -honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= -rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= -sigs.k8s.io/yaml v1.1.0/go.mod h1:UJmg0vDUVViEyp3mgSv9WPwZCDxu4rQW1olrI1uml+o= -sourcegraph.com/sourcegraph/appdash v0.0.0-20190731080439-ebfcffb1b5c0/go.mod h1:hI742Nqp5OhwiqlzhgfbWU4mW4yO10fP+LoT9WOswdU= diff --git a/swagger/auth-telnexus.yaml b/swagger/auth-kvision.yaml similarity index 94% rename from swagger/auth-telnexus.yaml rename to swagger/auth-kvision.yaml index c5f84c4..ec59ded 100644 --- a/swagger/auth-telnexus.yaml +++ b/swagger/auth-kvision.yaml @@ -1,13 +1,13 @@ swagger: "2.0" info: - version: 0.0.2 + version: "0.0.1" title: "auth" description: "Authentication Microservice" - termsOfService: "http://telnexus.com/terms/" + termsOfService: "http://taxnexus.net/terms/" contact: - email: "noc@telnexus.com" + email: "noc@taxnexus.net" license: - name: "Proprietary - Copyright (c) 2018-2020 by Telnexus LLC" + name: "Proprietary - Copyright (c) 2018-2021 by Taxnexus, Inc." securityDefinitions: ApiKeyAuth: type: "apiKey" @@ -18,7 +18,7 @@ security: schemes: - "http" basePath: "/v1" -host: "auth.infra.tnxs.net:8080" +host: "auth.vernonkeenan.com:8080" consumes: - "application/json" produces: @@ -51,7 +51,7 @@ responses: schema: $ref: "#/definitions/Error" UserResponse: - description: Telnexus Response with User objects + description: Taxnexus Response with User objects schema: $ref: "#/definitions/UserResponse" paths: @@ -145,9 +145,9 @@ definitions: ServerTimestamp: description: Backend Server Timestamp type: string - TelnexusAccount: + TaxnexusAccount: description: - Telnexus Account Number used for recording transactions + Taxnexus Account Number used for recording transactions type: string type: object User: @@ -224,7 +224,7 @@ definitions: description: Full Photo URL type: string ID: - description: Telnexus ID + description: Taxnexus ID type: string IsActive: description: Active @@ -298,8 +298,8 @@ definitions: StartOfDay: description: The time day starts type: string - TelnexusAccount: - description: Telnexus Account + TaxnexusAccount: + description: Taxnexus Account type: string TenantID: description: Tenant ID associated with this user @@ -329,7 +329,7 @@ definitions: type: array type: object UserResponse: - description: An array Telnexus user objects + description: An array Taxnexus user objects properties: Data: items: @@ -366,8 +366,8 @@ definitions: RoleName: description: Role Name type: string - TelnexusAccount: - description: Telnexus Account Number + TaxnexusAccount: + description: Taxnexus Account Number type: string UserEmail: description: User Email Address @@ -400,8 +400,8 @@ definitions: CompanyName: description: Account Name type: string - TelnexusAccount: - description: Telnexus Account + TaxnexusAccount: + description: Taxnexus Account type: string TenantActive: description: Tenant active? diff --git a/swagger/auth0.yaml b/swagger/auth0.yaml new file mode 100644 index 0000000..e22032f --- /dev/null +++ b/swagger/auth0.yaml @@ -0,0 +1,494 @@ +swagger: "2.0" +info: + version: "1.2.7" + title: "auth0" + description: "Auth0 Swagger Definition" + termsOfService: "http://taxnexus.net/terms/" + contact: + email: "noc@taxnexus.net" + license: + name: "Proprietary - Copyright (c) 2018-2020 by Taxnexus, Inc." +schemes: + - "https" +host: "taxnexus.auth0.com" +consumes: + - "application/json" +produces: + - "application/json" +parameters: + CredentialsRequest: + name: CredentialsRequest + in: body + required: true + description: Get Authentation Token + schema: + $ref: "#/definitions/CredentialsRequest" + email: + name: email + in: query + type: string + required: true + authHeader: + name: Authorization + in: header + type: string + required: true + UserRequest: + description: An array of User records + in: body + name: UserRequest + required: true + schema: + $ref: "#/definitions/UserRequest" + RoleUsersRequest: + description: An array of User IDs to add to a Role + in: body + name: RoleUsersRequest + required: true + schema: + $ref: "#/definitions/RoleUsersRequest" + UserRolesRequest: + description: An array of User IDs to add to a Role + in: body + name: UserRolesRequest + required: true + schema: + $ref: "#/definitions/UserRolesRequest" + roleId: + name: roleId + description: An Auth0 Role ID + type: string + in: path + required: true + userId: + name: userId + description: An Auth0 User ID + type: string + in: path + required: true +responses: + AccessForbidden: + description: "Access forbidden, account lacks access" + schema: + $ref: "#/definitions/Error" + NotFound: + description: Resource was not found + schema: + $ref: "#/definitions/Error" + ServerError: + description: Server Internal Error + schema: + $ref: "#/definitions/Error" + Unauthorized: + description: "Access Unauthorized, invalid API-KEY was used" + schema: + $ref: "#/definitions/Error" + UnprocessableEntity: + description: "Unprocessable Entity, likely a bad parameter" + schema: + $ref: "#/definitions/Error" + UserResponse: + description: Taxnexus Response with User objects + schema: + items: + $ref: "#/definitions/User" + type: array + RoleResponse: + description: Taxnexus Response with User objects + schema: + $ref: "#/definitions/RoleResponse" + CredentialsResponse: + description: Credentials response from Auth0 + schema: + $ref: "#/definitions/CredentialsResponse" +paths: + /oauth/token: + post: + summary: post to /oauth/token + operationId: postCredentials + description: Get credential token + parameters: + - $ref: "#/parameters/CredentialsRequest" + tags: + - Auth + responses: + "200": + $ref: "#/responses/CredentialsResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + /api/v2/roles: + get: + summary: Get Roles from Auth0 + operationId: getRoles + description: Get Roles from Auth0 + tags: + - Role + parameters: + - $ref: "#/parameters/authHeader" + responses: + "200": + $ref: "#/responses/UserResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + /api/v2/roles/{roleId}/users: + post: + summary: Add users to role + operationId: postRoleUsers + description: Add users to role + parameters: + - $ref: "#/parameters/authHeader" + - $ref: "#/parameters/RoleUsersRequest" + - $ref: "#/parameters/roleId" + tags: + - Role + responses: + "200": + description: Role users successfully updated + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "500": + $ref: "#/responses/ServerError" + /api/v2/users/{userId}/roles: + delete: + parameters: + - $ref: "#/parameters/authHeader" + - $ref: "#/parameters/userId" + - $ref: "#/parameters/UserRolesRequest" + tags: + - User + responses: + "204": + description: User roles successfully removed + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "500": + $ref: "#/responses/ServerError" + get: + summary: Get a User's Roles + description: Get a User's Roles + operationId: getUserRoles + parameters: + - $ref: "#/parameters/authHeader" + - $ref: "#/parameters/userId" + tags: + - User + responses: + "200": + $ref: "#/responses/RoleResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "500": + $ref: "#/responses/ServerError" + /api/v2/users: + get: + summary: Get all users from Auth0 + operationId: getUsers + description: Get all users from Auth0 + parameters: + - $ref: "#/parameters/authHeader" + tags: + - User + responses: + "200": + $ref: "#/responses/UserResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "500": + $ref: "#/responses/ServerError" + /api/v2/users-by-email: + get: + summary: Get a single user from Auth0 by Email Address + operationId: getUserByEmail + description: Get a single user from Auth0 by Email Address + parameters: + - $ref: "#/parameters/authHeader" + - $ref: "#/parameters/email" + tags: + - User + responses: + "200": + $ref: "#/responses/UserResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "500": + $ref: "#/responses/ServerError" + post: + summary: Create new Auth0 user + operationId: postUsers + description: create new Auth0 user + parameters: + - $ref: "#/parameters/authHeader" + - $ref: "#/parameters/UserRequest" + tags: + - User + responses: + "201": + description: New user created + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "409": + description: User already exists + "500": + $ref: "#/responses/ServerError" +definitions: + Error: + properties: + code: + format: int32 + type: integer + fields: + type: string + message: + type: string + type: object + Role: + properties: + id: + type: "string" + example: "rol_oWVoMn2Zx2qDSGUL" + name: + type: "string" + example: "Developer" + description: + type: "string" + example: "Taxnexus API Developer" + type: "object" + RoleResponse: + type: object + properties: + roles: + type: array + items: + $ref: "#/definitions/Role" + RoleUsersRequest: + properties: + users: + type: array + items: + type: string + UserRolesRequest: + properties: + roles: + type: array + items: + type: string + CredentialsRequest: + type: object + properties: + client_id: + type: string + client_secret: + type: string + audience: + type: string + grant_type: + type: string + CredentialsResponse: + type: object + properties: + access_token: + type: string + scope: + type: string + expires_in: + type: number + format: int64 + token_type: + format: string + NewUser: + type: object + properties: + email: + type: "string" + example: "john.doe@gmail.com" + phone_number: + type: "string" + example: "+199999999999999" + blocked: + type: "boolean" + example: false + email_verified: + type: "boolean" + example: false + phone_verified: + type: "boolean" + example: false + given_name: + type: "string" + example: "John" + family_name: + type: "string" + example: "Doe" + name: + type: "string" + example: "John Doe" + nickname: + type: "string" + example: "Johnny" + picture: + type: "string" + example: "https://secure.gravatar.com/avatar/15626c5e0c749cb912f9d1ad48dba440?s=480&r=pg&d=https%3A%2F%2Fssl.gstatic.com%2Fs2%2Fprofiles%2Fimages%2Fsilhouette80.png" + user_id: + type: "string" + example: "abc" + connection: + type: "string" + example: "Initial-Connection" + password: + type: "string" + example: "secret" + verify_email: + type: "boolean" + example: false + username: + type: "string" + example: "johndoe" + User: + properties: + email: + type: "string" + example: "vern@taxnexus.net" + email_verified: + type: "boolean" + example: true + user_id: + type: "string" + example: "auth0|5b180537157859716f2c9df5" + picture: + type: "string" + example: "https://s.gravatar.com/avatar/a08710b8d49416c729a0da8a9c34cdb0?s=480&r=pg&d=https%3A%2F%2Fcdn.auth0.com%2Favatars%2Fve.png" + nickname: + type: "string" + example: "vern" + identities: + type: "array" + items: + type: "object" + properties: + connection: + type: "string" + example: "Username-Password-Authentication" + provider: + type: "string" + example: "auth0" + user_id: + type: "string" + example: "5b180537157859716f2c9df5" + isSocial: + type: "boolean" + example: false + updated_at: + type: "string" + example: "2020-09-22T19:19:02.706Z" + created_at: + type: "string" + example: "2018-06-06T16:00:55.930Z" + name: + type: "string" + example: "Vernon Keenan" + last_password_reset: + type: "string" + example: "2020-09-21T00:11:47.397Z" + multifactor_last_modified: + type: "string" + example: "2020-09-21T00:30:34.081Z" + family_name: + type: "string" + example: "Keenan" + given_name: + type: "string" + example: "Vernon" + user_metadata: + properties: + taxnexus_email: + type: "string" + example: "vern@taxnexus.net" + taxnexus_firstname: + type: "string" + example: "Vernon" + taxnexus_fullname: + type: "string" + example: "Vernon Keenan" + taxnexus_lastname: + type: "string" + example: "Keenan" + taxnexus_phone: + type: "string" + example: "+15106791900" + type: "object" + app_metadata: + properties: + taxnexus_account_id: + type: "string" + example: "7f661ca6-ae4a-486f-9c3c-cd292685a46d" + taxnexus_contact_id: + type: "string" + example: "9f79dca8-e875-4e2b-a5ad-001a3d32e83d" + taxnexus_user_id: + type: "string" + example: "f04da03d-70ad-46df-a46c-a676388aadd7" + roles: + type: "array" + items: + type: "string" + example: + - "login" + type: "object" + last_ip: + type: "string" + example: "67.188.106.161" + last_login: + type: "string" + example: "2020-09-22T19:19:02.706Z" + logins_count: + type: "number" + example: 178 + format: int64 + UserRequest: + description: An array Auth0 new user objects + properties: + users: + items: + $ref: "#/definitions/NewUser" + type: array + type: object diff --git a/swagger/board-kvision.yaml b/swagger/board-kvision.yaml new file mode 100644 index 0000000..a4e6c83 --- /dev/null +++ b/swagger/board-kvision.yaml @@ -0,0 +1,1434 @@ +swagger: "2.0" +info: + description: Taxnexus Onboarding Service + title: board + termsOfService: "http://taxnexus.net/terms/" + contact: + email: noc@taxnexus.net + license: + name: "Proprietary - Copyright (c) 2018-2021 by Taxnexus, Inc." + version: 0.0.1 +schemes: + - http +host: "board.vernonkeenan.com:8080" +basePath: /v1 +produces: + - application/json +paths: + /developers: + options: + description: CORS support + operationId: developerOptions + responses: + "200": + $ref: "#/responses/CORSResponse" + tags: + - cors + post: + security: + - ApiKeyAuth: [] + consumes: + - application/json + description: Register new developers with POST + operationId: postDevelopers + parameters: + - $ref: "#/parameters/developerRequest" + responses: + "200": + $ref: "#/responses/DeveloperResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + summary: Onboard new developer + tags: + - Developers + /iqs: + options: + description: CORS support + operationId: iqOptions + responses: + "200": + $ref: "#/responses/CORSResponse" + tags: + - cors + post: + security: + - ApiKeyAuth: [] + consumes: + - application/json + description: Register new Taxnexus IQ Customer with POST + operationId: postIQ + parameters: + - $ref: "#/parameters/iqRequest" + responses: + "200": + $ref: "#/responses/IqResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + summary: Onboard new new Taxnexus IQ Customer + tags: + - Iq + /leads: + options: + description: CORS support + operationId: leadsOptions + responses: + "200": + $ref: "#/responses/CORSResponse" + tags: + - cors + post: + consumes: + - application/json + description: Add a new full Lead Record + operationId: postLeads + parameters: + - $ref: "#/parameters/leadRequest" + responses: + "200": + $ref: "#/responses/LeadResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + security: + - ApiKeyAuth: [] + summary: Add a new Lead record + tags: + - Leads + put: + description: Update Lead records + operationId: putLeads + parameters: + - $ref: "#/parameters/leadRequest" + responses: + "200": + $ref: "#/responses/LeadResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + security: + - ApiKeyAuth: [] + summary: Update Leads + tags: + - Leads + /userauths: + options: + description: CORS support + operationId: userAuthOptions + responses: + "200": + $ref: "#/responses/CORSResponse" + tags: + - cors + "/userauths/{usernamePath}": + get: + description: + Return a single UserAuth object from datastore as a Singleton + operationId: getUserAuth + parameters: + - $ref: "#/parameters/usernamePath" + responses: + "200": + $ref: "#/responses/UserAuthResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + security: + - ApiKeyAuth: [] + summary: Get a single UserAuth object + tags: + - UserAuth + /users: + get: + description: Get a clean user record + operationId: getUsers + parameters: + - $ref: "#/parameters/emailQueryRequired" + responses: + "200": + $ref: "#/responses/UserResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + security: + - ApiKeyAuth: [] + tags: + - Users + options: + description: CORS support + operationId: userOptions + responses: + "200": + $ref: "#/responses/CORSResponse" + tags: + - cors +definitions: + Account: + properties: + AccountNumber: + description: Account Number + type: string + AccountSource: + description: The marketing orgin of this account + type: string + Active: + description: Active + type: boolean + AdministrativeLevel: + description: + "For tax authorities, this account's administrative level, + e.g. Local, County, State or Federal" + type: string + Amount: + description: Rollup Tax Amount + format: double + type: number + AmountInvoiced: + description: Amount Invoiced + format: double + type: number + AmountPaid: + description: Amount Paid + format: double + type: number + AnnualRevenue: + description: Annual Revenue Estimate + format: double + type: number + Balance: + description: Account Balance + format: double + type: number + BillingAddress: + $ref: "#/definitions/Address" + BillingContactID: + description: Contact ID + type: string + BillingPreference: + description: Billing Preference + type: string + BusinessAddress: + $ref: "#/definitions/Address" + CannabisCustomer: + description: Is this a cannabis customer? + type: boolean + ChannelProgramLevelName: + description: Channel Program Level Name + type: string + ChannelProgramName: + description: Channel Program Name + type: string + ClientEndDate: + description: Client End Date + type: string + ClientStartDate: + description: Client Start Date + type: string + CompanyID: + description: The Company ID of this Account + type: string + CoordinateID: + description: The Id of the geo coordinates of this account + type: string + CreatedByID: + description: Created By User ID + type: string + CreatedDate: + description: Created Date + type: string + CustomerID: + description: Customer ID from source system + type: string + CustomerPriority: + description: Customer Priority + type: string + DBA: + description: This Account's 'Doing Business As' name + type: string + DUNSNumber: + description: D-U-N-S Number + type: string + DandBCompanyID: + description: D-n-B Company + type: string + DefaultAddress: + $ref: "#/definitions/Address" + DefaultBackendID: + description: Default Backend ID + type: string + DefaultDeliveryContactID: + description: Default Delivery Address Contact ID + type: string + DefaultEndUserID: + description: Default End User Contact ID + type: string + Description: + description: Description + type: string + EIN: + description: EIN + type: string + Email: + description: Main Account Email + type: string + EnrollmentStatus: + description: Enrollment Status + type: string + Fax: + description: Fax + type: string + ID: + description: Taxnexus Account Id + type: string + ISPCustomer: + description: ISP Customer? + type: boolean + Industry: + description: Industry + type: string + IsCustomerPortal: + description: Customer Portal Account + type: boolean + IsPartner: + description: Partner Account + type: boolean + JigSaw: + description: Data.com Key + type: string + LastModifiedByID: + description: Last Modified By User ID + type: string + LastModifiedDate: + description: Last Modified Date + type: string + MSPCustomer: + description: MSP Customer? + type: boolean + NAICSCode: + description: NAICS Code + type: string + NAICSDesc: + description: NAICS Description + type: string + Name: + description: Account Name + type: string + NumberOfEmployees: + description: Employee Count Estimate + format: int64 + type: number + NumberOfLocations: + description: Number of Locations Estimate + format: int64 + type: number + OpenCharges: + description: Open Charges + format: double + type: number + OrderContactID: + description: Vendor Order Contact ID + type: string + OrderEmail: + description: Order Email + type: string + OwnerID: + description: Account Owner User ID + type: string + Ownership: + description: Ownership + type: string + ParentFK: + description: Parent Foreign Key + type: string + ParentID: + description: Parent Account + type: string + Phone: + description: Phone + type: string + PlaceID: + description: + The ID of the Place situs record that applies to this Account + type: string + PreparerID: + description: Tax Preparer Contact ID + type: string + Rating: + description: Rating + type: string + RatingEngineID: + description: Rating Engine identifier + type: string + Ref: + description: External Reference ID + type: string + RevenueBase: + description: Rollup Revenue Base + format: double + type: number + RevenueNet: + description: Rollup Revenue Net + format: double + type: number + RevenueNotTaxable: + description: Rollup Revenue Not Taxable + format: double + type: number + SIC: + description: SIC Code + type: string + SICDesc: + description: SIC Description + type: string + ShippingAddress: + $ref: "#/definitions/Address" + ShippingCensusTract: + description: Shipping Census Tract + type: string + ShippingConactID: + description: Shipping Contact ID + type: string + ShippingCounty: + description: Shipping County + type: string + Site: + description: Account Site + type: string + Status: + description: Account Status + type: string + TaxExemption: + description: Tax Exemption + type: string + TaxOnTax: + description: Rollup Tax On Tax + format: double + type: number + TelecomCustomer: + description: Telecom Customer? + type: boolean + TickerSymbol: + description: Ticker Symbol + type: string + TradeStyle: + description: Tradestyle + type: string + Type: + description: Type + type: string + UnappliedPayments: + description: Unapplied Payments + format: double + type: number + UnitBase: + description: Rollup Unit Base + type: number + UpsellOpportunity: + description: Upsell Opportunity + type: string + WHMCSClientID: + description: WHMCS Client ID + format: int64 + type: number + Website: + description: Website + type: string + XeroContactID: + description: Xero Contact ID + type: string + YearStarted: + description: Year Started + type: string + type: object + Address: + properties: + City: + description: City + type: string + Country: + description: Country full name + type: string + CountryCode: + description: Country Code + type: string + PostalCode: + description: Postal Code + type: string + State: + description: State full name + type: string + StateCode: + description: State Code + type: string + Street: + description: Street number and name + type: string + type: object + Contact: + properties: + AccountID: + description: The primary account ID of this contact + type: string + AssistantName: + description: Assistant Name + type: string + AssistantPhone: + description: Asst. Phone + type: string + BirthDate: + description: Birthdate + type: string + CreatedByID: + description: Created By User ID + type: string + CreatedDate: + description: Created Date + type: string + Department: + description: Department + type: string + Description: + description: Description + type: string + DoNotCall: + description: Do Not Call? + type: boolean + Email: + description: Email address + type: string + EmailBounceDate: + description: Email Bounce Date + type: string + EmailBouncedReason: + description: Email Bounce Reason + type: string + EnrollmentStatus: + description: Taxnexus Enrollment Status + type: string + Fax: + description: Fax Number + type: string + FirstName: + description: First Name + type: string + HasOptedOutOfEmail: + description: Email Opt Out + type: boolean + HasOptedOutOfFax: + description: Fax Opt Out + type: boolean + HomePhone: + description: Home Phone + type: string + ID: + description: Taxnexus Record Id + type: string + IsEmailBounced: + description: Does this contact have bounced emails? + type: boolean + IsProvisioned: + description: Is Provisioned? + type: boolean + LastModifiedByID: + description: Last Modified By User ID + type: string + LastModifiedDate: + description: Last Modified Date + type: string + LastName: + description: Last Name + type: string + LeadSource: + description: Lead Source + type: string + Level: + description: Level + type: string + LinkedIn: + description: LinkedIn Page + type: string + MailingAddress: + $ref: "#/definitions/Address" + MailingLists: + description: Mailing Lists + type: string + MobilePhone: + description: Mobile Phone + type: string + Name: + description: Full Name + type: string + OtherAddress: + $ref: "#/definitions/Address" + OtherPhone: + description: Other Phone + type: string + OwnerID: + description: The User ID of the user who owns this Contact + type: string + PersonalEmail: + description: Personal Email Address for this Contact + type: string + Phone: + description: Phone Number + type: string + PhotoURL: + description: URL of a photograph of this User + type: string + RecruitingStatus: + description: Recruiting Status + type: string + Ref: + description: "External reference to this contact, if any" + type: string + ReportsToID: + description: Reports To Contact ID + type: string + Salutation: + description: Contact Salutation + type: string + Status: + description: The Contact Status + type: string + TenantID: + description: Tenant Identifier + type: string + Title: + description: Contact Title + type: string + Type: + description: Contact Type + type: string + type: object + Database: + description: A Database provisioned and owned by a Tenant + properties: + Active: + description: Is this database active? + type: boolean + ClusterID: + description: + The ID of the Cluster in which this database is deployed + type: string + CreatedByID: + description: Created By + type: string + CreatedDate: + description: Created Date + type: string + DSN: + description: Database connection string + type: string + DatabaseName: + description: The name of the physical database in the cluster + type: string + ID: + description: Record Id + type: string + LastModifiedByID: + description: Last Modified By + type: string + LastModifiedDate: + description: Last Modifed Date + type: string + Microservices: + description: + List of Taxnexus microservices implemented by this Database + type: string + Status: + description: The current status of this Tenant + type: string + TenantID: + description: The ID of the tenant who owns this Database + type: string + Type: + description: "The type of Database (mysql, etc)" + type: string + type: object + Developer: + properties: + Account: + $ref: "#/definitions/Account" + Contact: + $ref: "#/definitions/Contact" + PaymentMethod: + $ref: "#/definitions/PaymentMethod" + type: object + RuleExecution: + type: object + properties: + SagaID: + description: The Taxnexus SagaID for this rule execution + type: string + SagaType: + description: The Taxnexus SagaType for this rule execution + type: string + RuleID: + description: The Temporal Workflow ID + type: string + RunID: + description: The Temporal First Started Workflow Run ID + type: string + IQ: + properties: + Account: + $ref: "#/definitions/Account" + Contact: + $ref: "#/definitions/Contact" + Lead: + $ref: "#/definitions/Lead" + PaymentMethod: + $ref: "#/definitions/PaymentMethod" + Tenant: + $ref: "#/definitions/Tenant" + User: + $ref: "#/definitions/User" + type: object + Error: + properties: + code: + format: int64 + type: integer + fields: + type: string + message: + type: string + type: object + Lead: + properties: + Address: + $ref: "#/definitions/Address" + Company: + description: Company + type: string + Description: + description: Description + type: string + Email: + description: Email + type: string + FirstName: + description: First Name + type: string + ID: + description: Taxnexus Record Id + type: string + LastName: + description: Last Name + type: string + MobilePhone: + description: Mobile + type: string + Name: + description: Name + type: string + OwnerId: + description: LeadBasic Owner + type: string + PartnerAccountId: + description: Partner Account + type: string + Phone: + description: Phone + type: string + ProductID: + description: Product + type: string + RefererURL: + description: referer_url + type: string + Status: + description: LeadBasic Status + type: string + Title: + description: Title + type: string + Type: + description: Type + type: string + UTMCampaign: + description: utm_campaign + type: string + UTMContent: + description: utm_content + type: string + UTMMedium: + description: utm_medium + type: string + UTMSource: + description: utm_source + type: string + UTMTerm: + description: utm_term + type: string + Website: + description: Website + type: string + type: object + PaymentMethod: + description: + Describes the EFT or other payment information for an account and + billing contact + properties: + AccountID: + description: Account + type: string + AchAccountType: + description: ACH Account Type + type: string + AchBankAccount: + description: ACH Bank Account + type: string + AchRouting: + description: ACH Routing + type: string + Active: + description: Active? + type: boolean + Autopay: + description: Autopay? + type: boolean + BankName: + description: Bank Name + type: string + BillingContactID: + description: Billing Contact + type: string + CCnumber: + description: Credit Card Number + type: string + CCtype: + description: CC Type + type: string + CompanyID: + description: Company + type: string + ContractID: + description: Contract + type: string + CreatedByID: + description: Created By + type: string + CreatedDate: + description: Created Date + type: string + Default: + description: Default Payment Method? + type: boolean + ExpirationDate: + description: Expiration Date + type: string + ExpirationMonth: + description: Expiration Month + type: string + ExpirationYear: + description: Expiration Year + type: string + Gateway: + description: Gateway + type: string + GatewayKey: + description: Gateway Key + type: string + ID: + description: Telnexus Record Id + type: string + LastModifiedByID: + description: Last Modified By + type: string + LastModifiedDate: + description: Last Modified Date + type: string + Nickname: + description: Nickname + type: string + RecordType: + description: Record Type + type: string + Ref: + description: External Reference + type: string + type: object + Role: + description: A functional role within a Tenant + properties: + Auth0RoleID: + description: The corresponding Auth0 Role + type: string + CreatedByID: + description: Created By + type: string + CreatedDate: + description: Created Date + type: string + Description: + description: Role Description + type: string + ID: + description: Record Id + type: string + LastModifiedByID: + description: Last Modified By + type: string + LastModifiedDate: + description: Last Modifed Date + type: string + RoleName: + description: The name of this role + type: string + TenantID: + description: The ID of the Tenant that owns this Role + type: string + type: object + Tenant: + description: Taxnexus Account Tenant + properties: + AccountID: + description: The Account that owns this Tenant + type: string + Active: + description: Is this Tenant currently active? + type: boolean + CreatedByID: + description: Created By + type: string + CreatedDate: + description: Created Date + type: string + Databases: + items: + $ref: "#/definitions/Database" + type: array + ID: + description: Record Id + type: string + LastModifiedByID: + description: Last Modified By + type: string + LastModifiedDate: + description: Last Modifed Date + type: string + Roles: + items: + $ref: "#/definitions/Role" + type: array + Status: + description: The current status of this Tenant + type: string + TenantName: + description: Name of the Tenant Resource + type: string + TenantUsers: + items: + $ref: "#/definitions/TenantUser" + type: array + Type: + description: The type of Tenant + type: string + Version: + description: + The version number of the Tenant Onboarding system used to + create this tenant + type: string + type: object + TenantUser: + description: Relationship object that connects users to a tenant + properties: + AccessLevel: + description: The makeTenantUser access level for this User + type: string + AccountID: + description: Account ID + type: string + Auth0UserID: + description: Auth0 User ID + type: string + CompanyName: + description: Account Name + type: string + ContactID: + description: Contact ID + type: string + TaxnexusAccount: + description: Taxnexus Account + type: string + TenantActive: + description: Tenant active? + type: boolean + TenantID: + description: The Tenant ID + type: string + TenantName: + description: Tenant Name + type: string + TenantStatus: + description: Tenant Status + type: string + TenantType: + description: Tenant type + type: string + TenantVersion: + description: Tenant Version + type: string + UserEmail: + description: User Email Address + type: string + UserFullName: + description: User Full Name + type: string + UserID: + description: The User ID + type: string + Username: + description: Username + type: string + User: + properties: + APIKey: + description: API Key + type: string + AboutMe: + description: About Me + type: string + AccountID: + description: Account ID + type: string + Address: + $ref: "#/definitions/Address" + Alias: + description: Alias + type: string + Auth0UserID: + description: Auth0 User Id + type: string + CommunityNickname: + description: Nickname + type: string + CompanyName: + description: Company Name + type: string + ContactID: + description: Contact + type: string + CreatedByID: + description: Created User ID + type: string + CreatedDate: + description: Date Created + type: string + DelegatedApproverID: + description: Delegated Approver + type: string + Department: + description: Department + type: string + Division: + description: Division + type: string + Email: + description: Email address + type: string + EmployeeNumber: + description: Employee Number + type: string + EndOfDay: + description: Time day ends + type: string + Environment: + description: Environment + type: string + Extension: + description: Extension + type: string + FabricAPIKey: + description: Fabric API Key + type: string + Fax: + description: Fax + type: string + FirstName: + description: The first name + type: string + ForecastEnabled: + description: Allow Forecasting + type: boolean + FullPhotoURL: + description: Full Photo URL + type: string + ID: + description: Taxnexus ID + type: string + IsActive: + description: Active + type: boolean + IsPortalEnabled: + description: Is the user enabled for Communities? + type: boolean + IsProphilePhotoActive: + description: Has Profile Photo + type: boolean + IsSystemControlled: + type: boolean + LastIP: + description: IP address of last login + type: string + LastLogin: + description: Last login time + type: string + LastModifiedByID: + description: Last Modified User ID + type: string + LastModifiedDate: + description: Last Modified Date + type: string + LastName: + description: The Last Name + type: string + LoginCount: + description: Number of times user has logged in + format: int64 + type: number + ManagerID: + description: Manager + type: string + MobilePhone: + description: Mobile + type: string + Name: + description: Name + type: string + OutOfOfficeMessage: + description: Out of office message + type: string + Phone: + description: Phone + type: string + PortalRole: + description: Portal Role Level + type: string + ProfileID: + description: Profile + type: string + ReceivesAdminEmails: + description: Info Emails + type: boolean + ReceivesAdminInfoEmails: + description: Admin Info Emails + type: boolean + SenderEmail: + description: Email Sender Address + type: string + SenderName: + description: Email Sender Name + type: string + Signature: + description: Email Signature + type: string + SmallPhotoURL: + description: Small Photo URL + type: string + StartOfDay: + description: The time day starts + type: string + TaxnexusAccount: + description: Taxnexus Account + type: string + TenantID: + description: Tenant ID + type: string + TenantUsers: + items: + $ref: "#/definitions/TenantUser" + type: array + TimeZone: + description: Time Zone + type: string + Title: + description: Title + type: string + UserRoleID: + description: Role + type: string + UserRoles: + items: + $ref: "#/definitions/UserRole" + type: array + UserType: + description: User Type + type: string + Username: + description: Username + type: string + type: object + UserAuth: + properties: + APIKey: + description: API Key + type: string + AccountID: + description: Account ID + type: string + ContactID: + description: Contact + type: string + Email: + description: Email address + type: string + Roles: + description: Valid Roles for all tenants + items: + type: string + type: array + Tenants: + description: Valid Tenants + items: + type: string + type: array + UserID: + description: Taxneuxs User ID + type: string + UserRole: + description: Relationship object to connect a user to a role + properties: + AccountID: + description: Account Id + type: string + Auth0RoleID: + description: Linked role ID + type: string + Auth0UserID: + description: Auth0 User ID + type: string + CompanyName: + description: Company Name + type: string + ContactID: + description: Contact ID + type: string + RoleDescription: + description: Role description + type: string + RoleID: + description: The Role ID + type: string + RoleName: + description: Role Name + type: string + TaxnexusAccount: + description: Taxnexus Account Number + type: string + UserEmail: + description: User Email Address + type: string + UserFullName: + description: User Full Name + type: string + UserID: + description: The User ID + type: string + Username: + description: Username + type: string + type: object +parameters: + developerRequest: + description: A single Developer struct for onboarding + in: body + name: developerRequest + required: true + schema: + $ref: "#/definitions/Developer" + iqRequest: + description: A single Taxnexus IQ Customer struct for onboarding + in: body + name: iqRequest + required: true + schema: + $ref: "#/definitions/IQ" + emailPath: + description: Email address in the query path + in: path + name: emailPath + required: true + type: string + usernamePath: + description: Username in the query path + in: path + name: usernamePath + required: true + type: string + emailQuery: + description: Email address used for identity lookup + in: query + name: email + required: false + type: string + emailQueryRequired: + description: Email address + in: query + name: email + required: true + type: string + leadRequest: + description: A new Lead record as a single JSON object + in: body + name: leadRequest + required: true + schema: + $ref: "#/definitions/Lead" +responses: + AccessForbidden: + description: "Access forbidden, account lacks access" + headers: + Access-Control-Allow-Origin: + type: string + schema: + $ref: "#/definitions/Error" + CORSResponse: + description: CORS OPTIONS response + headers: + Access-Control-Allow-Credentials: + type: string + Access-Control-Allow-Headers: + type: string + Access-Control-Allow-Methods: + type: string + Access-Control-Allow-Origin: + type: string + Access-Control-Expose-Headers: + type: string + Access-Control-Max-Age: + type: string + Cache-Control: + type: string + Conflict: + description: Conflict + headers: + Access-Control-Allow-Origin: + type: string + schema: + $ref: "#/definitions/Error" + DeleteResponse: + description: + Taxnexus Response with Message Objects with Delete Status + headers: + Access-Control-Allow-Origin: + type: string + DeveloperResponse: + description: Taxnexus Response with a Developer object + headers: + Access-Control-Allow-Origin: + type: string + schema: + $ref: "#/definitions/RuleExecution" + IqResponse: + description: Taxnexus Response with an IQ object + headers: + Access-Control-Allow-Origin: + type: string + schema: + $ref: "#/definitions/RuleExecution" + InvalidDataError: + description: Invalid data was sent + headers: + Access-Control-Allow-Origin: + type: string + schema: + $ref: "#/definitions/Error" + LeadResponse: + description: Taxnexus Response with an array of Lead objects + headers: + Access-Control-Allow-Origin: + type: string + schema: + $ref: "#/definitions/RuleExecution" + NotFound: + description: Resource was not found + headers: + Access-Control-Allow-Origin: + type: string + schema: + $ref: "#/definitions/Error" + ServerError: + description: Server Internal Error + headers: + Access-Control-Allow-Origin: + type: string + schema: + $ref: "#/definitions/Error" + Unauthorized: + description: "Access unauthorized, invalid API-KEY was used" + headers: + Access-Control-Allow-Origin: + type: string + schema: + $ref: "#/definitions/Error" + UnprocessableEntity: + description: "Unprocessable Entity, likely a bad parameter" + headers: + Access-Control-Allow-Origin: + type: string + schema: + $ref: "#/definitions/Error" + UserAuthResponse: + description: Taxneuxs User Authentication Response + headers: + Access-Control-Allow-Origin: + type: string + schema: + $ref: "#/definitions/UserAuth" + UserResponse: + description: User Response + headers: + Access-Control-Allow-Origin: + type: string + schema: + $ref: "#/definitions/User" +securityDefinitions: + ApiKeyAuth: + type: apiKey + name: X-API-Key + in: header diff --git a/swagger/cloud-telnexus.yaml b/swagger/cloud-telnexus.yaml deleted file mode 100644 index 8a08327..0000000 --- a/swagger/cloud-telnexus.yaml +++ /dev/null @@ -1,699 +0,0 @@ -swagger: "2.0" -info: - version: 0.0.2 - title: "cloud" - description: "Cloud Gateway Microservice" - termsOfService: "http://telnexus.com/terms/" - contact: - email: "noc@telnexus.com" - license: - name: "Proprietary - Copyright (c) 2018-2020 by Telnexus LLC." -securityDefinitions: - ApiKeyAuth: - type: "apiKey" - in: "header" - name: "X-API-Key" -security: - - ApiKeyAuth: [] -schemes: - - "http" -basePath: "/v1" -host: "cloud.infra.tnxs.net:8080" -consumes: - - "application/json" -produces: - - "application/json" -parameters: - apiKeyQuery: - description: Service account or developer API key - in: query - name: apikey - type: string - hubRequest: - description: An array of new Hub records - in: body - name: hubRequest - required: true - schema: - $ref: "#/definitions/HubRequest" - limitQuery: - description: "How many objects to return at one time" - format: int64 - in: query - name: limit - required: false - type: integer - accountIdQuery: - description: Taxnexus Record Id of an Account - in: query - name: accountId - required: false - type: string - nameQuery: - description: The Name of this Object - in: query - name: name - required: false - type: string - offsetQuery: - description: How many objects to skip? (default 0) - format: int64 - in: query - name: offset - required: false - type: integer - activeQuery: - description: Retrieve active records? - in: query - name: active - required: false - type: boolean - emailQuery: - description: Email address? - in: query - name: email - required: false - type: string -responses: - AccessForbidden: - description: "Access forbidden, account lacks access" - schema: - $ref: "#/definitions/Error" - NotFound: - description: Resource was not found - schema: - $ref: "#/definitions/Error" - ServerError: - description: Server Internal Error - schema: - $ref: "#/definitions/Error" - Unauthorized: - description: "Access Unauthorized, invalid API-KEY was used" - schema: - $ref: "#/definitions/Error" - UnprocessableEntity: - description: "Unprocessable Entity, likely a bad parameter" - schema: - $ref: "#/definitions/Error" - UserResponse: - description: Taxnexus Response with User objects - schema: - $ref: "#/definitions/UserResponse" - HubResponse: - description: Telnexus Response with Hub objects - headers: - Access-Control-Allow-Origin: - type: string - Cache-Control: - type: string - schema: - $ref: "#/definitions/HubResponse" - DeleteResponse: - description: - Taxnexus Response with Message Objects with Delete Status - headers: - Access-Control-Allow-Origin: - type: string - schema: - $ref: "#/definitions/DeleteResponse" - CORSResponse: - description: CORS OPTIONS response - headers: - Access-Control-Allow-Origin: - type: string - Access-Control-Allow-Headers: - type: string - Access-Control-Allow-Methods: - type: string - Access-Control-Expose-Headers: - type: string - Access-Control-Max-Age: - type: string - Access-Control-Allow-Credentials: - type: string - Cache-Control: - type: string -paths: - /hubs: - delete: - description: Delete Telnexus Hub record - operationId: deleteHub - parameters: - - $ref: "#/parameters/accountIdQuery" - responses: - "200": - $ref: "#/responses/DeleteResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - security: - - ApiKeyAuth: [] - summary: Delete An Hub - tags: - - Hub - get: - description: Return a list of all available Hubs - operationId: getHubs - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/nameQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/activeQuery" - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/emailQuery" - responses: - "200": - $ref: "#/responses/HubResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - security: - - ApiKeyAuth: [] - summary: Get a list of accounts - tags: - - Hub - options: - description: CORS support - operationId: accountOptions - responses: - "200": - $ref: "#/responses/CORSResponse" - tags: - - cors - post: - description: Hub record to be added - operationId: postHubs - parameters: - - $ref: "#/parameters/hubRequest" - responses: - "200": - $ref: "#/responses/HubResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - security: - - ApiKeyAuth: [] - summary: Add a new account to Telnexus - tags: - - Hub - put: - description: Update Hubs - operationId: putHub - parameters: - - $ref: "#/parameters/hubRequest" - responses: - "200": - $ref: "#/responses/HubResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - security: - - ApiKeyAuth: [] - summary: Update a single account - tags: - - Hub - /users: - get: - summary: "Check API Key" - operationId: "getUsers" - description: - "Checks for a valid API key, and returns full user record" - parameters: - - $ref: "#/parameters/apiKeyQuery" - tags: - - "User" - responses: - "200": - $ref: "#/responses/UserResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" -definitions: - DeleteResponse: - properties: - Data: - items: - $ref: "#/definitions/Message" - type: array - Meta: - $ref: "#/definitions/ResponseMeta" - type: object - Hub: - type: object - properties: - ID: - type: string - description: Record Id - AccountID: - type: string - description: Account - BillingContactID: - type: string - description: Billing Contact - ContactID: - type: string - description: Contact - CreatedById: - type: string - description: Created By - CreatedDate: - type: string - description: Created Date - CurrentUsers: - type: number - description: Current Users - Name: - type: string - description: Hub Name - MaxUsers: - type: number - description: Max Users - OrderItem: - type: string - description: Order Item - LastModifiedByID: - type: string - description: Last Modified By - LastModifiedDate: - type: string - description: Last Modifed Date - VendorID: - type: string - description: Vendor - VendorTenantID: - type: string - description: Vendor Tenant ID - Address: - properties: - City: - description: City - type: string - Country: - description: Country full name - type: string - CountryCode: - description: Country Code - type: string - PostalCode: - description: Postal Code - type: string - State: - description: State full name - type: string - StateCode: - description: State Code - type: string - Street: - description: Street number and name - type: string - type: object - Error: - properties: - Code: - format: int32 - type: integer - Fields: - type: string - Message: - type: string - type: object - Message: - properties: - message: - type: string - ref: - type: string - type: object - ResponseMeta: - properties: - Contact: - description: Microservice Contact Info - type: string - Copyright: - description: Copyright Info - type: string - License: - description: License Information and Restrictions - type: string - OperationID: - description: Operation ID - type: string - RequestIP: - description: Request IP Address - type: string - RequestType: - description: Request Type - type: string - RequestURL: - description: Request URL - type: string - ServerInfo: - description: Data Server Info - type: string - ServerResponseTime: - description: Data Server Response Time (ms) - type: string - ServerTimestamp: - description: Backend Server Timestamp - type: string - TelnexusAccount: - description: - Taxnexus Account Number used for recording transactions - type: string - type: object - HubRequest: - description: An array of Hub objects - properties: - Data: - items: - $ref: "#/definitions/Hub" - type: array - type: object - HubResponse: - description: An array of Hub objects - properties: - Data: - items: - $ref: "#/definitions/Hub" - type: array - Meta: - $ref: "#/definitions/ResponseMeta" - type: object - User: - properties: - AboutMe: - description: About Me - type: string - AccountID: - description: Account ID - type: string - Address: - $ref: "#/definitions/Address" - Alias: - description: Alias - type: string - APIKey: - description: API Key - type: string - Auth0UserID: - description: Auth0 User Id - type: string - CommunityNickname: - description: Nickname - type: string - CompanyName: - description: Company Name - type: string - ContactID: - description: Contact - type: string - CreatedByID: - description: Created User ID - type: string - CreatedDate: - description: Date Created - type: string - DelegatedApproverID: - description: Delegated Approver - type: string - Department: - description: Department - type: string - Division: - description: Division - type: string - Email: - description: Email address - type: string - EmployeeNumber: - description: Employee Number - type: string - EndOfDay: - description: Time day ends - type: string - Environment: - description: Environment - type: string - Extension: - description: Extension - type: string - FabricAPIKey: - description: Fabric API Key - type: string - Fax: - description: Fax - type: string - FirstName: - description: The first name - type: string - ForecastEnabled: - description: Allow Forecasting - type: boolean - FullPhotoURL: - description: Full Photo URL - type: string - ID: - description: Taxnexus ID - type: string - IsActive: - description: Active - type: boolean - IsPortalEnabled: - description: Is the user enabled for Communities? - type: boolean - IsProphilePhotoActive: - description: Has Profile Photo - type: boolean - IsSystemControlled: - type: boolean - LastModifiedByID: - description: Last Modified User ID - type: string - LastModifiedDate: - description: Last Modified Date - type: string - LastLogin: - description: Last login time - type: string - LastIP: - description: IP address of last login - type: string - LoginCount: - description: Number of times user has logged in - type: number - format: int64 - LastName: - description: The Last Name - type: string - ManagerID: - description: Manager - type: string - MobilePhone: - description: Mobile - type: string - Name: - description: Name - type: string - OutOfOfficeMessage: - description: Out of office message - type: string - Phone: - description: Phone - type: string - PortalRole: - description: Portal Role Level - type: string - ProfileID: - description: Profile - type: string - ReceivesAdminInfoEmails: - description: Admin Info Emails - type: boolean - ReceivesAdminEmails: - description: Info Emails - type: boolean - SenderEmail: - description: Email Sender Address - type: string - SenderName: - description: Email Sender Name - type: string - Signature: - description: Email Signature - type: string - SmallPhotoURL: - description: Small Photo URL - type: string - StartOfDay: - description: The time day starts - type: string - TelnexusAccount: - description: Taxnexus Account - type: string - TenantID: - description: Tenant ID associated with this user - type: string - TimeZone: - description: Time Zone - type: string - Title: - description: Title - type: string - Username: - description: Username - type: string - UserRoleID: - description: Role - type: string - UserType: - description: User Type - type: string - UserRoles: - items: - $ref: "#/definitions/UserRole" - type: array - TenantUsers: - items: - $ref: "#/definitions/TenantUser" - type: array - type: object - UserResponse: - description: An array Taxnexus user objects - properties: - Data: - items: - $ref: "#/definitions/User" - type: array - Meta: - $ref: "#/definitions/ResponseMeta" - type: object - UserRole: - description: Relationship object that connects user to a role - type: object - properties: - AccountID: - description: Account Id - type: string - Auth0RoleID: - description: Linked role ID - type: string - Auth0UserID: - description: Auth0 User ID - type: string - CompanyName: - description: Company Name - type: string - ContactID: - description: Contact ID - type: string - RoleDescription: - description: Role description - type: string - RoleID: - description: The Role ID - type: string - RoleName: - description: Role Name - type: string - TelnexusAccount: - description: Taxnexus Account Number - type: string - UserEmail: - description: User Email Address - type: string - UserFullName: - description: User Full Name - type: string - UserID: - description: The User ID - type: string - Username: - description: Username - type: string - TenantUser: - description: Relationship object that connects users to a tenant - type: object - properties: - AccessLevel: - description: The makeTenantUser access level for this User - type: string - Auth0UserID: - description: Auth0 User ID - type: string - AccountID: - description: Account ID - type: string - ContactID: - description: Contact ID - type: string - CompanyName: - description: Account Name - type: string - TelnexusAccount: - description: Taxnexus Account - type: string - TenantActive: - description: Tenant active? - type: boolean - TenantID: - description: The Tenant ID - type: string - TenantName: - description: Tenant Name - type: string - TenantStatus: - description: Tenant Status - type: string - TenantType: - description: Tenant type - type: string - TenantVersion: - description: Tenant Version - type: string - Username: - description: Username - type: string - UserEmail: - description: User Email Address - type: string - UserFullName: - description: User Full Name - type: string - UserID: - description: The User ID - type: string diff --git a/swagger/crm-telnexus.yaml b/swagger/crm-kvision.yaml similarity index 95% rename from swagger/crm-telnexus.yaml rename to swagger/crm-kvision.yaml index ad54be4..76b50f8 100644 --- a/swagger/crm-telnexus.yaml +++ b/swagger/crm-kvision.yaml @@ -1,13 +1,13 @@ swagger: "2.0" info: - version: 0.0.2 + version: 0.0.1 title: "crm" description: "Customer Information Microservice" - termsOfService: "http://telnexus.com/terms/" + termsOfService: "http://taxnexus.net/terms/" contact: - email: "noc@telnexus.com" + email: "noc@taxnexus.net" license: - name: "Proprietary - Copyright (c) 2018-2020 by Telnexus LLC" + name: "Proprietary - Copyright (c) 2018-2021 by Taxnexus, Inc." securityDefinitions: ApiKeyAuth: type: "apiKey" @@ -16,14 +16,14 @@ securityDefinitions: schemes: - "http" basePath: "/v1" -host: "crm.infra.tnxs.net:8080" +host: "crm.vernonkeenan.com:8080" consumes: - "application/json" produces: - "application/json" parameters: accountIdQuery: - description: Telnexus Record Id of an Account + description: Taxnexus Record Id of an Account in: query name: accountId required: false @@ -42,19 +42,19 @@ parameters: required: false type: boolean companyIdQuery: - description: Telnexus Company record ID + description: Taxnexus Company record ID in: query name: companyId required: false type: string leadIdQuery: - description: Telnexus Lead record ID + description: Taxnexus Lead record ID in: query name: leadId required: false type: string contactIdQuery: - description: Telnexus Contact record ID + description: Taxnexus Contact record ID in: query name: contactId required: false @@ -121,7 +121,7 @@ responses: schema: $ref: "#/definitions/Error" AccountBasicResponse: - description: Telnexus Response with Account objects with Contacts + description: Taxnexus Response with Account objects with Contacts headers: Access-Control-Allow-Origin: type: string @@ -130,7 +130,7 @@ responses: schema: $ref: "#/definitions/AccountBasicResponse" AccountResponse: - description: Telnexus Response with Account objects with Contacts + description: Taxnexus Response with Account objects with Contacts headers: Access-Control-Allow-Origin: type: string @@ -139,7 +139,7 @@ responses: schema: $ref: "#/definitions/AccountResponse" AccountObservableResponse: - description: Telnexus Response with an array of Account objects + description: Taxnexus Response with an array of Account objects headers: Access-Control-Allow-Origin: type: string @@ -155,11 +155,11 @@ responses: type: string Cache-Control: type: string - description: Telnexus Response with Company objects + description: Taxnexus Response with Company objects schema: $ref: "#/definitions/CompanyResponse" CompanyObservableResponse: - description: Telnexus Response with an array of Company objects + description: Taxnexus Response with an array of Company objects headers: Access-Control-Allow-Origin: type: string @@ -177,7 +177,7 @@ responses: schema: $ref: "#/definitions/Error" ContactResponse: - description: Telnexus Response with an array of Contact objects + description: Taxnexus Response with an array of Contact objects headers: Access-Control-Allow-Origin: type: string @@ -186,7 +186,7 @@ responses: schema: $ref: "#/definitions/ContactResponse" ContactObservableResponse: - description: Telnexus Response with an array of Contact objects + description: Taxnexus Response with an array of Contact objects headers: Access-Control-Allow-Origin: type: string @@ -197,7 +197,7 @@ responses: $ref: "#/definitions/Contact" type: array LeadResponse: - description: Telnexus Response with an array of Lead objects + description: Taxnexus Response with an array of Lead objects headers: Access-Control-Allow-Origin: type: string @@ -206,7 +206,7 @@ responses: schema: $ref: "#/definitions/LeadResponse" LeadObservableResponse: - description: Telnexus Response with an array of Lead objects + description: Taxnexus Response with an array of Lead objects headers: Access-Control-Allow-Origin: type: string @@ -218,7 +218,7 @@ responses: type: array DeleteResponse: description: - Telnexus Response with Message Objects with Delete Status + Taxnexus Response with Message Objects with Delete Status headers: Access-Control-Allow-Origin: type: string @@ -279,7 +279,7 @@ responses: paths: /accounts: delete: - description: Delete Telnexus Account record + description: Delete Taxnexus Account record operationId: deleteAccount parameters: - $ref: "#/parameters/accountIdQuery" @@ -357,7 +357,7 @@ paths: $ref: "#/responses/ServerError" security: - ApiKeyAuth: [] - summary: Add a new account to Telnexus + summary: Add a new account to Taxnexus tags: - Accounts put: @@ -407,7 +407,7 @@ paths: $ref: "#/responses/ServerError" security: - ApiKeyAuth: [] - summary: Get Telnexus Accounts in an observable array + summary: Get Taxnexus Accounts in an observable array tags: - Accounts options: @@ -494,7 +494,7 @@ paths: $ref: "#/responses/ServerError" security: - ApiKeyAuth: [] - summary: Get Telnexus Companies in an observable array + summary: Get Taxnexus Companies in an observable array tags: - Companies options: @@ -507,7 +507,7 @@ paths: - cors /contacts: delete: - description: Delete Telnexus Contact record + description: Delete Taxnexus Contact record operationId: deleteContact parameters: - $ref: "#/parameters/contactIdQuery" @@ -635,7 +635,7 @@ paths: $ref: "#/responses/ServerError" security: - ApiKeyAuth: [] - summary: Get Telnexus Contacts in an observable array + summary: Get Taxnexus Contacts in an observable array tags: - Contacts options: @@ -648,7 +648,7 @@ paths: - cors /leads: delete: - description: Delete Telnexus Lead record + description: Delete Taxnexus Lead record operationId: deleteLead parameters: - $ref: "#/parameters/leadIdQuery" @@ -774,7 +774,7 @@ paths: $ref: "#/responses/ServerError" security: - ApiKeyAuth: [] - summary: Get Telnexus Leads in an observable array + summary: Get Taxnexus Leads in an observable array tags: - Leads options: @@ -901,7 +901,7 @@ definitions: description: Fax type: string ID: - description: Telnexus Account Id + description: Taxnexus Account Id type: string ISPCustomer: description: ISP Customer? @@ -1069,7 +1069,7 @@ definitions: AccountBasic: properties: AccountNumber: - description: "Telnexus Account Number of the OEM/Reseller " + description: "Taxnexus Account Number of the OEM/Reseller " type: string BillingAddress: $ref: "#/definitions/Address" @@ -1077,7 +1077,7 @@ definitions: description: Contact ID type: string CompanyID: - description: Telnexus OEM/Reseller Record Id + description: Taxnexus OEM/Reseller Record Id type: string CoordinateID: description: @@ -1196,7 +1196,7 @@ definitions: Company: properties: AccountID: - description: Telnexus ID of the Account that owns this Company + description: Taxnexus ID of the Account that owns this Company type: string AccountNumberPrefix: description: Account Number Prefix @@ -1263,7 +1263,7 @@ definitions: description: Font Name for Monospace type: string ID: - description: Telnexus Record Id + description: Taxnexus Record Id type: string International: description: International Customers? @@ -1362,7 +1362,7 @@ definitions: description: Email Bounce Reason type: string EnrollmentStatus: - description: Telnexus Enrollment Status + description: Taxnexus Enrollment Status type: string Fax: description: Fax Number @@ -1380,7 +1380,7 @@ definitions: description: Home Phone type: string ID: - description: Telnexus Record Id + description: Taxnexus Record Id type: string IsEmailBounced: description: Does this contact have bounced emails? @@ -1526,7 +1526,7 @@ definitions: description: First Name type: string ID: - description: Telnexus Record Id + description: Taxnexus Record Id type: string LastModifiedByID: description: Last Modified By User ID @@ -1632,11 +1632,11 @@ definitions: type: object RequestMeta: properties: - TelnexusAccount: - description: Telnexus Account Number of the Reseller or OEM + TaxnexusAccount: + description: Taxnexus Account Number of the Reseller or OEM type: string required: - - TelnexusAccount + - TaxnexusAccount type: object ResponseMeta: properties: @@ -1672,8 +1672,8 @@ definitions: ServerTimestamp: description: Backend Server Timestamp type: string - TelnexusAccount: + TaxnexusAccount: description: - Telnexus Account Number used for recording transactions + Taxnexus Account Number used for recording transactions type: string type: object diff --git a/swagger/devops-telnexus.yaml b/swagger/devops-kvision.yaml similarity index 95% rename from swagger/devops-telnexus.yaml rename to swagger/devops-kvision.yaml index 044bb0b..82d43ed 100644 --- a/swagger/devops-telnexus.yaml +++ b/swagger/devops-kvision.yaml @@ -1,13 +1,13 @@ swagger: "2.0" info: - version: 0.0.2 + version: 0.0.1 title: "devops" description: "System Operations Microservice" - termsOfService: "http://telnexus.com/terms/" + termsOfService: "http://taxnexus.net/terms/" contact: - email: "noc@telnexus.com" + email: "noc@taxnexus.net" license: - name: "Proprietary - Copyright (c) 2018-2020 by Telnexus LLC" + name: "Proprietary - Copyright (c) 2018-2021 by Taxnexus, Inc." securityDefinitions: ApiKeyAuth: type: "apiKey" @@ -23,19 +23,19 @@ produces: - "application/json" parameters: databaseIdQuery: - description: Telnexus Record Id of a Database + description: Taxnexus Record Id of a Database in: query name: databaseId required: false type: string - TelnexusAccountQuery: - description: Telnexus Account of a Tenant + taxnexusAccountQuery: + description: Taxnexus Account of a Tenant in: query - name: TelnexusAccount + name: taxnexusAccount required: false type: string tenantIdQuery: - description: Telnexus Record Id of a Tenant + description: Taxnexus Record Id of a Tenant in: query name: tenantId required: false @@ -102,20 +102,20 @@ parameters: schema: $ref: "#/definitions/UserRequest" accountIdQuery: - description: Telnexus Record Id of an Account + description: Taxnexus Record Id of an Account in: query name: accountId required: false type: string contactIdQuery: - description: Telnexus Record Id of a Contact + description: Taxnexus Record Id of a Contact in: query name: contactId required: false type: string accountNumberQuery: description: - The Telnexus Account Number of the Account to be used a record + The Taxnexus Account Number of the Account to be used a record retrieval in: query name: accountNumber @@ -133,49 +133,49 @@ parameters: name: apikey type: string clusterIdPath: - description: Telnexus Record Id of a Cluster + description: Taxnexus Record Id of a Cluster in: path name: clusterIdPath type: string required: true databaseIdPath: - description: Telnexus Record Id of a Database + description: Taxnexus Record Id of a Database in: path name: databaseIdPath type: string required: true clusterIdQuery: - description: Telnexus Record Id of a Cluster + description: Taxnexus Record Id of a Cluster in: query name: clusterId required: false type: string companyIdQuery: - description: Telnexus Record Id of a Company + description: Taxnexus Record Id of a Company in: query name: companyId required: false type: string ingestIdPath: - description: Telnexus Record Id of a Ingest + description: Taxnexus Record Id of a Ingest in: path name: ingestIdPath type: string required: true ingestIdQuery: - description: Telnexus Record Id of an Ingest + description: Taxnexus Record Id of an Ingest in: query name: ingestId required: false type: string jobIdPath: - description: Telnexus Record Id of a Job + description: Taxnexus Record Id of a Job in: path name: jobIdPath type: string required: true jobIdQuery: - description: Telnexus Record Id of a Job + description: Taxnexus Record Id of a Job in: query name: jobId required: false @@ -195,7 +195,7 @@ parameters: required: false type: integer serviceIdPath: - description: Telnexus Record Id of a Service + description: Taxnexus Record Id of a Service in: path name: serviceIdPath type: string @@ -206,7 +206,7 @@ parameters: name: serviceId type: string templateIdPath: - description: Telnexus Record Id of a Template + description: Taxnexus Record Id of a Template in: path name: templateIdPath type: string @@ -227,19 +227,19 @@ parameters: name: isMaster type: boolean userIdPath: - description: Telnexus Record Id of a User + description: Taxnexus Record Id of a User in: path name: userIdPath type: string required: true tenantIdPath: - description: Telnexus Record Id of a Tenant + description: Taxnexus Record Id of a Tenant in: path name: tenantIdPath type: string required: true userIdQuery: - description: Telnexus User ID (unique) + description: Taxnexus User ID (unique) in: query name: userId type: string @@ -289,7 +289,7 @@ responses: items: $ref: "#/definitions/Cluster" ClusterResponse: - description: Telnexus Response with Cluster objects + description: Taxnexus Response with Cluster objects headers: Access-Control-Allow-Origin: type: string @@ -299,14 +299,14 @@ responses: $ref: "#/definitions/ClusterResponse" DeveopsDeleteResponse: description: - Telnexus Response with Message Objects with Delete Status + Taxnexus Response with Message Objects with Delete Status headers: Access-Control-Allow-Origin: type: string schema: $ref: "#/definitions/DeleteResponse" IngestResponse: - description: Telnexus Response with Ingest objects + description: Taxnexus Response with Ingest objects headers: Access-Control-Allow-Origin: type: string @@ -335,7 +335,7 @@ responses: items: $ref: "#/definitions/Ingest" JobResponse: - description: Telnexus Response with Job objects + description: Taxnexus Response with Job objects headers: Access-Control-Allow-Origin: type: string @@ -374,7 +374,7 @@ responses: headers: Access-Control-Allow-Origin: type: string - description: Telnexus Response with Database objects + description: Taxnexus Response with Database objects schema: $ref: "#/definitions/DatabaseResponse" DatabaseSingletonResponse: @@ -401,7 +401,7 @@ responses: headers: Access-Control-Allow-Origin: type: string - description: Telnexus Response with Tenant objects + description: Taxnexus Response with Tenant objects schema: $ref: "#/definitions/TenantResponse" TenantSingletonResponse: @@ -432,7 +432,7 @@ responses: schema: $ref: "#/definitions/Error" ServiceResponse: - description: Telnexus Response with Service objects + description: Taxnexus Response with Service objects headers: Access-Control-Allow-Origin: type: string @@ -461,7 +461,7 @@ responses: items: $ref: "#/definitions/Service" TemplateResponse: - description: Telnexus Response with Template objects + description: Taxnexus Response with Template objects headers: Access-Control-Allow-Origin: type: string @@ -508,7 +508,7 @@ responses: schema: $ref: "#/definitions/Error" UserResponse: - description: Telnexus Response with User objects + description: Taxnexus Response with User objects headers: Access-Control-Allow-Origin: type: string @@ -590,7 +590,7 @@ paths: tags: - cors post: - description: Create Clusters in Telnexus + description: Create Clusters in Taxnexus operationId: postClusters parameters: - $ref: "#/parameters/ClusterRequest" @@ -613,7 +613,7 @@ paths: tags: - Cluster put: - description: Update Cluster in Telnexus + description: Update Cluster in Taxnexus operationId: putClusters parameters: - $ref: "#/parameters/ClusterRequest" @@ -726,7 +726,7 @@ paths: tags: - cors post: - description: Create Databases in Telnexus + description: Create Databases in Taxnexus operationId: postDatabases parameters: - $ref: "#/parameters/databaseRequest" @@ -749,7 +749,7 @@ paths: tags: - Database put: - description: Update Database in Telnexus + description: Update Database in Taxnexus operationId: putDatabases parameters: - $ref: "#/parameters/databaseRequest" @@ -1001,7 +1001,7 @@ paths: tags: - cors post: - description: Create and enqueue Jobs in Telnexus + description: Create and enqueue Jobs in Taxnexus operationId: postJobs parameters: - $ref: "#/parameters/JobRequest" @@ -1024,7 +1024,7 @@ paths: tags: - Job put: - description: Update Jobs in Telnexus + description: Update Jobs in Taxnexus operationId: putJobs parameters: - $ref: "#/parameters/JobRequest" @@ -1136,7 +1136,7 @@ paths: tags: - cors post: - description: Create Services in Telnexus + description: Create Services in Taxnexus operationId: postServices parameters: - $ref: "#/parameters/ServiceRequest" @@ -1159,7 +1159,7 @@ paths: tags: - Service put: - description: Update Services in Telnexus + description: Update Services in Taxnexus operationId: putServices parameters: - $ref: "#/parameters/ServiceRequest" @@ -1356,7 +1356,7 @@ paths: description: Return a list of Tenant records from the datastore operationId: getTenants parameters: - - $ref: "#/parameters/TelnexusAccountQuery" + - $ref: "#/parameters/taxnexusAccountQuery" - $ref: "#/parameters/tenantIdQuery" - $ref: "#/parameters/companyIdQuery" - $ref: "#/parameters/limitQuery" @@ -1388,7 +1388,7 @@ paths: tags: - cors post: - description: Create Tenants in Telnexus + description: Create Tenants in Taxnexus operationId: postTenants parameters: - $ref: "#/parameters/tenantRequest" @@ -1411,7 +1411,7 @@ paths: tags: - Tenant put: - description: Update Tenant in Telnexus + description: Update Tenant in Taxnexus operationId: putTenants parameters: - $ref: "#/parameters/tenantRequest" @@ -1671,7 +1671,7 @@ definitions: description: Gateway type: string ID: - description: Telnexus Record Id + description: Taxnexus Record Id type: string IPAddress: description: IP Address @@ -1757,7 +1757,7 @@ definitions: type: string Microservices: description: - List of Telnexus microservices implemented by this Database + List of Taxnexus microservices implemented by this Database type: string Status: description: The current status of this Tenant @@ -1807,7 +1807,7 @@ definitions: type: string type: object Ingest: - description: A record of the Ingest of information into Telnexus + description: A record of the Ingest of information into Taxnexus properties: AccountID: description: Account ID @@ -1823,7 +1823,7 @@ definitions: description: Company ID type: string CreatedByID: - description: Telnexus User ID + description: Taxnexus User ID type: string CreatedDate: description: Date of Job Creation @@ -1862,7 +1862,7 @@ definitions: description: Job ID type: string LastModifiedByID: - description: Telnexus User ID + description: Taxnexus User ID type: string LastModifiedDate: description: Last Modified Date @@ -1999,19 +1999,19 @@ definitions: Job: properties: AccountID: - description: Telnexus Account Id + description: Taxnexus Account Id type: string BackendID: - description: Telnexus Backend ID + description: Taxnexus Backend ID type: string CompanyID: - description: Telnexus Company ID + description: Taxnexus Company ID type: string CoordinateID: - description: Telnexus Coordinate ID + description: Taxnexus Coordinate ID type: string CreatedByID: - description: Telnexus User ID + description: Taxnexus User ID type: string CreatedDate: description: Date of Job Creation @@ -2038,7 +2038,7 @@ definitions: description: Error Reason type: string ID: - description: Telnexus Record Id of the Job record + description: Taxnexus Record Id of the Job record type: string Interval: description: @@ -2191,11 +2191,11 @@ definitions: type: object RequestMeta: properties: - TelnexusAccount: - description: Telnexus Account Number of the Reseller or OEM + TaxnexusAccount: + description: Taxnexus Account Number of the Reseller or OEM type: string required: - - TelnexusAccount + - TaxnexusAccount type: object ResponseMeta: properties: @@ -2231,9 +2231,9 @@ definitions: ServerTimestamp: description: Backend Server Timestamp type: string - TelnexusAccount: + TaxnexusAccount: description: - Telnexus Account Number used for recording transactions + Taxnexus Account Number used for recording transactions type: string type: object Role: @@ -2315,7 +2315,7 @@ definitions: description: GELF Address type: string ID: - description: Telnexus Record Id + description: Taxnexus Record Id type: string LastModifiedByID: description: Last Modified By @@ -2392,7 +2392,7 @@ definitions: format: byte type: string ID: - description: Telnexus Record Id + description: Taxnexus Record Id type: string IsActive: description: Active? @@ -2442,7 +2442,7 @@ definitions: $ref: "#/definitions/ResponseMeta" type: object Tenant: - description: Telnexus Account Tenant + description: Taxnexus Account Tenant properties: AccountID: description: The Account that owns this Tenant @@ -2528,8 +2528,8 @@ definitions: ContactID: description: Contact ID type: string - TelnexusAccount: - description: Telnexus Account + TaxnexusAccount: + description: Taxnexus Account type: string TenantActive: description: Tenant active? @@ -2636,7 +2636,7 @@ definitions: description: Full Photo URL type: string ID: - description: Telnexus ID + description: Taxnexus ID type: string IsActive: description: Active @@ -2710,8 +2710,8 @@ definitions: StartOfDay: description: The time day starts type: string - TelnexusAccount: - description: Telnexus Account + TaxnexusAccount: + description: Taxnexus Account type: string TenantID: description: Tenant ID associated with this user @@ -2784,8 +2784,8 @@ definitions: RoleName: description: Role Name type: string - TelnexusAccount: - description: Telnexus Account Number + TaxnexusAccount: + description: Taxnexus Account Number type: string UserEmail: description: User Email Address diff --git a/swagger/isp-telnexus.yaml b/swagger/isp-telnexus.yaml deleted file mode 100644 index c15deb6..0000000 --- a/swagger/isp-telnexus.yaml +++ /dev/null @@ -1,286 +0,0 @@ -swagger: "2.0" -info: - version: 0.0.2 - title: isp - description: Telnexus ISP Microservice - termsOfService: http://telnexus.com/terms/ - contact: - email: noc@telnexus.com - license: - name: Proprietary - Copyright (c) 2012-2020 by Telnexus LLC -securityDefinitions: - ApiKeyAuth: - type: apiKey - in: header - name: X-API-Key -security: - - ApiKeyAuth: [] -schemes: - - http -basePath: /v1 -host: isp.infra.tnxs.net:8080 -consumes: - - application/json -produces: - - application/json -responses: - AccessForbidden: - description: "Access forbidden, account lacks access" - schema: - $ref: "#/definitions/Error" - headers: - Access-Control-Allow-Origin: - type: string - Cache-Control: - type: string - NotFound: - description: Resource was not found - schema: - $ref: "#/definitions/Error" - headers: - Access-Control-Allow-Origin: - type: string - Cache-Control: - type: string - ServerError: - description: Server Internal Error - schema: - $ref: "#/definitions/Error" - headers: - Access-Control-Allow-Origin: - type: string - Cache-Control: - type: string - Unauthorized: - description: "Access Unauthorized, invalid API-KEY was used" - schema: - $ref: "#/definitions/Error" - headers: - Access-Control-Allow-Origin: - type: string - Cache-Control: - type: string - UnprocessableEntity: - description: "Unprocessable Entity, likely a bad parameter" - schema: - $ref: "#/definitions/Error" - headers: - Access-Control-Allow-Origin: - type: string - Cache-Control: - type: string - ZoneResponse: - description: Telnexus Response with an array of Zone objects - headers: - Access-Control-Allow-Origin: - type: string - Cache-Control: - type: string - schema: - $ref: "#/definitions/ZoneResponse" -parameters: - limitQuery: - default: 100 - description: - "How many objects to return at one time (max 300, default 100)" - format: int64 - in: query - name: limit - required: false - type: integer - offsetQuery: - default: 0 - description: How many objects to skip? (default 0) - format: int64 - in: query - name: offset - required: false - type: integer - accountIdQuery: - description: Telnexus Record Id of an Account - in: query - name: accountId - required: false - type: string - zoneIdQuery: - description: Telnexus Record Id of a Zone - in: query - name: zoneId - required: false - type: string -paths: - /zone: - get: - description: Get DNS Zones - summary: Get DNS Zones - tags: - - Zone - operationId: getZones - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/zoneIdQuery" - responses: - "200": - $ref: "#/responses/ZoneResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" -definitions: - Error: - properties: - code: - format: int64 - type: integer - fields: - type: string - message: - type: string - type: object - Registrar: - type: object - properties: - ID: - type: string - description: Record Id - AccountID: - type: string - description: Account - ContactID: - type: string - description: Contact - CreatedById: - type: string - description: Created By - CreatedDate: - type: string - description: Created Date - DateEnd: - type: string - description: End Date - DateStart: - type: string - description: Start Date - Description: - type: string - description: Description - LastModifiedById: - type: string - description: Last Modified By - LastModifiedDate: - type: string - description: Last Modifed Date - RegistrarName: - type: string - description: Registrar Name - URL: - type: string - description: Registrar URL - Zone: - type: object - properties: - ID: - type: string - description: Record Id - AccountID: - type: string - description: Account - ContactID: - type: string - description: Contact - CreatedById: - type: string - description: Created By - CreatedDate: - type: string - description: Created Date - DateEnd: - type: string - description: End Date - DateStart: - type: string - description: Start Date - Description: - type: string - description: Description - ExpirationDate: - type: string - description: Expiration Date - IDProtect: - type: boolean - description: ID Protect? - HostID: - type: string - description: The ID of the Host upon which this Zone is hosted - LastModifiedById: - type: string - description: Last Modified By - LastModifiedDate: - type: string - description: Last Modifed Date - PeriodStartID: - type: boolean - description: Auto Renew? - RegistrarID: - type: string - description: ID of the Registar that owns this zone instance - Term: - type: string - description: Term - ZoneName: - type: string - description: Zone Name - ZoneResponse: - description: An array of Zone objects - properties: - data: - items: - $ref: "#/definitions/Zone" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - ResponseMeta: - properties: - Contact: - description: Microservice Contact Info - type: string - Copyright: - description: Copyright Info - type: string - License: - description: License Information and Restrictions - type: string - OperationID: - description: Operation ID - type: string - RequestIP: - description: Request IP Address - type: string - RequestType: - description: Request Type - type: string - RequestURL: - description: Request URL - type: string - ServerInfo: - description: Data Server Info - type: string - ServerResponseTime: - description: Data Server Response Time (ms) - type: string - ServerTimestamp: - description: Backend Server Timestamp - type: string - TelnexusAccount: - description: - Telnexus Account Number used for recording transactions - type: string - type: object diff --git a/swagger/kazoo-telnexus.yaml b/swagger/kazoo-telnexus.yaml deleted file mode 100644 index 1c20286..0000000 --- a/swagger/kazoo-telnexus.yaml +++ /dev/null @@ -1,1343 +0,0 @@ -swagger: "2.0" -info: - version: 0.0.1 - title: voip - description: Telnexus VoIP Microservice - termsOfService: http://telnexus.com/terms/ - contact: - email: noc@telnexus.com - license: - name: Proprietary - Copyright (c) 2012-2020 by Telnexus LLC -securityDefinitions: - ApiKeyAuth: - type: apiKey - in: header - name: X-Auth-Token -security: - - ApiKeyAuth: [] -schemes: - - https -basePath: /v2 -host: api.zswitch.net:8443 -consumes: - - application/json -produces: - - application/json -responses: - GetDeviceResponse: - description: Kazoo response - schema: - $ref: "#/definitions/GetDeviceResponse" - GetNumberResponse: - description: Kazoo response - schema: - $ref: "#/definitions/GetNumberResponse" - GetAccountGroupResponse: - description: Kazoo response - schema: - $ref: "#/definitions/GetAccountGroupResponse" - GetAccountMediaResponse: - description: Kazoo response - schema: - $ref: "#/definitions/GetAccountMediaResponse" - GetAccountCallflowResponse: - description: Kazoo response - schema: - $ref: "#/definitions/GetAccountCallflowResponse" - GetAccountVmBoxResponse: - description: Kazoo response - schema: - $ref: "#/definitions/GetAccountVmBoxResponse" - GetAccountUserResponse: - description: Kazoo response - schema: - $ref: "#/definitions/GetAccountUserResponse" - GetAccountTimeRuleResponse: - description: Kazoo response - schema: - $ref: "#/definitions/GetAccountTimeRuleResponse" - GetKazooNumberResponse: - description: Kazoo response - schema: - $ref: "#/definitions/GetKazooNumberResponse" - GetAccountResponse: - description: Kazoo response - schema: - $ref: "#/definitions/GetAccountResponse" - GetAccountCdrResponse: - description: Kazoo response - schema: - $ref: "#/definitions/GetAccountCdrResponse" - GetAccountMenusResponse: - description: Kazoo response - schema: - $ref: "#/definitions/GetAccountMenusResponse" - GetAccountDescendentResponse: - description: Kazoo response - schema: - $ref: "#/definitions/GetAccountDescendentResponse" - AccessForbidden: - description: "Access forbidden, account lacks access" - schema: - $ref: "#/definitions/Error" - NotFound: - description: Resource was not found - schema: - $ref: "#/definitions/Error" - ServerError: - description: Server Internal Error - schema: - $ref: "#/definitions/Error" - Unauthorized: - description: "Access Unauthorized, invalid API-KEY was used" - schema: - $ref: "#/definitions/Error" - UnprocessableEntity: - description: "Unprocessable Entity, likely a bad parameter" - schema: - $ref: "#/definitions/Error" -parameters: - limitQuery: - default: 100 - description: - "How many objects to return at one time (max 300, default 100)" - format: int64 - in: query - name: limit - required: false - type: integer - offsetQuery: - default: 0 - description: How many objects to skip? (default 0) - format: int64 - in: query - name: offset - required: false - type: integer - startDateQuery: - type: number - format: int64 - in: query - name: created_from - required: true - endDateQuery: - type: number - format: int64 - in: query - name: created_to - required: true - accountIdPath: - type: string - in: path - name: accountId - required: true - userIdPath: - type: string - in: path - name: userId - required: true - prefixQuery: - name: prefix - type: number - format: int32 - in: query - required: false - quantityQuery: - name: quantity - type: number - format: int32 - in: query - required: false -paths: - /accounts/{accountId}: - get: - operationId: getAccounts - tags: - - Account - parameters: - - $ref: "#/parameters/accountIdPath" - responses: - "200": - $ref: "#/responses/GetAccountResponse" - "401": - $ref: "#/responses/Unauthorized" - "404": - $ref: "#/responses/NotFound" - /accounts/{accountId}/descendents: - get: - operationId: getAccountDescendents - tags: - - Account - parameters: - - $ref: "#/parameters/accountIdPath" - responses: - "200": - $ref: "#/responses/GetAccountDescendentResponse" - "401": - $ref: "#/responses/Unauthorized" - "404": - $ref: "#/responses/NotFound" - /accounts/{accountId}/users/{userId}/devices: - get: - operationId: getUserDevices - tags: - - Device - parameters: - - $ref: "#/parameters/accountIdPath" - - $ref: "#/parameters/userIdPath" - responses: - "200": - $ref: "#/responses/GetDeviceResponse" - "401": - $ref: "#/responses/Unauthorized" - "404": - $ref: "#/responses/NotFound" - /accounts/{accountId}/users: - get: - operationId: getAccountUsers - tags: - - User - parameters: - - $ref: "#/parameters/accountIdPath" - responses: - "200": - $ref: "#/responses/GetAccountUserResponse" - "401": - $ref: "#/responses/Unauthorized" - "404": - $ref: "#/responses/NotFound" - /accounts/{accountId}/vmboxes: - get: - operationId: getAccountVmBoxes - tags: - - User - parameters: - - $ref: "#/parameters/accountIdPath" - responses: - "200": - $ref: "#/responses/GetAccountVmBoxResponse" - "401": - $ref: "#/responses/Unauthorized" - "404": - $ref: "#/responses/NotFound" - /accounts/{accountId}/devices: - get: - operationId: getAccountDevices - tags: - - Device - parameters: - - $ref: "#/parameters/accountIdPath" - responses: - "200": - $ref: "#/responses/GetDeviceResponse" - "401": - $ref: "#/responses/Unauthorized" - "404": - $ref: "#/responses/NotFound" - /accounts/{accountId}/media: - get: - operationId: getAccountMedia - tags: - - Media - parameters: - - $ref: "#/parameters/accountIdPath" - responses: - "200": - $ref: "#/responses/GetAccountMediaResponse" - "401": - $ref: "#/responses/Unauthorized" - "404": - $ref: "#/responses/NotFound" - /accounts/{accountId}/temporal_rules: - get: - operationId: getAccountTimeRules - tags: - - TimeRule - parameters: - - $ref: "#/parameters/accountIdPath" - responses: - "200": - $ref: "#/responses/GetAccountTimeRuleResponse" - "401": - $ref: "#/responses/Unauthorized" - "404": - $ref: "#/responses/NotFound" - /accounts/{accountId}/menus: - get: - operationId: getAccountMenus - tags: - - Menu - parameters: - - $ref: "#/parameters/accountIdPath" - responses: - "200": - $ref: "#/responses/GetAccountMenusResponse" - "401": - $ref: "#/responses/Unauthorized" - "404": - $ref: "#/responses/NotFound" - /accounts/{accountId}/phone_numebers: - get: - operationId: getAccountNumbers - tags: - - PhoneNumber - parameters: - - $ref: "#/parameters/accountIdPath" - responses: - "200": - $ref: "#/responses/GetNumberResponse" - "401": - $ref: "#/responses/Unauthorized" - "404": - $ref: "#/responses/NotFound" - /phone_numebers: - get: - operationId: getKazooNumbers - tags: - - PhoneNumber - parameters: - - $ref: "#/parameters/prefixQuery" - - $ref: "#/parameters/quantityQuery" - responses: - "200": - $ref: "#/responses/GetKazooNumberResponse" - "401": - $ref: "#/responses/Unauthorized" - "404": - $ref: "#/responses/NotFound" - /accounts/{accountId}/groups: - get: - operationId: getAccountGroups - tags: - - Group - parameters: - - $ref: "#/parameters/accountIdPath" - responses: - "200": - $ref: "#/responses/GetAccountGroupResponse" - "401": - $ref: "#/responses/Unauthorized" - "404": - $ref: "#/responses/NotFound" - /accounts/{accountId}/callflows: - get: - operationId: getAccountCallflows - tags: - - CallFlow - parameters: - - $ref: "#/parameters/accountIdPath" - responses: - "200": - $ref: "#/responses/GetAccountCallflowResponse" - "401": - $ref: "#/responses/Unauthorized" - "404": - $ref: "#/responses/NotFound" - /accounts/{accountId}/cdrs: - get: - operationId: getAccountCDRs - tags: - - cdr - parameters: - - $ref: "#/parameters/accountIdPath" - - $ref: "#/parameters/startDateQuery" - - $ref: "#/parameters/endDateQuery" - responses: - "200": - $ref: "#/responses/GetAccountCdrResponse" - "401": - $ref: "#/responses/Unauthorized" - "404": - $ref: "#/responses/NotFound" -definitions: - Error: - properties: - code: - format: int32 - type: integer - fields: - type: string - message: - type: string - type: object - GetAccountCdrResponse: - properties: - auth_token: - type: string - data: - items: - properties: - authorizing_id: - example: f9627ff1bcca2d112931ee00dcfdb0c6 - type: string - billing_seconds: - example: 0 - type: number - bridge_id: - example: 1967142278_134071066@67.231.5.176 - type: string - call_id: - example: 2b35a5ec-43a1-11ea-99b1-ed64c60fd1ac - type: string - call_priority: - example: "" - type: string - call_type: - example: "" - type: string - callee_id_name: - example: Telnexus - type: string - callee_id_number: - example: "+15108597000" - type: string - caller_id_name: - example: Unavailable - type: string - caller_id_number: - example: "+17045943795" - type: string - calling_from: - example: "+17045943795" - type: string - cost: - example: "0" - type: string - datetime: - example: "2020-01-30 20:43:28" - type: string - dialed_number: - example: user_jaemid - type: string - direction: - example: outbound - type: string - duration_seconds: - example: 15 - type: number - from: - example: +17045943795@e0f5f0.s.zswitch.net - type: string - hangup_cause: - example: ORIGINATOR_CANCEL - type: string - id: - example: 202001-2b35a5ec-43a1-11ea-99b1-ed64c60fd1ac - type: string - interaction_id: - example: 63747636207-cc274afb - type: string - iso_8601: - example: "2020-01-30" - type: string - iso_8601_combined: - example: "2020-01-30T20:43:28Z" - type: string - media_server: - example: fs004.ord.p.zswitch.net - type: string - other_leg_call_id: - example: 1967142278_134071066@67.231.5.176 - type: string - owner_id: - example: c0a881b0dfbc7fc574cb67dcaf10879f - type: string - rate: - example: "0.0" - type: string - rate_name: - example: "" - type: string - recording_url: - example: "" - type: string - request: - example: user_jaemid@e0f5f0.s.zswitch.net - type: string - rfc_1036: - example: "Thu, 30 Jan 2020 20:43:28 GMT" - type: string - timestamp: - example: "63747636208" - type: string - to: - example: user_jaemid@e0f5f0.s.zswitch.net - type: string - unix_timestamp: - example: "1580417008" - type: string - type: object - type: array - node: - example: dqZFtHthbelyE8MI6vU-LA - type: string - page_size: - example: "534" - type: string - request_id: - example: e7897c563fb45f3b377046d9b54c3cb5 - type: string - start_key: - example: g2wAAAACbgUAAOqn1w5oAWpq - type: string - status: - example: success - type: string - timestamp: - example: "2020-05-07T01:06:49Z" - type: string - version: - example: 4.3.103 - type: string - GetAccountCallflowResponse: - properties: - auth_token: - example: >- - eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6ImM2M2I1NjY5YmE0NTQzZWVmMTE5OTc3ZTUyNDYxYzRlIn0.eyJpc3MiOiJrYXpvbyIsImlkZW50aXR5X3NpZyI6InJUMW5DNnNOOHNKQWp4blBSSk1LVE5Ed1ZEQWZwek9sSFBnb0FYTHgtQU0iLCJhY2NvdW50X2lkIjoiYTY2ZjJiN2E0MDk0NGI3NDRkY2M2M2NhNmYxMGY0N2EiLCJvd25lcl9pZCI6IjUwOTE2MWZmMmE1NzZiZDZhYmU1YjhjNzVmNmIxNWYwIiwibWV0aG9kIjoiY2JfdXNlcl9hdXRoIiwiZXhwIjoxNTg4ODE0OTcwfQ.cW38X_JKe_bToQ19LzPY1U4aqjf96cFSwkszhqMhdpoR2Kq5JuPxkuCWoG6q49lwpIHb_9mZyoYBG83eLnYkamcORoejyUDb0ob79VKMBAUHAlXPkMNz7H2apLEHp0O8bdxr8ymh0Il9I4nAZSVnPkufQpx8L41Oy_ovU0vHS0jb2dSeXsySO0qcrCsoR9psTtqvB1GZBCEO8S_9EJKpYaT3o-Kio8uHZh7HgCD3NCUbfW8emfE6omTFIzIY7FTwXM_4kaMbWTUv09nN7iIpxJw2r_2drT-V5K8GFXZLAvm_1CqtLOMTYb26i3Iae3-zh9GPANSU3O0fq79kKupHfw - type: string - data: - items: - properties: - featurecode: - properties: - name: - example: park_and_retrieve - type: string - number: - example: "3" - type: string - type: object - id: - example: ff059d91a6fe0d16ced1ef6ca1f2bc52 - type: string - modules: - example: - - park - items: - type: string - type: array - name: - example: 2004 - Vern iPad - type: string - numbers: - example: - - "2004" - items: - type: string - type: array - patterns: - example: - - '^\*3([0-9]*)$' - items: - type: string - type: array - type: object - type: array - node: - example: dqZFtHthbelyE8MI6vU-LA - type: string - page_size: - example: 34 - type: number - request_id: - example: 3aa5241a8f3150258750425ce3c5c767 - type: string - revision: - example: c10c73dd4f798fb595267e1d1c4eb9ff - type: string - status: - example: success - type: string - timestamp: - example: "2020-05-07T00:53:40Z" - type: string - version: - example: 4.3.103 - type: string - GetAccountDescendentResponse: - properties: - auth_token: - example: >- - eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6ImM2M2I1NjY5YmE0NTQzZWVmMTE5OTc3ZTUyNDYxYzRlIn0.eyJpc3MiOiJrYXpvbyIsImlkZW50aXR5X3NpZyI6InJUMW5DNnNOOHNKQWp4blBSSk1LVE5Ed1ZEQWZwek9sSFBnb0FYTHgtQU0iLCJhY2NvdW50X2lkIjoiYTY2ZjJiN2E0MDk0NGI3NDRkY2M2M2NhNmYxMGY0N2EiLCJvd25lcl9pZCI6IjUwOTE2MWZmMmE1NzZiZDZhYmU1YjhjNzVmNmIxNWYwIiwibWV0aG9kIjoiY2JfdXNlcl9hdXRoIiwiZXhwIjoxNTg4ODA3NjcyfQ.rsxUwAef3JnHzTc4eckxIx_RToGbNsKr3WVUoVDEPQ7slKLxhpfDTrNqXQ_kou-1646Z539YQCQGRsB5One4BfEDAfhAmH63d6jKwEU49yQUiZCBn8tbuzN4iiZmYn6z8wmqUQHO2KA3fo6IKrjggs3t1EK8iG05se4ltS21ZVQ-C0HVvvENoERu9iKEcM2SeKhl9Ucl3cqQpWRKBN9BEvTKpuXqM_Bkf2FiczQ3TJQ2SS0YJTYjoIKnOLHfM4H59ZcPwnTh0S3zplJ8e6dQv6t020x0gVYdA_U9EseIGhNQTtMEAztwleZJwdpBh6kiDxJb9-l4ENX4kFtvxsH4QQ - type: string - data: - items: - properties: - id: - example: 7cebd991bd99ffd909dbb08a7d8e2db4 - type: string - name: - example: Affinity - type: string - realm: - example: b5df22.s.zswitch.net - type: string - tree: - example: - - fb7cc960d5037466992af0e9504d0b27 - - d4804caa6d7a78c83ff2bc7fdf646398 - - 33776f3f94eb642c81e199cf5f1059ae - - a66f2b7a40944b744dcc63ca6f10f47a - items: - type: string - type: array - type: object - type: array - node: - example: dqZFtHthbelyE8MI6vU-LA - type: string - page_size: - example: 48 - type: number - request_id: - example: 0035dec0e0e4c486e3bcd4502cf6a95d - type: string - revision: - example: b3a4cb72580c7c2f93572a6ef2748b74 - type: string - start_key: - example: g20AAAAA - type: string - status: - example: success - type: string - timestamp: - example: "2020-05-06T23:01:48Z" - type: string - version: - example: 4.3.103 - type: string - type: object - GetAccountResponse: - properties: - auth_token: - example: >- - eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6ImM2M2I1NjY5YmE0NTQzZWVmMTE5OTc3ZTUyNDYxYzRlIn0.eyJpc3MiOiJrYXpvbyIsImlkZW50aXR5X3NpZyI6InJUMW5DNnNOOHNKQWp4blBSSk1LVE5Ed1ZEQWZwek9sSFBnb0FYTHgtQU0iLCJhY2NvdW50X2lkIjoiYTY2ZjJiN2E0MDk0NGI3NDRkY2M2M2NhNmYxMGY0N2EiLCJvd25lcl9pZCI6IjUwOTE2MWZmMmE1NzZiZDZhYmU1YjhjNzVmNmIxNWYwIiwibWV0aG9kIjoiY2JfdXNlcl9hdXRoIiwiZXhwIjoxNTg4ODA3NjcyfQ.rsxUwAef3JnHzTc4eckxIx_RToGbNsKr3WVUoVDEPQ7slKLxhpfDTrNqXQ_kou-1646Z539YQCQGRsB5One4BfEDAfhAmH63d6jKwEU49yQUiZCBn8tbuzN4iiZmYn6z8wmqUQHO2KA3fo6IKrjggs3t1EK8iG05se4ltS21ZVQ-C0HVvvENoERu9iKEcM2SeKhl9Ucl3cqQpWRKBN9BEvTKpuXqM_Bkf2FiczQ3TJQ2SS0YJTYjoIKnOLHfM4H59ZcPwnTh0S3zplJ8e6dQv6t020x0gVYdA_U9EseIGhNQTtMEAztwleZJwdpBh6kiDxJb9-l4ENX4kFtvxsH4QQ - type: string - data: - properties: - available_apps: - example: - - voip - - cluster - - userportal - - accounts - - developer - - pbxs - - numbers - items: - type: string - type: array - billing_id: - example: a66f2b7a40944b744dcc63ca6f10f47a - type: string - billing_mode: - example: manual - type: string - call_restriction: - properties: - caribbean: - properties: - action: - example: inherit - type: string - type: object - did_us: - properties: - action: - example: inherit - type: string - type: object - directory: - properties: - action: - example: inherit - type: string - type: object - emergency: - properties: - action: - example: inherit - type: string - type: object - international: - properties: - action: - example: inherit - type: string - type: object - toll_us: - properties: - action: - example: inherit - type: string - type: object - tollfree_us: - properties: - action: - example: inherit - type: string - type: object - unknown: - properties: - action: - example: inherit - type: string - type: object - type: object - caller_id: - properties: - emergency: - properties: - name: - example: Telnexus - type: string - number: - example: "+15109911114" - type: string - type: object - external: - properties: - name: - example: Telnexus - type: string - number: - example: "+15109911114" - type: string - type: object - type: object - contact: - properties: - billing: - properties: - email: - example: noc@telnexus.com - type: string - name: - example: "" - type: string - number: - example: "5108597000" - type: string - type: object - technical: - properties: - email: - example: noc@telnexus.com - type: string - number: - example: "5108497000" - type: string - type: object - type: object - created: - example: 63552627756 - format: int64 - type: number - descendants_count: - example: 48 - type: number - enabled: - example: true - type: boolean - format_from_uri: - example: false - type: boolean - id: - example: a66f2b7a40944b744dcc63ca6f10f47a - type: string - is_reseller: - example: false - type: boolean - language: - example: en-us - type: string - media: - properties: - bypass_media: - example: auto - type: string - type: object - name: - example: Telnexus Direct - type: string - notification_preference: - example: teletype - type: string - notifications: - properties: - fax_to_email: - properties: - service_name: - example: support@telnexus.com - type: string - service_provider: - example: support@telnexus.com - type: string - service_url: - example: telnexus.com - type: string - support_email: - example: support@telnexus.com - type: string - support_number: - example: 510-991-1114 - type: string - type: object - low_balance: - properties: - sent_low_balance: - example: false - type: boolean - type: object - voicemail_to_email: - properties: - service_name: - example: support@telnexus.com - type: string - service_provider: - example: support@telnexus.com - type: string - service_url: - example: telnexus.com - type: string - support_email: - example: support@telnexus.com - type: string - support_number: - example: 510-991-1114 - type: string - type: object - type: object - provision: - properties: - admin_password: - type: string - type: object - realm: - example: f5b70e.s.zswitch.net - type: string - reseller_id: - example: 33776f3f94eb642c81e199cf5f1059ae - type: string - superduper_admin: - example: false - type: boolean - timezone: - example: America/Los_Angeles - type: string - ui_metadata: - properties: - origin: - example: accounts - type: string - ui: - example: monster-ui - type: string - version: - example: 4.1-56 - type: string - type: object - ui_restrictions: - properties: - myaccount: - properties: - account: - properties: - show_tab: - example: true - type: boolean - type: object - balance: - properties: - show_credit: - example: true - type: boolean - show_header: - example: true - type: boolean - show_minutes: - example: true - type: boolean - show_tab: - example: true - type: boolean - type: object - billing: - properties: - show_tab: - example: true - type: boolean - type: object - errorTracker: - properties: - show_tab: - example: true - type: boolean - type: object - inbound: - properties: - show_tab: - example: true - type: boolean - type: object - outbound: - properties: - show_tab: - example: true - type: boolean - type: object - service_plan: - properties: - show_tab: - example: true - type: boolean - type: object - transactions: - properties: - show_tab: - example: true - type: boolean - type: object - twoway: - properties: - show_tab: - example: true - type: boolean - type: object - user: - properties: - show_tab: - example: true - type: boolean - type: object - type: object - type: object - wnm_allow_additions: - example: false - type: boolean - type: object - node: - example: dqZFtHthbelyE8MI6vU-LA - type: string - request_id: - example: 1bea6f4e37f65627452f9798d8398385 - type: string - revision: - example: 270-8664316349384947d416dc00285fb532 - type: string - status: - example: success - type: string - timestamp: - example: "2020-05-06T22:42:58Z" - type: string - version: - example: 4.3.103 - type: string - type: object - GetDeviceResponse: - properties: - page_size: - type: number - example: 4 - data: - type: array - items: - type: object - properties: - id: - type: string - example: "f9627ff1bcca2d112931ee00dcfdb0c6" - name: - type: string - example: "2007 - Vern iPhone Personal" - username: - type: string - example: "user_jaemid" - mac_address: - type: string - example: string - owner_id: - type: string - example: "c0a881b0dfbc7fc574cb67dcaf10879f" - enabled: - type: "boolean" - example: true - device_type: - type: string - example: "softphone" - revision: - type: string - example: "794a8debed3fca4330ba2373cd703773" - timestamp: - type: string - example: "2020-05-07T01:20:21Z" - version: - type: string - example: "4.3.103" - node: - type: string - example: "dqZFtHthbelyE8MI6vU-LA" - request_id: - type: string - example: "29c9cccc07016866243a9dbd9481c88a" - status: - type: string - example: "success" - auth_token: - type: string - GetAccountGroupResponse: - properties: - page_size: - type: number - example: 3 - data: - type: array - items: - type: object - properties: - id: - type: string - example: "e9e0627a0d41c4be4e8fa65a6d4777aa" - name: - type: string - example: "Berkeley Office" - endpoints: - type: number - example: 5 - revision: - type: string - example: "ac7c6fde786a11c16c4dd265eccb9aa5" - timestamp: - type: string - example: "2020-05-07T01:36:50Z" - version: - type: string - example: "4.3.103" - node: - type: string - example: "dqZFtHthbelyE8MI6vU-LA" - request_id: - type: string - example: "22d1269690b8a553106e929bd8923a55" - status: - type: string - example: "success" - auth_token: - type: string - GetAccountMediaResponse: - properties: - page_size: - type: number - example: 49 - data: - type: array - items: - type: object - properties: - id: - type: string - example: "fea26d66047257e74c132092b149e533" - name: - type: string - example: "test" - media_source: - type: string - example: "tts" - language: - type: string - example: "en-us" - is_prompt: - type: "boolean" - example: false - revision: - type: string - example: "b74319c4b8fb8cdba510362fa98facf0" - timestamp: - type: string - example: "2020-05-07T01:41:49Z" - version: - type: string - example: "4.3.103" - node: - type: string - example: "dqZFtHthbelyE8MI6vU-LA" - request_id: - type: string - example: "6e6dc6f474d1aa1689ac27a3c0605b38" - status: - type: string - example: "success" - auth_token: - type: string - GetAccountMenusResponse: - properties: - page_size: - type: number - example: 18 - data: - type: array - items: - type: object - properties: - id: - type: string - example: "fe46dd5b556ce876ce693b2d49b6402d" - name: - type: string - example: "RecordingStudio" - revision: - type: string - example: "d512f1f2cff2684eec3825938f23275b" - timestamp: - type: string - example: "2020-05-07T01:53:07Z" - version: - type: string - example: "4.3.103" - node: - type: string - example: "dqZFtHthbelyE8MI6vU-LA" - request_id: - type: string - example: "36c57100bce810968df34f77465e974a" - status: - type: string - example: "success" - auth_token: - type: string - GetNumberResponse: - properties: - page_size: - type: number - example: 117 - data: - properties: - numbers: - properties: - numberitem: - properties: - state: - type: string - example: "in_service" - features: - type: array - items: - type: string - example: - - "local" - assigned_to: - type: string - example: "a66f2b7a40944b744dcc63ca6f10f47a" - created: - type: number - example: 63714718327 - updated: - type: number - example: 63755492918 - features_available: - type: array - items: - type: string - example: - - "cnam" - - "e911" - - "force_outbound" - - "port" - - "prepend" - - "ringback" - type: object - type: object - cascade_quantity: - type: number - example: 61 - type: object - revision: - type: string - example: "7c9f4f30f97ba288bad4f0f620e9e0bc" - timestamp: - type: string - example: "2020-05-07T01:56:53Z" - version: - type: string - example: "4.3.103" - node: - type: string - example: "dqZFtHthbelyE8MI6vU-LA" - request_id: - type: string - example: "a73973839c028f42519105681482b64f" - status: - type: string - example: "success" - auth_token: - type: string - GetKazooNumberResponse: - properties: - data: - type: array - items: - type: object - properties: - number: - type: string - example: "+15183486324" - state: - type: string - example: "discovery" - timestamp: - type: string - example: "2020-05-07T02:30:03Z" - version: - type: string - example: "4.3.103" - node: - type: string - example: "dqZFtHthbelyE8MI6vU-LA" - request_id: - type: string - example: "b310489bd3933c740590b2dcec953de8" - status: - type: string - example: "success" - auth_token: - type: string - GetAccountTimeRuleResponse: - properties: - page_size: - type: number - example: 1 - data: - type: array - items: - type: object - properties: - id: - type: string - example: "1c3939fd0afcdadaa2986bc61c787d03" - name: - type: string - example: "Business Hours" - revision: - type: string - example: "b694bae5e001d52cf40637b618bc6bfb" - timestamp: - type: string - example: "2020-05-07T02:43:06Z" - version: - type: string - example: "4.3.103" - node: - type: string - example: "dqZFtHthbelyE8MI6vU-LA" - request_id: - type: string - example: "7372ec1ec4dc316cd0a8cf6786defde6" - status: - type: string - example: "success" - auth_token: - type: string - GetAccountUserResponse: - properties: - page_size: - type: number - example: 4 - data: - type: array - items: - type: object - properties: - id: - type: string - example: "8c571470fef7db363994c8427c07b7bb" - features: - type: array - items: - type: string - example: - - "vm_to_email" - username: - type: string - example: "phil" - email: - type: string - example: "reception@telnexus.com" - first_name: - type: string - example: "Phil" - last_name: - type: string - example: "Cranepool" - priv_level: - type: string - example: "user" - timezone: - type: string - example: "America/Los_Angeles" - revision: - type: string - example: "c989520cf895f314b32d163d3b59d723" - timestamp: - type: string - example: "2020-05-07T02:44:28Z" - version: - type: string - example: "4.3.103" - node: - type: string - example: "dqZFtHthbelyE8MI6vU-LA" - request_id: - type: string - example: "c11b939a99b181b3a09b7770c4e49302" - status: - type: string - example: "success" - auth_token: - type: string - GetAccountVmBoxResponse: - properties: - page_size: - type: number - example: 5 - data: - type: array - items: - type: object - properties: - id: - type: string - example: "cbd3606fea91c9b834c5a1fc0efa1098" - name: - type: string - example: "2005 - Bill VM" - mailbox: - type: string - example: "2005" - owner_id: - type: string - example: "f95626ebc2db4fd1a2b5ac5f6b11f7a3" - messages: - type: number - example: 12 - revision: - type: string - example: "171c5eb1c826f66fe16cfb0669f55994" - timestamp: - type: string - example: "2020-05-07T02:52:10Z" - version: - type: string - example: "4.3.103" - node: - type: string - example: "dqZFtHthbelyE8MI6vU-LA" - request_id: - type: string - example: "0452de0d2fbef2cbccafaf7b3894bc0b" - status: - type: string - example: "success" - auth_token: - type: string diff --git a/swagger/sf-gate-kvision.yaml b/swagger/sf-gate-kvision.yaml new file mode 100644 index 0000000..94620cd --- /dev/null +++ b/swagger/sf-gate-kvision.yaml @@ -0,0 +1,2427 @@ +swagger: "2.0" +info: + title: "sf-gate" + version: 1.2.7 + description: "Salesforce Gateway Microservice" + termsOfService: "http://taxnexus.net/terms/" + contact: + email: "noc@taxnexus.net" + license: + name: "Proprietary - Copyright (c) 2018-2021 by Taxnexus, Inc." +schemes: + - "http" +basePath: "/v1" +host: "sf-gate.fabric.tnxs.net:8080" +securityDefinitions: + ApiKeyAuth: + type: apiKey + in: header + name: X-API-Key +security: + - ApiKeyAuth: [] +consumes: + - application/json +produces: + - application/json +parameters: + accountIdQuery: + description: + Taxnexus Id of the Account to be used a record retrieval + in: query + name: accountId + required: false + type: string + accountIdQueryRequired: + description: + Taxnexus Id of the Account to be used a record retrieval + in: query + name: accountId + required: true + type: string + accountNumberQuery: + description: + The Taxnexus Account Number of the Account to be used a record + retrieval + in: query + name: accountNumber + required: false + type: string + accountRequest: + description: A request with an array of Account Objects + in: body + name: accountRequest + required: true + schema: + $ref: "#/definitions/AccountRequest" + accountTypeQuery: + description: The Type of this Object + enum: + - channel_partner_member + - channel_partner_prospect + - new + - other + - system + - tax_administrator_member + - tax_administrator_prospect + - taxpayer_customer + - taxpayer_prospect + in: query + name: type + required: false + type: string + activeQuery: + description: Retrieve only active records? + in: query + name: active + required: false + type: boolean + addressQuery: + description: Postal Address URL encoded; partial addresses allowed + in: query + name: address + required: false + type: string + apiKeyQuery: + description: Taxnexus Id of the User to be retrieved + in: query + name: apikey + required: false + type: string + authorityIdQuery: + description: Taxnexus Id of the Authority to be retrieved + in: query + name: authorityId + required: false + type: string + authorityRequestBody: + description: A request with an array of Authority Objects + in: body + name: authorityRequest + required: true + schema: + $ref: "#/definitions/AuthorityRequest" + roleIdQuery: + description: Taxnexus Id of the Role to be retrieved + in: query + name: roleId + required: false + type: string + backendIdQuery: + description: Taxnexus Id of the Backend to be retrieved + in: query + name: backendId + required: false + type: string + cashReceiptIdQuery: + description: Taxnexus Record Id of a Cash Receipt + in: query + name: cashReceiptId + required: false + type: string + clusterIdQuery: + description: Taxnexus Record Id of a Cluster + in: query + name: clusterId + required: false + type: string + databaseIdQuery: + description: Taxnexus Record Id of a Database + in: query + name: databaseId + required: false + type: string + tenantIdQuery: + description: Taxnexus Record Id of a Tenant + in: query + name: tenantId + required: false + type: string + tenantRequest: + description: An array of Tenant records + in: body + name: CTenantRequest + required: true + schema: + $ref: "#/definitions/TenantRequest" + companyIdQuery: + description: Taxnexus Id of the Company to be retrieved + in: query + name: companyId + required: false + type: string + contactIdQuery: + description: Taxnexus Id of the Contact to be retrieved + in: query + name: contactId + required: false + type: string + contactRequest: + description: An array of new Contact records + in: body + name: contactsRequest + required: true + schema: + $ref: "#/definitions/ContactRequest" + countryIdQuery: + description: The Country Taxnexus ID + in: query + name: countryId + required: false + type: string + countryQuery: + description: The Country abbreviation (2 char) + in: query + name: country + required: false + type: string + countyIdQuery: + description: The County Taxnexus ID + in: query + name: countyId + required: false + type: string + countyQuery: + description: The County Name + in: query + name: county + required: false + type: string + dateFromQuery: + description: The Starting Date for an object retrieval + in: query + name: dateFrom + required: false + type: string + dateToQuery: + description: The Ending Date for an object retrieval + in: query + name: dateTo + required: false + type: string + documentIdQuery: + description: Taxnexus Id of the Document to be retrieved + in: query + name: documentId + required: false + type: string + domainIdQuery: + description: Taxnexus Id of the Domain to be retrieved + in: query + name: domainId + required: false + type: string + domainQuery: + description: "The Tax Domain to rate (cannabis, sales or telecom)" + in: query + name: name + required: false + type: string + filingIdQuery: + description: Taxnexus Id of the Filing to be retrieved + in: query + name: filingId + required: false + type: string + filingTypeIdQuery: + description: Taxnexus Record Id of a Filing + in: query + name: filingTypeId + required: false + type: string + glBalanceIdQueryRequired: + description: Taxnexus Id of a GL Balance Record + in: query + name: glbalanceId + required: true + type: string + idRequestBody: + description: An array of existing Taxnexus Record IDs + in: body + name: idsRequest + required: true + schema: + $ref: "#/definitions/IdsRequest" + ingestIdQuery: + description: Taxnexus Record Id of an Ingest + in: query + name: ingestId + required: false + type: string + invoiceIdQuery: + description: Taxnexus Id of the Invoice to be retrieved + in: query + name: invoiceId + required: false + type: string + jobIdQuery: + description: Taxnexus Record Id of a Job record + in: query + name: jobId + required: false + type: string + licenseIdQuery: + description: Taxnexus Id of the License to be retrieved + in: query + name: licenseId + required: false + type: string + licenseTypeIdQuery: + description: Taxnexus Id of the License Type to be retrieved + in: query + name: licensetypeId + required: false + type: string + limitQuery: + description: "How many objects to return at one time" + format: int64 + in: query + name: limit + required: false + type: integer + masterQuery: + description: Retrieve only master records? + in: query + name: master + required: false + type: boolean + nameQuery: + description: The Name of this Object + in: query + name: name + required: false + type: string + offsetQuery: + description: How many objects to skip? (default 0) + format: int64 + in: query + name: offset + required: false + type: integer + orderIdQuery: + description: Taxnexus Id of the Company to be retrieved + in: query + name: orderId + required: false + type: string + periodIdQuery: + description: Taxnexus Id of the Period to be used a record retrieval + in: query + name: periodId + required: false + type: string + periodIdQueryRequired: + description: + Taxnexus Id of the Period to be used in a record retrieval + in: query + name: periodId + required: true + type: string + periodNameQueryRequired: + description: The Taxnexus Accounting Period + in: query + name: period + required: false + type: string + placeIdQuery: + description: The City name (must be accompanied by State) + in: query + name: placeId + required: false + type: string + placeQuery: + description: The City name (must be accompanied by State) + in: query + name: place + required: false + type: string + poIdQuery: + description: Taxnexus Id of the Purchase Order to be retrieved + in: query + name: poId + required: false + type: string + productIdQuery: + description: + Taxnexus Id of the Account to be used a record retrieval + in: query + name: productId + required: false + type: string + productRequestBody: + description: A request with an array of Product Objects + in: body + name: productRequest + required: true + schema: + $ref: "#/definitions/ProductRequest" + productdQuery: + description: Taxnexus Id of the Product to be retrieved + in: query + name: productId + required: false + type: string + quoteIdQuery: + description: Taxnexus Id of the Company to be retrieved + in: query + name: quoteId + required: false + type: string + serviceIdQuery: + description: Service ID + in: query + name: serviceId + type: string + stateIdQuery: + description: The State or Province abbreviation (2 char) + in: query + name: stateId + required: false + type: string + stateQuery: + description: The State or Province abbreviation (2 char) + in: query + name: state + required: false + type: string + statementIdQuery: + description: Taxnexus Id of the Company to be retrieved + in: query + name: statementId + required: false + type: string + submissionIdQuery: + description: Taxnexus Id of the Submisssion to be retrieved + in: query + name: submissionId + required: false + type: string + subscriptionIdQuery: + description: Taxnexus Id of the Subscription to be retrieved + in: query + name: subscriptionId + required: false + type: string + taxTypeAccountIdQuery: + description: Taxnexus Id of the Tax Type Account to be retrieved + in: query + name: taxtypeaccountId + required: false + type: string + taxTypeIdQuery: + description: Taxnexus Id of the Tax Type to be retrieved + in: query + name: taxtypeId + required: false + type: string + taxnexuscodeIdQuery: + description: Taxnexus Id of the Taxnexus Code to be retrieved + in: query + name: taxnexuscodeId + required: false + type: string + templateIdQuery: + description: Taxnexus Record Id of a Template + in: query + name: templateId + required: false + type: string + typeQuery: + description: The Type of this Object + in: query + name: type + required: false + type: string + userIdQuery: + description: Taxnexus Id of the User to be retrieved + in: query + name: userId + required: false + type: string + notebookIdQuery: + description: Template ID + in: query + name: notebookId + type: string + notebookRequest: + description: An array of Notebook records + in: body + name: NotebookRequest + required: true + schema: + $ref: "#/definitions/NotebookRequest" +responses: + AccessForbidden: + description: "Access forbidden, account lacks access" + schema: + $ref: "#/definitions/Error" + AccountResponse: + description: Taxnexus Response with Account objects + schema: + $ref: "#/definitions/AccountResponse" + TenantResponse: + description: Taxnexus Response with Tenant objects + schema: + $ref: "#/definitions/TenantResponse" + CompanyResponse: + description: Taxnexus Response with Company objects + schema: + $ref: "#/definitions/CompanyResponse" + Conflict: + description: Conflict + schema: + $ref: "#/definitions/Error" + ContactResponse: + description: An array of Contact objects + schema: + $ref: "#/definitions/ContactResponse" + DeleteResponse: + description: An array of Message Objects with Delete Status + schema: + properties: + data: + items: + $ref: "#/definitions/Message" + type: array + meta: + $ref: "#/definitions/ResponseMeta" + type: object + InvalidDataError: + description: Invalid data was sent + schema: + $ref: "#/definitions/InvalidError" + NotFound: + description: Resource was not found + schema: + $ref: "#/definitions/Error" + ProductResponse: + description: An array of Product objects + schema: + $ref: "#/definitions/ProductResponse" + RoleResponse: + description: Taxnexus Response with Role objects + schema: + $ref: "#/definitions/RoleResponse" + ServerError: + description: Server Internal Error + schema: + $ref: "#/definitions/Error" + TemplateResponse: + description: Taxnexus Response with Template objects + schema: + $ref: "#/definitions/TemplateResponse" + Unauthorized: + description: "Access unauthorized, invalid API-KEY was used" + schema: + $ref: "#/definitions/Error" + UnprocessableEntity: + description: "Unprocessable Entity, likely a bad parameter" + schema: + $ref: "#/definitions/Error" + UserResponse: + description: Taxnexus Response with User objects + schema: + $ref: "#/definitions/UserResponse" + NotebookResponse: + description: Taxnexus Response with Notebook objects + schema: + $ref: "#/definitions/NotebookResponse" +paths: + /accounts: + get: + description: Return a list of Accounts + operationId: getAccounts + parameters: + - $ref: "#/parameters/accountIdQuery" + - $ref: "#/parameters/activeQuery" + - $ref: "#/parameters/limitQuery" + - $ref: "#/parameters/offsetQuery" + responses: + "200": + $ref: "#/responses/AccountResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + summary: Get a list of accounts + tags: + - Accounts + post: + description: Account record to be added + operationId: postAccounts + parameters: + - $ref: "#/parameters/accountRequest" + responses: + "200": + $ref: "#/responses/AccountResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "500": + $ref: "#/responses/ServerError" + summary: Add a new account to Taxnexus + tags: + - Accounts + put: + description: Update a single account specified by accountId + operationId: putAccount + parameters: + - $ref: "#/parameters/accountRequest" + responses: + "200": + $ref: "#/responses/AccountResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "500": + $ref: "#/responses/ServerError" + summary: Update a single account + tags: + - Accounts + /roles: + get: + description: Return a list of Roles + operationId: getRoles + parameters: + - $ref: "#/parameters/limitQuery" + - $ref: "#/parameters/offsetQuery" + - $ref: "#/parameters/roleIdQuery" + responses: + "200": + $ref: "#/responses/RoleResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + summary: Get a list of Roles + tags: + - Roles + /tenants: + get: + description: Return a list of Tenant records from the datastore + operationId: getTenants + parameters: + - $ref: "#/parameters/tenantIdQuery" + - $ref: "#/parameters/companyIdQuery" + - $ref: "#/parameters/limitQuery" + - $ref: "#/parameters/offsetQuery" + responses: + "200": + $ref: "#/responses/TenantResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + summary: Get a list Tenants + tags: + - Tenants + post: + description: Create Tenants in Taxnexus + operationId: Tenants + parameters: + - $ref: "#/parameters/tenantRequest" + responses: + "200": + $ref: "#/responses/TenantResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + summary: Create new Tenants + tags: + - Tenants + put: + description: Update Tenant in Taxnexus + operationId: putTenants + parameters: + - $ref: "#/parameters/tenantRequest" + responses: + "200": + $ref: "#/responses/TenantResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + summary: Update Tenants + tags: + - Tenants + /companies: + get: + description: Retrieve a Company record from the datastore + operationId: getCompanies + parameters: + - $ref: "#/parameters/companyIdQuery" + - $ref: "#/parameters/limitQuery" + - $ref: "#/parameters/offsetQuery" + responses: + "200": + $ref: "#/responses/CompanyResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + summary: Get a Company record + tags: + - Companies + /contacts: + delete: + description: Delete Taxnexus Contact record + operationId: deleteContact + parameters: + - $ref: "#/parameters/contactIdQuery" + responses: + "200": + $ref: "#/responses/DeleteResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "500": + $ref: "#/responses/ServerError" + summary: Delete a Contact + tags: + - Contacts + get: + description: Return a list of all available Contacts + operationId: getContacts + parameters: + - $ref: "#/parameters/accountIdQuery" + - $ref: "#/parameters/activeQuery" + - $ref: "#/parameters/companyIdQuery" + - $ref: "#/parameters/contactIdQuery" + - $ref: "#/parameters/limitQuery" + - $ref: "#/parameters/offsetQuery" + responses: + "200": + $ref: "#/responses/ContactResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + summary: Get a list of contacts + tags: + - Contacts + post: + description: Contact record to be added + operationId: postContacts + parameters: + - $ref: "#/parameters/contactRequest" + responses: + "200": + $ref: "#/responses/ContactResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "500": + $ref: "#/responses/ServerError" + summary: Add new contacts + tags: + - Contacts + put: + description: Update Contact records + operationId: putContacts + parameters: + - $ref: "#/parameters/contactRequest" + responses: + "200": + $ref: "#/responses/ContactResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "500": + $ref: "#/responses/ServerError" + summary: Update Contact + tags: + - Contacts + /products: + get: + description: Return a list of all available Products + operationId: getProducts + parameters: + - $ref: "#/parameters/limitQuery" + - $ref: "#/parameters/offsetQuery" + - $ref: "#/parameters/productIdQuery" + - $ref: "#/parameters/activeQuery" + responses: + "200": + $ref: "#/responses/ProductResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + summary: Get a list of Products + tags: + - Products + /templates: + get: + description: + "Returns the PDF rendering template, or a link to where to get + the template" + operationId: getTemplates + parameters: + - $ref: "#/parameters/limitQuery" + - $ref: "#/parameters/offsetQuery" + - $ref: "#/parameters/templateIdQuery" + responses: + "200": + $ref: "#/responses/TemplateResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + summary: Get PDF Rendering Templates + tags: + - Templates + /users: + get: + description: Return a list of User records from the datastore + operationId: getUsers + parameters: + - $ref: "#/parameters/limitQuery" + - $ref: "#/parameters/offsetQuery" + - $ref: "#/parameters/userIdQuery" + - $ref: "#/parameters/activeQuery" + - $ref: "#/parameters/apiKeyQuery" + responses: + "200": + $ref: "#/responses/UserResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + summary: Get a list Users + tags: + - Users + /notebooks: + get: + description: Return a list of Notebook records from the datastore + operationId: getNotebooks + parameters: + - $ref: "#/parameters/notebookIdQuery" + - $ref: "#/parameters/limitQuery" + - $ref: "#/parameters/offsetQuery" + responses: + "200": + $ref: "#/responses/NotebookResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + summary: Get a list of Notebooks + tags: + - Notebooks + post: + description: Create Notebooks in Taxnexus + operationId: postNotebooks + parameters: + - $ref: "#/parameters/notebookRequest" + responses: + "200": + $ref: "#/responses/NotebookResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + summary: Create new Notebooks + tags: + - Notebooks + put: + description: Update Notebooks in Taxnexus + operationId: putNotebooks + parameters: + - $ref: "#/parameters/notebookRequest" + responses: + "200": + $ref: "#/responses/NotebookResponse" + "401": + $ref: "#/responses/Unauthorized" + "403": + $ref: "#/responses/AccessForbidden" + "404": + $ref: "#/responses/NotFound" + "422": + $ref: "#/responses/UnprocessableEntity" + "500": + $ref: "#/responses/ServerError" + summary: Update Notebooks + tags: + - Notebooks +definitions: + Account: + properties: + accountnumber: + description: Account Number + type: string + accountsource: + description: The marketing orgin of this account + type: string + active: + description: Active + type: boolean + administrativelevel: + description: + For tax authorities, this account's administrative level, e.g. + Local, County, State or Federal + type: string + amount: + description: Rollup Tax Amount + type: number + amountinvoiced: + description: Amount Invoiced + type: number + amountpaid: + description: Amount Paid + type: number + annualrevenue: + description: Annual Revenue Estimate + format: double + type: number + balance: + description: Account Balance + type: number + billingaddress: + $ref: "#/definitions/Address" + billingcontactid: + description: Contact ID + type: string + billingpreference: + description: Billing Preference + type: string + businessaddress: + $ref: "#/definitions/Address" + cannabiscustomer: + description: Is this a cannabis customer? + type: boolean + channelprogramlevelname: + description: Channel Program Level Name + type: string + channelprogramname: + description: Channel Program Name + type: string + clientenddate: + description: Client End Date + type: string + clientstartdate: + description: Client Start Date + type: string + companyid: + description: The Company ID of this Account + type: string + coordinateid: + description: The Id of the geo coordinates of this account + type: string + createdbyid: + description: Created By User ID + type: string + createddate: + description: Created Date + type: string + customerid: + description: Customer ID from source system + type: string + customerpriority: + description: Customer Priority + type: string + dandbcompanyid: + description: D-n-B Company + type: string + dba: + description: This Account's 'Doing Business As' name + type: string + defaultaddress: + $ref: "#/definitions/Address" + defaultbackendid: + description: Default Backend ID + type: string + defaultdeliverycontactid: + description: Default Delivery Address Contact ID + type: string + defaultenduserid: + description: Default End User Contact ID + type: string + description: + description: Description + type: string + dunsnumber: + description: D-U-N-S Number + type: string + ein: + description: EIN + type: string + email: + description: Main Account Email + type: string + enrollmentstatus: + description: Enrollment Status + type: string + fax: + description: Fax + type: string + id: + description: Taxnexus Account Id + type: string + industry: + description: Industry + type: string + iscustomerportal: + description: Customer Portal Account + type: boolean + ispartner: + description: Partner Account + type: boolean + ispcustomer: + description: ISP Customer? + type: boolean + jigsaw: + description: Data.com Key + type: string + lastmodifiedbyid: + description: Last Modified By User ID + type: string + lastmodifieddate: + description: Last Modified Date + type: string + mspcustomer: + description: MSP Customer? + type: boolean + naicscode: + description: NAICS Code + type: string + naicsdesc: + description: NAICS Description + type: string + name: + description: Account Name + type: string + numberofemployees: + description: Employee Count Estimate + format: int64 + type: number + numberoflocations: + description: Number of Locations Estimate + format: int64 + type: number + opencharges: + description: Open Charges + type: number + ordercontactid: + description: Vendor Order Contact ID + type: string + orderemail: + description: Order Email + type: string + ownerid: + description: Account Owner User ID + type: string + ownership: + description: Ownership + type: string + parentfk: + description: Parent Foreign Key + type: string + parentid: + description: Parent Account + type: string + phone: + description: Phone + type: string + placeid: + description: + The ID of the Place situs record that applies to this Account + type: string + preparerid: + description: Tax Preparer Contact ID + type: string + rating: + description: Rating + type: string + ratingengineid: + description: Rating Engine identifier + type: string + ref: + description: External Reference ID + type: string + revenuebase: + description: Rollup Revenue Base + type: number + revenuenet: + description: Rollup Revenue Net + type: number + revenuenottaxable: + description: Rollup Revenue Not Taxable + type: number + shippingaddress: + $ref: "#/definitions/Address" + shippingcensustract: + description: Shipping Census Tract + type: string + shippingcontactid: + description: Shipping Contact ID + type: string + shippingcounty: + description: Shipping County + type: string + sic: + description: SIC Code + type: string + sicdesc: + description: SIC Description + type: string + site: + description: Account Site + type: string + status: + description: Account Status + type: string + taxexemption: + description: Tax Exemption + type: string + taxontax: + description: Rollup Tax On Tax + type: number + telecomcustomer: + description: Telecom Customer? + type: boolean + tenantid: + description: tenant identifier + type: string + tickersymbol: + description: Ticker Symbol + type: string + tradestyle: + description: Tradestyle + type: string + type: + description: Type + type: string + unappliedpayments: + description: Unapplied Payments + type: number + unitbase: + description: Rollup Unit Base + type: number + upsellopportunity: + description: Upsell Opportunity + type: string + website: + description: Website + type: string + whmcsclientid: + description: WHMCS Client ID + format: int64 + type: number + xerocontactid: + description: Xero Contact ID + type: string + yearstarted: + description: Year Started + type: string + type: object + AccountRequest: + properties: + data: + items: + $ref: "#/definitions/Account" + type: array + meta: + $ref: "#/definitions/RequestMeta" + type: object + AccountResponse: + description: An array of Account objects + properties: + data: + items: + $ref: "#/definitions/Account" + type: array + meta: + $ref: "#/definitions/ResponseMeta" + type: object + Address: + properties: + city: + description: City + type: string + country: + description: Country full name + type: string + countrycode: + description: Country Code + type: string + postalcode: + description: Postal Code + type: string + state: + description: State full name + type: string + statecode: + description: State Code + type: string + street: + description: Street number and name + type: string + required: + - city + - statecode + type: object + Authority: + properties: + accountid: + description: Account + type: string + addressline1: + description: Address Line 1 + type: string + addressline2: + description: Address Line 2 + type: string + btn: + description: Billing Telephone Number + type: string + city: + description: City + type: string + contactid: + description: Contact ID + type: string + country: + type: string + createdbyid: + description: Created By User ID + type: string + createddate: + description: Created Date + type: string + date: + type: string + dateapproved: + description: Date Approved + type: string + id: + description: Taxnexus Record Identifier + type: string + lastmodifiedbyid: + description: Last Modified By User ID + type: string + lastmodifieddate: + description: Last Modified Date + type: string + losingcarrier: + description: Losing Carrier + type: string + name: + description: Authority Number + type: string + nameline1: + description: Name Line 1 + type: string + nameline2: + description: Name Line 2 + type: string + opportunityid: + description: Opportunity ID + type: string + orderid: + description: Order ID + type: string + parentfk: + description: + UUID Reference the master record that owns this item + type: string + postalcode: + description: Zip Code + type: string + quoteid: + description: Quote ID + type: string + ref: + description: Source System identifier for this record, if any + type: string + state: + description: State + type: string + status: + description: Status + type: string + tenantid: + description: tenant identifier + type: string + transferdate: + description: Transfer Date + type: string + type: + description: Authority Type + type: string + type: object + AuthorityRequest: + properties: + data: + items: + $ref: "#/definitions/Authority" + type: array + meta: + $ref: "#/definitions/RequestMeta" + type: object + AuthorityResponse: + properties: + data: + items: + $ref: "#/definitions/Authority" + type: array + meta: + $ref: "#/definitions/ResponseMeta" + type: object + Company: + properties: + accountid: + description: Taxnexus ID of the Account that owns this Company + type: string + accountnumberprefix: + description: Account Number Prefix + type: string + advancedperiodid: + description: The next period to be used in periodic billing + type: string + billingaddress: + $ref: "#/definitions/Address" + billingadvice: + description: Billing Advice + type: string + billingcontactid: + description: Contact ID + type: string + billingemail: + description: Billing Email + type: string + billingphone: + description: Billing Phone + type: string + billingwebsite: + description: Billing Website + type: string + closedperiodid: + description: The last closed period + type: string + coatemplateid: + description: Chart of Accounts Template Account ID + type: string + coloraccent1: + description: Color Accent1 + type: string + coloraccent2: + description: Color Accent2 + type: string + colorprimary: + description: Color Primary + type: string + createdbyid: + description: Created By User ID + type: string + createddate: + description: Created Date + type: string + currentperiodid: + description: The current period + type: string + currentperiodstatus: + description: The current period's status value + type: string + customersuccessid: + description: User ID of default Customer Success user + type: string + dateclosed: + description: Date Closed + type: string + defaultaddress: + $ref: "#/definitions/Address" + defaultcompany: + description: Default Company? + type: boolean + fontbody: + description: Font Name for Body Text + type: string + fontheading: + description: Font Name for Heading + type: string + fontheadingnarrow: + description: Font Name for Heading Narrow + type: string + fontlink: + description: Font Names for CSS Link + type: string + fontmono: + description: Font Name for Monospace + type: string + id: + description: Taxnexus Record Id + type: string + international: + description: International Customers? + type: boolean + lastaccountnumber: + description: Last Account Number + format: int64 + type: number + lastmodifiedbyid: + description: Last Modified By User ID + type: string + lastmodifieddate: + description: Last Modified Date + type: string + lasttaxtypenumber: + description: Last TaxType Number + format: int64 + type: number + logo: + description: Logo URL + type: string + name: + description: Company Name + type: string + ownerid: + description: The ID of the contact who owns this Company + type: string + preparerid: + description: User ID of the default tax preparer + type: string + pricebookid: + description: The ID of the default Pricebook for this company + type: string + tenantid: + description: tenant identifier + type: string + usertechleadid: + description: + The ID of the contact who is the User Tech Lead for Company + type: string + type: object + CompanyResponse: + description: An array of Company objects + properties: + data: + items: + $ref: "#/definitions/Company" + type: array + meta: + $ref: "#/definitions/ResponseMeta" + type: object + Contact: + properties: + accountid: + description: The primary account ID of this contact + type: string + assistantname: + description: Assistant Name + type: string + assistantphone: + description: Asst. Phone + type: string + birthdate: + description: Birthdate + type: string + createdbyid: + description: Created By User ID + type: string + createddate: + description: Created Date + type: string + department: + description: Department + type: string + description: + description: Description + type: string + donotcall: + description: Do Not Call? + type: boolean + email: + description: Email address + type: string + emailbounceddate: + description: Email Bounce Date + type: string + emailbouncedreason: + description: Email Bounce Reason + type: string + enrollmentstatus: + description: Taxnexus Enrollment Status + type: string + fax: + description: Fax Number + type: string + firstname: + description: First Name + type: string + hasoptedoutofemail: + description: Email Opt Out + type: boolean + hasoptedoutoffax: + description: Fax Opt Out + type: boolean + homephone: + description: Home Phone + type: string + id: + description: Taxnexus Record Id + type: string + isemailbounced: + description: Does this contact have bounced emails? + type: boolean + isprovisioned: + description: Is Provisioned? + type: boolean + lastmodifiedbyid: + description: Last Modified By User ID + type: string + lastmodifieddate: + description: Last Modified Date + type: string + lastname: + description: Last Name + type: string + leadsource: + description: Lead Source + type: string + level: + description: Level + type: string + linkedin: + description: LinkedIn Page + type: string + mailingaddress: + $ref: "#/definitions/Address" + mailinglists: + description: Mailing Lists + type: string + mobilephone: + description: Mobile Phone + type: string + name: + description: Full Name + type: string + otheraddress: + $ref: "#/definitions/Address" + otherphone: + description: Other Phone + type: string + ownerid: + description: The User ID of the user who owns this Contact + type: string + personalemail: + description: Personal Email Address for this Contact + type: string + phone: + description: Phone Number + type: string + photourl: + description: URL of a photograph of this User + type: string + recruitingstatus: + description: Recruiting Status + type: string + ref: + description: External reference to this contact, if any + type: string + reportstoid: + description: Reports To Contact ID + type: string + salutation: + description: Contact Salutation + type: string + status: + description: The Contact Status + type: string + tenantid: + description: tenant identifier + type: string + title: + description: Contact Title + type: string + type: + description: Contact Type + type: string + type: object + ContactRequest: + properties: + data: + items: + $ref: "#/definitions/Contact" + type: array + meta: + $ref: "#/definitions/RequestMeta" + required: + - meta + - data + type: object + ContactResponse: + properties: + data: + items: + $ref: "#/definitions/Contact" + type: array + meta: + $ref: "#/definitions/ResponseMeta" + type: object + ContractBasic: + properties: + description: + description: Description + type: string + enddate: + description: Contract End Date + type: string + hourlyrate: + description: Hourly Rate + type: number + id: + description: Taxnexus Record Id + type: string + isactive: + description: Is Active? + type: boolean + name: + description: Contract Name + type: string + parentfk: + description: + UUID Reference the master record that owns this item + type: string + paymentterms: + description: Payment Terms + type: string + pricebook2id: + description: Price Book + type: string + ref: + description: Source System identifier for this record, if any + type: string + startdate: + description: Contract Start Date + type: string + status: + description: Status + type: string + tenantid: + description: tenant identifier + type: string + type: + description: Contract Type + type: string + type: object + Error: + properties: + code: + format: int64 + type: integer + fields: + type: string + message: + type: string + type: object + Ids: + description: Taxnexus Record Ids + items: + type: string + type: array + IdsRequest: + properties: + data: + items: + $ref: "#/definitions/Ids" + type: array + meta: + $ref: "#/definitions/RequestMeta" + type: object + InvalidError: + allOf: + - $ref: "#/definitions/Error" + - properties: + details: + items: + type: string + type: array + type: object + Message: + properties: + message: + type: string + ref: + type: string + status: + type: integer + type: object + Notebook: + description: Defines a Taxnexus Notebook + properties: + accountid: + description: Account + type: string + contactid: + description: Contact + type: string + createdbyid: + description: Created By + type: string + createddate: + description: Created Date + type: string + date: + description: Analysis Date + type: string + dateend: + description: End Date + type: string + datestart: + description: Start Date + type: string + description: + description: Description + type: string + id: + description: Record Id + type: string + items: + items: + $ref: "#/definitions/NotebookItem" + type: array + lastmodifiedbyid: + description: Last Modified By + type: string + lastmodifieddate: + description: Last Modifed Date + type: string + periodendid: + description: Ending Period + type: string + periodstartid: + description: Starting Period + type: string + preparerid: + description: Preparer + type: string + tenantid: + description: tenant identifier + type: string + title: + description: Title + type: string + type: object + NotebookItem: + description: An analysis item associated with a Notebook + properties: + id: + description: Record Id + type: string + itemname: + description: Developer name of component + type: string + notebookid: + description: The notebook that owns this Item + type: string + tenantid: + description: tenant identifier + type: string + title: + description: Display title + type: string + type: object + NotebookRequest: + description: An array of Notebook objects + properties: + data: + items: + $ref: "#/definitions/Notebook" + type: array + meta: + $ref: "#/definitions/RequestMeta" + type: object + NotebookResponse: + description: An array of Notebook objects + properties: + data: + items: + $ref: "#/definitions/Notebook" + type: array + meta: + $ref: "#/definitions/ResponseMeta" + type: object + Pagination: + properties: + NextLink: + type: string + PLimit: + format: int64 + type: integer + POffset: + format: int64 + type: integer + PageSize: + format: int64 + type: integer + SetSize: + format: int64 + type: integer + type: object + Product: + properties: + AccountID: + description: The ID of the Account that owns this product + type: string + AgencyType: + description: Agency Type + type: string + AssetTracking: + description: Asset Tracking? + type: boolean + CreatedByID: + description: ID of who created this record instance + type: string + CreatedDate: + description: Date of record creation + type: string + Description: + description: Product Description + type: string + DescriptionSKU: + description: DescriptionSKU + type: string + DisplayURL: + description: Display URL + type: string + Family: + description: Product Family + type: string + ID: + description: Taxnexus Record Id + type: string + Image500: + description: Image (500) + type: string + ImageFull: + description: Image (Full) + type: string + InventoryTracking: + description: Inventory Tracking? + type: boolean + IsActive: + description: Active + type: boolean + IsGeneric: + description: isGeneric + type: boolean + LastModfiedDate: + description: Last Modified Date + type: string + LastModifiedByID: + description: Last modified by ID + type: string + MRCInterval: + description: MRC Interval + format: int64 + type: number + MSRP: + description: MSRP + format: double + type: number + Manufacturer: + description: Manufacturer + type: string + ManufacturerProductCode: + description: Manufacturer Product Code + type: string + Name: + description: Product Name + type: string + ProductCode: + description: Product Code + type: string + Prorateable: + description: Prorateable? + type: boolean + Publish: + description: Publish? + type: boolean + PublishUPC: + description: Publish UPC + type: string + QuantityUnitOfMeasure: + description: Quantity Unit Of Measure + type: string + Refundable: + description: Refundable? + type: boolean + SKU: + description: SKU + type: string + ShippingWeight: + description: Shipping Weight + format: double + type: number + Specifications: + description: Specifications + type: string + TaxnexusCode: + description: Taxnexus Code Name + type: string + TaxnexusCodeID: + description: Taxnexus Code + type: string + TenantID: + description: tenant identifier + type: string + Units: + description: Units + type: string + VendorID: + description: Vendor + type: string + VendorName: + description: Vendor Name + type: string + VendorPartNumber: + description: Vendor Part Number + type: string + VendorPrice: + description: Vendor Price + format: double + type: number + type: object + ProductRequest: + properties: + data: + items: + $ref: "#/definitions/Product" + type: array + meta: + $ref: "#/definitions/RequestMeta" + type: object + ProductResponse: + properties: + data: + items: + $ref: "#/definitions/Product" + type: array + meta: + $ref: "#/definitions/ResponseMeta" + type: object + RequestMeta: + properties: + TaxnexusAccount: + description: Taxnexus Account Number of the Reseller or OEM + type: string + required: + - TaxnexusAccount + type: object + ResponseMeta: + properties: + Contact: + description: Contact Info + type: string + Copyright: + description: Copyright Info + type: string + Info: + description: API Information + type: string + License: + description: License Info + type: string + OperationID: + type: string + Pagination: + $ref: "#/definitions/Pagination" + RequestIP: + type: string + RequestType: + type: string + RequestURL: + type: string + ServerInfo: + type: string + ServerResponseTime: + type: string + ServerTimeStamp: + type: string + TaxnexusAccount: + type: string + UserID: + type: string + type: object + Role: + description: A functional role within a Tenant + properties: + auth0roleid: + description: the corresponding auth0 role + type: string + createdbyid: + description: created by + type: string + createddate: + description: created date + type: string + description: + description: role description + type: string + id: + description: record id + type: string + lastmodifiedbyid: + description: last modified by + type: string + lastmodifieddate: + description: last modifed date + type: string + rolename: + description: the name of this role + type: string + tenantid: + description: the id of the tenant that owns this role + type: string + type: object + RoleRequest: + description: An array of Role objects + properties: + data: + items: + $ref: "#/definitions/Role" + type: array + meta: + $ref: "#/definitions/RequestMeta" + type: object + RoleResponse: + description: An array of Role objects + properties: + data: + items: + $ref: "#/definitions/Role" + type: array + meta: + $ref: "#/definitions/ResponseMeta" + type: object + Template: + properties: + CompanyID: + description: Company + type: string + CreatedByID: + type: string + CreatedDate: + type: string + Description: + description: Description + type: string + HTML: + description: HTML Body + format: byte + type: string + ID: + description: Taxnexus Record Id + type: string + IsActive: + description: Active? + type: boolean + IsMaster: + description: Master Template? + type: boolean + LastModifiedByID: + type: string + LastModifiedDate: + type: string + Name: + description: Template Name + type: string + ObjectType: + description: Object + type: string + RecordTypeName: + description: Record Type Name + type: string + Type: + description: Type + type: string + URL: + description: URL + type: string + tenantid: + description: tenant identifier + type: string + type: object + TemplateResponse: + properties: + data: + items: + $ref: "#/definitions/Template" + type: array + meta: + $ref: "#/definitions/ResponseMeta" + type: object + Tenant: + description: Taxnexus Account Tenant + properties: + accountid: + description: The Account that owns this Tenant + type: string + active: + description: Is this Tenant currently active? + type: boolean + createdbyid: + description: Created By + type: string + createddate: + description: Created Date + type: string + id: + description: Record Id + type: string + lastmodifiedbyid: + description: Last Modified By + type: string + lastmodifieddate: + description: Last Modifed Date + type: string + roles: + items: + $ref: "#/definitions/Role" + type: array + status: + description: The current status of this Tenant + type: string + tenantname: + description: Name of the Tenant Resource + type: string + tenantusers: + items: + $ref: "#/definitions/TenantUser" + type: array + type: + description: Type of tenant + type: string + version: + description: + The version number of the Tenant Onboarding system used to + create this tenant + type: string + type: object + TenantRequest: + description: An array of Tenant objects + properties: + data: + items: + $ref: "#/definitions/Tenant" + type: array + meta: + $ref: "#/definitions/RequestMeta" + type: object + TenantResponse: + description: An array of Tenant objects + properties: + data: + items: + $ref: "#/definitions/Tenant" + type: array + meta: + $ref: "#/definitions/ResponseMeta" + type: object + TenantUser: + description: Relationship object that connects users to a tenant + properties: + accesslevel: + description: The Tenant access level for this User + type: string + tenantid: + description: The Tenant ID + type: string + userid: + description: The User ID + type: string + type: object + User: + properties: + aboutme: + description: About Me + type: string + accountid: + description: Account ID + type: string + address: + $ref: "#/definitions/Address" + alias: + description: Alias + type: string + apikey: + description: API Key + type: string + auth0userid: + description: Auth0 User ID + type: string + communitynickname: + description: Nickname + type: string + companyname: + description: Company Name + type: string + contactid: + description: Contact + type: string + createdbyid: + description: Created User ID + type: string + createddate: + description: Date Created + type: string + delegatedapproverid: + description: Delegated Approver + type: string + department: + description: Department + type: string + division: + description: Division + type: string + email: + description: Email address + type: string + employeenumber: + description: Employee Number + type: string + endday: + description: Time day ends + type: string + environment: + description: Environment + type: string + extension: + description: Extension + type: string + fabricapikey: + description: Fabric API Key + type: string + fax: + description: Fax + type: string + firstname: + description: The first name + type: string + forecastenabled: + description: Allow Forecasting + type: boolean + fullphotourl: + description: Full Photo URL + type: string + id: + description: Taxnexus ID + type: string + isactive: + description: Active + type: boolean + isportalenabled: + description: Is the user enabled for Communities? + type: boolean + isprofilephotoactive: + description: Has Profile Photo + type: boolean + issystemcontrolled: + type: boolean + lastip: + description: ip address of last login + type: string + lastlogin: + description: last login time + type: string + lastmodifiedbyid: + description: Last Modified User ID + type: string + lastmodifieddate: + description: Last Modified Date + type: string + lastname: + description: The Last Name + type: string + logincount: + description: number of times user has logged in + format: int64 + type: number + managerid: + description: Manager + type: string + mobilephone: + description: Mobile + type: string + name: + description: Name + type: string + outofofficemessage: + description: Out of office message + type: string + phone: + description: Phone + type: string + portalrole: + description: Portal Role Level + type: string + profileid: + description: Profile + type: string + receivesadmininfoemails: + description: Admin Info Emails + type: boolean + receivesinfoemails: + description: Info Emails + type: boolean + senderemail: + description: Email Sender Address + type: string + sendername: + description: Email Sender Name + type: string + signature: + description: Email Signature + type: string + smallphotourl: + description: Small Photo URL + type: string + startday: + description: The time day starts + type: string + taxnexusaccount: + description: Taxnexus Account + type: string + tenantid: + type: string + tenantusers: + items: + $ref: "#/definitions/TenantUser" + type: array + timezonesidkey: + description: Time Zone + type: string + title: + description: Title + type: string + username: + description: Username + type: string + userroleid: + description: Role + type: string + userroles: + items: + $ref: "#/definitions/UserRole" + type: array + usertype: + description: User Type + type: string + type: object + UserResponse: + description: An array of Print-Ready ingest Objects + properties: + data: + items: + $ref: "#/definitions/User" + type: array + meta: + $ref: "#/definitions/ResponseMeta" + type: object + UserRole: + description: Relationship object that connects user to a role + properties: + auth0roleid: + description: Linked role ID + type: string + description: + description: Role description + type: string + name: + description: Role Name + type: string + roleid: + description: The Role ID + type: string + userid: + description: The User ID + type: string + type: object diff --git a/swagger/sf-gate-telnexus.yaml b/swagger/sf-gate-telnexus.yaml deleted file mode 100644 index 4f86be2..0000000 --- a/swagger/sf-gate-telnexus.yaml +++ /dev/null @@ -1,9169 +0,0 @@ -swagger: "2.0" -info: - title: "sf-gate" - version: 0.0.2 - description: "Salesforce Gateway Microservice" - termsOfService: "http://telnexus.com/terms/" - contact: - email: "noc@telnexus.com" - license: - name: "Proprietary - Copyright (c) 2018-2020 by Telnexus LLC" -schemes: - - "http" -basePath: "/v1" -host: "sf-gate.infra.tnxs.net:8080" -securityDefinitions: - ApiKeyAuth: - type: apiKey - in: header - name: X-API-Key -security: - - ApiKeyAuth: [] -consumes: - - application/json -produces: - - application/json -parameters: - accountIdQuery: - description: - Telnexus Id of the Account to be used a record retrieval - in: query - name: accountId - required: false - type: string - accountIdQueryRequired: - description: - Telnexus Id of the Account to be used a record retrieval - in: query - name: accountId - required: true - type: string - accountNumberQuery: - description: - The Telnexus Account Number of the Account to be used a record - retrieval - in: query - name: accountNumber - required: false - type: string - accountRequest: - description: A request with an array of Account Objects - in: body - name: accountRequest - required: true - schema: - $ref: "#/definitions/AccountRequest" - accountTypeQuery: - description: The Type of this Object - enum: - - channel_partner_member - - channel_partner_prospect - - new - - other - - system - - tax_administrator_member - - tax_administrator_prospect - - taxpayer_customer - - taxpayer_prospect - in: query - name: type - required: false - type: string - activeQuery: - description: Retrieve only active records? - in: query - name: active - required: false - type: boolean - addressQuery: - description: Postal Address URL encoded; partial addresses allowed - in: query - name: address - required: false - type: string - apiKeyQuery: - description: Telnexus Id of the User to be retrieved - in: query - name: apikey - required: false - type: string - authorityIdQuery: - description: Telnexus Id of the Authority to be retrieved - in: query - name: authorityId - required: false - type: string - authorityRequestBody: - description: A request with an array of Authority Objects - in: body - name: authorityRequest - required: true - schema: - $ref: "#/definitions/AuthorityRequest" - roleIdQuery: - description: Telnexus Id of the Role to be retrieved - in: query - name: roleId - required: false - type: string - backendIdQuery: - description: Telnexus Id of the Backend to be retrieved - in: query - name: backendId - required: false - type: string - backendRequestBody: - description: An array of new Backend records - in: body - name: backendsRequest - required: true - schema: - $ref: "#/definitions/BackendRequest" - cashReceiptIdQuery: - description: Telnexus Record Id of a Cash Receipt - in: query - name: cashReceiptId - required: false - type: string - cashReceiptRequest: - description: The response to a Cash Receipt Request - in: body - name: cashReceiptRequest - required: true - schema: - $ref: "#/definitions/CashReceiptRequest" - clusterIdQuery: - description: Telnexus Record Id of a Cluster - in: query - name: clusterId - required: false - type: string - databaseIdQuery: - description: Telnexus Record Id of a Database - in: query - name: databaseId - required: false - type: string - tenantIdQuery: - description: Telnexus Record Id of a Tenant - in: query - name: tenantId - required: false - type: string - clusterRequest: - description: An array of Cluster records - in: body - name: ClusterRequest - required: true - schema: - $ref: "#/definitions/ClusterRequest" - tenantRequest: - description: An array of Tenant records - in: body - name: CTenantRequest - required: true - schema: - $ref: "#/definitions/TenantRequest" - databaseRequest: - description: An array of Database records - in: body - name: DatabaseRequest - required: true - schema: - $ref: "#/definitions/DatabaseRequest" - companyIdQuery: - description: Telnexus Id of the Company to be retrieved - in: query - name: companyId - required: false - type: string - contactIdQuery: - description: Telnexus Id of the Contact to be retrieved - in: query - name: contactId - required: false - type: string - contactRequest: - description: An array of new Contact records - in: body - name: contactsRequest - required: true - schema: - $ref: "#/definitions/ContactRequest" - countryIdQuery: - description: The Country Telnexus ID - in: query - name: countryId - required: false - type: string - countryQuery: - description: The Country abbreviation (2 char) - in: query - name: country - required: false - type: string - countyIdQuery: - description: The County Telnexus ID - in: query - name: countyId - required: false - type: string - countyQuery: - description: The County Name - in: query - name: county - required: false - type: string - dateFromQuery: - description: The Starting Date for an object retrieval - in: query - name: dateFrom - required: false - type: string - dateToQuery: - description: The Ending Date for an object retrieval - in: query - name: dateTo - required: false - type: string - documentIdQuery: - description: Telnexus Id of the Document to be retrieved - in: query - name: documentId - required: false - type: string - domainIdQuery: - description: Telnexus Id of the Domain to be retrieved - in: query - name: domainId - required: false - type: string - domainQuery: - description: "The Tax Domain to rate (cannabis, sales or telecom)" - in: query - name: name - required: false - type: string - filingIdQuery: - description: Telnexus Id of the Filing to be retrieved - in: query - name: filingId - required: false - type: string - filingRequestBody: - description: A request with an array of Filing Objects - in: body - name: filingRequest - required: true - schema: - $ref: "#/definitions/FilingRequest" - filingTypeIdQuery: - description: Telnexus Record Id of a Filing - in: query - name: filingTypeId - required: false - type: string - filingTypeRequest: - description: A request with an array of FilingType Objects - in: body - name: FilingTypeRequest - required: true - schema: - $ref: "#/definitions/FilingTypeRequest" - glAccountRequest: - description: An array of new Statement records - in: body - name: glAccountRequest - required: true - schema: - $ref: "#/definitions/GlAccountRequest" - glBalanceIdQueryRequired: - description: Telnexus Id of a GL Balance Record - in: query - name: glbalanceId - required: true - type: string - idRequestBody: - description: An array of existing Telnexus Record IDs - in: body - name: idsRequest - required: true - schema: - $ref: "#/definitions/IdsRequest" - ingestIdQuery: - description: Telnexus Record Id of an Ingest - in: query - name: ingestId - required: false - type: string - ingestRequest: - description: An array of new Ingest records - in: body - name: IngestRequest - required: true - schema: - $ref: "#/definitions/IngestRequest" - invoiceIdQuery: - description: Telnexus Id of the Invoice to be retrieved - in: query - name: invoiceId - required: false - type: string - invoiceRequestBody: - description: An array of new Invoice records - in: body - name: invoicesRequest - required: true - schema: - $ref: "#/definitions/InvoiceRequest" - jobIdQuery: - description: Telnexus Record Id of a Job record - in: query - name: jobId - required: false - type: string - jobRequest: - description: An array of new Job records - in: body - name: JobRequest - required: true - schema: - $ref: "#/definitions/JobRequest" - journalEntryRequest: - description: An array of Journal Entry records - in: body - name: journalEntryRequest - required: true - schema: - $ref: "#/definitions/SubmissionRequest" - licenseIdQuery: - description: Telnexus Id of the License to be retrieved - in: query - name: licenseId - required: false - type: string - licenseTypeIdQuery: - description: Telnexus Id of the License Type to be retrieved - in: query - name: licensetypeId - required: false - type: string - limitQuery: - description: "How many objects to return at one time" - format: int64 - in: query - name: limit - required: false - type: integer - masterQuery: - description: Retrieve only master records? - in: query - name: master - required: false - type: boolean - nameQuery: - description: The Name of this Object - in: query - name: name - required: false - type: string - offsetQuery: - description: How many objects to skip? (default 0) - format: int64 - in: query - name: offset - required: false - type: integer - orderIdQuery: - description: Telnexus Id of the Company to be retrieved - in: query - name: orderId - required: false - type: string - periodIdQuery: - description: Telnexus Id of the Period to be used a record retrieval - in: query - name: periodId - required: false - type: string - periodIdQueryRequired: - description: - Telnexus Id of the Period to be used in a record retrieval - in: query - name: periodId - required: true - type: string - periodNameQueryRequired: - description: The Telnexus Accounting Period - in: query - name: period - required: false - type: string - periodRequest: - description: An array of Period records - in: body - name: periodRequest - required: true - schema: - $ref: "#/definitions/PeriodRequest" - placeIdQuery: - description: The City name (must be accompanied by State) - in: query - name: placeId - required: false - type: string - placeQuery: - description: The City name (must be accompanied by State) - in: query - name: place - required: false - type: string - poIdQuery: - description: Telnexus Id of the Purchase Order to be retrieved - in: query - name: poId - required: false - type: string - productIdQuery: - description: - Telnexus Id of the Account to be used a record retrieval - in: query - name: productId - required: false - type: string - productRequestBody: - description: A request with an array of Product Objects - in: body - name: productRequest - required: true - schema: - $ref: "#/definitions/ProductRequest" - productdQuery: - description: Telnexus Id of the Product to be retrieved - in: query - name: productId - required: false - type: string - quoteIdQuery: - description: Telnexus Id of the Company to be retrieved - in: query - name: quoteId - required: false - type: string - serviceIdQuery: - description: Service ID - in: query - name: serviceId - type: string - serviceRequest: - description: An array of Service records - in: body - name: ServiceRequest - required: true - schema: - $ref: "#/definitions/ServiceRequest" - stateIdQuery: - description: The State or Province abbreviation (2 char) - in: query - name: stateId - required: false - type: string - stateQuery: - description: The State or Province abbreviation (2 char) - in: query - name: state - required: false - type: string - statementIdQuery: - description: Telnexus Id of the Company to be retrieved - in: query - name: statementId - required: false - type: string - statementRequestBody: - description: An array of new Statement records - in: body - name: statementsRequest - required: true - schema: - $ref: "#/definitions/StatementRequest" - submissionIdQuery: - description: Telnexus Id of the Submisssion to be retrieved - in: query - name: submissionId - required: false - type: string - submissionRequestBody: - description: An array of new Submission records - in: body - name: submisssionsRequest - required: true - schema: - $ref: "#/definitions/SubmissionRequest" - subscriptionIdQuery: - description: Telnexus Id of the Subscription to be retrieved - in: query - name: subscriptionId - required: false - type: string - subscriptionRequestBody: - description: A request with an array of Subscription Objects - in: body - name: subscriptionRequest - required: true - schema: - $ref: "#/definitions/SubscriptionRequest" - taxInvoiceRequestBody: - description: A list of InvoiceBasic objects - in: body - name: taxInvoicesRequest - required: true - schema: - $ref: "#/definitions/TaxInvoicesRequest" - taxOrderRequestBody: - description: A list of InvoiceBasic objects - in: body - name: taxOrdersRequest - required: true - schema: - $ref: "#/definitions/TaxOrdersRequest" - taxPoRequestBody: - description: A list of PurchaseOrderBasic objects - in: body - name: taxPosRequest - required: true - schema: - $ref: "#/definitions/TaxPurchaseOrdersRequest" - taxQuoteRequestBody: - description: A list of InvoiceBasic objects - in: body - name: taxQuotesRequest - required: true - schema: - $ref: "#/definitions/TaxQuotesRequest" - taxTypeAccountIdQuery: - description: Telnexus Id of the Tax Type Account to be retrieved - in: query - name: taxtypeaccountId - required: false - type: string - taxTypeIdQuery: - description: Telnexus Id of the Tax Type to be retrieved - in: query - name: taxtypeId - required: false - type: string - taxnexuscodeIdQuery: - description: Telnexus Id of the Telnexus Code to be retrieved - in: query - name: taxnexuscodeId - required: false - type: string - templateIdQuery: - description: Telnexus Record Id of a Template - in: query - name: templateId - required: false - type: string - typeQuery: - description: The Type of this Object - in: query - name: type - required: false - type: string - userIdQuery: - description: Telnexus Id of the User to be retrieved - in: query - name: userId - required: false - type: string - notebookIdQuery: - description: Template ID - in: query - name: notebookId - type: string - notebookRequest: - description: An array of Notebook records - in: body - name: NotebookRequest - required: true - schema: - $ref: "#/definitions/NotebookRequest" -responses: - AccessForbidden: - description: "Access forbidden, account lacks access" - schema: - $ref: "#/definitions/Error" - AccountResponse: - description: Telnexus Response with Account objects - schema: - $ref: "#/definitions/AccountResponse" - AccountingRuleResponse: - description: Telnexus Response with Accounting Rule objects - schema: - $ref: "#/definitions/AccountingRuleResponse" - AccountingRulesetResponse: - description: Telnexus Response with Accounting Ruleset objects - schema: - $ref: "#/definitions/AccountingRulesetResponse" - AuthorityResponse: - description: An array of Authority objects - schema: - $ref: "#/definitions/AuthorityResponse" - BackendResponse: - description: Telnexus Response with Backend objects - schema: - $ref: "#/definitions/BackendResponse" - RoleResponse: - description: Telnexus Response with Role objects - schema: - $ref: "#/definitions/RoleResponse" - CashReceiptResponse: - description: Telnexus Response with Cash Receipt objects - schema: - $ref: "#/definitions/CashReceiptResponse" - ClusterResponse: - description: Telnexus Response with Cluster objects - schema: - $ref: "#/definitions/ClusterResponse" - DatabaseResponse: - description: Telnexus Response with Database objects - schema: - $ref: "#/definitions/DatabaseResponse" - TenantResponse: - description: Telnexus Response with Tenant objects - schema: - $ref: "#/definitions/TenantResponse" - CompanyResponse: - description: Telnexus Response with Company objects - schema: - $ref: "#/definitions/CompanyResponse" - Conflict: - description: Conflict - schema: - $ref: "#/definitions/Error" - ContactResponse: - description: An array of Contact objects - schema: - $ref: "#/definitions/ContactResponse" - CountryResponse: - description: Telnexus Response with an array of Country objects - schema: - $ref: "#/definitions/CountryResponse" - CountyResponse: - description: Telnexus Response with an array of County objects - schema: - $ref: "#/definitions/CountyResponse" - DeleteResponse: - description: An array of Message Objects with Delete Status - schema: - properties: - data: - items: - $ref: "#/definitions/Message" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - DomainResponse: - description: Telnexus Response with an array of Domain objects - schema: - $ref: "#/definitions/DomainResponse" - FilingResponse: - description: Telnexus Response with an array of Filing objects - schema: - $ref: "#/definitions/FilingResponse" - FilingTypeResponse: - description: Telnexus Response with an array of FilingType objects - schema: - $ref: "#/definitions/FilingTypeResponse" - GlAccountResponse: - description: An array of GL Account Objects - schema: - $ref: "#/definitions/GlAccountResponse" - GlBalanceResponse: - description: An array of GL Balance Objects - schema: - $ref: "#/definitions/GlBalanceResponse" - IngestResponse: - description: Telnexus Response with Ingest objects - schema: - $ref: "#/definitions/IngestResponse" - InvalidDataError: - description: Invalid data was sent - schema: - $ref: "#/definitions/InvalidError" - InvoiceResponse: - description: - Telnexus Response with an array of Invoice (full) objects - schema: - $ref: "#/definitions/InvoiceResponse" - JobResponse: - description: Telnexus Response with Job objects - schema: - $ref: "#/definitions/JobResponse" - LicenseResponse: - description: An array of License Objects - schema: - $ref: "#/definitions/LicenseResponse" - LicenseTypeResponse: - description: An array of License Type Objects - schema: - $ref: "#/definitions/LicenseTypeResponse" - NotFound: - description: Resource was not found - schema: - $ref: "#/definitions/Error" - OrderResponse: - description: An array of Order objects - schema: - $ref: "#/definitions/OrderResponse" - PeriodResponse: - description: Telnexus Response with Period objects - schema: - $ref: "#/definitions/PeriodResponse" - PlaceResponse: - description: Telnexus Response with an array of Place objects - schema: - $ref: "#/definitions/PlaceResponse" - ProductResponse: - description: An array of Product objects - schema: - $ref: "#/definitions/ProductResponse" - PurchaseOrderResponse: - description: An array of Purchase Order objects - schema: - $ref: "#/definitions/PurchaseOrderResponse" - QuoteResponse: - description: An array of Quote objects - schema: - $ref: "#/definitions/QuoteResponse" - ServerError: - description: Server Internal Error - schema: - $ref: "#/definitions/Error" - ServiceResponse: - description: Telnexus Response with Service objects - schema: - $ref: "#/definitions/ServiceResponse" - StateResponse: - description: Telnexus Response with an array of State objects - schema: - $ref: "#/definitions/StateResponse" - StatementResponse: - description: An array of Statement objects - schema: - $ref: "#/definitions/StatementResponse" - SubmissionResponse: - description: Telnexus Response with Submission objects - schema: - $ref: "#/definitions/SubmissionResponse" - SubscriptionResponse: - description: An array of Subscription Objects - schema: - $ref: "#/definitions/SubscriptionResponse" - TaxTransactionResponse: - description: An array of Tax Transaction Objects - schema: - $ref: "#/definitions/TaxTransactionResponse" - TaxTypeAccountResponse: - description: An array of TaxTypeAccount objects - schema: - $ref: "#/definitions/TaxTypeAccountResponse" - TaxTypeResponse: - description: Telnexus Response with an array of Tax Type objects - schema: - $ref: "#/definitions/TaxTypeResponse" - TelnexusCodeResponse: - description: - Telnexus Response with an array of Telnexus Code objects - schema: - $ref: "#/definitions/TelnexusCodeResponse" - TemplateResponse: - description: Telnexus Response with Template objects - schema: - $ref: "#/definitions/TemplateResponse" - Unauthorized: - description: "Access unauthorized, invalid API-KEY was used" - schema: - $ref: "#/definitions/Error" - UnprocessableEntity: - description: "Unprocessable Entity, likely a bad parameter" - schema: - $ref: "#/definitions/Error" - UserResponse: - description: Telnexus Response with User objects - schema: - $ref: "#/definitions/UserResponse" - NotebookResponse: - description: Telnexus Response with Notebook objects - schema: - $ref: "#/definitions/NotebookResponse" -paths: - /accountingrules: - get: - description: Return a list of Accounting Rules for an Account - operationId: getAccountingRules - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/accountIdQuery" - responses: - "200": - $ref: "#/responses/AccountingRuleResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Accounting Rules - tags: - - AccountingRules - /accountingrulesets: - get: - description: Return a list of Accounting Rulesets for an Account - operationId: getAccountingRulesets - parameters: - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/AccountingRulesetResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Accounting Rulesets - tags: - - AccountingRulesets - /accounts: - get: - description: Return a list of Accounts - operationId: getAccounts - parameters: - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/activeQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/AccountResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of accounts - tags: - - Accounts - post: - description: Account record to be added - operationId: postAccounts - parameters: - - $ref: "#/parameters/accountRequest" - responses: - "200": - $ref: "#/responses/AccountResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Add a new account to Telnexus - tags: - - Accounts - put: - description: Update a single account specified by accountId - operationId: putAccount - parameters: - - $ref: "#/parameters/accountRequest" - responses: - "200": - $ref: "#/responses/AccountResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Update a single account - tags: - - Accounts - /authorities: - get: - description: Return a list of available Authorities - operationId: getAuthorities - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/authorityIdQuery" - - $ref: "#/parameters/activeQuery" - responses: - "200": - $ref: "#/responses/AuthorityResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Authorities - tags: - - Authorities - /backends: - get: - description: Return a list of Backends - operationId: getBackends - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/backendIdQuery" - responses: - "200": - $ref: "#/responses/BackendResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Backends - tags: - - Backends - /roles: - get: - description: Return a list of Roles - operationId: getRoles - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/roleIdQuery" - responses: - "200": - $ref: "#/responses/RoleResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Roles - tags: - - Roles - /cashreceipts: - get: - description: Return a list of available Telnexus Cash Receipts - operationId: getCashReceipts - parameters: - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/activeQuery" - - $ref: "#/parameters/cashReceiptIdQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/CashReceiptResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Cash Receipts - tags: - - CashReceipts - post: - description: Create New Cash Receipts - operationId: postCashReceipts - parameters: - - in: body - name: cashReceiptRequest - schema: - $ref: "#/definitions/CashReceiptRequest" - responses: - "200": - $ref: "#/responses/CashReceiptResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Create new Cash Receipts - tags: - - CashReceipts - put: - description: Put a list of Cash Receipts - operationId: putCashRecipts - parameters: - - in: body - name: cashReceiptRequest - schema: - $ref: "#/definitions/CashReceiptRequest" - responses: - "200": - $ref: "#/responses/CashReceiptResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Put a list of Cash Receipts - tags: - - CashReceipts - /clusters: - get: - description: Return a list of Cluster records from the datastore - operationId: getClusters - parameters: - - $ref: "#/parameters/clusterIdQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/ClusterResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list Clusters - tags: - - Clusters - post: - description: Create Clusters in Telnexus - operationId: postClusters - parameters: - - $ref: "#/parameters/clusterRequest" - responses: - "200": - $ref: "#/responses/ClusterResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Create new Clusters - tags: - - Clusters - put: - description: Update Cluster in Telnexus - operationId: putClusters - parameters: - - $ref: "#/parameters/clusterRequest" - responses: - "200": - $ref: "#/responses/ClusterResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Update Clustera - tags: - - Clusters - /tenants: - get: - description: Return a list of Tenant records from the datastore - operationId: getTenants - parameters: - - $ref: "#/parameters/tenantIdQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/TenantResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list Tenants - tags: - - Tenants - post: - description: Create Tenants in Telnexus - operationId: Tenants - parameters: - - $ref: "#/parameters/tenantRequest" - responses: - "200": - $ref: "#/responses/TenantResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Create new Tenants - tags: - - Tenants - put: - description: Update Tenant in Telnexus - operationId: putTenants - parameters: - - $ref: "#/parameters/tenantRequest" - responses: - "200": - $ref: "#/responses/TenantResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Update Tenants - tags: - - Tenants - /databases: - get: - description: Return a list of Database records from the datastore - operationId: getDatabases - parameters: - - $ref: "#/parameters/databaseIdQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/DatabaseResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list Databases - tags: - - Databases - post: - description: Create Databases in Telnexus - operationId: postDatabases - parameters: - - $ref: "#/parameters/databaseRequest" - responses: - "200": - $ref: "#/responses/DatabaseResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Create new Databases - tags: - - Databases - put: - description: Update Database in Telnexus - operationId: putDatabases - parameters: - - $ref: "#/parameters/databaseRequest" - responses: - "200": - $ref: "#/responses/DatabaseResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Update Databases - tags: - - Databases - /companies: - get: - description: Retrieve a Company record from the datastore - operationId: getCompanies - parameters: - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/CompanyResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a Company record - tags: - - Companies - /contacts: - delete: - description: Delete Telnexus Contact record - operationId: deleteContact - parameters: - - $ref: "#/parameters/contactIdQuery" - responses: - "200": - $ref: "#/responses/DeleteResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Delete a Contact - tags: - - Contacts - get: - description: Return a list of all available Contacts - operationId: getContacts - parameters: - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/activeQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/contactIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/ContactResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of contacts - tags: - - Contacts - post: - description: Contact record to be added - operationId: postContacts - parameters: - - $ref: "#/parameters/contactRequest" - responses: - "200": - $ref: "#/responses/ContactResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Add new contacts - tags: - - Contacts - put: - description: Update Contact records - operationId: putContacts - parameters: - - $ref: "#/parameters/contactRequest" - responses: - "200": - $ref: "#/responses/ContactResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Update Contact - tags: - - Contacts - /counties: - get: - description: "Retrieve Counties, filter with parameters" - operationId: getCounties - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/stateQuery" - - $ref: "#/parameters/countyIdQuery" - responses: - "200": - $ref: "#/responses/CountyResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Retrieve Counties - tags: - - Counties - /countries: - get: - description: "Retrieve Countries, filter with parameters" - operationId: getCountries - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/countryIdQuery" - responses: - "200": - $ref: "#/responses/CountryResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Retrieve Countries - tags: - - Countries - /domains: - get: - description: - "Return all of the Commerce Domains in the Telnexus system. - Domains categorize general categories of commerce, such as - Merchandise, Wholesale Goods, Wholesale Trade, Services, etc." - operationId: getDomains - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/domainQuery" - - $ref: "#/parameters/domainIdQuery" - - $ref: "#/parameters/activeQuery" - responses: - "200": - $ref: "#/responses/DomainResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get Domain records - tags: - - Domains - /filings: - get: - description: Return a list of available Regulatory Filings - operationId: getFilings - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/domainQuery" - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/filingIdQuery" - - $ref: "#/parameters/activeQuery" - responses: - "200": - $ref: "#/responses/FilingResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Filings - tags: - - Filings - post: - description: Create new Filings - operationId: postFilings - parameters: - - $ref: "#/parameters/filingRequestBody" - responses: - "200": - $ref: "#/responses/FilingResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Create new Filings - tags: - - Filings - put: - description: - Update all the fields in a Filing record identified by Telnexus - ID - operationId: putFilings - parameters: - - $ref: "#/parameters/filingRequestBody" - responses: - "200": - $ref: "#/responses/FilingResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Update a Filing - tags: - - Filings - /filingtypes: - get: - description: Return a list of available Regulatory FilingTypes - operationId: getFilingTypes - parameters: - - $ref: "#/parameters/filingTypeIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/FilingTypeResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of FilingTypes - tags: - - FilingTypes - post: - description: Create new FilingTypes - operationId: postFilingTypes - parameters: - - $ref: "#/parameters/filingTypeRequest" - responses: - "200": - $ref: "#/responses/FilingTypeResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Create new FilingTypes - tags: - - FilingTypes - put: - description: - Update all the fields in a FilingType record identified by - Telnexus ID - operationId: putFilingTypes - parameters: - - $ref: "#/parameters/filingTypeRequest" - responses: - "200": - $ref: "#/responses/FilingTypeResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Update a FilingType - tags: - - FilingTypes - /glaccounts: - get: - description: Return a list of available General Ledger Accounts - operationId: getGlAccounts - parameters: - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/GlAccountResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of General Ledger Accounts - tags: - - GlAccounts - /glbalances: - get: - description: - Return a list of General Ledger Account Balances for a Telnexus - Account - operationId: getGlBalances - parameters: - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/GlBalanceResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of General Ledger Account Balances - tags: - - GlBalances - /ingests: - get: - description: Return a list of Print-Ready Ingest records - operationId: getIngests - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/accountNumberQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/ingestIdQuery" - - $ref: "#/parameters/activeQuery" - responses: - "200": - $ref: "#/responses/IngestResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list Ingests - tags: - - Ingests - post: - description: Update Ingests - operationId: postIngests - parameters: - - $ref: "#/parameters/ingestRequest" - responses: - "200": - $ref: "#/responses/IngestResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Update Ingests - tags: - - Ingests - put: - description: Update Ingests - operationId: putIngests - parameters: - - $ref: "#/parameters/ingestRequest" - responses: - "200": - $ref: "#/responses/IngestResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Update Ingests - tags: - - Ingests - /invoices: - get: - description: Return a list of available Telnexus Invoices - operationId: getInvoices - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/invoiceIdQuery" - - $ref: "#/parameters/activeQuery" - responses: - "200": - $ref: "#/responses/InvoiceResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Invoices - tags: - - Invoices - post: - description: Create New Invoices - operationId: postInvoices - parameters: - - in: body - name: invoiceRequest - schema: - $ref: "#/definitions/InvoiceRequest" - responses: - "200": - $ref: "#/responses/InvoiceResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Create a new Invoice - tags: - - Invoices - put: - description: Put a list of Invoices - operationId: putInvoices - parameters: - - in: body - name: invoiceRequest - schema: - $ref: "#/definitions/InvoiceRequest" - responses: - "200": - $ref: "#/responses/InvoiceResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Put a list of Invoices - tags: - - Invoices - /jobs: - get: - description: Return a list of Job records from the datastore - operationId: getJobs - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/accountNumberQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/jobIdQuery" - responses: - "200": - $ref: "#/responses/JobResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list Jobs - tags: - - Jobs - post: - description: Create and enqueue Jobs in Telnexus - operationId: postJobs - parameters: - - $ref: "#/parameters/jobRequest" - responses: - "200": - $ref: "#/responses/JobResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Create new Jobs - tags: - - Jobs - put: - description: Update Jobs in Telnexus - operationId: putJobs - parameters: - - $ref: "#/parameters/jobRequest" - responses: - "200": - $ref: "#/responses/JobResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Update Jobs - tags: - - Jobs - /licenses: - get: - description: "Retrieve all licenses, filter with parameters" - operationId: getLicenses - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/licenseIdQuery" - - $ref: "#/parameters/activeQuery" - responses: - "200": - $ref: "#/responses/LicenseResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Retrieve licenses - tags: - - Licenses - post: - description: Create new Licenses - operationId: postLicenses - parameters: - - description: The new licenses - in: body - name: licenseRequest - schema: - $ref: "#/definitions/LicenseRequest" - responses: - "200": - $ref: "#/responses/LicenseResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Create new Licenses - tags: - - Licenses - put: - description: Add or update licenses - operationId: putLicenses - parameters: - - description: The updated licenses - in: body - name: licenseRequest - schema: - $ref: "#/definitions/LicenseRequest" - responses: - "200": - $ref: "#/responses/LicenseResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Upsert a License - tags: - - Licenses - /licensetypes: - get: - description: Retrieve LicenseType records - operationId: getLicenseTypes - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/licenseTypeIdQuery" - - $ref: "#/parameters/activeQuery" - responses: - "200": - $ref: "#/responses/LicenseTypeResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Retrieve LicenseType records - tags: - - LicenseTypes - /orders: - get: - description: Return a list of Orders - operationId: getOrders - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/accountNumberQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/orderIdQuery" - - $ref: "#/parameters/activeQuery" - responses: - "200": - $ref: "#/responses/OrderResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Orders - tags: - - Orders - post: - description: Create new Orders - operationId: postOrders - parameters: - - in: body - name: order - schema: - $ref: "#/definitions/OrderBasicRequest" - responses: - "200": - $ref: "#/responses/OrderResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Create new Orders - tags: - - Orders - put: - description: Create new Orders - operationId: putOrders - parameters: - - in: body - name: order - schema: - $ref: "#/definitions/Order" - responses: - "200": - $ref: "#/responses/OrderResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Create new Orders - tags: - - Orders - /periods: - get: - description: Return a list of Periods for an Account - operationId: getPeriods - parameters: - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/periodIdQuery" - responses: - "200": - $ref: "#/responses/PeriodResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Periods - tags: - - Periods - /places: - get: - description: "Retrieve Places, filter with parameters" - operationId: getPlaces - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/stateQuery" - - $ref: "#/parameters/placeIdQuery" - responses: - "200": - $ref: "#/responses/PlaceResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Retrieve Places - tags: - - Places - /pos: - get: - description: Return a list of available Purchase Orders - operationId: getPos - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/poIdQuery" - - $ref: "#/parameters/activeQuery" - responses: - "200": - $ref: "#/responses/PurchaseOrderResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Purchase Orders - tags: - - PurchaseOrders - post: - description: Create New Purchase Order - operationId: postPos - parameters: - - in: body - name: purchaseOrderRequest - schema: - $ref: "#/definitions/PurchaseOrderRequest" - responses: - "200": - $ref: "#/responses/PurchaseOrderResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Create a new Purchase Order - tags: - - PurchaseOrders - put: - description: Upsert a list of Purchase Order - operationId: putPos - parameters: - - in: body - name: purchaseOrderRequest - schema: - $ref: "#/definitions/PurchaseOrderRequest" - responses: - "200": - $ref: "#/responses/PurchaseOrderResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Upsert a list of Purchase Order - tags: - - PurchaseOrders - /products: - get: - description: Return a list of all available Products - operationId: getProducts - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/productIdQuery" - - $ref: "#/parameters/activeQuery" - responses: - "200": - $ref: "#/responses/ProductResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Products - tags: - - Products - /quotes: - get: - description: Return a list of available Telnexus Quotes - operationId: getQuotes - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/accountNumberQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/quoteIdQuery" - - $ref: "#/parameters/activeQuery" - responses: - "200": - $ref: "#/responses/QuoteResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Quotes - tags: - - Quotes - post: - description: Create new Quotes - operationId: postQuotes - parameters: - - in: body - name: order - schema: - $ref: "#/definitions/Order" - responses: - "200": - $ref: "#/responses/QuoteResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Create new Quotes - tags: - - Quotes - put: - description: Update QUotes - operationId: putQuotes - parameters: - - in: body - name: order - schema: - $ref: "#/definitions/Order" - responses: - "200": - $ref: "#/responses/QuoteResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Update Quotes - tags: - - Quotes - /services: - get: - description: Return a list of Services records from the datastore - operationId: getServices - parameters: - - $ref: "#/parameters/serviceIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/ServiceResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Services - tags: - - Services - post: - description: Create Services in Telnexus - operationId: postServices - parameters: - - $ref: "#/parameters/serviceRequest" - responses: - "200": - $ref: "#/responses/ServiceResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Create new Services - tags: - - Services - put: - description: Update Services in Telnexus - operationId: putServices - parameters: - - $ref: "#/parameters/serviceRequest" - responses: - "200": - $ref: "#/responses/ServiceResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Update Services - tags: - - Services - /statements: - get: - description: Return a list of all available Statements - operationId: getStatements - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/accountNumberQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/statementIdQuery" - responses: - "200": - $ref: "#/responses/StatementResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of statements - tags: - - Statements - post: - description: - Create a new Statement for a particular Account with a Date - Range - operationId: postStatements - parameters: - - $ref: "#/parameters/statementRequestBody" - responses: - "200": - $ref: "#/responses/StatementResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Create new Statements - tags: - - Statements - /states: - get: - description: "Retrieve States, filter with parameters" - operationId: getStates - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/countryQuery" - - $ref: "#/parameters/stateIdQuery" - responses: - "200": - $ref: "#/responses/StateResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Retrieve States - tags: - - States - /submissions: - get: - description: Return a list of available Submissions - operationId: getSubmissions - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/submissionIdQuery" - - $ref: "#/parameters/activeQuery" - responses: - "200": - $ref: "#/responses/SubmissionResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Submissions - tags: - - Submissions - post: - description: Create new Sumissions - operationId: postSubmissions - parameters: - - $ref: "#/parameters/submissionRequestBody" - responses: - "200": - $ref: "#/responses/SubmissionResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Add new Submissions - tags: - - Submissions - put: - description: - Update all the fields in a Submission record identified by - Telnexus Id - operationId: putSubmissions - parameters: - - $ref: "#/parameters/submissionRequestBody" - responses: - "200": - $ref: "#/responses/SubmissionResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Update a Submission - tags: - - Submissions - /subscriptions: - get: - description: Return a list of available Subscriptions - operationId: getSubscriptions - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/companyIdQuery" - - $ref: "#/parameters/subscriptionIdQuery" - - $ref: "#/parameters/activeQuery" - responses: - "200": - $ref: "#/responses/SubscriptionResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Subscriptions - tags: - - Subscriptions - post: - description: Create new Sumissions - operationId: postSubscriptions - parameters: - - $ref: "#/parameters/subscriptionRequestBody" - responses: - "200": - $ref: "#/responses/SubscriptionResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Add new Subscriptions - tags: - - Subscriptions - put: - description: - Update all the fields in a Subscription record identified by - Telnexus Id - operationId: putSubscriptions - parameters: - - $ref: "#/parameters/subscriptionRequestBody" - responses: - "200": - $ref: "#/responses/SubscriptionResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Update a Subscription - tags: - - Subscriptions - /taxnexuscodes: - get: - description: Return a list of TelnexusCodes - operationId: getTelnexusCodes - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/taxnexuscodeIdQuery" - - $ref: "#/parameters/activeQuery" - responses: - "200": - $ref: "#/responses/TelnexusCodeResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of TelnexusCodes - tags: - - TelnexusCodes - /taxtypeaccounts: - get: - description: Return a list of Tax Type Accounts - operationId: getTaxTypeAccounts - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/accountIdQuery" - - $ref: "#/parameters/placeQuery" - - $ref: "#/parameters/stateQuery" - - $ref: "#/parameters/countyQuery" - - $ref: "#/parameters/countryQuery" - - $ref: "#/parameters/activeQuery" - - $ref: "#/parameters/taxTypeAccountIdQuery" - responses: - "200": - $ref: "#/responses/TaxTypeAccountResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Tax Type Accounts - tags: - - TaxTypeAccounts - post: - description: Create a new Tax Type Account - operationId: postTaxTypeAccounts - parameters: - - description: The new Tax Type Account - in: body - name: taxtypeaccount - schema: - $ref: "#/definitions/TaxTypeAccountRequest" - responses: - "200": - $ref: "#/responses/TaxTypeAccountResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Create new Tax Type Accounts - tags: - - TaxTypeAccounts - put: - description: Update a TaxTypeAccount - operationId: putTaxTypeAccounts - parameters: - - in: body - name: taxtypeaccount - schema: - $ref: "#/definitions/TaxTypeAccountRequest" - responses: - "200": - $ref: "#/responses/TaxTypeAccountResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "500": - $ref: "#/responses/ServerError" - summary: Update TaxTypeAccounts - tags: - - TaxTypeAccounts - /taxtypes: - get: - description: - Return a complete list of all the tax types handled by Telnexus; - use the lat long parameters to retrieve a Situs lookup - operationId: getTaxTypes - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/addressQuery" - - $ref: "#/parameters/placeQuery" - - $ref: "#/parameters/stateQuery" - - $ref: "#/parameters/countyQuery" - - $ref: "#/parameters/countryQuery" - - $ref: "#/parameters/activeQuery" - - $ref: "#/parameters/taxTypeIdQuery" - responses: - "200": - $ref: "#/responses/TaxTypeResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Tax Types - tags: - - TaxTypes - /templates: - get: - description: - "Returns the PDF rendering template, or a link to where to get - the template" - operationId: getTemplates - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/templateIdQuery" - responses: - "200": - $ref: "#/responses/TemplateResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get PDF Rendering Templates - tags: - - Templates - /users: - get: - description: Return a list of User records from the datastore - operationId: getUsers - parameters: - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - - $ref: "#/parameters/userIdQuery" - - $ref: "#/parameters/activeQuery" - - $ref: "#/parameters/apiKeyQuery" - responses: - "200": - $ref: "#/responses/UserResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list Users - tags: - - Users - /notebooks: - get: - description: Return a list of Notebook records from the datastore - operationId: getNotebooks - parameters: - - $ref: "#/parameters/notebookIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/NotebookResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Notebooks - tags: - - Notebooks - post: - description: Create Notebooks in Telnexus - operationId: postNotebooks - parameters: - - $ref: "#/parameters/notebookRequest" - responses: - "200": - $ref: "#/responses/NotebookResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Create new Notebooks - tags: - - Notebooks - put: - description: Update Notebooks in Telnexus - operationId: putNotebooks - parameters: - - $ref: "#/parameters/notebookRequest" - responses: - "200": - $ref: "#/responses/NotebookResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Update Notebooks - tags: - - Notebooks -definitions: - AccountingRule: - properties: - tenantid: - description: tenant identifier - type: string - id: - type: string - description: Telnexus Record Id - accountid: - type: string - description: The Account for whom this Account Rule exists - code: - type: string - description: The Code used for Accounting Rule Lookups - cogsaccountid: - type: string - description: - The Cost of Goods Sold account to be used for this Accounting - Rule - cogsaccountname: - type: string - description: COGS Account Name - createdbyid: - type: string - description: Created By - createddate: - type: string - description: Created Date - creditaccountid: - type: string - description: - The GL Account that is the Credit Account to be used in this - Accounting Rule - creditaccountname: - type: string - description: Credit Account Name - debitaccountid: - type: string - description: - The GL Account that is the Debit Account to be used in this - Accounting Rule - debitaccountname: - type: string - description: Debit Account Name - description: - type: string - description: Description - inventoryaccountid: - type: string - description: - The GL Account that is the Inventory Account to be used in - this Accounting Rule - inventoryaccountname: - type: string - description: Inventory Account Name - isdeferred: - type: boolean - description: - Is this a deferred tax, not to be charged on the invoice? - lastmodifiedbyid: - type: string - description: Last Modified By - lastmodifieddate: - type: string - description: Last Modified Date - parentfk: - type: string - description: Parent Foreign Key - proportion: - type: number - description: - The Proportion of Revenue which is governed by this Accounting - Rule; used for proportional taxing of products and services - AccountingRuleRequest: - properties: - data: - items: - $ref: "#/definitions/AccountingRule" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - AccountingRuleResponse: - properties: - data: - items: - $ref: "#/definitions/AccountingRule" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - AccountingRuleset: - type: object - properties: - tenantid: - description: tenant identifier - type: string - id: - type: string - description: Telnexus Record Id - accountid: - type: string - description: Telnexus Account ID - code: - type: string - description: Accounting Ruleset Code - createdbyid: - type: string - description: Created By - createddate: - type: string - description: Created Date - description: - type: string - description: Ruleset Description - lastmodifiedbyid: - type: string - description: Last Modified By - lastmodifieddate: - type: string - description: Last Modified Date - number: - type: string - description: Telnexus Ruleset Number - items: - items: - $ref: "#/definitions/AccountingRulesetItem" - type: array - AccountingRulesetRequest: - properties: - data: - items: - $ref: "#/definitions/AccountingRuleset" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - AccountingRulesetResponse: - properties: - data: - items: - $ref: "#/definitions/AccountingRuleset" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - AccountingRulesetItem: - type: object - properties: - tenantid: - description: tenant identifier - type: string - id: - type: string - description: Telnexus Record Id - accountingrulecode: - type: string - description: The code of the rule in this ruleset - Account: - properties: - tenantid: - description: tenant identifier - type: string - accountnumber: - description: Account Number - type: string - accountsource: - description: The marketing orgin of this account - type: string - active: - description: Active - type: boolean - administrativelevel: - description: - "For tax authorities, this account's administrative level, - e.g. Local, County, State or Federal" - type: string - amount: - description: Rollup Tax Amount - type: number - amountinvoiced: - description: Amount Invoiced - type: number - amountpaid: - description: Amount Paid - type: number - annualrevenue: - description: Annual Revenue Estimate - format: double - type: number - balance: - description: Account Balance - type: number - billingaddress: - $ref: "#/definitions/Address" - billingcontactid: - description: Contact ID - type: string - billingpreference: - description: Billing Preference - type: string - businessaddress: - $ref: "#/definitions/Address" - cannabiscustomer: - type: boolean - description: Is this a cannabis customer? - channelprogramlevelname: - description: Channel Program Level Name - type: string - channelprogramname: - description: Channel Program Name - type: string - clientenddate: - description: Client End Date - type: string - clientstartdate: - description: Client Start Date - type: string - companyid: - description: The Company ID of this Account - type: string - coordinateid: - description: The Id of the geo coordinates of this account - type: string - createdbyid: - description: Created By User ID - type: string - createddate: - description: Created Date - type: string - customerid: - description: Customer ID from source system - type: string - customerpriority: - description: Customer Priority - type: string - dandbcompanyid: - description: D-n-B Company - type: string - dba: - description: This Account's 'Doing Business As' name - type: string - defaultaddress: - $ref: "#/definitions/Address" - defaultbackendid: - description: Default Backend ID - type: string - defaultdeliverycontactid: - description: Default Delivery Address Contact ID - type: string - defaultenduserid: - description: Default End User Contact ID - type: string - description: - description: Description - type: string - dunsnumber: - description: D-U-N-S Number - type: string - ein: - description: EIN - type: string - email: - description: Main Account Email - type: string - enrollmentstatus: - description: Enrollment Status - type: string - fax: - description: Fax - type: string - id: - description: Telnexus Account Id - type: string - industry: - description: Industry - type: string - iscustomerportal: - description: Customer Portal Account - type: boolean - ispartner: - description: Partner Account - type: boolean - ispcustomer: - description: ISP Customer? - type: boolean - jigsaw: - description: Data.com Key - type: string - lastmodifiedbyid: - description: Last Modified By User ID - type: string - lastmodifieddate: - description: Last Modified Date - type: string - mspcustomer: - description: MSP Customer? - type: boolean - naicscode: - description: NAICS Code - type: string - naicsdesc: - description: NAICS Description - type: string - name: - description: Account Name - type: string - numberofemployees: - description: Employee Count Estimate - type: number - format: int64 - numberoflocations: - description: Number of Locations Estimate - type: number - format: int64 - opencharges: - description: Open Charges - type: number - ordercontactid: - description: Vendor Order Contact ID - type: string - orderemail: - description: Order Email - type: string - ownerid: - description: Account Owner User ID - type: string - ownership: - description: Ownership - type: string - parentfk: - description: Parent Foreign Key - type: string - parentid: - description: Parent Account - type: string - phone: - description: Phone - type: string - placeid: - description: - The ID of the Place situs record that applies to this Account - type: string - preparerid: - description: Tax Preparer Contact ID - type: string - rating: - description: Rating - type: string - ratingengineid: - description: Rating Engine identifier - type: string - ref: - description: External Reference ID - type: string - revenuebase: - description: Rollup Revenue Base - type: number - revenuenet: - description: Rollup Revenue Net - type: number - revenuenottaxable: - description: Rollup Revenue Not Taxable - type: number - shippingaddress: - $ref: "#/definitions/Address" - shippingcensustract: - description: Shipping Census Tract - type: string - shippingcounty: - description: Shipping County - type: string - shippingcontactid: - description: Shipping Contact ID - type: string - sic: - description: SIC Code - type: string - sicdesc: - description: SIC Description - type: string - site: - description: Account Site - type: string - status: - description: Account Status - type: string - taxexemption: - description: Tax Exemption - type: string - taxontax: - description: Rollup Tax On Tax - type: number - telecomcustomer: - description: Telecom Customer? - type: boolean - tickersymbol: - description: Ticker Symbol - type: string - tradestyle: - description: Tradestyle - type: string - type: - description: Type - type: string - unappliedpayments: - description: Unapplied Payments - type: number - unitbase: - description: Rollup Unit Base - type: number - upsellopportunity: - description: Upsell Opportunity - type: string - website: - description: Website - type: string - whmcsclientid: - description: WHMCS Client ID - type: number - format: int64 - xerocontactid: - description: Xero Contact ID - type: string - yearstarted: - description: Year Started - type: string - type: object - AccountRequest: - properties: - data: - items: - $ref: "#/definitions/Account" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - AccountResponse: - description: An array of Account objects - properties: - data: - items: - $ref: "#/definitions/Account" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Address: - properties: - city: - description: City - type: string - country: - description: Country full name - type: string - countrycode: - description: Country Code - type: string - postalcode: - description: Postal Code - type: string - state: - description: State full name - type: string - statecode: - description: State Code - type: string - street: - description: Street number and name - type: string - required: - - city - - statecode - type: object - Authority: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - description: Account - type: string - addressline1: - description: Address Line 1 - type: string - addressline2: - description: Address Line 2 - type: string - btn: - description: Billing Telephone Number - type: string - city: - description: City - type: string - contactid: - description: Contact ID - type: string - country: - type: string - createdbyid: - description: Created By User ID - type: string - createddate: - description: Created Date - type: string - date: - type: string - dateapproved: - description: Date Approved - type: string - id: - description: Telnexus Record Identifier - type: string - lastmodifiedbyid: - description: Last Modified By User ID - type: string - lastmodifieddate: - description: Last Modified Date - type: string - losingcarrier: - description: Losing Carrier - type: string - name: - description: Authority Number - type: string - nameline1: - description: Name Line 1 - type: string - nameline2: - description: Name Line 2 - type: string - opportunityid: - description: Opportunity ID - type: string - orderid: - description: Order ID - type: string - parentfk: - description: - UUID Reference the master record that owns this item - type: string - postalcode: - description: Zip Code - type: string - quoteid: - description: Quote ID - type: string - ref: - description: "Source System identifier for this record, if any" - type: string - state: - description: State - type: string - status: - description: Status - type: string - transferdate: - description: Transfer Date - type: string - type: - description: Authority Type - type: string - type: object - AuthorityRequest: - properties: - data: - items: - $ref: "#/definitions/Authority" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - AuthorityResponse: - properties: - data: - items: - $ref: "#/definitions/Authority" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Backend: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - description: The Account that owns this Backend - type: string - active: - description: Active - type: boolean - apikey: - description: apikey - type: string - applicationname: - description: Used to identify the State were required - type: string - authtype: - description: Authentication Type - type: string - backendname: - description: Backend Name - type: string - baseurl: - description: base_url - type: string - callbackurl: - description: callback_url - type: string - clientid: - description: client_id - type: string - clientsecret: - description: client_secret - type: string - companyid: - description: Company - type: string - createdbyid: - type: string - description: Created By - createddate: - type: string - description: Created Date - description: - description: Description - type: string - id: - description: Telnexus Record Id Only; not used in POST - type: string - lastmodifiedbyid: - type: string - description: Last Modified By - lastmodifieddate: - type: string - description: Last Modified Date - loginurl: - description: login_url - type: string - managementpassword: - description: Management Password - type: string - managementurl: - description: Management URL - type: string - managementusername: - description: Management Username - type: string - metrclicense: - description: MetrcLicense - type: string - metrcstate: - description: MetrcState - type: string - ownerid: - description: Ownerid - type: string - password: - description: password - type: string - production: - description: Production - type: boolean - projectid: - description: project_id - type: string - providercredentials: - description: Provider Credentials - type: string - realm: - description: realm - type: string - ref: - description: "Source System identifier for this record, if any" - type: string - resellerbackendid: - description: Resellerbackendid - type: string - securitytoken: - description: security_token - type: string - timeout: - description: Timeout - format: int64 - type: number - tokenuri: - description: token_uri - type: string - type: - description: Type - type: string - username: - description: username - type: string - vendor: - description: Backend Vendor Name - type: string - type: object - BackendRequest: - properties: - data: - items: - $ref: "#/definitions/Backend" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - BackendResponse: - properties: - data: - items: - $ref: "#/definitions/Backend" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - CashReceipt: - description: - Cash Receipt tracks all cash transactions in and out of the - enterprise - properties: - tenantid: - description: tenant identifier - type: string - accountbalance: - description: Account Balance - type: number - accountid: - description: Account - type: string - accountname: - description: Account Name - type: string - amount: - description: Amount - type: number - appliedamount: - description: Applied Amount - type: number - attempt_number: - description: Attempt Number - type: number - auditmessage: - description: Audit Trail Message - type: string - autopay: - description: Autopay? - type: boolean - billingcontactid: - description: Billing Contact - type: string - billingrunid: - description: Billing Run - type: string - createdbyid: - description: Created By - type: string - customerid: - description: Customer Id - type: string - date: - description: Journal Date - type: string - description: - description: Memo - type: string - gateway: - description: Gateway - type: string - gatewaykey: - description: Gateway Key - type: string - gatewaymessage: - description: Gateway Message - type: string - gatewaytxn: - description: GatewayTxn? - type: boolean - id: - description: Telnexus Record ID - type: string - invoiceid: - description: Invoice - type: string - isvalid: - description: Is Valid? - type: boolean - lastmodifiedbyid: - description: Last Modified By - type: string - name: - description: Payment Number - type: string - parentfk: - description: Parent Foreign Key - type: string - partneraccountid: - description: Partner Account - type: string - payment_method: - description: Payment Method - type: string - pending: - description: Pending? - type: boolean - periodid: - description: Period - type: string - picklistvalue: - description: Picklist Value - type: string - posted: - description: Posted - type: boolean - processed: - description: Processed - type: boolean - processing: - description: Processing - type: boolean - recordtypeid: - description: Record Type - type: string - ref: - description: External Reference - type: string - reference: - description: Reference - type: string - referencenumber: - description: Reference Number - type: number - rejected: - description: Rejected? - type: boolean - sourceid: - description: Source Payment Method - type: string - statementitemtype: - description: Statement Item Type - type: string - status: - description: Status - type: string - templateid: - description: Template - type: string - type: - description: Type - type: string - unappliedamount: - description: Unapplied Amount - type: number - validpayment: - description: Valid Payment? - type: boolean - xeroid: - description: Xero Credit Note Id - type: string - type: object - CashReceiptRequest: - properties: - data: - items: - $ref: "#/definitions/CashReceipt" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - CashReceiptResponse: - properties: - data: - items: - $ref: "#/definitions/CashReceipt" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Cluster: - type: object - properties: - id: - type: string - description: Telnexus Record Id - name: - type: string - description: Cluster Name - createdbyid: - type: string - description: Created By - createddate: - type: string - description: Created Date - description: - type: string - description: Description - environment: - type: string - description: Environment - ref: - type: string - description: External Reference - gateway: - type: string - description: Gateway - ip_address: - type: string - description: IP Address - lastmodifiedbyid: - type: string - description: Last Modified By - lastmodifieddate: - type: string - description: Last Modified Date - ownerid: - type: string - description: Owner - status: - type: string - description: Status - subnet: - type: string - description: Subnet - tenantid: - type: string - description: tenantid - type: - type: string - description: Type - zone: - type: string - description: Zone - ClusterRequest: - properties: - data: - items: - $ref: "#/definitions/Cluster" - type: array - meta: - $ref: "#/definitions/RequestMeta" - required: - - meta - - data - type: object - ClusterResponse: - description: An array of cluster objects - properties: - data: - items: - $ref: "#/definitions/Cluster" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Company: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - description: Telnexus ID of the Account that owns this Company - type: string - accountnumberprefix: - description: Account Number Prefix - type: string - advancedperiodid: - description: The next period to be used in periodic billing - type: string - billingaddress: - $ref: "#/definitions/Address" - billingadvice: - description: Billing Advice - type: string - billingcontactid: - description: Contact ID - type: string - billingemail: - description: Billing Email - type: string - billingphone: - description: Billing Phone - type: string - billingwebsite: - description: Billing Website - type: string - closedperiodid: - description: The last closed period - type: string - coatemplateid: - description: Chart of Accounts Template Account ID - type: string - coloraccent1: - description: Color Accent1 - type: string - coloraccent2: - description: Color Accent2 - type: string - colorprimary: - description: Color Primary - type: string - createdbyid: - description: Created By User ID - type: string - createddate: - description: Created Date - type: string - currentperiodid: - description: The current period - type: string - currentperiodstatus: - description: The current period's status value - type: string - customersuccessid: - description: User ID of default Customer Success user - type: string - dateclosed: - description: Date Closed - type: string - defaultaddress: - $ref: "#/definitions/Address" - defaultcompany: - description: Default Company? - type: boolean - fontbody: - description: Font Name for Body Text - type: string - fontheading: - description: Font Name for Heading - type: string - fontheadingnarrow: - description: Font Name for Heading Narrow - type: string - fontlink: - description: Font Names for CSS Link - type: string - fontmono: - description: Font Name for Monospace - type: string - id: - description: Telnexus Record Id - type: string - international: - description: International Customers? - type: boolean - lastaccountnumber: - description: Last Account Number - format: int64 - type: number - lastmodifiedbyid: - description: Last Modified By User ID - type: string - lastmodifieddate: - description: Last Modified Date - type: string - lasttaxtypenumber: - description: Last TaxType Number - format: int64 - type: number - logo: - description: Logo URL - type: string - name: - description: Company Name - type: string - ownerid: - description: The ID of the contact who owns this Company - type: string - preparerid: - description: User ID of the default tax preparer - type: string - pricebookid: - description: The ID of the default Pricebook for this company - type: string - usertechleadid: - description: - The ID of the contact who is the User Tech Lead for Company - type: string - type: object - CompanyResponse: - description: An array of Company objects - properties: - data: - items: - $ref: "#/definitions/Company" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Contact: - properties: - tenantid: - description: tenant identifier - type: string - id: - description: Telnexus Record Id - type: string - accountid: - description: The primary account ID of this contact - type: string - assistantname: - description: Assistant Name - type: string - assistantphone: - description: Asst. Phone - type: string - birthdate: - description: Birthdate - type: string - createdbyid: - description: Created By User ID - type: string - createddate: - description: Created Date - type: string - department: - description: Department - type: string - description: - description: Description - type: string - donotcall: - description: Do Not Call? - type: boolean - email: - description: Email address - type: string - emailbounceddate: - description: Email Bounce Date - type: string - emailbouncedreason: - description: Email Bounce Reason - type: string - enrollmentstatus: - description: Telnexus Enrollment Status - type: string - fax: - description: Fax Number - type: string - firstname: - description: First Name - type: string - hasoptedoutofemail: - description: Email Opt Out - type: boolean - hasoptedoutoffax: - description: Fax Opt Out - type: boolean - homephone: - description: Home Phone - type: string - isemailbounced: - description: Does this contact have bounced emails? - type: boolean - isprovisioned: - description: Is Provisioned? - type: boolean - lastmodifiedbyid: - description: Last Modified By User ID - type: string - lastmodifieddate: - description: Last Modified Date - type: string - lastname: - description: Last Name - type: string - leadsource: - description: Lead Source - type: string - level: - description: Level - type: string - linkedin: - description: LinkedIn Page - type: string - mailingaddress: - $ref: "#/definitions/Address" - mailinglists: - description: Mailing Lists - type: string - mobilephone: - description: Mobile Phone - type: string - name: - description: Full Name - type: string - otheraddress: - $ref: "#/definitions/Address" - otherphone: - description: Other Phone - type: string - ownerid: - description: The User ID of the user who owns this Contact - type: string - personalemail: - description: Personal Email Address for this Contact - type: string - phone: - description: Phone Number - type: string - photourl: - description: URL of a photograph of this User - type: string - recruitingstatus: - description: Recruiting Status - type: string - ref: - description: External reference to this contact, if any - type: string - reportstoid: - description: Reports To Contact ID - type: string - salutation: - description: Contact Salutation - type: string - status: - description: The Contact Status - type: string - title: - description: Contact Title - type: string - type: - description: Contact Type - type: string - type: object - ContactRequest: - properties: - data: - items: - $ref: "#/definitions/Contact" - type: array - meta: - $ref: "#/definitions/RequestMeta" - required: - - meta - - data - type: object - ContactResponse: - properties: - data: - items: - $ref: "#/definitions/Contact" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - ContractBasic: - properties: - tenantid: - description: tenant identifier - type: string - description: - description: Description - type: string - enddate: - description: Contract End Date - type: string - hourlyrate: - description: Hourly Rate - type: number - id: - description: Telnexus Record Id - type: string - isactive: - description: Is Active? - type: boolean - name: - description: Contract Name - type: string - parentfk: - description: - UUID Reference the master record that owns this item - type: string - paymentterms: - description: Payment Terms - type: string - pricebook2id: - description: Price Book - type: string - ref: - description: "Source System identifier for this record, if any" - type: string - startdate: - description: Contract Start Date - type: string - status: - description: Status - type: string - type: - description: Contract Type - type: string - type: object - Country: - properties: - accountid: - description: Account - type: string - amount: - description: Rollup Amount - type: number - format: double - code: - description: Code - type: string - latitude: - type: number - format: double - longitude: - type: number - format: double - contactid: - description: Contact - type: string - enrollmentstatus: - description: Enrollment Status - type: string - id: - description: Telnexus Record Id - type: string - interest: - description: Interest - type: number - format: double - name: - description: Country Name - type: string - penalty: - description: Penalty - type: number - format: double - ref: - description: "Source System identifier for this record, if any" - type: string - reportedadjustments: - description: Reported Adjustments - type: number - format: double - reporteddeductions: - description: Reported Deductions - type: number - format: double - reportednetrevenue: - description: Reported Net Revenue - type: number - format: double - reportedrate: - description: Reported Rate - type: number - format: double - reportedrevenue: - description: Reported Revenue - type: number - format: double - revenuebase: - description: Rollup Revenue Base - type: number - format: double - revenuenet: - description: Rollup Revenue Net - type: number - format: double - revenuenottaxable: - description: Rollup Revenue Not Taxable - type: number - format: double - status: - description: Document Status - type: string - format: double - subtotal: - description: Reported Tax - type: number - format: double - taxinstances: - items: - $ref: "#/definitions/TaxInstance" - type: array - templateid: - description: Template - type: string - totalamount: - description: Total Amount - type: number - format: double - unitbase: - description: Unit Base - type: number - type: object - CountryResponse: - description: An array of Country objects - properties: - data: - items: - $ref: "#/definitions/Country" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - County: - properties: - accountid: - description: Account - type: string - latitude: - type: number - format: double - longitude: - type: number - format: double - amount: - description: Rollup Amount - type: number - format: double - areadescription: - description: AreaDescription - type: string - contactid: - description: Contact - type: string - countryid: - description: Country Telnexus ID - type: string - enrollmentstatus: - description: Enrollment Status - type: string - fips: - description: FIPS - type: string - fipsclass: - description: FIPS Class - type: string - functionalstatus: - description: Functional Status - type: string - geocode: - description: Geocode - type: string - gnis: - description: GNIS Code - format: int64 - type: number - hasdistricttaxes: - description: True if this Place has District Sales taxes - type: boolean - id: - description: Telnexus Record Id - type: string - interest: - description: Interest - format: double - type: number - landarea: - description: Land Area - type: number - format: int64 - legalname: - description: Legal Name - type: string - name: - description: County Name - type: string - penalty: - description: Penalty - format: double - type: number - ref: - description: "Source System identifier for this record, if any" - type: string - reportedadjustments: - description: Reported Adjustments - type: number - format: double - reporteddeductions: - description: Reported Deductions - type: number - format: double - reportednetrevenue: - description: Reported Net Revenue - type: number - format: double - reportedrate: - description: Reported Rate - type: number - format: double - reportedrevenue: - description: Reported Revenue - type: number - format: double - revenuebase: - description: Rollup Revenue Base - type: number - format: double - revenuenet: - description: Rollup Revenue Net - type: number - format: double - revenuenottaxable: - description: Rollup Revenue Not Taxable - type: number - format: double - stateid: - description: State - type: string - status: - description: Document Status - type: string - subtotal: - description: Reported Tax - format: double - type: number - taxinstances: - items: - $ref: "#/definitions/TaxInstance" - type: array - templateid: - description: Print Template ID - type: string - totalamount: - description: Total Amount - format: double - type: number - totalarea: - description: Total Area - format: int64 - type: number - unitbase: - description: Unit Base - type: number - format: double - waterarea: - description: Water Area - format: int64 - type: number - type: object - CountyResponse: - description: An array of County objects - properties: - data: - items: - $ref: "#/definitions/County" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - CreditCard: - properties: - tenantid: - description: tenant identifier - type: string - active: - description: Active - type: boolean - billingcity: - description: Billing City - type: string - billingstate: - description: Billing State - type: string - billingstreet: - description: Billing Street - type: string - billingzip: - description: Billing Zip - type: string - cc_cid: - description: CC CID - type: string - cc_number: - description: CC Number - type: string - cc_print: - description: CC_Print - type: string - cc_type: - description: CC Type - type: string - companyid: - description: Company - type: string - expmonth: - description: Exp Month - type: string - expyear: - description: Exp Year - type: string - id: - description: Record Id - type: string - name: - description: CC Name - type: string - type: object - Domain: - properties: - active: - description: Active - type: boolean - description: - description: Description - type: string - id: - description: Telnexus Record Id Only; not used in POST - type: string - name: - description: Name - type: string - type: object - DomainResponse: - description: An array of Domain objects - properties: - data: - items: - $ref: "#/definitions/Domain" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Error: - properties: - code: - format: int64 - type: integer - fields: - type: string - message: - type: string - type: object - Filing: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - type: string - authorityid: - type: string - accountname: - description: Account Name on Filing - type: string - amount: - description: The amount of tax to be paid with this filing - format: double - type: number - contactid: - description: Billing Contact - type: string - createdbyid: - description: Created By User ID - type: string - createddate: - description: Created Date - type: string - date: - description: Filing Date - type: string - duedate: - description: Due Date - format: string - filingnumber: - description: Due Date - format: string - filingtypeid: - description: The ID of the Filing Type for this Filing - format: string - frequency: - description: Due Date - format: string - id: - description: Record Id - type: string - interest: - description: Interest - format: double - type: number - interestrate: - description: Interest - format: double - type: number - lastmodifiedbyid: - description: Last Modified By User ID - type: string - lastmodifieddate: - description: Last Modified Date - type: string - monthnumber: - description: The number of the Month of the filing - format: int64 - type: number - ownerid: - description: Taxneuxs ID of the User who owns this record - type: string - penalty: - description: Penalty - format: double - type: number - penaltydays: - description: Penalty Days - format: double - type: number - penaltyrate: - description: Penalty Days - format: double - type: number - periodid: - description: Period - type: string - preparerid: - description: Telnexus ID of the Contact who prepared this filing - type: string - quarternumber: - description: The number of the Month of the filing - format: int64 - type: number - ref: - description: "Source System identifier for this record, if any" - type: string - reportedadjustments: - description: Reported Adjustments - format: double - type: number - reporteddeductions: - description: Reported Deductions - format: double - type: number - reportednetrevenue: - description: Reported Net Revenue - format: double - type: number - reportedrate: - description: Reported Rate - format: double - type: number - reportedrevenue: - description: Reported Revenue - format: double - type: number - revenuebase: - description: Revenue Base - format: double - type: number - revenuenet: - description: Revenue Net - format: double - type: number - revenuenottaxable: - description: Revenue Not Taxable - format: double - type: number - semiannualnumber: - description: The number of the Month of the filing - format: int64 - type: number - status: - description: Status - type: string - submissionid: - description: Telnexus ID of the Submission that owns this Filing - type: string - subtotal: - description: Reported Tax - format: double - type: number - taxontax: - description: Tax On Tax - format: double - type: number - taxtypeaccountid: - description: - The TaxType Account for which this Filing is paying remittance - type: string - totalamount: - description: Total Amount - format: double - type: number - unitbase: - description: Unit Base - format: double - type: number - yearnumber: - description: The number of the Month of the filing - format: int64 - type: number - type: object - FilingRequest: - properties: - data: - items: - $ref: "#/definitions/Filing" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - FilingResponse: - description: An array of Filing Objects - properties: - data: - items: - $ref: "#/definitions/Filing" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - FilingDueDate: - type: object - description: Dates when this FilingType is due for filing - properties: - duedate: - type: string - description: - type: string - FilingTypeInstance: - type: object - description: A list of jurisdictions that use this Filing Type - properties: - countryid: - type: string - description: Country Id - countyid: - type: string - description: County ID - objecttype: - type: string - description: - The type of object that owns this FilingType instance - filingtypeid: - description: The ID of the Filing Type for this Filing - format: string - placeid: - type: string - description: Place ID - stateid: - type: string - description: StateID - FilingType: - type: object - description: An array of FilingType Objects - properties: - accountid: - description: Tax Authority - type: string - contactid: - description: Contact - type: string - createdbyid: - description: Created By - type: string - createddate: - description: Created Date - type: string - duedates: - items: - $ref: "#/definitions/FilingDueDate" - type: array - filingcity: - description: Filing City - type: string - filingcountry: - description: Filing Country - type: string - filingpostalcode: - description: Filing Postal Code - type: string - filingstate: - description: Filing State - type: string - filingstreet: - description: Filing Street - type: string - formname: - description: Form Name - type: string - formversion: - description: Form Version - type: string - frequency: - description: Frequency - type: string - fullname: - description: Filing Full Name - type: string - id: - description: Record Id - type: string - instances: - items: - $ref: "#/definitions/FilingTypeInstance" - type: array - lastmodifiedbyid: - description: Last Modified By - type: string - lastmodifieddate: - description: Last Modifed Date - type: string - level: - description: Jurisdictional Level - type: string - name: - description: Name - type: string - ownerid: - description: Owner - type: string - sagatype: - description: Saga Type - type: string - submissionmethod: - description: Submission Method - type: string - templateinstructionsid: - description: Instructions Template - type: string - templatereturnid: - description: Return Template - type: string - FilingTypeRequest: - properties: - data: - items: - $ref: "#/definitions/FilingType" - type: array - meta: - $ref: "#/definitions/RequestMeta" - required: - - meta - - data - type: object - FilingTypeResponse: - description: An array of Filing Objects - properties: - data: - items: - $ref: "#/definitions/FilingType" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - GlAccount: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - description: Account - type: string - accountlevel: - description: Account Level - type: number - accountname: - description: Account Name - type: string - accountnumber: - description: Account Number - type: number - accountsign: - description: Account Sign - type: string - accounttype: - description: Account Type - type: string - description: - description: Description - type: string - name: - description: Display Name - type: string - id: - description: Telnexus Record Id - type: string - isactive: - description: Is Active? - type: boolean - isbankaccount: - description: Is Bank Account ? - type: boolean - issummary: - description: Is Summary? - type: boolean - parentfk: - description: Parent Foreign Key - type: string - parentglaccountid: - description: Parent GL Account - type: string - ref: - description: Reference - type: string - status: - description: Status - type: string - type: object - GlAccountRequest: - properties: - data: - items: - $ref: "#/definitions/GlAccount" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - GlAccountResponse: - properties: - data: - items: - $ref: "#/definitions/GlAccount" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - GlBalance: - properties: - tenantid: - description: tenant identifier - type: string - accountname: - description: Account Name - type: string - amount: - description: Amount - type: number - closedate: - description: Close Date - type: string - createdbyid: - description: Created By User ID - type: string - createddate: - description: Created Date - type: string - credits: - description: Credits - type: number - debits: - description: Debits - type: number - description: - description: Description - type: string - glaccountdisplay: - description: GL Account Display Value - type: string - glaccountid: - description: GL Account - type: string - id: - description: Telnexus Record Id Only; not used in POST - type: string - lastmodifiedbyid: - description: Last Modified By User ID - type: string - lastmodifieddate: - description: Last Modified Date - type: string - periodid: - description: Period ID - type: string - ref: - description: "Source System identifier for this record, if any" - type: string - rollupcredits: - description: Rollup Credits - type: number - rollupdebits: - description: Rollup Debits - type: number - status: - description: Status - type: string - type: object - GlBalanceResponse: - properties: - data: - items: - $ref: "#/definitions/GlBalance" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Ids: - description: Telnexus Record Ids - items: - type: string - type: array - IdsRequest: - properties: - data: - items: - $ref: "#/definitions/Ids" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - Ingest: - description: A record of the Ingest of information into Telnexus - properties: - tenantid: - description: tenant identifier - type: string - accountid: - description: Account ID - type: string - amount: - description: Rollup Tax Amount - format: double - type: number - backendid: - description: Backend ID - type: string - companyid: - description: Company ID - type: string - createdbyid: - description: Telnexus User ID - type: string - createddate: - description: Date of Job Creation - type: string - description: - description: Ingest Description - type: string - enddate: - description: End Date - type: string - filename: - description: Filename - type: string - formatted: - description: Numeric and Date Values Pre-formatted as Text - properties: - amount: - type: string - ingestdate: - type: string - invoicecount: - type: string - pocount: - type: string - revenuebase: - type: string - revenuenottaxable: - type: string - unitbase: - type: string - type: object - id: - description: Record Id - type: string - ingestdate: - description: Ingest Date - type: string - ingestfailurereason: - description: Ingest Failure Reason - type: string - ingesttype: - description: Ingest Type - enum: - - fabric - - internal - - suretax - - taxnexus-api - type: string - invoicecount: - description: Invoice Count - format: int64 - type: number - jobid: - description: Job ID - type: string - lastmodifiedbyid: - description: Telnexus User ID - type: string - lastmodifieddate: - description: Last Modified Date - type: string - metrclicense: - description: License - type: string - metrcstate: - description: State Code - type: string - objecttype: - description: Ingest Object Type - enum: - - account - - cash-receipt - - contact - - invoice - - order - - po - - quote - type: string - parentfk: - description: Parent Foreign Key - type: string - periodid: - description: Period ID - type: string - pocount: - description: PO Count - format: int64 - type: number - postfailurereason: - description: Post Failure Reason - type: string - ratingengineid: - description: Rating Engine ID - type: string - ref: - description: Source System Reference - type: string - revenuebase: - description: Rollup Revenue Base - format: double - type: number - revenuenet: - description: Rollup Revenue Net - format: double - type: number - revenuenottaxable: - description: Rollup Revenue Not Taxable - format: double - type: number - sagaid: - description: - The Saga ID used to link log entries and transactions - type: string - sagatype: - description: The type of Saga transaction being performed - type: string - source: - description: The source system that generated this job - type: string - startdate: - description: Start Date - type: string - status: - description: Ingest Status - enum: - - failed_accounting - - failed_existing - - failed_glpost - - failed_invoice - - failed_po - - ingested - - new - - posted - - queued - - rated - - rejected - type: string - taxtransactioncount: - description: Tax Transaction Count - format: int64 - type: number - templateid: - description: Template - type: string - unitbase: - description: Rollup Unit Base - format: int64 - type: number - required: - - accountid - - objecttype - type: object - IngestRequest: - properties: - data: - items: - $ref: "#/definitions/Ingest" - type: array - meta: - $ref: "#/definitions/RequestMeta" - required: - - meta - - data - type: object - IngestResponse: - description: An array of Print-Ready ingest Objects - properties: - data: - items: - $ref: "#/definitions/Ingest" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - InvalidError: - allOf: - - $ref: "#/definitions/Error" - - properties: - details: - items: - type: string - type: array - type: object - Invoice: - properties: - tenantid: - description: tenant identifier - type: string - accountbalance: - description: Account Balance - format: double - type: number - accountid: - description: Account - type: string - accountname: - description: Account Name - type: string - advance: - description: Advance? - type: boolean - amount: - description: Invoice Amount - format: double - type: number - amount_adjustment: - description: Amount Adjustment - format: double - type: number - amountdue: - description: Amount Due - format: double - type: number - amountpaid: - description: Amount Paid - format: double - type: number - auditmessage: - description: Audit Trail Message - type: string - billingcity: - description: Billing City - type: string - billingcountry: - description: Billing Country - type: string - billingpostalcode: - description: Billing Postal Code - type: string - billingrunid: - description: Billing Run - type: string - billingstate: - description: Billing State - type: string - billingstreet: - description: Billing Street - type: string - billtocontactid: - type: string - cannabistax: - description: Cannabis Tax - format: double - type: number - contractid: - description: Contract - type: string - coordinate: - $ref: "#/definitions/Address" - customerid: - description: Customer ID - type: string - dateissued: - description: Date Issued - type: string - daysdue: - description: Days Due - format: double - type: number - depositamount: - description: Deposit Amount - format: double - type: number - description: - description: Description - type: string - discount: - description: Discount - format: double - type: number - id: - description: Telnexus Record Id Only; not used in POST - type: string - invoicedate: - description: Invoice Date - type: string - invoicenumber: - description: Invoice Number - type: string - isinternational: - description: Is International? - type: boolean - issuedaccountbalance: - description: Issued Account Balance - format: double - type: number - issuedamountdue: - description: Issued Amount Due - format: double - type: number - issuedbyid: - description: Issued By - type: string - isvalid: - description: Is Valid? - type: boolean - items: - description: The items associated with this Invoice - items: - $ref: "#/definitions/InvoiceItem" - type: array - lineitemcount: - description: Line Item Count - format: int64 - type: number - minimumpaymentdue: - description: Minimum Payment Due - format: double - type: number - monthlyamount: - description: Monthly Amount - format: double - type: number - opportunityid: - description: Opportunity - type: string - orderid: - description: Order - type: string - overdue0: - description: Overdue0 - format: double - type: number - overdue120: - description: Overdue 120 Days Amount - format: double - type: number - overdue30: - description: Overdue 30 Days Amount - format: double - type: number - overdue45: - description: Overdue 45 Days Amount - format: double - type: number - overdue60: - description: Overdue 60 Days Amount - format: double - type: number - overdue90: - description: Overdue 90 Days Amount - format: double - type: number - parentfk: - description: - UUID Reference the master record that owns this item - type: string - partneraccountid: - description: Partner Account - type: string - payment_method: - description: Payment Method - type: string - paymentdue: - description: Payment Due - type: string - paymentmethodid: - description: Payment Method - type: string - paymentterms: - description: Payment Terms - type: string - periodid: - description: Period - type: string - picklistvalue: - description: Picklist Value - type: string - posted: - description: Posted - type: boolean - prioraccountbalance: - description: Prior Account Balance - format: double - type: number - prioradjustments: - description: Prior Adjustments - format: double - type: number - priorinvoiceamount: - description: Prior Invoice Amount - format: double - type: number - priorinvoicedate: - description: Prior Invoice Date - type: string - priorinvoiceid: - description: Prior Invoice - type: string - priorpaymentamount: - description: Prior Payment Amount - format: double - type: number - priorpaymentdate: - description: Prior Payment Date - type: string - priorpaymentid: - description: Prior Payment - type: string - priorpaymentmemo: - description: Prior Payment Memo - type: string - prorated: - description: Prorated? - type: boolean - prorateddays: - description: Prorated Days - format: double - type: number - purchaseamount: - description: Purchase Amount - format: double - type: number - quoteid: - description: Quote - type: string - ratingingestid: - description: Rating Ingest - type: string - ref: - description: "Source System identifier for this record, if any" - type: string - reference: - description: Reference - type: string - salesregulation: - description: Sales Regulation Type (Medicinal or Recreational) - type: string - salestax: - description: Sales Tax - format: double - type: number - scheduledpaymentdate: - description: Scheduled Payment Date - type: string - service_term: - description: Service Term - type: string - shippingcity: - description: Shipping City - type: string - shippingcountry: - description: Shipping Country - type: string - shippinghandling: - description: Shipping & Handling - format: double - type: number - shippingpostalcode: - description: Shipping Postal Code - type: string - shippingstate: - description: Shipping State - type: string - shippingstreet: - description: Shipping Street - type: string - statementitemtype: - description: Statement Item Type - type: string - status: - description: Status - type: string - subtotal: - description: Subtotal - format: double - type: number - suppressworkflow: - description: Suppress Workflow? - type: boolean - taxitems: - description: The taxes associated with this Invoice - items: - $ref: "#/definitions/TaxTransaction" - type: array - telecomtax: - description: Telecom Tax - format: double - type: number - templateid: - description: Template - type: string - type: - description: Type - type: string - whmcsclientid: - description: WHMCS Client ID - type: string - whmcsinvoiceid: - description: WHMCS Invoice ID - type: string - xeroid: - description: Xero Invoice Id - type: string - year: - description: Year - format: int64 - type: number - type: object - InvoiceBasic: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - description: - Account Identifier from Source System; ignored in tax - calculations - type: string - amount: - description: Invoice Amount; ignored in tax calculation - format: double - type: number - amountdue: - description: Amount Due; ignored in tax calculations - format: double - type: number - coordinate: - $ref: "#/definitions/Address" - id: - description: Telnexus Record Id Only; not used in POST - type: string - invoicedate: - description: - Invoice Date; should be date only or correct time zone if in - time notation - type: string - invoicenumber: - description: - Source System Customer-Facing Invoice Number; ignored in tax - calculation - type: string - items: - description: The items associated with this Invoice - items: - $ref: "#/definitions/ItemBasic" - type: array - parentfk: - description: - UUID Reference the master record that owns this item - type: string - ref: - description: "Source System identifier for this record, if any" - type: string - salesregulation: - description: Sales Regulation Type - type: string - status: - description: - Status used by for Billing Balances; ignored in tax - calculation - enum: - - closed - - delivered - - hold - - issued - - new - - posted - - rated - - rating_failed - - rating_ready - - reissued - - rendered - - uncollectable - - voided - type: string - subtotal: - description: Subtotal - format: double - type: number - type: - description: Invoice Type - type: string - type: object - InvoiceItem: - properties: - tenantid: - description: tenant identifier - type: string - census_tract: - description: Census Tract - type: string - cogs: - description: Cost of Goods Sold - type: number - format: double - contractid: - description: Contract Number - type: string - countyid: - description: County - type: string - description: - description: Line Item Description - type: string - exportdescription: - description: Export Description - type: string - family: - description: Family - type: string - id: - description: Telnexus Record Id Only; not used in POST - type: string - invoiceid: - description: Invoice - type: string - linenumber: - description: Line - format: int64 - type: number - list_price: - description: List Price - type: number - locationid: - description: Location - type: string - orderitemid: - description: Order Item - type: string - parentfk: - description: - UUID Reference the master record that owns this item - type: string - periodid: - description: Period - type: string - productcode: - description: Product Code - type: string - productid: - description: Product - type: string - quantity: - description: Quantity - format: double - type: number - quotelineitemid: - description: Quote Line Item - type: string - ref: - description: "Source System identifier for this record, if any" - type: string - rejected_quantity: - description: Rejected Quantity - format: double - type: number - revenueaccount: - description: Revenue Account - type: number - seq: - description: Seq - type: string - shipped_quantity: - description: Shipped Quantity - type: number - shippinghandling: - description: Shipping & Handling - type: number - sku: - description: SKU - type: string - subscriptionid: - description: Subscription - type: string - subtotal: - description: Subtotal - type: number - taxnexuscode: - description: Telnexus Code - type: string - totalprice: - description: Total Price - type: number - unitprice: - description: Unit Price - type: number - type: object - InvoiceRequest: - properties: - data: - items: - $ref: "#/definitions/InvoiceBasic" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - InvoiceResponse: - properties: - data: - items: - $ref: "#/definitions/Invoice" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - ItemBasic: - properties: - description: - description: Line Item Description - type: string - cogs: - description: Cost of Goods Sold - type: number - format: double - id: - description: Telnexus Record Id Only; not used in POST - type: string - invoiceid: - description: Source System Parent Foreign Key to Invoice - type: string - parentfk: - description: - UUID Reference the master record that owns this item - type: string - productcode: - description: Product Code - type: string - quantity: - description: Quantity - format: double - type: number - ref: - description: "Source System identifier for this record, if any" - type: string - salesregulation: - description: Sales Regulation Type - type: string - shippinghandling: - description: Shipping & Handling and Delivery Fees for this Item - format: double - type: number - subtotal: - description: Subtotal - format: double - type: number - taxnexuscode: - description: Telnexus Code - type: string - unitprice: - description: Unit Price - format: double - type: number - units: - description: The Unit of Measure for this item - enum: - - each - - month - - day - - week - - hour - - oz_drywt_flower - - oz_drywt_leaves - - oz_fresh - - gm - - oz - - lb - type: string - required: - - quantity - - unitprice - - taxnexuscode - - ref - type: object - Job: - properties: - accountid: - description: Telnexus Account Id - type: string - backendid: - description: Telnexus Backend ID - type: string - companyid: - description: Telnexus Company ID - type: string - coordinateid: - description: Telnexus Coordinate ID - type: string - createdbyid: - description: Telnexus User ID - type: string - createddate: - description: Date of Job Creation - type: string - month: - type: number - format: int64 - quarter: - type: number - format: int64 - semiannual: - type: number - format: int64 - year: - type: number - format: int64 - duration: - description: - The amount of time after the Start Time to perform one or more - jobs - enum: - - day - - document - - hour - - minute - - month - - quarter - - second - - week - - year - type: string - enddate: - description: End Date/Time - type: string - errorreason: - description: Error Reason - type: string - id: - description: Telnexus Record Id of the Job record - type: string - interval: - description: - The time interval by which multiple jobs are executed within - the Duration - enum: - - day - - each - - hour - - minute - - month - - quarter - - second - - week - - year - type: string - jobdate: - description: Job Date - type: string - lastmodifiedbyid: - description: Last Modified By - type: string - lastmodifieddate: - description: Last Modified Date - type: string - nextjobid: - description: Next Job - type: string - objecttype: - description: Object Type - enum: - - invoice - - order - - po - - quote - type: string - ownerid: - description: The user ID that owns this job - type: string - parameters: - description: Any parameters needed to process the job - type: string - periodid: - description: Period - type: string - ratingengineid: - description: Rating Engine - type: string - ref: - description: External Reference - type: string - reschedule: - description: Reschedule? - type: boolean - rescheduleinterval: - description: Reschedule Interval - format: int64 - type: number - sagaid: - description: - The Saga ID used to link log entries and transactions - type: string - sagatype: - description: The type of Saga transaction being performed - enum: - - newGLPostInvoices - - newIngestInvoice - - newIngestPO - type: string - source: - description: The source system that generated this job - enum: - - api - - fabric - - taxnexus - - telnexus - type: string - startdate: - description: Start Date/Time - type: string - status: - description: Status - enum: - - active - - complete - - error - - new - - queued - type: string - target: - description: The target system that executes this job - enum: - - api - - fabric - - taxnexus - - telnexus - type: string - type: - description: Type - enum: - - coordinate - - email - - ingest - - tax - type: string - type: object - JobRequest: - properties: - data: - items: - $ref: "#/definitions/Job" - type: array - meta: - $ref: "#/definitions/RequestMeta" - required: - - meta - - data - type: object - JobResponse: - description: An array of Print-Ready ingest Objects - properties: - data: - items: - $ref: "#/definitions/Job" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - License: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - type: string - backendid: - type: string - contactid: - type: string - createdbyid: - type: string - createddate: - type: string - dateissued: - description: Date - type: string - expirationdate: - description: Expiration Date - type: string - id: - description: Telnexus Record Id Only; not used in POST - type: string - iscanceled: - description: Is Canceled? - type: boolean - isrevoked: - description: Is Revoked? - type: boolean - lastmodifiedbyid: - type: string - lastmodifieddate: - type: string - licensetypeid: - description: License Type Number - type: string - licensenumber: - description: License Number - type: string - ref: - description: "Source System identifier for this record, if any" - type: string - status: - description: Status - type: string - type: object - LicenseRequest: - properties: - data: - items: - $ref: "#/definitions/License" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - LicenseResponse: - properties: - data: - items: - $ref: "#/definitions/License" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - LicenseType: - properties: - accountid: - type: string - agentid: - type: string - contactid: - type: string - cost: - description: Cost - type: number - format: double - createdbyid: - type: string - createddate: - type: string - domainid: - type: string - frequency: - description: Frequency - type: string - id: - description: Telnexus Record Id - type: string - lastmodifiedbyid: - type: string - lastmodifieddate: - type: string - level: - description: Level - type: string - name: - description: License Type Name - type: string - picklistvalue: - description: Picklist Value - type: string - ref: - description: "Source System identifier for this record, if any" - type: string - restriction: - description: Restriction - type: string - tier: - description: Tier - type: string - domains: - type: array - items: - type: string - jurisdictions: - type: array - items: - $ref: "#/definitions/GeoLicenseTypeInstance" - type: object - GeoLicenseTypeInstance: - description: Links a license type to a geography - type: object - properties: - objecttype: - type: string - placeid: - type: string - countyid: - type: string - stateid: - type: string - countryid: - type: string - LicenseTypeResponse: - properties: - data: - items: - $ref: "#/definitions/LicenseType" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Message: - properties: - message: - type: string - ref: - type: string - status: - type: integer - type: object - Order: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - type: string - accountnumber: - description: Account Number - type: string - activatedbyid: - description: Activated By - type: string - activateddate: - description: Activated Date - type: string - amount: - description: Order Amount - format: double - type: number - billingaddress: - $ref: "#/definitions/Address" - billingcontactid: - type: string - billingtype: - description: Billing Type - type: string - billtocontactid: - description: Bill To Contact - type: string - cannabistax: - description: Cannabis Tax - format: double - type: number - companyauthorizedbyid: - description: Company Authorized By - type: string - companyauthorizeddate: - description: Company Authorized Date - type: string - completion: - description: Completion Status - type: string - contract: - $ref: "#/definitions/ContractBasic" - contractenddate: - description: Contract End Date - type: string - contractid: - description: Contract Number - type: string - contractname: - description: Contract Name - type: string - coordinate: - $ref: "#/definitions/Address" - customerauthorizedbyid: - description: Customer Authorized By - type: string - customerauthorizeddate: - description: Customer Authorized Date - type: string - description: - description: Description - type: string - effectivedate: - description: Order Start Date - type: string - enddate: - description: Order End Date - type: string - enduserid: - type: string - id: - description: Telnexus Record Id Only; not used in POST - type: string - installationdate: - description: Installation Date - type: string - invoice: - description: Invoice - type: string - isreductionorder: - description: Reduction Order - type: boolean - items: - description: The Order Items - items: - $ref: "#/definitions/OrderItem" - type: array - lineitemcount: - description: Line Item Count - format: int64 - type: number - monthlyamount: - description: Monthly Amount - type: number - name: - description: Order Name - type: string - open: - description: Open Order? - type: boolean - opportunityid: - description: Opportunity - type: string - ordernumber: - description: Order Number - type: string - orderreferencenumber: - description: Order Reference Number - type: string - originalorderid: - description: Original Order - type: string - ownerid: - description: Order Owner - type: string - parentfk: - description: - UUID Reference the master record that owns this item - type: string - paymentmethodid: - description: Payment Method - type: string - paymentterms: - description: Payment Terms - type: string - podate: - description: PO Date - type: string - ponumber: - description: PO Number - type: string - provisioningstatus: - description: Provisioning Status - type: string - purchaseamount: - description: Purchase Amount - type: number - quoteid: - description: Quote - type: string - recordtypeid: - description: Order Record Type - type: string - ref: - description: "Source System identifier for this record, if any" - type: string - salesregulation: - description: Sales Regulation Type - type: string - salestax: - description: Sales Tax - format: double - type: number - serviceterm: - description: Service Term - type: string - shippingaddress: - $ref: "#/definitions/Address" - shippingcontactid: - type: string - shippinghandling: - description: Shipping & Handling - type: number - shiptocontactid: - description: Ship To Contact - type: string - status: - description: Status - type: string - subtotal: - description: Subtotal - format: double - type: number - taxitems: - description: The taxes associated with this Order - items: - $ref: "#/definitions/TaxTransaction" - type: array - telecomtax: - description: Telecom Tax - format: double - type: number - templateid: - description: Template - type: string - totalamount: - description: Order Amount - format: int64 - type: number - type: - description: Order Type - type: string - type: object - OrderBasic: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - description: Account - type: string - amount: - description: Order Amount - format: double - type: number - amountdue: - description: Amount Due - format: double - type: number - coordinate: - $ref: "#/definitions/Address" - id: - description: Telnexus Record Id Only; not used in POST - type: string - items: - $ref: "#/definitions/ItemBasic" - orderdate: - description: Order Date - type: string - parentfk: - description: - UUID Reference the master record that owns this item - type: string - ref: - description: "Source System identifier for this record, if any" - type: string - salesregulation: - description: Sales Regulation Type (Medicinal or Recreational) - type: string - status: - description: Status - type: string - subtotal: - description: Subtotal - format: double - type: number - type: - description: Type - type: string - type: object - OrderBasicRequest: - properties: - data: - items: - $ref: "#/definitions/OrderBasic" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - OrderItem: - properties: - tenantid: - description: tenant identifier - type: string - account: - description: Account - type: object - activated: - description: Activated? - type: boolean - activatedby: - description: Activated By - type: string - availablequantity: - description: Available Quantity - format: double - type: number - contractid: - description: Contract Number - type: string - createreservation: - description: Create Reservation? - type: boolean - datedelivered: - description: Date Delivered - type: string - dateordered: - description: Date Ordered - type: string - datepromised: - description: Date Promised - type: string - description: - description: Line Description - type: string - discount: - description: Discount - format: double - type: number - enddate: - description: End Date - type: string - family: - description: Family - type: string - id: - description: Telnexus Record Id Only; not used in POST - type: string - inventorytracking: - description: Inventory Tracking - type: boolean - invoiceitemid: - description: Invoice Item - type: string - linegrossamount: - description: Line Gross Amount - format: double - type: number - lineitemnumber: - description: Line Item Number - format: int64 - type: number - listprice: - description: List Price - format: double - type: number - locationid: - description: Location - type: string - orderid: - description: Order - type: string - orderitemnumber: - description: Order Product Number - type: string - originalorderitemid: - description: Original Order Product - type: string - parentfk: - description: - UUID Reference the master record that owns this item - type: string - posted: - description: Posted? - type: boolean - product2id: - description: Product - type: string - productid: - description: ProductId - type: string - productname: - description: Product Name - type: string - quantity: - description: Quantity - format: double - type: number - quantityonhand: - description: Quantity On Hand - format: double - type: number - quotelineitemid: - description: Quote Line Item - type: string - ref: - description: "Source System identifier for this record, if any" - type: string - servicedate: - description: Start Date - type: string - shippinghandling: - description: Shipping & Handling - format: double - type: number - status: - description: Status - type: string - subscriptionid: - description: Subscription - type: string - subtotal: - description: Subtotal - format: double - type: number - taxnexuscodeid: - description: Telnexus Code - type: string - totalprice: - description: Total Price - format: double - type: number - unitprice: - description: Unit Price - format: double - type: number - type: object - OrderResponse: - description: An array of Order Objects - properties: - data: - items: - $ref: "#/definitions/Order" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Pagination: - properties: - NextLink: - type: string - PLimit: - format: int64 - type: integer - POffset: - format: int64 - type: integer - PageSize: - format: int64 - type: integer - SetSize: - format: int64 - type: integer - type: object - Period: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - description: Account that owns this Period - type: string - companyid: - description: Company - type: string - days: - description: Days - format: int64 - type: number - enddate: - description: End Date - type: string - id: - description: Telnexus Record Id - type: string - month: - description: Month number - format: int64 - type: number - name: - description: Period Name - type: string - quarter: - description: Quarter number - format: int64 - type: number - ref: - description: "Source System identifier for this record, if any" - type: string - semiannual: - description: Semiannual number - format: int64 - type: number - startdate: - description: Start Date - type: string - status: - description: Status - type: string - year: - description: Year number - format: int64 - type: number - type: object - PeriodRequest: - properties: - data: - items: - $ref: "#/definitions/Period" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - PeriodResponse: - description: An array of Period objects - properties: - data: - items: - $ref: "#/definitions/Period" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Place: - properties: - accountid: - description: Account - type: string - accountvalidation: - description: Account Validation - type: string - amount: - description: Rollup Amount - format: double - type: number - latitude: - type: number - format: double - longitude: - type: number - format: double - areadescription: - description: AreaDescription - type: string - contactid: - description: Contact - type: string - countryid: - description: Telnexus ID of the Country this places is in - type: string - countyid: - description: County - type: string - enrollmentstatus: - description: Enrollment Status - type: string - fips: - description: FIPS - type: string - fipsclass: - description: FIPS Class - type: string - functionalstatus: - description: Functional Status - type: string - geocode: - description: Geocode - type: string - gnis: - description: GNIS - format: int64 - type: number - hasdistricttaxes: - description: True if this Place has District Sales taxes - type: boolean - id: - description: Salesforce Record Id - type: string - interest: - description: Interest - format: double - type: number - landarea: - description: Land Area - format: int64 - type: number - legalname: - description: Legal Name - type: string - name: - description: Place Name - type: string - penalty: - description: Penalty - format: double - type: number - polygoncentroid: - description: Polygon Centroid - type: object - ref: - description: External reference if any - type: string - reportedadjustments: - description: Reported Adjustments - type: number - format: double - reporteddeductions: - description: Reported Deductions - type: number - format: double - reportednetrevenue: - description: Reported Net Revenue - type: number - format: double - reportedrate: - description: Reported Rate - type: number - format: double - reportedrevenue: - description: Reported Revenue - type: number - format: double - revenuebase: - description: Rollup Revenue Base - type: number - format: double - revenuenet: - description: Rollup Revenue Net - type: number - format: double - revenuenottaxable: - description: Rollup Revenue Not Taxable - type: number - format: double - stateid: - description: State - type: string - status: - description: Document Status - type: string - subtotal: - description: Reported Tax - format: double - type: number - taxinstances: - items: - $ref: "#/definitions/TaxInstance" - type: array - templateid: - description: Template - type: string - totalamount: - description: Total Amount - format: double - type: number - totalarea: - description: Total Area - format: int64 - type: number - unitbase: - description: Unit Base - type: number - waterarea: - description: Water Area - format: int64 - type: number - type: object - PlaceResponse: - properties: - data: - items: - $ref: "#/definitions/Place" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Pricebook: - properties: - tenantid: - description: tenant identifier - type: string - description: - description: Description - type: string - id: - description: Telnexus Record Id - type: string - isactive: - description: Active - type: boolean - isstandard: - description: Is Standard Price Book - type: boolean - name: - description: Price Book Name - type: string - type: object - PricebookEntry: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - description: Active - type: string - agentid: - description: Created By - type: string - id: - description: Record Id - type: string - pricebook: - $ref: "#/definitions/Pricebook" - procuct: - $ref: "#/definitions/Product" - productcode: - description: Product Code - type: string - unitprice: - description: List Price - format: double - type: number - usestandardprice: - description: Use Standard Price - type: boolean - type: object - Product: - properties: - AccountID: - description: The ID of the Account that owns this product - type: string - AgencyType: - description: Agency Type - type: string - AssetTracking: - description: Asset Tracking? - type: boolean - CreatedByID: - description: ID of who created this record instance - type: string - CreatedDate: - description: Date of record creation - type: string - Description: - description: Product Description - type: string - DescriptionSKU: - description: DescriptionSKU - type: string - DisplayURL: - description: Display URL - type: string - Family: - description: Product Family - type: string - ID: - description: Telnexus Record Id - type: string - Image500: - description: Image (500) - type: string - ImageFull: - description: Image (Full) - type: string - InventoryTracking: - description: Inventory Tracking? - type: boolean - IsActive: - description: Active - type: boolean - IsGeneric: - description: isGeneric - type: boolean - LastModifiedByID: - description: Last modified by ID - type: string - LastModfiedDate: - type: string - description: Last Modified Date - Manufacturer: - description: Manufacturer - type: string - ManufacturerProductCode: - description: Manufacturer Product Code - type: string - MRCInterval: - description: MRC Interval - format: int64 - type: number - MSRP: - description: MSRP - format: double - type: number - Name: - description: Product Name - type: string - ProductCode: - description: Product Code - type: string - Prorateable: - description: Prorateable? - type: boolean - Publish: - description: Publish? - type: boolean - PublishUPC: - description: Publish UPC - type: string - QuantityUnitOfMeasure: - description: Quantity Unit Of Measure - type: string - Refundable: - description: Refundable? - type: boolean - ShippingWeight: - description: Shipping Weight - format: double - type: number - SKU: - description: SKU - type: string - Specifications: - description: Specifications - type: string - TelnexusCodeID: - description: Telnexus Code - type: string - TelnexusCode: - description: Telnexus Code Name - type: string - TenantID: - description: tenant identifier - type: string - Units: - description: Units - type: string - VendorID: - description: Vendor - type: string - VendorName: - description: Vendor Name - type: string - VendorPartNumber: - description: Vendor Part Number - type: string - VendorPrice: - description: Vendor Price - format: double - type: number - type: object - ProductRequest: - properties: - data: - items: - $ref: "#/definitions/Product" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - ProductResponse: - properties: - data: - items: - $ref: "#/definitions/Product" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - PurchaseOrder: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - type: string - creditcardid: - type: string - date_expires: - description: Date Expires - type: string - date_promised: - description: Date Promised - type: string - date_requested: - description: Date Requested - type: string - description: - description: Description - type: string - duedate: - description: Due Date - type: string - enduserid: - type: string - grand_total: - description: Grand Total - format: double - type: number - id: - description: Telnexus Record Id - type: string - items: - items: - $ref: "#/definitions/PurchaseOrderItem" - type: array - lineitemcount: - description: Line Item Count - format: int64 - type: number - opportunityid: - description: Opportunity Name - type: string - orderid: - description: Order Number - type: string - parentfk: - description: The record identifier from the source system - type: string - paymentterms: - description: Payment Terms - type: string - podate: - description: Date - type: string - ponumber: - description: Number - type: string - posted: - description: Posted - type: boolean - quoteid: - description: Quote Name - type: string - sales_tax: - description: Addl Tax - format: double - type: number - salesregulation: - description: Sales Regulation Type (Medicinal or Recreational) - type: string - service_term: - description: Service Term - type: string - ship_date: - description: Ship Date - type: string - shipping_country: - description: Shipping Country - type: string - shipping_special_instructions: - description: Shipping Special Instructions - type: string - shippingaddress: - description: Shipping Address - type: string - shippingcity: - description: Shipping City - type: string - shippingcontactid: - type: string - shippinghandling: - description: Shipping & Handling - format: double - type: number - shippingpostalcode: - description: Shipping Postal Code - type: string - shippingstate: - description: Shipping State - type: string - shippingstreet: - description: Shipping Street - type: string - status: - description: Status - type: string - subtotal: - description: Subtotal - format: double - type: number - taxable: - description: Taxable? - type: string - taxitems: - description: The taxes associated with this Purchase Order - items: - $ref: "#/definitions/TaxTransaction" - type: array - totalprice: - description: Total Price - format: double - type: number - type: - description: Type - type: string - vendorid: - type: string - vendorquotenumber: - description: Vendor Quote Number - type: string - type: object - PurchaseOrderBasic: - properties: - accountid: - description: Account - type: string - amount: - description: Purchase Order Amount - type: number - amountdue: - description: Amount Due - format: double - type: number - coordinate: - $ref: "#/definitions/Address" - id: - description: Order Id - type: string - items: - items: - $ref: "#/definitions/ItemBasic" - type: array - podate: - description: Purcahse Order Date - type: string - ponumber: - description: Purchase Order Number - type: string - salesregulation: - description: Sales Regulation Type (Medicinal or Recreational) - type: string - status: - description: Status - type: string - subtotal: - description: Subtotal - format: double - type: number - type: - description: Type - type: string - type: object - PurchaseOrderItem: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - description: Account - type: string - description: - description: Line Item Description - type: string - due_date: - description: Due Date - type: string - enduserid: - description: End User - type: string - id: - description: Record Id - type: string - linenumber: - description: Line - format: int64 - type: number - locationid: - description: Location - type: string - orderitemid: - description: Order Item - type: string - parentfk: - description: - The record identifier of the parent record from the source - system - type: string - partneraccountid: - description: Partner Account - type: string - posted: - description: Posted - type: boolean - pricebookentryid: - description: PricebookEntryID - type: string - product: - description: Product - type: object - productcode: - description: Product Code - type: string - purchaseorderid: - description: Purchase Order - type: string - quantity: - description: Quantity - format: double - type: number - quotelineitemid: - description: Quote Item - type: string - received_qty: - description: Received Qty - format: double - type: number - rejected_qty: - description: Rejected Qty - format: double - type: number - seq: - description: Record ID Name - type: string - shipmentitmeid: - description: Shipment Item - type: string - status: - description: Status - type: string - stocked_qty: - description: Stocked Qty - format: double - type: number - subtotal: - description: Subtotal - format: double - type: number - taxable: - description: Taxable? - type: string - taxnexuscode: - description: Telnexus Code - type: string - totalprice: - description: Total Price - format: double - type: number - unitprice: - description: Unit Price - format: double - type: number - type: object - PurchaseOrderRequest: - properties: - data: - items: - $ref: "#/definitions/PurchaseOrder" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - PurchaseOrderResponse: - description: An array of Purchase Order Objects - properties: - data: - items: - $ref: "#/definitions/PurchaseOrder" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Quote: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - type: string - additionaladdress: - description: Additional To - type: object - additionalname: - description: Additional To Name - type: string - billingaddress: - description: Bill To - type: object - billingcontactid: - type: string - billingname: - description: Bill To Name - type: string - cannabistax: - description: Cannabis Tax - format: double - type: number - contactid: - type: string - contractid: - type: string - coordinateid: - type: string - creditterms: - description: Credit Terms - type: string - date: - description: Quote Date - type: string - description: - description: Description - type: string - discount: - description: Discount - format: double - type: number - discountamount: - description: Discount Amount - format: double - type: number - email: - description: Email - type: string - enduserid: - type: string - expirationdate: - description: Expiration Date - type: string - fax: - description: Fax - type: string - grandtotal: - description: Grand Total - format: double - type: number - id: - description: Telnexus Record Id Only; not used in POST - type: string - installationdate: - description: Installation Date - type: string - issyncing: - description: Syncing - type: boolean - items: - items: - $ref: "#/definitions/QuoteItem" - type: array - lineitemcount: - description: Line Items - format: int64 - type: number - monthlyamount: - description: Monthly Amount - format: double - type: number - name: - description: Quote Name - type: string - opportunityid: - description: Opportunity Name - type: string - ownerid: - description: Owner Name - type: string - parentfk: - description: - UUID Reference the master record that owns this item - type: string - paymentterms: - description: Payment Terms - type: string - phone: - description: Phone - type: string - purchaseamount: - description: Purchase Amount - format: double - type: number - quoteamount: - description: Quote Amount - format: double - type: number - quotenumber: - description: Quote Number - type: string - quotetoaddress: - description: Quote To - type: object - quotetoname: - description: Quote To Name - type: string - ref: - description: "Source System identifier for this record, if any" - type: string - salesregulation: - description: Sales Regulation Type - type: string - serviceterm: - description: Service Term - type: string - shippingaddress: - description: Ship To - type: object - shippingcontactid: - description: Shipping Contact - type: string - shippinghandling: - description: Shipping and Handling - format: double - type: number - shippingname: - description: Ship To Name - type: string - status: - description: Status - type: string - subtotal: - description: Subtotal - format: double - type: number - suppressworkflow: - description: Suppress Workflow? - type: boolean - tax: - description: Tax - format: double - type: number - taxitems: - description: The taxes associated with this Quote - items: - $ref: "#/definitions/TaxTransaction" - type: array - telecomtax: - description: Telecom Tax - format: double - type: number - templateid: - description: Template - type: string - totalprice: - description: Total Price - format: double - type: number - type: - description: Quote Type - type: string - type: object - QuoteBasic: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - description: Account - type: string - amount: - description: Quote Amount - type: number - amountdue: - description: Amount Due - type: number - coordinate: - $ref: "#/definitions/Address" - id: - description: Telnexus Record Id Only; not used in POST - type: string - items: - items: - $ref: "#/definitions/QuoteItemBasic" - type: array - parentfk: - description: - UUID Reference the master record that owns this item - type: string - quotedate: - description: Quote Date - type: string - ref: - description: "Source System identifier for this record, if any" - type: string - salesregulation: - description: Sales Regulation Type (Medicinal or Recreational) - type: string - status: - description: Status - type: string - subtotal: - description: Subtotal - format: double - type: number - type: - description: Type - type: string - type: object - QuoteItem: - properties: - tenantid: - description: tenant identifier - type: string - description: - description: Line Item Description - type: string - discount: - description: Discount - format: double - type: number - discountamount: - description: Discount Amount - format: double - type: number - id: - description: Telnexus Record Id Only; not used in POST - type: string - linegrossamount: - description: Line Gross Amount - format: double - type: number - linenumber: - description: Line Item Number - type: string - listprice: - description: List Price - type: number - locationid: - description: Location - type: string - parentfk: - description: - UUID Reference the master record that owns this item - type: string - productid: - description: Product record ID - type: string - productname: - description: Product Name - type: string - quantity: - description: Quantity - format: double - type: number - quoteid: - description: Quote Name - type: string - ref: - description: "Source System identifier for this record, if any" - type: string - servicedate: - description: Date - type: string - shippinghandling: - description: Shipping & Handling - format: double - type: number - subtotal: - description: Subtotal - format: double - type: number - supplierid: - description: Supplier - type: string - taxable: - description: Taxable? - format: double - type: string - totalprice: - description: Total Price - format: double - type: number - unitprice: - description: Sales Price - format: double - type: number - type: object - QuoteItemBasic: - properties: - tenantid: - description: tenant identifier - type: string - description: - description: Line Item Description - type: string - id: - description: Telnexus Record Id Only; not used in POST - type: string - invoiceid: - description: Invoice - type: string - parentfk: - description: - UUID Reference the master record that owns this item - type: string - productcode: - description: Product Code - type: string - quantity: - description: Quantity - format: double - type: number - ref: - description: "Source System identifier for this record, if any" - type: string - shippinghandling: - description: Shipping & Handling - format: double - type: number - subtotal: - description: Subtotal - format: double - type: number - taxnexuscode: - description: Telnexus Code - type: string - unitprice: - description: Unit Price - format: double - type: number - type: object - QuoteResponse: - properties: - data: - items: - $ref: "#/definitions/Quote" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - RequestMeta: - properties: - TelnexusAccount: - description: Telnexus Account Number of the Reseller or OEM - type: string - required: - - TelnexusAccount - type: object - ResponseMeta: - properties: - Contact: - description: Contact Info - type: string - Copyright: - description: Copyright Info - type: string - Info: - description: API Information - type: string - License: - description: License Info - type: string - OperationID: - type: string - Pagination: - $ref: "#/definitions/Pagination" - RequestIP: - type: string - RequestType: - type: string - RequestURL: - type: string - ServerInfo: - type: string - ServerResponseTime: - type: string - ServerTimeStamp: - type: string - TelnexusAccount: - type: string - UserID: - type: string - type: object - Service: - type: object - properties: - id: - type: string - description: Telnexus Record Id - active: - type: boolean - description: Active? - clusterid: - type: string - description: Cluster - clusterip: - type: string - description: Cluster IP - clusterurl: - type: string - description: Cluster URL - createdbyid: - type: string - description: Created By - createddate: - type: string - description: Created Date - environment: - type: string - description: Environment - externalurl: - type: string - description: External URL - gelfaddress: - type: string - description: GELF Address - lastmodifiedbyid: - type: string - description: Last Modified By - lastmodifieddate: - type: string - description: Last Modified Date - networkalias: - type: string - description: Network Alias - openapiversion: - type: string - description: OpenAPI Version - ownerid: - type: string - description: Owner - portexternal: - type: string - description: Port - External - porttest: - type: string - description: Port - Test - proxytype: - type: string - description: Proxy Type - replicas: - type: number - format: int64 - description: Replicas - repourl: - type: string - description: Repo URL - servicename: - type: string - description: Service Name - tenantid: - type: string - description: tenantid - version: - type: string - description: Version - ServiceRequest: - properties: - data: - items: - $ref: "#/definitions/Service" - type: array - meta: - $ref: "#/definitions/RequestMeta" - required: - - meta - - data - type: object - ServiceResponse: - description: An array of Service Objects - properties: - data: - items: - $ref: "#/definitions/Service" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - State: - properties: - accountid: - description: Account - type: string - amount: - description: Rollup Amount - format: double - type: number - code: - description: State Code - type: string - contactid: - description: Contact - type: string - latitude: - type: number - format: double - longitude: - type: number - format: double - contryid: - description: Country - type: string - division: - description: Division - type: string - enrollmentstatus: - description: Enrollment Status - type: string - fips: - description: FIPS - type: string - geocode: - description: State Geocode - type: string - gnis: - description: GNIS - type: number - format: int64 - id: - description: Telnexus Record Id - type: string - interest: - description: Interest - type: number - landarea: - description: Land Area - type: number - format: int64 - name: - description: State Name - type: string - penalty: - description: Penalty - type: number - format: double - ref: - description: "Source System identifier for this record, if any" - type: string - region: - description: Region - type: string - reportedadjustments: - description: Reported Adjustments - type: number - format: double - reporteddeductions: - description: Reported Deductions - type: number - format: double - reportednetrevenue: - description: Reported Net Revenue - type: number - format: double - reportedrate: - description: Reported Rate - type: number - format: double - reportedrevenue: - description: Reported Revenue - type: number - format: double - revenuebase: - description: Rollup Revenue Base - type: number - format: double - revenuenet: - description: Rollup Revenue Net - type: number - format: double - revenuenottaxable: - description: Rollup Revenue Not Taxable - type: number - format: double - sgc: - description: SGC - type: string - status: - description: Document Status - type: string - subtotal: - description: Reported Tax - type: number - format: double - taxinstances: - items: - $ref: "#/definitions/TaxInstance" - type: array - templateid: - description: Template - type: string - totalamount: - description: Total Amount - type: number - format: double - totalarea: - description: Total Area - type: number - format: int64 - unitbase: - description: Unit Base - type: number - format: double - waterarea: - description: Water Area - format: int64 - type: number - type: object - StateResponse: - description: An array of State objects - properties: - data: - items: - $ref: "#/definitions/State" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Statement: - properties: - tenantid: - description: tenant identifier - type: string - account: - description: Account - type: string - accountbalance: - description: Account Balance - type: number - accountcity: - description: Account City - type: string - accountcountry: - description: Account Country - type: string - accountname: - description: Account Name - type: string - accountpostalcode: - description: Account Postal Code - type: string - accountstate: - description: Account State - type: string - accountstatecode: - description: Account State Code - type: string - accountstreet: - description: Account Street - type: string - billingcountrycode: - description: Billing Country Code - type: string - contact: - description: Contact - type: string - date: - description: Statement Date - type: string - datefrom: - description: Date From - type: string - dateto: - description: Date To - type: string - deliverymethod: - description: Delivery Method - type: string - name: - description: Statement Number - type: string - recipientemail: - description: Recipient Email - type: string - recipienttype: - description: Recipient Type - type: string - statementid: - description: Statement Salesforce ID - type: string - type: object - StatementRequest: - properties: - data: - items: - $ref: "#/definitions/Statement" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - StatementResponse: - description: An array of Statement objects - properties: - data: - items: - $ref: "#/definitions/Statement" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Submission: - properties: - tenantid: - description: tenant identifier - type: string - companyid: - description: The Company that did the submission (Telnexus) - type: string - contactid: - description: Submission Contact - type: string - createdbyid: - description: Created By User ID - type: string - createddate: - description: Created Date - type: string - id: - description: Telnexus Record Id Only; not used in POST - type: string - lastmodifiedbyid: - description: Last Modified By User ID - type: string - lastmodifieddate: - description: Last Modified Date - type: string - notes: - description: Cover Letter - type: string - parentfk: - description: - UUID Reference the master record that owns this item - type: string - penalty: - description: Penalty paid - format: double - type: number - ref: - description: "Source System identifier for this record, if any" - type: string - reportedadjustments: - description: Reported Adjustments - format: double - type: number - reporteddeductions: - description: Reported Deductions - format: double - type: number - reportednetrevenue: - description: Reported Net Revenue - format: double - type: number - reportedrate: - description: Reported Rate - format: double - type: number - reportedrevenue: - description: Reported Revenue - format: double - type: number - revenuebase: - description: Revenue Base - format: double - type: number - revenuenet: - description: Revenue Net - format: double - type: number - revenuenottaxable: - description: Revenue Not Taxable - format: double - type: number - status: - description: Status - type: string - date: - description: Submission Date - type: string - submissionnumber: - description: Submission Number - type: string - subtotal: - description: Amount of remittance before penalty - format: double - type: number - taxtypeid: - description: - Telnexus ID of the TaxType for which this submssion is being - made - type: string - totalamount: - description: Total Amount of remittance - format: double - type: number - type: object - SubmissionRequest: - properties: - data: - items: - $ref: "#/definitions/Submission" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - SubmissionResponse: - description: An array of Submission objects - properties: - data: - items: - $ref: "#/definitions/Submission" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Subscription: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - type: string - activateddate: - description: Activated Date - type: string - activateduserid: - description: Activated By - type: string - allowedminutesinbound: - description: Allowed Minutes Inbound - format: double - type: number - allowedminutesoutbound: - description: Allowed Minutes Outbound - format: double - type: number - amount: - description: Amount - format: double - type: number - assetid: - description: Asset Name - type: string - auditmessage: - description: Audit Trail Message - type: string - canceldate: - description: Cancel Date - type: string - contract: - $ref: "#/definitions/ContractBasic" - description: - description: Description - type: string - directionsensitive: - description: Direction Sensitive Rating? - type: boolean - effectivedate: - description: Effective Date - type: string - email: - description: Email - type: string - enduserid: - type: string - fax_emails: - description: Fax Emails - type: string - id: - description: Telnexus Record Id - type: string - isactive: - description: Active? - type: boolean - orderdate: - description: Order Date - type: string - orderitemid: - description: Order Item - type: string - overagerateinbound: - description: Overage Rate Inbound - format: double - type: number - overagerateoutbound: - description: Overage Rate Outbound - format: double - type: number - password: - description: Password - type: string - paymentterms: - description: Payment Terms - type: string - pricebookid: - description: Price Book - type: string - productid: - description: Product record ID - type: string - productcode: - description: Product Code - type: string - productname: - description: Product Name - type: string - quantity: - description: Quantity - type: string - quoteitemid: - description: Quote Item - type: string - seq: - description: Subscription ID - type: string - status: - description: Status - type: string - suretax: - description: Suretax Code - type: string - tollfreerating: - description: tollfreeRating - type: boolean - type: - description: Type - type: string - unitprice: - description: Unit Price - format: double - type: number - units: - description: Units - type: string - unlimited: - description: Unlimited usage? - type: boolean - username: - description: Username - type: string - type: object - SubscriptionRequest: - properties: - data: - items: - $ref: "#/definitions/Subscription" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - SubscriptionResponse: - properties: - data: - items: - $ref: "#/definitions/Subscription" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - TaxInstance: - properties: - countryid: - description: - The Telnexus ID of the Country that owns this instance - type: string - countyid: - description: - The Telnexus ID of the County that owns this instance - type: string - createdbyid: - type: string - createddate: - description: The creation date of this database record - type: string - lastmodifiedbyid: - type: string - lastmodifieddate: - type: string - placeid: - description: - The Telnexus ID of the Place that owns this instance - type: string - stateid: - description: - The Telnexus ID of the State that owns this instance - type: string - taxtypeid: - description: The Telnexus Tax Type ID of this instance - type: string - type: - description: - "The Type of instance refers to the linking object (place, - county, state, country)" - type: string - type: object - TaxInvoicesRequest: - properties: - data: - items: - $ref: "#/definitions/InvoiceBasic" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - TaxOrdersRequest: - properties: - data: - items: - $ref: "#/definitions/OrderBasic" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - TaxPurchaseOrdersRequest: - properties: - data: - items: - $ref: "#/definitions/PurchaseOrderBasic" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - TaxQuotesRequest: - properties: - data: - items: - $ref: "#/definitions/QuoteBasic" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - TaxTransaction: - properties: - tenantid: - description: tenant identifier - type: string - accountid: - description: Account - type: string - amount: - description: Amount - format: double - type: number - effectiverate: - description: Effective Rate - format: double - type: number - filingid: - description: Filing - type: string - id: - description: Telnexus Record Id - type: string - invoiceid: - description: Invoice - type: string - invoiceitemid: - description: Invoice Item - type: string - issummary: - description: isSummary - type: boolean - journalitemid: - description: - "The Id of the GL Journal Item, part of a Journal Entry" - type: string - orderid: - description: Order - type: string - orderitemid: - description: Order Product - type: string - percenttaxable: - description: Percent Taxable - format: double - type: number - periodid: - description: Period - type: string - placeid: - description: Place - type: string - posted: - description: Posted - type: boolean - quoteid: - description: Quote - type: string - quoteitemid: - description: Quote Line Item - type: string - ratingingestid: - description: Rating Ingest - type: string - ratingtype: - description: Rating Type - type: string - revenuebase: - description: Revenue Base - format: double - type: number - revenuenet: - description: Revenue Net - format: double - type: number - revenuenottaxable: - description: Revenue Not Taxable - format: double - type: number - taxexemptrevenue: - description: Tax Exempt Revenue - format: double - type: number - taxrate: - description: Tax Rate - format: double - type: number - taxtypeid: - description: Tax Type - type: string - unitbase: - description: Unit Base - format: double - type: number - unitfeerate: - description: Unit Fee Rate - format: double - type: number - type: object - TaxTransactionResponse: - properties: - data: - items: - $ref: "#/definitions/TaxTransaction" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - TaxType: - properties: - accountid: - description: Authority Account Id - type: string - accountingrulecode: - description: The Accounting Rule Code used for GL Post - type: string - active: - description: Active - type: boolean - agencytype: - description: Agency Type - type: string - agentid: - description: Collection Agent Id - type: string - category: - description: Category - type: string - collectordomainid: - description: Collector Domain Id - type: string - companyid: - description: Company ID - type: string - contactid: - description: Authority Contact Id - type: string - createdbyid: - description: Created By User ID - type: string - createddate: - description: Created Date - type: string - description: - description: Description - type: string - effectivedate: - description: Effective Date - type: string - enddate: - description: End Date - type: string - enrollmentstatus: - description: Enrollment Status - type: string - filingcity: - description: Filing City - type: string - filingcountry: - description: Filing Country - type: string - filingemail: - description: Filing Email - type: string - filingmethod: - description: Filing Method - type: string - filingpostalcode: - description: Filing Postal Code - type: string - filingstate: - description: Filing State - type: string - filingstreet: - description: Filing Street - type: string - fractional: - description: - Does this Tax Type use a Fractional Basis for calculation? - type: boolean - frequency: - description: Frequency - type: string - geocodestring: - description: Geocode String - type: string - id: - description: Telnexus Record Id - type: string - interestrate: - description: Interest Rate - format: double - type: number - ismedicinal: - description: Business Tax? - type: boolean - isrecreational: - description: Cannabis Tax? - type: boolean - itemamount: - description: Rollup Amount - format: double - type: number - itemcount: - description: Rollup Tax Items - format: double - type: number - lastmodifiedbyid: - description: Last Modified By User ID - type: string - lastmodifieddate: - description: Last Modified Date - type: string - markuprate: - description: - The wholesale markup rate for Excise tax (CA cannabis) - format: double - type: number - name: - description: Tax Type Name (unique) - type: string - passthrough: - description: - Is this tax allowed to be passed-through to retail customers? - type: boolean - penaltydays: - description: Number of days until penalty is assessed - format: int64 - type: number - penaltyrate: - description: The percentage rate of a penalty (per month) - format: double - type: number - rate: - description: Tax Rate - format: double - type: number - reference: - description: Tax Website Reference - type: string - salesregulation: - description: Salesregulation Code for this TaxType - type: string - status: - description: TaxType Document Status - type: string - taxnexuscodeid: - description: Telnexus Code Id - type: string - taxnexusnumber: - description: The Tax Type number assigned by Telnexus - type: string - templateid: - description: Rendering Template Id - type: string - unitbase: - description: Rollup Unit Base - format: double - type: number - units: - description: Units - type: string - type: object - TaxTypeAccount: - properties: - tenantid: - type: string - accountid: - description: Account - type: string - accountnumber: - description: Account Number - type: string - active: - description: Active - type: boolean - amount: - description: Rollup Amount - format: double - type: number - contactid: - description: Contact ID - type: string - createdbyid: - type: string - createddate: - type: string - description: - description: Description - type: string - enddate: - description: End Date - type: string - id: - description: Telnexus Record Id Only; not used in POST - type: string - interest: - description: Interest - type: number - lastmodifiedbyid: - type: string - lastmodifieddate: - type: string - notes: - description: Notes - type: string - parentfk: - description: - UUID Reference the master record that owns this item - type: string - penalty: - description: Penalty - format: double - type: number - ref: - description: "Source System identifier for this record, if any" - type: string - reportedadjustments: - description: Reported Adjustments - format: double - type: number - reporteddeductions: - description: Reported Deductions - format: double - type: number - reportednetrevenue: - description: Reported Net Revenue - format: double - type: number - reportedrate: - description: Reported Rate - format: double - type: number - reportedrevenue: - description: Reported Revenue - format: double - type: number - revenuebase: - description: Rollup Revenue Base - format: double - type: number - revenuenet: - description: Rollup Revenue Net - format: double - type: number - revenuenottaxable: - description: Rollup Revenue Not Taxable - format: double - type: number - startdate: - description: Start Date - type: string - subtotal: - description: Reported Tax - format: double - type: number - tax: - description: Rollup Tax - format: double - type: number - taxontax: - description: Rollup Tax on Tax - format: double - type: number - taxtypeid: - description: Tax Type - type: string - totalamount: - description: Total Amount - format: double - type: number - unitbase: - description: Rollup Unit Base - format: double - type: number - type: object - TaxTypeAccountRequest: - properties: - data: - items: - $ref: "#/definitions/TaxTypeAccount" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - TaxTypeAccountResponse: - description: An array of TaxType Account objects with Contacts - properties: - data: - items: - $ref: "#/definitions/TaxTypeAccount" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - TaxTypeResponse: - description: An array of Tax Type objects - properties: - data: - items: - $ref: "#/definitions/TaxType" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - TelnexusCode: - properties: - active: - description: Is this an active Telnexus Code? - type: boolean - code: - description: Telnexus Code - type: string - createdbyid: - description: Created By User ID - type: string - createddate: - description: Created Date - type: string - description: - description: Telnexus Code Description - type: string - domainid: - description: Domain ID - type: string - domainname: - description: Domain Name - type: string - id: - description: Telnexus Record Id Only; not used in POST - type: string - level: - description: Level - type: string - lastmodifiedbyid: - description: Last Modified By User ID - type: string - lastmodifieddate: - description: Last Modified Date - type: string - part1: - description: Telnexus Code Part 1 - type: string - part2: - description: Telnexus Code Part 2 - type: string - part3: - description: Telnexus Code Part 3 - type: string - part4: - description: Telnexus Code Part 4 - type: string - part5: - description: Telnexus Code Part 4 - type: string - purchasingrulesetcode: - description: Purchasing Ruleset AccountingRuleset Code - type: string - purchasingrulesetid: - description: Purchasing Ruleset AccountingRuleset ID - type: string - ref: - description: External reference, if any - type: string - revenuerulesetcode: - description: Revenue Ruleset AccountingRuleset Code - type: string - revenuerulesetid: - description: Revenue Ruleset AccountingRuleset ID - type: string - type: object - TelnexusCodeResponse: - properties: - data: - items: - $ref: "#/definitions/TelnexusCode" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Template: - properties: - tenantid: - description: tenant identifier - type: string - CompanyID: - description: Company - type: string - CreatedByID: - type: string - CreatedDate: - type: string - Description: - description: Description - type: string - HTML: - description: HTML Body - type: string - format: byte - ID: - description: Telnexus Record Id - type: string - IsActive: - description: Active? - type: boolean - IsMaster: - description: Master Template? - type: boolean - LastModifiedByID: - type: string - LastModifiedDate: - type: string - Name: - description: Template Name - type: string - ObjectType: - description: Object - type: string - RecordTypeName: - description: Record Type Name - type: string - Type: - description: Type - type: string - URL: - description: URL - type: string - type: object - TemplateResponse: - properties: - data: - items: - $ref: "#/definitions/Template" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - User: - properties: - tenantid: - type: string - aboutme: - description: About Me - type: string - accountid: - description: Account ID - type: string - address: - $ref: "#/definitions/Address" - alias: - description: Alias - type: string - apikey: - description: API Key - type: string - auth0userid: - description: Auth0 User ID - type: string - communitynickname: - description: Nickname - type: string - companyname: - description: Company Name - type: string - contactid: - description: Contact - type: string - createdbyid: - description: Created User ID - type: string - createddate: - description: Date Created - type: string - delegatedapproverid: - description: Delegated Approver - type: string - department: - description: Department - type: string - division: - description: Division - type: string - email: - description: Email address - type: string - employeenumber: - description: Employee Number - type: string - endday: - description: Time day ends - type: string - environment: - description: Environment - type: string - extension: - description: Extension - type: string - fabricapikey: - description: Fabric API Key - type: string - fax: - description: Fax - type: string - firstname: - description: The first name - type: string - forecastenabled: - description: Allow Forecasting - type: boolean - fullphotourl: - description: Full Photo URL - type: string - id: - description: Telnexus ID - type: string - isactive: - description: Active - type: boolean - isportalenabled: - description: Is the user enabled for Communities? - type: boolean - isprofilephotoactive: - description: Has Profile Photo - type: boolean - issystemcontrolled: - type: boolean - lastip: - description: ip address of last login - type: string - lastlogin: - description: last login time - type: string - lastmodifiedbyid: - description: Last Modified User ID - type: string - lastmodifieddate: - description: Last Modified Date - type: string - lastname: - description: The Last Name - type: string - logincount: - description: number of times user has logged in - format: int64 - type: number - managerid: - description: Manager - type: string - mobilephone: - description: Mobile - type: string - name: - description: Name - type: string - outofofficemessage: - description: Out of office message - type: string - phone: - description: Phone - type: string - portalrole: - description: Portal Role Level - type: string - profileid: - description: Profile - type: string - receivesadmininfoemails: - description: Admin Info Emails - type: boolean - receivesinfoemails: - description: Info Emails - type: boolean - senderemail: - description: Email Sender Address - type: string - sendername: - description: Email Sender Name - type: string - signature: - description: Email Signature - type: string - smallphotourl: - description: Small Photo URL - type: string - startday: - description: The time day starts - type: string - TelnexusAccount: - description: Telnexus Account - type: string - timezonesidkey: - description: Time Zone - type: string - title: - description: Title - type: string - username: - description: Username - type: string - userroleid: - description: Role - type: string - usertype: - description: User Type - type: string - userroles: - items: - $ref: "#/definitions/UserRole" - type: array - tenantusers: - items: - $ref: "#/definitions/TenantUser" - type: array - type: object - UserResponse: - description: An array of Print-Ready ingest Objects - properties: - data: - items: - $ref: "#/definitions/User" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Notebook: - description: Defines a Telnexus Notebook - type: object - properties: - tenantid: - description: tenant identifier - type: string - id: - type: string - description: Record Id - accountid: - type: string - description: Account - contactid: - type: string - description: Contact - createdbyid: - type: string - description: Created By - createddate: - type: string - description: Created Date - date: - type: string - description: Analysis Date - dateend: - type: string - description: End Date - datestart: - type: string - description: Start Date - description: - type: string - description: Description - lastmodifiedbyid: - type: string - description: Last Modified By - lastmodifieddate: - type: string - description: Last Modifed Date - periodendid: - type: string - description: Ending Period - periodstartid: - type: string - description: Starting Period - preparerid: - type: string - description: Preparer - title: - type: string - description: Title - items: - type: array - items: - $ref: "#/definitions/NotebookItem" - NotebookRequest: - description: An array of Notebook objects - properties: - data: - items: - $ref: "#/definitions/Notebook" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - NotebookResponse: - description: An array of Notebook objects - properties: - data: - items: - $ref: "#/definitions/Notebook" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - NotebookItem: - type: object - description: An analysis item associated with a Notebook - properties: - tenantid: - description: tenant identifier - type: string - id: - type: string - description: Record Id - itemname: - type: string - description: Developer name of component - title: - type: string - description: Display title - notebookid: - type: string - description: The notebook that owns this Item - Tenant: - type: object - description: Telnexus Account Tenant - properties: - id: - type: string - description: Record Id - accountid: - type: string - description: The Account that owns this Tenant - active: - type: boolean - description: Is this Tenant currently active? - createdbyid: - type: string - description: Created By - createddate: - type: string - description: Created Date - lastmodifiedbyid: - type: string - description: Last Modified By - lastmodifieddate: - type: string - description: Last Modifed Date - status: - type: string - description: The current status of this Tenant - tenantname: - type: string - description: Name of the Tenant Resource - type: - type: string - description: Type of tenant - version: - type: string - description: - The version number of the Tenant Onboarding system used to - create this tenant - databases: - items: - $ref: "#/definitions/Database" - type: array - roles: - items: - $ref: "#/definitions/Role" - type: array - tenantusers: - items: - $ref: "#/definitions/TenantUser" - type: array - Role: - type: object - description: A functional role within a Tenant - properties: - id: - type: string - description: record id - auth0roleid: - description: the corresponding auth0 role - type: string - createdbyid: - type: string - description: created by - createddate: - type: string - description: created date - description: - type: string - description: role description - lastmodifiedbyid: - type: string - description: last modified by - lastmodifieddate: - type: string - description: last modifed date - rolename: - type: string - description: the name of this role - tenantid: - type: string - description: the id of the tenant that owns this role - RoleRequest: - description: An array of Role objects - properties: - data: - items: - $ref: "#/definitions/Role" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - RoleResponse: - description: An array of Role objects - properties: - data: - items: - $ref: "#/definitions/Role" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - TenantRequest: - description: An array of Tenant objects - properties: - data: - items: - $ref: "#/definitions/Tenant" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - TenantResponse: - description: An array of Tenant objects - properties: - data: - items: - $ref: "#/definitions/Tenant" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - Database: - type: object - description: A Database provisioned and owned by a Tenant - properties: - active: - description: Is this database active? - type: boolean - clusterid: - description: - The ID of the Cluster in which this database is deployed - type: string - createdbyid: - description: Created By - type: string - createddate: - description: Created Date - type: string - databasename: - description: The name of the physical database in the cluster - type: string - dsn: - description: Database connection string - type: string - id: - description: Record Id - type: string - lastmodifiedbyid: - description: Last Modified By - type: string - lastmodifieddate: - description: Last Modifed Date - type: string - microservices: - description: - List of Telnexus microservices implemented by this Database - type: string - status: - description: The current status of this Tenant - type: string - tenantid: - description: The ID of the tenant who owns this Database - type: string - type: - description: "The type of Database (mysql, etc)" - type: string - DatabaseRequest: - description: An array of Database objects - properties: - data: - items: - $ref: "#/definitions/Database" - type: array - meta: - $ref: "#/definitions/RequestMeta" - type: object - DatabaseResponse: - description: An array of Database objects - properties: - data: - items: - $ref: "#/definitions/Database" - type: array - meta: - $ref: "#/definitions/ResponseMeta" - type: object - TenantUser: - description: Relationship object that connects users to a tenant - type: object - properties: - accesslevel: - type: string - description: The Tenant access level for this User - tenantid: - type: string - description: The Tenant ID - userid: - type: string - description: The User ID - UserRole: - description: Relationship object that connects user to a role - type: object - properties: - description: - type: string - description: Role description - roleid: - type: string - description: The Role ID - userid: - type: string - description: The User ID - name: - type: string - description: Role Name - auth0roleid: - type: string - description: Linked role ID diff --git a/swagger/stash-telnexus.yaml b/swagger/stash-kvision.yaml similarity index 91% rename from swagger/stash-telnexus.yaml rename to swagger/stash-kvision.yaml index 2421401..9148f42 100644 --- a/swagger/stash-telnexus.yaml +++ b/swagger/stash-kvision.yaml @@ -1,13 +1,13 @@ swagger: "2.0" info: - version: 0.0.2 + version: 0.0.1 title: "stash" description: "PDF Storage Microservice" - termsOfService: "http://telnexus.com/terms/" + termsOfService: "http://taxnexus.net/terms/" contact: - email: "noc@telnexus.com" + email: "noc@taxnexus.net" license: - name: "Proprietary - Copyright (c) 2018-2020 by Telnexus LLC" + name: "Proprietary - Copyright (c) 2018-2021 by Taxnexus, Inc." securityDefinitions: ApiKeyAuth: type: "apiKey" @@ -18,7 +18,7 @@ security: schemes: - "http" basePath: "/v1" -host: "stash.infra.tnxs.net:8080" +host: "stash.vernonkeenan.com:8080" consumes: - "application/json" produces: @@ -52,7 +52,7 @@ responses: schema: $ref: "#/definitions/Error" PdfResponse: - description: Telnexus Response with an array of pdfs + description: Taxnexus Response with an array of pdfs schema: $ref: "#/definitions/DocumentResponse" ServerError: @@ -171,11 +171,11 @@ definitions: type: object RequestMeta: properties: - TelnexusAccount: - description: Telnexus Account Number of the Reseller or OEM + TaxnexusAccount: + description: Taxnexus Account Number of the Reseller or OEM type: string required: - - TelnexusAccount + - TaxnexusAccount type: object ResponseMeta: properties: @@ -209,8 +209,8 @@ definitions: ServerTimestamp: description: Backend Server Timestamp type: string - TelnexusAccount: + TaxnexusAccount: description: - Telnexus Account Number used for recording transactions + Taxnexus Account Number used for recording transactions type: string type: object diff --git a/swagger/voip-telnexus.yaml b/swagger/voip-telnexus.yaml deleted file mode 100644 index 69db38a..0000000 --- a/swagger/voip-telnexus.yaml +++ /dev/null @@ -1,1507 +0,0 @@ -swagger: "2.0" -info: - version: 0.0.2 - title: voip - description: Telnexus VoIP Microservice - termsOfService: http://telnexus.com/terms/ - contact: - email: noc@telnexus.com - license: - name: Proprietary - Copyright (c) 2012-2020 by Telnexus LLC -securityDefinitions: - ApiKeyAuth: - type: apiKey - in: header - name: X-API-Key -security: - - ApiKeyAuth: [] -schemes: - - http -basePath: /v1 -host: voip.infra.tnxs.net:8080 -consumes: - - application/json -produces: - - application/json -responses: - AuthorityResponse: - description: Telnexus Response with an array of Authority objects - schema: - $ref: "#/definitions/AuthorityResponse" - EndpointResponse: - description: Telnexus Response with an array of PBX objects - schema: - $ref: "#/definitions/EndpointResponse" - PhoneNumberResponse: - description: Telnexus Response with an array of PBX objects - schema: - $ref: "#/definitions/PhoneNumberResponse" - VmBoxResponse: - description: Telnexus Response with an array of PBX objects - schema: - $ref: "#/definitions/VmBoxResponse" - PbxResponse: - description: Telnexus Response with an array of PBX objects - schema: - $ref: "#/definitions/PbxResponse" - QueueResponse: - description: Telnexus Response with an array of Queue objects - schema: - $ref: "#/definitions/QueueResponse" - PbxUserResponse: - description: Telnexus Response with an array of PBX User objects - schema: - $ref: "#/definitions/PbxUserResponse" - AccessForbidden: - description: "Access forbidden, account lacks access" - schema: - $ref: "#/definitions/Error" - NotFound: - description: Resource was not found - schema: - $ref: "#/definitions/Error" - ServerError: - description: Server Internal Error - schema: - $ref: "#/definitions/Error" - Unauthorized: - description: "Access Unauthorized, invalid API-KEY was used" - schema: - $ref: "#/definitions/Error" - UnprocessableEntity: - description: "Unprocessable Entity, likely a bad parameter" - schema: - $ref: "#/definitions/Error" -parameters: - AuthorityRequest: - description: A request with an array of Authority Objects - in: body - name: authorityRequest - required: true - schema: - $ref: "#/definitions/AuthorityRequest" - EndpointRequest: - description: An array of new PBX records - in: body - name: endpointRequest - required: true - schema: - $ref: "#/definitions/EndpointRequest" - PbxRequest: - description: An array of new PBX records - in: body - name: pbxRequest - required: true - schema: - $ref: "#/definitions/PbxRequest" - PbxUserRequest: - description: An array of new PBX User records - in: body - name: pbxUserRequest - required: true - schema: - $ref: "#/definitions/PbxUserRequest" - PhoneNumberRequest: - description: An array of new PBX records - in: body - name: phoneNumberRequest - required: true - schema: - $ref: "#/definitions/PhoneNumberRequest" - VmBoxRequest: - description: An array of new VmBoxes - in: body - name: vmBoxRequest - required: true - schema: - $ref: "#/definitions/VmBoxRequest" - queueRequest: - description: An array of new Queues - in: body - name: queueRequest - required: true - schema: - $ref: "#/definitions/QueueRequest" - authorityIdQuery: - description: Telnexus Id of the Authority to be retrieved - in: query - name: authorityId - required: false - type: string - queueIdQuery: - description: Telnexus Id of the Queue to be retrieved - in: query - name: queueId - required: false - type: string - endpointIdQuery: - description: Telnexus Id of the endpoint to be retrieved - in: query - name: endpointId - required: false - type: string - limitQuery: - default: 100 - description: - "How many objects to return at one time (max 300, default 100)" - format: int64 - in: query - name: limit - required: false - type: integer - offsetQuery: - default: 0 - description: How many objects to skip? (default 0) - format: int64 - in: query - name: offset - required: false - type: integer - pbxIdQuery: - description: Telnexus Id of the PBX to be retrieved - in: query - name: pbxId - required: false - type: string - pbxUserIdQuery: - description: Telnexus Id of the PBX User to be retrieved - in: query - name: pbxUserId - required: false - type: string - phoneNumberIdQuery: - description: Telnexus Id of the Phone Number to be retrieved - in: query - name: phoneNumberId - required: false - type: string - vmBoxIdQuery: - description: Telnexus Id of the vmBox to be retrieved - in: query - name: vmBoxId - required: false - type: string -paths: - /authorities: - get: - description: Return a list of available Authorities - operationId: getAuthorities - parameters: - - $ref: "#/parameters/authorityIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/AuthorityResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Authorities - tags: - - Authority - post: - consumes: - - application/json - description: Create new Authorities - operationId: postAuthorities - parameters: - - $ref: "#/parameters/AuthorityRequest" - responses: - "200": - $ref: "#/responses/AuthorityResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Add new Authorities - tags: - - Authority - put: - consumes: - - application/json - description: - Update fields in an Authority record identified by Telnexus Id - operationId: putAuthorities - parameters: - - $ref: "#/parameters/AuthorityRequest" - responses: - "200": - $ref: "#/responses/AuthorityResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Update Authorities - tags: - - Authority - /endpoints: - get: - description: Return a list of available Endpoint entities - operationId: getEndpoints - parameters: - - $ref: "#/parameters/endpointIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/EndpointResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Endpoints - tags: - - Endpoint - post: - consumes: - - application/json - description: Create new Endpoints - operationId: postEndpoints - parameters: - - $ref: "#/parameters/EndpointRequest" - responses: - "200": - $ref: "#/responses/EndpointResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Add new Endpoints - tags: - - Endpoint - put: - consumes: - - application/json - description: - Update fields in Endpoint records identified by Telnexus Id - operationId: putEndpoints - parameters: - - $ref: "#/parameters/EndpointRequest" - responses: - "200": - $ref: "#/responses/EndpointResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Update Endpoints - tags: - - Endpoint - /pbxes: - get: - description: Return a list of available PBX entities - operationId: getPBXes - parameters: - - $ref: "#/parameters/pbxIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/PbxResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of PBXes - tags: - - Pbx - post: - consumes: - - application/json - description: Create new PBXes - operationId: postPBXes - parameters: - - $ref: "#/parameters/PbxRequest" - responses: - "200": - $ref: "#/responses/PbxResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Add new PBXes - tags: - - Pbx - put: - consumes: - - application/json - description: - Update fields in an PBX record identified by Telnexus Id - operationId: putPBXes - parameters: - - $ref: "#/parameters/PbxRequest" - responses: - "200": - $ref: "#/responses/PbxResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Update PBXes - tags: - - Pbx - /pbxusers: - get: - description: Return a list of available PBX Users - operationId: getPBXUsers - parameters: - - $ref: "#/parameters/pbxUserIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/PbxUserResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Authorities - tags: - - PbxUser - post: - consumes: - - application/json - description: Create new PBXUsers - operationId: postPBXUsers - parameters: - - $ref: "#/parameters/PbxUserRequest" - responses: - "200": - $ref: "#/responses/PbxUserResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Add new PBXUsers - tags: - - PbxUser - put: - consumes: - - application/json - description: - Update fields in PBXUsers record identified by Telnexus Id - operationId: PBXUsers - parameters: - - $ref: "#/parameters/PbxUserRequest" - responses: - "200": - $ref: "#/responses/PbxUserResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Update PBXUsers - tags: - - PbxUser - /phonenumbers: - get: - description: Return a list of available Phone Number entities - operationId: getPhoneNumbers - parameters: - - $ref: "#/parameters/phoneNumberIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/PhoneNumberResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Phone Number - tags: - - PhoneNumber - post: - consumes: - - application/json - description: Create new Phone Numbers - operationId: postPhoneNumbers - parameters: - - $ref: "#/parameters/PhoneNumberRequest" - responses: - "200": - $ref: "#/responses/PhoneNumberResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Add new Phone Numbers - tags: - - PhoneNumber - put: - consumes: - - application/json - description: - Update fields in an Phone Number record identified by Telnexus - Id - operationId: putPhoneNumbers - parameters: - - $ref: "#/parameters/PhoneNumberRequest" - responses: - "200": - $ref: "#/responses/PhoneNumberResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Update Phone Numbers - tags: - - PhoneNumber - /vmboxes: - get: - description: Return a list of available Voice Mail Box entities - operationId: getVmBoxes - parameters: - - $ref: "#/parameters/vmBoxIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/VmBoxResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Voice Mail Boxes - tags: - - VmBox - post: - consumes: - - application/json - description: Create new VmBoxes - operationId: postVmBoxes - parameters: - - $ref: "#/parameters/VmBoxRequest" - responses: - "200": - $ref: "#/responses/VmBoxResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Add new Voice Mail Boxes - tags: - - VmBox - put: - consumes: - - application/json - description: - Update fields in Voice Mail Box records identified by Telnexus - Id - operationId: putVmBoxes - parameters: - - $ref: "#/parameters/VmBoxRequest" - responses: - "200": - $ref: "#/responses/VmBoxResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Update Voice Mail Boxes - tags: - - VmBox - /queues: - get: - description: Return a list of available Queues - operationId: getQueues - parameters: - - $ref: "#/parameters/queueIdQuery" - - $ref: "#/parameters/limitQuery" - - $ref: "#/parameters/offsetQuery" - responses: - "200": - $ref: "#/responses/QueueResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Get a list of Queues - tags: - - Queue - post: - consumes: - - application/json - description: Create new Queues - operationId: postQueues - parameters: - - $ref: "#/parameters/queueRequest" - responses: - "200": - $ref: "#/responses/QueueResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Add new Queues - tags: - - Queue - put: - consumes: - - application/json - description: - Update fields in Queue records identified by Telnexus Id - operationId: putQueues - parameters: - - $ref: "#/parameters/queueRequest" - responses: - "200": - $ref: "#/responses/QueueResponse" - "401": - $ref: "#/responses/Unauthorized" - "403": - $ref: "#/responses/AccessForbidden" - "404": - $ref: "#/responses/NotFound" - "422": - $ref: "#/responses/UnprocessableEntity" - "500": - $ref: "#/responses/ServerError" - summary: Update Queues - tags: - - Queue -definitions: - Endpoint: - properties: - AssetID: - description: Asset ID - type: string - CallForwardID: - description: Call Forwarding Record ID - type: string - CallRestrictionID: - description: Call Restriction Record ID - type: string - CallerIdOverride: - description: Endpoint CNAM Override - type: string - ContactID: - description: Telnexus Contact ID - type: string - DeviceType: - description: Device Type - type: string - DialPlan: - description: Dial Plan - type: string - DoNotDisturb: - description: Do Not Disturb - type: string - DoNotDisturbEnabled: - description: Do Not Disturb Enabled? - type: boolean - Enabled: - description: Endpoint Enabled? - type: boolean - EndpointName: - description: Endpoint Name - type: string - ExcludeFromQueues: - description: Exclude From Queues? - type: boolean - ID: - description: Telnexus Record ID - type: string - KazooEndpointID: - description: Kazoo Endpoint ID - type: string - Language: - description: Endpoint Language Override - type: string - MacAddress: - description: MAC Address - type: string - MusicOnHold: - description: Music On Hold Override - type: string - MusicOnHoldMediaID: - description: Kazoo MOH Media ID - type: string - MwiUnassociatedUpdates: - description: MWI Unassociated Updates? - type: boolean - OwnerID: - description: Kazoo Owner ID - type: string - PbxID: - description: Telnexus PBX ID - type: string - PresenceID: - description: Presence ID - type: string - ProvisionID: - description: Provisioning Record ID - type: string - RegisterOverwriteNotify: - description: Register Overwrite Notify? - type: boolean - Ringtones: - description: Endpoint Ringtones - type: string - RingtonesExternal: - description: Ringtones External - type: string - RingtonesInternal: - description: Ringtones Internal - type: string - SipID: - description: SIP Information Record ID - type: string - SuppressUnregisterNotifications: - description: Suppress Unregister Notifications? - type: boolean - Timezone: - description: Endpoint Timezone Override - type: string - type: object - EndpointRequest: - description: - An array of Endpoint objects sent to be processed in a request - properties: - Data: - items: - $ref: "#/definitions/Endpoint" - type: array - type: object - EndpointResponse: - description: - An array of Endpoint objects sent in response to a request - properties: - Data: - items: - $ref: "#/definitions/Endpoint" - type: array - Meta: - $ref: "#/definitions/ResponseMeta" - type: object - Error: - properties: - Code: - format: int32 - type: integer - Fields: - type: string - Message: - type: string - type: object - Pbx: - properties: - AccountID: - description: Telnexus Account ID - type: string - BackendID: - description: Backend ID - type: string - BillingContact: - description: Billing Contact ID - type: string - BillingID: - description: Kazoo Billing ID - type: string - BillingMode: - description: Kazoo Billing Mode - type: string - CallRestrictionID: - description: Call Restriction Record ID - type: string - CallerIdEmergencyName: - description: Caller ID Emergency Name - type: string - CallerIdEmergencyNumber: - description: Caller ID Emergency Number - type: string - CallerIdExternalName: - description: Caller ID External Name - type: string - CallerIdExternalNumber: - description: Caller ID External Number - type: string - Created: - description: Date Created - type: string - Enabled: - description: User Enabled? - type: boolean - ID: - description: Telnexus ID - type: string - IsReseller: - description: Is Account a Reseller? - type: boolean - KazooAccountName: - description: Kazoo Account Name - type: string - KazooID: - description: Kazoo PBX ID - type: string - Language: - description: Language - type: string - MusicOnHold: - description: Default Music On Hold - type: string - Name: - description: PBX Name - type: string - Realm: - description: PBX Realm - type: string - ResellerID: - description: Reseller ID - type: string - TechnicalContactID: - description: Technical Contact - type: string - Timezone: - description: PBX Timezone - type: string - type: object - PbxRequest: - properties: - Data: - items: - $ref: "#/definitions/Pbx" - type: array - type: object - PbxResponse: - description: An array of Authority objects - properties: - Data: - items: - $ref: "#/definitions/Pbx" - type: array - Meta: - $ref: "#/definitions/ResponseMeta" - type: object - PbxUser: - properties: - CallRestrictionID: - description: Call Restriction Record ID - type: string - CallerID: - description: CNAM Override - type: string - ContactID: - description: Telnexus Contact ID - type: string - Email: - description: Email Address - type: string - Enabled: - description: Enabled? - type: boolean - FaxToEmailEnabled: - description: Fax To Email Enabled? - type: boolean - FirstName: - description: First Name - type: string - ID: - description: Telnexus ID - type: string - Language: - description: Language - type: string - LastName: - description: Last Name - type: string - PbxID: - description: Telnexus PBX ID - type: string - PrivLevel: - description: Privilege Level - type: string - RecordCall: - description: RecordCall? - type: boolean - RequirePasswordUpdate: - description: Require Passoword Update? - type: boolean - Timezone: - description: Timezone - type: string - UserID: - description: Kazoo User ID - type: string - UserName: - description: Kazoo Username - type: string - Verified: - description: Verified? - type: boolean - VmToEmailEnabled: - description: Voice Mail to Email Enabled? - type: boolean - type: object - PbxUserRequest: - properties: - Data: - items: - $ref: "#/definitions/PbxUser" - type: array - type: object - PbxUserResponse: - description: An array of PBX objects - properties: - Data: - items: - $ref: "#/definitions/PbxUser" - type: array - Meta: - $ref: "#/definitions/ResponseMeta" - type: object - PhoneNumber: - properties: - AccountID: - description: Telnexus Account ID - type: string - AuthorityID: - description: AuthorityID - type: string - CompanyID: - description: Telnexus Company ID - type: string - ContactID: - description: Telnexus Contact ID - type: string - ContractID: - description: Telnexus Contract ID - type: string - Description: - description: Description - type: string - Extension: - description: Extension - type: string - FaxLine: - description: Fax Line? - type: boolean - ID: - description: Telnexus Record ID - type: string - Indicator: - description: Indicator - type: string - LocalService: - description: Local Service - type: boolean - LocalToll: - description: Local Toll - type: boolean - LongDistance: - description: Long Distance - type: boolean - LosingCarrier: - description: Losing Carrier - type: string - OpportunityID: - description: Telnexus Opportunity ID - type: string - OrderID: - description: Telnexus Order ID - type: string - PhoneNumber: - description: Phone Number - type: string - PortOut: - description: Is this number to ported out? - type: boolean - ProductID: - description: Telnexus Product ID - type: string - QuoteID: - description: Telnexus Quote ID - type: string - Ratecenter: - description: Rate Center - type: string - Safety: - description: Is this a safety number? - type: boolean - Status: - description: Number Status - type: string - SubscriptionID: - description: Subscription ID - type: string - Tollfree: - description: Tollfree - type: string - Type: - description: Number Type - type: string - WholesalerID: - description: Wholesale Vendor ID - type: string - type: object - PhoneNumberRequest: - properties: - Data: - items: - $ref: "#/definitions/PhoneNumber" - type: array - type: object - PhoneNumberResponse: - description: An array of Phone Number objects - properties: - Data: - items: - $ref: "#/definitions/PhoneNumber" - type: array - Meta: - $ref: "#/definitions/ResponseMeta" - type: object - Recipient: - type: object - properties: - ID: - description: Telnexus Record Identifier - type: string - Available: - type: string - AvailabilityState: - type: string - QueueAvailability: - type: string - OfferedCall: - type: string - HandlingCall: - type: string - WiretappingRecipient: - type: string - WiretapMode: - type: string - WrapupTimeSeconds: - type: string - Node: - type: string - Stats: - type: object - $ref: "#/definitions/RecipientStats" - RecipientStats: - type: object - properties: - ID: - description: Telnexus Record Identifier - type: string - TotalCalls: - type: number - format: int64 - MissedCalls: - type: number - format: int64 - AvgCallTime: - type: number - format: float64 - LoginTime: - type: number - format: int64 - LastActionTime: - type: number - LastHandledTime: - type: number - RecipientRequest: - properties: - Data: - items: - $ref: "#/definitions/Recipient" - type: array - type: object - RecipientResponse: - description: An array of Recipient objects - properties: - Data: - items: - $ref: "#/definitions/Recipient" - type: array - Meta: - $ref: "#/definitions/ResponseMeta" - type: object - ResponseMeta: - properties: - Contact: - description: Microservice Contact Info - type: string - Copyright: - description: Copyright Info - type: string - License: - description: License Information and Restrictions - type: string - operationId: - description: Operation ID - type: string - RequestIP: - description: Request IP Address - type: string - RequestType: - description: Request Type - type: string - RequestURL: - description: Request URL - type: string - ServerInfo: - description: Data Server Info - type: string - ServerResponseTime: - description: Data Server Response Time (ms) - type: string - ServerTimestamp: - description: Backend Server Timestamp - type: string - TelnexusAccount: - description: - Telnexus Account Number used for recording transactions - type: string - type: object - Queue: - type: object - properties: - ID: - description: Telnexus Record Identifier - type: string - AgentWrapupTime: - description: - Pre-defined wait period applied after an agent handles a - customer call (in seconds) - type: integer - ForceAwayOnReject: - description: - If set to true and a recipient rejects a call, they will be - forced to away state - type: boolean - HoldTreatment: - description: - Media ID (or appropriate media URI) of media to play while - caller is on hold. - type: string - Name: - description: A friendly name for the queue - type: string - QueueRouter: - default: route_round_robin - description: - The queue router used for routing and delivering calls to - recipients - type: string - QueueType: - description: The type of queue - type: string - RingTimeout: - description: - Amount of time in seconds that qubicle will wait while ringing - for the agent to successfully answer a call. - type: integer - TickTime: - description: The time between delivery ticks in milliseconds - type: integer - Timeout: - description: - The maximum amount of time in seconds that a call will wait in - queue. - type: integer - TimeoutIfSizeExceeds: - description: - If set to a non-zero value the queue will immediately time out - any call entering the queue over the size - type: integer - TimeoutImmediatelyIfEmpty: - description: - If set to true and a call enters the queue while it has no - logged in agents, the call will time out - type: boolean - TimoutRedirect: - description: - The ID of a queue that the call will be sent to in the event - of a timeout - type: string - QueueRequest: - properties: - Data: - items: - $ref: "#/definitions/Queue" - type: array - type: object - QueueResponse: - description: An array of Recipient objects - properties: - Data: - items: - $ref: "#/definitions/Recipient" - type: array - Meta: - $ref: "#/definitions/ResponseMeta" - type: object - VmBox: - properties: - CheckIfOwner: - description: Check if VM owner is owner of endpoint - type: boolean - DeleteAfterNotify: - description: Delete VM after notification - type: boolean - ID: - description: Telnexus Record ID - type: string - IsSetup: - description: Is this VM Box setup? - type: boolean - KazooID: - description: Kazoo Mailbox Id - type: string - KazooOwnerID: - description: Kazoo User Id - type: string - MailboxNumber: - description: Kazoo Mailbox Number - type: string - Name: - description: Mailbox Name - type: string - NotConfigurable: - description: Not Configurable? - type: boolean - PbxID: - description: Telnexus PBX ID - type: string - RequirePIN: - description: Require PIN? - type: boolean - SaveAfterNotify: - description: Save after notify? - type: boolean - SkipGreeting: - description: Skip Greeting? - type: boolean - SkipInstructions: - description: Skip Instructions? - type: boolean - type: object - VmBoxRequest: - properties: - Data: - items: - $ref: "#/definitions/VmBox" - type: array - type: object - VmBoxResponse: - description: An array of VmBox objects - properties: - Data: - items: - $ref: "#/definitions/VmBox" - type: array - Meta: - $ref: "#/definitions/ResponseMeta" - type: object - Authority: - properties: - AccountID: - description: Account - type: string - AddressLine1: - description: Address Line 1 - type: string - AddressLine2: - description: Address Line 2 - type: string - BTN: - description: Billing Telephone Number - type: string - City: - description: City - type: string - ContactID: - description: Contact Name - type: string - Country: - description: Country - type: string - CreatedByID: - description: Created By User ID - type: string - CreatedDate: - description: Created Date - type: string - Date: - description: Authority Date - type: string - DateApproved: - description: Date Approved - type: string - ID: - description: Telnexus Record Identifier - type: string - LastModifiedByID: - description: Last Modified By User ID - type: string - LastModifiedDate: - description: Last Modified Date - type: string - LosingCarrier: - description: Losing Carrier - type: string - Name: - description: Authority Number - type: string - NameLine1: - description: Name Line 1 - type: string - NameLine2: - description: Name Line 2 - type: string - OpportunityID: - description: Opportunity Name - type: string - OrderID: - description: Order Number - type: string - ParentFK: - description: - UUID Reference the master record that owns this item - type: string - PostalCode: - description: Zip Code - type: string - QuoteID: - description: Quote Name - type: string - Ref: - description: "Source System identifier for this record, if any" - type: string - State: - description: State - type: string - Status: - description: Status - type: string - TemplateID: - description: ID of the Template for this object instance - type: string - TenantID: - description: Tenant that owns this object instance - type: string - TransferDate: - description: Transfer Date - type: string - Type: - description: Authority Type - type: string - type: object - AuthorityRequest: - properties: - Data: - items: - $ref: "#/definitions/Authority" - type: array - type: object - AuthorityResponse: - description: An array of Authority objects - properties: - Data: - items: - $ref: "#/definitions/Authority" - type: array - Meta: - $ref: "#/definitions/ResponseMeta" - type: object - Callflow: - description: - Call flows describe steps to take in order to process a phone - call. They are trees of information related to a phone call such - as "answer, play file, record file" etc. that are logically - grouped together and ordered. - properties: - ID: - description: Telnexus Record Identifier - type: string - FeatureCode: - description: - When the callflow is used as a featurecode this object tracks - the intended match of the pattern and name of the feature - properties: - name: - type: string - number: - type: string - type: object - Flags: - description: Flags set by external applications - items: - type: string - type: array - Flow: - $ref: "#/definitions/CallFlowAction" - description: - A callflow node defines a module to execute, data to provide - to that module, and zero or more children to branch to - # Metaflow: - # $ref: "#/definitions/metaflows" - # description: - # Actions applied to a call outside of the normal callflow, - # initiated by the caller(s) - Numbers: - default: [] - description: - A list of static numbers that the callflow should execute for - items: - maxLength: 36 - minLength: 1 - type: string - type: array - uniqueItems: true - Patterns: - default: [] - description: - A list of regular expressions that the callflow should execute - for, with optional capture groups - items: - minLength: 1 - type: string - type: array - type: object - CallFlowAction: - description: - Call flows describe steps to take in order to process a phone - call. They are trees of information related to a phone call such - as "answer, play file, record file" etc. that are logically - grouped together and ordered. - properties: - ID: - description: Telnexus Record Identifier - type: string - Children: - description: Children callflows - type: object - Data: - default: {} - description: The data/arguments of the callflow module - type: object - Module: - description: - The name of the callflow module to execute at this node - maxLength: 64 - minLength: 1 - type: string - type: object diff --git a/swagger/workflow-telnexus.yaml b/swagger/workflow-kvision.yaml similarity index 94% rename from swagger/workflow-telnexus.yaml rename to swagger/workflow-kvision.yaml index 5c69ced..fa4745b 100644 --- a/swagger/workflow-telnexus.yaml +++ b/swagger/workflow-kvision.yaml @@ -1,13 +1,13 @@ swagger: "2.0" info: - version: 0.0.2 + version: 0.0.1 title: "workflow" description: "Workflow Microservice" - termsOfService: "http://telnexus.com/terms/" + termsOfService: "http://taxnexus.net/terms/" contact: - email: "noc@telnexus.com" + email: "noc@taxnexus.net" license: - name: "Proprietary - Copyright (c) 2018-2020 by Telnexus LLC" + name: "Proprietary - Copyright (c) 2018-2021 by Taxnexus, Inc." securityDefinitions: ApiKeyAuth: type: "apiKey" @@ -16,7 +16,7 @@ securityDefinitions: schemes: - "http" basePath: "/v1" -host: "workflow.infra.tnxs.net:8080" +host: "workflow.vernonkeenan.com:8080" consumes: - "application/json" produces: @@ -233,7 +233,7 @@ definitions: type: string type: object AppLogRequest: - description: An array Telnexus Application Log objects + description: An array Taxnexus Application Log objects properties: data: items: @@ -243,7 +243,7 @@ definitions: $ref: "#/definitions/RequestMeta" type: object AppLogResponse: - description: An array Telnexus Application Log objects + description: An array Taxnexus Application Log objects properties: data: items: @@ -253,7 +253,7 @@ definitions: $ref: "#/definitions/ResponseMeta" type: object Document: - description: Telnexus Document + description: Taxnexus Document properties: ArchivedByID: type: string @@ -453,7 +453,7 @@ definitions: type: string type: object EmailMessageRequest: - description: An array Telnexus Send Email Message objects + description: An array Taxnexus Send Email Message objects properties: data: items: @@ -463,7 +463,7 @@ definitions: $ref: "#/definitions/RequestMeta" type: object EmailMessagesResponse: - description: An array Telnexus user objects + description: An array Taxnexus user objects properties: data: items: @@ -530,7 +530,7 @@ definitions: type: string type: object OutgoingEmailMessageRequest: - description: An array Telnexus New Email Message objects + description: An array Taxnexus New Email Message objects properties: data: items: @@ -541,11 +541,11 @@ definitions: type: object RequestMeta: properties: - TelnexusAccount: - description: Telnexus Account Number of the Reseller or OEM + TaxnexusAccount: + description: Taxnexus Account Number of the Reseller or OEM type: string required: - - TelnexusAccount + - TaxnexusAccount type: object ResponseMeta: properties: @@ -579,8 +579,8 @@ definitions: ServerTimestamp: description: Backend Server Timestamp type: string - TelnexusAccount: + TaxnexusAccount: description: - Telnexus Account Number used for recording transactions + Taxnexus Account Number used for recording transactions type: string type: object